UNPKG

primeng

Version:

PrimeNG is an open source UI library for Angular featuring a rich set of 80+ components, a theme designer, various theme alternatives such as Material, Bootstrap, Tailwind, premium templates and professional support. In addition, it integrates with PrimeB

397 lines (391 loc) 18.3 kB
import * as _angular_core from '@angular/core'; import * as _primeuix_motion from '@primeuix/motion'; import { MotionOptions, MotionEvent } from '@primeuix/motion'; import { BaseComponent } from 'primeng/basecomponent'; import * as i1 from 'primeng/bind'; import { Bind } from 'primeng/bind'; import { MotionPassThrough } from 'primeng/types/motion'; import { BaseStyle } from 'primeng/base'; declare class MotionStyle extends BaseStyle { name: string; style: string; classes: { root: string; }; static ɵfac: _angular_core.ɵɵFactoryDeclaration<MotionStyle, never>; static ɵprov: _angular_core.ɵɵInjectableDeclaration<MotionStyle>; } interface MotionStyle extends BaseStyle { } /** * Motion component is a container to apply motion effects to its content. * @group Components */ declare class Motion extends BaseComponent<MotionPassThrough> { $pcMotion: Motion | undefined; bindDirectiveInstance: Bind; onAfterViewChecked(): void; _componentStyle: MotionStyle; /******************** Inputs ********************/ /** * Whether the element is visible or not. * @group Props */ visible: _angular_core.InputSignal<boolean>; /** * Whether to mount the element on enter. * @group Props */ mountOnEnter: _angular_core.InputSignal<boolean>; /** * Whether to unmount the element on leave. * @group Props */ unmountOnLeave: _angular_core.InputSignal<boolean>; /** * The name of the motion. It can be a predefined motion name or a custom one. * phases: * [name]-enter * [name]-enter-active * [name]-enter-to * [name]-leave * [name]-leave-active * [name]-leave-to * @group Props */ name: _angular_core.InputSignal<string | undefined>; /** * The type of the motion, valid values 'transition' and 'animation'. * @group Props */ type: _angular_core.InputSignal<_primeuix_motion.MotionType | undefined>; /** * Whether the motion is safe. * @group Props */ safe: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion is disabled. * @group Props */ disabled: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should appear. * @group Props */ appear: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should enter. * @group Props */ enter: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should leave. * @group Props */ leave: _angular_core.InputSignal<boolean | undefined>; /** * The duration of the motion. * @group Props */ duration: _angular_core.InputSignal<_primeuix_motion.MotionDuration>; /** * The hide strategy of the motion, valid values 'display' and 'visibility'. * @group Props */ hideStrategy: _angular_core.InputSignal<"display" | "visibility">; /** * The enter from class of the motion. * @group Props */ enterFromClass: _angular_core.InputSignal<string | undefined>; /** * The enter to class of the motion. * @group Props */ enterToClass: _angular_core.InputSignal<string | undefined>; /** * The enter active class of the motion. * @group Props */ enterActiveClass: _angular_core.InputSignal<string | undefined>; /** * The leave from class of the motion. * @group Props */ leaveFromClass: _angular_core.InputSignal<string | undefined>; /** * The leave to class of the motion. * @group Props */ leaveToClass: _angular_core.InputSignal<string | undefined>; /** * The leave active class of the motion. * @group Props */ leaveActiveClass: _angular_core.InputSignal<string | undefined>; /******************** All Inputs ********************/ /** * The motion options. * @group Props */ options: _angular_core.InputSignal<MotionOptions>; /******************** Outputs ********************/ /** * Callback fired before the enter transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onBeforeEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the enter transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired after the enter transition/animation ends. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onAfterEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the enter transition/animation is cancelled. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onEnterCancelled: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired before the leave transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onBeforeLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the leave transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired after the leave transition/animation ends. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onAfterLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the leave transition/animation is cancelled. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onLeaveCancelled: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /******************** Computed ********************/ private motionOptions; private motion; private isInitialMount; private cancelled; private destroyed; rendered: _angular_core.WritableSignal<boolean>; private readonly handleBeforeEnter; private readonly handleEnter; private readonly handleAfterEnter; private readonly handleEnterCancelled; private readonly handleBeforeLeave; private readonly handleLeave; private readonly handleAfterLeave; private readonly handleLeaveCancelled; constructor(); onDestroy(): void; static ɵfac: _angular_core.ɵɵFactoryDeclaration<Motion, never>; static ɵcmp: _angular_core.ɵɵComponentDeclaration<Motion, "p-motion", never, { "visible": { "alias": "visible"; "required": false; "isSignal": true; }; "mountOnEnter": { "alias": "mountOnEnter"; "required": false; "isSignal": true; }; "unmountOnLeave": { "alias": "unmountOnLeave"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "type": { "alias": "type"; "required": false; "isSignal": true; }; "safe": { "alias": "safe"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "appear": { "alias": "appear"; "required": false; "isSignal": true; }; "enter": { "alias": "enter"; "required": false; "isSignal": true; }; "leave": { "alias": "leave"; "required": false; "isSignal": true; }; "duration": { "alias": "duration"; "required": false; "isSignal": true; }; "hideStrategy": { "alias": "hideStrategy"; "required": false; "isSignal": true; }; "enterFromClass": { "alias": "enterFromClass"; "required": false; "isSignal": true; }; "enterToClass": { "alias": "enterToClass"; "required": false; "isSignal": true; }; "enterActiveClass": { "alias": "enterActiveClass"; "required": false; "isSignal": true; }; "leaveFromClass": { "alias": "leaveFromClass"; "required": false; "isSignal": true; }; "leaveToClass": { "alias": "leaveToClass"; "required": false; "isSignal": true; }; "leaveActiveClass": { "alias": "leaveActiveClass"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": false; "isSignal": true; }; }, { "onBeforeEnter": "onBeforeEnter"; "onEnter": "onEnter"; "onAfterEnter": "onAfterEnter"; "onEnterCancelled": "onEnterCancelled"; "onBeforeLeave": "onBeforeLeave"; "onLeave": "onLeave"; "onAfterLeave": "onAfterLeave"; "onLeaveCancelled": "onLeaveCancelled"; }, never, ["*"], true, [{ directive: typeof i1.Bind; inputs: {}; outputs: {}; }]>; } /** * Motion Directive is directive to apply motion effects to elements. * @group Components */ declare class MotionDirective extends BaseComponent { $pcMotionDirective: MotionDirective | undefined; /******************** Inputs ********************/ /** * Whether the element is visible or not. * @group Props */ visible: _angular_core.InputSignal<boolean>; /** * The name of the motion. It can be a predefined motion name or a custom one. * phases: * [name]-enter * [name]-enter-active * [name]-enter-to * [name]-leave * [name]-leave-active * [name]-leave-to * @group Props */ name: _angular_core.InputSignal<string | undefined>; /** * The type of the motion, valid values 'transition' and 'animation'. * @group Props */ type: _angular_core.InputSignal<_primeuix_motion.MotionType | undefined>; /** * Whether the motion is safe. * @group Props */ safe: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion is disabled. * @group Props */ disabled: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should appear. * @group Props */ appear: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should enter. * @group Props */ enter: _angular_core.InputSignal<boolean | undefined>; /** * Whether the motion should leave. * @group Props */ leave: _angular_core.InputSignal<boolean | undefined>; /** * The duration of the motion. * @group Props */ duration: _angular_core.InputSignal<_primeuix_motion.MotionDuration>; /** * The hide strategy of the motion, valid values 'display' and 'visibility'. * @group Props */ hideStrategy: _angular_core.InputSignal<"display" | "visibility">; /** * The enter from class of the motion. * @group Props */ enterFromClass: _angular_core.InputSignal<string | undefined>; /** * The enter to class of the motion. * @group Props */ enterToClass: _angular_core.InputSignal<string | undefined>; /** * The enter active class of the motion. * @group Props */ enterActiveClass: _angular_core.InputSignal<string | undefined>; /** * The leave from class of the motion. * @group Props */ leaveFromClass: _angular_core.InputSignal<string | undefined>; /** * The leave to class of the motion. * @group Props */ leaveToClass: _angular_core.InputSignal<string | undefined>; /** * The leave active class of the motion. * @group Props */ leaveActiveClass: _angular_core.InputSignal<string | undefined>; /******************** All Inputs ********************/ /** * The motion options. * @group Props */ options: _angular_core.InputSignal<MotionOptions>; /******************** Outputs ********************/ /** * Callback fired before the enter transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onBeforeEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the enter transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired after the enter transition/animation ends. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onAfterEnter: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the enter transition/animation is cancelled. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onEnterCancelled: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired before the leave transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onBeforeLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the leave transition/animation starts. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired after the leave transition/animation ends. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onAfterLeave: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /** * Callback fired when the leave transition/animation is cancelled. * @param {MotionEvent} [event] - The event object containing details about the motion. * @param {Element} event.element - The element being transitioned/animated. * @group Emits */ onLeaveCancelled: _angular_core.OutputEmitterRef<MotionEvent | undefined>; /******************** Computed ********************/ private motionOptions; private motion; private isInitialMount; private cancelled; private destroyed; private readonly handleBeforeEnter; private readonly handleEnter; private readonly handleAfterEnter; private readonly handleEnterCancelled; private readonly handleBeforeLeave; private readonly handleLeave; private readonly handleAfterLeave; private readonly handleLeaveCancelled; constructor(); onDestroy(): void; static ɵfac: _angular_core.ɵɵFactoryDeclaration<MotionDirective, never>; static ɵdir: _angular_core.ɵɵDirectiveDeclaration<MotionDirective, "[pMotion]", never, { "visible": { "alias": "pMotion"; "required": false; "isSignal": true; }; "name": { "alias": "pMotionName"; "required": false; "isSignal": true; }; "type": { "alias": "pMotionType"; "required": false; "isSignal": true; }; "safe": { "alias": "pMotionSafe"; "required": false; "isSignal": true; }; "disabled": { "alias": "pMotionDisabled"; "required": false; "isSignal": true; }; "appear": { "alias": "pMotionAppear"; "required": false; "isSignal": true; }; "enter": { "alias": "pMotionEnter"; "required": false; "isSignal": true; }; "leave": { "alias": "pMotionLeave"; "required": false; "isSignal": true; }; "duration": { "alias": "pMotionDuration"; "required": false; "isSignal": true; }; "hideStrategy": { "alias": "pMotionHideStrategy"; "required": false; "isSignal": true; }; "enterFromClass": { "alias": "pMotionEnterFromClass"; "required": false; "isSignal": true; }; "enterToClass": { "alias": "pMotionEnterToClass"; "required": false; "isSignal": true; }; "enterActiveClass": { "alias": "pMotionEnterActiveClass"; "required": false; "isSignal": true; }; "leaveFromClass": { "alias": "pMotionLeaveFromClass"; "required": false; "isSignal": true; }; "leaveToClass": { "alias": "pMotionLeaveToClass"; "required": false; "isSignal": true; }; "leaveActiveClass": { "alias": "pMotionLeaveActiveClass"; "required": false; "isSignal": true; }; "options": { "alias": "pMotionOptions"; "required": false; "isSignal": true; }; }, { "onBeforeEnter": "pMotionOnBeforeEnter"; "onEnter": "pMotionOnEnter"; "onAfterEnter": "pMotionOnAfterEnter"; "onEnterCancelled": "pMotionOnEnterCancelled"; "onBeforeLeave": "pMotionOnBeforeLeave"; "onLeave": "pMotionOnLeave"; "onAfterLeave": "pMotionOnAfterLeave"; "onLeaveCancelled": "pMotionOnLeaveCancelled"; }, never, never, true, never>; } declare class MotionModule { static ɵfac: _angular_core.ɵɵFactoryDeclaration<MotionModule, never>; static ɵmod: _angular_core.ɵɵNgModuleDeclaration<MotionModule, never, [typeof Motion, typeof MotionDirective], [typeof Motion, typeof MotionDirective]>; static ɵinj: _angular_core.ɵɵInjectorDeclaration<MotionModule>; } export { Motion, MotionDirective, MotionModule };