feffery_antd_components 0.4.3-rc2 → 0.4.3-rc4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/DESCRIPTION +1 -1
  2. package/Project.toml +1 -1
  3. package/README-en_US.md +1 -1
  4. package/README.md +1 -1
  5. package/feffery_antd_components/AntdConfigProvider.py +21 -2
  6. package/feffery_antd_components/AntdModal.py +8 -4
  7. package/feffery_antd_components/AntdNotification.py +20 -9
  8. package/feffery_antd_components/AntdTable.py +53 -22
  9. package/feffery_antd_components/async-antd_table.js +2 -2
  10. package/feffery_antd_components/async-data_display.js +1 -1
  11. package/feffery_antd_components/async-data_entry.js +3 -3
  12. package/feffery_antd_components/async-upload.js +2 -2
  13. package/feffery_antd_components/feffery_antd_components.min.js +6 -6
  14. package/feffery_antd_components/metadata.json +1 -1
  15. package/feffery_antd_components/package-info.json +2 -2
  16. package/package.json +2 -2
  17. package/src/jl/'feffery'_antdconfigprovider.jl +6 -1
  18. package/src/jl/'feffery'_antdmodal.jl +2 -1
  19. package/src/jl/'feffery'_antdnotification.jl +6 -4
  20. package/src/jl/'feffery'_antdtable.jl +21 -9
  21. package/src/lib/components/dataDisplay/AntdTable.react.js +48 -8
  22. package/src/lib/components/feedback/AntdModal.react.js +10 -3
  23. package/src/lib/components/feedback/AntdNotification.react.js +9 -4
  24. package/src/lib/components/locales.react.js +4 -0
  25. package/src/lib/components/other/AntdConfigProvider.react.js +38 -25
  26. package/src/lib/fragments/AntdTable.react.js +47 -15
  27. package/tests/dataDisplay/AntdTable/feat_select_mode_show_search.py +70 -0
  28. package/tests/dataDisplay/AntdTable/feat_tag_mode_tooltip.py +88 -0
  29. package/tests/dataDisplay/AntdTable/feat_title_popover_nodes.py +79 -0
  30. package/tests/dataDisplay/AntdTable/perf_editable_column_format_constrait_message.py +65 -0
  31. package/tests/feedback/AntdModal/feat_loading_title.py +92 -0
  32. package/tests/feedback/AntdNotification/feat_component_content.py +64 -0
  33. package/tests/feedback/AntdNotification/feat_number_of_stack.py +40 -0
  34. package/tests/other/AntdConfigProvider/feat_use_css.py +67 -0
package/DESCRIPTION CHANGED
@@ -1,6 +1,6 @@
1
1
  Package: fefferyAntdComponents
2
2
  Title: Best implementation of Antd components in Plotly Dash.
3
- Version: 0.4.3-rc2
3
+ Version: 0.4.3-rc4
4
4
  Description: Best implementation of Antd components in Plotly Dash.
5
5
  Depends: R (>= 3.0.2)
6
6
  Imports:
package/Project.toml CHANGED
@@ -2,7 +2,7 @@
2
2
  name = "FefferyAntdComponents"
3
3
  uuid = "1b08a953-4be3-4667-9a23-674b58f7de79"
4
4
  authors = ["CNFeffery <fefferypzy@gmail.com>"]
5
- version = "0.4.3-rc2"
5
+ version = "0.4.3-rc4"
6
6
 
7
7
  [deps]
8
8
  Dash = "1b08a953-4be3-4667-9a23-3db579824955"
package/README-en_US.md CHANGED
@@ -33,7 +33,7 @@ pip install feffery-antd-components -U
33
33
  ## 2 Install the latest preview release version
34
34
 
35
35
  > [!NOTE]
36
- > The latest preview release version (2025-10-11): `0.4.3rc2`
36
+ > The latest preview release version (2025-11-19): `0.4.3rc4`
37
37
 
