bkui-vue 2.0.1-beta.2 → 2.0.1-beta.20
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/dist/index.cjs.js +166 -166
- package/dist/index.esm.js +31807 -31749
- package/dist/index.umd.js +166 -166
- package/dist/style.css +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/affix/index.js +7 -7
- package/lib/alert/alert.d.ts +5 -5
- package/lib/alert/index.d.ts +11 -11
- package/lib/backtop/backtop.d.ts +1 -1
- package/lib/backtop/index.d.ts +3 -3
- package/lib/backtop/index.js +6 -6
- package/lib/badge/index.js +1 -1
- package/lib/button/button.d.ts +7 -7
- package/lib/button/index.d.ts +8 -8
- package/lib/button/index.js +6 -7
- package/lib/cascader/cascader-panel.d.ts +1 -1
- package/lib/cascader/cascader.css +3 -3
- package/lib/cascader/cascader.d.ts +1 -1
- package/lib/cascader/cascader.less +4 -4
- package/lib/cascader/cascader.variable.css +3 -3
- package/lib/cascader/index.js +35 -36
- package/lib/cascader/interface.d.ts +1 -1
- package/lib/checkbox/checkbox.d.ts +7 -7
- package/lib/checkbox/index.d.ts +11 -11
- package/lib/checkbox/index.js +12 -4
- package/lib/checkbox/type.d.ts +1 -1
- package/lib/code-diff/index.js +8 -8
- package/lib/collapse/index.js +2 -2
- package/lib/collapse/utils.d.ts +2 -2
- package/lib/color-picker/color-picker.css +3 -3
- package/lib/color-picker/color-picker.less +3 -3
- package/lib/color-picker/color-picker.variable.css +3 -3
- package/lib/color-picker/index.js +45 -45
- package/lib/components.d.ts +32 -32
- package/lib/components.js +31 -31
- package/lib/config-provider/index.d.ts +1 -1
- package/lib/container/index.js +6 -7
- package/lib/date-picker/base/date-table.d.ts +1 -1
- package/lib/date-picker/base/month-table.d.ts +1 -1
- package/lib/date-picker/base/picker-dropdown.d.ts +1 -1
- package/lib/date-picker/base/year-table.d.ts +3 -3
- package/lib/date-picker/date-picker.d.ts +0 -1
- package/lib/date-picker/index.d.ts +0 -3
- package/lib/date-picker/index.js +318 -218
- package/lib/date-picker/interface.d.ts +9 -9
- package/lib/date-picker/panel/date-range.d.ts +6 -68
- package/lib/date-picker/panel/date.d.ts +1 -1
- package/lib/date-picker/panel/time-range.d.ts +1 -1
- package/lib/date-picker/panel/time.d.ts +1 -1
- package/lib/date-picker/props.d.ts +1 -1
- package/lib/date-picker/utils.d.ts +5 -1
- package/lib/dialog/dialog.css +0 -4
- package/lib/dialog/dialog.d.ts +25 -20
- package/lib/dialog/dialog.variable.css +0 -4
- package/lib/dialog/index.d.ts +55 -44
- package/lib/dialog/index.js +22 -22
- package/lib/dialog/props.d.ts +10 -8
- package/lib/directives/index.d.ts +3 -3
- package/lib/directives/index.js +166 -166
- package/lib/directives/tooltips.d.ts +1 -1
- package/lib/dist.index.js +2 -4
- package/lib/divider/divider.d.ts +5 -5
- package/lib/divider/index.d.ts +11 -11
- package/lib/divider/index.js +2 -2
- package/lib/divider/props.d.ts +2 -2
- package/lib/dropdown/dropdown.d.ts +5 -5
- package/lib/dropdown/index.d.ts +11 -11
- package/lib/dropdown/index.js +7 -7
- package/lib/exception/exception.d.ts +9 -9
- package/lib/exception/index.d.ts +11 -11
- package/lib/exception/index.js +10 -10
- package/lib/exception/typings/index.d.ts +1 -1
- package/lib/fixed-navbar/index.js +2 -2
- package/lib/form/form.d.ts +2 -2
- package/lib/form/index.js +14 -15
- package/lib/form/type.d.ts +2 -2
- package/lib/icon/index.d.ts +11 -11
- package/lib/icon/index.js +11 -11
- package/lib/image/image-viewer.d.ts +1 -1
- package/lib/image/index.js +20 -21
- package/lib/index.d.ts +9 -3
- package/lib/index.js +5 -29
- package/lib/info-box/index.js +13 -13
- package/lib/info-box/info-box.d.ts +15 -15
- package/lib/input/index.d.ts +15 -15
- package/lib/input/index.js +16 -17
- package/lib/input/input.d.ts +15 -15
- package/lib/link/index.d.ts +11 -11
- package/lib/link/index.js +3 -3
- package/lib/link/link.d.ts +5 -5
- package/lib/loading/index.d.ts +4 -4
- package/lib/loading/index.js +6 -6
- package/lib/loading/loading.d.ts +6 -6
- package/lib/locale/index.d.ts +1 -1
- package/lib/menu/index.js +0 -1
- package/lib/menu/utils.d.ts +3 -3
- package/lib/message/index.js +18 -18
- package/lib/message/messageConstructor.d.ts +11 -11
- package/lib/modal/index.d.ts +21 -8
- package/lib/modal/index.js +14 -8
- package/lib/modal/modal.css +0 -4
- package/lib/modal/modal.d.ts +8 -3
- package/lib/modal/modal.less +0 -5
- package/lib/modal/modal.variable.css +0 -4
- package/lib/modal/props.mixin.d.ts +3 -1
- package/lib/navigation/index.js +20 -20
- package/lib/navigation/navigation.d.ts +1 -1
- package/lib/notify/index.js +4 -4
- package/lib/overflow-title/components/overflow-title.d.ts +9 -9
- package/lib/overflow-title/index.d.ts +19 -19
- package/lib/overflow-title/index.js +61 -11
- package/lib/overflow-title/props.d.ts +18 -18
- package/lib/pagination/index.js +16 -16
- package/lib/pagination/type.d.ts +1 -1
- package/lib/pagination/use-limit.d.ts +1 -1
- package/lib/pagination/use-total.d.ts +1 -1
- package/lib/plugin-popover/index.js +18 -20
- package/lib/pop-confirm/index.d.ts +11 -11
- package/lib/pop-confirm/index.js +11 -10
- package/lib/pop-confirm/pop-confirm.d.ts +5 -5
- package/lib/pop-confirm/props.d.ts +4 -4
- package/lib/popover/const.d.ts +3 -3
- package/lib/popover/index.d.ts +19 -19
- package/lib/popover/index.js +18 -20
- package/lib/popover/plugin-popover.d.ts +1 -1
- package/lib/popover/popover.d.ts +7 -7
- package/lib/popover/props.d.ts +4 -4
- package/lib/preset.d.ts +0 -1
- package/lib/preset.js +0 -1
- package/lib/process/index.js +3 -3
- package/lib/progress/index.d.ts +11 -11
- package/lib/progress/index.js +10 -11
- package/lib/progress/progress.d.ts +7 -7
- package/lib/radio/index.d.ts +21 -21
- package/lib/radio/index.js +28 -17
- package/lib/radio/radio-button.d.ts +7 -7
- package/lib/radio/radio-group.d.ts +7 -7
- package/lib/radio/radio.d.ts +7 -7
- package/lib/radio/type.d.ts +1 -1
- package/lib/rate/index.js +8 -8
- package/lib/rate/rate.css +27 -0
- package/lib/rate/rate.less +33 -0
- package/lib/rate/rate.variable.css +27 -0
- package/lib/resize-layout/index.d.ts +11 -11
- package/lib/resize-layout/index.js +7 -8
- package/lib/resize-layout/resize-layout.d.ts +5 -5
- package/lib/scrollbar/index.js +0 -1
- package/lib/scrollbar/scrollbar-core/index.d.ts +9 -9
- package/lib/search-select/index.js +66 -66
- package/lib/search-select/menu.d.ts +1 -1
- package/lib/search-select/selected.d.ts +1 -1
- package/lib/search-select/utils.d.ts +3 -3
- package/lib/select/index.d.ts +85 -67
- package/lib/select/index.js +126 -120
- package/lib/select/option.d.ts +1 -1
- package/lib/select/select.css +1 -2
- package/lib/select/select.d.ts +34 -26
- package/lib/select/select.less +1 -2
- package/lib/select/select.variable.css +1 -2
- package/lib/select/selectTagInput.d.ts +6 -6
- package/lib/select/type.d.ts +2 -2
- package/lib/shared/index.d.ts +1 -1
- package/lib/shared/index.js +38 -46
- package/lib/shared/popover.d.ts +3 -3
- package/lib/shared/token.d.ts +1 -1
- package/lib/shared/vue-types.d.ts +46 -46
- package/lib/shared/z-index-manager.d.ts +6 -6
- package/lib/sideslider/index.d.ts +18 -7
- package/lib/sideslider/index.js +11 -11
- package/lib/sideslider/sideslider.d.ts +8 -3
- package/lib/slider/index.js +21 -23
- package/lib/steps/index.d.ts +11 -11
- package/lib/steps/index.js +3 -3
- package/lib/steps/steps.d.ts +7 -7
- package/lib/styles/index.d.ts +0 -1
- package/lib/swiper/index.js +5 -5
- package/lib/switcher/index.js +2 -2
- package/lib/switcher/switcher.d.ts +2 -2
- package/lib/tab/index.d.ts +22 -22
- package/lib/tab/index.js +15 -15
- package/lib/tab/props.d.ts +15 -15
- package/lib/tab/tab-nav.d.ts +10 -10
- package/lib/tab/tab.d.ts +10 -10
- package/lib/table/components/table-column.d.ts +27 -87
- package/lib/table/const.d.ts +8 -8
- package/lib/table/events.d.ts +21 -21
- package/lib/table/index.d.ts +194 -244
- package/lib/table/index.js +166 -145
- package/lib/table/plugins/use-shift-key.d.ts +2 -0
- package/lib/table/props.d.ts +34 -34
- package/lib/table/table.css +3 -4
- package/lib/table/table.d.ts +47 -47
- package/lib/table/table.less +4 -12
- package/lib/table/table.variable.css +3 -4
- package/lib/table/use-attributes.d.ts +3 -3
- package/lib/table/use-column.d.ts +9 -129
- package/lib/table/use-common.d.ts +4 -4
- package/lib/table/utils.d.ts +5 -5
- package/lib/table-column/index.d.ts +42 -172
- package/lib/table-column/index.js +19 -19
- package/lib/tag/index.d.ts +11 -11
- package/lib/tag/index.js +2 -2
- package/lib/tag/tag.d.ts +5 -5
- package/lib/tag-input/common.d.ts +1 -1
- package/lib/tag-input/index.d.ts +8 -8
- package/lib/tag-input/index.js +30 -30
- package/lib/tag-input/tag-input.d.ts +4 -4
- package/lib/tag-input/tag-props.d.ts +2 -2
- package/lib/timeline/index.js +2 -2
- package/lib/transfer/const.d.ts +2 -2
- package/lib/transfer/index.js +19 -19
- package/lib/transfer/transfer.css +9 -9
- package/lib/transfer/transfer.less +3 -3
- package/lib/transfer/transfer.variable.css +9 -9
- package/lib/tree/constant.d.ts +20 -20
- package/lib/tree/index.d.ts +20 -20
- package/lib/tree/index.js +53 -49
- package/lib/tree/props.d.ts +6 -6
- package/lib/tree/tree.d.ts +8 -14
- package/lib/tree/tree.less +1 -1
- package/lib/tree/use-empty.d.ts +1 -1
- package/lib/tree/use-node-action.d.ts +2 -2
- package/lib/tree/use-search.d.ts +1 -1
- package/lib/tree/util.d.ts +1 -1
- package/lib/upload/index.js +41 -35
- package/lib/upload/props.d.ts +1 -1
- package/lib/upload/upload.type.d.ts +7 -7
- package/lib/upload/use-file-handler.d.ts +1 -1
- package/lib/virtual-render/index.js +2 -3
- package/package.json +17 -55
- package/lib/rate/star.css +0 -27
- package/lib/rate/star.less +0 -34
- package/lib/rate/star.variable.css +0 -156
package/lib/select/index.js
CHANGED
@@ -2,12 +2,11 @@ import "../styles/reset.css";
|
|
2
2
|
import "./select.less";
|
3
3
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_shared_edbdfb03__ from "../shared";
|
4
4
|
import * as __WEBPACK_EXTERNAL_MODULE_vue__ from "vue";
|
5
|
-
import * as __WEBPACK_EXTERNAL_MODULE_lodash_isEqual_ce045a54__ from "lodash/isEqual";
|
6
5
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_checkbox_13b1cb4a__ from "../checkbox";
|
7
6
|
import "../checkbox/checkbox.less";
|
8
7
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_config_provider_fe8577a3__ from "../config-provider";
|
9
8
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__ from "../icon";
|
10
|
-
import * as
|
9
|
+
import * as __WEBPACK_EXTERNAL_MODULE_lodash_isEqual_ce045a54__ from "lodash/isEqual";
|
11
10
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_directives_45d4776f__ from "../directives";
|
12
11
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_input_d525237e__ from "../input";
|
13
12
|
import "../input/input.less";
|
@@ -17,9 +16,10 @@ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_popover_9b03f19d__ from "../p
|
|
17
16
|
import "../popover/popover.less";
|
18
17
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_virtual_render_927587a8__ from "../virtual-render";
|
19
18
|
import "../virtual-render/virtual-render.less";
|
20
|
-
import * as
|
19
|
+
import * as __WEBPACK_EXTERNAL_MODULE_lodash_merge_cf99375a__ from "lodash/merge";
|
21
20
|
import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_tag_d74826be__ from "../tag";
|
22
21
|
import "../tag/tag.less";
|
22
|
+
import * as __WEBPACK_EXTERNAL_MODULE_lodash_debounce_3540babe__ from "lodash/debounce";
|
23
23
|
/******/ var __webpack_modules__ = ({
|
24
24
|
|
25
25
|
/***/ 7609:
|
@@ -492,10 +492,6 @@ function _defineProperty(obj, key, value) {
|
|
492
492
|
var external_vue_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
493
493
|
var external_vue_y = x => () => x
|
494
494
|
const external_vue_namespaceObject = external_vue_x({ ["computed"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.computed, ["createTextVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createTextVNode, ["createVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createVNode, ["customRef"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.customRef, ["defineComponent"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.defineComponent, ["getCurrentInstance"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.getCurrentInstance, ["inject"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.inject, ["mergeProps"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.mergeProps, ["onBeforeMount"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.onBeforeMount, ["onBeforeUnmount"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.onBeforeUnmount, ["onMounted"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.onMounted, ["provide"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.provide, ["reactive"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.reactive, ["ref"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.ref, ["resolveDirective"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.resolveDirective, ["toRef"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.toRef, ["toRefs"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.toRefs, ["vModelText"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.vModelText, ["vShow"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.vShow, ["watch"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.watch, ["withDirectives"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.withDirectives });
|
495
|
-
;// CONCATENATED MODULE: external "lodash/isEqual"
|
496
|
-
var isEqual_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
497
|
-
var isEqual_y = x => () => x
|
498
|
-
const isEqual_namespaceObject = isEqual_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_isEqual_ce045a54__["default"] });
|
499
495
|
;// CONCATENATED MODULE: external "../checkbox"
|
500
496
|
var checkbox_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
501
497
|
var checkbox_y = x => () => x
|
@@ -512,6 +508,10 @@ const config_provider_namespaceObject = config_provider_x({ ["useLocale"]: () =>
|
|
512
508
|
var icon_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
513
509
|
var icon_y = x => () => x
|
514
510
|
const icon_namespaceObject = icon_x({ ["AngleUp"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.AngleUp, ["AngleUpFill"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.AngleUpFill, ["Close"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.Close, ["Done"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.Done, ["Search"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.Search, ["TextAll"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.TextAll });
|
511
|
+
;// CONCATENATED MODULE: external "lodash/isEqual"
|
512
|
+
var isEqual_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
513
|
+
var isEqual_y = x => () => x
|
514
|
+
const isEqual_namespaceObject = isEqual_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_isEqual_ce045a54__["default"] });
|
515
515
|
;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js
|
516
516
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
517
517
|
try {
|
@@ -732,7 +732,6 @@ function isInViewPort(el, client) {
|
|
732
732
|
|
733
733
|
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; }
|
734
734
|
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; }
|
735
|
-
/* eslint-disable vue/no-reserved-component-names */
|
736
735
|
/*
|
737
736
|
* Tencent is pleased to support the open source community by making
|
738
737
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
@@ -894,16 +893,16 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
894
893
|
"onClick": this.handleOptionClick,
|
895
894
|
"onMouseenter": this.handleMouseEnter
|
896
895
|
}, [this.showSelectedIcon && this.selectedStyle === shared_namespaceObject.SelectedTypeEnum.CHECKBOX && (0,external_vue_namespaceObject.createVNode)(checkbox_namespaceObject["default"], {
|
897
|
-
"disabled": this.disabled,
|
898
896
|
"class": this.resolveClassName('select-checkbox'),
|
897
|
+
"disabled": this.disabled,
|
899
898
|
"modelValue": this.selected
|
900
899
|
}, null), (_this$$slots$default = (_this$$slots$default2 = (_this$$slots = this.$slots)["default"]) === null || _this$$slots$default2 === void 0 ? void 0 : _this$$slots$default2.call(_this$$slots)) !== null && _this$$slots$default !== void 0 ? _this$$slots$default : (0,external_vue_namespaceObject.createVNode)("span", {
|
901
900
|
"class": this.resolveClassName('select-option-item'),
|
902
901
|
"title": String(this.optionName)
|
903
902
|
}, [this.highlightKeyword ? this.transformNode(String(this.optionName)) : this.optionName]), this.showSelectedIcon && this.selected && this.selectedStyle === shared_namespaceObject.SelectedTypeEnum.CHECK && (0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.Done, {
|
904
|
-
"class": this.resolveClassName('select-selected-icon'),
|
905
903
|
"width": 22,
|
906
|
-
"height": 22
|
904
|
+
"height": 22,
|
905
|
+
"class": this.resolveClassName('select-selected-icon')
|
907
906
|
}, null)]), [[external_vue_namespaceObject.vShow, this.visible]]);
|
908
907
|
}
|
909
908
|
}));
|
@@ -1054,10 +1053,6 @@ function optionGroup_objectSpread(e) { for (var r = 1; r < arguments.length; r++
|
|
1054
1053
|
}, [(_this$$slots$default = (_this$$slots = this.$slots)["default"]) === null || _this$$slots$default === void 0 ? void 0 : _this$$slots$default.call(_this$$slots)]), [[external_vue_namespaceObject.vShow, !this.groupCollapse]])]), [[external_vue_namespaceObject.vShow, this.visible]]);
|
1055
1054
|
}
|
1056
1055
|
}));
|
1057
|
-
;// CONCATENATED MODULE: external "lodash/merge"
|
1058
|
-
var merge_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
1059
|
-
var merge_y = x => () => x
|
1060
|
-
const merge_namespaceObject = merge_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_merge_cf99375a__["default"] });
|
1061
1056
|
;// CONCATENATED MODULE: external "../directives"
|
1062
1057
|
var directives_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
1063
1058
|
var directives_y = x => () => x
|
@@ -1094,6 +1089,10 @@ const virtual_render_namespaceObject = virtual_render_x({ ["default"]: () => __W
|
|
1094
1089
|
var virtual_render_less_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
1095
1090
|
var virtual_render_less_y = x => () => x
|
1096
1091
|
const virtual_render_less_namespaceObject = virtual_render_less_x({ });
|
1092
|
+
;// CONCATENATED MODULE: external "lodash/merge"
|
1093
|
+
var merge_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
1094
|
+
var merge_y = x => () => x
|
1095
|
+
const merge_namespaceObject = merge_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_merge_cf99375a__["default"] });
|
1097
1096
|
;// CONCATENATED MODULE: ../../packages/select/src/pinyin/dict.js
|
1098
1097
|
/*
|
1099
1098
|
* Tencent is pleased to support the open source community by making
|
@@ -1121,8 +1120,6 @@ const virtual_render_less_namespaceObject = virtual_render_less_x({ });
|
|
1121
1120
|
* IN THE SOFTWARE.
|
1122
1121
|
*/
|
1123
1122
|
|
1124
|
-
/* eslint-disable max-len */
|
1125
|
-
|
1126
1123
|
/**
|
1127
1124
|
* Source: <https://android.googlesource.com/platform/packages/providers/ContactsProvider/+/0c49720fb3d58e346739c2ccd56ed2b739249e07/src/com/android/providers/contacts/HanziToPinyin.java>
|
1128
1125
|
* Updated by creeper
|
@@ -2036,7 +2033,6 @@ let COLLATOR;
|
|
2036
2033
|
function patchDict(patchers) {
|
2037
2034
|
if (!patchers) return;
|
2038
2035
|
if (typeof patchers === 'function') {
|
2039
|
-
// eslint-disable-next-line no-param-reassign
|
2040
2036
|
patchers = [patchers];
|
2041
2037
|
}
|
2042
2038
|
if (patchers.forEach) {
|
@@ -2127,7 +2123,6 @@ function genToken(ch) {
|
|
2127
2123
|
}
|
2128
2124
|
|
2129
2125
|
if (cmp < 0) {
|
2130
|
-
// eslint-disable-next-line no-plusplus
|
2131
2126
|
offset--;
|
2132
2127
|
}
|
2133
2128
|
|
@@ -2296,10 +2291,6 @@ if (core.isSupported() && _56l.shouldPatch(core.genToken)) {
|
|
2296
2291
|
|
2297
2292
|
/* harmony default export */ const pinyin = (core);
|
2298
2293
|
|
2299
|
-
;// CONCATENATED MODULE: external "lodash/debounce"
|
2300
|
-
var debounce_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
2301
|
-
var debounce_y = x => () => x
|
2302
|
-
const debounce_namespaceObject = debounce_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_debounce_3540babe__["default"] });
|
2303
2294
|
;// CONCATENATED MODULE: external "../tag"
|
2304
2295
|
var tag_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
2305
2296
|
var tag_y = x => () => x
|
@@ -2308,6 +2299,10 @@ const tag_namespaceObject = tag_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE
|
|
2308
2299
|
var tag_less_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
2309
2300
|
var tag_less_y = x => () => x
|
2310
2301
|
const tag_less_namespaceObject = tag_less_x({ });
|
2302
|
+
;// CONCATENATED MODULE: external "lodash/debounce"
|
2303
|
+
var debounce_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
2304
|
+
var debounce_y = x => () => x
|
2305
|
+
const debounce_namespaceObject = debounce_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_debounce_3540babe__["default"] });
|
2311
2306
|
;// CONCATENATED MODULE: ../../packages/select/src/selectTagInput.tsx
|
2312
2307
|
|
2313
2308
|
|
@@ -2494,21 +2489,21 @@ const tag_less_namespaceObject = tag_less_x({ });
|
|
2494
2489
|
display: this.selected.length && !this.filterable ? 'none' : ''
|
2495
2490
|
};
|
2496
2491
|
return (0,external_vue_namespaceObject.createVNode)("div", {
|
2497
|
-
"
|
2498
|
-
"
|
2492
|
+
"ref": "tagWrapperRef",
|
2493
|
+
"class": selectTagClass
|
2499
2494
|
}, [(_this$$slots2 = this.$slots) === null || _this$$slots2 === void 0 || (_this$$slots2$prefix = _this$$slots2.prefix) === null || _this$$slots2$prefix === void 0 ? void 0 : _this$$slots2$prefix.call(_this$$slots2), (0,external_vue_namespaceObject.createVNode)("div", {
|
2500
2495
|
"class": tagWrapperClass
|
2501
2496
|
}, [(_this$$slots$default = (_this$$slots$default2 = (_this$$slots3 = this.$slots)["default"]) === null || _this$$slots$default2 === void 0 ? void 0 : _this$$slots$default2.call(_this$$slots3)) !== null && _this$$slots$default !== void 0 ? _this$$slots$default : this.selected.map(function (item, index) {
|
2502
2497
|
var _this$select;
|
2503
2498
|
return (0,external_vue_namespaceObject.createVNode)(tag_namespaceObject["default"], {
|
2504
|
-
"closable": true,
|
2505
|
-
"theme": _this.tagTheme,
|
2506
|
-
"style": {
|
2507
|
-
display: _this.collapseTags && _this.overflowTagIndex && index >= _this.overflowTagIndex ? 'none' : ''
|
2508
|
-
},
|
2509
2499
|
"ref": function ref(el) {
|
2510
2500
|
return _this.tagsRefs[index] = el;
|
2511
2501
|
},
|
2502
|
+
"style": {
|
2503
|
+
display: _this.collapseTags && _this.overflowTagIndex && index >= _this.overflowTagIndex ? 'none' : ''
|
2504
|
+
},
|
2505
|
+
"theme": _this.tagTheme,
|
2506
|
+
"closable": true,
|
2512
2507
|
"onClose": function onClose() {
|
2513
2508
|
return _this.handleRemoveTag(item.value);
|
2514
2509
|
}
|
@@ -2518,11 +2513,11 @@ const tag_less_namespaceObject = tag_less_x({ });
|
|
2518
2513
|
}
|
2519
2514
|
});
|
2520
2515
|
}), (0,external_vue_namespaceObject.withDirectives)((0,external_vue_namespaceObject.createVNode)(tag_namespaceObject["default"], {
|
2521
|
-
"
|
2516
|
+
"ref": "collapseTagRef",
|
2522
2517
|
"style": {
|
2523
2518
|
display: !!this.overflowTagIndex && this.collapseTags ? '' : 'none'
|
2524
2519
|
},
|
2525
|
-
"
|
2520
|
+
"class": this.resolveClassName('select-overflow-tag')
|
2526
2521
|
}, {
|
2527
2522
|
"default": function _default() {
|
2528
2523
|
return [(0,external_vue_namespaceObject.createTextVNode)("+"), _this.selected.length - _this.overflowTagIndex];
|
@@ -2531,13 +2526,13 @@ const tag_less_namespaceObject = tag_less_x({ });
|
|
2531
2526
|
content: this.overflowContent,
|
2532
2527
|
disabled: !this.overflowTagIndex || !this.collapseTags
|
2533
2528
|
}]]), (0,external_vue_namespaceObject.createVNode)("input", {
|
2534
|
-
"class": this.resolveClassName('select-tag-input'),
|
2535
2529
|
"ref": "inputRef",
|
2536
|
-
"type": "text",
|
2537
2530
|
"style": inputStyle,
|
2531
|
+
"class": this.resolveClassName('select-tag-input'),
|
2532
|
+
"disabled": this.disabled,
|
2538
2533
|
"placeholder": !this.selected.length ? this.placeholder : '',
|
2539
2534
|
"readonly": !this.filterable,
|
2540
|
-
"
|
2535
|
+
"type": "text",
|
2541
2536
|
"value": !this.filterable ? '' : this.value,
|
2542
2537
|
"onInput": this.handleInput,
|
2543
2538
|
"onKeydown": this.handleKeydown
|
@@ -2554,7 +2549,6 @@ function select_unsupportedIterableToArray(o, minLen) { if (!o) return; if (type
|
|
2554
2549
|
function select_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; }
|
2555
2550
|
function select_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; }
|
2556
2551
|
function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? select_ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : select_ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
2557
|
-
/* eslint-disable vue/no-reserved-component-names */
|
2558
2552
|
/*
|
2559
2553
|
* Tencent is pleased to support the open source community by making
|
2560
2554
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
@@ -2615,7 +2609,8 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
2615
2609
|
loading: shared_namespaceObject.PropTypes.bool.def(false),
|
2616
2610
|
filterable: shared_namespaceObject.PropTypes.bool.def(true),
|
2617
2611
|
remoteMethod: shared_namespaceObject.PropTypes.func,
|
2618
|
-
scrollHeight: shared_namespaceObject.PropTypes.number.def(
|
2612
|
+
scrollHeight: shared_namespaceObject.PropTypes.number.def(204),
|
2613
|
+
minHeight: shared_namespaceObject.PropTypes.number,
|
2619
2614
|
showAll: shared_namespaceObject.PropTypes.bool.def(false),
|
2620
2615
|
allOptionId: shared_namespaceObject.PropTypes.oneOfType([shared_namespaceObject.PropTypes.number, shared_namespaceObject.PropTypes.string]),
|
2621
2616
|
showSelectAll: shared_namespaceObject.PropTypes.bool.def(false),
|
@@ -2736,7 +2731,6 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
2736
2731
|
var contentRef = (0,external_vue_namespaceObject.ref)();
|
2737
2732
|
var searchRef = (0,external_vue_namespaceObject.ref)();
|
2738
2733
|
var selectTagInputRef = (0,external_vue_namespaceObject.ref)();
|
2739
|
-
var virtualRenderRef = (0,external_vue_namespaceObject.ref)();
|
2740
2734
|
var popoverRef = (0,external_vue_namespaceObject.ref)();
|
2741
2735
|
var optionsMap = (0,external_vue_namespaceObject.ref)(new Map());
|
2742
2736
|
var options = (0,external_vue_namespaceObject.computed)(function () {
|
@@ -2849,6 +2843,16 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
2849
2843
|
var virtualHeight = (0,external_vue_namespaceObject.computed)(function () {
|
2850
2844
|
return scrollHeight.value - 12 - (isShowSelectAll.value ? 32 : 0);
|
2851
2845
|
});
|
2846
|
+
var virtualLineHeight = (0,external_vue_namespaceObject.ref)(32);
|
2847
|
+
// 是否启用虚拟滚动(如果配置了启用,但是数据小于滚动高度则不开启)
|
2848
|
+
var isEnableVirtualRender = (0,external_vue_namespaceObject.computed)(function () {
|
2849
|
+
if (enableVirtualRender.value) return virtualList.value.length * virtualLineHeight.value > virtualHeight.value;
|
2850
|
+
return false;
|
2851
|
+
});
|
2852
|
+
// 预加载滚动数据
|
2853
|
+
var preloadItemCount = (0,external_vue_namespaceObject.computed)(function () {
|
2854
|
+
return Math.ceil(virtualHeight.value / virtualLineHeight.value);
|
2855
|
+
});
|
2852
2856
|
// 当前空状态时显示文案
|
2853
2857
|
var curContentText = (0,external_vue_namespaceObject.computed)(function () {
|
2854
2858
|
if (searchLoading.value) {
|
@@ -2933,6 +2937,7 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
2933
2937
|
// 滚动到当前选中的options中
|
2934
2938
|
var scrollActiveOptionIntoView = function scrollActiveOptionIntoView() {
|
2935
2939
|
var _contentRef$value, _contentRef$value$que, _optionsDom$;
|
2940
|
+
if (isEnableVirtualRender.value) return;
|
2936
2941
|
var optionsDom = (_contentRef$value = contentRef.value) === null || _contentRef$value === void 0 || (_contentRef$value$que = _contentRef$value.querySelectorAll) === null || _contentRef$value$que === void 0 ? void 0 : _contentRef$value$que.call(_contentRef$value, '.is-selected');
|
2937
2942
|
optionsDom === null || optionsDom === void 0 || (_optionsDom$ = optionsDom[0]) === null || _optionsDom$ === void 0 || _optionsDom$.scrollIntoView({
|
2938
2943
|
block: 'center'
|
@@ -3252,7 +3257,7 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3252
3257
|
};
|
3253
3258
|
// 处理键盘事件
|
3254
3259
|
var handleDocumentKeydown = function handleDocumentKeydown(e) {
|
3255
|
-
if (!isPopoverShow.value ||
|
3260
|
+
if (!isPopoverShow.value || isEnableVirtualRender.value) return;
|
3256
3261
|
var availableOptions = options.value.filter(function (option) {
|
3257
3262
|
return !option.disabled && option.visible;
|
3258
3263
|
});
|
@@ -3310,13 +3315,6 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3310
3315
|
hidePopover();
|
3311
3316
|
handleBlur();
|
3312
3317
|
};
|
3313
|
-
var handlePopoverShow = function handlePopoverShow() {
|
3314
|
-
setTimeout(function () {
|
3315
|
-
var _virtualRenderRef$val, _virtualRenderRef$val2;
|
3316
|
-
// 虚拟滚动首次未更新问题
|
3317
|
-
enableVirtualRender.value && ((_virtualRenderRef$val = virtualRenderRef.value) === null || _virtualRenderRef$val === void 0 || (_virtualRenderRef$val2 = _virtualRenderRef$val.reset) === null || _virtualRenderRef$val2 === void 0 ? void 0 : _virtualRenderRef$val2.call(_virtualRenderRef$val));
|
3318
|
-
});
|
3319
|
-
};
|
3320
3318
|
(0,external_vue_namespaceObject.provide)(selectKey, (0,external_vue_namespaceObject.reactive)({
|
3321
3319
|
multiple: multiple,
|
3322
3320
|
selected: selected,
|
@@ -3354,7 +3352,6 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3354
3352
|
contentRef: contentRef,
|
3355
3353
|
searchRef: searchRef,
|
3356
3354
|
selectTagInputRef: selectTagInputRef,
|
3357
|
-
virtualRenderRef: virtualRenderRef,
|
3358
3355
|
popoverRef: popoverRef,
|
3359
3356
|
searchLoading: searchLoading,
|
3360
3357
|
isOptionsEmpty: isOptionsEmpty,
|
@@ -3391,13 +3388,15 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3391
3388
|
handleDeleteTag: handleDeleteTag,
|
3392
3389
|
handleInputChange: handleInputChange,
|
3393
3390
|
handleSelectedAllOptionMouseEnter: handleSelectedAllOptionMouseEnter,
|
3394
|
-
handlePopoverShow: handlePopoverShow,
|
3395
3391
|
localLoadingText: localLoadingText,
|
3396
3392
|
localPlaceholder: localPlaceholder,
|
3397
3393
|
localSearchPlaceholder: localSearchPlaceholder,
|
3398
3394
|
localSelectAllText: localSelectAllText,
|
3399
3395
|
resolveClassName: resolveClassName,
|
3400
|
-
handleCreateCustomOption: handleCreateCustomOption
|
3396
|
+
handleCreateCustomOption: handleCreateCustomOption,
|
3397
|
+
virtualLineHeight: virtualLineHeight,
|
3398
|
+
isEnableVirtualRender: isEnableVirtualRender,
|
3399
|
+
preloadItemCount: preloadItemCount
|
3401
3400
|
};
|
3402
3401
|
},
|
3403
3402
|
render: function render() {
|
@@ -3406,11 +3405,11 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3406
3405
|
var suffixIcon = function suffixIcon() {
|
3407
3406
|
if (_this.loading) {
|
3408
3407
|
return (0,external_vue_namespaceObject.createVNode)(loading_namespaceObject["default"], {
|
3409
|
-
"loading": true,
|
3410
|
-
"theme": "primary",
|
3411
3408
|
"class": "spinner",
|
3409
|
+
"loading": true,
|
3412
3410
|
"mode": "spin",
|
3413
|
-
"size": "mini"
|
3411
|
+
"size": "mini",
|
3412
|
+
"theme": "primary"
|
3414
3413
|
}, null);
|
3415
3414
|
}
|
3416
3415
|
if (_this.clearable && _this.isHover && _this.selected.length && !_this.isDisabled) {
|
@@ -3442,12 +3441,12 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3442
3441
|
if (!_this.isShowSelectAll) return;
|
3443
3442
|
return (0,external_vue_namespaceObject.createVNode)("li", {
|
3444
3443
|
"class": _this.resolveClassName('select-option'),
|
3445
|
-
"
|
3446
|
-
"
|
3444
|
+
"onClick": _this.toggleSelectAll,
|
3445
|
+
"onMouseenter": _this.handleSelectedAllOptionMouseEnter
|
3447
3446
|
}, [_this.selectedStyle === 'checkbox' && (0,external_vue_namespaceObject.createVNode)(checkbox_namespaceObject["default"], {
|
3448
3447
|
"class": _this.resolveClassName('select-checkbox'),
|
3449
|
-
"
|
3450
|
-
"
|
3448
|
+
"indeterminate": !_this.isAllSelected && !!_this.selected.length && !_this.isAll,
|
3449
|
+
"modelValue": _this.isAllSelected
|
3451
3450
|
}, null), _this.t.selectAll]);
|
3452
3451
|
};
|
3453
3452
|
// 全部
|
@@ -3463,6 +3462,7 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3463
3462
|
"class": "select-all-icon"
|
3464
3463
|
}, null), (0,external_vue_namespaceObject.createVNode)("span", null, [_this.t.all])])]);
|
3465
3464
|
};
|
3465
|
+
// 默认trigger输入框渲染
|
3466
3466
|
var renderTriggerInput = function renderTriggerInput() {
|
3467
3467
|
var _this$$slots5;
|
3468
3468
|
if (_this.multipleMode === 'tag') {
|
@@ -3473,15 +3473,15 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3473
3473
|
"onUpdate:modelValue": function onUpdateModelValue($event) {
|
3474
3474
|
return _this.customOptionName = $event;
|
3475
3475
|
},
|
3476
|
-
"selected": _this.selected,
|
3477
|
-
"tagTheme": _this.tagTheme,
|
3478
|
-
"placeholder": _this.localPlaceholder,
|
3479
|
-
"filterable": _this.isInput,
|
3480
|
-
"disabled": _this.isDisabled,
|
3481
3476
|
"behavior": _this.behavior,
|
3482
|
-
"onRemove": _this.handleDeleteTag,
|
3483
3477
|
"collapseTags": _this.isCollapseTags,
|
3484
|
-
"
|
3478
|
+
"disabled": _this.isDisabled,
|
3479
|
+
"filterable": _this.isInput,
|
3480
|
+
"placeholder": _this.localPlaceholder,
|
3481
|
+
"selected": _this.selected,
|
3482
|
+
"tagTheme": _this.tagTheme,
|
3483
|
+
"onEnter": _this.handleCreateCustomOption,
|
3484
|
+
"onRemove": _this.handleDeleteTag
|
3485
3485
|
}, {
|
3486
3486
|
prefix: renderPrefix(),
|
3487
3487
|
"default": ((_this$$slots3 = _this.$slots) === null || _this$$slots3 === void 0 ? void 0 : _this$$slots3.tag) && function () {
|
@@ -3497,18 +3497,18 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3497
3497
|
}
|
3498
3498
|
return (0,external_vue_namespaceObject.createVNode)(input_namespaceObject["default"], (0,external_vue_namespaceObject.mergeProps)({
|
3499
3499
|
"ref": "inputRef",
|
3500
|
-
"
|
3500
|
+
"behavior": _this.behavior,
|
3501
|
+
"disabled": _this.isDisabled,
|
3501
3502
|
"modelValue": _this.isInput ? _this.customOptionName : _this.selectedLabel.join(','),
|
3502
3503
|
"placeholder": _this.isInput ? _this.selectedLabel.join(',') || _this.localPlaceholder : _this.localPlaceholder,
|
3503
3504
|
"readonly": !_this.isInput,
|
3504
3505
|
"selectReadonly": true,
|
3505
|
-
"disabled": _this.isDisabled,
|
3506
|
-
"behavior": _this.behavior,
|
3507
3506
|
"size": _this.size,
|
3508
|
-
"withValidate": false,
|
3509
3507
|
"stopPropagation": false,
|
3510
|
-
"
|
3511
|
-
"
|
3508
|
+
"type": "text",
|
3509
|
+
"withValidate": false,
|
3510
|
+
"onEnter": _this.handleCreateCustomOption,
|
3511
|
+
"onInput": _this.handleInputChange
|
3512
3512
|
}, _this.prefix ? {
|
3513
3513
|
prefix: _this.prefix
|
3514
3514
|
} : null), select_objectSpread(select_objectSpread({}, typeof ((_this$$slots5 = _this.$slots) === null || _this$$slots5 === void 0 ? void 0 : _this$$slots5.prefix) === 'function' ? {
|
@@ -3522,14 +3522,15 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3522
3522
|
}
|
3523
3523
|
}));
|
3524
3524
|
};
|
3525
|
+
// 渲染trigger
|
3525
3526
|
var renderSelectTrigger = function renderSelectTrigger() {
|
3526
3527
|
var _this$$slots7, _this$$slots7$trigger;
|
3527
3528
|
return (0,external_vue_namespaceObject.createVNode)("div", {
|
3528
|
-
"
|
3529
|
+
"ref": "triggerRef",
|
3529
3530
|
"style": {
|
3530
3531
|
height: _this.autoHeight && _this.collapseTags ? '32px' : ''
|
3531
3532
|
},
|
3532
|
-
"
|
3533
|
+
"class": _this.resolveClassName('select-trigger'),
|
3533
3534
|
"onClick": _this.handleTogglePopover,
|
3534
3535
|
"onMouseenter": _this.setHover,
|
3535
3536
|
"onMouseleave": _this.cancelHover
|
@@ -3537,47 +3538,13 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3537
3538
|
selected: _this.selected
|
3538
3539
|
})) || renderTriggerInput()]);
|
3539
3540
|
};
|
3540
|
-
|
3541
|
-
|
3542
|
-
return (0,external_vue_namespaceObject.createVNode)("
|
3543
|
-
"class": _this.resolveClassName('select-content-wrapper'),
|
3544
|
-
"ref": "contentRef"
|
3545
|
-
}, [renderAll(), _this.filterable && !_this.inputSearch && (0,external_vue_namespaceObject.createVNode)("div", {
|
3546
|
-
"class": _this.resolveClassName('select-search-wrapper')
|
3547
|
-
}, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.Search, {
|
3548
|
-
"class": "icon-search",
|
3549
|
-
"width": 16,
|
3550
|
-
"height": 16
|
3551
|
-
}, null), (0,external_vue_namespaceObject.withDirectives)((0,external_vue_namespaceObject.createVNode)("input", {
|
3552
|
-
"ref": "searchRef",
|
3553
|
-
"class": _this.resolveClassName('select-search-input'),
|
3554
|
-
"placeholder": _this.localSearchPlaceholder,
|
3555
|
-
"onUpdate:modelValue": function onUpdateModelValue($event) {
|
3556
|
-
return _this.searchValue = $event;
|
3557
|
-
}
|
3558
|
-
}, null), [[external_vue_namespaceObject.vModelText, _this.searchValue]])]), !_this.isShowSelectContent && (0,external_vue_namespaceObject.createVNode)("div", {
|
3559
|
-
"class": _this.resolveClassName('select-empty')
|
3560
|
-
}, [_this.searchLoading && (0,external_vue_namespaceObject.createVNode)(loading_namespaceObject["default"], {
|
3561
|
-
"class": "mr5",
|
3562
|
-
"theme": "primary",
|
3563
|
-
"loading": true,
|
3564
|
-
"mode": "spin",
|
3565
|
-
"size": "mini"
|
3566
|
-
}, null), (0,external_vue_namespaceObject.createVNode)("span", null, [_this.curContentText])]), (0,external_vue_namespaceObject.createVNode)("div", {
|
3567
|
-
"class": _this.resolveClassName('select-content')
|
3568
|
-
}, [(0,external_vue_namespaceObject.createVNode)("div", {
|
3569
|
-
"class": _this.enableVirtualRender ? '' : _this.resolveClassName('select-dropdown'),
|
3570
|
-
"style": {
|
3571
|
-
maxHeight: "".concat(_this.scrollHeight, "px")
|
3572
|
-
},
|
3573
|
-
"onScroll": _this.handleScroll
|
3574
|
-
}, [(0,external_vue_namespaceObject.withDirectives)((0,external_vue_namespaceObject.createVNode)("ul", {
|
3575
|
-
"class": _this.resolveClassName('select-options')
|
3576
|
-
}, [renderSelectAll(), _this.enableVirtualRender ? (0,external_vue_namespaceObject.createVNode)(virtual_render_namespaceObject["default"], {
|
3577
|
-
"list": _this.virtualList,
|
3541
|
+
// 渲染列表模式
|
3542
|
+
var renderList = function renderList() {
|
3543
|
+
return _this.isEnableVirtualRender ? (0,external_vue_namespaceObject.createVNode)(virtual_render_namespaceObject["default"], {
|
3578
3544
|
"height": _this.virtualHeight,
|
3579
|
-
"lineHeight":
|
3580
|
-
"
|
3545
|
+
"lineHeight": _this.virtualLineHeight,
|
3546
|
+
"list": _this.virtualList,
|
3547
|
+
"preloadItemCount": _this.preloadItemCount
|
3581
3548
|
}, {
|
3582
3549
|
"default": function _default(_ref3) {
|
3583
3550
|
var _this$$slots8, _this$$slots9;
|
@@ -3585,8 +3552,8 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3585
3552
|
var optionRender = ((_this$$slots8 = _this.$slots) === null || _this$$slots8 === void 0 ? void 0 : _this$$slots8.optionRender) || ((_this$$slots9 = _this.$slots) === null || _this$$slots9 === void 0 ? void 0 : _this$$slots9.virtualScrollRender);
|
3586
3553
|
return data.map(function (item) {
|
3587
3554
|
return (0,external_vue_namespaceObject.createVNode)(src_option, {
|
3588
|
-
"key": item[_this.idKey],
|
3589
3555
|
"id": item[_this.idKey],
|
3556
|
+
"key": item[_this.idKey],
|
3590
3557
|
"name": item[_this.displayKey]
|
3591
3558
|
}, typeof optionRender === 'function' ? {
|
3592
3559
|
"default": function _default() {
|
@@ -3600,8 +3567,8 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3600
3567
|
}) : _this.list.map(function (item) {
|
3601
3568
|
var _this$$slots10;
|
3602
3569
|
return (0,external_vue_namespaceObject.createVNode)(src_option, {
|
3603
|
-
"key": item[_this.idKey],
|
3604
3570
|
"id": item[_this.idKey],
|
3571
|
+
"key": item[_this.idKey],
|
3605
3572
|
"name": item[_this.displayKey]
|
3606
3573
|
}, (_this$$slots10 = _this.$slots) !== null && _this$$slots10 !== void 0 && _this$$slots10.optionRender ? {
|
3607
3574
|
"default": function _default() {
|
@@ -3611,24 +3578,63 @@ function select_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { v
|
|
3611
3578
|
});
|
3612
3579
|
}
|
3613
3580
|
} : null);
|
3614
|
-
})
|
3581
|
+
});
|
3582
|
+
};
|
3583
|
+
// 渲染内容
|
3584
|
+
var renderSelectContent = function renderSelectContent() {
|
3585
|
+
var _this$$slots12, _this$$slots12$defaul, _this$$slots13, _this$$slots14;
|
3586
|
+
return (0,external_vue_namespaceObject.createVNode)("div", {
|
3587
|
+
"ref": "contentRef",
|
3588
|
+
"class": _this.resolveClassName('select-content-wrapper')
|
3589
|
+
}, [renderAll(), _this.filterable && !_this.inputSearch && (0,external_vue_namespaceObject.createVNode)("div", {
|
3590
|
+
"class": _this.resolveClassName('select-search-wrapper')
|
3591
|
+
}, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.Search, {
|
3592
|
+
"width": 16,
|
3593
|
+
"height": 16,
|
3594
|
+
"class": "icon-search"
|
3595
|
+
}, null), (0,external_vue_namespaceObject.withDirectives)((0,external_vue_namespaceObject.createVNode)("input", {
|
3596
|
+
"ref": "searchRef",
|
3597
|
+
"class": _this.resolveClassName('select-search-input'),
|
3598
|
+
"onUpdate:modelValue": function onUpdateModelValue($event) {
|
3599
|
+
return _this.searchValue = $event;
|
3600
|
+
},
|
3601
|
+
"placeholder": _this.localSearchPlaceholder
|
3602
|
+
}, null), [[external_vue_namespaceObject.vModelText, _this.searchValue]])]), !_this.isShowSelectContent && (0,external_vue_namespaceObject.createVNode)("div", {
|
3603
|
+
"class": _this.resolveClassName('select-empty')
|
3604
|
+
}, [_this.searchLoading && (0,external_vue_namespaceObject.createVNode)(loading_namespaceObject["default"], {
|
3605
|
+
"class": "mr5",
|
3606
|
+
"loading": true,
|
3607
|
+
"mode": "spin",
|
3608
|
+
"size": "mini",
|
3609
|
+
"theme": "primary"
|
3610
|
+
}, null), (0,external_vue_namespaceObject.createVNode)("span", null, [_this.curContentText])]), (0,external_vue_namespaceObject.createVNode)("div", {
|
3611
|
+
"class": _this.resolveClassName('select-content')
|
3612
|
+
}, [(0,external_vue_namespaceObject.createVNode)("div", {
|
3613
|
+
"style": {
|
3614
|
+
maxHeight: "".concat(_this.scrollHeight, "px"),
|
3615
|
+
minHeight: "".concat(_this.minHeight, "px")
|
3616
|
+
},
|
3617
|
+
"class": _this.isEnableVirtualRender ? '' : _this.resolveClassName('select-dropdown'),
|
3618
|
+
"onScroll": _this.handleScroll
|
3619
|
+
}, [(0,external_vue_namespaceObject.createVNode)("ul", {
|
3620
|
+
"class": _this.resolveClassName('select-options')
|
3621
|
+
}, [renderSelectAll(), renderList(), (_this$$slots12 = _this.$slots) === null || _this$$slots12 === void 0 || (_this$$slots12$defaul = _this$$slots12["default"]) === null || _this$$slots12$defaul === void 0 ? void 0 : _this$$slots12$defaul.call(_this$$slots12), _this.scrollLoading && (0,external_vue_namespaceObject.createVNode)("li", {
|
3615
3622
|
"class": _this.resolveClassName('select-options-loading')
|
3616
3623
|
}, [(0,external_vue_namespaceObject.createVNode)(loading_namespaceObject["default"], {
|
3617
3624
|
"class": "spinner mr5",
|
3618
|
-
"theme": "primary",
|
3619
3625
|
"loading": true,
|
3620
3626
|
"mode": "spin",
|
3621
|
-
"size": "mini"
|
3622
|
-
|
3627
|
+
"size": "mini",
|
3628
|
+
"theme": "primary"
|
3629
|
+
}, null), (0,external_vue_namespaceObject.createVNode)("span", null, [_this.localLoadingText])])])]), ((_this$$slots13 = _this.$slots) === null || _this$$slots13 === void 0 ? void 0 : _this$$slots13.extension) && (0,external_vue_namespaceObject.createVNode)("div", {
|
3623
3630
|
"class": _this.resolveClassName('select-extension')
|
3624
3631
|
}, [(_this$$slots14 = _this.$slots) === null || _this$$slots14 === void 0 ? void 0 : _this$$slots14.extension()])])]);
|
3625
3632
|
};
|
3626
3633
|
return (0,external_vue_namespaceObject.createVNode)("div", {
|
3627
3634
|
"class": selectClass
|
3628
3635
|
}, [(0,external_vue_namespaceObject.createVNode)(popover_namespaceObject["default"], (0,external_vue_namespaceObject.mergeProps)(this.popoverConfig, {
|
3629
|
-
"
|
3630
|
-
"
|
3631
|
-
"ref": "popoverRef"
|
3636
|
+
"ref": "popoverRef",
|
3637
|
+
"onClickoutside": this.handleClickOutside
|
3632
3638
|
}), {
|
3633
3639
|
"default": function _default() {
|
3634
3640
|
return renderSelectTrigger();
|
package/lib/select/option.d.ts
CHANGED
@@ -28,7 +28,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
28
28
|
handleOptionClick: () => void;
|
29
29
|
handleMouseEnter: () => void;
|
30
30
|
resolveClassName: (cls: string) => string;
|
31
|
-
transformNode: (str: string) =>
|
31
|
+
transformNode: (str: string) => (VNode | string)[] | string;
|
32
32
|
visible: import("vue").Ref<boolean>;
|
33
33
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
34
34
|
id: {
|
package/lib/select/select.css
CHANGED
@@ -330,9 +330,8 @@
|
|
330
330
|
.bk-popover.bk-pop2-content.bk-select-popover .bk-select-content-wrapper .bk-select-option {
|
331
331
|
position: relative;
|
332
332
|
display: flex;
|
333
|
-
height: 32px;
|
333
|
+
min-height: 32px;
|
334
334
|
padding: 0 12px;
|
335
|
-
line-height: 32px;
|
336
335
|
color: #63656e;
|
337
336
|
text-align: left;
|
338
337
|
cursor: pointer;
|