UNPKG

1.1 kBTypeScriptView Raw
1import * as React from 'react';
2import type { AvatarProps } from './Avatar';
3import SkeletonAvatar from './Avatar';
4import SkeletonButton from './Button';
5import SkeletonImage from './Image';
6import SkeletonInput from './Input';
7import SkeletonNode from './Node';
8import type { SkeletonParagraphProps } from './Paragraph';
9import type { SkeletonTitleProps } from './Title';
10type SkeletonAvatarProps = Omit<AvatarProps, 'active'>;
11export interface SkeletonProps {
12 active?: boolean;
13 loading?: boolean;
14 prefixCls?: string;
15 className?: string;
16 rootClassName?: string;
17 style?: React.CSSProperties;
18 children?: React.ReactNode;
19 avatar?: SkeletonAvatarProps | boolean;
20 title?: SkeletonTitleProps | boolean;
21 paragraph?: SkeletonParagraphProps | boolean;
22 round?: boolean;
23}
24type CompoundedComponent = {
25 Button: typeof SkeletonButton;
26 Avatar: typeof SkeletonAvatar;
27 Input: typeof SkeletonInput;
28 Image: typeof SkeletonImage;
29 Node: typeof SkeletonNode;
30};
31declare const Skeleton: React.FC<SkeletonProps> & CompoundedComponent;
32export default Skeleton;