feffery_antd_components 0.1.16 → 0.2.0-rc0
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.
- package/DESCRIPTION +1 -1
- package/NAMESPACE +1 -0
- package/Project.toml +1 -1
- package/README-en_US.md +51 -0
- package/README.md +14 -5
- package/feffery_antd_components/AntdAlert.py +1 -1
- package/feffery_antd_components/AntdAnchor.py +1 -1
- package/feffery_antd_components/AntdAvatar.py +1 -1
- package/feffery_antd_components/AntdBackTop.py +1 -1
- package/feffery_antd_components/AntdButton.py +10 -6
- package/feffery_antd_components/AntdCarousel.py +1 -1
- package/feffery_antd_components/AntdCascader.py +9 -5
- package/feffery_antd_components/AntdCol.py +1 -1
- package/feffery_antd_components/AntdContent.py +1 -1
- package/feffery_antd_components/AntdCustomSkeleton.py +1 -1
- package/feffery_antd_components/AntdDraggerUpload.py +1 -1
- package/feffery_antd_components/AntdDrawer.py +1 -1
- package/feffery_antd_components/AntdFooter.py +1 -1
- package/feffery_antd_components/AntdHeader.py +1 -1
- package/feffery_antd_components/AntdIcon.py +8 -4
- package/feffery_antd_components/AntdImage.py +1 -1
- package/feffery_antd_components/AntdInput.py +16 -8
- package/feffery_antd_components/AntdInputNumber.py +11 -7
- package/feffery_antd_components/AntdLayout.py +1 -1
- package/feffery_antd_components/AntdModal.py +10 -4
- package/feffery_antd_components/AntdParagraph.py +1 -1
- package/feffery_antd_components/AntdPasteImage.py +1 -1
- package/feffery_antd_components/AntdPopupCard.py +72 -0
- package/feffery_antd_components/AntdRibbon.py +3 -3
- package/feffery_antd_components/AntdRow.py +1 -1
- package/feffery_antd_components/AntdSegmented.py +5 -3
- package/feffery_antd_components/AntdSegmentedColoring.py +7 -3
- package/feffery_antd_components/AntdSider.py +1 -1
- package/feffery_antd_components/AntdSkeleton.py +1 -1
- package/feffery_antd_components/AntdSpace.py +1 -1
- package/feffery_antd_components/AntdSpin.py +2 -2
- package/feffery_antd_components/AntdStatistic.py +1 -1
- package/feffery_antd_components/AntdTabPane.py +1 -1
- package/feffery_antd_components/AntdTable.py +55 -7
- package/feffery_antd_components/AntdTag.py +1 -1
- package/feffery_antd_components/AntdText.py +1 -1
- package/feffery_antd_components/AntdTitle.py +1 -1
- package/feffery_antd_components/AntdTree.py +6 -4
- package/feffery_antd_components/AntdTreeSelect.py +8 -6
- package/feffery_antd_components/_imports_.py +2 -0
- package/feffery_antd_components/feffery_antd_components.min.js +1 -1
- package/feffery_antd_components/metadata.json +1042 -93
- package/feffery_antd_components/package-info.json +6 -2
- package/git-operations.md +0 -1
- package/images//345/233/275/351/231/205/345/214/226/347/244/272/344/276/213.png +0 -0
- package/package.json +6 -2
- package/setup.py +0 -1
- package/src/FefferyAntdComponents.jl +4 -3
- package/src/jl/'feffery'_antdalert.jl +1 -1
- package/src/jl/'feffery'_antdanchor.jl +1 -1
- package/src/jl/'feffery'_antdavatar.jl +1 -1
- package/src/jl/'feffery'_antdbacktop.jl +1 -1
- package/src/jl/'feffery'_antdbutton.jl +4 -2
- package/src/jl/'feffery'_antdcarousel.jl +1 -1
- package/src/jl/'feffery'_antdcascader.jl +4 -2
- package/src/jl/'feffery'_antdcol.jl +1 -1
- package/src/jl/'feffery'_antdcontent.jl +1 -1
- package/src/jl/'feffery'_antdcustomskeleton.jl +1 -1
- package/src/jl/'feffery'_antddraggerupload.jl +1 -1
- package/src/jl/'feffery'_antddrawer.jl +1 -1
- package/src/jl/'feffery'_antdfooter.jl +1 -1
- package/src/jl/'feffery'_antdheader.jl +1 -1
- package/src/jl/'feffery'_antdicon.jl +4 -2
- package/src/jl/'feffery'_antdimage.jl +1 -1
- package/src/jl/'feffery'_antdinput.jl +8 -4
- package/src/jl/'feffery'_antdinputnumber.jl +5 -3
- package/src/jl/'feffery'_antdlayout.jl +1 -1
- package/src/jl/'feffery'_antdmodal.jl +5 -2
- package/src/jl/'feffery'_antdparagraph.jl +1 -1
- package/src/jl/'feffery'_antdpasteimage.jl +1 -1
- package/src/jl/'feffery'_antdpopupcard.jl +43 -0
- package/src/jl/'feffery'_antdribbon.jl +1 -1
- package/src/jl/'feffery'_antdrow.jl +1 -1
- package/src/jl/'feffery'_antdsegmented.jl +5 -4
- package/src/jl/'feffery'_antdsegmentedcoloring.jl +3 -1
- package/src/jl/'feffery'_antdsider.jl +1 -1
- package/src/jl/'feffery'_antdskeleton.jl +1 -1
- package/src/jl/'feffery'_antdspace.jl +1 -1
- package/src/jl/'feffery'_antdspin.jl +2 -2
- package/src/jl/'feffery'_antdstatistic.jl +1 -1
- package/src/jl/'feffery'_antdtable.jl +31 -4
- package/src/jl/'feffery'_antdtabpane.jl +1 -1
- package/src/jl/'feffery'_antdtag.jl +1 -1
- package/src/jl/'feffery'_antdtext.jl +1 -1
- package/src/jl/'feffery'_antdtitle.jl +1 -1
- package/src/jl/'feffery'_antdtree.jl +3 -2
- package/src/jl/'feffery'_antdtreeselect.jl +3 -2
- package/src/lib/components/AntdAlert.react.js +16 -3
- package/src/lib/components/AntdAnchor.react.js +79 -70
- package/src/lib/components/AntdAvatar.react.js +21 -4
- package/src/lib/components/AntdBackTop.react.js +11 -2
- package/src/lib/components/AntdButton.react.js +82 -54
- package/src/lib/components/AntdCarousel.react.js +11 -2
- package/src/lib/components/AntdCascader.react.js +128 -82
- package/src/lib/components/AntdCheckboxGroup.react.js +2 -0
- package/src/lib/components/AntdDrawer.react.js +11 -2
- package/src/lib/components/AntdIcon.react.js +70 -37
- package/src/lib/components/AntdImage.react.js +16 -3
- package/src/lib/components/AntdInput.react.js +212 -175
- package/src/lib/components/AntdInputNumber.react.js +12 -2
- package/src/lib/components/AntdModal.react.js +22 -1
- package/src/lib/components/AntdPasteImage.react.js +11 -2
- package/src/lib/components/AntdPopupCard.react.js +241 -0
- package/src/lib/components/AntdRibbon.react.js +1 -1
- package/src/lib/components/AntdSegmented.react.js +19 -4
- package/src/lib/components/AntdSegmentedColoring.react.js +107 -82
- package/src/lib/components/AntdSelect.react.js +5 -0
- package/src/lib/components/AntdSpace.react.js +21 -4
- package/src/lib/components/AntdSpin.react.js +21 -6
- package/src/lib/components/AntdStatistic.react.js +11 -2
- package/src/lib/components/AntdTable.react.js +252 -18
- package/src/lib/components/AntdTag.react.js +12 -2
- package/src/lib/components/AntdTree.react.js +182 -136
- package/src/lib/components/AntdTreeSelect.react.js +144 -101
- package/src/lib/components/grid/AntdCol.react.js +11 -2
- package/src/lib/components/grid/AntdRow.react.js +12 -3
- package/src/lib/components/layout/AntdContent.react.js +11 -2
- package/src/lib/components/layout/AntdFooter.react.js +11 -2
- package/src/lib/components/layout/AntdHeader.react.js +11 -2
- package/src/lib/components/layout/AntdLayout.react.js +11 -2
- package/src/lib/components/layout/AntdSider.react.js +11 -2
- package/src/lib/components/skeleton/AntdCustomSkeleton.react.js +11 -3
- package/src/lib/components/skeleton/AntdSkeleton.react.js +11 -2
- package/src/lib/components/styles.css +4 -0
- package/src/lib/components/tabs/AntdTabPane.react.js +11 -2
- package/src/lib/components/typography/AntdParagraph.react.js +11 -2
- package/src/lib/components/typography/AntdText.react.js +11 -2
- package/src/lib/components/typography/AntdTitle.react.js +11 -2
- package/src/lib/components/upload/AntdDraggerUpload.react.js +11 -2
- package/src/lib/components/utils.js +17 -2
- package/src/lib/index.js +24 -1
- package/tests/DebounceTest/app.py +89 -0
- package/tests/SegmentedColoringTest/app.py +106 -0
- package/tests/TableCellClickTest/app.py +67 -0
- package/tests/TableCellRowMergeTest/app.py +88 -0
- package/tests/TableEmptyContentTest/app.py +37 -0
- package/tests/TableMiniChartAdvanceTest/app.py +85 -0
- package/tests/TreeNodeStyleTest/app.py +73 -0
- package/tests/TreeTest/app.py +96 -0
- package/tests/VirtualClassNameTest/app.py +49 -0
- package/usage.py +125 -62
- package/webpack.config.js +45 -11
- package/tests/UploadTest/app.py +0 -70
|
@@ -10,15 +10,16 @@ An AntdTable component.
|
|
|
10
10
|
Keyword arguments:
|
|
11
11
|
- `id` (String; optional)
|
|
12
12
|
- `bordered` (Bool; optional)
|
|
13
|
+
- `checkedDataIndex` (String; optional)
|
|
13
14
|
- `className` (String; optional)
|
|
14
15
|
- `clickedContent` (String; optional)
|
|
15
16
|
- `columns` (optional): . columns has the following type: Array of lists containing elements 'title', 'dataIndex', 'renderOptions', 'fixed', 'editable', 'align', 'width', 'ellipsis', 'sorter', 'render', 'onCell', 'title_'.
|
|
16
17
|
Those elements have the following types:
|
|
17
18
|
- `title` (String; required)
|
|
18
19
|
- `dataIndex` (String; required)
|
|
19
|
-
- `renderOptions` (optional): . renderOptions has the following type: lists containing elements 'renderType', 'renderLinkText', 'renderButtonPopConfirmProps', 'tooltipCustomContent'.
|
|
20
|
+
- `renderOptions` (optional): . renderOptions has the following type: lists containing elements 'renderType', 'renderLinkText', 'renderButtonPopConfirmProps', 'tooltipCustomContent', 'progressOneHundredPercentColor', 'ringProgressFontSize'.
|
|
20
21
|
Those elements have the following types:
|
|
21
|
-
- `renderType` (a value equal to: 'link', 'ellipsis', 'mini-line', 'mini-bar', 'mini-progress', 'mini-ring-progress', 'mini-area', 'tags', 'button', 'copyable', 'status-badge', 'image', 'custom-format', 'ellipsis-copyable', 'corner-mark'; optional)
|
|
22
|
+
- `renderType` (a value equal to: 'link', 'ellipsis', 'mini-line', 'mini-bar', 'mini-progress', 'mini-ring-progress', 'mini-area', 'tags', 'button', 'copyable', 'status-badge', 'image', 'custom-format', 'ellipsis-copyable', 'corner-mark', 'checkbox', 'switch', 'row-merge'; optional)
|
|
22
23
|
- `renderLinkText` (String; optional)
|
|
23
24
|
- `renderButtonPopConfirmProps` (optional): . renderButtonPopConfirmProps has the following type: lists containing elements 'title', 'okText', 'cancelText'.
|
|
24
25
|
Those elements have the following types:
|
|
@@ -26,6 +27,8 @@ Those elements have the following types:
|
|
|
26
27
|
- `okText` (String; optional)
|
|
27
28
|
- `cancelText` (String; optional)
|
|
28
29
|
- `tooltipCustomContent` (String; optional)
|
|
30
|
+
- `progressOneHundredPercentColor` (String; optional)
|
|
31
|
+
- `ringProgressFontSize` (Real; optional)
|
|
29
32
|
- `fixed` (a value equal to: 'left', 'right'; optional)
|
|
30
33
|
- `editable` (Bool; optional)
|
|
31
34
|
- `align` (a value equal to: 'left', 'center', 'right'; optional)
|
|
@@ -79,7 +82,22 @@ Those elements have the following types:
|
|
|
79
82
|
- `content` (Real | String; optional)
|
|
80
83
|
- `offsetX` (Real; optional)
|
|
81
84
|
- `offsetY` (Real; optional)
|
|
82
|
-
- `hide` (Bool; optional)
|
|
85
|
+
- `hide` (Bool; optional) | lists containing elements 'checked', 'disabled', 'label'.
|
|
86
|
+
Those elements have the following types:
|
|
87
|
+
- `checked` (Bool; optional)
|
|
88
|
+
- `disabled` (Bool; optional)
|
|
89
|
+
- `label` (String; optional) | lists containing elements 'checked', 'disabled', 'label', 'checkedChildren', 'unCheckedChildren'.
|
|
90
|
+
Those elements have the following types:
|
|
91
|
+
- `checked` (Bool; optional)
|
|
92
|
+
- `disabled` (Bool; optional)
|
|
93
|
+
- `label` (String; optional)
|
|
94
|
+
- `checkedChildren` (String; optional)
|
|
95
|
+
- `unCheckedChildren` (String; optional) | lists containing elements 'content', 'rowSpan'.
|
|
96
|
+
Those elements have the following types:
|
|
97
|
+
- `content` (Real | String; optional)
|
|
98
|
+
- `rowSpan` (Real; optional)s
|
|
99
|
+
- `emptyContent` (a list of or a singular dash component, string or number; optional)
|
|
100
|
+
- `enableCellClickListenColumns` (Bool; optional)
|
|
83
101
|
- `enableHoverListen` (Bool; optional)
|
|
84
102
|
- `expandRowByClick` (Bool; optional)
|
|
85
103
|
- `expandedRowKeyToContent` (optional): . expandedRowKeyToContent has the following type: Array of lists containing elements 'key', 'content'.
|
|
@@ -107,6 +125,7 @@ Those elements have the following types:
|
|
|
107
125
|
- `miniChartHeight` (Real; optional)
|
|
108
126
|
- `mode` (a value equal to: 'client-side', 'server-side'; optional)
|
|
109
127
|
- `nClicksButton` (Real; optional)
|
|
128
|
+
- `nClicksCell` (Real; optional)
|
|
110
129
|
- `pagination` (optional): . pagination has the following type: Bool | lists containing elements 'position', 'pageSize', 'current', 'showSizeChanger', 'pageSizeOptions', 'showTitle', 'showQuickJumper', 'showTotalPrefix', 'showTotalSuffix', 'total', 'hideOnSinglePage', 'simple', 'disabled', 'responsive', 'size'.
|
|
111
130
|
Those elements have the following types:
|
|
112
131
|
- `position` (a value equal to: 'topLeft', 'topCenter', 'topRight', 'bottomLeft', 'bottomCenter', 'bottomRight'; optional)
|
|
@@ -125,9 +144,16 @@ Those elements have the following types:
|
|
|
125
144
|
- `responsive` (Bool; optional)
|
|
126
145
|
- `size` (a value equal to: 'default', 'small'; optional)
|
|
127
146
|
- `recentlyButtonClickedRow` (Dict; optional)
|
|
147
|
+
- `recentlyCellClickColumn` (String; optional)
|
|
148
|
+
- `recentlyCellClickRecord` (String | Real; optional)
|
|
128
149
|
- `recentlyChangedRow` (Dict; optional)
|
|
150
|
+
- `recentlyCheckedLabel` (String; optional)
|
|
151
|
+
- `recentlyCheckedRow` (Dict; optional)
|
|
152
|
+
- `recentlyCheckedStatus` (Bool; optional)
|
|
129
153
|
- `recentlyMouseEnterColumn` (String; optional)
|
|
130
154
|
- `recentlyMouseEnterRow` (String | Real; optional)
|
|
155
|
+
- `recentlySwtichRow` (Dict; optional)
|
|
156
|
+
- `recentlySwtichStatus` (Bool; optional)
|
|
131
157
|
- `rowSelectionType` (a value equal to: 'checkbox', 'radio'; optional)
|
|
132
158
|
- `rowSelectionWidth` (String | Real; optional)
|
|
133
159
|
- `selectedRowKeys` (Array of String | Reals; optional)
|
|
@@ -151,10 +177,11 @@ Those elements have the following types:
|
|
|
151
177
|
- `colSpan` (Real; optional)
|
|
152
178
|
- `align` (a value equal to: 'left', 'center', 'right'; optional)s
|
|
153
179
|
- `summaryRowFixed` (Bool; optional)
|
|
180
|
+
- `swtichDataIndex` (String; optional)
|
|
154
181
|
- `titlePopoverInfo` (Dict; optional)
|
|
155
182
|
"""
|
|
156
183
|
function 'feffery'_antdtable(; kwargs...)
|
|
157
|
-
available_props = Symbol[:id, :bordered, :className, :clickedContent, :columns, :columnsFormatConstraint, :conditionalStyleFuncs, :containerId, :currentData, :customFormatFuncs, :data, :enableHoverListen, :expandRowByClick, :expandedRowKeyToContent, :expandedRowWidth, :filter, :filterOptions, :key, :loading_state, :locale, :maxHeight, :maxWidth, :miniChartAnimation, :miniChartHeight, :mode, :nClicksButton, :pagination, :recentlyButtonClickedRow, :recentlyChangedRow, :recentlyMouseEnterColumn, :recentlyMouseEnterRow, :rowSelectionType, :rowSelectionWidth, :selectedRowKeys, :selectedRows, :size, :sortOptions, :sorter, :sticky, :style, :summaryRowContents, :summaryRowFixed, :titlePopoverInfo]
|
|
184
|
+
available_props = Symbol[:id, :bordered, :checkedDataIndex, :className, :clickedContent, :columns, :columnsFormatConstraint, :conditionalStyleFuncs, :containerId, :currentData, :customFormatFuncs, :data, :emptyContent, :enableCellClickListenColumns, :enableHoverListen, :expandRowByClick, :expandedRowKeyToContent, :expandedRowWidth, :filter, :filterOptions, :key, :loading_state, :locale, :maxHeight, :maxWidth, :miniChartAnimation, :miniChartHeight, :mode, :nClicksButton, :nClicksCell, :pagination, :recentlyButtonClickedRow, :recentlyCellClickColumn, :recentlyCellClickRecord, :recentlyChangedRow, :recentlyCheckedLabel, :recentlyCheckedRow, :recentlyCheckedStatus, :recentlyMouseEnterColumn, :recentlyMouseEnterRow, :recentlySwtichRow, :recentlySwtichStatus, :rowSelectionType, :rowSelectionWidth, :selectedRowKeys, :selectedRows, :size, :sortOptions, :sorter, :sticky, :style, :summaryRowContents, :summaryRowFixed, :swtichDataIndex, :titlePopoverInfo]
|
|
158
185
|
wild_props = Symbol[]
|
|
159
186
|
return Component("'feffery'_antdtable", "AntdTable", "feffery_antd_components", available_props, wild_props; kwargs...)
|
|
160
187
|
end
|
|
@@ -13,7 +13,7 @@ An AntdTabPane component.
|
|
|
13
13
|
Keyword arguments:
|
|
14
14
|
- `children` (a list of or a singular dash component, string or number; optional): The content of the tab - will only be displayed if this tab is selected
|
|
15
15
|
- `id` (String; optional)
|
|
16
|
-
- `className` (String; optional)
|
|
16
|
+
- `className` (String | Dict; optional)
|
|
17
17
|
- `closable` (Bool; optional)
|
|
18
18
|
- `disabled` (Bool; optional)
|
|
19
19
|
- `key` (String; optional)
|
|
@@ -13,7 +13,7 @@ An AntdText component.
|
|
|
13
13
|
Keyword arguments:
|
|
14
14
|
- `children` (a list of or a singular dash component, string or number; optional): The content of the tab - will only be displayed if this tab is selected
|
|
15
15
|
- `id` (String; optional)
|
|
16
|
-
- `className` (String; optional)
|
|
16
|
+
- `className` (String | Dict; optional)
|
|
17
17
|
- `code` (Bool; optional)
|
|
18
18
|
- `copyable` (Bool; optional)
|
|
19
19
|
- `disabled` (Bool; optional)
|
|
@@ -13,7 +13,7 @@ An AntdTitle component.
|
|
|
13
13
|
Keyword arguments:
|
|
14
14
|
- `children` (a list of or a singular dash component, string or number; optional): The content of the tab - will only be displayed if this tab is selected
|
|
15
15
|
- `id` (String; optional)
|
|
16
|
-
- `className` (String; optional)
|
|
16
|
+
- `className` (String | Dict; optional)
|
|
17
17
|
- `code` (Bool; optional)
|
|
18
18
|
- `copyable` (Bool; optional)
|
|
19
19
|
- `disabled` (Bool; optional)
|
|
@@ -48,10 +48,11 @@ session: window.sessionStorage, data is cleared once the browser quit.
|
|
|
48
48
|
Those elements have the following types:
|
|
49
49
|
- `showLeafIcon` (Bool; optional)
|
|
50
50
|
- `style` (Dict; optional)
|
|
51
|
-
- `treeData` (optional)
|
|
51
|
+
- `treeData` (Array; optional)
|
|
52
|
+
- `treeDataMode` (a value equal to: 'tree', 'flat'; optional)
|
|
52
53
|
"""
|
|
53
54
|
function 'feffery'_antdtree(; kwargs...)
|
|
54
|
-
available_props = Symbol[:id, :checkStrictly, :checkable, :checkedKeys, :className, :defaultCheckedKeys, :defaultExpandAll, :defaultExpandParent, :defaultExpandedKeys, :defaultSelectedKeys, :expandedKeys, :halfCheckedKeys, :height, :key, :loading_state, :multiple, :persisted_props, :persistence, :persistence_type, :selectable, :selectedKeys, :showIcon, :showLine, :style, :treeData]
|
|
55
|
+
available_props = Symbol[:id, :checkStrictly, :checkable, :checkedKeys, :className, :defaultCheckedKeys, :defaultExpandAll, :defaultExpandParent, :defaultExpandedKeys, :defaultSelectedKeys, :expandedKeys, :halfCheckedKeys, :height, :key, :loading_state, :multiple, :persisted_props, :persistence, :persistence_type, :selectable, :selectedKeys, :showIcon, :showLine, :style, :treeData, :treeDataMode]
|
|
55
56
|
wild_props = Symbol[]
|
|
56
57
|
return Component("'feffery'_antdtree", "AntdTree", "feffery_antd_components", available_props, wild_props; kwargs...)
|
|
57
58
|
end
|
|
@@ -44,7 +44,8 @@ session: window.sessionStorage, data is cleared once the browser quit.
|
|
|
44
44
|
- `style` (Dict; optional)
|
|
45
45
|
- `treeCheckStrictly` (Bool; optional)
|
|
46
46
|
- `treeCheckable` (Bool; optional)
|
|
47
|
-
- `treeData` (
|
|
47
|
+
- `treeData` (Array; required)
|
|
48
|
+
- `treeDataMode` (a value equal to: 'tree', 'flat'; optional)
|
|
48
49
|
- `treeDefaultExpandAll` (Bool; optional)
|
|
49
50
|
- `treeDefaultExpandedKeys` (Array of Strings; optional)
|
|
50
51
|
- `treeExpandedKeys` (Array of Strings; optional)
|
|
@@ -54,7 +55,7 @@ session: window.sessionStorage, data is cleared once the browser quit.
|
|
|
54
55
|
- `virtual` (Bool; optional)
|
|
55
56
|
"""
|
|
56
57
|
function 'feffery'_antdtreeselect(; kwargs...)
|
|
57
|
-
available_props = Symbol[:id, :allowClear, :bordered, :className, :defaultValue, :disabled, :key, :listHeight, :loading_state, :locale, :maxTagCount, :multiple, :persisted_props, :persistence, :persistence_type, :placeholder, :placement, :size, :status, :style, :treeCheckStrictly, :treeCheckable, :treeData, :treeDefaultExpandAll, :treeDefaultExpandedKeys, :treeExpandedKeys, :treeLine, :treeNodeFilterProp, :value, :virtual]
|
|
58
|
+
available_props = Symbol[:id, :allowClear, :bordered, :className, :defaultValue, :disabled, :key, :listHeight, :loading_state, :locale, :maxTagCount, :multiple, :persisted_props, :persistence, :persistence_type, :placeholder, :placement, :size, :status, :style, :treeCheckStrictly, :treeCheckable, :treeData, :treeDataMode, :treeDefaultExpandAll, :treeDefaultExpandedKeys, :treeExpandedKeys, :treeLine, :treeNodeFilterProp, :value, :virtual]
|
|
58
59
|
wild_props = Symbol[]
|
|
59
60
|
return Component("'feffery'_antdtreeselect", "AntdTreeSelect", "feffery_antd_components", available_props, wild_props; kwargs...)
|
|
60
61
|
end
|
|
@@ -2,6 +2,8 @@ import React, { Component } from 'react';
|
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
3
|
import TextLoop from 'react-text-loop'
|
|
4
4
|
import { Alert } from 'antd';
|
|
5
|
+
import { useCss } from 'react-use';
|
|
6
|
+
import { isString } from 'lodash';
|
|
5
7
|
import Marquee from 'react-fast-marquee';
|
|
6
8
|
import 'antd/dist/antd.css';
|
|
7
9
|
|
|
@@ -28,7 +30,11 @@ export default class AntdAlert extends Component {
|
|
|
28
30
|
if (messageRenderMode === 'loop-text' && Array.isArray(message)) {
|
|
29
31
|
return (
|
|
30
32
|
<Alert id={id}
|
|
31
|
-
className={
|
|
33
|
+
className={
|
|
34
|
+
isString(className) ?
|
|
35
|
+
className :
|
|
36
|
+
useCss(className)
|
|
37
|
+
}
|
|
32
38
|
style={style}
|
|
33
39
|
key={key}
|
|
34
40
|
message={
|
|
@@ -50,7 +56,11 @@ export default class AntdAlert extends Component {
|
|
|
50
56
|
|
|
51
57
|
return (
|
|
52
58
|
<Alert id={id}
|
|
53
|
-
className={
|
|
59
|
+
className={
|
|
60
|
+
isString(className) ?
|
|
61
|
+
className :
|
|
62
|
+
useCss(className)
|
|
63
|
+
}
|
|
54
64
|
style={style}
|
|
55
65
|
key={key}
|
|
56
66
|
message={
|
|
@@ -77,7 +87,10 @@ AntdAlert.propTypes = {
|
|
|
77
87
|
id: PropTypes.string,
|
|
78
88
|
|
|
79
89
|
// css类名
|
|
80
|
-
className: PropTypes.
|
|
90
|
+
className: PropTypes.oneOfType([
|
|
91
|
+
PropTypes.string,
|
|
92
|
+
PropTypes.object
|
|
93
|
+
]),
|
|
81
94
|
|
|
82
95
|
// 自定义css字典
|
|
83
96
|
style: PropTypes.object,
|
|
@@ -1,86 +1,89 @@
|
|
|
1
|
-
import React
|
|
1
|
+
import React from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
|
+
import { useCss } from 'react-use';
|
|
4
|
+
import { isString } from 'lodash';
|
|
3
5
|
import { Anchor } from 'antd';
|
|
4
6
|
import 'antd/dist/antd.css';
|
|
5
7
|
|
|
6
8
|
const { Link } = Anchor;
|
|
7
9
|
|
|
8
10
|
// 定义锚点组件AntdAnchor,api参数参考https://ant.design/components/anchor-cn/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
if (obj.hasOwnProperty('
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
obj
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
{renderAnchorTree(obj.children)}
|
|
39
|
-
</Link>
|
|
40
|
-
|
|
41
|
-
} else {
|
|
42
|
-
|
|
43
|
-
obj = <Link
|
|
44
|
-
href={obj.href}
|
|
45
|
-
title={obj.title}
|
|
46
|
-
/>
|
|
47
|
-
}
|
|
11
|
+
const AntdAnchor = (props) => {
|
|
12
|
+
// 取得必要属性或参数
|
|
13
|
+
let {
|
|
14
|
+
id,
|
|
15
|
+
className,
|
|
16
|
+
style,
|
|
17
|
+
key,
|
|
18
|
+
linkDict,
|
|
19
|
+
align,
|
|
20
|
+
containerId,
|
|
21
|
+
targetOffset,
|
|
22
|
+
affix,
|
|
23
|
+
bounds,
|
|
24
|
+
offsetTop,
|
|
25
|
+
loading_state
|
|
26
|
+
} = props;
|
|
27
|
+
|
|
28
|
+
const renderAnchorTree = (obj) => {
|
|
29
|
+
// 当anchorObj类型为对象时
|
|
30
|
+
if (obj.hasOwnProperty('href')) {
|
|
31
|
+
//当anchorObj具有children属性时
|
|
32
|
+
if (obj.hasOwnProperty('children')) {
|
|
33
|
+
|
|
34
|
+
obj = <Link
|
|
35
|
+
href={obj.href}
|
|
36
|
+
title={obj.title}
|
|
37
|
+
>
|
|
38
|
+
{renderAnchorTree(obj.children)}
|
|
39
|
+
</Link>
|
|
48
40
|
|
|
49
41
|
} else {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
42
|
+
|
|
43
|
+
obj = <Link
|
|
44
|
+
href={obj.href}
|
|
45
|
+
title={obj.title}
|
|
46
|
+
/>
|
|
53
47
|
}
|
|
54
48
|
|
|
55
|
-
|
|
49
|
+
} else {
|
|
50
|
+
for (let i = 0; i < obj.length; i++) {
|
|
51
|
+
obj[i] = renderAnchorTree(obj[i])
|
|
52
|
+
}
|
|
56
53
|
}
|
|
57
54
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
return (
|
|
61
|
-
<div
|
|
62
|
-
style={{ float: align }}
|
|
63
|
-
data-dash-is-loading={
|
|
64
|
-
(loading_state && loading_state.is_loading) || undefined
|
|
65
|
-
}
|
|
66
|
-
>
|
|
67
|
-
{
|
|
68
|
-
<Anchor
|
|
69
|
-
id={id}
|
|
70
|
-
className={className}
|
|
71
|
-
style={style}
|
|
72
|
-
key={key}
|
|
73
|
-
getContainer={containerId ? () => document.getElementById(containerId) : containerId}
|
|
74
|
-
targetOffset={targetOffset}
|
|
75
|
-
affix={affix}
|
|
76
|
-
bounds={bounds}
|
|
77
|
-
offsetTop={offsetTop}>
|
|
78
|
-
{linkDict}
|
|
79
|
-
</Anchor>
|
|
80
|
-
}
|
|
81
|
-
</div>
|
|
82
|
-
);
|
|
55
|
+
return obj;
|
|
83
56
|
}
|
|
57
|
+
|
|
58
|
+
return (
|
|
59
|
+
<div
|
|
60
|
+
style={{ float: align }}
|
|
61
|
+
data-dash-is-loading={
|
|
62
|
+
(loading_state && loading_state.is_loading) || undefined
|
|
63
|
+
}
|
|
64
|
+
>
|
|
65
|
+
{
|
|
66
|
+
<Anchor
|
|
67
|
+
id={id}
|
|
68
|
+
className={
|
|
69
|
+
isString(className) ?
|
|
70
|
+
className :
|
|
71
|
+
useCss(className)
|
|
72
|
+
}
|
|
73
|
+
style={style}
|
|
74
|
+
key={key}
|
|
75
|
+
getContainer={containerId ? (
|
|
76
|
+
document.getElementById(containerId) ? () => document.getElementById(containerId) : undefined
|
|
77
|
+
) : undefined}
|
|
78
|
+
targetOffset={targetOffset}
|
|
79
|
+
affix={affix}
|
|
80
|
+
bounds={bounds}
|
|
81
|
+
offsetTop={offsetTop}>
|
|
82
|
+
{renderAnchorTree(linkDict)}
|
|
83
|
+
</Anchor>
|
|
84
|
+
}
|
|
85
|
+
</div>
|
|
86
|
+
);
|
|
84
87
|
}
|
|
85
88
|
|
|
86
89
|
// 定义递归PropTypes
|
|
@@ -102,7 +105,10 @@ AntdAnchor.propTypes = {
|
|
|
102
105
|
id: PropTypes.string,
|
|
103
106
|
|
|
104
107
|
// css类名
|
|
105
|
-
className: PropTypes.
|
|
108
|
+
className: PropTypes.oneOfType([
|
|
109
|
+
PropTypes.string,
|
|
110
|
+
PropTypes.object
|
|
111
|
+
]),
|
|
106
112
|
|
|
107
113
|
// 自定义css字典
|
|
108
114
|
style: PropTypes.object,
|
|
@@ -157,3 +163,6 @@ AntdAnchor.propTypes = {
|
|
|
157
163
|
AntdAnchor.defaultProps = {
|
|
158
164
|
align: 'right'
|
|
159
165
|
}
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
export default AntdAnchor;
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
3
|
import { Avatar } from 'antd';
|
|
4
|
+
import { useCss } from 'react-use';
|
|
5
|
+
import { isString } from 'lodash';
|
|
4
6
|
import AntdIcon from './AntdIcon.react';
|
|
5
7
|
import 'antd/dist/antd.css';
|
|
6
8
|
|
|
@@ -31,7 +33,11 @@ export default class AntdAvatar extends Component {
|
|
|
31
33
|
return (
|
|
32
34
|
<Avatar
|
|
33
35
|
id={id}
|
|
34
|
-
className={
|
|
36
|
+
className={
|
|
37
|
+
isString(className) ?
|
|
38
|
+
className :
|
|
39
|
+
useCss(className)
|
|
40
|
+
}
|
|
35
41
|
style={style}
|
|
36
42
|
key={key}
|
|
37
43
|
src={src}
|
|
@@ -50,7 +56,11 @@ export default class AntdAvatar extends Component {
|
|
|
50
56
|
return (
|
|
51
57
|
<Avatar
|
|
52
58
|
id={id}
|
|
53
|
-
className={
|
|
59
|
+
className={
|
|
60
|
+
isString(className) ?
|
|
61
|
+
className :
|
|
62
|
+
useCss(className)
|
|
63
|
+
}
|
|
54
64
|
style={style}
|
|
55
65
|
key={key}
|
|
56
66
|
gap={gap}
|
|
@@ -66,7 +76,11 @@ export default class AntdAvatar extends Component {
|
|
|
66
76
|
return (
|
|
67
77
|
<Avatar
|
|
68
78
|
id={id}
|
|
69
|
-
className={
|
|
79
|
+
className={
|
|
80
|
+
isString(className) ?
|
|
81
|
+
className :
|
|
82
|
+
useCss(className)
|
|
83
|
+
}
|
|
70
84
|
style={style}
|
|
71
85
|
key={key}
|
|
72
86
|
icon={icon ? <AntdIcon icon={icon} /> : <AntdIcon icon={'antd-user'} />}
|
|
@@ -88,7 +102,10 @@ AntdAvatar.propTypes = {
|
|
|
88
102
|
id: PropTypes.string,
|
|
89
103
|
|
|
90
104
|
// css类名
|
|
91
|
-
className: PropTypes.
|
|
105
|
+
className: PropTypes.oneOfType([
|
|
106
|
+
PropTypes.string,
|
|
107
|
+
PropTypes.object
|
|
108
|
+
]),
|
|
92
109
|
|
|
93
110
|
// 自定义css字典
|
|
94
111
|
style: PropTypes.object,
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
|
+
import { useCss } from 'react-use';
|
|
4
|
+
import { isString } from 'lodash';
|
|
3
5
|
import { BackTop } from 'antd';
|
|
4
6
|
import 'antd/dist/antd.css';
|
|
5
7
|
|
|
@@ -21,7 +23,11 @@ export default class AntdBackTop extends Component {
|
|
|
21
23
|
|
|
22
24
|
return (
|
|
23
25
|
<BackTop id={id}
|
|
24
|
-
className={
|
|
26
|
+
className={
|
|
27
|
+
isString(className) ?
|
|
28
|
+
className :
|
|
29
|
+
useCss(className)
|
|
30
|
+
}
|
|
25
31
|
style={style}
|
|
26
32
|
key={key}
|
|
27
33
|
target={containerId ? () => document.getElementById(containerId) : () => window}
|
|
@@ -40,7 +46,10 @@ AntdBackTop.propTypes = {
|
|
|
40
46
|
id: PropTypes.string,
|
|
41
47
|
|
|
42
48
|
// css类名
|
|
43
|
-
className: PropTypes.
|
|
49
|
+
className: PropTypes.oneOfType([
|
|
50
|
+
PropTypes.string,
|
|
51
|
+
PropTypes.object
|
|
52
|
+
]),
|
|
44
53
|
|
|
45
54
|
// 自定义css字典
|
|
46
55
|
style: PropTypes.object,
|
|
@@ -1,60 +1,76 @@
|
|
|
1
|
-
import React, { Component } from 'react';
|
|
2
1
|
import PropTypes from 'prop-types';
|
|
3
2
|
import { Button } from 'antd';
|
|
3
|
+
import { useCss } from 'react-use';
|
|
4
|
+
import { isString } from 'lodash';
|
|
4
5
|
import 'antd/dist/antd.css';
|
|
6
|
+
import { useRequest } from 'ahooks';
|
|
5
7
|
|
|
6
8
|
// 定义分割线组件AntdButton,api参数参考https://ant.design/components/button-cn/
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
9
|
+
const AntdButton = (props) => {
|
|
10
|
+
// 取得必要属性或参数
|
|
11
|
+
let {
|
|
12
|
+
id,
|
|
13
|
+
children,
|
|
14
|
+
className,
|
|
15
|
+
style,
|
|
16
|
+
key,
|
|
17
|
+
setProps,
|
|
18
|
+
type,
|
|
19
|
+
href,
|
|
20
|
+
target,
|
|
21
|
+
block,
|
|
22
|
+
danger,
|
|
23
|
+
disabled,
|
|
24
|
+
shape,
|
|
25
|
+
size,
|
|
26
|
+
nClicks,
|
|
27
|
+
debounceWait,
|
|
28
|
+
icon,
|
|
29
|
+
loading,
|
|
30
|
+
loading_state
|
|
31
|
+
} = props;
|
|
32
|
+
|
|
33
|
+
const { run: onClick } = useRequest(
|
|
34
|
+
() => {
|
|
35
|
+
nClicks++;
|
|
36
|
+
// 更新nClicks
|
|
37
|
+
setProps({ nClicks: nClicks })
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
debounceWait: debounceWait,
|
|
41
|
+
debounceLeading: true,
|
|
42
|
+
manual: true
|
|
43
|
+
}
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
// 返回定制化的前端组件
|
|
47
|
+
return (
|
|
48
|
+
<Button
|
|
49
|
+
id={id}
|
|
50
|
+
className={
|
|
51
|
+
isString(className) ?
|
|
52
|
+
className :
|
|
53
|
+
useCss(className)
|
|
54
|
+
}
|
|
55
|
+
style={style}
|
|
56
|
+
key={key}
|
|
57
|
+
type={type}
|
|
58
|
+
href={href}
|
|
59
|
+
target={target}
|
|
60
|
+
block={block}
|
|
61
|
+
danger={danger}
|
|
62
|
+
disabled={disabled}
|
|
63
|
+
shape={shape}
|
|
64
|
+
size={size}
|
|
65
|
+
icon={icon}
|
|
66
|
+
onClick={onClick}
|
|
67
|
+
loading={loading}
|
|
68
|
+
data-dash-is-loading={
|
|
69
|
+
(loading_state && loading_state.is_loading) || undefined
|
|
70
|
+
}
|
|
71
|
+
>{children}
|
|
72
|
+
</Button>
|
|
73
|
+
);
|
|
58
74
|
}
|
|
59
75
|
|
|
60
76
|
// 定义参数或属性
|
|
@@ -66,7 +82,10 @@ AntdButton.propTypes = {
|
|
|
66
82
|
children: PropTypes.node,
|
|
67
83
|
|
|
68
84
|
// css类名
|
|
69
|
-
className: PropTypes.
|
|
85
|
+
className: PropTypes.oneOfType([
|
|
86
|
+
PropTypes.string,
|
|
87
|
+
PropTypes.object
|
|
88
|
+
]),
|
|
70
89
|
|
|
71
90
|
// 自定义css字典
|
|
72
91
|
style: PropTypes.object,
|
|
@@ -101,6 +120,12 @@ AntdButton.propTypes = {
|
|
|
101
120
|
// 记录按钮从渲染后开始被点击的次数,默认为0
|
|
102
121
|
nClicks: PropTypes.number,
|
|
103
122
|
|
|
123
|
+
// 用于配置value变化更新的防抖等待时长(单位:毫秒),默认为0
|
|
124
|
+
debounceWait: PropTypes.number,
|
|
125
|
+
|
|
126
|
+
// 组件型参数,设置按钮前缀图标元素
|
|
127
|
+
icon: PropTypes.node,
|
|
128
|
+
|
|
104
129
|
// 用于设置是否为按钮渲染“加载中不可点击”效果,默认为false
|
|
105
130
|
loading: PropTypes.bool,
|
|
106
131
|
|
|
@@ -132,5 +157,8 @@ AntdButton.defaultProps = {
|
|
|
132
157
|
block: false,
|
|
133
158
|
danger: false,
|
|
134
159
|
disabled: false,
|
|
135
|
-
nClicks: 0
|
|
160
|
+
nClicks: 0,
|
|
161
|
+
debounceWait: 0
|
|
136
162
|
}
|
|
163
|
+
|
|
164
|
+
export default AntdButton;
|