amis-ui 6.13.0-beta.7 → 6.13.0-beta.8
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/package.json +3 -3
- package/scss/components/form/_excel.scss +110 -4
- package/esm/components/404.d.ts +0 -53
- package/esm/components/404.js +0 -35
- package/esm/components/Alert.d.ts +0 -615
- package/esm/components/Alert.js +0 -266
- package/esm/components/Alert2.d.ts +0 -117
- package/esm/components/Alert2.js +0 -58
- package/esm/components/AlphabetIndexer.d.ts +0 -11
- package/esm/components/AlphabetIndexer.js +0 -48
- package/esm/components/AnchorNav.d.ts +0 -162
- package/esm/components/AnchorNav.js +0 -153
- package/esm/components/AnchorNavSection.d.ts +0 -2
- package/esm/components/AnchorNavSection.js +0 -7
- package/esm/components/ArrayInput.d.ts +0 -617
- package/esm/components/ArrayInput.js +0 -147
- package/esm/components/AsideNav.d.ts +0 -142
- package/esm/components/AsideNav.js +0 -133
- package/esm/components/AssociatedSelection.d.ts +0 -564
- package/esm/components/AssociatedSelection.js +0 -103
- package/esm/components/AutoSizer.d.ts +0 -2
- package/esm/components/AutoSizer.js +0 -8
- package/esm/components/Avatar.d.ts +0 -374
- package/esm/components/Avatar.js +0 -126
- package/esm/components/Badge.d.ts +0 -118
- package/esm/components/Badge.js +0 -154
- package/esm/components/BaiduMapPicker.d.ts +0 -100
- package/esm/components/BaiduMapPicker.js +0 -366
- package/esm/components/BarCode.d.ts +0 -56
- package/esm/components/BarCode.js +0 -42
- package/esm/components/Breadcrumb.d.ts +0 -115
- package/esm/components/Breadcrumb.js +0 -160
- package/esm/components/Button.d.ts +0 -147
- package/esm/components/Button.js +0 -63
- package/esm/components/CalendarMobile.d.ts +0 -431
- package/esm/components/CalendarMobile.js +0 -538
- package/esm/components/Card.d.ts +0 -444
- package/esm/components/Card.js +0 -88
- package/esm/components/Cascader.d.ts +0 -108
- package/esm/components/Cascader.js +0 -515
- package/esm/components/ChainedDropdownSelection.d.ts +0 -561
- package/esm/components/ChainedDropdownSelection.js +0 -104
- package/esm/components/ChainedSelection.d.ts +0 -554
- package/esm/components/ChainedSelection.js +0 -184
- package/esm/components/Checkbox.d.ts +0 -110
- package/esm/components/Checkbox.js +0 -87
- package/esm/components/CityArea.d.ts +0 -299
- package/esm/components/CityArea.js +0 -190
- package/esm/components/CityDB.d.ts +0 -13
- package/esm/components/CityDB.js +0 -3942
- package/esm/components/CodeMirror.d.ts +0 -29
- package/esm/components/CodeMirror.js +0 -140
- package/esm/components/Collapse.d.ts +0 -447
- package/esm/components/Collapse.js +0 -184
- package/esm/components/CollapseGroup.d.ts +0 -219
- package/esm/components/CollapseGroup.js +0 -117
- package/esm/components/ColorPicker.d.ts +0 -530
- package/esm/components/ColorPicker.js +0 -260
- package/esm/components/Combo.d.ts +0 -354
- package/esm/components/Combo.js +0 -212
- package/esm/components/ConditionBuilder.d.ts +0 -2
- package/esm/components/ConditionBuilder.js +0 -7
- package/esm/components/ConfirmBox.d.ts +0 -322
- package/esm/components/ConfirmBox.js +0 -129
- package/esm/components/ContextMenu.d.ts +0 -115
- package/esm/components/ContextMenu.js +0 -305
- package/esm/components/DatePicker.d.ts +0 -638
- package/esm/components/DatePicker.js +0 -717
- package/esm/components/DateRangePicker.d.ts +0 -1046
- package/esm/components/DateRangePicker.js +0 -1389
- package/esm/components/DiffEditor.d.ts +0 -21
- package/esm/components/DiffEditor.js +0 -119
- package/esm/components/DndContainer.d.ts +0 -205
- package/esm/components/DndContainer.js +0 -25
- package/esm/components/Drawer.d.ts +0 -158
- package/esm/components/Drawer.js +0 -269
- package/esm/components/DropDownSelection.d.ts +0 -557
- package/esm/components/DropDownSelection.js +0 -78
- package/esm/components/DropdownContextMenus.d.ts +0 -84
- package/esm/components/DropdownContextMenus.js +0 -93
- package/esm/components/Editor.d.ts +0 -681
- package/esm/components/Editor.js +0 -238
- package/esm/components/Form.d.ts +0 -31
- package/esm/components/Form.js +0 -84
- package/esm/components/FormField.d.ts +0 -287
- package/esm/components/FormField.js +0 -78
- package/esm/components/FormulaPicker.d.ts +0 -2
- package/esm/components/FormulaPicker.js +0 -7
- package/esm/components/GaodeMapPicker.d.ts +0 -89
- package/esm/components/GaodeMapPicker.js +0 -204
- package/esm/components/GridNav.d.ts +0 -53
- package/esm/components/GridNav.js +0 -125
- package/esm/components/GridNavItem.d.ts +0 -2
- package/esm/components/GridNavItem.js +0 -7
- package/esm/components/GroupedSelection.d.ts +0 -543
- package/esm/components/GroupedSelection.js +0 -138
- package/esm/components/HeadCellDropDown.d.ts +0 -2
- package/esm/components/HeadCellDropDown.js +0 -7
- package/esm/components/HorizontalScroll.d.ts +0 -75
- package/esm/components/HorizontalScroll.js +0 -271
- package/esm/components/Html.d.ts +0 -82
- package/esm/components/Html.js +0 -52
- package/esm/components/Icon.d.ts +0 -2
- package/esm/components/Icon.js +0 -7
- package/esm/components/ImageGallery.d.ts +0 -465
- package/esm/components/ImageGallery.js +0 -396
- package/esm/components/Input.d.ts +0 -18
- package/esm/components/Input.js +0 -75
- package/esm/components/InputBox.d.ts +0 -100
- package/esm/components/InputBox.js +0 -98
- package/esm/components/InputBoxWithSuggestion.d.ts +0 -272
- package/esm/components/InputBoxWithSuggestion.js +0 -69
- package/esm/components/InputJSONSchema.d.ts +0 -2
- package/esm/components/InputJSONSchema.js +0 -7
- package/esm/components/InputTable.d.ts +0 -317
- package/esm/components/InputTable.js +0 -176
- package/esm/components/JSONSchemaEditor.d.ts +0 -2
- package/esm/components/JSONSchemaEditor.js +0 -7
- package/esm/components/Layout.d.ts +0 -74
- package/esm/components/Layout.js +0 -60
- package/esm/components/Link.d.ts +0 -60
- package/esm/components/Link.js +0 -44
- package/esm/components/ListGroup.d.ts +0 -77
- package/esm/components/ListGroup.js +0 -31
- package/esm/components/ListMenu.d.ts +0 -568
- package/esm/components/ListMenu.js +0 -62
- package/esm/components/LocationPicker.d.ts +0 -467
- package/esm/components/LocationPicker.js +0 -208
- package/esm/components/Markdown.d.ts +0 -25
- package/esm/components/Markdown.js +0 -70
- package/esm/components/Menu.d.ts +0 -2
- package/esm/components/Menu.js +0 -7
- package/esm/components/MobileDevTool.d.ts +0 -12
- package/esm/components/MobileDevTool.js +0 -312
- package/esm/components/Modal.d.ts +0 -1316
- package/esm/components/Modal.js +0 -261
- package/esm/components/ModalManager.d.ts +0 -17
- package/esm/components/ModalManager.js +0 -42
- package/esm/components/MonthRangePicker.d.ts +0 -744
- package/esm/components/MultilineText.d.ts +0 -454
- package/esm/components/MultilineText.js +0 -90
- package/esm/components/NumberInput.d.ts +0 -201
- package/esm/components/NumberInput.js +0 -274
- package/esm/components/OverflowTpl.d.ts +0 -61
- package/esm/components/OverflowTpl.js +0 -101
- package/esm/components/Pagination.d.ts +0 -812
- package/esm/components/Pagination.js +0 -375
- package/esm/components/PdfViewer.d.ts +0 -49
- package/esm/components/PdfViewer.js +0 -83
- package/esm/components/Picker.d.ts +0 -277
- package/esm/components/Picker.js +0 -73
- package/esm/components/PickerColumn.d.ts +0 -62
- package/esm/components/PickerColumn.js +0 -276
- package/esm/components/PickerContainer.d.ts +0 -291
- package/esm/components/PickerContainer.js +0 -157
- package/esm/components/PopOverContainer.d.ts +0 -59
- package/esm/components/PopOverContainer.js +0 -149
- package/esm/components/PopUp.d.ts +0 -573
- package/esm/components/PopUp.js +0 -85
- package/esm/components/Progress.d.ts +0 -311
- package/esm/components/Progress.js +0 -136
- package/esm/components/PullRefresh.d.ts +0 -79
- package/esm/components/PullRefresh.js +0 -172
- package/esm/components/Radios.d.ts +0 -170
- package/esm/components/Radios.js +0 -122
- package/esm/components/Range.d.ts +0 -131
- package/esm/components/Range.js +0 -517
- package/esm/components/Rating.d.ts +0 -227
- package/esm/components/Rating.js +0 -341
- package/esm/components/ResultBox.d.ts +0 -532
- package/esm/components/ResultBox.js +0 -215
- package/esm/components/ResultList.d.ts +0 -554
- package/esm/components/ResultList.js +0 -254
- package/esm/components/ResultTableList.d.ts +0 -786
- package/esm/components/ResultTableList.js +0 -152
- package/esm/components/ResultTreeList.d.ts +0 -425
- package/esm/components/ResultTreeList.js +0 -239
- package/esm/components/RichText.d.ts +0 -48
- package/esm/components/RichText.js +0 -271
- package/esm/components/SearchBox.d.ts +0 -625
- package/esm/components/SearchBox.js +0 -299
- package/esm/components/Select.d.ts +0 -6498
- package/esm/components/Select.js +0 -843
- package/esm/components/SelectMobile.d.ts +0 -38
- package/esm/components/SelectMobile.js +0 -370
- package/esm/components/Selection.d.ts +0 -598
- package/esm/components/Selection.js +0 -166
- package/esm/components/Shape.d.ts +0 -58
- package/esm/components/Shape.js +0 -429
- package/esm/components/Signature.d.ts +0 -279
- package/esm/components/Signature.js +0 -291
- package/esm/components/Slider.d.ts +0 -56
- package/esm/components/Slider.js +0 -140
- package/esm/components/SparkLine.d.ts +0 -397
- package/esm/components/SparkLine.js +0 -62
- package/esm/components/Spinner.d.ts +0 -266
- package/esm/components/Spinner.js +0 -202
- package/esm/components/Steps.d.ts +0 -117
- package/esm/components/Steps.js +0 -76
- package/esm/components/Switch.d.ts +0 -105
- package/esm/components/Switch.js +0 -73
- package/esm/components/Tab.d.ts +0 -2
- package/esm/components/Tab.js +0 -7
- package/esm/components/Table.d.ts +0 -2
- package/esm/components/Table.js +0 -7
- package/esm/components/TableSelection.d.ts +0 -791
- package/esm/components/TableSelection.js +0 -169
- package/esm/components/Tabs.d.ts +0 -670
- package/esm/components/Tabs.js +0 -607
- package/esm/components/TabsTransfer.d.ts +0 -423
- package/esm/components/TabsTransfer.js +0 -219
- package/esm/components/TabsTransferPicker.d.ts +0 -267
- package/esm/components/TabsTransferPicker.js +0 -81
- package/esm/components/Tag.d.ts +0 -307
- package/esm/components/Tag.js +0 -137
- package/esm/components/Textarea.d.ts +0 -564
- package/esm/components/Textarea.js +0 -147
- package/esm/components/Timeline.d.ts +0 -56
- package/esm/components/Timeline.js +0 -60
- package/esm/components/TimelineItem.d.ts +0 -1292
- package/esm/components/TimelineItem.js +0 -101
- package/esm/components/Tinymce.d.ts +0 -66
- package/esm/components/Tinymce.js +0 -632
- package/esm/components/TitleBar.d.ts +0 -123
- package/esm/components/TitleBar.js +0 -48
- package/esm/components/Toast.d.ts +0 -591
- package/esm/components/Toast.js +0 -247
- package/esm/components/Tooltip.d.ts +0 -65
- package/esm/components/Tooltip.js +0 -36
- package/esm/components/TooltipWrapper.d.ts +0 -217
- package/esm/components/TooltipWrapper.js +0 -181
- package/esm/components/Transfer.d.ts +0 -1844
- package/esm/components/Transfer.js +0 -481
- package/esm/components/TransferDropDown.d.ts +0 -634
- package/esm/components/TransferDropDown.js +0 -98
- package/esm/components/TransferPicker.d.ts +0 -275
- package/esm/components/TransferPicker.js +0 -98
- package/esm/components/TransferSearch.d.ts +0 -283
- package/esm/components/TransferSearch.js +0 -100
- package/esm/components/Tree.d.ts +0 -1991
- package/esm/components/Tree.js +0 -1179
- package/esm/components/TreeSelection.d.ts +0 -601
- package/esm/components/TreeSelection.js +0 -201
- package/esm/components/UserSelect.d.ts +0 -541
- package/esm/components/UserSelect.js +0 -674
- package/esm/components/UserTabSelect.d.ts +0 -315
- package/esm/components/UserTabSelect.js +0 -227
- package/esm/components/VerificationCode.d.ts +0 -116
- package/esm/components/VerificationCode.js +0 -172
- package/esm/components/VirtualList.d.ts +0 -2
- package/esm/components/VirtualList.js +0 -7
- package/esm/components/WithRemoteConfig.d.ts +0 -383
- package/esm/components/WithRemoteConfig.js +0 -302
- package/esm/components/WithStore.d.ts +0 -72
- package/esm/components/WithStore.js +0 -48
- package/esm/components/calendar/Calendar.d.ts +0 -83
- package/esm/components/calendar/Calendar.js +0 -529
- package/esm/components/calendar/CalendarContainer.d.ts +0 -10
- package/esm/components/calendar/CalendarContainer.js +0 -27
- package/esm/components/calendar/DaysView.d.ts +0 -184
- package/esm/components/calendar/DaysView.js +0 -527
- package/esm/components/calendar/MonthsView.d.ts +0 -133
- package/esm/components/calendar/MonthsView.js +0 -175
- package/esm/components/calendar/QuartersView.d.ts +0 -102
- package/esm/components/calendar/QuartersView.js +0 -125
- package/esm/components/calendar/TimeView.d.ts +0 -183
- package/esm/components/calendar/TimeView.js +0 -559
- package/esm/components/calendar/YearsView.d.ts +0 -102
- package/esm/components/calendar/YearsView.js +0 -122
- package/esm/components/condition-builder/Expression.d.ts +0 -292
- package/esm/components/condition-builder/Expression.js +0 -121
- package/esm/components/condition-builder/Field.d.ts +0 -272
- package/esm/components/condition-builder/Field.js +0 -32
- package/esm/components/condition-builder/Formula.d.ts +0 -261
- package/esm/components/condition-builder/Func.d.ts +0 -273
- package/esm/components/condition-builder/Func.js +0 -75
- package/esm/components/condition-builder/Group.d.ts +0 -310
- package/esm/components/condition-builder/Group.js +0 -191
- package/esm/components/condition-builder/GroupOrItem.d.ts +0 -87
- package/esm/components/condition-builder/GroupOrItem.js +0 -105
- package/esm/components/condition-builder/InputSwitch.d.ts +0 -47
- package/esm/components/condition-builder/InputSwitch.js +0 -28
- package/esm/components/condition-builder/Item.d.ts +0 -287
- package/esm/components/condition-builder/Item.js +0 -232
- package/esm/components/condition-builder/Value.d.ts +0 -272
- package/esm/components/condition-builder/Value.js +0 -108
- package/esm/components/condition-builder/config.d.ts +0 -36
- package/esm/components/condition-builder/config.js +0 -120
- package/esm/components/condition-builder/index.d.ts +0 -319
- package/esm/components/condition-builder/index.js +0 -228
- package/esm/components/condition-builder/types.d.ts +0 -115
- package/esm/components/formula/CodeEditor.d.ts +0 -92
- package/esm/components/formula/CodeEditor.js +0 -99
- package/esm/components/formula/Editor.d.ts +0 -516
- package/esm/components/formula/Editor.js +0 -430
- package/esm/components/formula/FuncList.d.ts +0 -46
- package/esm/components/formula/FuncList.js +0 -63
- package/esm/components/formula/Input.d.ts +0 -292
- package/esm/components/formula/Input.js +0 -122
- package/esm/components/formula/Picker.d.ts +0 -492
- package/esm/components/formula/Picker.js +0 -454
- package/esm/components/formula/VariableList.d.ts +0 -58
- package/esm/components/formula/VariableList.js +0 -182
- package/esm/components/formula/plugin.d.ts +0 -51
- package/esm/components/formula/plugin.js +0 -372
- package/esm/components/icons.d.ts +0 -61
- package/esm/components/icons.js +0 -456
- package/esm/components/index.d.ts +0 -136
- package/esm/components/json-schema/Array.d.ts +0 -3
- package/esm/components/json-schema/Array.js +0 -129
- package/esm/components/json-schema/Item.d.ts +0 -5
- package/esm/components/json-schema/Item.js +0 -63
- package/esm/components/json-schema/Object.d.ts +0 -5
- package/esm/components/json-schema/Object.js +0 -265
- package/esm/components/json-schema/index.d.ts +0 -272
- package/esm/components/json-schema/index.js +0 -29
- package/esm/components/menu/MenuContext.d.ts +0 -83
- package/esm/components/menu/MenuContext.js +0 -25
- package/esm/components/menu/MenuItem.d.ts +0 -81
- package/esm/components/menu/MenuItem.js +0 -112
- package/esm/components/menu/PanelMenu.d.ts +0 -46
- package/esm/components/menu/PanelMenu.js +0 -68
- package/esm/components/menu/SubMenu.d.ts +0 -84
- package/esm/components/menu/SubMenu.js +0 -137
- package/esm/components/menu/index.d.ts +0 -381
- package/esm/components/menu/index.js +0 -369
- package/esm/components/schema-editor/Array.d.ts +0 -11
- package/esm/components/schema-editor/Array.js +0 -84
- package/esm/components/schema-editor/Common.d.ts +0 -61
- package/esm/components/schema-editor/Common.js +0 -161
- package/esm/components/schema-editor/Item.d.ts +0 -8
- package/esm/components/schema-editor/Item.js +0 -24
- package/esm/components/schema-editor/Object.d.ts +0 -51
- package/esm/components/schema-editor/Object.js +0 -294
- package/esm/components/schema-editor/SchemaVariableList.d.ts +0 -186
- package/esm/components/schema-editor/SchemaVariableList.js +0 -74
- package/esm/components/schema-editor/SchemaVariableListPicker.d.ts +0 -179
- package/esm/components/schema-editor/SchemaVariableListPicker.js +0 -34
- package/esm/components/schema-editor/index.d.ts +0 -797
- package/esm/components/schema-editor/index.js +0 -122
- package/esm/components/table/Cell.d.ts +0 -36
- package/esm/components/table/Cell.js +0 -43
- package/esm/components/table/ColGroup.d.ts +0 -24
- package/esm/components/table/ColGroup.js +0 -58
- package/esm/components/table/Head.d.ts +0 -45
- package/esm/components/table/Head.js +0 -150
- package/esm/components/table/HeadCellDropDown.d.ts +0 -289
- package/esm/components/table/HeadCellDropDown.js +0 -55
- package/esm/components/table/HeadCellFilter.d.ts +0 -414
- package/esm/components/table/HeadCellFilter.js +0 -131
- package/esm/components/table/HeadCellSelect.d.ts +0 -357
- package/esm/components/table/HeadCellSelect.js +0 -52
- package/esm/components/table/HeadCellSort.d.ts +0 -278
- package/esm/components/table/HeadCellSort.js +0 -88
- package/esm/components/table/ItemActionsWrapper.d.ts +0 -10
- package/esm/components/table/ItemActionsWrapper.js +0 -29
- package/esm/components/table/Row.d.ts +0 -56
- package/esm/components/table/Row.js +0 -224
- package/esm/components/table/SummaryRow.d.ts +0 -28
- package/esm/components/table/SummaryRow.js +0 -73
- package/esm/components/table/index.d.ts +0 -852
- package/esm/components/table/index.js +0 -1067
- package/esm/components/table/util.d.ts +0 -56
- package/esm/components/table/util.js +0 -263
- package/esm/components/virtual-list/AutoSizer.d.ts +0 -19
- package/esm/components/virtual-list/AutoSizer.js +0 -49
- package/esm/components/virtual-list/SizeAndPositionManager.d.ts +0 -70
- package/esm/components/virtual-list/SizeAndPositionManager.js +0 -216
- package/esm/components/virtual-list/constants.d.ts +0 -34
- package/esm/components/virtual-list/constants.js +0 -45
- package/esm/components/virtual-list/index.d.ts +0 -99
- package/esm/components/virtual-list/index.js +0 -288
- package/esm/components/withBadge.d.ts +0 -2
- package/esm/components/withBadge.js +0 -7
- package/esm/hooks/index.d.ts +0 -8
- package/esm/hooks/use-click-away.d.ts +0 -12
- package/esm/hooks/use-click-away.js +0 -55
- package/esm/hooks/use-on-screen.d.ts +0 -2
- package/esm/hooks/use-on-screen.js +0 -28
- package/esm/hooks/use-set-state.d.ts +0 -2
- package/esm/hooks/use-set-state.js +0 -19
- package/esm/hooks/use-sub-form.d.ts +0 -4
- package/esm/hooks/use-sub-form.js +0 -39
- package/esm/hooks/use-touch.d.ts +0 -16
- package/esm/hooks/use-touch.js +0 -77
- package/esm/hooks/use-update-effect.d.ts +0 -3
- package/esm/hooks/use-update-effect.js +0 -21
- package/esm/hooks/use-validation-resolver.d.ts +0 -7
- package/esm/hooks/use-validation-resolver.js +0 -115
- package/esm/icons/alert-danger.svg.js +0 -22
- package/esm/icons/alert-info.svg.js +0 -22
- package/esm/icons/alert-success.svg.js +0 -22
- package/esm/icons/alert-warning.svg.js +0 -22
- package/esm/icons/arrow-double-left.svg.js +0 -24
- package/esm/icons/arrow-double-right.svg.js +0 -24
- package/esm/icons/back.svg.js +0 -21
- package/esm/icons/calendar.svg.js +0 -31
- package/esm/icons/caret.svg.js +0 -21
- package/esm/icons/check.svg.js +0 -21
- package/esm/icons/clock.svg.js +0 -29
- package/esm/icons/close-small.svg.js +0 -24
- package/esm/icons/close.svg.js +0 -21
- package/esm/icons/cloud-upload.svg.js +0 -22
- package/esm/icons/column-filter.svg.js +0 -22
- package/esm/icons/columns.svg.js +0 -21
- package/esm/icons/compress-alt.svg.js +0 -21
- package/esm/icons/copy.svg.js +0 -26
- package/esm/icons/date.svg.js +0 -26
- package/esm/icons/department.svg.js +0 -52
- package/esm/icons/desk-empty.svg.js +0 -73
- package/esm/icons/dot.svg.js +0 -36
- package/esm/icons/down-arrow-bold.svg.js +0 -22
- package/esm/icons/down.svg.js +0 -23
- package/esm/icons/download.svg.js +0 -24
- package/esm/icons/drag-bar.svg.js +0 -53
- package/esm/icons/drag.svg.js +0 -22
- package/esm/icons/edit.svg.js +0 -21
- package/esm/icons/ellipsis-v.svg.js +0 -21
- package/esm/icons/enter.svg.js +0 -20
- package/esm/icons/exchange.svg.js +0 -21
- package/esm/icons/expand-alt.svg.js +0 -21
- package/esm/icons/fail.svg.js +0 -31
- package/esm/icons/file.svg.js +0 -22
- package/esm/icons/filter.svg.js +0 -21
- package/esm/icons/folder.svg.js +0 -24
- package/esm/icons/fullscreen.svg.js +0 -21
- package/esm/icons/function.svg.js +0 -21
- package/esm/icons/home.svg.js +0 -21
- package/esm/icons/if.svg.js +0 -21
- package/esm/icons/image.svg.js +0 -20
- package/esm/icons/info-circle.svg.js +0 -21
- package/esm/icons/info.svg.js +0 -27
- package/esm/icons/input-clear.svg.js +0 -20
- package/esm/icons/invisible.svg.js +0 -22
- package/esm/icons/left-arrow.svg.js +0 -23
- package/esm/icons/loading-outline.svg.js +0 -21
- package/esm/icons/location.svg.js +0 -20
- package/esm/icons/menu.svg.js +0 -20
- package/esm/icons/minus.svg.js +0 -21
- package/esm/icons/move.svg.js +0 -22
- package/esm/icons/mute.svg.js +0 -21
- package/esm/icons/new-edit.svg.js +0 -22
- package/esm/icons/pause.svg.js +0 -21
- package/esm/icons/pencil.svg.js +0 -21
- package/esm/icons/play.svg.js +0 -20
- package/esm/icons/plus-cicle.svg.js +0 -20
- package/esm/icons/plus-fine.svg.js +0 -21
- package/esm/icons/plus.svg.js +0 -21
- package/esm/icons/post.svg.js +0 -48
- package/esm/icons/question-mark.svg.js +0 -26
- package/esm/icons/question.svg.js +0 -21
- package/esm/icons/redo.svg.js +0 -21
- package/esm/icons/refresh.svg.js +0 -21
- package/esm/icons/reload.svg.js +0 -21
- package/esm/icons/remove.svg.js +0 -21
- package/esm/icons/retry.svg.js +0 -24
- package/esm/icons/right-arrow-bold.svg.js +0 -21
- package/esm/icons/right-arrow.svg.js +0 -23
- package/esm/icons/right-double-arrow.svg.js +0 -22
- package/esm/icons/role.svg.js +0 -43
- package/esm/icons/rotate-left.svg.js +0 -22
- package/esm/icons/rotate-right.svg.js +0 -22
- package/esm/icons/rotate-screen.svg.js +0 -21
- package/esm/icons/scale-origin.svg.js +0 -24
- package/esm/icons/schedule.svg.js +0 -24
- package/esm/icons/search.svg.js +0 -21
- package/esm/icons/setting.svg.js +0 -21
- package/esm/icons/slider-handle-icon.svg.js +0 -22
- package/esm/icons/sort-asc.svg.js +0 -21
- package/esm/icons/sort-default.svg.js +0 -21
- package/esm/icons/sort-desc.svg.js +0 -21
- package/esm/icons/star.svg.js +0 -21
- package/esm/icons/status-close.svg.js +0 -23
- package/esm/icons/steps-finsh.svg.js +0 -22
- package/esm/icons/sub-plus.svg.js +0 -20
- package/esm/icons/success.svg.js +0 -29
- package/esm/icons/transparent.svg.js +0 -38
- package/esm/icons/trash.svg.js +0 -22
- package/esm/icons/tree-down.svg.js +0 -21
- package/esm/icons/undo-normal.svg.js +0 -25
- package/esm/icons/undo.svg.js +0 -21
- package/esm/icons/unfullscreen.svg.js +0 -21
- package/esm/icons/upload.svg.js +0 -21
- package/esm/icons/user-remove.svg.js +0 -33
- package/esm/icons/view.svg.js +0 -22
- package/esm/icons/volume.svg.js +0 -24
- package/esm/icons/warning-mark.svg.js +0 -22
- package/esm/icons/warning.svg.js +0 -21
- package/esm/icons/window-restore.svg.js +0 -21
- package/esm/icons/zoom-in.svg.js +0 -21
- package/esm/icons/zoom-out.svg.js +0 -21
- package/esm/index.d.ts +0 -15
- package/esm/index.js +0 -154
- package/esm/locale/de-DE.d.ts +0 -1
- package/esm/locale/de-DE.js +0 -419
- package/esm/locale/en-US.d.ts +0 -1
- package/esm/locale/en-US.js +0 -425
- package/esm/locale/zh-CN.d.ts +0 -1
- package/esm/locale/zh-CN.js +0 -434
- package/esm/themes/ang.d.ts +0 -3
- package/esm/themes/ang.js +0 -15
- package/esm/themes/antd.d.ts +0 -1
- package/esm/themes/antd.js +0 -42
- package/esm/themes/cxd.d.ts +0 -3
- package/esm/themes/cxd.js +0 -455
- package/esm/themes/dark.d.ts +0 -3
- package/esm/themes/dark.js +0 -23
- package/esm/themes/default.d.ts +0 -4
- package/esm/utils/index.d.ts +0 -2
- package/esm/utils/smoothSignature.d.ts +0 -86
- package/esm/utils/vectorComputed.d.ts +0 -20
- package/esm/utils/vectorComputed.js +0 -75
- package/esm/withRemoteConfig.d.ts +0 -2
- package/esm/withRemoteConfig.js +0 -7
- package/esm/withStore.d.ts +0 -2
- package/esm/withStore.js +0 -7
- package/lib/components/404.d.ts +0 -53
- package/lib/components/404.js +0 -43
- package/lib/components/Alert.d.ts +0 -615
- package/lib/components/Alert.js +0 -279
- package/lib/components/Alert2.d.ts +0 -117
- package/lib/components/Alert2.js +0 -66
- package/lib/components/AlphabetIndexer.d.ts +0 -11
- package/lib/components/AlphabetIndexer.js +0 -59
- package/lib/components/AnchorNav.d.ts +0 -162
- package/lib/components/AnchorNav.js +0 -162
- package/lib/components/AnchorNavSection.d.ts +0 -2
- package/lib/components/AnchorNavSection.js +0 -14
- package/lib/components/ArrayInput.d.ts +0 -617
- package/lib/components/ArrayInput.js +0 -160
- package/lib/components/AsideNav.d.ts +0 -142
- package/lib/components/AsideNav.js +0 -140
- package/lib/components/AssociatedSelection.d.ts +0 -564
- package/lib/components/AssociatedSelection.js +0 -106
- package/lib/components/AutoSizer.d.ts +0 -2
- package/lib/components/AutoSizer.js +0 -15
- package/lib/components/Avatar.d.ts +0 -374
- package/lib/components/Avatar.js +0 -154
- package/lib/components/Badge.d.ts +0 -118
- package/lib/components/Badge.js +0 -165
- package/lib/components/BaiduMapPicker.d.ts +0 -100
- package/lib/components/BaiduMapPicker.js +0 -379
- package/lib/components/BarCode.d.ts +0 -56
- package/lib/components/BarCode.js +0 -52
- package/lib/components/Breadcrumb.d.ts +0 -115
- package/lib/components/Breadcrumb.js +0 -170
- package/lib/components/Button.d.ts +0 -147
- package/lib/components/Button.js +0 -71
- package/lib/components/CalendarMobile.d.ts +0 -431
- package/lib/components/CalendarMobile.js +0 -546
- package/lib/components/Card.d.ts +0 -444
- package/lib/components/Card.js +0 -100
- package/lib/components/Cascader.d.ts +0 -108
- package/lib/components/Cascader.js +0 -527
- package/lib/components/ChainedDropdownSelection.d.ts +0 -561
- package/lib/components/ChainedDropdownSelection.js +0 -116
- package/lib/components/ChainedSelection.d.ts +0 -554
- package/lib/components/ChainedSelection.js +0 -197
- package/lib/components/Checkbox.d.ts +0 -110
- package/lib/components/Checkbox.js +0 -95
- package/lib/components/CityArea.d.ts +0 -299
- package/lib/components/CityArea.js +0 -197
- package/lib/components/CityDB.d.ts +0 -13
- package/lib/components/CityDB.js +0 -3949
- package/lib/components/CodeMirror.d.ts +0 -29
- package/lib/components/CodeMirror.js +0 -152
- package/lib/components/Collapse.d.ts +0 -447
- package/lib/components/Collapse.js +0 -192
- package/lib/components/CollapseGroup.d.ts +0 -219
- package/lib/components/CollapseGroup.js +0 -124
- package/lib/components/ColorPicker.d.ts +0 -530
- package/lib/components/ColorPicker.js +0 -267
- package/lib/components/Combo.d.ts +0 -354
- package/lib/components/Combo.js +0 -165
- package/lib/components/ConditionBuilder.d.ts +0 -2
- package/lib/components/ConditionBuilder.js +0 -14
- package/lib/components/ConfirmBox.d.ts +0 -322
- package/lib/components/ConfirmBox.js +0 -141
- package/lib/components/ContextMenu.d.ts +0 -115
- package/lib/components/ContextMenu.js +0 -322
- package/lib/components/DatePicker.d.ts +0 -638
- package/lib/components/DatePicker.js +0 -725
- package/lib/components/DateRangePicker.d.ts +0 -1046
- package/lib/components/DateRangePicker.js +0 -1401
- package/lib/components/DiffEditor.d.ts +0 -21
- package/lib/components/DiffEditor.js +0 -130
- package/lib/components/DndContainer.d.ts +0 -205
- package/lib/components/DndContainer.js +0 -32
- package/lib/components/Drawer.d.ts +0 -158
- package/lib/components/Drawer.js +0 -279
- package/lib/components/DropDownSelection.d.ts +0 -557
- package/lib/components/DropDownSelection.js +0 -85
- package/lib/components/DropdownContextMenus.d.ts +0 -84
- package/lib/components/DropdownContextMenus.js +0 -101
- package/lib/components/Editor.d.ts +0 -681
- package/lib/components/Editor.js +0 -246
- package/lib/components/Form.d.ts +0 -31
- package/lib/components/Form.js +0 -97
- package/lib/components/FormField.d.ts +0 -287
- package/lib/components/FormField.js +0 -90
- package/lib/components/FormulaPicker.d.ts +0 -2
- package/lib/components/FormulaPicker.js +0 -14
- package/lib/components/GaodeMapPicker.d.ts +0 -89
- package/lib/components/GaodeMapPicker.js +0 -217
- package/lib/components/GridNav.d.ts +0 -53
- package/lib/components/GridNav.js +0 -133
- package/lib/components/GridNavItem.d.ts +0 -2
- package/lib/components/GridNavItem.js +0 -14
- package/lib/components/GroupedSelection.d.ts +0 -543
- package/lib/components/GroupedSelection.js +0 -150
- package/lib/components/HeadCellDropDown.d.ts +0 -2
- package/lib/components/HeadCellDropDown.js +0 -14
- package/lib/components/HorizontalScroll.d.ts +0 -75
- package/lib/components/HorizontalScroll.js +0 -283
- package/lib/components/Html.d.ts +0 -82
- package/lib/components/Html.js +0 -59
- package/lib/components/Icon.d.ts +0 -2
- package/lib/components/Icon.js +0 -14
- package/lib/components/ImageGallery.d.ts +0 -465
- package/lib/components/ImageGallery.js +0 -409
- package/lib/components/Input.d.ts +0 -18
- package/lib/components/Input.js +0 -86
- package/lib/components/InputBox.d.ts +0 -100
- package/lib/components/InputBox.js +0 -110
- package/lib/components/InputBoxWithSuggestion.d.ts +0 -272
- package/lib/components/InputBoxWithSuggestion.js +0 -81
- package/lib/components/InputJSONSchema.d.ts +0 -2
- package/lib/components/InputJSONSchema.js +0 -14
- package/lib/components/InputTable.d.ts +0 -317
- package/lib/components/InputTable.js +0 -189
- package/lib/components/JSONSchemaEditor.d.ts +0 -2
- package/lib/components/JSONSchemaEditor.js +0 -14
- package/lib/components/Layout.d.ts +0 -74
- package/lib/components/Layout.js +0 -56
- package/lib/components/Link.d.ts +0 -60
- package/lib/components/Link.js +0 -56
- package/lib/components/ListGroup.d.ts +0 -77
- package/lib/components/ListGroup.js +0 -43
- package/lib/components/ListMenu.d.ts +0 -568
- package/lib/components/ListMenu.js +0 -74
- package/lib/components/LocationPicker.d.ts +0 -467
- package/lib/components/LocationPicker.js +0 -220
- package/lib/components/Markdown.d.ts +0 -25
- package/lib/components/Markdown.js +0 -83
- package/lib/components/Menu.d.ts +0 -2
- package/lib/components/Menu.js +0 -14
- package/lib/components/MobileDevTool.d.ts +0 -12
- package/lib/components/MobileDevTool.js +0 -325
- package/lib/components/Modal.d.ts +0 -1316
- package/lib/components/Modal.js +0 -272
- package/lib/components/ModalManager.d.ts +0 -17
- package/lib/components/ModalManager.js +0 -53
- package/lib/components/MonthRangePicker.d.ts +0 -744
- package/lib/components/MultilineText.d.ts +0 -454
- package/lib/components/MultilineText.js +0 -102
- package/lib/components/NumberInput.d.ts +0 -201
- package/lib/components/NumberInput.js +0 -289
- package/lib/components/OverflowTpl.d.ts +0 -61
- package/lib/components/OverflowTpl.js +0 -109
- package/lib/components/Pagination.d.ts +0 -812
- package/lib/components/Pagination.js +0 -388
- package/lib/components/PdfViewer.d.ts +0 -49
- package/lib/components/PdfViewer.js +0 -89
- package/lib/components/Picker.d.ts +0 -277
- package/lib/components/Picker.js +0 -80
- package/lib/components/PickerColumn.d.ts +0 -62
- package/lib/components/PickerColumn.js +0 -288
- package/lib/components/PickerContainer.d.ts +0 -291
- package/lib/components/PickerContainer.js +0 -169
- package/lib/components/PopOverContainer.d.ts +0 -59
- package/lib/components/PopOverContainer.js +0 -162
- package/lib/components/PopUp.d.ts +0 -573
- package/lib/components/PopUp.js +0 -94
- package/lib/components/Progress.d.ts +0 -311
- package/lib/components/Progress.js +0 -148
- package/lib/components/PullRefresh.d.ts +0 -79
- package/lib/components/PullRefresh.js +0 -178
- package/lib/components/Radios.d.ts +0 -170
- package/lib/components/Radios.js +0 -119
- package/lib/components/Range.d.ts +0 -131
- package/lib/components/Range.js +0 -528
- package/lib/components/Rating.d.ts +0 -227
- package/lib/components/Rating.js +0 -349
- package/lib/components/ResultBox.d.ts +0 -532
- package/lib/components/ResultBox.js +0 -230
- package/lib/components/ResultList.d.ts +0 -554
- package/lib/components/ResultList.js +0 -268
- package/lib/components/ResultTableList.d.ts +0 -786
- package/lib/components/ResultTableList.js +0 -161
- package/lib/components/ResultTreeList.d.ts +0 -425
- package/lib/components/ResultTreeList.js +0 -254
- package/lib/components/RichText.d.ts +0 -48
- package/lib/components/RichText.js +0 -283
- package/lib/components/SearchBox.d.ts +0 -625
- package/lib/components/SearchBox.js +0 -315
- package/lib/components/Select.d.ts +0 -6498
- package/lib/components/Select.js +0 -861
- package/lib/components/SelectMobile.d.ts +0 -38
- package/lib/components/SelectMobile.js +0 -382
- package/lib/components/Selection.d.ts +0 -598
- package/lib/components/Selection.js +0 -176
- package/lib/components/Shape.d.ts +0 -58
- package/lib/components/Shape.js +0 -434
- package/lib/components/Signature.d.ts +0 -279
- package/lib/components/Signature.js +0 -295
- package/lib/components/Slider.d.ts +0 -56
- package/lib/components/Slider.js +0 -146
- package/lib/components/SparkLine.d.ts +0 -397
- package/lib/components/SparkLine.js +0 -74
- package/lib/components/Spinner.d.ts +0 -266
- package/lib/components/Spinner.js +0 -210
- package/lib/components/Steps.d.ts +0 -117
- package/lib/components/Steps.js +0 -84
- package/lib/components/Switch.d.ts +0 -105
- package/lib/components/Switch.js +0 -80
- package/lib/components/Tab.d.ts +0 -2
- package/lib/components/Tab.js +0 -14
- package/lib/components/Table.d.ts +0 -2
- package/lib/components/Table.js +0 -14
- package/lib/components/TableSelection.d.ts +0 -791
- package/lib/components/TableSelection.js +0 -183
- package/lib/components/Tabs.d.ts +0 -670
- package/lib/components/Tabs.js +0 -618
- package/lib/components/TabsTransfer.d.ts +0 -423
- package/lib/components/TabsTransfer.js +0 -232
- package/lib/components/TabsTransferPicker.d.ts +0 -267
- package/lib/components/TabsTransferPicker.js +0 -93
- package/lib/components/Tag.d.ts +0 -307
- package/lib/components/Tag.js +0 -146
- package/lib/components/Textarea.d.ts +0 -564
- package/lib/components/Textarea.js +0 -160
- package/lib/components/Timeline.d.ts +0 -56
- package/lib/components/Timeline.js +0 -68
- package/lib/components/TimelineItem.d.ts +0 -1292
- package/lib/components/TimelineItem.js +0 -118
- package/lib/components/Tinymce.d.ts +0 -66
- package/lib/components/Tinymce.js +0 -648
- package/lib/components/TitleBar.d.ts +0 -123
- package/lib/components/TitleBar.js +0 -51
- package/lib/components/Toast.d.ts +0 -591
- package/lib/components/Toast.js +0 -258
- package/lib/components/Tooltip.d.ts +0 -65
- package/lib/components/Tooltip.js +0 -43
- package/lib/components/TooltipWrapper.d.ts +0 -217
- package/lib/components/TooltipWrapper.js +0 -188
- package/lib/components/Transfer.d.ts +0 -1844
- package/lib/components/Transfer.js +0 -498
- package/lib/components/TransferDropDown.d.ts +0 -634
- package/lib/components/TransferDropDown.js +0 -106
- package/lib/components/TransferPicker.d.ts +0 -275
- package/lib/components/TransferPicker.js +0 -110
- package/lib/components/TransferSearch.d.ts +0 -283
- package/lib/components/TransferSearch.js +0 -113
- package/lib/components/Tree.d.ts +0 -1991
- package/lib/components/Tree.js +0 -1173
- package/lib/components/TreeSelection.d.ts +0 -601
- package/lib/components/TreeSelection.js +0 -209
- package/lib/components/UserSelect.d.ts +0 -541
- package/lib/components/UserSelect.js +0 -685
- package/lib/components/UserTabSelect.d.ts +0 -315
- package/lib/components/UserTabSelect.js +0 -235
- package/lib/components/VerificationCode.d.ts +0 -116
- package/lib/components/VerificationCode.js +0 -191
- package/lib/components/VirtualList.d.ts +0 -2
- package/lib/components/VirtualList.js +0 -14
- package/lib/components/WithRemoteConfig.d.ts +0 -383
- package/lib/components/WithRemoteConfig.js +0 -316
- package/lib/components/WithStore.d.ts +0 -72
- package/lib/components/WithStore.js +0 -61
- package/lib/components/calendar/Calendar.d.ts +0 -83
- package/lib/components/calendar/Calendar.js +0 -542
- package/lib/components/calendar/CalendarContainer.d.ts +0 -10
- package/lib/components/calendar/CalendarContainer.js +0 -38
- package/lib/components/calendar/DaysView.d.ts +0 -184
- package/lib/components/calendar/DaysView.js +0 -546
- package/lib/components/calendar/MonthsView.d.ts +0 -133
- package/lib/components/calendar/MonthsView.js +0 -188
- package/lib/components/calendar/QuartersView.d.ts +0 -102
- package/lib/components/calendar/QuartersView.js +0 -138
- package/lib/components/calendar/TimeView.d.ts +0 -183
- package/lib/components/calendar/TimeView.js +0 -574
- package/lib/components/calendar/YearsView.d.ts +0 -102
- package/lib/components/calendar/YearsView.js +0 -135
- package/lib/components/condition-builder/Expression.d.ts +0 -292
- package/lib/components/condition-builder/Expression.js +0 -133
- package/lib/components/condition-builder/Field.d.ts +0 -272
- package/lib/components/condition-builder/Field.js +0 -44
- package/lib/components/condition-builder/Formula.d.ts +0 -261
- package/lib/components/condition-builder/Func.d.ts +0 -273
- package/lib/components/condition-builder/Func.js +0 -87
- package/lib/components/condition-builder/Group.d.ts +0 -310
- package/lib/components/condition-builder/Group.js +0 -203
- package/lib/components/condition-builder/GroupOrItem.d.ts +0 -87
- package/lib/components/condition-builder/GroupOrItem.js +0 -117
- package/lib/components/condition-builder/InputSwitch.d.ts +0 -47
- package/lib/components/condition-builder/InputSwitch.js +0 -36
- package/lib/components/condition-builder/Item.d.ts +0 -287
- package/lib/components/condition-builder/Item.js +0 -244
- package/lib/components/condition-builder/Value.d.ts +0 -272
- package/lib/components/condition-builder/Value.js +0 -121
- package/lib/components/condition-builder/config.d.ts +0 -36
- package/lib/components/condition-builder/config.js +0 -125
- package/lib/components/condition-builder/index.d.ts +0 -319
- package/lib/components/condition-builder/index.js +0 -240
- package/lib/components/condition-builder/types.d.ts +0 -115
- package/lib/components/formula/CodeEditor.d.ts +0 -92
- package/lib/components/formula/CodeEditor.js +0 -110
- package/lib/components/formula/Editor.d.ts +0 -516
- package/lib/components/formula/Editor.js +0 -444
- package/lib/components/formula/FuncList.d.ts +0 -46
- package/lib/components/formula/FuncList.js +0 -75
- package/lib/components/formula/Input.d.ts +0 -292
- package/lib/components/formula/Input.js +0 -134
- package/lib/components/formula/Picker.d.ts +0 -492
- package/lib/components/formula/Picker.js +0 -467
- package/lib/components/formula/VariableList.d.ts +0 -58
- package/lib/components/formula/VariableList.js +0 -193
- package/lib/components/formula/plugin.d.ts +0 -51
- package/lib/components/formula/plugin.js +0 -381
- package/lib/components/icons.d.ts +0 -61
- package/lib/components/icons.js +0 -484
- package/lib/components/index.d.ts +0 -136
- package/lib/components/json-schema/Array.d.ts +0 -3
- package/lib/components/json-schema/Array.js +0 -140
- package/lib/components/json-schema/Item.d.ts +0 -5
- package/lib/components/json-schema/Item.js +0 -75
- package/lib/components/json-schema/Object.d.ts +0 -5
- package/lib/components/json-schema/Object.js +0 -278
- package/lib/components/json-schema/index.d.ts +0 -272
- package/lib/components/json-schema/index.js +0 -40
- package/lib/components/menu/MenuContext.d.ts +0 -83
- package/lib/components/menu/MenuContext.js +0 -29
- package/lib/components/menu/MenuItem.d.ts +0 -81
- package/lib/components/menu/MenuItem.js +0 -120
- package/lib/components/menu/PanelMenu.d.ts +0 -46
- package/lib/components/menu/PanelMenu.js +0 -74
- package/lib/components/menu/SubMenu.d.ts +0 -84
- package/lib/components/menu/SubMenu.js +0 -145
- package/lib/components/menu/index.d.ts +0 -381
- package/lib/components/menu/index.js +0 -379
- package/lib/components/schema-editor/Array.d.ts +0 -11
- package/lib/components/schema-editor/Array.js +0 -95
- package/lib/components/schema-editor/Common.d.ts +0 -61
- package/lib/components/schema-editor/Common.js +0 -174
- package/lib/components/schema-editor/Item.d.ts +0 -8
- package/lib/components/schema-editor/Item.js +0 -35
- package/lib/components/schema-editor/Object.d.ts +0 -51
- package/lib/components/schema-editor/Object.js +0 -305
- package/lib/components/schema-editor/SchemaVariableList.d.ts +0 -186
- package/lib/components/schema-editor/SchemaVariableList.js +0 -86
- package/lib/components/schema-editor/SchemaVariableListPicker.d.ts +0 -179
- package/lib/components/schema-editor/SchemaVariableListPicker.js +0 -46
- package/lib/components/schema-editor/index.d.ts +0 -797
- package/lib/components/schema-editor/index.js +0 -131
- package/lib/components/table/Cell.d.ts +0 -36
- package/lib/components/table/Cell.js +0 -50
- package/lib/components/table/ColGroup.d.ts +0 -24
- package/lib/components/table/ColGroup.js +0 -69
- package/lib/components/table/Head.d.ts +0 -45
- package/lib/components/table/Head.js +0 -157
- package/lib/components/table/HeadCellDropDown.d.ts +0 -289
- package/lib/components/table/HeadCellDropDown.js +0 -63
- package/lib/components/table/HeadCellFilter.d.ts +0 -414
- package/lib/components/table/HeadCellFilter.js +0 -140
- package/lib/components/table/HeadCellSelect.d.ts +0 -357
- package/lib/components/table/HeadCellSelect.js +0 -60
- package/lib/components/table/HeadCellSort.d.ts +0 -278
- package/lib/components/table/HeadCellSort.js +0 -96
- package/lib/components/table/ItemActionsWrapper.d.ts +0 -10
- package/lib/components/table/ItemActionsWrapper.js +0 -40
- package/lib/components/table/Row.d.ts +0 -56
- package/lib/components/table/Row.js +0 -231
- package/lib/components/table/SummaryRow.d.ts +0 -28
- package/lib/components/table/SummaryRow.js +0 -81
- package/lib/components/table/index.d.ts +0 -852
- package/lib/components/table/index.js +0 -1081
- package/lib/components/table/util.d.ts +0 -56
- package/lib/components/table/util.js +0 -285
- package/lib/components/virtual-list/AutoSizer.d.ts +0 -19
- package/lib/components/virtual-list/AutoSizer.js +0 -76
- package/lib/components/virtual-list/SizeAndPositionManager.d.ts +0 -70
- package/lib/components/virtual-list/SizeAndPositionManager.js +0 -220
- package/lib/components/virtual-list/constants.d.ts +0 -34
- package/lib/components/virtual-list/constants.js +0 -53
- package/lib/components/virtual-list/index.d.ts +0 -99
- package/lib/components/virtual-list/index.js +0 -317
- package/lib/components/withBadge.d.ts +0 -2
- package/lib/components/withBadge.js +0 -14
- package/lib/helper.css +0 -47744
- package/lib/hooks/index.d.ts +0 -8
- package/lib/hooks/use-click-away.d.ts +0 -12
- package/lib/hooks/use-click-away.js +0 -59
- package/lib/hooks/use-on-screen.d.ts +0 -2
- package/lib/hooks/use-on-screen.js +0 -32
- package/lib/hooks/use-set-state.d.ts +0 -2
- package/lib/hooks/use-set-state.js +0 -27
- package/lib/hooks/use-sub-form.d.ts +0 -4
- package/lib/hooks/use-sub-form.js +0 -48
- package/lib/hooks/use-touch.d.ts +0 -16
- package/lib/hooks/use-touch.js +0 -81
- package/lib/hooks/use-update-effect.d.ts +0 -3
- package/lib/hooks/use-update-effect.js +0 -25
- package/lib/hooks/use-validation-resolver.d.ts +0 -7
- package/lib/hooks/use-validation-resolver.js +0 -125
- package/lib/icons/alert-danger.svg.js +0 -29
- package/lib/icons/alert-info.svg.js +0 -29
- package/lib/icons/alert-success.svg.js +0 -29
- package/lib/icons/alert-warning.svg.js +0 -29
- package/lib/icons/arrow-double-left.svg.js +0 -31
- package/lib/icons/arrow-double-right.svg.js +0 -31
- package/lib/icons/back.svg.js +0 -28
- package/lib/icons/calendar.svg.js +0 -38
- package/lib/icons/caret.svg.js +0 -28
- package/lib/icons/check.svg.js +0 -28
- package/lib/icons/clock.svg.js +0 -36
- package/lib/icons/close-small.svg.js +0 -31
- package/lib/icons/close.svg.js +0 -28
- package/lib/icons/cloud-upload.svg.js +0 -29
- package/lib/icons/column-filter.svg.js +0 -29
- package/lib/icons/columns.svg.js +0 -28
- package/lib/icons/compress-alt.svg.js +0 -28
- package/lib/icons/copy.svg.js +0 -33
- package/lib/icons/date.svg.js +0 -33
- package/lib/icons/department.svg.js +0 -59
- package/lib/icons/desk-empty.svg.js +0 -80
- package/lib/icons/dot.svg.js +0 -43
- package/lib/icons/down-arrow-bold.svg.js +0 -29
- package/lib/icons/down.svg.js +0 -30
- package/lib/icons/download.svg.js +0 -31
- package/lib/icons/drag-bar.svg.js +0 -60
- package/lib/icons/drag.svg.js +0 -29
- package/lib/icons/edit.svg.js +0 -28
- package/lib/icons/ellipsis-v.svg.js +0 -28
- package/lib/icons/enter.svg.js +0 -27
- package/lib/icons/exchange.svg.js +0 -28
- package/lib/icons/expand-alt.svg.js +0 -28
- package/lib/icons/fail.svg.js +0 -38
- package/lib/icons/file.svg.js +0 -29
- package/lib/icons/filter.svg.js +0 -28
- package/lib/icons/folder.svg.js +0 -31
- package/lib/icons/fullscreen.svg.js +0 -28
- package/lib/icons/function.svg.js +0 -28
- package/lib/icons/home.svg.js +0 -28
- package/lib/icons/if.svg.js +0 -28
- package/lib/icons/image.svg.js +0 -27
- package/lib/icons/info-circle.svg.js +0 -28
- package/lib/icons/info.svg.js +0 -34
- package/lib/icons/input-clear.svg.js +0 -27
- package/lib/icons/invisible.svg.js +0 -29
- package/lib/icons/left-arrow.svg.js +0 -30
- package/lib/icons/loading-outline.svg.js +0 -28
- package/lib/icons/location.svg.js +0 -27
- package/lib/icons/menu.svg.js +0 -27
- package/lib/icons/minus.svg.js +0 -28
- package/lib/icons/move.svg.js +0 -29
- package/lib/icons/mute.svg.js +0 -28
- package/lib/icons/new-edit.svg.js +0 -29
- package/lib/icons/pause.svg.js +0 -28
- package/lib/icons/pencil.svg.js +0 -28
- package/lib/icons/play.svg.js +0 -27
- package/lib/icons/plus-cicle.svg.js +0 -27
- package/lib/icons/plus-fine.svg.js +0 -28
- package/lib/icons/plus.svg.js +0 -28
- package/lib/icons/post.svg.js +0 -55
- package/lib/icons/question-mark.svg.js +0 -33
- package/lib/icons/question.svg.js +0 -28
- package/lib/icons/redo.svg.js +0 -28
- package/lib/icons/refresh.svg.js +0 -28
- package/lib/icons/reload.svg.js +0 -28
- package/lib/icons/remove.svg.js +0 -28
- package/lib/icons/retry.svg.js +0 -31
- package/lib/icons/right-arrow-bold.svg.js +0 -28
- package/lib/icons/right-arrow.svg.js +0 -30
- package/lib/icons/right-double-arrow.svg.js +0 -29
- package/lib/icons/role.svg.js +0 -50
- package/lib/icons/rotate-left.svg.js +0 -29
- package/lib/icons/rotate-right.svg.js +0 -29
- package/lib/icons/rotate-screen.svg.js +0 -28
- package/lib/icons/scale-origin.svg.js +0 -31
- package/lib/icons/schedule.svg.js +0 -31
- package/lib/icons/search.svg.js +0 -28
- package/lib/icons/setting.svg.js +0 -28
- package/lib/icons/slider-handle-icon.svg.js +0 -29
- package/lib/icons/sort-asc.svg.js +0 -28
- package/lib/icons/sort-default.svg.js +0 -28
- package/lib/icons/sort-desc.svg.js +0 -28
- package/lib/icons/star.svg.js +0 -28
- package/lib/icons/status-close.svg.js +0 -30
- package/lib/icons/steps-finsh.svg.js +0 -29
- package/lib/icons/sub-plus.svg.js +0 -27
- package/lib/icons/success.svg.js +0 -36
- package/lib/icons/transparent.svg.js +0 -45
- package/lib/icons/trash.svg.js +0 -29
- package/lib/icons/tree-down.svg.js +0 -28
- package/lib/icons/undo-normal.svg.js +0 -32
- package/lib/icons/undo.svg.js +0 -28
- package/lib/icons/unfullscreen.svg.js +0 -28
- package/lib/icons/upload.svg.js +0 -28
- package/lib/icons/user-remove.svg.js +0 -40
- package/lib/icons/view.svg.js +0 -29
- package/lib/icons/volume.svg.js +0 -31
- package/lib/icons/warning-mark.svg.js +0 -29
- package/lib/icons/warning.svg.js +0 -28
- package/lib/icons/window-restore.svg.js +0 -28
- package/lib/icons/zoom-in.svg.js +0 -28
- package/lib/icons/zoom-out.svg.js +0 -28
- package/lib/index.d.ts +0 -15
- package/lib/index.js +0 -344
- package/lib/locale/de-DE.d.ts +0 -1
- package/lib/locale/de-DE.js +0 -421
- package/lib/locale/en-US.d.ts +0 -1
- package/lib/locale/en-US.js +0 -427
- package/lib/locale/zh-CN.d.ts +0 -1
- package/lib/locale/zh-CN.js +0 -436
- package/lib/scss/helper.scss.js +0 -12
- package/lib/scss/themes/ang.scss.js +0 -12
- package/lib/scss/themes/antd.scss.js +0 -12
- package/lib/scss/themes/cxd.scss.js +0 -12
- package/lib/scss/themes/dark.scss.js +0 -12
- package/lib/scss/themes/default.scss.js +0 -12
- package/lib/themes/ang.css +0 -46140
- package/lib/themes/ang.d.ts +0 -3
- package/lib/themes/ang.js +0 -20
- package/lib/themes/antd.css +0 -46127
- package/lib/themes/antd.d.ts +0 -1
- package/lib/themes/antd.js +0 -44
- package/lib/themes/cxd.css +0 -46116
- package/lib/themes/cxd.d.ts +0 -3
- package/lib/themes/cxd.js +0 -459
- package/lib/themes/dark.css +0 -46147
- package/lib/themes/dark.d.ts +0 -3
- package/lib/themes/dark.js +0 -28
- package/lib/themes/default.css +0 -46116
- package/lib/themes/default.d.ts +0 -4
- package/lib/utils/index.d.ts +0 -2
- package/lib/utils/smoothSignature.d.ts +0 -86
- package/lib/utils/vectorComputed.d.ts +0 -20
- package/lib/utils/vectorComputed.js +0 -84
- package/lib/withRemoteConfig.d.ts +0 -2
- package/lib/withRemoteConfig.js +0 -14
- package/lib/withStore.d.ts +0 -2
- package/lib/withStore.js +0 -14
package/lib/components/Select.js
DELETED
|
@@ -1,861 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* amis-ui v6.13.0-beta.7
|
|
3
|
-
* Copyright 2018-2025 fex
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
'use strict';
|
|
7
|
-
|
|
8
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
|
-
|
|
10
|
-
var tslib = require('tslib');
|
|
11
|
-
var amisCore = require('amis-core');
|
|
12
|
-
var React = require('react');
|
|
13
|
-
var isInteger = require('lodash/isInteger');
|
|
14
|
-
var omit = require('lodash/omit');
|
|
15
|
-
var merge = require('lodash/merge');
|
|
16
|
-
var index = require('./virtual-list/index.js');
|
|
17
|
-
var TooltipWrapper = require('./TooltipWrapper.js');
|
|
18
|
-
var Downshift = require('downshift');
|
|
19
|
-
var icons = require('./icons.js');
|
|
20
|
-
var matchSorter = require('match-sorter');
|
|
21
|
-
var isPlainObject = require('lodash/isPlainObject');
|
|
22
|
-
var ReactDOM = require('react-dom');
|
|
23
|
-
var Checkbox = require('./Checkbox.js');
|
|
24
|
-
var Input = require('./Input.js');
|
|
25
|
-
var Spinner = require('./Spinner.js');
|
|
26
|
-
var WithRemoteConfig = require('./WithRemoteConfig.js');
|
|
27
|
-
var PopOverContainer = require('./PopOverContainer.js');
|
|
28
|
-
var SelectMobile = require('./SelectMobile.js');
|
|
29
|
-
|
|
30
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
31
|
-
|
|
32
|
-
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
33
|
-
var isInteger__default = /*#__PURE__*/_interopDefaultLegacy(isInteger);
|
|
34
|
-
var omit__default = /*#__PURE__*/_interopDefaultLegacy(omit);
|
|
35
|
-
var merge__default = /*#__PURE__*/_interopDefaultLegacy(merge);
|
|
36
|
-
var Downshift__default = /*#__PURE__*/_interopDefaultLegacy(Downshift);
|
|
37
|
-
var isPlainObject__default = /*#__PURE__*/_interopDefaultLegacy(isPlainObject);
|
|
38
|
-
|
|
39
|
-
var __react_jsx__ = require('react');
|
|
40
|
-
var _J$X_ = (__react_jsx__["default"] || __react_jsx__).createElement;
|
|
41
|
-
(__react_jsx__["default"] || __react_jsx__).Fragment;
|
|
42
|
-
var defaultFilterOption = function (options, inputValue, option) {
|
|
43
|
-
return matchSorter.matchSorter(options, inputValue, tslib.__assign({ threshold: matchSorter.matchSorter.rankings.CONTAINS }, option));
|
|
44
|
-
};
|
|
45
|
-
function value2array(value, props, enableNodePath) {
|
|
46
|
-
if (enableNodePath === void 0) { enableNodePath = false; }
|
|
47
|
-
var labelField = props.labelField, _a = props.valueField, valueField = _a === void 0 ? 'value' : _a, pathSeparator = props.pathSeparator, delimiter = props.delimiter, options = props.options, multi = props.multi, multiple = props.multiple;
|
|
48
|
-
if (enableNodePath) {
|
|
49
|
-
value = amisCore.normalizeNodePath(value, enableNodePath, labelField, valueField, pathSeparator, delimiter).nodeValueArray;
|
|
50
|
-
}
|
|
51
|
-
if (multi || multiple) {
|
|
52
|
-
if (typeof value === 'string') {
|
|
53
|
-
value = value.split(delimiter || ',');
|
|
54
|
-
}
|
|
55
|
-
if (!Array.isArray(value)) {
|
|
56
|
-
if (value === null || value === undefined) {
|
|
57
|
-
return [];
|
|
58
|
-
}
|
|
59
|
-
value = [value];
|
|
60
|
-
}
|
|
61
|
-
return value
|
|
62
|
-
.map(function (value) {
|
|
63
|
-
return expandValue(value, options, valueField) ||
|
|
64
|
-
(amisCore.isObject(value) && value.hasOwnProperty(valueField)
|
|
65
|
-
? value
|
|
66
|
-
: undefined);
|
|
67
|
-
})
|
|
68
|
-
.filter(function (item) { return item; });
|
|
69
|
-
}
|
|
70
|
-
else if (Array.isArray(value)) {
|
|
71
|
-
value = value[0];
|
|
72
|
-
}
|
|
73
|
-
var expandedValue = expandValue(value, options, valueField);
|
|
74
|
-
return expandedValue
|
|
75
|
-
? [expandedValue]
|
|
76
|
-
: amisCore.isObject(value) && value.hasOwnProperty(valueField || 'value')
|
|
77
|
-
? [value]
|
|
78
|
-
: [];
|
|
79
|
-
}
|
|
80
|
-
function expandValue(value, options, valueField) {
|
|
81
|
-
var _a;
|
|
82
|
-
if (valueField === void 0) { valueField = 'value'; }
|
|
83
|
-
var valueType = typeof value;
|
|
84
|
-
if (valueType !== 'string' &&
|
|
85
|
-
valueType !== 'number' &&
|
|
86
|
-
valueType !== 'boolean' &&
|
|
87
|
-
valueType !== 'object') {
|
|
88
|
-
return value;
|
|
89
|
-
}
|
|
90
|
-
if (!options) {
|
|
91
|
-
return null;
|
|
92
|
-
}
|
|
93
|
-
if (valueType === 'object' &&
|
|
94
|
-
value &&
|
|
95
|
-
value.hasOwnProperty(valueField || 'value')) {
|
|
96
|
-
value = (_a = value[valueField || 'value']) !== null && _a !== void 0 ? _a : '';
|
|
97
|
-
}
|
|
98
|
-
return amisCore.findTree(options, optionValueCompare(value, valueField || 'value'), {
|
|
99
|
-
resolve: amisCore.getOptionValueBindField(valueField),
|
|
100
|
-
value: amisCore.getOptionValue(value, valueField)
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
function matchOptionValue(a, b, valueField) {
|
|
104
|
-
if (valueField === void 0) { valueField = 'value'; }
|
|
105
|
-
return amisCore.isObject(a)
|
|
106
|
-
? a === b[valueField || 'value']
|
|
107
|
-
: String(b[valueField || 'value']) === String(a);
|
|
108
|
-
}
|
|
109
|
-
function optionValueCompare(a, valueField) {
|
|
110
|
-
if (valueField === void 0) { valueField = 'value'; }
|
|
111
|
-
return function (b) { return matchOptionValue(a, b, valueField); };
|
|
112
|
-
}
|
|
113
|
-
function normalizeOptions(options, share, valueField) {
|
|
114
|
-
if (share === void 0) { share = {
|
|
115
|
-
values: [],
|
|
116
|
-
options: []
|
|
117
|
-
}; }
|
|
118
|
-
if (valueField === void 0) { valueField = 'value'; }
|
|
119
|
-
if (typeof options === 'string') {
|
|
120
|
-
return options.split(',').map(function (item) {
|
|
121
|
-
var idx = share.values.indexOf(item);
|
|
122
|
-
if (~idx) {
|
|
123
|
-
return share.options[idx];
|
|
124
|
-
}
|
|
125
|
-
var option = {
|
|
126
|
-
label: item,
|
|
127
|
-
value: item
|
|
128
|
-
};
|
|
129
|
-
share.values.push(option.value);
|
|
130
|
-
share.options.push(option);
|
|
131
|
-
return option;
|
|
132
|
-
});
|
|
133
|
-
}
|
|
134
|
-
else if (Array.isArray(options) &&
|
|
135
|
-
typeof options[0] === 'string') {
|
|
136
|
-
return options.map(function (item) {
|
|
137
|
-
var idx = share.values.indexOf(item);
|
|
138
|
-
if (~idx) {
|
|
139
|
-
return share.options[idx];
|
|
140
|
-
}
|
|
141
|
-
var option = {
|
|
142
|
-
label: item,
|
|
143
|
-
value: item
|
|
144
|
-
};
|
|
145
|
-
share.values.push(option.value);
|
|
146
|
-
share.options.push(option);
|
|
147
|
-
return option;
|
|
148
|
-
});
|
|
149
|
-
}
|
|
150
|
-
else if (Array.isArray(options)) {
|
|
151
|
-
return options.map(function (item) {
|
|
152
|
-
var value = item && item[valueField];
|
|
153
|
-
var idx = value !== undefined && !item.children
|
|
154
|
-
? share.values.indexOf(value)
|
|
155
|
-
: -1;
|
|
156
|
-
if (~idx) {
|
|
157
|
-
return share.options[idx];
|
|
158
|
-
}
|
|
159
|
-
var option = tslib.__assign(tslib.__assign({}, item), { value: value });
|
|
160
|
-
if (typeof option.children !== 'undefined') {
|
|
161
|
-
option.children = normalizeOptions(option.children, share, valueField);
|
|
162
|
-
}
|
|
163
|
-
else if (value !== undefined) {
|
|
164
|
-
share.values.push(value);
|
|
165
|
-
share.options.push(option);
|
|
166
|
-
}
|
|
167
|
-
return option;
|
|
168
|
-
});
|
|
169
|
-
}
|
|
170
|
-
else if (isPlainObject__default["default"](options)) {
|
|
171
|
-
return Object.keys(options).map(function (key) {
|
|
172
|
-
var idx = share.values.indexOf(key);
|
|
173
|
-
if (~idx) {
|
|
174
|
-
return share.options[idx];
|
|
175
|
-
}
|
|
176
|
-
var option = {
|
|
177
|
-
label: options[key],
|
|
178
|
-
value: key
|
|
179
|
-
};
|
|
180
|
-
share.values.push(option.value);
|
|
181
|
-
share.options.push(option);
|
|
182
|
-
return option;
|
|
183
|
-
});
|
|
184
|
-
}
|
|
185
|
-
return [];
|
|
186
|
-
}
|
|
187
|
-
var DownshiftChangeTypes = Downshift__default["default"].stateChangeTypes;
|
|
188
|
-
var Select = /** @class */ (function (_super) {
|
|
189
|
-
tslib.__extends(Select, _super);
|
|
190
|
-
function Select(props) {
|
|
191
|
-
var _this = _super.call(this, props) || this;
|
|
192
|
-
_this.menu = React__default["default"].createRef();
|
|
193
|
-
_this.state = {
|
|
194
|
-
isOpen: props.defaultOpen || false,
|
|
195
|
-
isFocused: false,
|
|
196
|
-
inputValue: '',
|
|
197
|
-
highlightedIndex: -1,
|
|
198
|
-
selection: value2array(props.value, props),
|
|
199
|
-
itemHeight: 32 /** Select选项高度保持一致 */,
|
|
200
|
-
pickerSelectItem: ''
|
|
201
|
-
};
|
|
202
|
-
return _this;
|
|
203
|
-
}
|
|
204
|
-
Select.prototype.componentDidMount = function () {
|
|
205
|
-
var loadOptions = this.props.loadOptions;
|
|
206
|
-
loadOptions && loadOptions('');
|
|
207
|
-
};
|
|
208
|
-
Select.prototype.componentDidUpdate = function (prevProps) {
|
|
209
|
-
var props = this.props;
|
|
210
|
-
var fn = amisCore.noop;
|
|
211
|
-
if (JSON.stringify(props.value) !== JSON.stringify(prevProps.value) ||
|
|
212
|
-
JSON.stringify(props.options) !== JSON.stringify(prevProps.options)) {
|
|
213
|
-
var selection = value2array(props.value, props);
|
|
214
|
-
this.setState({
|
|
215
|
-
selection: selection
|
|
216
|
-
}, fn);
|
|
217
|
-
}
|
|
218
|
-
};
|
|
219
|
-
Select.prototype.open = function () {
|
|
220
|
-
var _this = this;
|
|
221
|
-
var _a = this.props, disabled = _a.disabled, loading = _a.loading;
|
|
222
|
-
if (disabled || loading) {
|
|
223
|
-
return;
|
|
224
|
-
}
|
|
225
|
-
this.setState({
|
|
226
|
-
isOpen: true,
|
|
227
|
-
highlightedIndex: -1
|
|
228
|
-
}, function () { return setTimeout(_this.focus, 500); });
|
|
229
|
-
};
|
|
230
|
-
Select.prototype.close = function () {
|
|
231
|
-
this.setState({
|
|
232
|
-
isOpen: false
|
|
233
|
-
});
|
|
234
|
-
};
|
|
235
|
-
Select.prototype.confirm = function () {
|
|
236
|
-
// @ts-ignore
|
|
237
|
-
this.handleChange(this.state.pickerSelectItem);
|
|
238
|
-
this.setState({
|
|
239
|
-
isOpen: false
|
|
240
|
-
});
|
|
241
|
-
};
|
|
242
|
-
Select.prototype.toggle = function (e) {
|
|
243
|
-
var _this = this;
|
|
244
|
-
var _a = this.props, disabled = _a.disabled, loading = _a.loading;
|
|
245
|
-
if ((e &&
|
|
246
|
-
this.menu.current &&
|
|
247
|
-
this.menu.current.contains(e.target)) ||
|
|
248
|
-
disabled ||
|
|
249
|
-
loading) {
|
|
250
|
-
return;
|
|
251
|
-
}
|
|
252
|
-
this.setState({
|
|
253
|
-
isOpen: !this.state.isOpen,
|
|
254
|
-
highlightedIndex: -1
|
|
255
|
-
}, this.state.isOpen ? undefined : function () { return setTimeout(_this.focus, 500); });
|
|
256
|
-
};
|
|
257
|
-
Select.prototype.onFocus = function (e) {
|
|
258
|
-
var _a = this.props, simpleValue = _a.simpleValue, disabled = _a.disabled, loading = _a.loading;
|
|
259
|
-
var _b = this.state, selection = _b.selection, isOpen = _b.isOpen;
|
|
260
|
-
var value = simpleValue ? selection.map(function (item) { return item.value; }) : selection;
|
|
261
|
-
if (!disabled && !loading && !isOpen) {
|
|
262
|
-
this.setState({ isFocused: true }, this.focus);
|
|
263
|
-
}
|
|
264
|
-
this.props.onFocus &&
|
|
265
|
-
this.props.onFocus(tslib.__assign(tslib.__assign({}, e), { value: value }));
|
|
266
|
-
};
|
|
267
|
-
Select.prototype.onBlur = function (e) {
|
|
268
|
-
var simpleValue = this.props.simpleValue;
|
|
269
|
-
var selection = this.state.selection;
|
|
270
|
-
var value = simpleValue ? selection.map(function (item) { return item.value; }) : selection;
|
|
271
|
-
this.setState({
|
|
272
|
-
isFocused: false
|
|
273
|
-
});
|
|
274
|
-
this.props.onBlur &&
|
|
275
|
-
this.props.onBlur(tslib.__assign(tslib.__assign({}, e), { value: value }));
|
|
276
|
-
};
|
|
277
|
-
Select.prototype.focus = function () {
|
|
278
|
-
this.input
|
|
279
|
-
? this.input.focus()
|
|
280
|
-
: this.getTarget() && this.getTarget().focus();
|
|
281
|
-
};
|
|
282
|
-
Select.prototype.blur = function () {
|
|
283
|
-
this.input
|
|
284
|
-
? this.input.blur()
|
|
285
|
-
: this.getTarget() && this.getTarget().blur();
|
|
286
|
-
};
|
|
287
|
-
Select.prototype.getTarget = function () {
|
|
288
|
-
if (!this.target) {
|
|
289
|
-
this.target = ReactDOM.findDOMNode(this);
|
|
290
|
-
}
|
|
291
|
-
return this.target;
|
|
292
|
-
};
|
|
293
|
-
Select.prototype.inputRef = function (ref) {
|
|
294
|
-
this.input = ref;
|
|
295
|
-
};
|
|
296
|
-
Select.prototype.toggleCheckAll = function () {
|
|
297
|
-
var _a = this.props, options = _a.options, onChange = _a.onChange, simpleValue = _a.simpleValue, checkAllBySearch = _a.checkAllBySearch, labelField = _a.labelField, valueField = _a.valueField, _b = _a.filterOption, filterOption = _b === void 0 ? defaultFilterOption : _b;
|
|
298
|
-
var inputValue = this.state.inputValue;
|
|
299
|
-
var selection = this.state.selection;
|
|
300
|
-
var filtedOptions = (inputValue && checkAllBySearch !== false
|
|
301
|
-
? filterOption(options, inputValue, {
|
|
302
|
-
keys: [labelField || 'label', valueField || 'value']
|
|
303
|
-
})
|
|
304
|
-
: options.concat()).filter(function (option) { return option && !option.disabled; });
|
|
305
|
-
var optionsValues = filtedOptions.map(function (option) { return option.value; });
|
|
306
|
-
var selectionValues = selection.map(function (select) { return select.value; });
|
|
307
|
-
var checkedAll = optionsValues.every(function (option) { return selectionValues.indexOf(option) > -1; });
|
|
308
|
-
selection = checkedAll ? [] : filtedOptions;
|
|
309
|
-
onChange(simpleValue ? selection.map(function (item) { return item.value; }) : selection);
|
|
310
|
-
};
|
|
311
|
-
Select.prototype.removeItem = function (index, e) {
|
|
312
|
-
var _a = this.props, onChange = _a.onChange, simpleValue = _a.simpleValue, disabled = _a.disabled;
|
|
313
|
-
if (disabled) {
|
|
314
|
-
return;
|
|
315
|
-
}
|
|
316
|
-
var value = this.state.selection;
|
|
317
|
-
e && e.stopPropagation();
|
|
318
|
-
value = Array.isArray(value) ? value.concat() : [value];
|
|
319
|
-
value.splice(index, 1);
|
|
320
|
-
onChange(simpleValue ? value.map(function (item) { return item.value; }) : value);
|
|
321
|
-
};
|
|
322
|
-
Select.prototype.handleInputChange = function (evt) {
|
|
323
|
-
var _this = this;
|
|
324
|
-
var loadOptions = this.props.loadOptions;
|
|
325
|
-
this.setState({
|
|
326
|
-
inputValue: evt.currentTarget.value
|
|
327
|
-
}, function () { return loadOptions && loadOptions(_this.state.inputValue); });
|
|
328
|
-
};
|
|
329
|
-
Select.prototype.handlePickerChange = function (selectItem, index, confirm) {
|
|
330
|
-
if (!this.props.multiple) {
|
|
331
|
-
selectItem = selectItem[0];
|
|
332
|
-
}
|
|
333
|
-
this.setState({
|
|
334
|
-
pickerSelectItem: selectItem
|
|
335
|
-
});
|
|
336
|
-
// 直接选中选项
|
|
337
|
-
if (confirm) {
|
|
338
|
-
this.handleChange(selectItem);
|
|
339
|
-
}
|
|
340
|
-
};
|
|
341
|
-
/**
|
|
342
|
-
* DownShift中ESC按键动作会触发change事件,此时selectItem为null,需要单独处理,参考:
|
|
343
|
-
* {@link https://github.com/downshift-js/downshift/issues/719 GitHub Issue #719}
|
|
344
|
-
*/
|
|
345
|
-
Select.prototype.handleChange = function (selectItem) {
|
|
346
|
-
var _a = this.props, onChange = _a.onChange, multiple = _a.multiple, simpleValue = _a.simpleValue, valueField = _a.valueField;
|
|
347
|
-
var selection = this.state.selection;
|
|
348
|
-
if (selectItem == null) {
|
|
349
|
-
return;
|
|
350
|
-
}
|
|
351
|
-
if (multiple) {
|
|
352
|
-
var selectionValues = selection.map(function (item) { return item[valueField]; });
|
|
353
|
-
selection = selection.concat();
|
|
354
|
-
var idx = selectionValues.indexOf(selectItem[valueField]);
|
|
355
|
-
if (~idx) {
|
|
356
|
-
selection.splice(idx, 1);
|
|
357
|
-
}
|
|
358
|
-
else {
|
|
359
|
-
selection.push(selectItem);
|
|
360
|
-
}
|
|
361
|
-
onChange(simpleValue ? selection.map(function (item) { return item[valueField]; }) : selection);
|
|
362
|
-
}
|
|
363
|
-
else {
|
|
364
|
-
// Downshift里面的判断修改后的值是否相等时,没有区分是否多选,且用的是!==,所以这里拦截一下
|
|
365
|
-
(!selection.length ||
|
|
366
|
-
selection[0][valueField] !== selectItem[valueField]) &&
|
|
367
|
-
onChange(simpleValue ? selectItem[valueField] : selectItem);
|
|
368
|
-
}
|
|
369
|
-
};
|
|
370
|
-
Select.prototype.handleStateChange = function (changes) {
|
|
371
|
-
var _a = this.props, multiple = _a.multiple, checkAll = _a.checkAll;
|
|
372
|
-
var update = {};
|
|
373
|
-
switch (changes.type) {
|
|
374
|
-
case DownshiftChangeTypes.keyDownEnter:
|
|
375
|
-
case DownshiftChangeTypes.clickItem:
|
|
376
|
-
update = tslib.__assign(tslib.__assign({}, update), { isOpen: multiple ? true : false, isFocused: multiple && checkAll ? true : false });
|
|
377
|
-
break;
|
|
378
|
-
case DownshiftChangeTypes.controlledPropUpdatedSelectedItem:
|
|
379
|
-
break;
|
|
380
|
-
case DownshiftChangeTypes.changeInput:
|
|
381
|
-
update.highlightedIndex = 0;
|
|
382
|
-
break;
|
|
383
|
-
case DownshiftChangeTypes.keyDownArrowDown:
|
|
384
|
-
case DownshiftChangeTypes.keyDownArrowUp:
|
|
385
|
-
case DownshiftChangeTypes.itemMouseEnter:
|
|
386
|
-
update = tslib.__assign(tslib.__assign({}, update), changes);
|
|
387
|
-
break;
|
|
388
|
-
}
|
|
389
|
-
if (Object.keys(update).length) {
|
|
390
|
-
this.setState(update);
|
|
391
|
-
}
|
|
392
|
-
};
|
|
393
|
-
Select.prototype.handleKeyPress = function (e) {
|
|
394
|
-
/**
|
|
395
|
-
* 考虑到label/value中有空格的case
|
|
396
|
-
* 这里使用组合键关闭 win:shift + space,mac:shift + space
|
|
397
|
-
*/
|
|
398
|
-
if (e.key === ' ' && e.shiftKey) {
|
|
399
|
-
this.toggle();
|
|
400
|
-
e.preventDefault();
|
|
401
|
-
}
|
|
402
|
-
};
|
|
403
|
-
Select.prototype.clearValue = function (e) {
|
|
404
|
-
var onChange = this.props.onChange;
|
|
405
|
-
e.preventDefault();
|
|
406
|
-
e.stopPropagation();
|
|
407
|
-
onChange(this.props.resetValue);
|
|
408
|
-
};
|
|
409
|
-
Select.prototype.clearSearchValue = function () {
|
|
410
|
-
var loadOptions = this.props.loadOptions;
|
|
411
|
-
this.setState({
|
|
412
|
-
inputValue: ''
|
|
413
|
-
}, function () { return loadOptions === null || loadOptions === void 0 ? void 0 : loadOptions(''); });
|
|
414
|
-
};
|
|
415
|
-
Select.prototype.handleAddClick = function () {
|
|
416
|
-
var onAdd = this.props.onAdd;
|
|
417
|
-
onAdd && onAdd();
|
|
418
|
-
};
|
|
419
|
-
Select.prototype.handleEditClick = function (e, item) {
|
|
420
|
-
var onEdit = this.props.onEdit;
|
|
421
|
-
e.preventDefault();
|
|
422
|
-
e.stopPropagation();
|
|
423
|
-
onEdit && onEdit(item);
|
|
424
|
-
};
|
|
425
|
-
Select.prototype.handleDeleteClick = function (e, item) {
|
|
426
|
-
var onDelete = this.props.onDelete;
|
|
427
|
-
e.preventDefault();
|
|
428
|
-
e.stopPropagation();
|
|
429
|
-
onDelete && onDelete(item);
|
|
430
|
-
};
|
|
431
|
-
Select.prototype.renderValue = function (_a) {
|
|
432
|
-
var _b;
|
|
433
|
-
var _this = this;
|
|
434
|
-
_a.inputValue; _a.isOpen;
|
|
435
|
-
var _c = this.props, cx = _c.classnames, multiple = _c.multiple, valuesNoWrap = _c.valuesNoWrap, placeholder = _c.placeholder, labelField = _c.labelField, disabled = _c.disabled, maxTagCount = _c.maxTagCount, overflowTagPopover = _c.overflowTagPopover, showInvalidMatch = _c.showInvalidMatch, renderValueLabel = _c.renderValueLabel, popOverContainer = _c.popOverContainer, __ = _c.translate;
|
|
436
|
-
var selection = this.state.selection;
|
|
437
|
-
var labelKey = labelField || 'label';
|
|
438
|
-
if (!selection.length) {
|
|
439
|
-
return (_J$X_("div", { key: "placeholder", className: cx('Select-placeholder') }, __(placeholder)));
|
|
440
|
-
}
|
|
441
|
-
if (multiple &&
|
|
442
|
-
maxTagCount != null &&
|
|
443
|
-
isInteger__default["default"](Math.floor(maxTagCount)) &&
|
|
444
|
-
Math.floor(maxTagCount) >= 0 &&
|
|
445
|
-
Math.floor(maxTagCount) < selection.length) {
|
|
446
|
-
var maxVisibleCount_1 = Math.floor(maxTagCount);
|
|
447
|
-
var tooltipProps_1 = tslib.__assign({ placement: 'top', trigger: 'hover', showArrow: false, offset: [0, -10], tooltipClassName: cx('Select-overflow', overflowTagPopover === null || overflowTagPopover === void 0 ? void 0 : overflowTagPopover.tooltipClassName) }, omit__default["default"](overflowTagPopover, ['children', 'content', 'tooltipClassName']));
|
|
448
|
-
return tslib.__spreadArray(tslib.__spreadArray([], tslib.__read(selection.slice(0, maxVisibleCount_1)), false), [
|
|
449
|
-
(_b = {}, _b[labelKey] = "+ ".concat(selection.length - maxVisibleCount_1, " ..."), _b)
|
|
450
|
-
], false).map(function (item, index) {
|
|
451
|
-
var label = amisCore.labelToString(item[labelKey]);
|
|
452
|
-
if (index === maxVisibleCount_1) {
|
|
453
|
-
return (_J$X_(TooltipWrapper["default"], { key: selection.length, container: popOverContainer, tooltip: tslib.__assign(tslib.__assign({}, tooltipProps_1), { children: function () { return (_J$X_("div", { className: cx('Select-overflow-wrapper') }, selection
|
|
454
|
-
.slice(maxVisibleCount_1, selection.length)
|
|
455
|
-
.map(function (item, index) {
|
|
456
|
-
var itemIndex = index + maxVisibleCount_1;
|
|
457
|
-
var label = amisCore.labelToString(item[labelKey]);
|
|
458
|
-
return (_J$X_("div", { key: itemIndex, className: cx('Select-value', {
|
|
459
|
-
'is-disabled': disabled,
|
|
460
|
-
'is-invalid': showInvalidMatch
|
|
461
|
-
? item.__unmatched
|
|
462
|
-
: false
|
|
463
|
-
}) },
|
|
464
|
-
_J$X_("span", { className: cx('Select-valueLabel') }, renderValueLabel
|
|
465
|
-
? renderValueLabel(item)
|
|
466
|
-
: label),
|
|
467
|
-
_J$X_("span", { className: cx('Select-valueIcon', {
|
|
468
|
-
'is-disabled': disabled || item.disabled
|
|
469
|
-
}), onClick: _this.removeItem.bind(_this, itemIndex) },
|
|
470
|
-
_J$X_(icons.Icon, { icon: "close", className: "icon" }))));
|
|
471
|
-
}))); } }) },
|
|
472
|
-
_J$X_("div", { className: cx('Select-value', {
|
|
473
|
-
'is-disabled': disabled,
|
|
474
|
-
'is-invalid': showInvalidMatch ? item.__unmatched : false
|
|
475
|
-
}), onClick: function (e) {
|
|
476
|
-
return e.stopPropagation();
|
|
477
|
-
} },
|
|
478
|
-
_J$X_("span", { className: cx('Select-valueLabel') }, renderValueLabel ? renderValueLabel(item) : label))));
|
|
479
|
-
}
|
|
480
|
-
return (_J$X_(TooltipWrapper["default"], { container: popOverContainer, placement: 'top', tooltip: label, trigger: 'hover', key: index },
|
|
481
|
-
_J$X_("div", { className: cx('Select-value', {
|
|
482
|
-
'is-disabled': disabled,
|
|
483
|
-
'is-invalid': showInvalidMatch ? item.__unmatched : false
|
|
484
|
-
}) },
|
|
485
|
-
_J$X_("span", { className: cx('Select-valueLabel') }, renderValueLabel ? renderValueLabel(item) : label),
|
|
486
|
-
_J$X_("span", { className: cx('Select-valueIcon', {
|
|
487
|
-
'is-disabled': disabled || item.disabled
|
|
488
|
-
}), onClick: _this.removeItem.bind(_this, index) },
|
|
489
|
-
_J$X_(icons.Icon, { icon: "close", className: "icon" })))));
|
|
490
|
-
});
|
|
491
|
-
}
|
|
492
|
-
return selection.map(function (item, index) {
|
|
493
|
-
var label = amisCore.labelToString(item[labelKey]);
|
|
494
|
-
if (!multiple) {
|
|
495
|
-
return (_J$X_("div", { className: cx('Select-value', {
|
|
496
|
-
'is-disabled': disabled,
|
|
497
|
-
'is-invalid': showInvalidMatch ? item.__unmatched : false
|
|
498
|
-
}), key: index }, renderValueLabel ? renderValueLabel(item) : label));
|
|
499
|
-
}
|
|
500
|
-
return valuesNoWrap ? ("".concat(label).concat(index === selection.length - 1 ? '' : ' + ')) : (_J$X_(TooltipWrapper["default"], { container: popOverContainer, placement: 'top', tooltip: label, trigger: 'hover', key: index },
|
|
501
|
-
_J$X_("div", { className: cx('Select-value', {
|
|
502
|
-
'is-disabled': disabled,
|
|
503
|
-
'is-invalid': showInvalidMatch ? item.__unmatched : false
|
|
504
|
-
}) },
|
|
505
|
-
_J$X_("span", { className: cx('Select-valueLabel') }, renderValueLabel ? renderValueLabel(item) : label),
|
|
506
|
-
_J$X_("span", { className: cx('Select-valueIcon', {
|
|
507
|
-
'is-disabled': disabled || item.disabled
|
|
508
|
-
}), onClick: _this.removeItem.bind(_this, index) },
|
|
509
|
-
_J$X_(icons.Icon, { icon: "close", className: "icon" })))));
|
|
510
|
-
});
|
|
511
|
-
};
|
|
512
|
-
Select.prototype.renderOuter = function (_a) {
|
|
513
|
-
var _this = this;
|
|
514
|
-
var _b;
|
|
515
|
-
var selectedItem = _a.selectedItem, getItemProps = _a.getItemProps, highlightedIndex = _a.highlightedIndex, inputValue = _a.inputValue, isOpen = _a.isOpen; _a.getToggleButtonProps; var getInputProps = _a.getInputProps;
|
|
516
|
-
var _c = this.props, popOverContainer = _c.popOverContainer, options = _c.options, valueField = _c.valueField, labelField = _c.labelField, noResultsText = _c.noResultsText, loadOptions = _c.loadOptions, creatable = _c.creatable, multiple = _c.multiple, valuesNoWrap = _c.valuesNoWrap, cx = _c.classnames, popoverClassName = _c.popoverClassName, popOverContainerSelector = _c.popOverContainerSelector, checkAll = _c.checkAll, checkAllLabel = _c.checkAllLabel, checkAllBySearch = _c.checkAllBySearch, searchable = _c.searchable, createBtnLabel = _c.createBtnLabel, disabled = _c.disabled, searchPromptText = _c.searchPromptText, editable = _c.editable, removable = _c.removable, overlayPlacement = _c.overlayPlacement, __ = _c.translate, hideSelected = _c.hideSelected, renderMenu = _c.renderMenu; _c.mobileClassName; var _d = _c.virtualThreshold, virtualThreshold = _d === void 0 ? 100 : _d, mobileUI = _c.mobileUI, _e = _c.filterOption, filterOption = _e === void 0 ? defaultFilterOption : _e, overlay = _c.overlay, loading = _c.loading, testIdBuilder = _c.testIdBuilder;
|
|
517
|
-
var selection = this.state.selection;
|
|
518
|
-
var checkedAll = false;
|
|
519
|
-
var checkedPartial = false;
|
|
520
|
-
var filtedOptions = (inputValue && isOpen && !loadOptions
|
|
521
|
-
? filterOption(options, inputValue, {
|
|
522
|
-
keys: [labelField || 'label', valueField || 'value']
|
|
523
|
-
})
|
|
524
|
-
: options.concat()).filter(function (option) { return !option.hidden && option.visible !== false; });
|
|
525
|
-
var enableVirtualRender = filtedOptions.length && filtedOptions.length > virtualThreshold;
|
|
526
|
-
var selectionValues = selection.map(function (select) { return select[valueField]; });
|
|
527
|
-
if (multiple && checkAll) {
|
|
528
|
-
var optionsValues = (checkAllBySearch !== false ? filtedOptions : options).map(function (option) { return option[valueField]; });
|
|
529
|
-
checkedAll = optionsValues.every(function (option) { return selectionValues.indexOf(option) > -1; });
|
|
530
|
-
checkedPartial = optionsValues.some(function (option) { return selectionValues.indexOf(option) > -1; });
|
|
531
|
-
}
|
|
532
|
-
// 用于虚拟渲染的每项高度
|
|
533
|
-
var virtualItemHeight = this.props.itemHeight || this.state.itemHeight;
|
|
534
|
-
// 渲染单个选项
|
|
535
|
-
var renderItem = function (_a) {
|
|
536
|
-
var index = _a.index, style = _a.style;
|
|
537
|
-
var item = filtedOptions[index];
|
|
538
|
-
if (!item) {
|
|
539
|
-
return null;
|
|
540
|
-
}
|
|
541
|
-
var checked = selectedItem === item || !!~selectionValues.indexOf(item[valueField]);
|
|
542
|
-
if (hideSelected && checked) {
|
|
543
|
-
return null;
|
|
544
|
-
}
|
|
545
|
-
var label = amisCore.labelToString(item[labelField]);
|
|
546
|
-
var optTestIdBudr = testIdBuilder === null || testIdBuilder === void 0 ? void 0 : testIdBuilder.getChild("option-".concat(label || index));
|
|
547
|
-
return (_J$X_("div", tslib.__assign({}, getItemProps({
|
|
548
|
-
key: typeof item.value === 'string'
|
|
549
|
-
? "".concat(item.label, "-").concat(item.value)
|
|
550
|
-
: index,
|
|
551
|
-
index: index,
|
|
552
|
-
item: item,
|
|
553
|
-
disabled: item.disabled
|
|
554
|
-
}), { style: merge__default["default"](style, enableVirtualRender ? { width: '100%' } : {}), className: cx("Select-option", {
|
|
555
|
-
'is-disabled': item.disabled,
|
|
556
|
-
'is-highlight': highlightedIndex === index,
|
|
557
|
-
'is-active': checked
|
|
558
|
-
}) }, optTestIdBudr === null || optTestIdBudr === void 0 ? void 0 : optTestIdBudr.getTestId()),
|
|
559
|
-
renderMenu ? (multiple ? (_J$X_(Checkbox["default"], { checked: checked, trueValue: item.value, onChange: function () {
|
|
560
|
-
_this.handleChange(item);
|
|
561
|
-
}, disabled: item.disabled, testIdBuilder: optTestIdBudr === null || optTestIdBudr === void 0 ? void 0 : optTestIdBudr.getChild('chekbx'), size: "sm" }, renderMenu(item, {
|
|
562
|
-
multiple: multiple,
|
|
563
|
-
checkAll: checkAll,
|
|
564
|
-
checked: checked,
|
|
565
|
-
onChange: function () { return _this.handleChange(item); },
|
|
566
|
-
inputValue: inputValue || '',
|
|
567
|
-
searchable: searchable,
|
|
568
|
-
index: index
|
|
569
|
-
}))) : (renderMenu(item, {
|
|
570
|
-
multiple: multiple,
|
|
571
|
-
checkAll: checkAll,
|
|
572
|
-
checked: checked,
|
|
573
|
-
onChange: function () { return _this.handleChange(item); },
|
|
574
|
-
inputValue: inputValue || '',
|
|
575
|
-
searchable: searchable,
|
|
576
|
-
index: index
|
|
577
|
-
}))) : multiple ? (_J$X_("div", { title: label, className: cx('Select-option-checkbox') },
|
|
578
|
-
_J$X_(Checkbox["default"], { checked: checked, trueValue: item.value, onChange: function () {
|
|
579
|
-
_this.handleChange(item);
|
|
580
|
-
}, disabled: item.disabled, size: "sm" },
|
|
581
|
-
item.disabled
|
|
582
|
-
? label
|
|
583
|
-
: amisCore.highlight(label, inputValue, cx('Select-option-hl')),
|
|
584
|
-
item.tip ? _J$X_("span", null, item.tip) : null))) : (_J$X_("span", tslib.__assign({ className: cx('Select-option-content'), title: typeof label === 'string' ? label : '' }, optTestIdBudr === null || optTestIdBudr === void 0 ? void 0 : optTestIdBudr.getChild('content').getTestId()),
|
|
585
|
-
item.disabled
|
|
586
|
-
? label
|
|
587
|
-
: amisCore.highlight(label, inputValue, cx('Select-option-hl')),
|
|
588
|
-
item.tip ? _J$X_("span", null, item.tip) : null)),
|
|
589
|
-
editable ? (_J$X_("a", { "data-tooltip": __('Select.edit'), "data-position": "left" },
|
|
590
|
-
_J$X_(icons.Icon, { icon: "pencil", className: "icon", onClick: function (e) { return _this.handleEditClick(e, item); } }))) : null,
|
|
591
|
-
removable ? (_J$X_("a", { "data-tooltip": __('Select.clear'), "data-position": "left" },
|
|
592
|
-
_J$X_(icons.Icon, { icon: "close", className: "icon", onClick: function (e) { return _this.handleDeleteClick(e, item); } }))) : null));
|
|
593
|
-
};
|
|
594
|
-
var menu = (_J$X_("div", { ref: this.menu, className: cx('Select-menu', {
|
|
595
|
-
'Select--longlist': enableVirtualRender,
|
|
596
|
-
'is-mobile': mobileUI
|
|
597
|
-
}) },
|
|
598
|
-
searchable ? (_J$X_("div", { className: cx("Select-input", {
|
|
599
|
-
'is-focused': this.state.isFocused
|
|
600
|
-
}) },
|
|
601
|
-
_J$X_(icons.Icon, { icon: "search", className: "icon" }),
|
|
602
|
-
_J$X_(Input["default"], tslib.__assign({}, getInputProps({
|
|
603
|
-
onFocus: this.onFocus,
|
|
604
|
-
onBlur: this.onBlur,
|
|
605
|
-
disabled: disabled,
|
|
606
|
-
placeholder: __(searchPromptText),
|
|
607
|
-
onChange: this.handleInputChange,
|
|
608
|
-
ref: this.inputRef
|
|
609
|
-
}))),
|
|
610
|
-
(inputValue === null || inputValue === void 0 ? void 0 : inputValue.length) ? (_J$X_("a", { onClick: this.clearSearchValue, className: cx('Select-clear') },
|
|
611
|
-
_J$X_(icons.Icon, { icon: "close", className: "icon" }))) : null)) : null,
|
|
612
|
-
loading ? (_J$X_("div", { className: cx('Select-noResult') }, __('loading'))) : (_J$X_(React__default["default"].Fragment, null,
|
|
613
|
-
multiple && valuesNoWrap ? (_J$X_("div", { className: cx('Select-option') },
|
|
614
|
-
__('Select.selected'),
|
|
615
|
-
"(",
|
|
616
|
-
selectionValues.length,
|
|
617
|
-
")")) : null,
|
|
618
|
-
multiple && checkAll && filtedOptions.length ? (_J$X_("div", { className: cx('Select-option') },
|
|
619
|
-
_J$X_(Checkbox["default"], { checked: checkedPartial, partial: checkedPartial && !checkedAll, onChange: this.toggleCheckAll, size: "sm" }, __(checkAllLabel)))) : null,
|
|
620
|
-
creatable && !disabled ? (_J$X_("a", { className: cx('Select-addBtn'), onClick: this.handleAddClick },
|
|
621
|
-
_J$X_(icons.Icon, { icon: "plus", className: "icon" }),
|
|
622
|
-
__(createBtnLabel))) : null,
|
|
623
|
-
filtedOptions.length ? (filtedOptions.length > virtualThreshold ? ( // 较多数据时才启用 virtuallist,避免滚动条问题
|
|
624
|
-
_J$X_(index["default"], { height: filtedOptions.length > 8
|
|
625
|
-
? 266
|
|
626
|
-
: filtedOptions.length * virtualItemHeight, itemCount: filtedOptions.length, itemSize: virtualItemHeight, renderItem: renderItem })) : (filtedOptions.map(function (item, index) {
|
|
627
|
-
return renderItem({ index: index });
|
|
628
|
-
}))) : (_J$X_("div", { className: cx('Select-noResult') }, __(noResultsText)))))));
|
|
629
|
-
return mobileUI ? (_J$X_(SelectMobile["default"], tslib.__assign({}, this.props, { highlightedIndex: highlightedIndex, isOpen: isOpen, getItemProps: getItemProps, getInputProps: getInputProps, selectedItem: selectedItem, onChange: function (selection) {
|
|
630
|
-
_this.setState({
|
|
631
|
-
isOpen: false
|
|
632
|
-
});
|
|
633
|
-
_this.props.onChange(selection);
|
|
634
|
-
}, onClose: this.close }))) : (_J$X_(amisCore.Overlay, { container: popOverContainer || this.getTarget, containerSelector: popOverContainerSelector, target: this.getTarget, placement: overlayPlacement === 'auto'
|
|
635
|
-
? PopOverContainer.PopOverContainer.alignToPlacement(overlay)
|
|
636
|
-
: overlayPlacement, show: true },
|
|
637
|
-
_J$X_(amisCore.PopOver, { overlay: true, className: cx('Select-popover', popoverClassName), style: {
|
|
638
|
-
width: (overlay &&
|
|
639
|
-
PopOverContainer.PopOverContainer.calcOverlayWidth(overlay, (_b = this.target) === null || _b === void 0 ? void 0 : _b.offsetWidth)) ||
|
|
640
|
-
(this.target ? this.target.offsetWidth : 'auto')
|
|
641
|
-
}, onHide: this.close }, menu)));
|
|
642
|
-
};
|
|
643
|
-
Select.prototype.render = function () {
|
|
644
|
-
var _this = this;
|
|
645
|
-
var _a = this.props, cx = _a.classnames, multiple = _a.multiple, valuesNoWrap = _a.valuesNoWrap, searchable = _a.searchable, inline = _a.inline, block = _a.block, className = _a.className, value = _a.value, loading = _a.loading, clearable = _a.clearable, labelField = _a.labelField, disabled = _a.disabled; _a.checkAll; var borderMode = _a.borderMode, mobileUI = _a.mobileUI, hasError = _a.hasError, testIdBuilder = _a.testIdBuilder, loadingConfig = _a.loadingConfig, controlStyle = _a.controlStyle;
|
|
646
|
-
var selection = this.state.selection;
|
|
647
|
-
var inputValue = this.state.inputValue;
|
|
648
|
-
var resetValue = this.props.resetValue;
|
|
649
|
-
return (_J$X_(Downshift__default["default"], { selectedItem: selection, highlightedIndex: this.state.highlightedIndex, isOpen: this.state.isOpen, inputValue: inputValue, onChange:
|
|
650
|
-
/*展示 Checkbox 的时候,会出发多次 onChange 原因待查*/
|
|
651
|
-
multiple ? amisCore.noop : this.handleChange, onStateChange: this.handleStateChange, itemToString: function (item) {
|
|
652
|
-
return item ? "".concat(amisCore.labelToString(item[labelField])) : '';
|
|
653
|
-
} }, function (options) {
|
|
654
|
-
var _a;
|
|
655
|
-
var isOpen = options.isOpen;
|
|
656
|
-
return (_J$X_("div", tslib.__assign({ tabIndex: disabled ? -1 : 0, onKeyPress: _this.handleKeyPress, onClick: _this.toggle, onFocus: _this.onFocus, onBlur: _this.onBlur }, testIdBuilder === null || testIdBuilder === void 0 ? void 0 : testIdBuilder.getTestId(), { className: cx("Select", (_a = {},
|
|
657
|
-
_a["Select--multi"] = multiple,
|
|
658
|
-
_a["Select--inline"] = inline,
|
|
659
|
-
_a["Select--block"] = block,
|
|
660
|
-
_a["Select--searchable"] = searchable,
|
|
661
|
-
_a['is-opened'] = isOpen,
|
|
662
|
-
_a['is-focused'] = _this.state.isFocused,
|
|
663
|
-
_a['is-disabled'] = disabled || loading,
|
|
664
|
-
_a['is-mobile'] = mobileUI,
|
|
665
|
-
_a['is-error'] = hasError,
|
|
666
|
-
_a["Select--border".concat(amisCore.ucFirst(borderMode))] = borderMode,
|
|
667
|
-
_a), className), "data-amis-name": _this.props.dataName, style: controlStyle }),
|
|
668
|
-
_J$X_("div", { className: cx("Select-valueWrap", {
|
|
669
|
-
'Select-valuesNoWrap': valuesNoWrap
|
|
670
|
-
}) }, _this.renderValue(options)),
|
|
671
|
-
clearable &&
|
|
672
|
-
!disabled &&
|
|
673
|
-
(Array.isArray(value)
|
|
674
|
-
? value.length
|
|
675
|
-
: value != null && value !== resetValue) ? (_J$X_("a", tslib.__assign({ onClick: _this.clearValue, className: cx('Select-clear') }, testIdBuilder === null || testIdBuilder === void 0 ? void 0 : testIdBuilder.getChild('clear').getTestId()),
|
|
676
|
-
_J$X_(icons.Icon, { icon: "input-clear", className: "icon" }))) : null,
|
|
677
|
-
loading ? (_J$X_(Spinner["default"], { show: true, icon: "reload", size: "sm", spinnerClassName: cx('Select-spinner'), loadingConfig: loadingConfig })) : null,
|
|
678
|
-
_J$X_("span", tslib.__assign({ className: cx('Select-arrow') }, testIdBuilder === null || testIdBuilder === void 0 ? void 0 : testIdBuilder.getChild('arrow').getTestId()),
|
|
679
|
-
_J$X_(icons.Icon, { icon: "right-arrow-bold", className: "icon" })),
|
|
680
|
-
isOpen ? _this.renderOuter(options) : null));
|
|
681
|
-
}));
|
|
682
|
-
};
|
|
683
|
-
Select.defaultProps = {
|
|
684
|
-
multiple: false,
|
|
685
|
-
clearable: true,
|
|
686
|
-
creatable: false,
|
|
687
|
-
showInvalidMatch: false,
|
|
688
|
-
createBtnLabel: 'Select.createLabel',
|
|
689
|
-
searchPromptText: 'Select.searchPromptText',
|
|
690
|
-
loadingPlaceholder: 'loading',
|
|
691
|
-
noResultsText: 'noResult',
|
|
692
|
-
clearAllText: 'Select.clearAll',
|
|
693
|
-
clearValueText: 'Select.clear',
|
|
694
|
-
placeholder: 'Select.placeholder',
|
|
695
|
-
valueField: 'value',
|
|
696
|
-
labelField: 'label',
|
|
697
|
-
resetValue: '',
|
|
698
|
-
inline: false,
|
|
699
|
-
disabled: false,
|
|
700
|
-
checkAll: false,
|
|
701
|
-
checkAllLabel: 'Select.checkAll',
|
|
702
|
-
defaultCheckAll: false,
|
|
703
|
-
overlayPlacement: 'auto',
|
|
704
|
-
virtualThreshold: 100
|
|
705
|
-
};
|
|
706
|
-
tslib.__decorate([
|
|
707
|
-
amisCore.autobind,
|
|
708
|
-
tslib.__metadata("design:type", Function),
|
|
709
|
-
tslib.__metadata("design:paramtypes", []),
|
|
710
|
-
tslib.__metadata("design:returntype", void 0)
|
|
711
|
-
], Select.prototype, "open", null);
|
|
712
|
-
tslib.__decorate([
|
|
713
|
-
amisCore.autobind,
|
|
714
|
-
tslib.__metadata("design:type", Function),
|
|
715
|
-
tslib.__metadata("design:paramtypes", []),
|
|
716
|
-
tslib.__metadata("design:returntype", void 0)
|
|
717
|
-
], Select.prototype, "close", null);
|
|
718
|
-
tslib.__decorate([
|
|
719
|
-
amisCore.autobind,
|
|
720
|
-
tslib.__metadata("design:type", Function),
|
|
721
|
-
tslib.__metadata("design:paramtypes", []),
|
|
722
|
-
tslib.__metadata("design:returntype", void 0)
|
|
723
|
-
], Select.prototype, "confirm", null);
|
|
724
|
-
tslib.__decorate([
|
|
725
|
-
amisCore.autobind,
|
|
726
|
-
tslib.__metadata("design:type", Function),
|
|
727
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
728
|
-
tslib.__metadata("design:returntype", void 0)
|
|
729
|
-
], Select.prototype, "toggle", null);
|
|
730
|
-
tslib.__decorate([
|
|
731
|
-
amisCore.autobind,
|
|
732
|
-
tslib.__metadata("design:type", Function),
|
|
733
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
734
|
-
tslib.__metadata("design:returntype", void 0)
|
|
735
|
-
], Select.prototype, "onFocus", null);
|
|
736
|
-
tslib.__decorate([
|
|
737
|
-
amisCore.autobind,
|
|
738
|
-
tslib.__metadata("design:type", Function),
|
|
739
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
740
|
-
tslib.__metadata("design:returntype", void 0)
|
|
741
|
-
], Select.prototype, "onBlur", null);
|
|
742
|
-
tslib.__decorate([
|
|
743
|
-
amisCore.autobind,
|
|
744
|
-
tslib.__metadata("design:type", Function),
|
|
745
|
-
tslib.__metadata("design:paramtypes", []),
|
|
746
|
-
tslib.__metadata("design:returntype", void 0)
|
|
747
|
-
], Select.prototype, "focus", null);
|
|
748
|
-
tslib.__decorate([
|
|
749
|
-
amisCore.autobind,
|
|
750
|
-
tslib.__metadata("design:type", Function),
|
|
751
|
-
tslib.__metadata("design:paramtypes", []),
|
|
752
|
-
tslib.__metadata("design:returntype", void 0)
|
|
753
|
-
], Select.prototype, "getTarget", null);
|
|
754
|
-
tslib.__decorate([
|
|
755
|
-
amisCore.autobind,
|
|
756
|
-
tslib.__metadata("design:type", Function),
|
|
757
|
-
tslib.__metadata("design:paramtypes", [HTMLInputElement]),
|
|
758
|
-
tslib.__metadata("design:returntype", void 0)
|
|
759
|
-
], Select.prototype, "inputRef", null);
|
|
760
|
-
tslib.__decorate([
|
|
761
|
-
amisCore.autobind,
|
|
762
|
-
tslib.__metadata("design:type", Function),
|
|
763
|
-
tslib.__metadata("design:paramtypes", []),
|
|
764
|
-
tslib.__metadata("design:returntype", void 0)
|
|
765
|
-
], Select.prototype, "toggleCheckAll", null);
|
|
766
|
-
tslib.__decorate([
|
|
767
|
-
amisCore.autobind,
|
|
768
|
-
tslib.__metadata("design:type", Function),
|
|
769
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
770
|
-
tslib.__metadata("design:returntype", void 0)
|
|
771
|
-
], Select.prototype, "handleInputChange", null);
|
|
772
|
-
tslib.__decorate([
|
|
773
|
-
amisCore.autobind,
|
|
774
|
-
tslib.__metadata("design:type", Function),
|
|
775
|
-
tslib.__metadata("design:paramtypes", [Object, Number, Boolean]),
|
|
776
|
-
tslib.__metadata("design:returntype", void 0)
|
|
777
|
-
], Select.prototype, "handlePickerChange", null);
|
|
778
|
-
tslib.__decorate([
|
|
779
|
-
amisCore.autobind,
|
|
780
|
-
tslib.__metadata("design:type", Function),
|
|
781
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
782
|
-
tslib.__metadata("design:returntype", void 0)
|
|
783
|
-
], Select.prototype, "handleChange", null);
|
|
784
|
-
tslib.__decorate([
|
|
785
|
-
amisCore.autobind,
|
|
786
|
-
tslib.__metadata("design:type", Function),
|
|
787
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
788
|
-
tslib.__metadata("design:returntype", void 0)
|
|
789
|
-
], Select.prototype, "handleStateChange", null);
|
|
790
|
-
tslib.__decorate([
|
|
791
|
-
amisCore.autobind,
|
|
792
|
-
tslib.__metadata("design:type", Function),
|
|
793
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
794
|
-
tslib.__metadata("design:returntype", void 0)
|
|
795
|
-
], Select.prototype, "handleKeyPress", null);
|
|
796
|
-
tslib.__decorate([
|
|
797
|
-
amisCore.autobind,
|
|
798
|
-
tslib.__metadata("design:type", Function),
|
|
799
|
-
tslib.__metadata("design:paramtypes", [Object]),
|
|
800
|
-
tslib.__metadata("design:returntype", void 0)
|
|
801
|
-
], Select.prototype, "clearValue", null);
|
|
802
|
-
tslib.__decorate([
|
|
803
|
-
amisCore.autobind,
|
|
804
|
-
tslib.__metadata("design:type", Function),
|
|
805
|
-
tslib.__metadata("design:paramtypes", []),
|
|
806
|
-
tslib.__metadata("design:returntype", void 0)
|
|
807
|
-
], Select.prototype, "clearSearchValue", null);
|
|
808
|
-
tslib.__decorate([
|
|
809
|
-
amisCore.autobind,
|
|
810
|
-
tslib.__metadata("design:type", Function),
|
|
811
|
-
tslib.__metadata("design:paramtypes", []),
|
|
812
|
-
tslib.__metadata("design:returntype", void 0)
|
|
813
|
-
], Select.prototype, "handleAddClick", null);
|
|
814
|
-
tslib.__decorate([
|
|
815
|
-
amisCore.autobind,
|
|
816
|
-
tslib.__metadata("design:type", Function),
|
|
817
|
-
tslib.__metadata("design:paramtypes", [Event, Object]),
|
|
818
|
-
tslib.__metadata("design:returntype", void 0)
|
|
819
|
-
], Select.prototype, "handleEditClick", null);
|
|
820
|
-
tslib.__decorate([
|
|
821
|
-
amisCore.autobind,
|
|
822
|
-
tslib.__metadata("design:type", Function),
|
|
823
|
-
tslib.__metadata("design:paramtypes", [Event, Object]),
|
|
824
|
-
tslib.__metadata("design:returntype", void 0)
|
|
825
|
-
], Select.prototype, "handleDeleteClick", null);
|
|
826
|
-
return Select;
|
|
827
|
-
}(React__default["default"].Component));
|
|
828
|
-
var methods = ['focus', 'blur'];
|
|
829
|
-
var EnhancedSelect = amisCore.uncontrollable(amisCore.themeable(amisCore.localeable(Select, methods), methods), {
|
|
830
|
-
value: 'onChange'
|
|
831
|
-
}, methods);
|
|
832
|
-
var SelectWithRemoteOptions = WithRemoteConfig.withRemoteConfig({
|
|
833
|
-
adaptor: function (data) { return data.options || data.items || data.rows || data; },
|
|
834
|
-
normalizeConfig: function (options, origin) {
|
|
835
|
-
options = normalizeOptions(options);
|
|
836
|
-
if (Array.isArray(options)) {
|
|
837
|
-
return options.concat();
|
|
838
|
-
}
|
|
839
|
-
return origin;
|
|
840
|
-
}
|
|
841
|
-
})(/** @class */ (function (_super) {
|
|
842
|
-
tslib.__extends(class_1, _super);
|
|
843
|
-
function class_1() {
|
|
844
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
845
|
-
}
|
|
846
|
-
class_1.prototype.render = function () {
|
|
847
|
-
var _a = this.props, loading = _a.loading, config = _a.config; _a.deferLoad; _a.updateConfig; var rest = tslib.__rest(_a, ["loading", "config", "deferLoad", "updateConfig"]);
|
|
848
|
-
return (_J$X_(EnhancedSelect, tslib.__assign({}, rest, { options: config || rest.options || [], loading: loading })));
|
|
849
|
-
};
|
|
850
|
-
return class_1;
|
|
851
|
-
}(React__default["default"].Component)));
|
|
852
|
-
|
|
853
|
-
exports.Select = Select;
|
|
854
|
-
exports.SelectWithRemoteOptions = SelectWithRemoteOptions;
|
|
855
|
-
exports["default"] = EnhancedSelect;
|
|
856
|
-
exports.defaultFilterOption = defaultFilterOption;
|
|
857
|
-
exports.expandValue = expandValue;
|
|
858
|
-
exports.matchOptionValue = matchOptionValue;
|
|
859
|
-
exports.normalizeOptions = normalizeOptions;
|
|
860
|
-
exports.optionValueCompare = optionValueCompare;
|
|
861
|
-
exports.value2array = value2array;
|