38
38
  ```bash
39
39
  pip install feffery-antd-components --pre -U
package/README.md CHANGED
@@ -33,7 +33,7 @@ pip install feffery-antd-components -U
33
33
  ## 2 最新预发布版本安装方式
34
34
 
35
35
  > [!NOTE]
36
- > 最新预发布版本(2025-10-11):`0.4.3rc2`
36
+ > 最新预发布版本(2025-11-19):`0.4.3rc4`
37
37
 
38
38
  ```bash
39
39
  pip install feffery-antd-components --pre -U
@@ -37,6 +37,16 @@ Keyword arguments:
37
37
  为内部组件设置快捷主题算法,支持多种主题组合,可选项有`'default'`、`'dark'`、`'compact'`
38
38
  默认值:`'default'`.
39
39
 
40
+ - cssVar (dict; optional):
41
+ 是否开启`CSS`变量模式,具体参考:https://ant-design.antgroup.com/docs/react/css-variables
42
+ 默认值:`False`.
43
+
44
+ `cssVar` is a boolean | dict with keys:
45
+
46
+ - prefix (string; optional)
47
+
48
+ - key (string; optional)
49
+
40
50
  - useOldTheme (a value equal to: 'default', 'dark'; optional):
41
51
  是否强制使用`0.3.x`版本之前的主题样式,可选项有`'default'`、`'dark'`.
42
52
 
@@ -81,6 +91,14 @@ Keyword arguments:
81
91
  _base_nodes = ['children']
82
92
  _namespace = 'feffery_antd_components'
83
93
  _type = 'AntdConfigProvider'
