UNPKG

@progress/kendo-react-animation

Version:

React Animation component assists with animating HTML elements. KendoReact Animation package

84 lines (83 loc) 2.75 kB
import * as React from 'react'; import * as PropTypes from 'prop-types'; import { AnimationInterface } from './AnimationInterface'; /** * Specifies the direction of the Slide Animation ([see example]({% slug direction_animation %}#toc-slide)). * * The supported directions are: * * (Default) `down`&mdash;On showing, slides the content from top to bottom, and vice-versa. * * `up`&mdash;On showing, slides the content from bottom to top, and vice-versa. * * `left`&mdash;On showing, slides the content from right to left, and vice-versa. * * `right`&mdash;On showing, slides the content from left to right, and vice-versa. */ export declare type SlideDirection = 'up' | 'down' | 'left' | 'right'; /** * Represent the props of the [KendoReact Slide Animation component]({% slug animationtypes_animation %}#toc-slide). * * {% meta %} * {% variant title:Hooks %} * {% embed_file props/slide/func/main.tsx preview %} * {% embed_file props/slide/func/styles.css %} * {% endvariant %} * {% variant title:Classes %} * {% embed_file props/slide/class/main.tsx preview %} * {% embed_file props/slide/class/styles.css %} * {% endvariant %} * {% endmeta %} * */ export interface SlideProps extends AnimationInterface { /** * After the element reaches its exit state, it is no longer available in the DOM. If a DOM operation is required, access it trough the `childFactory` function. */ childFactory?: any; /** * Specifies the CSS class names which are set to the Animation. */ className?: string; /** * Specifies the direction of the Slide Animation. Defaults to `down`. */ direction?: SlideDirection; /** * Specifies the node type of the parent Animation. Defaults to `div`. */ component?: string; /** * Specifies the id of the Animation. */ id?: string; /** * Specifies the style of the parent Animation. */ style?: any; } export declare class Slide extends React.Component<SlideProps, {}> { /** * @hidden */ static propTypes: { children: PropTypes.Requireable<NonNullable<PropTypes.ReactNodeLike>>; childFactory: PropTypes.Requireable<any>; className: PropTypes.Requireable<string>; direction: PropTypes.Requireable<string>; component: PropTypes.Requireable<string>; id: PropTypes.Requireable<string>; style: PropTypes.Requireable<any>; }; /** * @hidden */ static defaultProps: { appear: boolean; enter: boolean; exit: boolean; transitionEnterDuration: number; transitionExitDuration: number; direction: string; }; /** * @hidden */ render(): JSX.Element; }