index.d.ts 957 B

12345678910111213141516171819202122232425262728
  1. import * as React from 'react';
  2. import type { SizeType } from '../config-provider/SizeContext';
  3. import Compact from './Compact';
  4. export { SpaceContext } from './context';
  5. export type SpaceSize = SizeType | number;
  6. export interface SpaceProps extends React.HTMLAttributes<HTMLDivElement> {
  7. prefixCls?: string;
  8. className?: string;
  9. rootClassName?: string;
  10. style?: React.CSSProperties;
  11. size?: SpaceSize | [SpaceSize, SpaceSize];
  12. direction?: 'horizontal' | 'vertical';
  13. align?: 'start' | 'end' | 'center' | 'baseline';
  14. split?: React.ReactNode;
  15. wrap?: boolean;
  16. classNames?: {
  17. item: string;
  18. };
  19. styles?: {
  20. item: React.CSSProperties;
  21. };
  22. }
  23. declare const InternalSpace: React.ForwardRefExoticComponent<SpaceProps & React.RefAttributes<HTMLDivElement>>;
  24. type CompoundedComponent = typeof InternalSpace & {
  25. Compact: typeof Compact;
  26. };
  27. declare const Space: CompoundedComponent;
  28. export default Space;