vft 0.0.507 → 0.0.511
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.css +1 -1
- package/es/components/affix/affix.vue2.js +2 -2
- package/es/components/alert/alert.vue2.js +1 -1
- package/es/components/autocomplete/autocomplete.vue2.js +1 -1
- package/es/components/avatar/avatar.vue2.js +2 -2
- package/es/components/avatar-stack/avatar-stack.vue2.js +7 -7
- package/es/components/backtop/backtop.vue2.js +1 -1
- package/es/components/breadcrumb/breadcrumb-item.vue2.js +3 -3
- package/es/components/breadcrumb/breadcrumb.vue2.js +2 -2
- package/es/components/button/button-group.vue2.js +2 -2
- package/es/components/button/button.vue2.js +7 -7
- package/es/components/button/use-button.js +3 -3
- package/es/components/card/card.vue2.js +6 -6
- package/es/components/carousel/carousel-item.vue2.js +3 -3
- package/es/components/carousel/carousel.vue2.js +1 -1
- package/es/components/carousel/use-carousel.js +1 -1
- package/es/components/cascader/cascader.vue2.js +203 -202
- package/es/components/cascader-panel/index.vue2.js +1 -1
- package/es/components/cascader-panel/menu.vue2.js +50 -49
- package/es/components/cascader-panel/node.vue2.js +8 -8
- package/es/components/check-tag/check-tag.vue2.js +2 -2
- package/es/components/checkbox/checkbox-button.vue2.js +13 -13
- package/es/components/checkbox/checkbox-group.vue2.js +3 -3
- package/es/components/checkbox/checkbox.vue2.js +1 -1
- package/es/components/clamp/clamp.vue2.js +2 -2
- package/es/components/clamp-toggle/clamp-toggle.vue2.js +21 -17
- package/es/components/clamp-tooltip/clamp-tooltip.vue2.js +6 -6
- package/es/components/col/col.vue2.js +2 -2
- package/es/components/collapse/collapse-item.vue2.js +2 -2
- package/es/components/collapse/collapse.vue2.js +2 -2
- package/es/components/collapse-transition/collapse-transition.vue2.js +2 -2
- package/es/components/color-picker/color-picker.vue2.js +134 -133
- package/es/components/color-picker/components/alpha-slider.vue2.js +2 -2
- package/es/components/color-picker/components/hue-slider.vue.js +2 -2
- package/es/components/color-picker/components/predefine.vue.js +3 -3
- package/es/components/color-picker/components/sv-panel.vue.js +2 -2
- package/es/components/config-provider/config-provider.vue.d.ts +2 -0
- package/es/components/config-provider/config-provider.vue2.js +5 -4
- package/es/components/config-provider/constants.d.ts +1 -0
- package/es/components/config-provider/constants.js +3 -2
- package/es/components/config-provider/hooks/use-global-config.js +33 -30
- package/es/components/config-provider/index.d.ts +9 -0
- package/es/components/config-provider/index.js +6 -5
- package/es/components/container/aside.vue2.js +2 -2
- package/es/components/container/container.vue2.js +2 -2
- package/es/components/container/footer.vue2.js +2 -2
- package/es/components/container/header.vue2.js +2 -2
- package/es/components/container/main.vue2.js +2 -2
- package/es/components/context-menu/context-menu.vue2.js +1 -1
- package/es/components/countdown/countdown.vue2.js +2 -2
- package/es/components/date-picker/composables/use-basic-date-table.js +83 -82
- package/es/components/date-picker/composables/use-month-range-header.js +15 -14
- package/es/components/date-picker/composables/use-panel-date-range.js +24 -23
- package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +6 -6
- package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +40 -39
- package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +41 -40
- package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +184 -183
- package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +225 -224
- package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +12 -12
- package/es/components/date-picker/date-picker-com/panel-year-range.vue2.js +12 -12
- package/es/components/date-picker/props/basic-date-table.js +3 -3
- package/es/components/date-picker/props/basic-month-table.js +3 -3
- package/es/components/date-picker/props/basic-year-table.js +3 -3
- package/es/components/date-time-select/date-time-select.vue2.js +39 -36
- package/es/components/descriptions/description.vue2.js +1 -1
- package/es/components/descriptions/descriptions-row.vue2.js +10 -10
- package/es/components/dialog/dialog-content.vue2.js +3 -3
- package/es/components/dialog/dialog.vue2.js +5 -5
- package/es/components/divider/divider.vue2.js +5 -5
- package/es/components/drawer/drawer.vue2.js +4 -4
- package/es/components/dropdown/dropdown-item-impl.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown-item-impl.vue2.js +3 -3
- package/es/components/dropdown/dropdown-item.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown-item.vue2.js +2 -2
- package/es/components/dropdown/dropdown-menu.vue2.js +2 -2
- package/es/components/dropdown/dropdown.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown.vue2.js +68 -67
- package/es/components/dropdown/index.d.ts +33 -33
- package/es/components/empty/empty.vue2.js +39 -38
- package/es/components/footer-layout/footer-layout.vue2.js +2 -2
- package/es/components/form/form-item.vue2.js +16 -16
- package/es/components/form/form.vue2.js +2 -2
- package/es/components/full-screen/full-screen.vue2.js +18 -17
- package/es/components/header-layout/header-layout.vue2.js +1 -1
- package/es/components/horizontal-menu/horizontal-menu.vue2.js +3 -3
- package/es/components/icon/icon.vue2.js +3 -3
- package/es/components/icon-text/icon-text.vue2.js +1 -1
- package/es/components/iframe-layout/iframe-layout.vue2.js +4 -4
- package/es/components/iframe-layout/iframe-page.vue2.js +2 -2
- package/es/components/image/image.vue2.js +60 -59
- package/es/components/image-viewer/image-viewer.vue2.js +43 -42
- package/es/components/index.d.ts +1 -0
- package/es/components/index.js +214 -210
- package/es/components/input/input.vue2.js +2 -2
- package/es/components/input-number/input-number.vue2.js +4 -4
- package/es/components/input-tag/composables/use-input-tag.js +1 -1
- package/es/components/input-tag/input-tag.vue2.js +7 -7
- package/es/components/link/link.vue2.js +1 -1
- package/es/components/list-cell/list-cell.vue2.js +1 -1
- package/es/components/logo/logo.vue2.js +10 -10
- package/es/components/md-comment/md-comment.vue2.js +2 -2
- package/es/components/md-container/md-container.vue2.js +75 -74
- package/es/components/md-container/toc.js +37 -36
- package/es/components/menu/menu-collapse-transition.vue.js +2 -2
- package/es/components/menu/menu-item-group.vue2.js +7 -7
- package/es/components/menu/menu-item.vue2.js +1 -1
- package/es/components/message/message.vue2.js +3 -3
- package/es/components/message-box/index.d.ts +4 -0
- package/es/components/message-box/index.js +14 -0
- package/es/components/message-box/message-box.vue.d.ts +103 -0
- package/es/components/message-box/message-box.vue.js +4 -0
- package/es/components/message-box/message-box.vue2.js +358 -0
- package/es/components/message-box/method.d.ts +3 -0
- package/es/components/message-box/method.js +101 -0
- package/es/components/message-box/style/css.d.ts +2 -0
- package/es/components/message-box/style/css.js +3 -0
- package/es/components/message-box/style/index.d.ts +2 -0
- package/es/components/message-box/style/index.js +3 -0
- package/es/components/message-box/types.d.ts +202 -0
- package/es/components/message-box/types.js +1 -0
- package/es/components/modal/index.d.ts +1 -0
- package/es/components/modal/modal-footer-action.vue2.js +25 -24
- package/es/components/modal/modal.vue.d.ts +1 -0
- package/es/components/modal/modal.vue2.js +30 -28
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +17 -16
- package/es/components/multiple-tabs/tab-content.vue2.js +2 -2
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +54 -53
- package/es/components/notification/notification.vue2.js +1 -1
- package/es/components/overlay/overlay.vue2.js +1 -1
- package/es/components/page-wrapper/page-wrapper.vue2.js +2 -2
- package/es/components/pagination/components/jumper.vue2.js +2 -2
- package/es/components/pagination/components/next.vue2.js +4 -4
- package/es/components/pagination/components/pager.vue2.js +1 -1
- package/es/components/pagination/components/prev.vue2.js +4 -4
- package/es/components/pagination/components/sizes.vue2.js +2 -2
- package/es/components/pagination/components/total.vue2.js +2 -2
- package/es/components/popconfirm/popconfirm.vue2.js +40 -39
- package/es/components/popover/popover.vue2.js +1 -1
- package/es/components/popper/arrow.vue2.js +2 -2
- package/es/components/popper/content.vue2.js +2 -2
- package/es/components/popper/trigger.vue2.js +4 -4
- package/es/components/progress/progress.vue2.js +1 -1
- package/es/components/progress-i/progress-i.vue2.js +2 -2
- package/es/components/qrcode/qrcode.vue2.js +1 -1
- package/es/components/radio/radio-button.vue2.js +2 -2
- package/es/components/radio/radio-group.vue2.js +3 -3
- package/es/components/radio/radio.vue2.js +2 -2
- package/es/components/rate/rate.vue2.js +6 -6
- package/es/components/router-view-content/router-view-content.vue2.js +7 -7
- package/es/components/roving-focus-group/roving-focus-group.vue2.js +2 -2
- package/es/components/roving-focus-group/roving-focus-item.vue2.js +2 -2
- package/es/components/row/row.vue2.js +2 -2
- package/es/components/scrollbar/bar.vue2.js +2 -2
- package/es/components/scrollbar/scrollbar.vue2.js +7 -7
- package/es/components/scrollbar/thumb.vue2.js +2 -2
- package/es/components/search/search.vue2.js +78 -76
- package/es/components/segmented/segmented.vue2.js +7 -7
- package/es/components/select/group-item.vue.js +2 -2
- package/es/components/select/option-item.vue.js +2 -2
- package/es/components/select/select.vue.js +1 -1
- package/es/components/select/useSelect.js +232 -231
- package/es/components/skeleton/skeleton-item.vue2.js +2 -2
- package/es/components/skeleton/skeleton.vue2.js +8 -8
- package/es/components/slider/button.vue2.js +2 -2
- package/es/components/slider/slider.vue2.js +1 -1
- package/es/components/space/space.js +1 -1
- package/es/components/statistic/statistic.vue2.js +17 -17
- package/es/components/steps/item.vue2.js +11 -11
- package/es/components/steps/steps.vue2.js +2 -2
- package/es/components/super-form/super-form-action.vue2.js +11 -11
- package/es/components/super-form/super-form-item.vue2.js +5 -4
- package/es/components/super-form/super-form.vue2.js +7 -7
- package/es/components/super-form/use/helper.js +12 -12
- package/es/components/super-form/use/use-form.js +8 -8
- package/es/components/switch/switch.vue2.js +1 -1
- package/es/components/table/field.js +34 -33
- package/es/components/table/table.vue2.js +154 -157
- package/es/components/table/use/use-data-source.js +90 -90
- package/es/components/tabs/tab-bar.vue2.js +2 -2
- package/es/components/tabs/tab-pane.vue2.js +6 -6
- package/es/components/teleport/teleport.vue2.js +2 -2
- package/es/components/time-picker/common/picker-range-trigger.vue2.js +2 -2
- package/es/components/time-picker/common/picker.vue2.js +8 -8
- package/es/components/time-picker/time-picker-com/basic-time-spinner.vue2.js +1 -1
- package/es/components/time-picker/time-picker-com/panel-time-pick.vue2.js +66 -65
- package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +134 -133
- package/es/components/time-select/time-select.vue2.js +3 -3
- package/es/components/timeline/timeline-item.vue2.js +1 -1
- package/es/components/tooltip/content.vue2.js +6 -6
- package/es/components/tooltip/tooltip.vue2.js +1 -1
- package/es/components/tooltip/trigger.vue2.js +2 -2
- package/es/components/transfer/transfer-panel.vue2.js +59 -58
- package/es/components/transfer/transfer.vue2.js +70 -69
- package/es/components/tree/tree-node.vue.js +1 -1
- package/es/components/tree/tree.vue2.js +60 -59
- package/es/components/upload/index.d.ts +3 -3
- package/es/components/upload/upload-content.vue.d.ts +2 -2
- package/es/components/upload/upload-content.vue2.js +76 -73
- package/es/components/upload/upload-dragger.vue2.js +2 -2
- package/es/components/upload/upload-list.vue2.js +46 -45
- package/es/components/upload/upload.vue.d.ts +2 -2
- package/es/components/upload/upload.vue2.js +87 -85
- package/es/components/upload/utils.js +29 -29
- package/es/components/verify-code/verify-code.vue2.js +2 -2
- package/es/components/watermark/watermark.vue2.js +2 -2
- package/es/constants/date.d.ts +1 -1
- package/es/constants/date.js +9 -1
- package/es/hooks/use-id/index.js +2 -2
- package/es/hooks/use-z-index/index.js +3 -3
- package/es/index.d.ts +1 -0
- package/es/index.js +43 -38
- package/es/locale/index.d.js +1 -0
- package/es/locale/index.d.ts +26 -0
- package/es/locale/index.js +10 -0
- package/es/locale/lang/en.d.ts +183 -0
- package/es/locale/lang/en.js +241 -0
- package/es/locale/lang/zh-cn.d.ts +183 -0
- package/es/locale/lang/zh-cn.js +241 -0
- package/es/locale/lang/zh-tw.d.ts +183 -0
- package/es/locale/lang/zh-tw.js +241 -0
- package/es/locale/use-locale.d.ts +17 -0
- package/es/locale/use-locale.js +56 -0
- package/es/package.json.d.ts +1 -1
- package/es/package.json.js +1 -1
- package/es/plugin.js +5 -3
- package/es/utils/helper.js +2 -2
- package/es/utils/ns-cover.js +1 -1
- package/es/utils/vue/vnode.js +4 -4
- package/lib/components/button/use-button.cjs +1 -1
- package/lib/components/cascader/cascader.vue2.cjs +1 -1
- package/lib/components/cascader-panel/menu.vue2.cjs +4 -4
- package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
- package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
- package/lib/components/config-provider/config-provider.vue.d.ts +2 -0
- package/lib/components/config-provider/config-provider.vue2.cjs +1 -1
- package/lib/components/config-provider/constants.cjs +1 -1
- package/lib/components/config-provider/constants.d.ts +1 -0
- package/lib/components/config-provider/hooks/use-global-config.cjs +1 -1
- package/lib/components/config-provider/index.cjs +1 -1
- package/lib/components/config-provider/index.d.ts +9 -0
- package/lib/components/date-picker/composables/use-basic-date-table.cjs +1 -1
- package/lib/components/date-picker/composables/use-month-range-header.cjs +1 -1
- package/lib/components/date-picker/composables/use-panel-date-range.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
- package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
- package/lib/components/dropdown/dropdown-item-impl.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown-item.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
- package/lib/components/dropdown/index.d.ts +33 -33
- package/lib/components/empty/empty.vue2.cjs +1 -1
- package/lib/components/full-screen/full-screen.vue2.cjs +1 -1
- package/lib/components/image/image.vue2.cjs +1 -1
- package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
- package/lib/components/index.cjs +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/md-container/md-container.vue2.cjs +1 -1
- package/lib/components/md-container/toc.cjs +1 -1
- package/lib/components/message-box/index.cjs +1 -0
- package/lib/components/message-box/index.d.ts +4 -0
- package/lib/components/message-box/message-box.vue.cjs +1 -0
- package/lib/components/message-box/message-box.vue.d.ts +103 -0
- package/lib/components/message-box/message-box.vue2.cjs +1 -0
- package/lib/components/message-box/method.cjs +1 -0
- package/lib/components/message-box/method.d.ts +3 -0
- package/lib/components/message-box/style/css.cjs +1 -0
- package/lib/components/message-box/style/css.d.ts +2 -0
- package/lib/components/message-box/style/index.cjs +1 -0
- package/lib/components/message-box/style/index.d.ts +2 -0
- package/lib/components/message-box/types.cjs +1 -0
- package/lib/components/message-box/types.d.ts +202 -0
- package/lib/components/modal/index.d.ts +1 -0
- package/lib/components/modal/modal-footer-action.vue2.cjs +1 -1
- package/lib/components/modal/modal.vue.d.ts +1 -0
- package/lib/components/modal/modal.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
- package/lib/components/search/search.vue2.cjs +1 -1
- package/lib/components/select/useSelect.cjs +1 -1
- package/lib/components/super-form/super-form-item.vue2.cjs +1 -1
- package/lib/components/super-form/use/helper.cjs +1 -1
- package/lib/components/super-form/use/use-form.cjs +1 -1
- package/lib/components/table/field.cjs +1 -1
- package/lib/components/table/table.vue2.cjs +1 -1
- package/lib/components/table/use/use-data-source.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-pick.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
- package/lib/components/transfer/transfer-panel.vue2.cjs +1 -1
- package/lib/components/transfer/transfer.vue2.cjs +1 -1
- package/lib/components/tree/tree.vue2.cjs +1 -1
- package/lib/components/upload/index.d.ts +3 -3
- package/lib/components/upload/upload-content.vue.d.ts +2 -2
- package/lib/components/upload/upload-content.vue2.cjs +1 -1
- package/lib/components/upload/upload-list.vue2.cjs +1 -1
- package/lib/components/upload/upload.vue.d.ts +2 -2
- package/lib/components/upload/upload.vue2.cjs +1 -1
- package/lib/components/upload/utils.cjs +1 -1
- package/lib/constants/date.cjs +1 -1
- package/lib/constants/date.d.ts +1 -1
- package/lib/index.cjs +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/locale/index.cjs +1 -0
- package/lib/locale/index.d.cjs +1 -0
- package/lib/locale/index.d.ts +26 -0
- package/lib/locale/lang/en.cjs +1 -0
- package/lib/locale/lang/en.d.ts +183 -0
- package/lib/locale/lang/zh-cn.cjs +1 -0
- package/lib/locale/lang/zh-cn.d.ts +183 -0
- package/lib/locale/lang/zh-tw.cjs +1 -0
- package/lib/locale/lang/zh-tw.d.ts +183 -0
- package/lib/locale/use-locale.cjs +1 -0
- package/lib/locale/use-locale.d.ts +17 -0
- package/lib/package.json.cjs +1 -1
- package/lib/package.json.d.ts +1 -1
- package/lib/plugin.cjs +1 -1
- package/package.json +2 -2
- package/theme-style/index.css +1 -1
- package/theme-style/src/super-form.scss +0 -1
- package/theme-style/src/table.scss +4 -0
- package/theme-style/vft-super-form.css +1 -1
- package/theme-style/vft-table.css +1 -1
- package/web-types.json +1 -1
|
@@ -1,38 +1,38 @@
|
|
|
1
1
|
import "../../pagination/index.js";
|
|
2
|
-
import { isFunction as B, isBoolean as
|
|
3
|
-
import { merge as
|
|
4
|
-
import { ref as O, watchEffect as
|
|
5
|
-
import { PageSize as
|
|
6
|
-
function
|
|
7
|
-
tableData:
|
|
2
|
+
import { isFunction as B, isBoolean as tt, delObjAttrNotExist as et, isString as at, isEmptyObject as rt, isNullOrUndefined as M, isObject as k, isNumber as q, isPlainObject as nt } from "@vft/utils";
|
|
3
|
+
import { merge as it, get as H } from "lodash-es";
|
|
4
|
+
import { ref as O, watchEffect as ot, unref as i, watch as U, computed as st, onMounted as lt, nextTick as V } from "vue";
|
|
5
|
+
import { PageSize as ct } from "../constants.js";
|
|
6
|
+
function ht(m, {
|
|
7
|
+
tableData: W,
|
|
8
8
|
setLoading: P,
|
|
9
9
|
getPaginationInfo: D,
|
|
10
10
|
setPagination: h,
|
|
11
11
|
getGridRef: C
|
|
12
|
-
},
|
|
13
|
-
const f = O([]),
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}),
|
|
12
|
+
}, z) {
|
|
13
|
+
const f = O([]), E = O({});
|
|
14
|
+
ot(() => {
|
|
15
|
+
W.value = i(f);
|
|
16
|
+
}), U(
|
|
17
17
|
() => i(m).data,
|
|
18
18
|
() => {
|
|
19
|
-
const { data:
|
|
20
|
-
!
|
|
19
|
+
const { data: t, api: e } = i(m);
|
|
20
|
+
!e && t && (f.value = t);
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
immediate: !0
|
|
24
24
|
}
|
|
25
25
|
);
|
|
26
|
-
function
|
|
27
|
-
h(
|
|
26
|
+
function X(t) {
|
|
27
|
+
h(t), T({});
|
|
28
28
|
}
|
|
29
|
-
const
|
|
30
|
-
const
|
|
31
|
-
return !
|
|
29
|
+
const x = st(() => {
|
|
30
|
+
const t = i(f);
|
|
31
|
+
return !t || t.length === 0 ? i(f) : i(f);
|
|
32
32
|
});
|
|
33
|
-
async function T(
|
|
33
|
+
async function T(t) {
|
|
34
34
|
const {
|
|
35
|
-
api:
|
|
35
|
+
api: e,
|
|
36
36
|
fetchSetting: r = {},
|
|
37
37
|
beforeFetch: a,
|
|
38
38
|
afterFetch: o,
|
|
@@ -41,10 +41,10 @@ function he(m, {
|
|
|
41
41
|
transformParams: w,
|
|
42
42
|
extraParams: u
|
|
43
43
|
} = i(m);
|
|
44
|
-
if (!(!
|
|
44
|
+
if (!(!e || !B(e)))
|
|
45
45
|
try {
|
|
46
46
|
P(!0);
|
|
47
|
-
const { pageField: n, sizeField: d, listField:
|
|
47
|
+
const { pageField: n, sizeField: d, listField: v, totalField: y } = Object.assign(
|
|
48
48
|
{},
|
|
49
49
|
{
|
|
50
50
|
pageField: "page",
|
|
@@ -54,86 +54,86 @@ function he(m, {
|
|
|
54
54
|
},
|
|
55
55
|
r
|
|
56
56
|
);
|
|
57
|
-
let g = {}, l =
|
|
58
|
-
const { currentPage: j = 1, pageSize: _ =
|
|
57
|
+
let g = {}, l = t;
|
|
58
|
+
const { currentPage: j = 1, pageSize: _ = ct } = i(
|
|
59
59
|
D
|
|
60
60
|
);
|
|
61
61
|
if (w) {
|
|
62
|
-
if (
|
|
62
|
+
if (tt(s) && !s)
|
|
63
63
|
g = {};
|
|
64
64
|
else {
|
|
65
|
-
const p =
|
|
65
|
+
const p = t && t.page || j;
|
|
66
66
|
g[n] = s?.pageIsZero ? p - 1 : p, g[d] = _;
|
|
67
67
|
}
|
|
68
|
-
if (l =
|
|
68
|
+
if (l = it(t, g), a && B(a)) {
|
|
69
69
|
const p = await a(l);
|
|
70
70
|
l = { ...l, ...p };
|
|
71
71
|
}
|
|
72
|
-
c &&
|
|
72
|
+
c && et(
|
|
73
73
|
l,
|
|
74
|
-
|
|
74
|
+
at(c) ? c === "strict" : !1
|
|
75
75
|
);
|
|
76
76
|
}
|
|
77
|
-
l && !
|
|
78
|
-
const F = await
|
|
79
|
-
let b = N ? F : H(F,
|
|
77
|
+
l && !rt(l) && !M(u) ? k(l) && k(u) && (l = Object.assign({}, l, u)) : M(u) || (l = u);
|
|
78
|
+
const F = await e(l), N = Array.isArray(F);
|
|
79
|
+
let b = N ? F : H(F, v);
|
|
80
80
|
const S = N ? F.length : H(F, y);
|
|
81
81
|
if (Number(S)) {
|
|
82
82
|
const p = Math.ceil(S / _);
|
|
83
83
|
if (j > p)
|
|
84
84
|
return h({
|
|
85
85
|
currentPage: p
|
|
86
|
-
}), await T(
|
|
86
|
+
}), await T(t);
|
|
87
87
|
}
|
|
88
|
-
return o && B(o) && (b = await o(b) || b), f.value = b,
|
|
88
|
+
return o && B(o) && (b = await o(b) || b), f.value = b, E.value = b, h({
|
|
89
89
|
total: S || 0
|
|
90
|
-
}),
|
|
91
|
-
currentPage:
|
|
92
|
-
}),
|
|
90
|
+
}), t && t.page && h({
|
|
91
|
+
currentPage: t.page || 1
|
|
92
|
+
}), z("fetch-success", {
|
|
93
93
|
items: i(b),
|
|
94
94
|
total: S
|
|
95
95
|
}), b;
|
|
96
96
|
} catch (n) {
|
|
97
|
-
console.log(n),
|
|
97
|
+
console.log(n), z("fetch-error", n), f.value = [], h({
|
|
98
98
|
total: 0
|
|
99
99
|
});
|
|
100
100
|
} finally {
|
|
101
|
-
|
|
101
|
+
V(() => {
|
|
102
102
|
P(!1);
|
|
103
103
|
});
|
|
104
104
|
}
|
|
105
105
|
}
|
|
106
|
-
function
|
|
107
|
-
return
|
|
106
|
+
function A() {
|
|
107
|
+
return E.value;
|
|
108
108
|
}
|
|
109
|
-
async function
|
|
109
|
+
async function Z(t) {
|
|
110
110
|
return h({
|
|
111
|
-
currentPage:
|
|
112
|
-
}), await T(
|
|
111
|
+
currentPage: t?.page || 1
|
|
112
|
+
}), await T(t);
|
|
113
113
|
}
|
|
114
|
-
async function
|
|
115
|
-
return f.value[
|
|
114
|
+
async function J(t, e, r) {
|
|
115
|
+
return f.value[t] && (f.value[t][e] = r), f.value[t];
|
|
116
116
|
}
|
|
117
|
-
function
|
|
118
|
-
const r = C(), a = r.getRowById(
|
|
117
|
+
function L(t, e) {
|
|
118
|
+
const r = C(), a = r.getRowById(t);
|
|
119
119
|
if (!a) return;
|
|
120
120
|
const s = i(m).treeConfig;
|
|
121
121
|
if (!!s && s?.parentField) {
|
|
122
|
-
const w = s.parentField, u = a[w], n =
|
|
123
|
-
if (
|
|
122
|
+
const w = s.parentField, u = a[w], n = e[w], d = (g) => g == null || g === "" ? null : g, v = d(u), y = d(n);
|
|
123
|
+
if (v !== y) {
|
|
124
124
|
if (r.remove(a), y !== null) {
|
|
125
125
|
const l = r.getRowById(y);
|
|
126
|
-
l ? r.insertChild(
|
|
126
|
+
l ? r.insertChild(e, l) : r.insert(e);
|
|
127
127
|
} else
|
|
128
|
-
r.insert(
|
|
128
|
+
r.insert(e);
|
|
129
129
|
const g = s.rowField || "id";
|
|
130
|
-
return r.getRowById(
|
|
130
|
+
return r.getRowById(e[g]);
|
|
131
131
|
}
|
|
132
132
|
}
|
|
133
|
-
return r.setRow(a,
|
|
133
|
+
return r.setRow(a, e), a;
|
|
134
134
|
}
|
|
135
|
-
async function Q(
|
|
136
|
-
const a =
|
|
135
|
+
async function Q(t, e = 0, r) {
|
|
136
|
+
const a = nt(t) ? [t] : t, o = a.length, s = i(m), c = C();
|
|
137
137
|
if (!!s.treeConfig)
|
|
138
138
|
if (r != null && r !== "") {
|
|
139
139
|
const n = c.getRowById(r);
|
|
@@ -146,7 +146,7 @@ function he(m, {
|
|
|
146
146
|
} else
|
|
147
147
|
for (const n of a)
|
|
148
148
|
await c.insert(n);
|
|
149
|
-
else if (
|
|
149
|
+
else if (e === -1)
|
|
150
150
|
for (const n of a)
|
|
151
151
|
await c.insertAt(n, -1);
|
|
152
152
|
else
|
|
@@ -160,76 +160,76 @@ function he(m, {
|
|
|
160
160
|
}
|
|
161
161
|
return i(f);
|
|
162
162
|
}
|
|
163
|
-
function Y(
|
|
164
|
-
const r = C(), a =
|
|
163
|
+
function Y(t, e) {
|
|
164
|
+
const r = C(), a = t != null ? Array.isArray(t) ? t : [t] : e != null ? Array.isArray(e) ? e.map((s) => r.getRowById(s)).filter(Boolean) : r.getRowById(e) ? [r.getRowById(e)] : [] : [];
|
|
165
165
|
if (!a.length) return;
|
|
166
166
|
r.remove(a);
|
|
167
167
|
const { total: o } = i(D);
|
|
168
168
|
q(o) && h({ total: Math.max(0, o - a.length) });
|
|
169
169
|
}
|
|
170
|
-
function
|
|
171
|
-
f.value =
|
|
170
|
+
function I(t) {
|
|
171
|
+
f.value = t;
|
|
172
172
|
}
|
|
173
173
|
function $() {
|
|
174
|
-
return
|
|
174
|
+
return x.value;
|
|
175
175
|
}
|
|
176
|
-
function G(
|
|
177
|
-
const
|
|
178
|
-
if (
|
|
179
|
-
const r =
|
|
176
|
+
function G(t) {
|
|
177
|
+
const e = String(t).trim().toLowerCase();
|
|
178
|
+
if (e) {
|
|
179
|
+
const r = A?.()?.filter((a) => {
|
|
180
180
|
for (const o in a)
|
|
181
|
-
if (String(a[o]).trim().toLowerCase()?.includes(
|
|
181
|
+
if (String(a[o]).trim().toLowerCase()?.includes(e))
|
|
182
182
|
return !0;
|
|
183
183
|
});
|
|
184
|
-
|
|
184
|
+
I(r);
|
|
185
185
|
} else
|
|
186
|
-
A(
|
|
186
|
+
I(A());
|
|
187
187
|
}
|
|
188
|
-
function K(
|
|
189
|
-
const
|
|
190
|
-
!
|
|
191
|
-
if (
|
|
192
|
-
|
|
188
|
+
function K(t) {
|
|
189
|
+
const e = C();
|
|
190
|
+
!e || !i(m).treeConfig || V(() => {
|
|
191
|
+
if (t === void 0 || t === -1) {
|
|
192
|
+
e.setAllTreeExpand(!0);
|
|
193
193
|
return;
|
|
194
194
|
}
|
|
195
|
-
const o =
|
|
195
|
+
const o = e.getTableData().tableData;
|
|
196
196
|
if (!o || o.length === 0) {
|
|
197
|
-
console.warn("
|
|
197
|
+
console.warn("没有数据可展开");
|
|
198
198
|
return;
|
|
199
199
|
}
|
|
200
200
|
const s = [], c = (w, u) => {
|
|
201
|
-
u >
|
|
202
|
-
u <=
|
|
201
|
+
u > t || w.forEach((n) => {
|
|
202
|
+
u <= t && s.push(n);
|
|
203
203
|
const d = n._X_ROW_CHILD;
|
|
204
|
-
d && d.length > 0 && u <
|
|
204
|
+
d && d.length > 0 && u < t && c(d, u + 1);
|
|
205
205
|
});
|
|
206
206
|
};
|
|
207
|
-
c(o, 1), s.length > 0 &&
|
|
207
|
+
c(o, 1), s.length > 0 && e.setTreeExpand(s, !0);
|
|
208
208
|
});
|
|
209
209
|
}
|
|
210
210
|
const R = O(!0);
|
|
211
|
-
return
|
|
211
|
+
return lt(() => {
|
|
212
212
|
i(m).immediate && T(), R.value = !1;
|
|
213
|
-
}),
|
|
213
|
+
}), U(
|
|
214
214
|
() => i(m).api,
|
|
215
215
|
() => {
|
|
216
216
|
i(m).watchApiFetch && !R.value && i(m).immediate && T();
|
|
217
217
|
}
|
|
218
218
|
), {
|
|
219
|
-
setTableData:
|
|
220
|
-
updateTableData:
|
|
221
|
-
updateTableDataRecord:
|
|
219
|
+
setTableData: I,
|
|
220
|
+
updateTableData: J,
|
|
221
|
+
updateTableDataRecord: L,
|
|
222
222
|
insertTableDataRecord: Q,
|
|
223
223
|
deleteTableDataRecord: Y,
|
|
224
|
-
reload:
|
|
225
|
-
handleTableChange:
|
|
226
|
-
getDataSourceRef:
|
|
224
|
+
reload: Z,
|
|
225
|
+
handleTableChange: X,
|
|
226
|
+
getDataSourceRef: x,
|
|
227
227
|
getDataSource: $,
|
|
228
|
-
getRawDataSource:
|
|
228
|
+
getRawDataSource: A,
|
|
229
229
|
tableSearch: G,
|
|
230
230
|
expandTreeLevel: K
|
|
231
231
|
};
|
|
232
232
|
}
|
|
233
233
|
export {
|
|
234
|
-
|
|
234
|
+
ht as useDataSource
|
|
235
235
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as S, inject as $, ref as f, watch as T, nextTick as k, onBeforeUnmount as C, computed as D, onMounted as E,
|
|
1
|
+
import { defineComponent as S, inject as $, ref as f, watch as T, nextTick as k, onBeforeUnmount as C, computed as D, onMounted as E, openBlock as O, createElementBlock as F, normalizeStyle as L, normalizeClass as P, unref as y } from "vue";
|
|
2
2
|
import { useResizeObserver as R } from "@vueuse/core";
|
|
3
3
|
import { capitalize as l } from "@vft/utils";
|
|
4
4
|
import "../config-provider/hooks/use-global-config.js";
|
|
@@ -59,7 +59,7 @@ const Y = /* @__PURE__ */ S({
|
|
|
59
59
|
}), x({
|
|
60
60
|
ref: i,
|
|
61
61
|
update: a
|
|
62
|
-
}), (e, s) => (
|
|
62
|
+
}), (e, s) => (O(), F("div", {
|
|
63
63
|
ref_key: "barRef",
|
|
64
64
|
ref: i,
|
|
65
65
|
class: P([y(u).e("active-bar"), y(u).is(B.value), { "is-load": d.value }]),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as b, getCurrentInstance as C, useSlots as g, inject as R, ref as i, computed as f, watch as k, reactive as w, onBeforeUnmount as N, onBeforeUpdate as _,
|
|
1
|
+
import { defineComponent as b, getCurrentInstance as C, useSlots as g, inject as R, ref as i, computed as f, watch as k, reactive as w, onBeforeUnmount as N, onBeforeUpdate as _, unref as n, withDirectives as $, openBlock as x, createElementBlock as z, normalizeClass as E, renderSlot as P, vShow as S, createCommentVNode as I } from "vue";
|
|
2
2
|
import { eagerComputed as v } from "@vueuse/core";
|
|
3
3
|
import "@vft/utils";
|
|
4
4
|
import { throwError as U } from "../../utils/error.js";
|
|
@@ -48,20 +48,20 @@ const D = ["id", "aria-hidden", "aria-labelledby"], F = b({
|
|
|
48
48
|
e.unregisterPane(p);
|
|
49
49
|
}), _(() => {
|
|
50
50
|
u.label && e.nav$.value?.scheduleRender();
|
|
51
|
-
}), (l, K) => n(y) ? $((
|
|
51
|
+
}), (l, K) => n(y) ? $((x(), z("div", {
|
|
52
52
|
key: 0,
|
|
53
53
|
id: `pane-${s.value}`,
|
|
54
54
|
ref_key: "paneRef",
|
|
55
55
|
ref: m,
|
|
56
|
-
class:
|
|
56
|
+
class: E(n(c).b()),
|
|
57
57
|
role: "tabpanel",
|
|
58
58
|
"aria-hidden": !n(t),
|
|
59
59
|
"aria-labelledby": `tab-${s.value}`
|
|
60
60
|
}, [
|
|
61
|
-
|
|
61
|
+
P(l.$slots, "default")
|
|
62
62
|
], 10, D)), [
|
|
63
|
-
[
|
|
64
|
-
]) :
|
|
63
|
+
[S, n(t)]
|
|
64
|
+
]) : I("", !0);
|
|
65
65
|
}
|
|
66
66
|
});
|
|
67
67
|
export {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as l, renderSlot as o,
|
|
1
|
+
import { defineComponent as l, renderSlot as o, openBlock as a, createBlock as r, Teleport as n } from "vue";
|
|
2
2
|
const f = /* @__PURE__ */ l({
|
|
3
3
|
__name: "teleport",
|
|
4
4
|
props: {
|
|
@@ -6,7 +6,7 @@ const f = /* @__PURE__ */ l({
|
|
|
6
6
|
to: {}
|
|
7
7
|
},
|
|
8
8
|
setup(e) {
|
|
9
|
-
return (t, s) => e.disabled ? o(t.$slots, "default", { key: 0 }) : (
|
|
9
|
+
return (t, s) => e.disabled ? o(t.$slots, "default", { key: 0 }) : (a(), r(n, {
|
|
10
10
|
key: 1,
|
|
11
11
|
to: e.to
|
|
12
12
|
}, [
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as m, ref as u, computed as $,
|
|
1
|
+
import { defineComponent as m, ref as u, computed as $, openBlock as M, createElementBlock as T, normalizeStyle as w, normalizeClass as z, unref as o, renderSlot as t, createElementVNode as d, mergeProps as i } from "vue";
|
|
2
2
|
import { useAttrs as A } from "../../../hooks/use-attrs/index.js";
|
|
3
3
|
import "@vueuse/core";
|
|
4
4
|
import "@vft/utils";
|
|
@@ -56,7 +56,7 @@ const N = ["id", "name", "placeholder", "value", "disabled"], D = ["id", "name",
|
|
|
56
56
|
blur: () => {
|
|
57
57
|
s.value?.blur(), l.value?.blur();
|
|
58
58
|
}
|
|
59
|
-
}), (e, G) => (
|
|
59
|
+
}), (e, G) => (M(), T("div", {
|
|
60
60
|
ref_key: "wrapperRef",
|
|
61
61
|
ref: v,
|
|
62
62
|
class: z([o(b).is("active", o(C)), e.$attrs.class]),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as ge, ref as f, useAttrs as Ge, inject as Qe, computed as s, watch as Xe, nextTick as H, unref as n, onBeforeUnmount as Ze, provide as _e,
|
|
1
|
+
import { defineComponent as ge, ref as f, useAttrs as Ge, inject as Qe, computed as s, watch as Xe, nextTick as H, unref as n, onBeforeUnmount as Ze, provide as _e, openBlock as h, createBlock as g, mergeProps as xe, withCtx as y, renderSlot as se, withModifiers as T, normalizeStyle as ie, normalizeClass as b, createCommentVNode as B, createElementVNode as ea, toDisplayString as aa } from "vue";
|
|
2
2
|
import { isEqual as la } from "lodash-es";
|
|
3
3
|
import { onClickOutside as oa, unrefElement as na } from "@vueuse/core";
|
|
4
4
|
import { isArray as V, noop as ce } from "@vft/utils";
|
|
@@ -244,7 +244,7 @@ const ma = ge({
|
|
|
244
244
|
* @description pick item manually
|
|
245
245
|
*/
|
|
246
246
|
onPick: x
|
|
247
|
-
}), (e, a) => (
|
|
247
|
+
}), (e, a) => (h(), g(n(sa), xe({
|
|
248
248
|
ref_key: "refPopper",
|
|
249
249
|
ref: A,
|
|
250
250
|
visible: r.value,
|
|
@@ -268,7 +268,7 @@ const ma = ge({
|
|
|
268
268
|
onHide: ee
|
|
269
269
|
}), {
|
|
270
270
|
default: y(() => [
|
|
271
|
-
Be.value ? (
|
|
271
|
+
Be.value ? (h(), g(fa, {
|
|
272
272
|
key: 1,
|
|
273
273
|
id: e.id,
|
|
274
274
|
ref_key: "inputRef",
|
|
@@ -299,7 +299,7 @@ const ma = ge({
|
|
|
299
299
|
onKeydown: ue
|
|
300
300
|
}, {
|
|
301
301
|
prefix: y(() => [
|
|
302
|
-
N.value ? (
|
|
302
|
+
N.value ? (h(), g(n(K), {
|
|
303
303
|
key: 0,
|
|
304
304
|
icon: N.value,
|
|
305
305
|
class: b([n(w).e("icon"), n(k).e("icon")])
|
|
@@ -313,7 +313,7 @@ const ma = ge({
|
|
|
313
313
|
])
|
|
314
314
|
]),
|
|
315
315
|
suffix: y(() => [
|
|
316
|
-
e.clearIcon ? (
|
|
316
|
+
e.clearIcon ? (h(), g(n(K), {
|
|
317
317
|
key: 0,
|
|
318
318
|
icon: e.clearIcon,
|
|
319
319
|
class: b(we.value),
|
|
@@ -322,7 +322,7 @@ const ma = ge({
|
|
|
322
322
|
}, null, 8, ["icon", "class", "onMousedown"])) : B("", !0)
|
|
323
323
|
]),
|
|
324
324
|
_: 3
|
|
325
|
-
}, 8, ["id", "model-value", "name", "disabled", "readonly", "start-placeholder", "end-placeholder", "class", "style", "aria-label", "tabindex", "onFocus", "onBlur"])) : (
|
|
325
|
+
}, 8, ["id", "model-value", "name", "disabled", "readonly", "start-placeholder", "end-placeholder", "class", "style", "aria-label", "tabindex", "onFocus", "onBlur"])) : (h(), g(n(ua), {
|
|
326
326
|
key: 0,
|
|
327
327
|
id: e.id,
|
|
328
328
|
ref_key: "inputRef",
|
|
@@ -352,7 +352,7 @@ const ma = ge({
|
|
|
352
352
|
}, ["stop"]))
|
|
353
353
|
}, {
|
|
354
354
|
prefix: y(() => [
|
|
355
|
-
N.value ? (
|
|
355
|
+
N.value ? (h(), g(n(K), {
|
|
356
356
|
key: 0,
|
|
357
357
|
icon: N.value,
|
|
358
358
|
class: b(n(w).e("icon")),
|
|
@@ -361,7 +361,7 @@ const ma = ge({
|
|
|
361
361
|
}, null, 8, ["icon", "class"])) : B("", !0)
|
|
362
362
|
]),
|
|
363
363
|
suffix: y(() => [
|
|
364
|
-
P.value && e.clearIcon ? (
|
|
364
|
+
P.value && e.clearIcon ? (h(), g(n(K), {
|
|
365
365
|
key: 0,
|
|
366
366
|
icon: e.clearIcon,
|
|
367
367
|
class: b(`${n(w).e("icon")} clear-icon`),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as de, inject as pe, ref as C, computed as k, unref as r, onMounted as he, nextTick as x, watch as fe,
|
|
1
|
+
import { defineComponent as de, inject as pe, ref as C, computed as k, unref as r, onMounted as he, nextTick as x, watch as fe, openBlock as l, createElementBlock as a, normalizeClass as m, Fragment as u, renderList as $, createBlock as be, withCtx as we, createTextVNode as _, toDisplayString as f, createCommentVNode as I, withDirectives as j, createVNode as U, createElementVNode as ve } from "vue";
|
|
2
2
|
import { debounce as Se } from "lodash-es";
|
|
3
3
|
import { vRepeatClick as q } from "@vft/directives";
|
|
4
4
|
import { VftScrollbar as ge } from "../../scrollbar/index.js";
|
|
@@ -1,109 +1,110 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as Q, inject as W, ref as w, computed as d, openBlock as T, createBlock as X, Transition as Z, withCtx as ee, createElementBlock as te, normalizeClass as r, unref as n, createElementVNode as p, createVNode as ne, toDisplayString as A, createCommentVNode as oe } from "vue";
|
|
2
2
|
import f from "dayjs";
|
|
3
|
-
import { EVENT_CODE as
|
|
3
|
+
import { EVENT_CODE as se } from "../../../constants/aria.js";
|
|
4
4
|
import "@vueuse/core";
|
|
5
|
-
import { isUndefined as
|
|
5
|
+
import { isUndefined as ae } from "@vft/utils";
|
|
6
6
|
import "../../config-provider/hooks/use-global-config.js";
|
|
7
7
|
import "lodash-es";
|
|
8
8
|
import "../../form/index.js";
|
|
9
|
-
import { useNamespace as
|
|
9
|
+
import { useNamespace as ie } from "../../../hooks/use-namespace/index.js";
|
|
10
10
|
import "../../../hooks/use-model-toggle/index.js";
|
|
11
11
|
import "@popperjs/core";
|
|
12
12
|
import "../../../hooks/use-z-index/index.js";
|
|
13
|
-
import
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import
|
|
18
|
-
|
|
13
|
+
import re from "../../../locale/use-locale.js";
|
|
14
|
+
import { PICKER_BASE_INJECTION_KEY as le } from "../constants.js";
|
|
15
|
+
import { panelTimePickerProps as ce } from "../props/panel-time-picker.js";
|
|
16
|
+
import { useTimePanel as pe } from "../composables/use-time-panel.js";
|
|
17
|
+
import { useOldValue as me, buildAvailableTimeSlotGetter as ue } from "../composables/use-time-picker.js";
|
|
18
|
+
import de from "./basic-time-spinner.vue2.js";
|
|
19
|
+
const Pe = /* @__PURE__ */ Q({
|
|
19
20
|
__name: "panel-time-pick",
|
|
20
|
-
props:
|
|
21
|
+
props: ce,
|
|
21
22
|
emits: ["pick", "select-range", "set-picker-option"],
|
|
22
|
-
setup(
|
|
23
|
-
const
|
|
24
|
-
arrowControl:
|
|
23
|
+
setup(R, { emit: E }) {
|
|
24
|
+
const o = R, s = E, _ = W(le), {
|
|
25
|
+
arrowControl: D,
|
|
25
26
|
disabledHours: b,
|
|
26
27
|
disabledMinutes: g,
|
|
27
28
|
disabledSeconds: v,
|
|
28
|
-
defaultValue:
|
|
29
|
-
} =
|
|
30
|
-
const t = f(e).locale(
|
|
29
|
+
defaultValue: N
|
|
30
|
+
} = _.props, { getAvailableHours: O, getAvailableMinutes: P, getAvailableSeconds: y } = ue(b, g, v), i = ie("time"), { t: k } = re(), m = w("zh-cn"), h = w([0, 2]), I = me(o), B = d(() => ae(o.actualVisible) ? `${i.namespace.value}-zoom-in-top` : ""), l = d(() => o.format.includes("ss")), K = d(() => o.format.includes("A") ? "A" : o.format.includes("a") ? "a" : ""), x = (e) => {
|
|
31
|
+
const t = f(e).locale(m.value), a = u(t);
|
|
31
32
|
return t.isSame(a);
|
|
32
|
-
},
|
|
33
|
-
|
|
34
|
-
},
|
|
35
|
-
t ||
|
|
36
|
-
}, z = (e) => {
|
|
37
|
-
if (!n.visible)
|
|
38
|
-
return;
|
|
39
|
-
const t = m(e).millisecond(0);
|
|
40
|
-
o("pick", t, !0);
|
|
41
|
-
}, M = (e, t) => {
|
|
42
|
-
o("select-range", e, t), k.value = [e, t];
|
|
33
|
+
}, z = () => {
|
|
34
|
+
s("pick", I.value, !1);
|
|
35
|
+
}, M = (e = !1, t = !1) => {
|
|
36
|
+
t || s("pick", o.parsedValue, e);
|
|
43
37
|
}, U = (e) => {
|
|
38
|
+
if (!o.visible)
|
|
39
|
+
return;
|
|
40
|
+
const t = u(e).millisecond(0);
|
|
41
|
+
s("pick", t, !0);
|
|
42
|
+
}, $ = (e, t) => {
|
|
43
|
+
s("select-range", e, t), h.value = [e, t];
|
|
44
|
+
}, j = (e) => {
|
|
44
45
|
const t = [0, 3].concat(l.value ? [6] : []), a = ["hours", "minutes"].concat(
|
|
45
46
|
l.value ? ["seconds"] : []
|
|
46
|
-
), c = (t.indexOf(
|
|
47
|
-
|
|
48
|
-
},
|
|
49
|
-
const t = e.code, { left: a, right:
|
|
50
|
-
if ([a,
|
|
51
|
-
|
|
47
|
+
), c = (t.indexOf(h.value[0]) + e + t.length) % t.length;
|
|
48
|
+
V.start_emitSelectRange(a[c]);
|
|
49
|
+
}, H = (e) => {
|
|
50
|
+
const t = e.code, { left: a, right: S, up: c, down: F } = se;
|
|
51
|
+
if ([a, S].includes(t)) {
|
|
52
|
+
j(t === a ? -1 : 1), e.preventDefault();
|
|
52
53
|
return;
|
|
53
54
|
}
|
|
54
|
-
if ([c,
|
|
55
|
-
const
|
|
56
|
-
|
|
55
|
+
if ([c, F].includes(t)) {
|
|
56
|
+
const C = t === c ? -1 : 1;
|
|
57
|
+
V.start_scrollDown(C), e.preventDefault();
|
|
57
58
|
}
|
|
58
|
-
}, { timePickerOptions:
|
|
59
|
-
getAvailableHours:
|
|
60
|
-
getAvailableMinutes:
|
|
61
|
-
getAvailableSeconds:
|
|
62
|
-
}),
|
|
63
|
-
return
|
|
64
|
-
default:
|
|
65
|
-
e.actualVisible || e.visible ? (
|
|
59
|
+
}, { timePickerOptions: V, onSetOption: G, getAvailableTime: J } = pe({
|
|
60
|
+
getAvailableHours: O,
|
|
61
|
+
getAvailableMinutes: P,
|
|
62
|
+
getAvailableSeconds: y
|
|
63
|
+
}), u = (e) => J(e, o.datetimeRole || "", !0), L = (e) => e ? f(e, o.format).locale(m.value) : null, Y = (e) => e ? e.format(o.format) : null, q = () => f(N).locale(m.value);
|
|
64
|
+
return s("set-picker-option", ["isValidValue", x]), s("set-picker-option", ["formatToString", Y]), s("set-picker-option", ["parseUserInput", L]), s("set-picker-option", ["handleKeydownInput", H]), s("set-picker-option", ["getRangeAvailableTime", u]), s("set-picker-option", ["getDefaultValue", q]), (e, t) => (T(), X(Z, { name: B.value }, {
|
|
65
|
+
default: ee(() => [
|
|
66
|
+
e.actualVisible || e.visible ? (T(), te("div", {
|
|
66
67
|
key: 0,
|
|
67
|
-
class: r(
|
|
68
|
+
class: r(n(i).b("panel"))
|
|
68
69
|
}, [
|
|
69
70
|
p("div", {
|
|
70
|
-
class: r([
|
|
71
|
+
class: r([n(i).be("panel", "content"), { "has-seconds": l.value }])
|
|
71
72
|
}, [
|
|
72
|
-
|
|
73
|
+
ne(de, {
|
|
73
74
|
ref: "spinner",
|
|
74
75
|
role: e.datetimeRole || "start",
|
|
75
|
-
"arrow-control":
|
|
76
|
+
"arrow-control": n(D),
|
|
76
77
|
"show-seconds": l.value,
|
|
77
|
-
"am-pm-mode":
|
|
78
|
+
"am-pm-mode": K.value,
|
|
78
79
|
"spinner-date": e.parsedValue,
|
|
79
|
-
"disabled-hours":
|
|
80
|
-
"disabled-minutes":
|
|
81
|
-
"disabled-seconds":
|
|
82
|
-
onChange:
|
|
83
|
-
onSetOption:
|
|
84
|
-
onSelectRange:
|
|
80
|
+
"disabled-hours": n(b),
|
|
81
|
+
"disabled-minutes": n(g),
|
|
82
|
+
"disabled-seconds": n(v),
|
|
83
|
+
onChange: U,
|
|
84
|
+
onSetOption: n(G),
|
|
85
|
+
onSelectRange: $
|
|
85
86
|
}, null, 8, ["role", "arrow-control", "show-seconds", "am-pm-mode", "spinner-date", "disabled-hours", "disabled-minutes", "disabled-seconds", "onSetOption"])
|
|
86
87
|
], 2),
|
|
87
88
|
p("div", {
|
|
88
|
-
class: r(
|
|
89
|
+
class: r(n(i).be("panel", "footer"))
|
|
89
90
|
}, [
|
|
90
91
|
p("button", {
|
|
91
92
|
type: "button",
|
|
92
|
-
class: r(["cancel", [
|
|
93
|
-
onClick:
|
|
94
|
-
}, "
|
|
93
|
+
class: r(["cancel", [n(i).be("panel", "btn")]]),
|
|
94
|
+
onClick: z
|
|
95
|
+
}, A(n(k)("vft.timePicker.cancel")), 3),
|
|
95
96
|
p("button", {
|
|
96
97
|
type: "button",
|
|
97
|
-
class: r(["confirm", [
|
|
98
|
-
onClick: t[0] || (t[0] = (a) =>
|
|
99
|
-
}, "
|
|
98
|
+
class: r(["confirm", [n(i).be("panel", "btn")]]),
|
|
99
|
+
onClick: t[0] || (t[0] = (a) => M())
|
|
100
|
+
}, A(n(k)("vft.timePicker.confirm")), 3)
|
|
100
101
|
], 2)
|
|
101
|
-
], 2)) :
|
|
102
|
+
], 2)) : oe("", !0)
|
|
102
103
|
]),
|
|
103
104
|
_: 1
|
|
104
105
|
}, 8, ["name"]));
|
|
105
106
|
}
|
|
106
107
|
});
|
|
107
108
|
export {
|
|
108
|
-
|
|
109
|
+
Pe as default
|
|
109
110
|
};
|