index.d.ts 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. import type { CSSProperties } from 'react';
  2. import type { FullToken, GenerateStyle, GetDefaultToken } from '../../theme/internal';
  3. /** Component only token. Which will handle additional calculation of alias token */
  4. export interface ComponentToken {
  5. /**
  6. * @desc 折叠面板头部内边距
  7. * @descEN Padding of header
  8. */
  9. headerPadding: CSSProperties['padding'];
  10. /**
  11. * @desc 折叠面板头部背景
  12. * @descEN Background of header
  13. */
  14. headerBg: string;
  15. /**
  16. * @desc 折叠面板内容内边距
  17. * @descEN Padding of content
  18. */
  19. contentPadding: CSSProperties['padding'];
  20. /**
  21. * @desc 折叠面板内容背景
  22. * @descEN Background of content
  23. */
  24. contentBg: string;
  25. /**
  26. * @desc 简约风格折叠面板的内容内边距
  27. * @descEN Padding of content in borderless style
  28. */
  29. borderlessContentPadding: CSSProperties['padding'];
  30. /**
  31. * @desc 简约风格折叠面板的内容背景
  32. * @descEN Background of content in borderless style
  33. */
  34. borderlessContentBg: string;
  35. }
  36. type CollapseToken = FullToken<'Collapse'> & {
  37. /**
  38. * @desc 小号折叠面板头部内边距
  39. * @descEN Padding of small header
  40. */
  41. collapseHeaderPaddingSM: string;
  42. /**
  43. * @desc 大号折叠面板头部内边距
  44. * @descEN Padding of large header
  45. */
  46. collapseHeaderPaddingLG: string;
  47. /**
  48. * @desc 折叠面板边框圆角
  49. * @descEN Border radius of collapse panel
  50. */
  51. collapsePanelBorderRadius: number;
  52. };
  53. export declare const genBaseStyle: GenerateStyle<CollapseToken>;
  54. export declare const prepareComponentToken: GetDefaultToken<'Collapse'>;
  55. declare const _default: (prefixCls: string, rootCls?: string) => readonly [(node: React.ReactElement) => React.ReactElement, string, string];
  56. export default _default;