bkui-vue 2.0.2-beta.9 → 2.0.2-beta.90
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/License.txt +1 -2
- package/dist/cli.css +1 -0
- package/dist/index.cjs.js +166 -138
- package/dist/index.esm.js +24631 -18441
- package/dist/index.umd.js +166 -138
- package/dist/locale/en.esm.js.map +1 -1
- package/dist/locale/en.umd.js.map +1 -1
- package/dist/locale/ja-jp.esm.js +2 -0
- package/dist/locale/ja-jp.esm.js.map +1 -0
- package/dist/locale/ja-jp.umd.js +2 -0
- package/dist/locale/ja-jp.umd.js.map +1 -0
- package/dist/locale/zh-cn.esm.js.map +1 -1
- package/dist/locale/zh-cn.umd.js.map +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/affix/affix.variable.css +2 -1
- package/lib/affix/index.js +2 -2
- package/lib/alert/alert.variable.css +2 -1
- package/lib/alert/index.js +16 -5
- package/lib/animate-number/index.js +2 -2
- package/lib/backtop/backtop.variable.css +2 -1
- package/lib/backtop/index.js +2 -2
- package/lib/badge/badge.variable.css +2 -1
- package/lib/badge/index.js +2 -2
- package/lib/breadcrumb/breadcrumb.variable.css +2 -1
- package/lib/breadcrumb/index.js +3 -3
- package/lib/button/button.d.ts +1 -1
- package/lib/button/button.variable.css +2 -1
- package/lib/button/index.js +3 -3
- package/lib/card/card.variable.css +2 -1
- package/lib/card/index.js +2 -2
- package/lib/cascader/cascader.css +52 -25
- package/lib/cascader/cascader.d.ts +309 -0
- package/lib/cascader/cascader.less +109 -75
- package/lib/cascader/cascader.variable.css +54 -26
- package/lib/cascader/index.d.ts +618 -0
- package/lib/cascader/index.js +147 -65
- package/lib/checkbox/checkbox.variable.css +2 -1
- package/lib/checkbox/index.js +5 -5
- package/lib/code-diff/code-diff.variable.css +2 -1
- package/lib/code-diff/index.js +2 -2
- package/lib/collapse/collapse.variable.css +2 -1
- package/lib/collapse/index.js +3 -3
- package/lib/collapse-transition/collapse-transition.variable.css +2 -1
- package/lib/collapse-transition/index.js +2 -2
- package/lib/color-picker/color-picker.variable.css +2 -1
- package/lib/color-picker/index.js +64 -55
- package/lib/components.js +1 -1
- package/lib/config-provider/config-provider.variable.css +2 -1
- package/lib/config-provider/index.d.ts +1 -1
- package/lib/config-provider/index.js +6 -6
- package/lib/container/container.variable.css +2 -1
- package/lib/container/index.js +5 -5
- package/lib/date-picker/date-picker.d.ts +2 -1
- package/lib/date-picker/date-picker.variable.css +2 -1
- package/lib/date-picker/index.d.ts +6 -2
- package/lib/date-picker/index.js +79 -76
- package/lib/date-picker/panel/date-range.d.ts +2 -1
- package/lib/date-picker/panel/time.d.ts +1 -1
- package/lib/date-picker/utils.d.ts +5 -17
- package/lib/dialog/dialog.css +20 -1
- package/lib/dialog/dialog.variable.css +22 -2
- package/lib/dialog/index.js +13 -36
- package/lib/directives/index.js +8 -9
- package/lib/dist.index.js +1 -1
- package/lib/divider/divider.variable.css +2 -1
- package/lib/divider/index.js +3 -3
- package/lib/dropdown/dropdown.d.ts +1 -0
- package/lib/dropdown/dropdown.variable.css +2 -1
- package/lib/dropdown/index.d.ts +3 -0
- package/lib/dropdown/index.js +15 -10
- package/lib/exception/exception.variable.css +2 -1
- package/lib/exception/index.js +2 -2
- package/lib/fixed-navbar/fixed-navbar.variable.css +2 -1
- package/lib/fixed-navbar/index.js +2 -2
- package/lib/form/form-item.d.ts +19 -0
- package/lib/form/form.css +17 -4
- package/lib/form/form.less +25 -6
- package/lib/form/form.variable.css +19 -5
- package/lib/form/index.d.ts +13 -0
- package/lib/form/index.js +43 -50
- package/lib/hooks.js +1 -1
- package/lib/icon/angle-double-down-line.js +1 -1
- package/lib/icon/angle-double-left-line.js +1 -1
- package/lib/icon/angle-double-left.js +1 -1
- package/lib/icon/angle-double-right-line.js +1 -1
- package/lib/icon/angle-double-right.js +1 -1
- package/lib/icon/angle-double-up-line.js +1 -1
- package/lib/icon/angle-down-fill.js +1 -1
- package/lib/icon/angle-down-line.js +1 -1
- package/lib/icon/angle-down.js +1 -1
- package/lib/icon/angle-left.js +1 -1
- package/lib/icon/angle-right.js +1 -1
- package/lib/icon/angle-up-fill.js +1 -1
- package/lib/icon/angle-up.js +1 -1
- package/lib/icon/archive-fill.js +1 -1
- package/lib/icon/arrows-left.js +1 -1
- package/lib/icon/arrows-right.js +1 -1
- package/lib/icon/assistant.js +1 -1
- package/lib/icon/audio-fill.js +1 -1
- package/lib/icon/bk.js +1 -1
- package/lib/icon/circle.js +1 -1
- package/lib/icon/close-line.js +1 -1
- package/lib/icon/close.js +1 -1
- package/lib/icon/code.js +1 -1
- package/lib/icon/cog-shape.js +1 -1
- package/lib/icon/collapse-left.js +1 -1
- package/lib/icon/copy-shape.js +1 -1
- package/lib/icon/copy.js +1 -1
- package/lib/icon/data-shape.js +1 -1
- package/lib/icon/del.js +1 -1
- package/lib/icon/doc-fill.js +1 -1
- package/lib/icon/done.js +1 -1
- package/lib/icon/down-shape.js +1 -1
- package/lib/icon/down-small.js +1 -1
- package/lib/icon/edit-line.js +1 -1
- package/lib/icon/ellipsis.js +1 -1
- package/lib/icon/enlarge-line.js +1 -1
- package/lib/icon/error.js +1 -1
- package/lib/icon/excel-fill.js +1 -1
- package/lib/icon/exclamation-circle-shape.js +1 -1
- package/lib/icon/eye.js +1 -1
- package/lib/icon/filliscreen-line.js +1 -1
- package/lib/icon/fix-line.js +1 -1
- package/lib/icon/fix-shape.js +1 -1
- package/lib/icon/folder-open.js +1 -1
- package/lib/icon/folder-shape-open.js +1 -1
- package/lib/icon/folder-shape.js +1 -1
- package/lib/icon/folder.js +1 -1
- package/lib/icon/funnel.js +1 -1
- package/lib/icon/grag-fill.js +1 -1
- package/lib/icon/help-document-fill.js +1 -1
- package/lib/icon/help-fill.js +1 -1
- package/lib/icon/help.js +1 -1
- package/lib/icon/image-fill.js +1 -1
- package/lib/icon/img-error.js +1 -1
- package/lib/icon/img-placehoulder.js +1 -1
- package/lib/icon/index.js +1 -1
- package/lib/icon/info-line.js +1 -1
- package/lib/icon/info.js +1 -1
- package/lib/icon/left-shape.js +1 -1
- package/lib/icon/left-turn-line.js +1 -1
- package/lib/icon/loading.js +1 -1
- package/lib/icon/narrow-line.js +1 -1
- package/lib/icon/original.js +1 -1
- package/lib/icon/pdf-fill.js +1 -1
- package/lib/icon/play-shape.js +1 -1
- package/lib/icon/plus.js +1 -1
- package/lib/icon/ppt-fill.js +1 -1
- package/lib/icon/qq.js +1 -1
- package/lib/icon/right-shape.js +1 -1
- package/lib/icon/right-turn-line.js +1 -1
- package/lib/icon/search.js +1 -1
- package/lib/icon/share.js +1 -1
- package/lib/icon/spinner.js +1 -1
- package/lib/icon/success.js +1 -1
- package/lib/icon/switcher-loading.js +1 -1
- package/lib/icon/text-all.js +1 -1
- package/lib/icon/text-file.js +1 -1
- package/lib/icon/text-fill.js +1 -1
- package/lib/icon/transfer.js +1 -1
- package/lib/icon/tree-application-shape.js +1 -1
- package/lib/icon/unfull-screen.js +1 -1
- package/lib/icon/unvisible.js +1 -1
- package/lib/icon/up-shape.js +1 -1
- package/lib/icon/upload.js +1 -1
- package/lib/icon/video-fill.js +1 -1
- package/lib/icon/warn.js +1 -1
- package/lib/icon/weixin-pro.js +1 -1
- package/lib/icon/weixin.js +1 -1
- package/lib/image/image-viewer.variable.css +2 -1
- package/lib/image/image.variable.css +2 -1
- package/lib/image/index.js +11 -12
- package/lib/index.js +1 -1
- package/lib/info-box/index.js +22 -7
- package/lib/info-box/info-box.css +20 -1
- package/lib/info-box/info-box.d.ts +1 -0
- package/lib/info-box/info-box.less +28 -2
- package/lib/info-box/info-box.variable.css +23 -3
- package/lib/input/index.d.ts +45 -20
- package/lib/input/index.js +57 -29
- package/lib/input/input.css +6 -0
- package/lib/input/input.d.ts +35 -17
- package/lib/input/input.less +7 -0
- package/lib/input/input.variable.css +8 -1
- package/lib/link/index.js +2 -2
- package/lib/link/link.variable.css +2 -1
- package/lib/loading/index.js +15 -7
- package/lib/loading/loading.variable.css +2 -1
- package/lib/locale/index.d.ts +1 -0
- package/lib/locale/index.js +172 -4
- package/lib/locale/lang/ja-jp.d.ts +3 -0
- package/lib/menu/index.js +12 -9
- package/lib/menu/menu.css +5 -4
- package/lib/menu/menu.less +1 -0
- package/lib/menu/menu.variable.css +7 -5
- package/lib/menu/submenu.variable.css +2 -1
- package/lib/message/index.js +62 -28
- package/lib/message/message.variable.css +2 -1
- package/lib/message/messageConstructor.d.ts +1 -1
- package/lib/modal/index.js +19 -8
- package/lib/modal/modal.css +20 -1
- package/lib/modal/modal.variable.css +22 -2
- package/lib/navigation/index.js +3 -3
- package/lib/navigation/navigation.css +29 -29
- package/lib/navigation/navigation.less +29 -29
- package/lib/navigation/navigation.variable.css +31 -30
- package/lib/notify/index.js +43 -24
- package/lib/notify/notify.variable.css +2 -1
- package/lib/overflow-title/components/overflow-title.d.ts +6 -2
- package/lib/overflow-title/index.d.ts +12 -4
- package/lib/overflow-title/index.js +3 -3
- package/lib/overflow-title/props.d.ts +3 -1
- package/lib/pagination/index.js +22 -14
- package/lib/pagination/pagination.css +1 -0
- package/lib/pagination/pagination.less +1 -0
- package/lib/pagination/pagination.variable.css +3 -1
- package/lib/pop-confirm/index.d.ts +592 -0
- package/lib/pop-confirm/index.js +10 -6
- package/lib/pop-confirm/pop-confirm.d.ts +296 -0
- package/lib/pop-confirm/pop-confirm.variable.css +2 -1
- package/lib/pop-confirm/props.d.ts +148 -0
- package/lib/popover/index.d.ts +18 -10
- package/lib/popover/index.js +281 -76
- package/lib/popover/popover.d.ts +8 -4
- package/lib/popover/popover.variable.css +2 -1
- package/lib/popover/props.d.ts +3 -1
- package/lib/popover/use-floating.d.ts +2 -2
- package/lib/popover/use-popover-init.d.ts +2 -2
- package/lib/popover/use-popper-id.d.ts +3 -1
- package/lib/popover2/index.js +2 -2
- package/lib/preset.js +1 -1
- package/lib/process/index.js +2 -2
- package/lib/process/process.d.ts +1 -1
- package/lib/process/process.variable.css +2 -1
- package/lib/progress/index.js +4 -4
- package/lib/progress/progress.variable.css +2 -1
- package/lib/radio/index.js +5 -5
- package/lib/radio/radio.variable.css +2 -1
- package/lib/rate/index.js +3 -3
- package/lib/rate/rate.variable.css +2 -1
- package/lib/resize-layout/index.js +2 -2
- package/lib/resize-layout/resize-layout.css +1 -0
- package/lib/resize-layout/resize-layout.less +1 -0
- package/lib/resize-layout/resize-layout.variable.css +3 -1
- package/lib/scrollbar/css/scrollbar.variable.css +2 -1
- package/lib/scrollbar/index.js +6 -6
- package/lib/search-select/index.d.ts +43 -15
- package/lib/search-select/index.js +88 -37
- package/lib/search-select/input.d.ts +5 -1
- package/lib/search-select/search-select.d.ts +14 -5
- package/lib/search-select/search-select.variable.css +2 -1
- package/lib/search-select/selected.d.ts +10 -2
- package/lib/search-select/utils.d.ts +1 -0
- package/lib/select/common.d.ts +0 -1
- package/lib/select/index.d.ts +58 -11
- package/lib/select/index.js +68 -66
- package/lib/select/optionGroup.d.ts +12 -1
- package/lib/select/select.d.ts +21 -4
- package/lib/select/select.variable.css +2 -1
- package/lib/select/type.d.ts +1 -0
- package/lib/shared/index.d.ts +1 -1
- package/lib/shared/index.js +10 -10
- package/lib/shared/z-index-manager.d.ts +1 -1
- package/lib/sideslider/index.d.ts +129 -2
- package/lib/sideslider/index.js +149 -11
- package/lib/sideslider/sideslider.css +62 -0
- package/lib/sideslider/sideslider.d.ts +59 -1
- package/lib/sideslider/sideslider.less +83 -0
- package/lib/sideslider/sideslider.variable.css +64 -1
- package/lib/slider/index.d.ts +1 -1
- package/lib/slider/index.js +5 -4
- package/lib/slider/slider-button.d.ts +1 -1
- package/lib/slider/slider.d.ts +1 -1
- package/lib/slider/slider.variable.css +2 -1
- package/lib/steps/index.js +13 -14
- package/lib/steps/steps.css +24 -11
- package/lib/steps/steps.d.ts +1 -1
- package/lib/steps/steps.less +28 -10
- package/lib/steps/steps.variable.css +26 -12
- package/lib/styles/mixins/animate.variable.css +2 -1
- package/lib/styles/mixins/popper.variable.css +2 -1
- package/lib/styles/mixins/scroll.variable.css +2 -1
- package/lib/styles/reset.variable.css +2 -1
- package/lib/styles/themes/themes.less +4 -1
- package/lib/swiper/index.js +2 -2
- package/lib/swiper/swiper.variable.css +2 -1
- package/lib/switcher/index.js +2 -2
- package/lib/switcher/switcher.variable.css +2 -1
- package/lib/tab/index.d.ts +12 -0
- package/lib/tab/index.js +22 -17
- package/lib/tab/props.d.ts +3 -0
- package/lib/tab/tab.d.ts +6 -0
- package/lib/tab/tab.variable.css +2 -1
- package/lib/table/index.js +35 -36
- package/lib/table/plugins/head-filter.variable.css +2 -1
- package/lib/table/plugins/head-sort.variable.css +2 -1
- package/lib/table/plugins/settings.variable.css +2 -1
- package/lib/table/table.css +1 -0
- package/lib/table/table.variable.css +3 -1
- package/lib/table-column/index.js +1 -1
- package/lib/tag/index.d.ts +23 -0
- package/lib/tag/index.js +10 -5
- package/lib/tag/tag.d.ts +11 -0
- package/lib/tag/tag.variable.css +2 -1
- package/lib/tag-input/index.d.ts +82 -9
- package/lib/tag-input/index.js +1639 -54
- package/lib/tag-input/tag-input.css +31 -0
- package/lib/tag-input/tag-input.d.ts +36 -4
- package/lib/tag-input/tag-input.less +36 -0
- package/lib/tag-input/tag-input.variable.css +33 -1
- package/lib/tag-input/tag-props.d.ts +13 -1
- package/lib/tag-input/tag-render.d.ts +24 -2
- package/lib/time-picker/index.js +1 -1
- package/lib/time-picker/time-picker.variable.css +2 -1
- package/lib/timeline/index.d.ts +7 -7
- package/lib/timeline/index.js +1375 -9
- package/lib/timeline/timeline.d.ts +5 -5
- package/lib/timeline/timeline.variable.css +2 -1
- package/lib/transfer/index.d.ts +1 -24
- package/lib/transfer/index.js +21 -11
- package/lib/transfer/props.d.ts +0 -5
- package/lib/transfer/transfer.css +26 -8
- package/lib/transfer/transfer.d.ts +1 -12
- package/lib/transfer/transfer.less +18 -8
- package/lib/transfer/transfer.variable.css +28 -9
- package/lib/tree/constant.d.ts +2 -0
- package/lib/tree/index.d.ts +67 -11
- package/lib/tree/index.js +17694 -103
- package/lib/tree/props.d.ts +37 -3
- package/lib/tree/tree.css +34 -0
- package/lib/tree/tree.d.ts +31 -5
- package/lib/tree/tree.less +41 -2
- package/lib/tree/tree.variable.css +36 -1
- package/lib/tree/use-array-move.d.ts +6 -0
- package/lib/tree/use-node-action.d.ts +3 -1
- package/lib/tree/use-node-attribute.d.ts +3 -0
- package/lib/upload/index.js +8 -8
- package/lib/upload/upload.variable.css +2 -1
- package/lib/virtual-render/index.js +7 -7
- package/lib/virtual-render/virtual-render.variable.css +2 -1
- package/lib/volar.components.d.ts +2 -1
- package/package.json +13 -2
- package/dist/style.css +0 -1
package/lib/shared/index.js
CHANGED
|
@@ -121,7 +121,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
121
121
|
* Tencent is pleased to support the open source community by making
|
|
122
122
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
123
123
|
*
|
|
124
|
-
* Copyright (C)
|
|
124
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
125
125
|
*
|
|
126
126
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
127
127
|
*
|
|
@@ -215,7 +215,7 @@ function _typeof(o) {
|
|
|
215
215
|
* Tencent is pleased to support the open source community by making
|
|
216
216
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
217
217
|
*
|
|
218
|
-
* Copyright (C)
|
|
218
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
219
219
|
*
|
|
220
220
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
221
221
|
*
|
|
@@ -476,7 +476,7 @@ const external_vue_namespaceObject = x({ ["inject"]: () => __WEBPACK_EXTERNAL_MO
|
|
|
476
476
|
* Tencent is pleased to support the open source community by making
|
|
477
477
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
478
478
|
*
|
|
479
|
-
* Copyright (C)
|
|
479
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
480
480
|
*
|
|
481
481
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
482
482
|
*
|
|
@@ -504,7 +504,7 @@ var formItemKey = Symbol('formItem');
|
|
|
504
504
|
* Tencent is pleased to support the open source community by making
|
|
505
505
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
506
506
|
*
|
|
507
|
-
* Copyright (C)
|
|
507
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
508
508
|
*
|
|
509
509
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
510
510
|
*
|
|
@@ -535,7 +535,7 @@ var useForm = function useForm() {
|
|
|
535
535
|
* Tencent is pleased to support the open source community by making
|
|
536
536
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
537
537
|
*
|
|
538
|
-
* Copyright (C)
|
|
538
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
539
539
|
*
|
|
540
540
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
541
541
|
*
|
|
@@ -760,7 +760,7 @@ function v4(options, buf, offset) {
|
|
|
760
760
|
* Tencent is pleased to support the open source community by making
|
|
761
761
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
762
762
|
*
|
|
763
|
-
* Copyright (C)
|
|
763
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
764
764
|
*
|
|
765
765
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
766
766
|
*
|
|
@@ -1158,7 +1158,7 @@ var getPopContainerId = function getPopContainerId() {
|
|
|
1158
1158
|
* Tencent is pleased to support the open source community by making
|
|
1159
1159
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
1160
1160
|
*
|
|
1161
|
-
* Copyright (C)
|
|
1161
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
1162
1162
|
*
|
|
1163
1163
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
1164
1164
|
*
|
|
@@ -1208,7 +1208,7 @@ const throttle_namespaceObject = throttle_x({ ["default"]: () => __WEBPACK_EXTER
|
|
|
1208
1208
|
* Tencent is pleased to support the open source community by making
|
|
1209
1209
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
1210
1210
|
*
|
|
1211
|
-
* Copyright (C)
|
|
1211
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
1212
1212
|
*
|
|
1213
1213
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
1214
1214
|
*
|
|
@@ -1422,7 +1422,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
1422
1422
|
* Tencent is pleased to support the open source community by making
|
|
1423
1423
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
1424
1424
|
*
|
|
1425
|
-
* Copyright (C)
|
|
1425
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
1426
1426
|
*
|
|
1427
1427
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
1428
1428
|
*
|
|
@@ -1725,7 +1725,7 @@ function SelectedType() {
|
|
|
1725
1725
|
* Tencent is pleased to support the open source community by making
|
|
1726
1726
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
1727
1727
|
*
|
|
1728
|
-
* Copyright (C)
|
|
1728
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
1729
1729
|
*
|
|
1730
1730
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
1731
1731
|
*
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Tencent is pleased to support the open source community by making
|
|
3
3
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
4
4
|
*
|
|
5
|
-
* Copyright (C)
|
|
5
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
6
6
|
*
|
|
7
7
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
8
8
|
*
|
|
@@ -10,6 +10,31 @@ declare const BkSideslider: {
|
|
|
10
10
|
default: string;
|
|
11
11
|
validator: (value: string) => boolean;
|
|
12
12
|
};
|
|
13
|
+
resizable: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
14
|
+
default: boolean;
|
|
15
|
+
} & {
|
|
16
|
+
default: boolean;
|
|
17
|
+
};
|
|
18
|
+
minWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
19
|
+
default: number;
|
|
20
|
+
} & {
|
|
21
|
+
default: number;
|
|
22
|
+
};
|
|
23
|
+
maxWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
24
|
+
default: number;
|
|
25
|
+
} & {
|
|
26
|
+
default: number;
|
|
27
|
+
};
|
|
28
|
+
triggerWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
29
|
+
default: number;
|
|
30
|
+
} & {
|
|
31
|
+
default: number;
|
|
32
|
+
};
|
|
33
|
+
immediate: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
34
|
+
default: boolean;
|
|
35
|
+
} & {
|
|
36
|
+
default: boolean;
|
|
37
|
+
};
|
|
13
38
|
isShow: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
14
39
|
default: boolean;
|
|
15
40
|
} & {
|
|
@@ -75,8 +100,11 @@ declare const BkSideslider: {
|
|
|
75
100
|
onShown?: (...args: any[]) => any;
|
|
76
101
|
onClosed?: (...args: any[]) => any;
|
|
77
102
|
"onUpdate:isShow"?: (...args: any[]) => any;
|
|
103
|
+
"onBefore-resize"?: (...args: any[]) => any;
|
|
104
|
+
onResizing?: (...args: any[]) => any;
|
|
105
|
+
"onAfter-resize"?: (...args: any[]) => any;
|
|
78
106
|
"onAnimation-end"?: (...args: any[]) => any;
|
|
79
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("hidden" | "shown" | "closed" | "update:isShow" | "animation-end")[], import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & Readonly<import("vue").ExtractPropTypes<{
|
|
107
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("hidden" | "shown" | "closed" | "update:isShow" | "before-resize" | "resizing" | "after-resize" | "animation-end")[], import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & Readonly<import("vue").ExtractPropTypes<{
|
|
80
108
|
title: import("vue-types").VueTypeValidableDef<string> & {
|
|
81
109
|
default: string;
|
|
82
110
|
} & {
|
|
@@ -87,6 +115,31 @@ declare const BkSideslider: {
|
|
|
87
115
|
default: string;
|
|
88
116
|
validator: (value: string) => boolean;
|
|
89
117
|
};
|
|
118
|
+
resizable: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
119
|
+
default: boolean;
|
|
120
|
+
} & {
|
|
121
|
+
default: boolean;
|
|
122
|
+
};
|
|
123
|
+
minWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
124
|
+
default: number;
|
|
125
|
+
} & {
|
|
126
|
+
default: number;
|
|
127
|
+
};
|
|
128
|
+
maxWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
129
|
+
default: number;
|
|
130
|
+
} & {
|
|
131
|
+
default: number;
|
|
132
|
+
};
|
|
133
|
+
triggerWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
134
|
+
default: number;
|
|
135
|
+
} & {
|
|
136
|
+
default: number;
|
|
137
|
+
};
|
|
138
|
+
immediate: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
139
|
+
default: boolean;
|
|
140
|
+
} & {
|
|
141
|
+
default: boolean;
|
|
142
|
+
};
|
|
90
143
|
isShow: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
91
144
|
default: boolean;
|
|
92
145
|
} & {
|
|
@@ -152,9 +205,13 @@ declare const BkSideslider: {
|
|
|
152
205
|
onShown?: (...args: any[]) => any;
|
|
153
206
|
onClosed?: (...args: any[]) => any;
|
|
154
207
|
"onUpdate:isShow"?: (...args: any[]) => any;
|
|
208
|
+
"onBefore-resize"?: (...args: any[]) => any;
|
|
209
|
+
onResizing?: (...args: any[]) => any;
|
|
210
|
+
"onAfter-resize"?: (...args: any[]) => any;
|
|
155
211
|
"onAnimation-end"?: (...args: any[]) => any;
|
|
156
212
|
}, {
|
|
157
213
|
title: string;
|
|
214
|
+
maxWidth: number;
|
|
158
215
|
extCls: string;
|
|
159
216
|
left: string;
|
|
160
217
|
top: string;
|
|
@@ -163,6 +220,7 @@ declare const BkSideslider: {
|
|
|
163
220
|
backgroundColor: string;
|
|
164
221
|
transfer: string | boolean | HTMLElement;
|
|
165
222
|
direction: string;
|
|
223
|
+
resizable: boolean;
|
|
166
224
|
fullscreen: boolean;
|
|
167
225
|
showMask: boolean;
|
|
168
226
|
closeIcon: boolean;
|
|
@@ -170,6 +228,9 @@ declare const BkSideslider: {
|
|
|
170
228
|
quickClose: boolean;
|
|
171
229
|
animateType: string;
|
|
172
230
|
beforeClose: () => boolean | Promise<boolean>;
|
|
231
|
+
minWidth: number;
|
|
232
|
+
triggerWidth: number;
|
|
233
|
+
immediate: boolean;
|
|
173
234
|
}, true, {}, {}, {
|
|
174
235
|
P: {};
|
|
175
236
|
B: {};
|
|
@@ -188,6 +249,31 @@ declare const BkSideslider: {
|
|
|
188
249
|
default: string;
|
|
189
250
|
validator: (value: string) => boolean;
|
|
190
251
|
};
|
|
252
|
+
resizable: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
253
|
+
default: boolean;
|
|
254
|
+
} & {
|
|
255
|
+
default: boolean;
|
|
256
|
+
};
|
|
257
|
+
minWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
258
|
+
default: number;
|
|
259
|
+
} & {
|
|
260
|
+
default: number;
|
|
261
|
+
};
|
|
262
|
+
maxWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
263
|
+
default: number;
|
|
264
|
+
} & {
|
|
265
|
+
default: number;
|
|
266
|
+
};
|
|
267
|
+
triggerWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
268
|
+
default: number;
|
|
269
|
+
} & {
|
|
270
|
+
default: number;
|
|
271
|
+
};
|
|
272
|
+
immediate: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
273
|
+
default: boolean;
|
|
274
|
+
} & {
|
|
275
|
+
default: boolean;
|
|
276
|
+
};
|
|
191
277
|
isShow: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
192
278
|
default: boolean;
|
|
193
279
|
} & {
|
|
@@ -253,9 +339,13 @@ declare const BkSideslider: {
|
|
|
253
339
|
onShown?: (...args: any[]) => any;
|
|
254
340
|
onClosed?: (...args: any[]) => any;
|
|
255
341
|
"onUpdate:isShow"?: (...args: any[]) => any;
|
|
342
|
+
"onBefore-resize"?: (...args: any[]) => any;
|
|
343
|
+
onResizing?: (...args: any[]) => any;
|
|
344
|
+
"onAfter-resize"?: (...args: any[]) => any;
|
|
256
345
|
"onAnimation-end"?: (...args: any[]) => any;
|
|
257
346
|
}, () => JSX.Element, {}, {}, {}, {
|
|
258
347
|
title: string;
|
|
348
|
+
maxWidth: number;
|
|
259
349
|
extCls: string;
|
|
260
350
|
left: string;
|
|
261
351
|
top: string;
|
|
@@ -264,6 +354,7 @@ declare const BkSideslider: {
|
|
|
264
354
|
backgroundColor: string;
|
|
265
355
|
transfer: string | boolean | HTMLElement;
|
|
266
356
|
direction: string;
|
|
357
|
+
resizable: boolean;
|
|
267
358
|
fullscreen: boolean;
|
|
268
359
|
showMask: boolean;
|
|
269
360
|
closeIcon: boolean;
|
|
@@ -271,6 +362,9 @@ declare const BkSideslider: {
|
|
|
271
362
|
quickClose: boolean;
|
|
272
363
|
animateType: string;
|
|
273
364
|
beforeClose: () => boolean | Promise<boolean>;
|
|
365
|
+
minWidth: number;
|
|
366
|
+
triggerWidth: number;
|
|
367
|
+
immediate: boolean;
|
|
274
368
|
}>;
|
|
275
369
|
__isFragment?: never;
|
|
276
370
|
__isTeleport?: never;
|
|
@@ -286,6 +380,31 @@ declare const BkSideslider: {
|
|
|
286
380
|
default: string;
|
|
287
381
|
validator: (value: string) => boolean;
|
|
288
382
|
};
|
|
383
|
+
resizable: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
384
|
+
default: boolean;
|
|
385
|
+
} & {
|
|
386
|
+
default: boolean;
|
|
387
|
+
};
|
|
388
|
+
minWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
389
|
+
default: number;
|
|
390
|
+
} & {
|
|
391
|
+
default: number;
|
|
392
|
+
};
|
|
393
|
+
maxWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
394
|
+
default: number;
|
|
395
|
+
} & {
|
|
396
|
+
default: number;
|
|
397
|
+
};
|
|
398
|
+
triggerWidth: import("vue-types").VueTypeValidableDef<number> & {
|
|
399
|
+
default: number;
|
|
400
|
+
} & {
|
|
401
|
+
default: number;
|
|
402
|
+
};
|
|
403
|
+
immediate: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
404
|
+
default: boolean;
|
|
405
|
+
} & {
|
|
406
|
+
default: boolean;
|
|
407
|
+
};
|
|
289
408
|
isShow: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
290
409
|
default: boolean;
|
|
291
410
|
} & {
|
|
@@ -351,9 +470,13 @@ declare const BkSideslider: {
|
|
|
351
470
|
onShown?: (...args: any[]) => any;
|
|
352
471
|
onClosed?: (...args: any[]) => any;
|
|
353
472
|
"onUpdate:isShow"?: (...args: any[]) => any;
|
|
473
|
+
"onBefore-resize"?: (...args: any[]) => any;
|
|
474
|
+
onResizing?: (...args: any[]) => any;
|
|
475
|
+
"onAfter-resize"?: (...args: any[]) => any;
|
|
354
476
|
"onAnimation-end"?: (...args: any[]) => any;
|
|
355
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("hidden" | "shown" | "closed" | "update:isShow" | "animation-end")[], "hidden" | "shown" | "closed" | "update:isShow" | "animation-end", {
|
|
477
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("hidden" | "shown" | "closed" | "update:isShow" | "before-resize" | "resizing" | "after-resize" | "animation-end")[], "hidden" | "shown" | "closed" | "update:isShow" | "before-resize" | "resizing" | "after-resize" | "animation-end", {
|
|
356
478
|
title: string;
|
|
479
|
+
maxWidth: number;
|
|
357
480
|
extCls: string;
|
|
358
481
|
left: string;
|
|
359
482
|
top: string;
|
|
@@ -362,6 +485,7 @@ declare const BkSideslider: {
|
|
|
362
485
|
backgroundColor: string;
|
|
363
486
|
transfer: string | boolean | HTMLElement;
|
|
364
487
|
direction: string;
|
|
488
|
+
resizable: boolean;
|
|
365
489
|
fullscreen: boolean;
|
|
366
490
|
showMask: boolean;
|
|
367
491
|
closeIcon: boolean;
|
|
@@ -369,5 +493,8 @@ declare const BkSideslider: {
|
|
|
369
493
|
quickClose: boolean;
|
|
370
494
|
animateType: string;
|
|
371
495
|
beforeClose: () => boolean | Promise<boolean>;
|
|
496
|
+
minWidth: number;
|
|
497
|
+
triggerWidth: number;
|
|
498
|
+
immediate: boolean;
|
|
372
499
|
}, {}, string, {}> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & import("vue").Plugin<any[]>;
|
|
373
500
|
export default BkSideslider;
|
package/lib/sideslider/index.js
CHANGED
|
@@ -506,7 +506,7 @@ function _defineProperty(obj, key, value) {
|
|
|
506
506
|
;// CONCATENATED MODULE: external "vue"
|
|
507
507
|
var external_vue_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
|
508
508
|
var external_vue_y = x => () => x
|
|
509
|
-
const external_vue_namespaceObject = external_vue_x({ ["Fragment"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.Fragment, ["createVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createVNode, ["defineComponent"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.defineComponent, ["getCurrentInstance"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.getCurrentInstance, ["isVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.isVNode, ["mergeProps"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.mergeProps, ["useAttrs"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.useAttrs, ["useSlots"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.useSlots });
|
|
509
|
+
const external_vue_namespaceObject = external_vue_x({ ["Fragment"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.Fragment, ["createVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createVNode, ["defineComponent"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.defineComponent, ["getCurrentInstance"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.getCurrentInstance, ["isVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.isVNode, ["mergeProps"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.mergeProps, ["nextTick"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.nextTick, ["ref"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.ref, ["useAttrs"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.useAttrs, ["useSlots"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.useSlots, ["watch"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.watch, ["withModifiers"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.withModifiers });
|
|
510
510
|
// EXTERNAL MODULE: ../../node_modules/@babel/runtime/regenerator/index.js
|
|
511
511
|
var regenerator = __webpack_require__(2841);
|
|
512
512
|
var regenerator_default = /*#__PURE__*/__webpack_require__.n(regenerator);
|
|
@@ -541,7 +541,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
541
541
|
* Tencent is pleased to support the open source community by making
|
|
542
542
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
543
543
|
*
|
|
544
|
-
* Copyright (C)
|
|
544
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
545
545
|
*
|
|
546
546
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
547
547
|
*
|
|
@@ -591,9 +591,14 @@ sliderProps.width["default"] = '400';
|
|
|
591
591
|
}
|
|
592
592
|
return true;
|
|
593
593
|
}
|
|
594
|
-
}
|
|
594
|
+
},
|
|
595
|
+
resizable: shared_namespaceObject.PropTypes.bool.def(false),
|
|
596
|
+
minWidth: shared_namespaceObject.PropTypes.number.def(400),
|
|
597
|
+
maxWidth: shared_namespaceObject.PropTypes.number.def(Infinity),
|
|
598
|
+
triggerWidth: shared_namespaceObject.PropTypes.number.def(5),
|
|
599
|
+
immediate: shared_namespaceObject.PropTypes.bool.def(false) // 是否实时拖拽(拖拽时立即改变宽度)
|
|
595
600
|
}),
|
|
596
|
-
emits: ['closed', 'update:isShow', 'shown', 'hidden', 'animation-end'],
|
|
601
|
+
emits: ['closed', 'update:isShow', 'shown', 'hidden', 'animation-end', 'before-resize', 'resizing', 'after-resize'],
|
|
597
602
|
setup: function setup(props, _ref) {
|
|
598
603
|
var emit = _ref.emit;
|
|
599
604
|
var attrs = (0,external_vue_namespaceObject.useAttrs)();
|
|
@@ -601,6 +606,20 @@ sliderProps.width["default"] = '400';
|
|
|
601
606
|
var instance = (0,external_vue_namespaceObject.getCurrentInstance)();
|
|
602
607
|
var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
|
|
603
608
|
resolveClassName = _usePrefix.resolveClassName;
|
|
609
|
+
// 拖拽相关状态
|
|
610
|
+
var currentWidth = (0,external_vue_namespaceObject.ref)(props.width);
|
|
611
|
+
// 代理线
|
|
612
|
+
var resizeProxyRef = (0,external_vue_namespaceObject.ref)(null);
|
|
613
|
+
// 遮罩
|
|
614
|
+
var resizeMaskRef = (0,external_vue_namespaceObject.ref)(null);
|
|
615
|
+
// modalWrapper
|
|
616
|
+
var modalWrapperRef = (0,external_vue_namespaceObject.ref)(null);
|
|
617
|
+
// content
|
|
618
|
+
var contentRef = (0,external_vue_namespaceObject.ref)(null);
|
|
619
|
+
// trigger
|
|
620
|
+
var triggerRef = (0,external_vue_namespaceObject.ref)(null);
|
|
621
|
+
// state
|
|
622
|
+
var state = (0,external_vue_namespaceObject.ref)({});
|
|
604
623
|
var handleClose = /*#__PURE__*/function () {
|
|
605
624
|
var _ref2 = _asyncToGenerator( /*#__PURE__*/regenerator_default().mark(function _callee() {
|
|
606
625
|
var shouldClose;
|
|
@@ -634,10 +653,115 @@ sliderProps.width["default"] = '400';
|
|
|
634
653
|
}();
|
|
635
654
|
var handleShown = function handleShown() {
|
|
636
655
|
emit('shown');
|
|
656
|
+
// 当侧边栏显示后,获取 modalWrapper 的引用
|
|
657
|
+
if (props.resizable && contentRef.value) {
|
|
658
|
+
(0,external_vue_namespaceObject.nextTick)(function () {
|
|
659
|
+
var _contentRef$value;
|
|
660
|
+
// 从当前实例的 content 元素向上查找 modal-wrapper,避免多个实例冲突
|
|
661
|
+
var element = (_contentRef$value = contentRef.value) === null || _contentRef$value === void 0 ? void 0 : _contentRef$value.parentElement;
|
|
662
|
+
while (element) {
|
|
663
|
+
if (element.classList.contains(resolveClassName('modal-wrapper'))) {
|
|
664
|
+
modalWrapperRef.value = element;
|
|
665
|
+
break;
|
|
666
|
+
}
|
|
667
|
+
element = element.parentElement;
|
|
668
|
+
}
|
|
669
|
+
});
|
|
670
|
+
}
|
|
637
671
|
};
|
|
638
672
|
var handleHidden = function handleHidden() {
|
|
639
673
|
emit('hidden');
|
|
674
|
+
// 清理引用
|
|
675
|
+
if (props.resizable) {
|
|
676
|
+
modalWrapperRef.value = null;
|
|
677
|
+
}
|
|
640
678
|
};
|
|
679
|
+
// 获取实际宽度值(限制在 min 和 max 之间)
|
|
680
|
+
var getRealValue = function getRealValue(current) {
|
|
681
|
+
var screenWidth = window.innerWidth;
|
|
682
|
+
var maxAllowed = Math.min(props.maxWidth, screenWidth - 100); // 至少留100px空间
|
|
683
|
+
return Math.min(maxAllowed, Math.max(props.minWidth, current));
|
|
684
|
+
};
|
|
685
|
+
// 更新 resizeProxy 的样式
|
|
686
|
+
var updateResizeProxyStyle = function updateResizeProxyStyle(width) {
|
|
687
|
+
if (!resizeProxyRef.value) return;
|
|
688
|
+
resizeProxyRef.value.style.visibility = 'visible';
|
|
689
|
+
if (props.direction === 'left') {
|
|
690
|
+
resizeProxyRef.value.style.inset = "0 auto 0 ".concat(width, "px");
|
|
691
|
+
} else {
|
|
692
|
+
resizeProxyRef.value.style.inset = "0 ".concat(width, "px 0 auto");
|
|
693
|
+
}
|
|
694
|
+
};
|
|
695
|
+
// 更新遮罩的样式
|
|
696
|
+
var updateResizeMaskStyle = function updateResizeMaskStyle(show) {
|
|
697
|
+
if (!resizeMaskRef.value) return;
|
|
698
|
+
resizeMaskRef.value.style.display = show ? 'block' : 'none';
|
|
699
|
+
resizeMaskRef.value.style.cursor = 'col-resize';
|
|
700
|
+
};
|
|
701
|
+
// mousedown 事件处理
|
|
702
|
+
var handleMousedown = function handleMousedown(event) {
|
|
703
|
+
var _modalWrapperRef$valu;
|
|
704
|
+
var mouseEvent = event;
|
|
705
|
+
if (!props.resizable) return;
|
|
706
|
+
emit('before-resize', mouseEvent);
|
|
707
|
+
var rect = (_modalWrapperRef$valu = modalWrapperRef.value) === null || _modalWrapperRef$valu === void 0 ? void 0 : _modalWrapperRef$valu.getBoundingClientRect();
|
|
708
|
+
if (!rect) return;
|
|
709
|
+
// 拖拽开始时,将 currentWidth 设置为实际像素宽度作为基准
|
|
710
|
+
currentWidth.value = rect.width;
|
|
711
|
+
state.value = Object.freeze({
|
|
712
|
+
mouse: {
|
|
713
|
+
clientX: mouseEvent.clientX
|
|
714
|
+
},
|
|
715
|
+
sidebar: {
|
|
716
|
+
width: rect.width
|
|
717
|
+
}
|
|
718
|
+
});
|
|
719
|
+
updateResizeMaskStyle(true);
|
|
720
|
+
// 非 immediate 模式下显示代理线
|
|
721
|
+
if (!props.immediate) {
|
|
722
|
+
updateResizeProxyStyle(rect.width);
|
|
723
|
+
}
|
|
724
|
+
var finalWidth = rect.width;
|
|
725
|
+
var handleMouseMove = function handleMouseMove(event) {
|
|
726
|
+
var delta;
|
|
727
|
+
if (props.direction === 'left') {
|
|
728
|
+
delta = event.clientX - state.value.mouse.clientX;
|
|
729
|
+
} else {
|
|
730
|
+
delta = state.value.mouse.clientX - event.clientX;
|
|
731
|
+
}
|
|
732
|
+
var newWidth = state.value.sidebar.width + delta;
|
|
733
|
+
finalWidth = getRealValue(newWidth);
|
|
734
|
+
// immediate 模式:直接更新宽度
|
|
735
|
+
if (props.immediate) {
|
|
736
|
+
currentWidth.value = finalWidth;
|
|
737
|
+
} else {
|
|
738
|
+
// 非 immediate 模式:更新代理线位置
|
|
739
|
+
updateResizeProxyStyle(finalWidth);
|
|
740
|
+
}
|
|
741
|
+
emit('resizing', finalWidth);
|
|
742
|
+
};
|
|
743
|
+
var handleMouseUp = function handleMouseUp() {
|
|
744
|
+
if (resizeProxyRef.value) {
|
|
745
|
+
resizeProxyRef.value.style.visibility = 'hidden';
|
|
746
|
+
}
|
|
747
|
+
updateResizeMaskStyle(false);
|
|
748
|
+
document.removeEventListener('mousemove', handleMouseMove);
|
|
749
|
+
document.removeEventListener('mouseup', handleMouseUp);
|
|
750
|
+
// 只在非 immediate 模式下才需要最后更新宽度
|
|
751
|
+
if (!props.immediate) {
|
|
752
|
+
currentWidth.value = finalWidth;
|
|
753
|
+
}
|
|
754
|
+
emit('after-resize', finalWidth);
|
|
755
|
+
};
|
|
756
|
+
document.addEventListener('mousemove', handleMouseMove);
|
|
757
|
+
document.addEventListener('mouseup', handleMouseUp);
|
|
758
|
+
};
|
|
759
|
+
// 监听 width prop 变化,保持用户设置的原值
|
|
760
|
+
(0,external_vue_namespaceObject.watch)(function () {
|
|
761
|
+
return props.width;
|
|
762
|
+
}, function (newWidth) {
|
|
763
|
+
currentWidth.value = newWidth;
|
|
764
|
+
});
|
|
641
765
|
return function () {
|
|
642
766
|
var modelSlot = {
|
|
643
767
|
header: function header() {
|
|
@@ -646,7 +770,9 @@ sliderProps.width["default"] = '400';
|
|
|
646
770
|
"class": "".concat(resolveClassName('sideslider-header'))
|
|
647
771
|
}, [(0,external_vue_namespaceObject.createVNode)("div", {
|
|
648
772
|
"class": "".concat(resolveClassName('sideslider-close')),
|
|
649
|
-
"onClick":
|
|
773
|
+
"onClick": function onClick() {
|
|
774
|
+
return void handleClose();
|
|
775
|
+
}
|
|
650
776
|
}, [props.direction === 'left' ? (0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleLeft, null, null) : (0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleRight, null, null)]), (0,external_vue_namespaceObject.createVNode)("div", {
|
|
651
777
|
"class": "".concat(resolveClassName('sideslider-title'))
|
|
652
778
|
}, [(_slots$header = (_slots$header2 = slots.header) === null || _slots$header2 === void 0 ? void 0 : _slots$header2.call(slots)) !== null && _slots$header !== void 0 ? _slots$header : props.title])])]);
|
|
@@ -654,8 +780,17 @@ sliderProps.width["default"] = '400';
|
|
|
654
780
|
"default": function _default() {
|
|
655
781
|
var _slots$default;
|
|
656
782
|
return (0,external_vue_namespaceObject.createVNode)("div", {
|
|
783
|
+
"ref": contentRef,
|
|
657
784
|
"class": "".concat(resolveClassName('sideslider-content'))
|
|
658
|
-
}, [(_slots$default = slots["default"]) === null || _slots$default === void 0 ? void 0 : _slots$default.call(slots)
|
|
785
|
+
}, [(_slots$default = slots["default"]) === null || _slots$default === void 0 ? void 0 : _slots$default.call(slots), props.resizable && (0,external_vue_namespaceObject.createVNode)(external_vue_namespaceObject.Fragment, null, [(0,external_vue_namespaceObject.createVNode)("i", {
|
|
786
|
+
"ref": triggerRef,
|
|
787
|
+
"style": "width: ".concat(props.triggerWidth, "px;"),
|
|
788
|
+
"class": "".concat(resolveClassName('sideslider-resize-trigger')),
|
|
789
|
+
"onMousedown": (0,external_vue_namespaceObject.withModifiers)(handleMousedown, ['left'])
|
|
790
|
+
}, null), (0,external_vue_namespaceObject.createVNode)("i", {
|
|
791
|
+
"ref": resizeProxyRef,
|
|
792
|
+
"class": ["".concat(resolveClassName('sideslider-resize-proxy')), props.direction]
|
|
793
|
+
}, null)])]);
|
|
659
794
|
}
|
|
660
795
|
};
|
|
661
796
|
if (slots.footer) {
|
|
@@ -671,9 +806,9 @@ sliderProps.width["default"] = '400';
|
|
|
671
806
|
if (instance.vnode.scopeId) {
|
|
672
807
|
inheritAttrs[instance.vnode.scopeId] = '';
|
|
673
808
|
}
|
|
674
|
-
return (0,external_vue_namespaceObject.createVNode)(modal_namespaceObject["default"], (0,external_vue_namespaceObject.mergeProps)(inheritAttrs, {
|
|
675
|
-
"width":
|
|
676
|
-
"class": _defineProperty(_defineProperty({}, resolveClassName('sideslider'), true), "is-position-".concat(props.direction), props.direction),
|
|
809
|
+
return (0,external_vue_namespaceObject.createVNode)(external_vue_namespaceObject.Fragment, null, [(0,external_vue_namespaceObject.createVNode)(modal_namespaceObject["default"], (0,external_vue_namespaceObject.mergeProps)(inheritAttrs, {
|
|
810
|
+
"width": currentWidth.value,
|
|
811
|
+
"class": _defineProperty(_defineProperty(_defineProperty({}, resolveClassName('sideslider'), true), "is-position-".concat(props.direction), props.direction), "".concat(resolveClassName('sideslider-resizable')), props.resizable),
|
|
677
812
|
"extCls": props.extCls,
|
|
678
813
|
"animateType": props.direction,
|
|
679
814
|
"backgroundColor": props.backgroundColor,
|
|
@@ -692,7 +827,10 @@ sliderProps.width["default"] = '400';
|
|
|
692
827
|
"default": function _default() {
|
|
693
828
|
return [modelSlot];
|
|
694
829
|
}
|
|
695
|
-
})
|
|
830
|
+
}), props.resizable && (0,external_vue_namespaceObject.createVNode)("div", {
|
|
831
|
+
"ref": resizeMaskRef,
|
|
832
|
+
"class": "".concat(resolveClassName('sideslider-resize-mask'))
|
|
833
|
+
}, null)]);
|
|
696
834
|
};
|
|
697
835
|
}
|
|
698
836
|
}));
|
|
@@ -701,7 +839,7 @@ sliderProps.width["default"] = '400';
|
|
|
701
839
|
* Tencent is pleased to support the open source community by making
|
|
702
840
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
|
|
703
841
|
*
|
|
704
|
-
* Copyright (C)
|
|
842
|
+
* Copyright (C) 2025 Tencent. All rights reserved.
|
|
705
843
|
*
|
|
706
844
|
* 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
|
|
707
845
|
*
|
|
@@ -1,12 +1,32 @@
|
|
|
1
1
|
.bk-sideslider.is-position-right .bk-modal-wrapper {
|
|
2
2
|
right: 0;
|
|
3
3
|
}
|
|
4
|
+
.bk-sideslider.is-position-right.bk-sideslider-resizable .bk-sideslider-resize-trigger {
|
|
5
|
+
left: 0;
|
|
6
|
+
cursor: col-resize;
|
|
7
|
+
}
|
|
8
|
+
.bk-sideslider.is-position-right.bk-sideslider-resizable .bk-sideslider-resize-trigger:after {
|
|
9
|
+
left: 1px;
|
|
10
|
+
}
|
|
11
|
+
.bk-sideslider.is-position-right.bk-sideslider-resizable .bk-sideslider-resize-proxy.right {
|
|
12
|
+
border-left: 2px solid #3a84ff;
|
|
13
|
+
}
|
|
4
14
|
.bk-sideslider.is-position-left .bk-modal-wrapper {
|
|
5
15
|
left: 0;
|
|
6
16
|
}
|
|
7
17
|
.bk-sideslider.is-position-left .bk-sideslider-header {
|
|
8
18
|
flex-direction: row-reverse;
|
|
9
19
|
}
|
|
20
|
+
.bk-sideslider.is-position-left.bk-sideslider-resizable .bk-sideslider-resize-trigger {
|
|
21
|
+
right: 0;
|
|
22
|
+
cursor: col-resize;
|
|
23
|
+
}
|
|
24
|
+
.bk-sideslider.is-position-left.bk-sideslider-resizable .bk-sideslider-resize-trigger:after {
|
|
25
|
+
right: 1px;
|
|
26
|
+
}
|
|
27
|
+
.bk-sideslider.is-position-left.bk-sideslider-resizable .bk-sideslider-resize-proxy.left {
|
|
28
|
+
border-left: 2px solid #3a84ff;
|
|
29
|
+
}
|
|
10
30
|
.bk-sideslider .bk-modal-wrapper {
|
|
11
31
|
position: fixed;
|
|
12
32
|
top: 0;
|
|
@@ -42,6 +62,9 @@
|
|
|
42
62
|
font-size: 16px;
|
|
43
63
|
color: #313238;
|
|
44
64
|
}
|
|
65
|
+
.bk-sideslider-content {
|
|
66
|
+
position: relative;
|
|
67
|
+
}
|
|
45
68
|
.bk-sideslider-footer {
|
|
46
69
|
display: flex;
|
|
47
70
|
align-items: center;
|
|
@@ -50,3 +73,42 @@
|
|
|
50
73
|
padding-left: 24px;
|
|
51
74
|
margin-top: 24px;
|
|
52
75
|
}
|
|
76
|
+
.bk-sideslider-resize-trigger {
|
|
77
|
+
position: absolute;
|
|
78
|
+
top: 0;
|
|
79
|
+
z-index: 3;
|
|
80
|
+
width: 5px;
|
|
81
|
+
height: calc(100vh - 52px);
|
|
82
|
+
background-color: transparent;
|
|
83
|
+
}
|
|
84
|
+
.bk-sideslider-resize-trigger:after {
|
|
85
|
+
position: absolute;
|
|
86
|
+
top: 50%;
|
|
87
|
+
width: 2px;
|
|
88
|
+
height: 2px;
|
|
89
|
+
color: #c4c6cc;
|
|
90
|
+
content: '';
|
|
91
|
+
background: currentColor;
|
|
92
|
+
box-shadow: 0 4px 0 0 currentColor, 0 8px 0 0 currentColor, 0 -4px 0 0 currentColor, 0 -8px 0 0 currentColor;
|
|
93
|
+
transform: translateY(-50%);
|
|
94
|
+
}
|
|
95
|
+
.bk-sideslider-resize-trigger:hover:after {
|
|
96
|
+
color: #3a84ff;
|
|
97
|
+
}
|
|
98
|
+
.bk-sideslider-resize-proxy {
|
|
99
|
+
position: fixed;
|
|
100
|
+
top: 0;
|
|
101
|
+
bottom: 0;
|
|
102
|
+
z-index: 9999;
|
|
103
|
+
pointer-events: none;
|
|
104
|
+
visibility: hidden;
|
|
105
|
+
}
|
|
106
|
+
.bk-sideslider-resize-mask {
|
|
107
|
+
position: fixed;
|
|
108
|
+
top: 0;
|
|
109
|
+
right: 0;
|
|
110
|
+
bottom: 0;
|
|
111
|
+
left: 0;
|
|
112
|
+
z-index: 9998;
|
|
113
|
+
display: none;
|
|
114
|
+
}
|