@vtx/components 3.1.96 → 3.1.97
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/lib/_util/filterSpecialCharacters.js +55 -44
- package/lib/_util/filterSpecialCharacters.js.map +1 -1
- package/lib/_util/getComponentProps.js +1 -4
- package/lib/_util/getComponentProps.js.map +1 -1
- package/lib/_util/getToken.js +7 -15
- package/lib/_util/getToken.js.map +1 -1
- package/lib/_util/getUrlParam.js +1 -8
- package/lib/_util/getUrlParam.js.map +1 -1
- package/lib/_util/isFunction.js +0 -1
- package/lib/_util/isFunction.js.map +1 -1
- package/lib/_util/isObject.js +0 -1
- package/lib/_util/isObject.js.map +1 -1
- package/lib/_util/useColSize.js +2 -12
- package/lib/_util/useColSize.js.map +1 -1
- package/lib/_util/useInterval.js +0 -3
- package/lib/_util/useInterval.js.map +1 -1
- package/lib/_util/useSet.js +23 -39
- package/lib/_util/useSet.js.map +1 -1
- package/lib/config.js +1 -2
- package/lib/config.js.map +1 -1
- package/lib/index.js +0 -29
- package/lib/index.js.map +1 -1
- package/lib/style/index.less +2 -2
- package/lib/style/themes/compact.less +1 -1
- package/lib/style/themes/dark.less +9 -9
- package/lib/style/themes/default.less +7 -7
- package/lib/style/themes/index.less +1 -1
- package/lib/style/themes/variable.less +5 -5
- package/lib/vtx-color-picker/index.js +9 -26
- package/lib/vtx-color-picker/index.js.map +1 -1
- package/lib/vtx-color-picker/style/css.js +0 -2
- package/lib/vtx-color-picker/style/css.js.map +1 -1
- package/lib/vtx-color-picker/style/index.js +0 -2
- package/lib/vtx-color-picker/style/index.js.map +1 -1
- package/lib/vtx-combogrid/Combogrid.js +46 -86
- package/lib/vtx-combogrid/Combogrid.js.map +1 -1
- package/lib/vtx-combogrid/index.js +32 -58
- package/lib/vtx-combogrid/index.js.map +1 -1
- package/lib/vtx-combogrid/style/css.js +0 -7
- package/lib/vtx-combogrid/style/css.js.map +1 -1
- package/lib/vtx-combogrid/style/index.js +0 -7
- package/lib/vtx-combogrid/style/index.js.map +1 -1
- package/lib/vtx-datagrid/Alert.js +5 -14
- package/lib/vtx-datagrid/Alert.js.map +1 -1
- package/lib/vtx-datagrid/ColumnSetting.js +37 -76
- package/lib/vtx-datagrid/ColumnSetting.js.map +1 -1
- package/lib/vtx-datagrid/ResizeableTitle.js +3 -15
- package/lib/vtx-datagrid/ResizeableTitle.js.map +1 -1
- package/lib/vtx-datagrid/index.js +117 -188
- package/lib/vtx-datagrid/index.js.map +1 -1
- package/lib/vtx-datagrid/renderColumnButtons.js +7 -38
- package/lib/vtx-datagrid/renderColumnButtons.js.map +1 -1
- package/lib/vtx-datagrid/style/css.js +0 -10
- package/lib/vtx-datagrid/style/css.js.map +1 -1
- package/lib/vtx-datagrid/style/index.js +0 -10
- package/lib/vtx-datagrid/style/index.js.map +1 -1
- package/lib/vtx-date-picker/QdatePicker.js +21 -51
- package/lib/vtx-date-picker/QdatePicker.js.map +1 -1
- package/lib/vtx-date-picker/generatePicker.js +24 -65
- package/lib/vtx-date-picker/generatePicker.js.map +1 -1
- package/lib/vtx-date-picker/index.js +1 -7
- package/lib/vtx-date-picker/index.js.map +1 -1
- package/lib/vtx-date-picker/style/css.js +0 -1
- package/lib/vtx-date-picker/style/css.js.map +1 -1
- package/lib/vtx-date-picker/style/index.js +0 -1
- package/lib/vtx-date-picker/style/index.js.map +1 -1
- package/lib/vtx-date-picker/style/index.less +39 -39
- package/lib/vtx-editor/index.js +9 -28
- package/lib/vtx-editor/index.js.map +1 -1
- package/lib/vtx-editor/style/css.js +0 -1
- package/lib/vtx-editor/style/css.js.map +1 -1
- package/lib/vtx-editor/style/index.js +0 -1
- package/lib/vtx-editor/style/index.js.map +1 -1
- package/lib/vtx-editor/style/index.less +8 -8
- package/lib/vtx-ellipsis-text/index.js +14 -27
- package/lib/vtx-ellipsis-text/index.js.map +1 -1
- package/lib/vtx-ellipsis-text/style/css.js +0 -1
- package/lib/vtx-ellipsis-text/style/css.js.map +1 -1
- package/lib/vtx-ellipsis-text/style/index.js +0 -1
- package/lib/vtx-ellipsis-text/style/index.js.map +1 -1
- package/lib/vtx-ellipsis-text/style/index.less +13 -13
- package/lib/vtx-export/index.js +36 -69
- package/lib/vtx-export/index.js.map +1 -1
- package/lib/vtx-export/style/css.js +0 -5
- package/lib/vtx-export/style/css.js.map +1 -1
- package/lib/vtx-export/style/index.js +0 -5
- package/lib/vtx-export/style/index.js.map +1 -1
- package/lib/vtx-export-async/History.js +59 -100
- package/lib/vtx-export-async/History.js.map +1 -1
- package/lib/vtx-export-async/index.js +64 -105
- package/lib/vtx-export-async/index.js.map +1 -1
- package/lib/vtx-export-async/style/css.js.map +1 -1
- package/lib/vtx-export-async/style/index.js.map +1 -1
- package/lib/vtx-export-async/util.js +2 -13
- package/lib/vtx-export-async/util.js.map +1 -1
- package/lib/vtx-form-layout/Card.js +11 -33
- package/lib/vtx-form-layout/Card.js.map +1 -1
- package/lib/vtx-form-layout/Divider.js +5 -11
- package/lib/vtx-form-layout/Divider.js.map +1 -1
- package/lib/vtx-form-layout/FormItem.js +12 -34
- package/lib/vtx-form-layout/FormItem.js.map +1 -1
- package/lib/vtx-form-layout/Pane.js +3 -9
- package/lib/vtx-form-layout/Pane.js.map +1 -1
- package/lib/vtx-form-layout/Row.js +1 -8
- package/lib/vtx-form-layout/Row.js.map +1 -1
- package/lib/vtx-form-layout/context.js +1 -4
- package/lib/vtx-form-layout/context.js.map +1 -1
- package/lib/vtx-form-layout/demo/Modal.less +43 -43
- package/lib/vtx-form-layout/index.js +9 -24
- package/lib/vtx-form-layout/index.js.map +1 -1
- package/lib/vtx-form-layout/style/css.js +0 -7
- package/lib/vtx-form-layout/style/css.js.map +1 -1
- package/lib/vtx-form-layout/style/index.js +0 -7
- package/lib/vtx-form-layout/style/index.js.map +1 -1
- package/lib/vtx-form-layout/style/index.less +216 -216
- package/lib/vtx-image/Image.js +73 -113
- package/lib/vtx-image/Image.js.map +1 -1
- package/lib/vtx-image/Preview.js +30 -59
- package/lib/vtx-image/Preview.js.map +1 -1
- package/lib/vtx-image/PreviewGroup.js +17 -47
- package/lib/vtx-image/PreviewGroup.js.map +1 -1
- package/lib/vtx-image/index.js +4 -11
- package/lib/vtx-image/index.js.map +1 -1
- package/lib/vtx-image/style/css.js +0 -1
- package/lib/vtx-image/style/css.js.map +1 -1
- package/lib/vtx-image/style/index.js +0 -1
- package/lib/vtx-image/style/index.js.map +1 -1
- package/lib/vtx-import/index.js +45 -78
- package/lib/vtx-import/index.js.map +1 -1
- package/lib/vtx-import/result.js +10 -28
- package/lib/vtx-import/result.js.map +1 -1
- package/lib/vtx-import/style/css.js +0 -3
- package/lib/vtx-import/style/css.js.map +1 -1
- package/lib/vtx-import/style/index.js +0 -3
- package/lib/vtx-import/style/index.js.map +1 -1
- package/lib/vtx-import/style/index.less +8 -8
- package/lib/vtx-import2/CheckResult.js +1 -8
- package/lib/vtx-import2/CheckResult.js.map +1 -1
- package/lib/vtx-import2/Content.js +11 -33
- package/lib/vtx-import2/Content.js.map +1 -1
- package/lib/vtx-import2/DownloadSvg.js +1 -6
- package/lib/vtx-import2/DownloadSvg.js.map +1 -1
- package/lib/vtx-import2/ImportResult.js +7 -14
- package/lib/vtx-import2/ImportResult.js.map +1 -1
- package/lib/vtx-import2/UploadSvg.js +1 -6
- package/lib/vtx-import2/UploadSvg.js.map +1 -1
- package/lib/vtx-import2/index.js +51 -107
- package/lib/vtx-import2/index.js.map +1 -1
- package/lib/vtx-import2/style/css.js +0 -3
- package/lib/vtx-import2/style/css.js.map +1 -1
- package/lib/vtx-import2/style/index.js +0 -3
- package/lib/vtx-import2/style/index.js.map +1 -1
- package/lib/vtx-import2/style/index.less +102 -102
- package/lib/vtx-input/TextArea.js +10 -27
- package/lib/vtx-input/TextArea.js.map +1 -1
- package/lib/vtx-input/index.js +20 -45
- package/lib/vtx-input/index.js.map +1 -1
- package/lib/vtx-input/style/css.js +0 -1
- package/lib/vtx-input/style/css.js.map +1 -1
- package/lib/vtx-input/style/index.js +0 -1
- package/lib/vtx-input/style/index.js.map +1 -1
- package/lib/vtx-input/style/index.less +24 -24
- package/lib/vtx-input/useLength.js +7 -20
- package/lib/vtx-input/useLength.js.map +1 -1
- package/lib/vtx-modal/Title.js +2 -8
- package/lib/vtx-modal/Title.js.map +1 -1
- package/lib/vtx-modal/index.js +49 -82
- package/lib/vtx-modal/index.js.map +1 -1
- package/lib/vtx-modal/style/css.js +0 -1
- package/lib/vtx-modal/style/css.js.map +1 -1
- package/lib/vtx-modal/style/index.js +0 -1
- package/lib/vtx-modal/style/index.js.map +1 -1
- package/lib/vtx-page-layout/Basic.js +3 -8
- package/lib/vtx-page-layout/Basic.js.map +1 -1
- package/lib/vtx-page-layout/Content.js +15 -26
- package/lib/vtx-page-layout/Content.js.map +1 -1
- package/lib/vtx-page-layout/Pane.js +3 -12
- package/lib/vtx-page-layout/Pane.js.map +1 -1
- package/lib/vtx-page-layout/TableLayout.js +30 -60
- package/lib/vtx-page-layout/TableLayout.js.map +1 -1
- package/lib/vtx-page-layout/TableWrap.js +11 -22
- package/lib/vtx-page-layout/TableWrap.js.map +1 -1
- package/lib/vtx-page-layout/container.js +23 -51
- package/lib/vtx-page-layout/container.js.map +1 -1
- package/lib/vtx-page-layout/index.js +1 -10
- package/lib/vtx-page-layout/index.js.map +1 -1
- package/lib/vtx-page-layout/style/css.js.map +1 -1
- package/lib/vtx-page-layout/style/index.js.map +1 -1
- package/lib/vtx-page-layout/style/index.less +138 -138
- package/lib/vtx-rps-frame/index.js +37 -57
- package/lib/vtx-rps-frame/index.js.map +1 -1
- package/lib/vtx-rps-frame/style/css.js.map +1 -1
- package/lib/vtx-rps-frame/style/index.js.map +1 -1
- package/lib/vtx-scrollable-row/index.js +30 -64
- package/lib/vtx-scrollable-row/index.js.map +1 -1
- package/lib/vtx-scrollable-row/style/css.js.map +1 -1
- package/lib/vtx-scrollable-row/style/index.js.map +1 -1
- package/lib/vtx-scrollable-row/style/index.less +113 -113
- package/lib/vtx-search/VtxCol.js +7 -26
- package/lib/vtx-search/VtxCol.js.map +1 -1
- package/lib/vtx-search/VtxRow.js +7 -14
- package/lib/vtx-search/VtxRow.js.map +1 -1
- package/lib/vtx-search/index.js +61 -106
- package/lib/vtx-search/index.js.map +1 -1
- package/lib/vtx-search/style/css.js +0 -4
- package/lib/vtx-search/style/css.js.map +1 -1
- package/lib/vtx-search/style/index.js +0 -4
- package/lib/vtx-search/style/index.js.map +1 -1
- package/lib/vtx-search-map-input/index.js +58 -93
- package/lib/vtx-search-map-input/index.js.map +1 -1
- package/lib/vtx-search-map-input/style/css.js +0 -2
- package/lib/vtx-search-map-input/style/css.js.map +1 -1
- package/lib/vtx-search-map-input/style/index.js +0 -2
- package/lib/vtx-search-map-input/style/index.js.map +1 -1
- package/lib/vtx-select/index.js +39 -91
- package/lib/vtx-select/index.js.map +1 -1
- package/lib/vtx-select/style/css.js +0 -8
- package/lib/vtx-select/style/css.js.map +1 -1
- package/lib/vtx-select/style/index.js +0 -8
- package/lib/vtx-select/style/index.js.map +1 -1
- package/lib/vtx-select/style/index.less +68 -68
- package/lib/vtx-signature/index.js +18 -33
- package/lib/vtx-signature/index.js.map +1 -1
- package/lib/vtx-signature/style/css.js +0 -2
- package/lib/vtx-signature/style/css.js.map +1 -1
- package/lib/vtx-signature/style/index.js +0 -2
- package/lib/vtx-signature/style/index.js.map +1 -1
- package/lib/vtx-signature/style/index.less +33 -33
- package/lib/vtx-split-pane/Pane.js +11 -22
- package/lib/vtx-split-pane/Pane.js.map +1 -1
- package/lib/vtx-split-pane/Resizer.js +19 -39
- package/lib/vtx-split-pane/Resizer.js.map +1 -1
- package/lib/vtx-split-pane/SplitPane.js +51 -107
- package/lib/vtx-split-pane/SplitPane.js.map +1 -1
- package/lib/vtx-split-pane/index.js +1 -6
- package/lib/vtx-split-pane/index.js.map +1 -1
- package/lib/vtx-split-pane/style/css.js +0 -3
- package/lib/vtx-split-pane/style/css.js.map +1 -1
- package/lib/vtx-split-pane/style/index.js +0 -3
- package/lib/vtx-split-pane/style/index.js.map +1 -1
- package/lib/vtx-split-pane/style/index.less +76 -76
- package/lib/vtx-statistics-column/Back.js +2 -9
- package/lib/vtx-statistics-column/Back.js.map +1 -1
- package/lib/vtx-statistics-column/Item.js +14 -30
- package/lib/vtx-statistics-column/Item.js.map +1 -1
- package/lib/vtx-statistics-column/Total.js +14 -30
- package/lib/vtx-statistics-column/Total.js.map +1 -1
- package/lib/vtx-statistics-column/context.js +1 -4
- package/lib/vtx-statistics-column/context.js.map +1 -1
- package/lib/vtx-statistics-column/index.js +1 -18
- package/lib/vtx-statistics-column/index.js.map +1 -1
- package/lib/vtx-statistics-column/style/css.js +0 -1
- package/lib/vtx-statistics-column/style/css.js.map +1 -1
- package/lib/vtx-statistics-column/style/index.js +0 -1
- package/lib/vtx-statistics-column/style/index.js.map +1 -1
- package/lib/vtx-statistics-column/style/index.less +59 -59
- package/lib/vtx-time-picker/index.js +4 -18
- package/lib/vtx-time-picker/index.js.map +1 -1
- package/lib/vtx-time-picker/style/css.js.map +1 -1
- package/lib/vtx-time-picker/style/index.js.map +1 -1
- package/lib/vtx-tree/index.js +49 -114
- package/lib/vtx-tree/index.js.map +1 -1
- package/lib/vtx-tree/style/css.js +0 -2
- package/lib/vtx-tree/style/css.js.map +1 -1
- package/lib/vtx-tree/style/index.js +0 -2
- package/lib/vtx-tree/style/index.js.map +1 -1
- package/lib/vtx-tree/utils.js +6 -27
- package/lib/vtx-tree/utils.js.map +1 -1
- package/lib/vtx-tree-select/index.js +27 -71
- package/lib/vtx-tree-select/index.js.map +1 -1
- package/lib/vtx-tree-select/style/css.js +0 -3
- package/lib/vtx-tree-select/style/css.js.map +1 -1
- package/lib/vtx-tree-select/style/index.js +0 -3
- package/lib/vtx-tree-select/style/index.js.map +1 -1
- package/lib/vtx-upload/FilePreview.js +15 -33
- package/lib/vtx-upload/FilePreview.js.map +1 -1
- package/lib/vtx-upload/index.js +79 -156
- package/lib/vtx-upload/index.js.map +1 -1
- package/lib/vtx-upload/style/css.js +0 -6
- package/lib/vtx-upload/style/css.js.map +1 -1
- package/lib/vtx-upload/style/index.js +0 -6
- package/lib/vtx-upload/style/index.js.map +1 -1
- package/lib/vtx-upload/style/index.less +61 -61
- package/lib/vtx-wang-editor/index.js +74 -116
- package/lib/vtx-wang-editor/index.js.map +1 -1
- package/lib/vtx-wang-editor/style/css.js +0 -1
- package/lib/vtx-wang-editor/style/css.js.map +1 -1
- package/lib/vtx-wang-editor/style/index.js +0 -1
- package/lib/vtx-wang-editor/style/index.js.map +1 -1
- package/lib/vtx-wang-editor/style/index.less +12 -12
- package/lib/vtx-wang-editor/wangEditorUtil.js +75 -136
- package/lib/vtx-wang-editor/wangEditorUtil.js.map +1 -1
- package/lib/vtx-ztree/index.js +69 -119
- package/lib/vtx-ztree/index.js.map +1 -1
- package/lib/vtx-ztree/style/css.js +0 -1
- package/lib/vtx-ztree/style/css.js.map +1 -1
- package/lib/vtx-ztree/style/index.js +0 -1
- package/lib/vtx-ztree/style/index.js.map +1 -1
- package/lib/vtx-ztree/style/index.less +45 -45
- package/lib/vtx-ztree-select/index.js +74 -142
- package/lib/vtx-ztree-select/index.js.map +1 -1
- package/lib/vtx-ztree-select/style/css.js +0 -3
- package/lib/vtx-ztree-select/style/css.js.map +1 -1
- package/lib/vtx-ztree-select/style/index.js +0 -3
- package/lib/vtx-ztree-select/style/index.js.map +1 -1
- package/lib/vtx-ztree-select/style/index.less +109 -109
- package/package.json +121 -121
|
@@ -1,97 +1,55 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(
|
|
4
|
-
|
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports["default"] = void 0;
|
|
9
|
-
|
|
10
8
|
var _react = _interopRequireDefault(require("react"));
|
|
11
|
-
|
|
12
9
|
var _popover = _interopRequireDefault(require("antd/lib/popover"));
|
|
13
|
-
|
|
14
10
|
var _input = _interopRequireDefault(require("antd/lib/input"));
|
|
15
|
-
|
|
16
11
|
var _tag = _interopRequireDefault(require("antd/lib/tag"));
|
|
17
|
-
|
|
18
12
|
var _CloseCircleFilled = _interopRequireDefault(require("@ant-design/icons/CloseCircleFilled"));
|
|
19
|
-
|
|
20
13
|
var _DownOutlined = _interopRequireDefault(require("@ant-design/icons/DownOutlined"));
|
|
21
|
-
|
|
22
14
|
var _lodash = _interopRequireDefault(require("lodash.isequal"));
|
|
23
|
-
|
|
24
15
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
25
|
-
|
|
26
16
|
var _classnames2 = _interopRequireDefault(require("classnames"));
|
|
27
|
-
|
|
28
17
|
var _vtxZtree = _interopRequireDefault(require("../vtx-ztree"));
|
|
29
|
-
|
|
30
18
|
var _icons = require("@ant-design/icons");
|
|
31
|
-
|
|
32
19
|
var _button = _interopRequireDefault(require("antd/lib/button"));
|
|
33
|
-
|
|
34
20
|
var _empty = _interopRequireDefault(require("antd/lib/empty"));
|
|
35
|
-
|
|
36
21
|
var _excluded = ["children"];
|
|
37
|
-
|
|
38
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
39
|
-
|
|
40
23
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
41
|
-
|
|
42
24
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
43
|
-
|
|
44
25
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
45
|
-
|
|
46
26
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
47
|
-
|
|
48
27
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
49
|
-
|
|
50
28
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
51
|
-
|
|
52
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
53
|
-
|
|
29
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
54
30
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
55
|
-
|
|
56
31
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
57
|
-
|
|
58
|
-
function
|
|
59
|
-
|
|
60
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
61
|
-
|
|
62
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
63
|
-
|
|
32
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
33
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
34
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
64
35
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
65
|
-
|
|
66
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
67
|
-
|
|
36
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
68
37
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
69
|
-
|
|
70
|
-
function
|
|
71
|
-
|
|
72
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
73
|
-
|
|
74
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
75
|
-
|
|
38
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
39
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
40
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
76
41
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
77
|
-
|
|
78
42
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
79
|
-
|
|
80
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
81
|
-
|
|
43
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
82
44
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
83
|
-
|
|
84
|
-
|
|
45
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
46
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
47
|
+
var VtxZtreeSelect = exports["default"] = /*#__PURE__*/function (_React$Component) {
|
|
85
48
|
_inherits(VtxZtreeSelect, _React$Component);
|
|
86
|
-
|
|
87
|
-
var _super = _createSuper(VtxZtreeSelect);
|
|
88
|
-
|
|
89
49
|
function VtxZtreeSelect(props) {
|
|
90
50
|
var _this;
|
|
91
|
-
|
|
92
51
|
_classCallCheck(this, VtxZtreeSelect);
|
|
93
|
-
|
|
94
|
-
_this = _super.call(this, props);
|
|
52
|
+
_this = _callSuper(this, VtxZtreeSelect, [props]);
|
|
95
53
|
_this.tree = null;
|
|
96
54
|
_this.treeRefreshFlag = 1;
|
|
97
55
|
_this.state = {
|
|
@@ -101,16 +59,16 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
101
59
|
inputRef: null
|
|
102
60
|
};
|
|
103
61
|
_this.keyNodesMapping = {};
|
|
104
|
-
|
|
105
62
|
_this.getKeyNodesMapping();
|
|
106
|
-
|
|
107
63
|
_this.TextEnum = _objectSpread({
|
|
108
64
|
alreadyChooseText: '已选择',
|
|
109
65
|
clearChoosedOptionsText: '清空已选项',
|
|
110
66
|
emptyDescriptionText: '暂无数据'
|
|
111
67
|
}, props.customEnumText || {});
|
|
112
68
|
return _this;
|
|
113
|
-
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// UNSAFE_componentWillReceiveProps(nextProps) {
|
|
114
72
|
// if (!isEqual(this.props.data, nextProps.data)) {
|
|
115
73
|
// this.getKeyNodesMapping(nextProps.data);
|
|
116
74
|
// }
|
|
@@ -118,16 +76,14 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
118
76
|
// this.treeRefreshFlag++;
|
|
119
77
|
// }
|
|
120
78
|
// }
|
|
121
|
-
// 替换componentWillReceiveProps
|
|
122
|
-
|
|
123
79
|
|
|
80
|
+
// 替换componentWillReceiveProps
|
|
124
81
|
_createClass(VtxZtreeSelect, [{
|
|
125
82
|
key: "componentDidUpdate",
|
|
126
83
|
value: function componentDidUpdate(prevProps) {
|
|
127
84
|
if (!(0, _lodash["default"])(this.props.data, prevProps.data)) {
|
|
128
85
|
this.getKeyNodesMapping(this.props.data);
|
|
129
86
|
}
|
|
130
|
-
|
|
131
87
|
if (!(0, _lodash["default"])(this.props.expandedKeys, prevProps.expandedKeys)) {
|
|
132
88
|
this.treeRefreshFlag++;
|
|
133
89
|
}
|
|
@@ -137,14 +93,11 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
137
93
|
value: function getKeyNodesMapping(nodes) {
|
|
138
94
|
var t = this;
|
|
139
95
|
t.keyNodesMapping = {};
|
|
140
|
-
|
|
141
96
|
(function genNodes(nodes) {
|
|
142
97
|
nodes.map(function (item) {
|
|
143
98
|
var children = item.children,
|
|
144
|
-
|
|
145
|
-
|
|
99
|
+
rest = _objectWithoutProperties(item, _excluded);
|
|
146
100
|
t.keyNodesMapping[item.key] = rest;
|
|
147
|
-
|
|
148
101
|
if (Array.isArray(children) && children.length > 0) {
|
|
149
102
|
genNodes(children);
|
|
150
103
|
}
|
|
@@ -163,38 +116,31 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
163
116
|
this.tree.cancelSelectedNodes(this.props.value);
|
|
164
117
|
}
|
|
165
118
|
}
|
|
166
|
-
|
|
167
119
|
this.props.onChange && this.props.onChange({
|
|
168
120
|
nodes: [],
|
|
169
121
|
keys: [],
|
|
170
122
|
leafKeys: [],
|
|
171
123
|
names: []
|
|
172
124
|
});
|
|
173
|
-
|
|
174
125
|
if (this.tree) {
|
|
175
126
|
var _this$tree;
|
|
176
|
-
|
|
177
127
|
this.setState({
|
|
178
128
|
searchValue: ''
|
|
179
129
|
});
|
|
180
|
-
(_this$tree = this.tree) === null || _this$tree === void 0
|
|
130
|
+
(_this$tree = this.tree) === null || _this$tree === void 0 || _this$tree.fuzzySearch('');
|
|
181
131
|
}
|
|
182
132
|
}
|
|
183
133
|
}, {
|
|
184
134
|
key: "clearKey",
|
|
185
135
|
value: function clearKey(key) {
|
|
186
136
|
var _this2 = this;
|
|
187
|
-
|
|
188
137
|
var keyIndex = this.props.value.indexOf(key);
|
|
189
|
-
|
|
190
138
|
if (keyIndex != -1) {
|
|
191
139
|
var keyList = _toConsumableArray(this.props.value);
|
|
192
|
-
|
|
193
140
|
keyList.splice(keyIndex, 1);
|
|
194
141
|
var nodes = keyList.map(function (key) {
|
|
195
142
|
return _this2.keyNodesMapping[key];
|
|
196
143
|
});
|
|
197
|
-
|
|
198
144
|
if (this.tree) {
|
|
199
145
|
if (this.props.treeCheckable) {
|
|
200
146
|
this.tree.checkNodes([key], false);
|
|
@@ -202,7 +148,6 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
202
148
|
this.tree.cancelSelectedNodes([key]);
|
|
203
149
|
}
|
|
204
150
|
}
|
|
205
|
-
|
|
206
151
|
this.props.onChange && this.props.onChange({
|
|
207
152
|
nodes: nodes,
|
|
208
153
|
keys: keyList,
|
|
@@ -225,42 +170,41 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
225
170
|
}, {
|
|
226
171
|
key: "render",
|
|
227
172
|
value: function render() {
|
|
228
|
-
var _data
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
173
|
+
var _data$;
|
|
174
|
+
var t = this;
|
|
175
|
+
// 必填参数
|
|
232
176
|
var _t$props = t.props,
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
177
|
+
data = _t$props.data,
|
|
178
|
+
value = _t$props.value;
|
|
179
|
+
// 可配参数
|
|
236
180
|
var _t$props2 = t.props,
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
181
|
+
_t$props2$prefixCls = _t$props2.prefixCls,
|
|
182
|
+
prefixCls = _t$props2$prefixCls === void 0 ? 'vtx-ztree-select' : _t$props2$prefixCls,
|
|
183
|
+
_t$props2$treeCheckab = _t$props2.treeCheckable,
|
|
184
|
+
treeCheckable = _t$props2$treeCheckab === void 0 ? false : _t$props2$treeCheckab,
|
|
185
|
+
_t$props2$treeDefault = _t$props2.treeDefaultExpandAll,
|
|
186
|
+
treeDefaultExpandAll = _t$props2$treeDefault === void 0 ? false : _t$props2$treeDefault,
|
|
187
|
+
_t$props2$multiple = _t$props2.multiple,
|
|
188
|
+
multiple = _t$props2$multiple === void 0 ? false : _t$props2$multiple,
|
|
189
|
+
_t$props2$showSearch = _t$props2.showSearch,
|
|
190
|
+
showSearch = _t$props2$showSearch === void 0 ? true : _t$props2$showSearch,
|
|
191
|
+
searchPlaceholder = _t$props2.searchPlaceholder,
|
|
192
|
+
_t$props2$dropdownSty = _t$props2.dropdownStyle,
|
|
193
|
+
dropdownStyle = _t$props2$dropdownSty === void 0 ? {} : _t$props2$dropdownSty,
|
|
194
|
+
_t$props2$style = _t$props2.style,
|
|
195
|
+
style = _t$props2$style === void 0 ? {} : _t$props2$style,
|
|
196
|
+
_t$props2$disabled = _t$props2.disabled,
|
|
197
|
+
disabled = _t$props2$disabled === void 0 ? false : _t$props2$disabled,
|
|
198
|
+
_t$props2$refreshFlag = _t$props2.refreshFlag,
|
|
199
|
+
refreshFlag = _t$props2$refreshFlag === void 0 ? null : _t$props2$refreshFlag,
|
|
200
|
+
expandedKeys = _t$props2.expandedKeys,
|
|
201
|
+
customCfg = _t$props2.customCfg,
|
|
202
|
+
checkStrictly = _t$props2.checkStrictly,
|
|
203
|
+
_t$props2$popoverProp = _t$props2.popoverProps,
|
|
204
|
+
popoverProps = _t$props2$popoverProp === void 0 ? {} : _t$props2$popoverProp,
|
|
205
|
+
_t$props2$allowClear = _t$props2.allowClear,
|
|
206
|
+
allowClear = _t$props2$allowClear === void 0 ? true : _t$props2$allowClear;
|
|
207
|
+
// eslint-disable-next-line camelcase
|
|
264
208
|
var value_arr = function (val) {
|
|
265
209
|
if (Array.isArray(val)) {
|
|
266
210
|
return val;
|
|
@@ -270,7 +214,6 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
270
214
|
return [];
|
|
271
215
|
}
|
|
272
216
|
}(value);
|
|
273
|
-
|
|
274
217
|
var selectedNodes = value_arr.filter(function (k) {
|
|
275
218
|
return k in t.keyNodesMapping;
|
|
276
219
|
}).map(function (item) {
|
|
@@ -278,9 +221,9 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
278
221
|
id: item,
|
|
279
222
|
name: t.keyNodesMapping[item].name
|
|
280
223
|
};
|
|
281
|
-
});
|
|
282
|
-
|
|
283
|
-
var treeProps = (
|
|
224
|
+
});
|
|
225
|
+
// ztree配置
|
|
226
|
+
var treeProps = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
284
227
|
data: data,
|
|
285
228
|
// 树的数据
|
|
286
229
|
// showSearch: showSearch,
|
|
@@ -288,13 +231,12 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
288
231
|
searchPlaceholder: searchPlaceholder,
|
|
289
232
|
multiple: multiple,
|
|
290
233
|
checkable: treeCheckable
|
|
291
|
-
},
|
|
234
|
+
}, treeCheckable ? 'checkedKeys' : 'selectedKeys', value_arr), "defaultExpandAll", treeDefaultExpandAll), "expandedKeys", expandedKeys ? expandedKeys : treeDefaultExpandAll ? undefined : (data === null || data === void 0 || (_data$ = data[0]) === null || _data$ === void 0 ? void 0 : _data$.key) || '-1'), "refreshFlag", refreshFlag || t.treeRefreshFlag), "customCfg", customCfg), "checkStrictly", checkStrictly), "ref", function ref(instance) {
|
|
292
235
|
if (instance) t.tree = instance;
|
|
293
|
-
}),
|
|
236
|
+
}), "onClick", function onClick(_ref) {
|
|
294
237
|
var selectedNodes = _ref.selectedNodes,
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
238
|
+
selectedKeys = _ref.selectedKeys,
|
|
239
|
+
selectedNames = _ref.selectedNames;
|
|
298
240
|
// console.log(selectedNodes,selectedKeys,selectedNames)
|
|
299
241
|
if (!treeCheckable) {
|
|
300
242
|
t.props.onChange && t.props.onChange({
|
|
@@ -307,22 +249,19 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
307
249
|
}),
|
|
308
250
|
names: selectedNames
|
|
309
251
|
});
|
|
310
|
-
|
|
311
252
|
if (!multiple) {
|
|
312
253
|
var _t$tree;
|
|
313
|
-
|
|
314
254
|
t.setState({
|
|
315
255
|
popoverVisible: false,
|
|
316
256
|
searchValue: ''
|
|
317
257
|
});
|
|
318
|
-
(_t$tree = t.tree) === null || _t$tree === void 0
|
|
258
|
+
(_t$tree = t.tree) === null || _t$tree === void 0 || _t$tree.fuzzySearch('');
|
|
319
259
|
}
|
|
320
260
|
}
|
|
321
|
-
}),
|
|
261
|
+
}), "onCheck", function onCheck(_ref2) {
|
|
322
262
|
var checkedNodes = _ref2.checkedNodes,
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
263
|
+
checkedKeys = _ref2.checkedKeys,
|
|
264
|
+
checkedNames = _ref2.checkedNames;
|
|
326
265
|
if (treeCheckable) {
|
|
327
266
|
t.props.onChange && t.props.onChange({
|
|
328
267
|
nodes: checkedNodes,
|
|
@@ -335,10 +274,11 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
335
274
|
names: checkedNames
|
|
336
275
|
});
|
|
337
276
|
}
|
|
338
|
-
}),
|
|
277
|
+
}), "beforeCheck", function beforeCheck(treeNode) {
|
|
339
278
|
return t.props.beforeCheck ? t.props.beforeCheck(treeNode) : true;
|
|
340
|
-
})
|
|
279
|
+
});
|
|
341
280
|
|
|
281
|
+
// 多选组件
|
|
342
282
|
var MultiSelect = /*#__PURE__*/_react["default"].createElement("div", {
|
|
343
283
|
className: (0, _classnames2["default"])("".concat(prefixCls, "-multiple-box")),
|
|
344
284
|
style: style,
|
|
@@ -384,11 +324,10 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
384
324
|
onChange: function onChange(e) {
|
|
385
325
|
if (t.tree) {
|
|
386
326
|
var _t$tree2;
|
|
387
|
-
|
|
388
327
|
t.setState({
|
|
389
328
|
searchValue: e.target.value
|
|
390
329
|
});
|
|
391
|
-
(_t$tree2 = t.tree) === null || _t$tree2 === void 0
|
|
330
|
+
(_t$tree2 = t.tree) === null || _t$tree2 === void 0 || _t$tree2.fuzzySearch(e.target.value.trim());
|
|
392
331
|
}
|
|
393
332
|
},
|
|
394
333
|
onBlur: function onBlur() {
|
|
@@ -443,14 +382,15 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
443
382
|
onClick: function onClick(e) {
|
|
444
383
|
e.stopPropagation();
|
|
445
384
|
}
|
|
446
|
-
})));
|
|
447
|
-
|
|
385
|
+
})));
|
|
448
386
|
|
|
387
|
+
// 单选组件
|
|
449
388
|
var SingleSelect = /*#__PURE__*/_react["default"].createElement(_input["default"], {
|
|
450
389
|
value: t.state.focusSingle ? t.state.searchValue : t.state.searchValue || selectedNodes.map(function (item) {
|
|
451
390
|
return item.name;
|
|
452
391
|
}).join(', '),
|
|
453
|
-
style: style
|
|
392
|
+
style: style
|
|
393
|
+
// readOnly
|
|
454
394
|
,
|
|
455
395
|
disabled: disabled,
|
|
456
396
|
placeholder: t.props.placeholder,
|
|
@@ -478,15 +418,13 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
478
418
|
onChange: function onChange(e) {
|
|
479
419
|
if (t.tree) {
|
|
480
420
|
var _t$tree3;
|
|
481
|
-
|
|
482
421
|
t.setState({
|
|
483
422
|
searchValue: e.target.value
|
|
484
423
|
});
|
|
485
|
-
(_t$tree3 = t.tree) === null || _t$tree3 === void 0
|
|
424
|
+
(_t$tree3 = t.tree) === null || _t$tree3 === void 0 || _t$tree3.fuzzySearch(e.target.value.trim());
|
|
486
425
|
}
|
|
487
426
|
}
|
|
488
427
|
});
|
|
489
|
-
|
|
490
428
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
491
429
|
className: prefixCls
|
|
492
430
|
}, disabled ? multiple || treeCheckable ? MultiSelect : SingleSelect : /*#__PURE__*/_react["default"].createElement(_popover["default"], _extends({
|
|
@@ -503,30 +441,24 @@ var VtxZtreeSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
503
441
|
cursor: 'end'
|
|
504
442
|
});
|
|
505
443
|
}
|
|
506
|
-
|
|
507
444
|
t.setState({
|
|
508
445
|
popoverVisible: v,
|
|
509
446
|
focusMultiple: v
|
|
510
447
|
});
|
|
511
|
-
|
|
512
448
|
if (!v) {
|
|
513
449
|
var _t$tree4;
|
|
514
|
-
|
|
515
450
|
t.setState({
|
|
516
451
|
searchValue: ''
|
|
517
452
|
});
|
|
518
|
-
(_t$tree4 = t.tree) === null || _t$tree4 === void 0
|
|
453
|
+
(_t$tree4 = t.tree) === null || _t$tree4 === void 0 || _t$tree4.fuzzySearch('');
|
|
519
454
|
}
|
|
520
455
|
},
|
|
521
456
|
visible: t.state.popoverVisible
|
|
522
457
|
}), multiple || treeCheckable ? MultiSelect : SingleSelect));
|
|
523
458
|
}
|
|
524
459
|
}]);
|
|
525
|
-
|
|
526
460
|
return VtxZtreeSelect;
|
|
527
461
|
}(_react["default"].Component);
|
|
528
|
-
|
|
529
|
-
exports["default"] = VtxZtreeSelect;
|
|
530
462
|
VtxZtreeSelect.propTypes = {
|
|
531
463
|
data: _propTypes["default"].array,
|
|
532
464
|
expandedKeys: _propTypes["default"].arrayOf(_propTypes["default"].string),
|