seeds.d.ts 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. import type { PresetColorType } from './presetColors';
  2. export interface SeedToken extends PresetColorType {
  3. /**
  4. * @nameZH 品牌主色
  5. * @nameEN Brand Color
  6. * @desc 品牌色是体现产品特性和传播理念最直观的视觉元素之一。在你完成品牌主色的选取之后,我们会自动帮你生成一套完整的色板,并赋予它们有效的设计语义
  7. * @descEN Brand color is one of the most direct visual elements to reflect the characteristics and communication of the product. After you have selected the brand color, we will automatically generate a complete color palette and assign it effective design semantics.
  8. */
  9. colorPrimary: string;
  10. /**
  11. * @nameZH 成功色
  12. * @nameEN Success Color
  13. * @desc 用于表示操作成功的 Token 序列,如 Result、Progress 等组件会使用该组梯度变量。
  14. * @descEN Used to represent the token sequence of operation success, such as Result, Progress and other components will use these map tokens.
  15. */
  16. colorSuccess: string;
  17. /**
  18. * @nameZH 警戒色
  19. * @nameEN Warning Color
  20. * @desc 用于表示操作警告的 Token 序列,如 Notification、 Alert等警告类组件或 Input 输入类等组件会使用该组梯度变量。
  21. * @descEN Used to represent the warning map token, such as Notification, Alert, etc. Alert or Control component(like Input) will use these map tokens.
  22. */
  23. colorWarning: string;
  24. /**
  25. * @nameZH 错误色
  26. * @nameEN Error Color
  27. * @desc 用于表示操作失败的 Token 序列,如失败按钮、错误状态提示(Result)组件等。
  28. * @descEN Used to represent the visual elements of the operation failure, such as the error Button, error Result component, etc.
  29. */
  30. colorError: string;
  31. /**
  32. * @nameZH 信息色
  33. * @nameEN Info Color
  34. * @desc 用于表示操作信息的 Token 序列,如 Alert 、Tag、 Progress 等组件都有用到该组梯度变量。
  35. * @descEN Used to represent the operation information of the Token sequence, such as Alert, Tag, Progress, and other components use these map tokens.
  36. */
  37. colorInfo: string;
  38. /**
  39. * @nameZH 基础文本色
  40. * @nameEN Seed Text Color
  41. * @desc 用于派生文本色梯度的基础变量,v5 中我们添加了一层文本色的派生算法可以产出梯度明确的文本色的梯度变量。但**请不要在代码中直接使用该 Seed Token**!
  42. * @descEN Used to derive the base variable of the text color gradient. In v5, we added a layer of text color derivation algorithm to produce gradient variables of text color gradient. But please do not use this Seed Token directly in the code!
  43. */
  44. colorTextBase: string;
  45. /**
  46. * @nameZH 基础背景色
  47. * @nameEN Seed Background Color
  48. * @desc 用于派生背景色梯度的基础变量,v5 中我们添加了一层背景色的派生算法可以产出梯度明确的背景色的梯度变量。但 **请不要在代码中直接使用该 Seed Token** !
  49. * @descEN Used to derive the base variable of the background color gradient. In v5, we added a layer of background color derivation algorithm to produce map token of background color. But PLEASE DO NOT USE this Seed Token directly in the code!
  50. */
  51. colorBgBase: string;
  52. /**
  53. * @nameZH 字体
  54. * @nameEN FontFamily
  55. * @desc Ant Design 的字体家族中优先使用系统默认的界面字体,同时提供了一套利于屏显的备用字体库,来维护在不同平台以及浏览器的显示下,字体始终保持良好的易读性和可读性,体现了友好、稳定和专业的特性。
  56. */
  57. fontFamily: string;
  58. /**
  59. * @nameZH 默认字号
  60. * @nameEN Default Font Size
  61. * @desc 设计系统中使用最广泛的字体大小,文本梯度也将基于该字号进行派生。
  62. * @default 14
  63. */
  64. fontSize: number;
  65. /**
  66. * @nameZH 基础线宽
  67. * @nameEN Base Line Width
  68. * @desc 用于控制组件边框、分割线等的宽度
  69. * @descEN Border width of base components
  70. */
  71. lineWidth: number;
  72. /**
  73. * @nameZH 线条样式
  74. * @nameEN Line Style
  75. * @desc 用于控制组件边框、分割线等的样式,默认是实线
  76. * @descEN Border style of base components
  77. */
  78. lineType: string;
  79. /**
  80. * @nameZH 基础圆角
  81. * @nameEN Base Border Radius
  82. * @descEN Border radius of base components
  83. * @desc 基础组件的圆角大小,例如按钮、输入框、卡片等
  84. */
  85. borderRadius: number;
  86. /**
  87. * @nameZH 尺寸变化单位
  88. * @nameEN Size Change Unit
  89. * @desc 用于控制组件尺寸的变化单位,在 Ant Design 中我们的基础单位为 4 ,便于更加细致地控制尺寸梯度
  90. * @descEN The unit of size change, in Ant Design, our base unit is 4, which is more fine-grained control of the size step
  91. * @default 4
  92. */
  93. sizeUnit: number;
  94. /**
  95. * @nameZH 尺寸步长
  96. * @nameEN Size Base Step
  97. * @desc 用于控制组件尺寸的基础步长,尺寸步长结合尺寸变化单位,就可以派生各种尺寸梯度。通过调整步长即可得到不同的布局模式,例如 V5 紧凑模式下的尺寸步长为 2
  98. * @descEN The base step of size change, the size step combined with the size change unit, can derive various size steps. By adjusting the step, you can get different layout modes, such as the size step of the compact mode of V5 is 2
  99. * @default 4
  100. */
  101. sizeStep: number;
  102. /**
  103. * @nameZH 组件箭头尺寸
  104. */
  105. sizePopupArrow: number;
  106. /**
  107. * @nameZH 基础高度
  108. * @nameEN Base Control Height
  109. * @desc Ant Design 中按钮和输入框等基础控件的高度
  110. * @descEN The height of the basic controls such as buttons and input boxes in Ant Design
  111. * @default 32
  112. */
  113. controlHeight: number;
  114. /**
  115. * @nameZH 基础 zIndex
  116. * @nameEN Base zIndex
  117. * @desc 所有组件的基础 Z 轴值,用于一些悬浮类的组件的可以基于该值 Z 轴控制层级,例如 BackTop、 Affix 等
  118. * @descEN The base Z axis value of all components, which can be used to control the level of some floating components based on the Z axis value, such as BackTop, Affix, etc.
  119. *
  120. * @default 0
  121. */
  122. zIndexBase: number;
  123. /**
  124. * @nameZH 浮层基础 zIndex
  125. * @nameEN popup base zIndex
  126. * @desc 浮层类组件的基础 Z 轴值,用于一些悬浮类的组件的可以基于该值 Z 轴控制层级,例如 FloatButton、 Affix、Modal 等
  127. * @descEN Base zIndex of component like FloatButton, Affix which can be cover by large popup
  128. * @default 1000
  129. */
  130. zIndexPopupBase: number;
  131. /**
  132. * @nameZH 图片不透明度
  133. * @nameEN Define default Image opacity. Useful when in dark-like theme
  134. */
  135. opacityImage: number;
  136. /**
  137. * @nameZH 动画时长变化单位
  138. * @nameEN Animation Duration Unit
  139. * @desc 用于控制动画时长的变化单位
  140. * @descEN The unit of animation duration change
  141. * @default 100ms
  142. */
  143. motionUnit: number;
  144. /**
  145. * @nameZH 动画基础时长
  146. */
  147. motionBase: number;
  148. motionEaseOutCirc: string;
  149. motionEaseInOutCirc: string;
  150. motionEaseInOut: string;
  151. motionEaseOutBack: string;
  152. motionEaseInBack: string;
  153. motionEaseInQuint: string;
  154. motionEaseOutQuint: string;
  155. motionEaseOut: string;
  156. /**
  157. * @nameZH 线框风格
  158. * @nameEN Wireframe Style
  159. * @desc 用于将组件的视觉效果变为线框化,如果需要使用 V4 的效果,需要开启配置项
  160. * @default false
  161. */
  162. wireframe: boolean;
  163. }