94
+ CssVar = TypedDict(
95
+ "CssVar",
96
+ {
97
+ "prefix": NotRequired[str],
98
+ "key": NotRequired[str]
99
+ }
100
+ )
101
+
84
102
  Token = TypedDict(
85
103
  "Token",
86
104
  {
@@ -102,6 +120,7 @@ Keyword arguments:
102
120
  id: typing.Optional[typing.Union[str, dict]] = None,
103
121
  key: typing.Optional[str] = None,
104
122
  algorithm: typing.Optional[typing.Union[Literal["default", "dark", "compact"], typing.Sequence[Literal["default", "dark", "compact"]]]] = None,
123
+ cssVar: typing.Optional[typing.Union[bool, "CssVar"]] = None,
105
124
  useOldTheme: typing.Optional[Literal["default", "dark"]] = None,
106
125
  primaryColor: typing.Optional[str] = None,
107
126
  componentDisabled: typing.Optional[bool] = None,
@@ -114,9 +133,9 @@ Keyword arguments:
114
133
  enableLayer: typing.Optional[bool] = None,
115
134
  **kwargs
116
135
  ):
117
- self._prop_names = ['id', 'key', 'children', 'algorithm', 'useOldTheme', 'primaryColor', 'componentDisabled', 'componentSize', 'locale', 'wavesDisabled', 'token', 'componentsToken', 'compatibilityMode', 'enableLayer']
136
+ self._prop_names = ['id', 'key', 'children', 'algorithm', 'cssVar', 'useOldTheme', 'primaryColor', 'componentDisabled', 'componentSize', 'locale', 'wavesDisabled', 'token', 'componentsToken', 'compatibilityMode', 'enableLayer']
118
137
  self._valid_wildcard_attributes = []
119
- self.available_properties = ['id', 'key', 'children', 'algorithm', 'useOldTheme', 'primaryColor', 'componentDisabled', 'componentSize', 'locale', 'wavesDisabled', 'token', 'componentsToken', 'compatibilityMode', 'enableLayer']
138
+ self.available_properties = ['id', 'key', 'children', 'algorithm', 'cssVar', 'useOldTheme', 'primaryColor', 'componentDisabled', 'componentSize', 'locale', 'wavesDisabled', 'token', 'componentsToken', 'compatibilityMode', 'enableLayer']
120
139
  self.available_wildcard_properties = []
121
140
  _explicit_args = kwargs.pop('_explicit_args')
122
141
  _locals = locals()
@@ -92,6 +92,9 @@ Keyword arguments:
92
92
  - title (a list of or a singular dash component, string or number; optional):
93
93
  组件型,标题内容.
94
94
 
95
+ - loadingTitle (a list of or a singular dash component, string or number; optional):
96
+ 组件型,loading状态下的标题内容.
97
+
95
98
  - renderFooter (boolean; default False):
96
99
  是否渲染底部操作按钮 默认值:`False`.
97
100
 
@@ -238,8 +241,8 @@ Keyword arguments:
238
241
 
239
242
  - aria-* (string; optional):
240
243
  `aria-*`格式属性通配."""
241
- _children_props = ['title', 'okText', 'cancelText', 'loadingOkText']
242
- _base_nodes = ['title', 'okText', 'cancelText', 'loadingOkText', 'children']
244
+ _children_props = ['title', 'loadingTitle', 'okText', 'cancelText', 'loadingOkText']
245
+ _base_nodes = ['title', 'loadingTitle', 'okText', 'cancelText', 'loadingOkText', 'children']
243
246
  _namespace = 'feffery_antd_components'
244
247
  _type = 'AntdModal'
245
248
  Styles = TypedDict(
@@ -317,6 +320,7 @@ Keyword arguments:
317
320
  locale: typing.Optional[Literal["zh-cn", "en-us", "de-de", "ru-ru"]] = None,
318
321
  visible: typing.Optional[bool] = None,
319
322
  title: typing.Optional[ComponentType] = None,
323
+ loadingTitle: typing.Optional[ComponentType] = None,
320
324
  renderFooter: typing.Optional[bool] = None,
321
325
  okText: typing.Optional[ComponentType] = None,
322
326
  okButtonProps: typing.Optional["OkButtonProps"] = None,
@@ -343,9 +347,9 @@ Keyword arguments:
343
347
  loading: typing.Optional[bool] = None,
344
348
  **kwargs
345
349
  ):
346
- self._prop_names = ['id', 'key', 'children', 'style', 'className', 'styles', 'classNames', 'locale', 'visible', 'title', 'renderFooter', 'okText', 'okButtonProps', 'cancelText', 'cancelButtonProps', 'width', 'centered', 'keyboard', 'closable', 'mask', 'maskClosable', 'okClickClose', 'preventClose', 'zIndex', 'okCounts', 'cancelCounts', 'closeCounts', 'confirmAutoSpin', 'loadingOkText', 'confirmLoading', 'transitionType', 'forceRender', 'destroyOnClose', 'loading', 'data-*', 'aria-*']
350
+ self._prop_names = ['id', 'key', 'children', 'style', 'className', 'styles', 'classNames', 'locale', 'visible', 'title', 'loadingTitle', 'renderFooter', 'okText', 'okButtonProps', 'cancelText', 'cancelButtonProps', 'width', 'centered', 'keyboard', 'closable', 'mask', 'maskClosable', 'okClickClose', 'preventClose', 'zIndex', 'okCounts', 'cancelCounts', 'closeCounts', 'confirmAutoSpin', 'loadingOkText', 'confirmLoading', 'transitionType', 'forceRender', 'destroyOnClose', 'loading', 'data-*', 'aria-*']
347
351
  self._valid_wildcard_attributes = ['data-', 'aria-']
348
- self.available_properties = ['id', 'key', 'children', 'style', 'className', 'styles', 'classNames', 'locale', 'visible', 'title', 'renderFooter', 'okText', 'okButtonProps', 'cancelText', 'cancelButtonProps', 'width', 'centered', 'keyboard', 'closable', 'mask', 'maskClosable', 'okClickClose', 'preventClose', 'zIndex', 'okCounts', 'cancelCounts', 'closeCounts', 'confirmAutoSpin', 'loadingOkText', 'confirmLoading', 'transitionType', 'forceRender', 'destroyOnClose', 'loading', 'data-*', 'aria-*']
352
+ self.available_properties = ['id', 'key', 'children', 'style', 'className', 'styles', 'classNames', 'locale', 'visible', 'title', 'loadingTitle', 'renderFooter', 'okText', 'okButtonProps', 'cancelText', 'cancelButtonProps', 'width', 'centered', 'keyboard', 'closable', 'mask', 'maskClosable', 'okClickClose', 'preventClose', 'zIndex', 'okCounts', 'cancelCounts', 'closeCounts', 'confirmAutoSpin', 'loadingOkText', 'confirmLoading', 'transitionType', 'forceRender', 'destroyOnClose', 'loading', 'data-*', 'aria-*']
349
353
  self.available_wildcard_properties = ['data-', 'aria-']
350
354
  _explicit_args = kwargs.pop('_explicit_args')
351
355
  _locals = locals()
@@ -33,10 +33,10 @@ Keyword arguments:
33
33
  - className (string | dict; optional):
34
34
  当前组件css类名,支持[动态css](/advanced-classname).
35
35
 
36
- - message (string; optional):
36
+ - message (a list of or a singular dash component, string or number; optional):
37
37
  通知提醒主要信息.
38
38
 
39
- - description (string; optional):
39
+ - description (a list of or a singular dash component, string or number; optional):
40
40
  通知提醒描述信息.
41
41
 
42
42
  - type (a value equal to: 'default', 'success', 'error', 'info', 'warning'; default 'default'):
@@ -86,10 +86,14 @@ Keyword arguments:
86
86
  - danger (boolean; optional):
87
87
  按钮是否呈现危险状态 默认值:`False`.
88
88
 
89
- - stack (boolean; default False):
90
- 是否开启多通知自动折叠堆叠功能 默认值:`False`."""
91
- _children_props = []
92
- _base_nodes = ['children']
89
+ - stack (dict; default False):
90
+ 是否开启多通知自动折叠堆叠功能 默认值:`False`.
91
+
92
+ `stack` is a boolean | dict with keys:
93
+
94
+ - threshold (number; optional)"""
95
+ _children_props = ['message', 'description']
96
+ _base_nodes = ['message', 'description', 'children']
93
97
  _namespace = 'feffery_antd_components'
94
98
  _type = 'AntdNotification'
95
99
  CloseButton = TypedDict(
@@ -103,6 +107,13 @@ Keyword arguments:
103
107
  }
104
108
  )
105
109
 
110
+ Stack = TypedDict(
111
+ "Stack",
112
+ {
113
+ "threshold": NotRequired[NumberType]
114
+ }
115
+ )
116
+
106
117
 
107
118
  def __init__(
108
119
  self,
@@ -110,8 +121,8 @@ Keyword arguments:
110
121
  key: typing.Optional[str] = None,
111
122
  style: typing.Optional[typing.Any] = None,
112
123
  className: typing.Optional[typing.Union[str, dict]] = None,
113
- message: typing.Optional[str] = None,
114
- description: typing.Optional[str] = None,
124
+ message: typing.Optional[ComponentType] = None,
125
+ description: typing.Optional[ComponentType] = None,
115
126
  type: typing.Optional[Literal["default", "success", "error", "info", "warning"]] = None,
116
127
  placement: typing.Optional[Literal["top", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight"]] = None,
117
128
  top: typing.Optional[NumberType] = None,
@@ -121,7 +132,7 @@ Keyword arguments:
121
132
  pauseOnHover: typing.Optional[bool] = None,
122
133
  closable: typing.Optional[bool] = None,
123
134
  closeButton: typing.Optional["CloseButton"] = None,
124
- stack: typing.Optional[bool] = None,
135
+ stack: typing.Optional[typing.Union[bool, "Stack"]] = None,
125
136
  **kwargs
126
137
  ):
127
138
  self._prop_names = ['id', 'key', 'style', 'className', 'message', 'description', 'type', 'placement', 'top', 'bottom', 'duration', 'showProgress', 'pauseOnHover', 'closable', 'closeButton', 'stack']
@@ -254,13 +254,37 @@ Keyword arguments:
254
254
  适用于`'tags'`模式,标签颜色.
255
255
 
256
256
  - tag (string | number; optional):
257
- 适用于`'tags'`模式,标签内容. | list of dicts with keys:
257
+ 适用于`'tags'`模式,标签内容.
258
+
259
+ - tooltip (dict; optional):
260
+ 适用于`'tags'`模式,为当前标签添加额外的文字提示功能.
261
+
262
+ `tooltip` is a dict with keys:
263
+
264
+ - title (string; optional):
265
+ 文字提示内容.
266
+
267
+ - placement (a value equal to: 'top', 'left', 'right', 'bottom', 'topLeft', 'topRight', 'bottomLeft', 'bottomRight'; optional):
268
+ 文字提示弹出方向,可选项有`'top'`、`'left'`、`'right'`、`'bottom'`、`'topLeft'`、`'topRight'`、`'bottomLeft'`、`'bottomRight'`、`'leftTop'`、`'leftBottom'`、`'rightTop'`、`'rightBottom'`
269
+ 默认值:`'top'`. | list of dicts with keys:
258
270
 
259
271
  - color (string; optional):
260
272
  适用于`'tags'`模式,当前标签颜色.
261
273
 
262
274
  - tag (string | number; optional):
263
- 适用于`'tags'`模式,当前标签内容. | dict with keys:
275
+ 适用于`'tags'`模式,当前标签内容.
276
+
277
+ - tooltip (dict; optional):
278
+ 适用于`'tags'`模式,为当前标签添加额外的文字提示功能.
279
+
280
+ `tooltip` is a dict with keys:
281
+
282
+ - title (string; optional):
283
+ 文字提示内容.
284
+
285
+ - placement (a value equal to: 'top', 'left', 'right', 'bottom', 'topLeft', 'topRight', 'bottomLeft', 'bottomRight'; optional):
286
+ 文字提示弹出方向,可选项有`'top'`、`'left'`、`'right'`、`'bottom'`、`'topLeft'`、`'topRight'`、`'bottomLeft'`、`'bottomRight'`、`'leftTop'`、`'leftBottom'`、`'rightTop'`、`'rightBottom'`
287
+ 默认值:`'top'`. | dict with keys:
264
288
 
265
289
  - disabled (boolean; optional):
266
290
  适用于`'button'`模式,同`AntdButton`中的同名参数.
@@ -535,7 +559,10 @@ Keyword arguments:
535
559
  默认值:`'value'`.
536
560
 
537
561
  - allowClear (boolean; optional):
538
- 适用于`'select'`模式,是否允许快捷清空已选项 默认值:`True`. | dict
562
+ 适用于`'select'`模式,是否允许快捷清空已选项 默认值:`True`.
563
+
564
+ - showSearch (boolean; optional):
565
+ 适用于`'select'`模式,是否开启输入框可搜索功能. | dict
539
566
 
540
567
  - bordered (boolean; default False):
541
568
  是否渲染框线 默认值:`False`.
@@ -600,17 +627,19 @@ Keyword arguments:
600
627
  - recentlyMouseEnterRow (dict; optional):
601
628
  当`enableHoverListen=True`时,监听最近一次鼠标移入的行数据信息.
602
629
 
603
- - titlePopoverInfo (dict; optional):
630
+ - titlePopoverInfo (list of dicts; optional):
604
631
  配置各字段标题额外气泡说明卡片信息相关参数.
605
632
 
606
- `titlePopoverInfo` is a dict with strings as keys and values of
607
- type dict with keys:
633
+ `titlePopoverInfo` is a list of dicts with keys:
608
634
 
609
- - title (string; optional):
610
- 气泡卡片标题.
635
+ - dataIndex (string; required):
636
+ 必填,对应字段的dataIndex.
611
637
 
612
- - content (string; optional):
613
- 气泡卡片内容.
638
+ - title (a list of or a singular dash component, string or number; optional):
639
+ 气泡卡片标题,支持字符串或组件型.
640
+
641
+ - content (a list of or a singular dash component, string or number; optional):
642
+ 气泡卡片内容,支持字符串或组件型.
614
643
 
615
644
  - placement (a value equal to: 'top', 'left', 'right', 'bottom', 'topLeft', 'topRight', 'bottomLeft', 'bottomRight', 'leftTop', 'leftBottom', 'rightTop', 'rightBottom'; optional):
616
645
  气泡卡片弹出方位,可选项有`'top'`、`'left'`、`'right'`、`'bottom'`、`'topLeft'`、`'topRight'`、`'bottomLeft'`、`'bottomRight'`、`'leftTop'`、`'leftBottom'`、`'rightTop'`、`'rightBottom'`
@@ -1015,7 +1044,7 @@ Keyword arguments:
1015
1044
 
1016
1045
  - aria-* (string; optional):
1017
1046
  `aria-*`格式属性通配."""
1018
- _children_props = ['columns[].title', 'data[]{}', 'summaryRowContents[].content', 'expandedRowKeyToContent[].content', 'emptyContent', 'title', 'footer']
1047
+ _children_props = ['columns[].title', 'data[]{}', 'titlePopoverInfo[].title', 'titlePopoverInfo[].content', 'summaryRowContents[].content', 'expandedRowKeyToContent[].content', 'emptyContent', 'title', 'footer']
1019
1048
  _base_nodes = ['emptyContent', 'title', 'footer', 'children']
1020
1049
  _namespace = 'feffery_antd_components'
1021
1050
  _type = 'AntdTable'
@@ -1133,24 +1162,25 @@ Keyword arguments:
1133
1162
  "value": NotRequired[typing.Union[typing.Union[str, NumberType], typing.Sequence[typing.Union[str, NumberType]]]],
1134
1163
  "maxTagCount": NotRequired[typing.Union[NumberType, Literal["responsive"]]],
1135
1164
  "optionFilterProp": NotRequired[Literal["value", "label"]],
1136
- "allowClear": NotRequired[bool]
1165
+ "allowClear": NotRequired[bool],
1166
+ "showSearch": NotRequired[bool]
1137
1167
  }
