@@ -50,27 +50,52 @@ type ComponentsConfig = {
5050} ;
5151
5252export interface ThemeConfig {
53+ /**
54+ * @descCN 用于修改 Design Token。
55+ * @descEN Modify Design Token.
56+ */
5357 token ?: Partial < AliasToken > ;
58+ /**
59+ * @descCN 用于修改各个组件的 Component Token 以及覆盖该组件消费的 Alias Token。
60+ * @descEN Modify Component Token and Alias Token applied to components.
61+ */
5462 components ?: ComponentsConfig ;
63+ /**
64+ * @descCN 用于修改 Seed Token 到 Map Token 的算法。
65+ * @descEN Modify the algorithms of theme.
66+ * @default defaultAlgorithm
67+ */
5568 algorithm ?: MappingAlgorithm | MappingAlgorithm [ ] ;
69+ /**
70+ * @descCN 是否继承外层 `ConfigProvider` 中配置的主题。
71+ * @descEN Whether to inherit the theme configured in the outer layer `ConfigProvider`.
72+ * @default true
73+ */
5674 inherit ?: boolean ;
5775 /**
58- * @descCN 是否开启 `hashed` 属性。如果你的应用中只存在一个版本的 antd,你可以设置为 `false` 来进一步减小样式体积。默认值为 `ture`。
59- * @descEN Whether to enable the `hashed` attribute. If there is only one version of antd in your application, you can set `false` to reduce the bundle size. defaults to `true`.
76+ * @descCN 是否开启 `hashed` 属性。如果你的应用中只存在一个版本的 antd,你可以设置为 `false` 来进一步减小样式体积。
77+ * @descEN Whether to enable the `hashed` attribute. If there is only one version of antd in your application, you can set `false` to reduce the bundle size.
78+ * @default true
79+ * @since 5.12.0
6080 */
6181 hashed ?: boolean ;
6282 /**
63- * @descCN 通过 `cssVar` 配置来开启 CSS 变量模式,这个配置会被继承。默认值为 `false`。
64- * @descEN Enable CSS variable mode through `cssVar` configuration, This configuration will be inherited. defaults to `false`.
83+ * @descCN 通过 `cssVar` 配置来开启 CSS 变量模式,这个配置会被继承。
84+ * @descEN Enable CSS variable mode through `cssVar` configuration, This configuration will be inherited.
85+ * @default false
86+ * @since 5.12.0
6587 */
6688 cssVar ?:
6789 | {
6890 /**
69- * Prefix for css variable, default to `ant`.
91+ * @descCN css 变量的前缀
92+ * @descEN Prefix for css variable.
93+ * @default ant
7094 */
7195 prefix ?: string ;
7296 /**
73- * Unique key for theme, should be set manually < react@18.
97+ * @descCN 主题的唯一 key,版本低于 react@18 时需要手动设置。
98+ * @descEN Unique key for theme, should be set manually < react@18.
7499 */
75100 key ?: string ;
76101 }
@@ -141,7 +166,16 @@ export type SpaceConfig = ComponentStyleConfig & Pick<SpaceProps, 'size' | 'clas
141166export type PopupOverflow = 'viewport' | 'scroll' ;
142167
143168export interface WaveConfig {
169+ /**
170+ * @descCN 是否开启水波纹效果。如果需要关闭,可以设置为 `false`。
171+ * @descEN Whether to use wave effect. If it needs to close, set to `false`.
172+ * @default true
173+ */
144174 disabled ?: boolean ;
175+ /**
176+ * @descCN 自定义水波纹效果。
177+ * @descEN Customized wave effect.
178+ */
145179 showEffect ?: ShowWaveEffect ;
146180}
147181
@@ -152,6 +186,10 @@ export interface ConfigConsumerProps {
152186 iconPrefixCls : string ;
153187 getPrefixCls : ( suffixCls ?: string , customizePrefixCls ?: string ) => string ;
154188 renderEmpty ?: RenderEmptyHandler ;
189+ /**
190+ * @descCN 设置 [Content Security Policy](https://developer.mozilla.org/zh-CN/docs/Web/HTTP/CSP) 配置。
191+ * @descEN Set the [Content Security Policy](https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP) config.
192+ */
155193 csp ?: CSPConfig ;
156194 autoInsertSpaceInButton ?: boolean ;
157195 input ?: InputConfig ;
0 commit comments