1138
1168
  )
1139
1169
 
1140
- DataPopConfirmProps = TypedDict(
1141
- "DataPopConfirmProps",
1170
+ DataTooltip = TypedDict(
1171
+ "DataTooltip",
1142
1172
  {
1143
1173
  "title": NotRequired[str],
1144
- "okText": NotRequired[str],
1145
- "cancelText": NotRequired[str]
1174
+ "placement": NotRequired[Literal["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight"]]
1146
1175
  }
1147
1176
  )
1148
1177
 
1149
- DataTooltip = TypedDict(
1150
- "DataTooltip",
1178
+ DataPopConfirmProps = TypedDict(
1179
+ "DataPopConfirmProps",
1151
1180
  {
1152
1181
  "title": NotRequired[str],
1153
- "placement": NotRequired[Literal["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight"]]
1182
+ "okText": NotRequired[str],
1183
+ "cancelText": NotRequired[str]
1154
1184
  }
1155
1185
  )
1156
1186
 
@@ -1186,8 +1216,9 @@ Keyword arguments:
1186
1216
  TitlePopoverInfo = TypedDict(
1187
1217
  "TitlePopoverInfo",
1188
1218
  {
1189
- "title": NotRequired[str],
1190
- "content": NotRequired[str],
1219
+ "dataIndex": str,
1220
+ "title": NotRequired[ComponentType],
1221
+ "content": NotRequired[ComponentType],
1191
1222
  "placement": NotRequired[Literal["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight", "leftTop", "leftBottom", "rightTop", "rightBottom"]],
1192
1223
  "overlayStyle": NotRequired[dict]
1193
1224
  }
@@ -1345,7 +1376,7 @@ Keyword arguments:
1345
1376
  recentlyMouseEnterColumnDataIndex: typing.Optional[str] = None,
1346
1377
  recentlyMouseEnterRowKey: typing.Optional[typing.Union[str, NumberType]] = None,
1347
1378
  recentlyMouseEnterRow: typing.Optional[dict] = None,
1348
- titlePopoverInfo: typing.Optional[typing.Dict[typing.Union[str, float, int], "TitlePopoverInfo"]] = None,
1379
+ titlePopoverInfo: typing.Optional[typing.Sequence["TitlePopoverInfo"]] = None,
1349
1380
  columnsFormatConstraint: typing.Optional[typing.Dict[typing.Union[str, float, int], "ColumnsFormatConstraint"]] = None,
1350
1381
  sortOptions: typing.Optional["SortOptions"] = None,
1351
1382
  showSorterTooltip: typing.Optional[bool] = None,