@das-fed/ui 6.4.0-hot.1 → 6.4.0-hot.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/packages/business-components/app-container/index.js +255 -47
- package/packages/business-components/app-container/index.js.gz +0 -0
- package/packages/business-components/change-enterprises/index.js +298 -90
- package/packages/business-components/change-enterprises/index.js.gz +0 -0
- package/packages/business-components/change-pwd/index.js +0 -1
- package/packages/business-components/currency-page/index.js +0 -1
- package/packages/business-components/device-panel/index.js +28123 -23290
- package/packages/business-components/device-panel/index.js.gz +0 -0
- package/packages/business-components/export-button/index.js +0 -1
- package/packages/business-components/import-button/index.js +0 -1
- package/packages/business-components/layout-breadcrumb/index.js +0 -1
- package/packages/business-components/model-table-dialog/index.js +0 -1
- package/packages/business-components/process-configuration/index.js +0 -1
- package/packages/business-components/process-form/index.js +1010 -802
- package/packages/business-components/process-form/index.js.gz +0 -0
- package/packages/business-components/process-log/index.js +3669 -332
- package/packages/business-components/process-log/index.js.gz +0 -0
- package/packages/business-components/process-table/index.js +0 -1
- package/packages/business-components/urgent-panel/index.js +2338 -1554
- package/packages/business-components/urgent-panel/index.js.gz +0 -0
- package/packages/business-components/user-org-dialog/index.js +0 -1
- package/packages/business-components/video-dialog/index.js +0 -1
- package/packages/components/alert/index.js +3418 -52
- package/packages/components/alert/index.js.gz +0 -0
- package/packages/components/audio-video/index.js +0 -1
- package/packages/components/autocomplete/index.js +2875 -457
- package/packages/components/autocomplete/index.js.gz +0 -0
- package/packages/components/breadcrumb/index.js +271 -48
- package/packages/components/breadcrumb/index.js.gz +0 -0
- package/packages/components/button/index.js +9800 -212
- package/packages/components/button/index.js.gz +0 -0
- package/packages/components/calendar/index.js +0 -1
- package/packages/components/cascader/index.js +6406 -140
- package/packages/components/cascader/index.js.gz +0 -0
- package/packages/components/checkbox/index.js +3837 -180
- package/packages/components/checkbox/index.js.gz +0 -0
- package/packages/components/collapse-panel/index.js +3624 -31
- package/packages/components/collapse-panel/index.js.gz +0 -0
- package/packages/components/collapse-transition/index.js +0 -1
- package/packages/components/collaspe/index.js +3624 -31
- package/packages/components/collaspe/index.js.gz +0 -0
- package/packages/components/color-picker/index.js +5346 -107
- package/packages/components/color-picker/index.js.gz +0 -0
- package/packages/components/custom-search-item/index.js +0 -1
- package/packages/components/date-picker/index.js +13993 -530
- package/packages/components/date-picker/index.js.gz +0 -0
- package/packages/components/dialog/index.js +1835 -187
- package/packages/components/dialog/index.js.gz +0 -0
- package/packages/components/dimple-layout/index.js +0 -1
- package/packages/components/drawer/index.js +1614 -39
- package/packages/components/drawer/index.js.gz +0 -0
- package/packages/components/dropdown/index.js +4615 -55
- package/packages/components/dropdown/index.js.gz +0 -0
- package/packages/components/edit-table/index.js +0 -1
- package/packages/components/empty/index.js +800 -40
- package/packages/components/empty/index.js.gz +0 -0
- package/packages/components/form/index.js +0 -1
- package/packages/components/form-item/index.js +0 -1
- package/packages/components/icon/index.js +0 -1
- package/packages/components/image-preview/index.js +1283 -34
- package/packages/components/image-preview/index.js.gz +0 -0
- package/packages/components/image-upload/index.js +11722 -112
- package/packages/components/image-upload/index.js.gz +0 -0
- package/packages/components/image-viewer/index.js +13168 -387
- package/packages/components/image-viewer/index.js.gz +0 -0
- package/packages/components/input/index.js +1086 -158
- package/packages/components/input/index.js.gz +0 -0
- package/packages/components/input-dialog-select/index.js +0 -1
- package/packages/components/input-number/index.js +1831 -146
- package/packages/components/input-number/index.js.gz +0 -0
- package/packages/components/live-player/index.js +3669 -2884
- package/packages/components/live-player/index.js.gz +0 -0
- package/packages/components/loading/index.js +0 -1
- package/packages/components/map/index.js +5214 -1191
- package/packages/components/map/index.js.gz +0 -0
- package/packages/components/menu-aside/index.js +8297 -604
- package/packages/components/menu-aside/index.js.gz +0 -0
- package/packages/components/menu-header/index.js +10077 -39
- package/packages/components/menu-header/index.js.gz +0 -0
- package/packages/components/message/index.js +1289 -54
- package/packages/components/message/index.js.gz +0 -0
- package/packages/components/notification/index.js +3269 -48
- package/packages/components/notification/index.js.gz +0 -0
- package/packages/components/pagination/index.js +8025 -149
- package/packages/components/pagination/index.js.gz +0 -0
- package/packages/components/popover/index.js +2495 -45
- package/packages/components/popover/index.js.gz +0 -0
- package/packages/components/popup-mask/index.js +0 -1
- package/packages/components/preview/index.js +0 -1
- package/packages/components/progress/index.js +517 -108
- package/packages/components/progress/index.js.gz +0 -0
- package/packages/components/radio/index.js +3724 -160
- package/packages/components/radio/index.js.gz +0 -0
- package/packages/components/radio-tabs/index.js +0 -1
- package/packages/components/rich-editor/index.js +0 -1
- package/packages/components/scrollbar/index.js +1442 -916
- package/packages/components/scrollbar/index.js.gz +0 -0
- package/packages/components/search/index.js +5261 -90
- package/packages/components/search/index.js.gz +0 -0
- package/packages/components/search-form/index.js +1010 -921
- package/packages/components/search-form/index.js.gz +0 -0
- package/packages/components/select/index.js +10505 -380
- package/packages/components/select/index.js.gz +0 -0
- package/packages/components/select-input/index.js +0 -1
- package/packages/components/select-list/index.js +1433 -1174
- package/packages/components/select-list/index.js.gz +0 -0
- package/packages/components/special-range-picker-month/index.js +2645 -197
- package/packages/components/special-range-picker-month/index.js.gz +0 -0
- package/packages/components/special-range-picker-year/index.js +2710 -260
- package/packages/components/special-range-picker-year/index.js.gz +0 -0
- package/packages/components/spin/index.js +3534 -49
- package/packages/components/spin/index.js.gz +0 -0
- package/packages/components/split-panel/index.js +0 -1
- package/packages/components/step/index.js +4085 -29
- package/packages/components/step/index.js.gz +0 -0
- package/packages/components/steps/index.js +4070 -15
- package/packages/components/steps/index.js.gz +0 -0
- package/packages/components/switch/index.js +547 -32
- package/packages/components/switch/index.js.gz +0 -0
- package/packages/components/table/index.js +17503 -5202
- package/packages/components/table/index.js.gz +0 -0
- package/packages/components/tabs/index.js +12630 -173
- package/packages/components/tabs/index.js.gz +0 -0
- package/packages/components/tag/index.js +325 -56
- package/packages/components/tag/index.js.gz +0 -0
- package/packages/components/text-tooltip/index.js +0 -1
- package/packages/components/time-line/index.js +3397 -61
- package/packages/components/time-line/index.js.gz +0 -0
- package/packages/components/tooltip/index.js +2174 -66
- package/packages/components/tooltip/index.js.gz +0 -0
- package/packages/components/tree/index.js +6747 -1882
- package/packages/components/tree/index.js.gz +0 -0
- package/packages/components/tree-select/index.js +2778 -359
- package/packages/components/tree-select/index.js.gz +0 -0
- package/packages/components/tree-table/index.js +0 -1
- package/packages/components/upload/index.js +11726 -116
- package/packages/components/upload/index.js.gz +0 -0
- package/packages/components/virtual-tree/index.js +2928 -87
- package/packages/components/virtual-tree/index.js.gz +0 -0
- package/packages/components/watermark/index.js +368 -18
- package/packages/components/watermark/index.js.gz +0 -0
- /package/packages/business-components/app-container/{style.css → index.css} +0 -0
- /package/packages/business-components/app-container/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/change-enterprises/{style.css → index.css} +0 -0
- /package/packages/business-components/change-enterprises/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/change-pwd/{style.css → index.css} +0 -0
- /package/packages/business-components/currency-page/{style.css → index.css} +0 -0
- /package/packages/business-components/device-panel/{style.css → index.css} +0 -0
- /package/packages/business-components/device-panel/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/export-button/{style.css → index.css} +0 -0
- /package/packages/business-components/import-button/{style.css → index.css} +0 -0
- /package/packages/business-components/layout-breadcrumb/{style.css → index.css} +0 -0
- /package/packages/business-components/model-table-dialog/{style.css → index.css} +0 -0
- /package/packages/business-components/model-table-dialog/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/process-configuration/{style.css → index.css} +0 -0
- /package/packages/business-components/process-configuration/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/process-form/{style.css → index.css} +0 -0
- /package/packages/business-components/process-log/{style.css → index.css} +0 -0
- /package/packages/business-components/process-log/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/process-table/{style.css → index.css} +0 -0
- /package/packages/business-components/urgent-panel/{style.css → index.css} +0 -0
- /package/packages/business-components/urgent-panel/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/user-org-dialog/{style.css → index.css} +0 -0
- /package/packages/business-components/user-org-dialog/{style.css.gz → index.css.gz} +0 -0
- /package/packages/business-components/video-dialog/{style.css → index.css} +0 -0
- /package/packages/business-components/video-dialog/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/alert/{style.css → index.css} +0 -0
- /package/packages/components/alert/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/audio-video/{style.css → index.css} +0 -0
- /package/packages/components/autocomplete/{style.css → index.css} +0 -0
- /package/packages/components/autocomplete/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/breadcrumb/{style.css → index.css} +0 -0
- /package/packages/components/breadcrumb/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/button/{style.css → index.css} +0 -0
- /package/packages/components/button/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/calendar/{style.css → index.css} +0 -0
- /package/packages/components/calendar/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/cascader/{style.css → index.css} +0 -0
- /package/packages/components/cascader/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/checkbox/{style.css → index.css} +0 -0
- /package/packages/components/checkbox/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/collapse-panel/{style.css → index.css} +0 -0
- /package/packages/components/collapse-panel/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/collapse-transition/{style.css → index.css} +0 -0
- /package/packages/components/collaspe/{style.css → index.css} +0 -0
- /package/packages/components/color-picker/{style.css → index.css} +0 -0
- /package/packages/components/color-picker/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/custom-search-item/{style.css → index.css} +0 -0
- /package/packages/components/date-picker/{style.css → index.css} +0 -0
- /package/packages/components/date-picker/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/dialog/{style.css → index.css} +0 -0
- /package/packages/components/dialog/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/dimple-layout/{style.css → index.css} +0 -0
- /package/packages/components/dimple-layout/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/drawer/{style.css → index.css} +0 -0
- /package/packages/components/dropdown/{style.css → index.css} +0 -0
- /package/packages/components/dropdown/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/edit-table/{style.css → index.css} +0 -0
- /package/packages/components/edit-table/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/empty/{style.css → index.css} +0 -0
- /package/packages/components/form/{style.css → index.css} +0 -0
- /package/packages/components/form-item/{style.css → index.css} +0 -0
- /package/packages/components/form-item/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/icon/{style.css → index.css} +0 -0
- /package/packages/components/image-upload/{style.css → index.css} +0 -0
- /package/packages/components/image-upload/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/image-viewer/{style.css → index.css} +0 -0
- /package/packages/components/image-viewer/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/input/{style.css → index.css} +0 -0
- /package/packages/components/input/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/input-dialog-select/{style.css → index.css} +0 -0
- /package/packages/components/input-dialog-select/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/input-number/{style.css → index.css} +0 -0
- /package/packages/components/input-number/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/live-player/{style.css → index.css} +0 -0
- /package/packages/components/loading/{style.css → index.css} +0 -0
- /package/packages/components/loading/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/map/{style.css → index.css} +0 -0
- /package/packages/components/menu-aside/{style.css → index.css} +0 -0
- /package/packages/components/menu-aside/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/menu-header/{style.css → index.css} +0 -0
- /package/packages/components/menu-header/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/message/{style.css → index.css} +0 -0
- /package/packages/components/message/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/notification/{style.css → index.css} +0 -0
- /package/packages/components/notification/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/pagination/{style.css → index.css} +0 -0
- /package/packages/components/pagination/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/popover/{style.css → index.css} +0 -0
- /package/packages/components/popover/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/popup-mask/{style.css → index.css} +0 -0
- /package/packages/components/preview/{style.css → index.css} +0 -0
- /package/packages/components/progress/{style.css → index.css} +0 -0
- /package/packages/components/progress/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/radio/{style.css → index.css} +0 -0
- /package/packages/components/radio/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/radio-tabs/{style.css → index.css} +0 -0
- /package/packages/components/radio-tabs/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/rich-editor/{style.css → index.css} +0 -0
- /package/packages/components/rich-editor/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/scrollbar/{style.css → index.css} +0 -0
- /package/packages/components/scrollbar/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/search/{style.css → index.css} +0 -0
- /package/packages/components/search/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/search-form/{style.css → index.css} +0 -0
- /package/packages/components/search-form/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/select/{style.css → index.css} +0 -0
- /package/packages/components/select/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/select-input/{style.css → index.css} +0 -0
- /package/packages/components/select-input/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/select-list/{style.css → index.css} +0 -0
- /package/packages/components/select-list/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/special-range-picker-month/{style.css → index.css} +0 -0
- /package/packages/components/special-range-picker-month/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/special-range-picker-year/{style.css → index.css} +0 -0
- /package/packages/components/special-range-picker-year/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/spin/{style.css → index.css} +0 -0
- /package/packages/components/spin/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/split-panel/{style.css → index.css} +0 -0
- /package/packages/components/split-panel/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/step/{style.css → index.css} +0 -0
- /package/packages/components/steps/{style.css → index.css} +0 -0
- /package/packages/components/steps/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/switch/{style.css → index.css} +0 -0
- /package/packages/components/switch/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/table/{style.css → index.css} +0 -0
- /package/packages/components/table/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tabs/{style.css → index.css} +0 -0
- /package/packages/components/tabs/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tag/{style.css → index.css} +0 -0
- /package/packages/components/tag/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/text-tooltip/{style.css → index.css} +0 -0
- /package/packages/components/text-tooltip/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/time-line/{style.css → index.css} +0 -0
- /package/packages/components/time-line/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tooltip/{style.css → index.css} +0 -0
- /package/packages/components/tooltip/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tree/{style.css → index.css} +0 -0
- /package/packages/components/tree/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tree-select/{style.css → index.css} +0 -0
- /package/packages/components/tree-select/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/tree-table/{style.css → index.css} +0 -0
- /package/packages/components/tree-table/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/upload/{style.css → index.css} +0 -0
- /package/packages/components/upload/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/virtual-tree/{style.css → index.css} +0 -0
- /package/packages/components/virtual-tree/{style.css.gz → index.css.gz} +0 -0
- /package/packages/components/watermark/{style.css → index.css} +0 -0
|
@@ -1,37 +1,296 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import "
|
|
7
|
-
import "
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import { useModelValue as Zt } from "@das-fed/utils/vue";
|
|
15
|
-
import { SizeWatcher as Fi } from "@das-fed/utils/size-watcher";
|
|
1
|
+
import { withInstall as Vn } from "@das-fed/utils/with-install/index";
|
|
2
|
+
import { i18n as Ue, setI18nRule as Fn } from "@das-fed/web/packages/i18n/index";
|
|
3
|
+
import { getVar as pt, setThemeRule as Ln } from "@das-fed/web/packages/theme/index";
|
|
4
|
+
import "element-plus/theme-chalk/base.css";
|
|
5
|
+
import "element-plus/theme-chalk/el-infinite-scroll.css";
|
|
6
|
+
import { nextTick as Ie, pushScopeId as Hn, popScopeId as jn, openBlock as z, createBlock as le, withScopeId as Bn, markRaw as Wn, shallowReactive as Xn, resolveComponent as Yn, resolveDirective as Gn, withDirectives as Ee, createElementBlock as X, normalizeClass as de, renderSlot as ye, createCommentVNode as Q, resolveDynamicComponent as Yt, normalizeStyle as fn, withCtx as nt, Fragment as At, renderList as Nt, mergeProps as Un, toHandlers as Kn, createVNode as qn, ref as $e, computed as it, onMounted as hn, onBeforeUnmount as Jn, watch as Gt, defineComponent as Zn, useCssVars as Qn, createElementVNode as Ae, toDisplayString as Ne, unref as O, createTextVNode as Be } from "vue";
|
|
7
|
+
import { vDasTooltip as mt } from "@das-fed/ui/packages/components/text-tooltip/index";
|
|
8
|
+
import { DasButton as ei } from "@das-fed/ui/packages/components/button/index";
|
|
9
|
+
import { vOverlay as ti } from "@das-fed/ui/packages/components/overlay/index";
|
|
10
|
+
import { DasIconClose2 as gt } from "@das-fed/ui/packages/icons/close-2/index";
|
|
11
|
+
import { DasIconDrag as ni } from "@das-fed/ui/packages/icons/drag/index";
|
|
12
|
+
import { useModelValue as pn } from "@das-fed/utils/vue";
|
|
13
|
+
import { SizeWatcher as ii } from "@das-fed/utils/size-watcher";
|
|
16
14
|
import "@das-fed/ui/packages/global/theme";
|
|
17
15
|
import "@das-fed/ui/packages/global/style";
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
16
|
+
var Ut;
|
|
17
|
+
const dt = typeof window < "u";
|
|
18
|
+
dt && ((Ut = window == null ? void 0 : window.navigator) != null && Ut.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
19
|
+
const Kt = (e) => {
|
|
20
|
+
let t = 0, n = e;
|
|
21
|
+
for (; n; )
|
|
22
|
+
t += n.offsetTop, n = n.offsetParent;
|
|
23
|
+
return t;
|
|
24
|
+
}, ri = (e, t) => Math.abs(Kt(e) - Kt(t));
|
|
25
|
+
/**
|
|
26
|
+
* @vue/shared v3.4.35
|
|
27
|
+
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
28
|
+
* @license MIT
|
|
29
|
+
**/
|
|
30
|
+
process.env.NODE_ENV !== "production" && Object.freeze({});
|
|
31
|
+
process.env.NODE_ENV !== "production" && Object.freeze([]);
|
|
32
|
+
const oi = (e) => typeof e == "function", li = (e) => {
|
|
33
|
+
const t = /* @__PURE__ */ Object.create(null);
|
|
34
|
+
return (n) => t[n] || (t[n] = e(n));
|
|
35
|
+
}, ai = /-(\w)/g, si = li((e) => e.replace(ai, (t, n) => n ? n.toUpperCase() : ""));
|
|
36
|
+
var ui = typeof global == "object" && global && global.Object === Object && global, ci = typeof self == "object" && self && self.Object === Object && self, mn = ui || ci || Function("return this")(), rt = mn.Symbol, gn = Object.prototype, di = gn.hasOwnProperty, fi = gn.toString, ze = rt ? rt.toStringTag : void 0;
|
|
37
|
+
function hi(e) {
|
|
38
|
+
var t = di.call(e, ze), n = e[ze];
|
|
39
|
+
try {
|
|
40
|
+
e[ze] = void 0;
|
|
41
|
+
var i = !0;
|
|
42
|
+
} catch {
|
|
43
|
+
}
|
|
44
|
+
var r = fi.call(e);
|
|
45
|
+
return i && (t ? e[ze] = n : delete e[ze]), r;
|
|
46
|
+
}
|
|
47
|
+
var pi = Object.prototype, mi = pi.toString;
|
|
48
|
+
function gi(e) {
|
|
49
|
+
return mi.call(e);
|
|
50
|
+
}
|
|
51
|
+
var vi = "[object Null]", bi = "[object Undefined]", qt = rt ? rt.toStringTag : void 0;
|
|
52
|
+
function yi(e) {
|
|
53
|
+
return e == null ? e === void 0 ? bi : vi : qt && qt in Object(e) ? hi(e) : gi(e);
|
|
54
|
+
}
|
|
55
|
+
function wi(e) {
|
|
56
|
+
return e != null && typeof e == "object";
|
|
57
|
+
}
|
|
58
|
+
var Si = "[object Symbol]";
|
|
59
|
+
function Ei(e) {
|
|
60
|
+
return typeof e == "symbol" || wi(e) && yi(e) == Si;
|
|
61
|
+
}
|
|
62
|
+
var _i = /\s/;
|
|
63
|
+
function Ti(e) {
|
|
64
|
+
for (var t = e.length; t-- && _i.test(e.charAt(t)); )
|
|
65
|
+
;
|
|
66
|
+
return t;
|
|
67
|
+
}
|
|
68
|
+
var Di = /^\s+/;
|
|
69
|
+
function Ii(e) {
|
|
70
|
+
return e && e.slice(0, Ti(e) + 1).replace(Di, "");
|
|
71
|
+
}
|
|
72
|
+
function ot(e) {
|
|
73
|
+
var t = typeof e;
|
|
74
|
+
return e != null && (t == "object" || t == "function");
|
|
75
|
+
}
|
|
76
|
+
var Jt = NaN, Oi = /^[-+]0x[0-9a-f]+$/i, Ci = /^0b[01]+$/i, Ai = /^0o[0-7]+$/i, Ni = parseInt;
|
|
77
|
+
function Zt(e) {
|
|
78
|
+
if (typeof e == "number")
|
|
79
|
+
return e;
|
|
80
|
+
if (Ei(e))
|
|
81
|
+
return Jt;
|
|
82
|
+
if (ot(e)) {
|
|
83
|
+
var t = typeof e.valueOf == "function" ? e.valueOf() : e;
|
|
84
|
+
e = ot(t) ? t + "" : t;
|
|
85
|
+
}
|
|
86
|
+
if (typeof e != "string")
|
|
87
|
+
return e === 0 ? e : +e;
|
|
88
|
+
e = Ii(e);
|
|
89
|
+
var n = Ci.test(e);
|
|
90
|
+
return n || Ai.test(e) ? Ni(e.slice(2), n ? 2 : 8) : Oi.test(e) ? Jt : +e;
|
|
91
|
+
}
|
|
92
|
+
var vt = function() {
|
|
93
|
+
return mn.Date.now();
|
|
94
|
+
}, zi = "Expected a function", Pi = Math.max, ki = Math.min;
|
|
95
|
+
function xi(e, t, n) {
|
|
96
|
+
var i, r, o, l, s, a, u = 0, c = !1, d = !1, m = !0;
|
|
97
|
+
if (typeof e != "function")
|
|
98
|
+
throw new TypeError(zi);
|
|
99
|
+
t = Zt(t) || 0, ot(n) && (c = !!n.leading, d = "maxWait" in n, o = d ? Pi(Zt(n.maxWait) || 0, t) : o, m = "trailing" in n ? !!n.trailing : m);
|
|
100
|
+
function y(I) {
|
|
101
|
+
var P = i, L = r;
|
|
102
|
+
return i = r = void 0, u = I, l = e.apply(L, P), l;
|
|
103
|
+
}
|
|
104
|
+
function S(I) {
|
|
105
|
+
return u = I, s = setTimeout(T, t), c ? y(I) : l;
|
|
106
|
+
}
|
|
107
|
+
function p(I) {
|
|
108
|
+
var P = I - a, L = I - u, R = t - P;
|
|
109
|
+
return d ? ki(R, o - L) : R;
|
|
110
|
+
}
|
|
111
|
+
function f(I) {
|
|
112
|
+
var P = I - a, L = I - u;
|
|
113
|
+
return a === void 0 || P >= t || P < 0 || d && L >= o;
|
|
114
|
+
}
|
|
115
|
+
function T() {
|
|
116
|
+
var I = vt();
|
|
117
|
+
if (f(I))
|
|
118
|
+
return D(I);
|
|
119
|
+
s = setTimeout(T, p(I));
|
|
120
|
+
}
|
|
121
|
+
function D(I) {
|
|
122
|
+
return s = void 0, m && i ? y(I) : (i = r = void 0, l);
|
|
123
|
+
}
|
|
124
|
+
function w() {
|
|
125
|
+
s !== void 0 && clearTimeout(s), u = 0, i = a = r = s = void 0;
|
|
126
|
+
}
|
|
127
|
+
function g() {
|
|
128
|
+
return s === void 0 ? l : D(vt());
|
|
129
|
+
}
|
|
130
|
+
function B() {
|
|
131
|
+
var I = vt(), P = f(I);
|
|
132
|
+
if (i = arguments, r = this, a = I, P) {
|
|
133
|
+
if (s === void 0)
|
|
134
|
+
return S(a);
|
|
135
|
+
if (d)
|
|
136
|
+
return clearTimeout(s), s = setTimeout(T, t), y(a);
|
|
137
|
+
}
|
|
138
|
+
return s === void 0 && (s = setTimeout(T, t)), l;
|
|
139
|
+
}
|
|
140
|
+
return B.cancel = w, B.flush = g, B;
|
|
141
|
+
}
|
|
142
|
+
var $i = "Expected a function";
|
|
143
|
+
function Qt(e, t, n) {
|
|
144
|
+
var i = !0, r = !0;
|
|
145
|
+
if (typeof e != "function")
|
|
146
|
+
throw new TypeError($i);
|
|
147
|
+
return ot(n) && (i = "leading" in n ? !!n.leading : i, r = "trailing" in n ? !!n.trailing : r), xi(e, t, {
|
|
148
|
+
leading: i,
|
|
149
|
+
maxWait: t,
|
|
150
|
+
trailing: r
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
class Mi extends Error {
|
|
154
|
+
constructor(t) {
|
|
155
|
+
super(t), this.name = "ElementPlusError";
|
|
26
156
|
}
|
|
27
|
-
var r = t.indexOf("Edge/");
|
|
28
|
-
return r > 0 ? parseInt(t.substring(r + 5, t.indexOf(".", r)), 10) : -1;
|
|
29
157
|
}
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
Dt.init || (Dt.init = !0, je = Hi() !== -1);
|
|
158
|
+
function Ri(e, t) {
|
|
159
|
+
throw new Mi(`[${e}] ${t}`);
|
|
33
160
|
}
|
|
34
|
-
|
|
161
|
+
const Vi = (e, t) => {
|
|
162
|
+
var n;
|
|
163
|
+
if (!dt || !e || !t)
|
|
164
|
+
return "";
|
|
165
|
+
let i = si(t);
|
|
166
|
+
i === "float" && (i = "cssFloat");
|
|
167
|
+
try {
|
|
168
|
+
const r = e.style[i];
|
|
169
|
+
if (r)
|
|
170
|
+
return r;
|
|
171
|
+
const o = (n = document.defaultView) == null ? void 0 : n.getComputedStyle(e, "");
|
|
172
|
+
return o ? o[i] : "";
|
|
173
|
+
} catch {
|
|
174
|
+
return e.style[i];
|
|
175
|
+
}
|
|
176
|
+
}, Fi = (e, t) => {
|
|
177
|
+
if (!dt)
|
|
178
|
+
return !1;
|
|
179
|
+
const n = {
|
|
180
|
+
undefined: "overflow",
|
|
181
|
+
true: "overflow-y",
|
|
182
|
+
false: "overflow-x"
|
|
183
|
+
}[String(t)], i = Vi(e, n);
|
|
184
|
+
return ["scroll", "auto", "overlay"].some((r) => i.includes(r));
|
|
185
|
+
}, Li = (e, t) => {
|
|
186
|
+
if (!dt)
|
|
187
|
+
return;
|
|
188
|
+
let n = e;
|
|
189
|
+
for (; n; ) {
|
|
190
|
+
if ([window, document, document.documentElement].includes(n))
|
|
191
|
+
return window;
|
|
192
|
+
if (Fi(n, t))
|
|
193
|
+
return n;
|
|
194
|
+
n = n.parentNode;
|
|
195
|
+
}
|
|
196
|
+
return n;
|
|
197
|
+
}, ie = "ElInfiniteScroll", Hi = 50, ji = 200, Bi = 0, Wi = {
|
|
198
|
+
delay: {
|
|
199
|
+
type: Number,
|
|
200
|
+
default: ji
|
|
201
|
+
},
|
|
202
|
+
distance: {
|
|
203
|
+
type: Number,
|
|
204
|
+
default: Bi
|
|
205
|
+
},
|
|
206
|
+
disabled: {
|
|
207
|
+
type: Boolean,
|
|
208
|
+
default: !1
|
|
209
|
+
},
|
|
210
|
+
immediate: {
|
|
211
|
+
type: Boolean,
|
|
212
|
+
default: !0
|
|
213
|
+
}
|
|
214
|
+
}, Lt = (e, t) => Object.entries(Wi).reduce((n, [i, r]) => {
|
|
215
|
+
var o, l;
|
|
216
|
+
const { type: s, default: a } = r, u = e.getAttribute(`infinite-scroll-${i}`);
|
|
217
|
+
let c = (l = (o = t[u]) != null ? o : u) != null ? l : a;
|
|
218
|
+
return c = c === "false" ? !1 : c, c = s(c), n[i] = Number.isNaN(c) ? a : c, n;
|
|
219
|
+
}, {}), vn = (e) => {
|
|
220
|
+
const { observer: t } = e[ie];
|
|
221
|
+
t && (t.disconnect(), delete e[ie].observer);
|
|
222
|
+
}, Xi = (e, t) => {
|
|
223
|
+
const { container: n, containerEl: i, instance: r, observer: o, lastScrollTop: l } = e[ie], { disabled: s, distance: a } = Lt(e, r), { clientHeight: u, scrollHeight: c, scrollTop: d } = i, m = d - l;
|
|
224
|
+
if (e[ie].lastScrollTop = d, o || s || m < 0)
|
|
225
|
+
return;
|
|
226
|
+
let y = !1;
|
|
227
|
+
if (n === e)
|
|
228
|
+
y = c - (u + d) <= a;
|
|
229
|
+
else {
|
|
230
|
+
const { clientTop: S, scrollHeight: p } = e, f = ri(e, i);
|
|
231
|
+
y = d + u >= f + S + p - a;
|
|
232
|
+
}
|
|
233
|
+
y && t.call(r);
|
|
234
|
+
};
|
|
235
|
+
function bt(e, t) {
|
|
236
|
+
const { containerEl: n, instance: i } = e[ie], { disabled: r } = Lt(e, i);
|
|
237
|
+
r || n.clientHeight === 0 || (n.scrollHeight <= n.clientHeight ? t.call(i) : vn(e));
|
|
238
|
+
}
|
|
239
|
+
const Yi = {
|
|
240
|
+
async mounted(e, t) {
|
|
241
|
+
const { instance: n, value: i } = t;
|
|
242
|
+
oi(i) || Ri(ie, "'v-infinite-scroll' binding value must be a function"), await Ie();
|
|
243
|
+
const { delay: r, immediate: o } = Lt(e, n), l = Li(e, !0), s = l === window ? document.documentElement : l, a = Qt(Xi.bind(null, e, i), r);
|
|
244
|
+
if (l) {
|
|
245
|
+
if (e[ie] = {
|
|
246
|
+
instance: n,
|
|
247
|
+
container: l,
|
|
248
|
+
containerEl: s,
|
|
249
|
+
delay: r,
|
|
250
|
+
cb: i,
|
|
251
|
+
onScroll: a,
|
|
252
|
+
lastScrollTop: s.scrollTop
|
|
253
|
+
}, o) {
|
|
254
|
+
const u = new MutationObserver(Qt(bt.bind(null, e, i), Hi));
|
|
255
|
+
e[ie].observer = u, u.observe(e, { childList: !0, subtree: !0 }), bt(e, i);
|
|
256
|
+
}
|
|
257
|
+
l.addEventListener("scroll", a);
|
|
258
|
+
}
|
|
259
|
+
},
|
|
260
|
+
unmounted(e) {
|
|
261
|
+
const { container: t, onScroll: n } = e[ie];
|
|
262
|
+
t == null || t.removeEventListener("scroll", n), vn(e);
|
|
263
|
+
},
|
|
264
|
+
async updated(e) {
|
|
265
|
+
if (!e[ie])
|
|
266
|
+
await Ie();
|
|
267
|
+
else {
|
|
268
|
+
const { containerEl: t, cb: n, observer: i } = e[ie];
|
|
269
|
+
t.clientHeight && i && bt(e, n);
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}, zt = Yi;
|
|
273
|
+
zt.install = (e) => {
|
|
274
|
+
e.directive("InfiniteScroll", zt);
|
|
275
|
+
};
|
|
276
|
+
const Gi = zt;
|
|
277
|
+
function Ui() {
|
|
278
|
+
var e = window.navigator.userAgent, t = e.indexOf("MSIE ");
|
|
279
|
+
if (t > 0)
|
|
280
|
+
return parseInt(e.substring(t + 5, e.indexOf(".", t)), 10);
|
|
281
|
+
var n = e.indexOf("Trident/");
|
|
282
|
+
if (n > 0) {
|
|
283
|
+
var i = e.indexOf("rv:");
|
|
284
|
+
return parseInt(e.substring(i + 3, e.indexOf(".", i)), 10);
|
|
285
|
+
}
|
|
286
|
+
var r = e.indexOf("Edge/");
|
|
287
|
+
return r > 0 ? parseInt(e.substring(r + 5, e.indexOf(".", r)), 10) : -1;
|
|
288
|
+
}
|
|
289
|
+
let Ke;
|
|
290
|
+
function Pt() {
|
|
291
|
+
Pt.init || (Pt.init = !0, Ke = Ui() !== -1);
|
|
292
|
+
}
|
|
293
|
+
var ft = {
|
|
35
294
|
name: "ResizeObserver",
|
|
36
295
|
props: {
|
|
37
296
|
emitOnMount: {
|
|
@@ -51,11 +310,11 @@ var at = {
|
|
|
51
310
|
"notify"
|
|
52
311
|
],
|
|
53
312
|
mounted() {
|
|
54
|
-
|
|
313
|
+
Pt(), Ie(() => {
|
|
55
314
|
this._w = this.$el.offsetWidth, this._h = this.$el.offsetHeight, this.emitOnMount && this.emitSize();
|
|
56
315
|
});
|
|
57
|
-
const
|
|
58
|
-
this._resizeObject =
|
|
316
|
+
const e = document.createElement("object");
|
|
317
|
+
this._resizeObject = e, e.setAttribute("aria-hidden", "true"), e.setAttribute("tabindex", -1), e.onload = this.addResizeHandlers, e.type = "text/html", Ke && this.$el.appendChild(e), e.data = "about:blank", Ke || this.$el.appendChild(e);
|
|
59
318
|
},
|
|
60
319
|
beforeUnmount() {
|
|
61
320
|
this.removeResizeHandlers();
|
|
@@ -74,113 +333,113 @@ var at = {
|
|
|
74
333
|
this._resizeObject.contentDocument.defaultView.addEventListener("resize", this.compareAndNotify), this.compareAndNotify();
|
|
75
334
|
},
|
|
76
335
|
removeResizeHandlers() {
|
|
77
|
-
this._resizeObject && this._resizeObject.onload && (!
|
|
336
|
+
this._resizeObject && this._resizeObject.onload && (!Ke && this._resizeObject.contentDocument && this._resizeObject.contentDocument.defaultView.removeEventListener("resize", this.compareAndNotify), this.$el.removeChild(this._resizeObject), this._resizeObject.onload = null, this._resizeObject = null);
|
|
78
337
|
}
|
|
79
338
|
}
|
|
80
339
|
};
|
|
81
|
-
const
|
|
82
|
-
|
|
83
|
-
const
|
|
340
|
+
const Ki = /* @__PURE__ */ Bn("data-v-b329ee4c");
|
|
341
|
+
Hn("data-v-b329ee4c");
|
|
342
|
+
const qi = {
|
|
84
343
|
class: "resize-observer",
|
|
85
344
|
tabindex: "-1"
|
|
86
345
|
};
|
|
87
|
-
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
function
|
|
346
|
+
jn();
|
|
347
|
+
const Ji = /* @__PURE__ */ Ki((e, t, n, i, r, o) => (z(), le("div", qi)));
|
|
348
|
+
ft.render = Ji;
|
|
349
|
+
ft.__scopeId = "data-v-b329ee4c";
|
|
350
|
+
ft.__file = "src/components/ResizeObserver.vue";
|
|
351
|
+
function qe(e) {
|
|
93
352
|
"@babel/helpers - typeof";
|
|
94
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
|
95
|
-
return typeof
|
|
96
|
-
} :
|
|
97
|
-
return
|
|
98
|
-
},
|
|
99
|
-
}
|
|
100
|
-
function
|
|
101
|
-
if (!(
|
|
353
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? qe = function(t) {
|
|
354
|
+
return typeof t;
|
|
355
|
+
} : qe = function(t) {
|
|
356
|
+
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
357
|
+
}, qe(e);
|
|
358
|
+
}
|
|
359
|
+
function Zi(e, t) {
|
|
360
|
+
if (!(e instanceof t))
|
|
102
361
|
throw new TypeError("Cannot call a class as a function");
|
|
103
362
|
}
|
|
104
|
-
function
|
|
105
|
-
for (var
|
|
106
|
-
var
|
|
107
|
-
|
|
363
|
+
function Qi(e, t) {
|
|
364
|
+
for (var n = 0; n < t.length; n++) {
|
|
365
|
+
var i = t[n];
|
|
366
|
+
i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(e, i.key, i);
|
|
108
367
|
}
|
|
109
368
|
}
|
|
110
|
-
function
|
|
111
|
-
return
|
|
369
|
+
function er(e, t, n) {
|
|
370
|
+
return t && Qi(e.prototype, t), e;
|
|
112
371
|
}
|
|
113
|
-
function
|
|
114
|
-
return
|
|
372
|
+
function en(e) {
|
|
373
|
+
return tr(e) || nr(e) || ir(e) || rr();
|
|
115
374
|
}
|
|
116
|
-
function
|
|
117
|
-
if (Array.isArray(
|
|
375
|
+
function tr(e) {
|
|
376
|
+
if (Array.isArray(e)) return kt(e);
|
|
118
377
|
}
|
|
119
|
-
function
|
|
120
|
-
if (typeof Symbol < "u" && Symbol.iterator in Object(
|
|
378
|
+
function nr(e) {
|
|
379
|
+
if (typeof Symbol < "u" && Symbol.iterator in Object(e)) return Array.from(e);
|
|
121
380
|
}
|
|
122
|
-
function
|
|
123
|
-
if (
|
|
124
|
-
if (typeof
|
|
125
|
-
var
|
|
126
|
-
if (
|
|
127
|
-
if (
|
|
381
|
+
function ir(e, t) {
|
|
382
|
+
if (e) {
|
|
383
|
+
if (typeof e == "string") return kt(e, t);
|
|
384
|
+
var n = Object.prototype.toString.call(e).slice(8, -1);
|
|
385
|
+
if (n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set") return Array.from(e);
|
|
386
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return kt(e, t);
|
|
128
387
|
}
|
|
129
388
|
}
|
|
130
|
-
function
|
|
131
|
-
(
|
|
132
|
-
for (var
|
|
133
|
-
return
|
|
389
|
+
function kt(e, t) {
|
|
390
|
+
(t == null || t > e.length) && (t = e.length);
|
|
391
|
+
for (var n = 0, i = new Array(t); n < t; n++) i[n] = e[n];
|
|
392
|
+
return i;
|
|
134
393
|
}
|
|
135
|
-
function
|
|
394
|
+
function rr() {
|
|
136
395
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
137
396
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
138
397
|
}
|
|
139
|
-
function
|
|
140
|
-
var
|
|
141
|
-
return typeof
|
|
142
|
-
callback:
|
|
143
|
-
} :
|
|
144
|
-
}
|
|
145
|
-
function
|
|
146
|
-
var
|
|
147
|
-
for (var u = arguments.length,
|
|
148
|
-
d
|
|
149
|
-
if (o =
|
|
150
|
-
var m =
|
|
151
|
-
typeof m == "function" && (m = m(a, r)), (!
|
|
152
|
-
|
|
153
|
-
},
|
|
398
|
+
function or(e) {
|
|
399
|
+
var t;
|
|
400
|
+
return typeof e == "function" ? t = {
|
|
401
|
+
callback: e
|
|
402
|
+
} : t = e, t;
|
|
403
|
+
}
|
|
404
|
+
function lr(e, t) {
|
|
405
|
+
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, i, r, o, l = function(a) {
|
|
406
|
+
for (var u = arguments.length, c = new Array(u > 1 ? u - 1 : 0), d = 1; d < u; d++)
|
|
407
|
+
c[d - 1] = arguments[d];
|
|
408
|
+
if (o = c, !(i && a === r)) {
|
|
409
|
+
var m = n.leading;
|
|
410
|
+
typeof m == "function" && (m = m(a, r)), (!i || a !== r) && m && e.apply(void 0, [a].concat(en(o))), r = a, clearTimeout(i), i = setTimeout(function() {
|
|
411
|
+
e.apply(void 0, [a].concat(en(o))), i = 0;
|
|
412
|
+
}, t);
|
|
154
413
|
}
|
|
155
414
|
};
|
|
156
415
|
return l._clear = function() {
|
|
157
|
-
clearTimeout(
|
|
416
|
+
clearTimeout(i), i = null;
|
|
158
417
|
}, l;
|
|
159
418
|
}
|
|
160
|
-
function
|
|
161
|
-
if (
|
|
162
|
-
if (
|
|
163
|
-
for (var
|
|
164
|
-
if (!
|
|
419
|
+
function bn(e, t) {
|
|
420
|
+
if (e === t) return !0;
|
|
421
|
+
if (qe(e) === "object") {
|
|
422
|
+
for (var n in e)
|
|
423
|
+
if (!bn(e[n], t[n]))
|
|
165
424
|
return !1;
|
|
166
425
|
return !0;
|
|
167
426
|
}
|
|
168
427
|
return !1;
|
|
169
428
|
}
|
|
170
|
-
var
|
|
171
|
-
function t
|
|
172
|
-
|
|
429
|
+
var ar = /* @__PURE__ */ function() {
|
|
430
|
+
function e(t, n, i) {
|
|
431
|
+
Zi(this, e), this.el = t, this.observer = null, this.frozen = !1, this.createObserver(n, i);
|
|
173
432
|
}
|
|
174
|
-
return
|
|
433
|
+
return er(e, [{
|
|
175
434
|
key: "createObserver",
|
|
176
|
-
value: function(
|
|
435
|
+
value: function(n, i) {
|
|
177
436
|
var r = this;
|
|
178
437
|
if (this.observer && this.destroyObserver(), !this.frozen) {
|
|
179
|
-
if (this.options =
|
|
438
|
+
if (this.options = or(n), this.callback = function(s, a) {
|
|
180
439
|
r.options.callback(s, a), s && r.options.once && (r.frozen = !0, r.destroyObserver());
|
|
181
440
|
}, this.callback && this.options.throttle) {
|
|
182
441
|
var o = this.options.throttleOptions || {}, l = o.leading;
|
|
183
|
-
this.callback =
|
|
442
|
+
this.callback = lr(this.callback, this.options.throttle, {
|
|
184
443
|
leading: function(a) {
|
|
185
444
|
return l === "both" || l === "visible" && a || l === "hidden" && !a;
|
|
186
445
|
}
|
|
@@ -189,17 +448,17 @@ var Qi = /* @__PURE__ */ function() {
|
|
|
189
448
|
this.oldResult = void 0, this.observer = new IntersectionObserver(function(s) {
|
|
190
449
|
var a = s[0];
|
|
191
450
|
if (s.length > 1) {
|
|
192
|
-
var u = s.find(function(
|
|
193
|
-
return
|
|
451
|
+
var u = s.find(function(d) {
|
|
452
|
+
return d.isIntersecting;
|
|
194
453
|
});
|
|
195
454
|
u && (a = u);
|
|
196
455
|
}
|
|
197
456
|
if (r.callback) {
|
|
198
|
-
var
|
|
199
|
-
if (
|
|
200
|
-
r.oldResult =
|
|
457
|
+
var c = a.isIntersecting && a.intersectionRatio >= r.threshold;
|
|
458
|
+
if (c === r.oldResult) return;
|
|
459
|
+
r.oldResult = c, r.callback(c, a);
|
|
201
460
|
}
|
|
202
|
-
}, this.options.intersection),
|
|
461
|
+
}, this.options.intersection), Ie(function() {
|
|
203
462
|
r.observer && r.observer.observe(r.el);
|
|
204
463
|
});
|
|
205
464
|
}
|
|
@@ -214,66 +473,66 @@ var Qi = /* @__PURE__ */ function() {
|
|
|
214
473
|
get: function() {
|
|
215
474
|
return this.options.intersection && typeof this.options.intersection.threshold == "number" ? this.options.intersection.threshold : 0;
|
|
216
475
|
}
|
|
217
|
-
}]),
|
|
476
|
+
}]), e;
|
|
218
477
|
}();
|
|
219
|
-
function
|
|
220
|
-
var
|
|
221
|
-
if (
|
|
222
|
-
var r = new
|
|
223
|
-
|
|
478
|
+
function yn(e, t, n) {
|
|
479
|
+
var i = t.value;
|
|
480
|
+
if (i && !(typeof IntersectionObserver > "u")) {
|
|
481
|
+
var r = new ar(e, i, n);
|
|
482
|
+
e._vue_visibilityState = r;
|
|
224
483
|
}
|
|
225
484
|
}
|
|
226
|
-
function
|
|
227
|
-
var
|
|
228
|
-
if (!
|
|
229
|
-
var o =
|
|
230
|
-
if (!
|
|
231
|
-
|
|
485
|
+
function sr(e, t, n) {
|
|
486
|
+
var i = t.value, r = t.oldValue;
|
|
487
|
+
if (!bn(i, r)) {
|
|
488
|
+
var o = e._vue_visibilityState;
|
|
489
|
+
if (!i) {
|
|
490
|
+
wn(e);
|
|
232
491
|
return;
|
|
233
492
|
}
|
|
234
|
-
o ? o.createObserver(
|
|
235
|
-
value:
|
|
236
|
-
},
|
|
493
|
+
o ? o.createObserver(i, n) : yn(e, {
|
|
494
|
+
value: i
|
|
495
|
+
}, n);
|
|
237
496
|
}
|
|
238
497
|
}
|
|
239
|
-
function
|
|
240
|
-
var
|
|
241
|
-
|
|
498
|
+
function wn(e) {
|
|
499
|
+
var t = e._vue_visibilityState;
|
|
500
|
+
t && (t.destroyObserver(), delete e._vue_visibilityState);
|
|
242
501
|
}
|
|
243
|
-
var
|
|
244
|
-
beforeMount:
|
|
245
|
-
updated:
|
|
246
|
-
unmounted:
|
|
247
|
-
},
|
|
502
|
+
var ur = {
|
|
503
|
+
beforeMount: yn,
|
|
504
|
+
updated: sr,
|
|
505
|
+
unmounted: wn
|
|
506
|
+
}, cr = {
|
|
248
507
|
itemsLimit: 1e3
|
|
249
|
-
},
|
|
250
|
-
function
|
|
251
|
-
return
|
|
252
|
-
}
|
|
253
|
-
var
|
|
254
|
-
return getComputedStyle(
|
|
255
|
-
},
|
|
256
|
-
return
|
|
257
|
-
},
|
|
258
|
-
return
|
|
508
|
+
}, dr = /(auto|scroll)/;
|
|
509
|
+
function Sn(e, t) {
|
|
510
|
+
return e.parentNode === null ? t : Sn(e.parentNode, t.concat([e]));
|
|
511
|
+
}
|
|
512
|
+
var yt = function(t, n) {
|
|
513
|
+
return getComputedStyle(t, null).getPropertyValue(n);
|
|
514
|
+
}, fr = function(t) {
|
|
515
|
+
return yt(t, "overflow") + yt(t, "overflow-y") + yt(t, "overflow-x");
|
|
516
|
+
}, hr = function(t) {
|
|
517
|
+
return dr.test(fr(t));
|
|
259
518
|
};
|
|
260
|
-
function
|
|
261
|
-
if (
|
|
262
|
-
for (var
|
|
263
|
-
if (
|
|
264
|
-
return
|
|
519
|
+
function tn(e) {
|
|
520
|
+
if (e instanceof HTMLElement || e instanceof SVGElement) {
|
|
521
|
+
for (var t = Sn(e.parentNode, []), n = 0; n < t.length; n += 1)
|
|
522
|
+
if (hr(t[n]))
|
|
523
|
+
return t[n];
|
|
265
524
|
return document.scrollingElement || document.documentElement;
|
|
266
525
|
}
|
|
267
526
|
}
|
|
268
|
-
function
|
|
527
|
+
function xt(e) {
|
|
269
528
|
"@babel/helpers - typeof";
|
|
270
|
-
return
|
|
271
|
-
return typeof
|
|
272
|
-
} : function(
|
|
273
|
-
return
|
|
274
|
-
},
|
|
529
|
+
return xt = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
530
|
+
return typeof t;
|
|
531
|
+
} : function(t) {
|
|
532
|
+
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
533
|
+
}, xt(e);
|
|
275
534
|
}
|
|
276
|
-
var
|
|
535
|
+
var pr = {
|
|
277
536
|
items: {
|
|
278
537
|
type: Array,
|
|
279
538
|
required: !0
|
|
@@ -285,8 +544,8 @@ var an = {
|
|
|
285
544
|
direction: {
|
|
286
545
|
type: String,
|
|
287
546
|
default: "vertical",
|
|
288
|
-
validator: function(
|
|
289
|
-
return ["vertical", "horizontal"].includes(
|
|
547
|
+
validator: function(t) {
|
|
548
|
+
return ["vertical", "horizontal"].includes(t);
|
|
290
549
|
}
|
|
291
550
|
},
|
|
292
551
|
listTag: {
|
|
@@ -298,33 +557,33 @@ var an = {
|
|
|
298
557
|
default: "div"
|
|
299
558
|
}
|
|
300
559
|
};
|
|
301
|
-
function
|
|
302
|
-
return this.items.length &&
|
|
560
|
+
function mr() {
|
|
561
|
+
return this.items.length && xt(this.items[0]) !== "object";
|
|
303
562
|
}
|
|
304
|
-
var
|
|
563
|
+
var $t = !1;
|
|
305
564
|
if (typeof window < "u") {
|
|
306
|
-
|
|
565
|
+
$t = !1;
|
|
307
566
|
try {
|
|
308
|
-
var
|
|
567
|
+
var gr = Object.defineProperty({}, "passive", {
|
|
309
568
|
get: function() {
|
|
310
|
-
|
|
569
|
+
$t = !0;
|
|
311
570
|
}
|
|
312
571
|
});
|
|
313
|
-
window.addEventListener("test", null,
|
|
572
|
+
window.addEventListener("test", null, gr);
|
|
314
573
|
} catch {
|
|
315
574
|
}
|
|
316
575
|
}
|
|
317
|
-
let
|
|
318
|
-
var
|
|
576
|
+
let vr = 0;
|
|
577
|
+
var Ht = {
|
|
319
578
|
name: "RecycleScroller",
|
|
320
579
|
components: {
|
|
321
|
-
ResizeObserver:
|
|
580
|
+
ResizeObserver: ft
|
|
322
581
|
},
|
|
323
582
|
directives: {
|
|
324
|
-
ObserveVisibility:
|
|
583
|
+
ObserveVisibility: ur
|
|
325
584
|
},
|
|
326
585
|
props: {
|
|
327
|
-
...
|
|
586
|
+
...pr,
|
|
328
587
|
itemSize: {
|
|
329
588
|
type: Number,
|
|
330
589
|
default: null
|
|
@@ -409,22 +668,22 @@ var Pt = {
|
|
|
409
668
|
computed: {
|
|
410
669
|
sizes() {
|
|
411
670
|
if (this.itemSize === null) {
|
|
412
|
-
const
|
|
671
|
+
const e = {
|
|
413
672
|
"-1": { accumulator: 0 }
|
|
414
|
-
},
|
|
673
|
+
}, t = this.items, n = this.sizeField, i = this.minItemSize;
|
|
415
674
|
let r = 1e4, o = 0, l;
|
|
416
|
-
for (let s = 0, a =
|
|
417
|
-
l =
|
|
418
|
-
return this.$_computedMinItemSize = r,
|
|
675
|
+
for (let s = 0, a = t.length; s < a; s++)
|
|
676
|
+
l = t[s][n] || i, l < r && (r = l), o += l, e[s] = { accumulator: o, size: l };
|
|
677
|
+
return this.$_computedMinItemSize = r, e;
|
|
419
678
|
}
|
|
420
679
|
return [];
|
|
421
680
|
},
|
|
422
|
-
simpleArray:
|
|
681
|
+
simpleArray: mr,
|
|
423
682
|
itemIndexByKey() {
|
|
424
|
-
const { keyField:
|
|
425
|
-
for (let
|
|
426
|
-
|
|
427
|
-
return
|
|
683
|
+
const { keyField: e, items: t } = this, n = {};
|
|
684
|
+
for (let i = 0, r = t.length; i < r; i++)
|
|
685
|
+
n[t[i][e]] = i;
|
|
686
|
+
return n;
|
|
428
687
|
}
|
|
429
688
|
},
|
|
430
689
|
watch: {
|
|
@@ -456,236 +715,236 @@ var Pt = {
|
|
|
456
715
|
});
|
|
457
716
|
},
|
|
458
717
|
activated() {
|
|
459
|
-
const
|
|
460
|
-
typeof
|
|
461
|
-
this.scrollToPosition(
|
|
718
|
+
const e = this.$_lastUpdateScrollPosition;
|
|
719
|
+
typeof e == "number" && this.$nextTick(() => {
|
|
720
|
+
this.scrollToPosition(e);
|
|
462
721
|
});
|
|
463
722
|
},
|
|
464
723
|
beforeUnmount() {
|
|
465
724
|
this.removeListeners();
|
|
466
725
|
},
|
|
467
726
|
methods: {
|
|
468
|
-
addView(t,
|
|
469
|
-
const o =
|
|
470
|
-
id:
|
|
471
|
-
index:
|
|
727
|
+
addView(e, t, n, i, r) {
|
|
728
|
+
const o = Wn({
|
|
729
|
+
id: vr++,
|
|
730
|
+
index: t,
|
|
472
731
|
used: !0,
|
|
473
|
-
key:
|
|
732
|
+
key: i,
|
|
474
733
|
type: r
|
|
475
|
-
}), l =
|
|
476
|
-
item:
|
|
734
|
+
}), l = Xn({
|
|
735
|
+
item: n,
|
|
477
736
|
position: 0,
|
|
478
737
|
nr: o
|
|
479
738
|
});
|
|
480
|
-
return
|
|
739
|
+
return e.push(l), l;
|
|
481
740
|
},
|
|
482
|
-
unuseView(
|
|
483
|
-
const
|
|
484
|
-
let r =
|
|
485
|
-
r || (r = [],
|
|
741
|
+
unuseView(e, t = !1) {
|
|
742
|
+
const n = this.$_unusedViews, i = e.nr.type;
|
|
743
|
+
let r = n.get(i);
|
|
744
|
+
r || (r = [], n.set(i, r)), r.push(e), t || (e.nr.used = !1, e.position = -9999);
|
|
486
745
|
},
|
|
487
746
|
handleResize() {
|
|
488
747
|
this.$emit("resize"), this.ready && this.updateVisibleItems(!1);
|
|
489
748
|
},
|
|
490
|
-
handleScroll(
|
|
749
|
+
handleScroll(e) {
|
|
491
750
|
if (!this.$_scrollDirty) {
|
|
492
751
|
if (this.$_scrollDirty = !0, this.$_updateTimeout) return;
|
|
493
|
-
const
|
|
752
|
+
const t = () => requestAnimationFrame(() => {
|
|
494
753
|
this.$_scrollDirty = !1;
|
|
495
|
-
const { continuous:
|
|
496
|
-
|
|
754
|
+
const { continuous: n } = this.updateVisibleItems(!1, !0);
|
|
755
|
+
n || (clearTimeout(this.$_refreshTimout), this.$_refreshTimout = setTimeout(this.handleScroll, this.updateInterval + 100));
|
|
497
756
|
});
|
|
498
|
-
|
|
499
|
-
this.$_updateTimeout = 0, this.$_scrollDirty &&
|
|
757
|
+
t(), this.updateInterval && (this.$_updateTimeout = setTimeout(() => {
|
|
758
|
+
this.$_updateTimeout = 0, this.$_scrollDirty && t();
|
|
500
759
|
}, this.updateInterval));
|
|
501
760
|
}
|
|
502
761
|
},
|
|
503
|
-
handleVisibilityChange(
|
|
504
|
-
this.ready && (
|
|
762
|
+
handleVisibilityChange(e, t) {
|
|
763
|
+
this.ready && (e || t.boundingClientRect.width !== 0 || t.boundingClientRect.height !== 0 ? (this.$emit("visible"), requestAnimationFrame(() => {
|
|
505
764
|
this.updateVisibleItems(!1);
|
|
506
765
|
})) : this.$emit("hidden"));
|
|
507
766
|
},
|
|
508
|
-
updateVisibleItems(
|
|
509
|
-
const
|
|
510
|
-
let p,
|
|
767
|
+
updateVisibleItems(e, t = !1) {
|
|
768
|
+
const n = this.itemSize, i = this.gridItems || 1, r = this.itemSecondarySize || n, o = this.$_computedMinItemSize, l = this.typeField, s = this.simpleArray ? null : this.keyField, a = this.items, u = a.length, c = this.sizes, d = this.$_views, m = this.$_unusedViews, y = this.pool, S = this.itemIndexByKey;
|
|
769
|
+
let p, f, T, D, w;
|
|
511
770
|
if (!u)
|
|
512
|
-
p =
|
|
771
|
+
p = f = D = w = T = 0;
|
|
513
772
|
else if (this.$_prerender)
|
|
514
|
-
p =
|
|
773
|
+
p = D = 0, f = w = Math.min(this.prerender, a.length), T = null;
|
|
515
774
|
else {
|
|
516
|
-
const
|
|
517
|
-
if (
|
|
518
|
-
let
|
|
519
|
-
if (
|
|
775
|
+
const _ = this.getScroll();
|
|
776
|
+
if (t) {
|
|
777
|
+
let N = _.start - this.$_lastUpdateScrollPosition;
|
|
778
|
+
if (N < 0 && (N = -N), n === null && N < o || N < n)
|
|
520
779
|
return {
|
|
521
780
|
continuous: !0
|
|
522
781
|
};
|
|
523
782
|
}
|
|
524
|
-
this.$_lastUpdateScrollPosition =
|
|
525
|
-
const
|
|
526
|
-
|
|
527
|
-
let
|
|
528
|
-
if (this.$refs.before && (
|
|
529
|
-
const
|
|
530
|
-
|
|
783
|
+
this.$_lastUpdateScrollPosition = _.start;
|
|
784
|
+
const V = this.buffer;
|
|
785
|
+
_.start -= V, _.end += V;
|
|
786
|
+
let x = 0;
|
|
787
|
+
if (this.$refs.before && (x = this.$refs.before.scrollHeight, _.start -= x), this.$refs.after) {
|
|
788
|
+
const N = this.$refs.after.scrollHeight;
|
|
789
|
+
_.end += N;
|
|
531
790
|
}
|
|
532
|
-
if (
|
|
533
|
-
let
|
|
791
|
+
if (n === null) {
|
|
792
|
+
let N, K = 0, ce = u - 1, F = ~~(u / 2), me;
|
|
534
793
|
do
|
|
535
|
-
|
|
536
|
-
while (
|
|
537
|
-
for (
|
|
538
|
-
for (
|
|
539
|
-
for (
|
|
794
|
+
me = F, N = c[F].accumulator, N < _.start ? K = F : F < u - 1 && c[F + 1].accumulator > _.start && (ce = F), F = ~~((K + ce) / 2);
|
|
795
|
+
while (F !== me);
|
|
796
|
+
for (F < 0 && (F = 0), p = F, T = c[u - 1].accumulator, f = F; f < u && c[f].accumulator < _.end; f++) ;
|
|
797
|
+
for (f === -1 ? f = a.length - 1 : (f++, f > u && (f = u)), D = p; D < u && x + c[D].accumulator < _.start; D++) ;
|
|
798
|
+
for (w = D; w < u && x + c[w].accumulator < _.end; w++) ;
|
|
540
799
|
} else {
|
|
541
|
-
p = ~~(
|
|
542
|
-
const
|
|
543
|
-
p -=
|
|
800
|
+
p = ~~(_.start / n * i);
|
|
801
|
+
const N = p % i;
|
|
802
|
+
p -= N, f = Math.ceil(_.end / n * i), D = Math.max(0, Math.floor((_.start - x) / n * i)), w = Math.floor((_.end - x) / n * i), p < 0 && (p = 0), f > u && (f = u), D < 0 && (D = 0), w > u && (w = u), T = Math.ceil(u / i) * n;
|
|
544
803
|
}
|
|
545
804
|
}
|
|
546
|
-
|
|
805
|
+
f - p > cr.itemsLimit && this.itemsLimitError(), this.totalSize = T;
|
|
547
806
|
let g;
|
|
548
|
-
const
|
|
549
|
-
if (
|
|
550
|
-
for (let
|
|
551
|
-
g = _
|
|
552
|
-
const
|
|
553
|
-
let
|
|
554
|
-
for (let
|
|
555
|
-
|
|
556
|
-
const
|
|
557
|
-
if (
|
|
558
|
-
throw new Error(`Key is ${
|
|
559
|
-
if (g =
|
|
807
|
+
const B = p <= this.$_endIndex && f >= this.$_startIndex;
|
|
808
|
+
if (B)
|
|
809
|
+
for (let _ = 0, V = y.length; _ < V; _++)
|
|
810
|
+
g = y[_], g.nr.used && (e && (g.nr.index = S[g.item[s]]), (g.nr.index == null || g.nr.index < p || g.nr.index >= f) && this.unuseView(g));
|
|
811
|
+
const I = B ? null : /* @__PURE__ */ new Map();
|
|
812
|
+
let P, L, R;
|
|
813
|
+
for (let _ = p; _ < f; _++) {
|
|
814
|
+
P = a[_];
|
|
815
|
+
const V = s ? P[s] : P;
|
|
816
|
+
if (V == null)
|
|
817
|
+
throw new Error(`Key is ${V} on item (keyField is '${s}')`);
|
|
818
|
+
if (g = d.get(V), !n && !c[_].size) {
|
|
560
819
|
g && this.unuseView(g);
|
|
561
820
|
continue;
|
|
562
821
|
}
|
|
563
|
-
|
|
564
|
-
let
|
|
822
|
+
L = P[l];
|
|
823
|
+
let x = m.get(L), N = !1;
|
|
565
824
|
if (!g)
|
|
566
|
-
|
|
567
|
-
else if (!g.nr.used && (g.nr.used = !0,
|
|
568
|
-
const
|
|
569
|
-
|
|
825
|
+
B ? x && x.length ? g = x.pop() : g = this.addView(y, _, P, V, L) : (R = I.get(L) || 0, (!x || R >= x.length) && (g = this.addView(y, _, P, V, L), this.unuseView(g, !0), x = m.get(L)), g = x[R], I.set(L, R + 1)), d.delete(g.nr.key), g.nr.used = !0, g.nr.index = _, g.nr.key = V, g.nr.type = L, d.set(V, g), N = !0;
|
|
826
|
+
else if (!g.nr.used && (g.nr.used = !0, N = !0, x)) {
|
|
827
|
+
const K = x.indexOf(g);
|
|
828
|
+
K !== -1 && x.splice(K, 1);
|
|
570
829
|
}
|
|
571
|
-
g.item =
|
|
830
|
+
g.item = P, N && (_ === a.length - 1 && this.$emit("scroll-end"), _ === 0 && this.$emit("scroll-start")), n === null ? (g.position = c[_ - 1].accumulator, g.offset = 0) : (g.position = Math.floor(_ / i) * n, g.offset = _ % i * r);
|
|
572
831
|
}
|
|
573
|
-
return this.$_startIndex = p, this.$_endIndex =
|
|
574
|
-
continuous:
|
|
832
|
+
return this.$_startIndex = p, this.$_endIndex = f, this.emitUpdate && this.$emit("update", p, f, D, w), clearTimeout(this.$_sortTimer), this.$_sortTimer = setTimeout(this.sortViews, this.updateInterval + 300), {
|
|
833
|
+
continuous: B
|
|
575
834
|
};
|
|
576
835
|
},
|
|
577
836
|
getListenerTarget() {
|
|
578
|
-
let
|
|
579
|
-
return window.document && (
|
|
837
|
+
let e = tn(this.$el);
|
|
838
|
+
return window.document && (e === window.document.documentElement || e === window.document.body) && (e = window), e;
|
|
580
839
|
},
|
|
581
840
|
getScroll() {
|
|
582
|
-
const { $el:
|
|
583
|
-
let
|
|
841
|
+
const { $el: e, direction: t } = this, n = t === "vertical";
|
|
842
|
+
let i;
|
|
584
843
|
if (this.pageMode) {
|
|
585
|
-
const r =
|
|
586
|
-
let l = -(
|
|
587
|
-
l < 0 && (s += l, l = 0), l + s > o && (s = o - l),
|
|
844
|
+
const r = e.getBoundingClientRect(), o = n ? r.height : r.width;
|
|
845
|
+
let l = -(n ? r.top : r.left), s = n ? window.innerHeight : window.innerWidth;
|
|
846
|
+
l < 0 && (s += l, l = 0), l + s > o && (s = o - l), i = {
|
|
588
847
|
start: l,
|
|
589
848
|
end: l + s
|
|
590
849
|
};
|
|
591
|
-
} else
|
|
592
|
-
start:
|
|
593
|
-
end:
|
|
594
|
-
} :
|
|
595
|
-
start:
|
|
596
|
-
end:
|
|
850
|
+
} else n ? i = {
|
|
851
|
+
start: e.scrollTop,
|
|
852
|
+
end: e.scrollTop + e.clientHeight
|
|
853
|
+
} : i = {
|
|
854
|
+
start: e.scrollLeft,
|
|
855
|
+
end: e.scrollLeft + e.clientWidth
|
|
597
856
|
};
|
|
598
|
-
return
|
|
857
|
+
return i;
|
|
599
858
|
},
|
|
600
859
|
applyPageMode() {
|
|
601
860
|
this.pageMode ? this.addListeners() : this.removeListeners();
|
|
602
861
|
},
|
|
603
862
|
addListeners() {
|
|
604
|
-
this.listenerTarget = this.getListenerTarget(), this.listenerTarget.addEventListener("scroll", this.handleScroll,
|
|
863
|
+
this.listenerTarget = this.getListenerTarget(), this.listenerTarget.addEventListener("scroll", this.handleScroll, $t ? {
|
|
605
864
|
passive: !0
|
|
606
865
|
} : !1), this.listenerTarget.addEventListener("resize", this.handleResize);
|
|
607
866
|
},
|
|
608
867
|
removeListeners() {
|
|
609
868
|
this.listenerTarget && (this.listenerTarget.removeEventListener("scroll", this.handleScroll), this.listenerTarget.removeEventListener("resize", this.handleResize), this.listenerTarget = null);
|
|
610
869
|
},
|
|
611
|
-
scrollToItem(
|
|
612
|
-
let
|
|
613
|
-
const
|
|
614
|
-
this.itemSize === null ?
|
|
870
|
+
scrollToItem(e) {
|
|
871
|
+
let t;
|
|
872
|
+
const n = this.gridItems || 1;
|
|
873
|
+
this.itemSize === null ? t = e > 0 ? this.sizes[e - 1].accumulator : 0 : t = Math.floor(e / n) * this.itemSize, this.scrollToPosition(t);
|
|
615
874
|
},
|
|
616
|
-
scrollToPosition(
|
|
617
|
-
const
|
|
618
|
-
let
|
|
875
|
+
scrollToPosition(e) {
|
|
876
|
+
const t = this.direction === "vertical" ? { scroll: "scrollTop", start: "top" } : { scroll: "scrollLeft", start: "left" };
|
|
877
|
+
let n, i, r;
|
|
619
878
|
if (this.pageMode) {
|
|
620
|
-
const o =
|
|
621
|
-
|
|
879
|
+
const o = tn(this.$el), l = o.tagName === "HTML" ? 0 : o[t.scroll], s = o.getBoundingClientRect(), u = this.$el.getBoundingClientRect()[t.start] - s[t.start];
|
|
880
|
+
n = o, i = t.scroll, r = e + l + u;
|
|
622
881
|
} else
|
|
623
|
-
|
|
624
|
-
i
|
|
882
|
+
n = this.$el, i = t.scroll, r = e;
|
|
883
|
+
n[i] = r;
|
|
625
884
|
},
|
|
626
885
|
itemsLimitError() {
|
|
627
886
|
throw setTimeout(() => {
|
|
628
887
|
}), new Error("Rendered items limit reached");
|
|
629
888
|
},
|
|
630
889
|
sortViews() {
|
|
631
|
-
this.pool.sort((
|
|
890
|
+
this.pool.sort((e, t) => e.nr.index - t.nr.index);
|
|
632
891
|
}
|
|
633
892
|
}
|
|
634
893
|
};
|
|
635
|
-
const
|
|
894
|
+
const br = {
|
|
636
895
|
key: 0,
|
|
637
896
|
ref: "before",
|
|
638
897
|
class: "vue-recycle-scroller__slot"
|
|
639
|
-
},
|
|
898
|
+
}, yr = {
|
|
640
899
|
key: 1,
|
|
641
900
|
ref: "after",
|
|
642
901
|
class: "vue-recycle-scroller__slot"
|
|
643
902
|
};
|
|
644
|
-
function
|
|
645
|
-
const l =
|
|
646
|
-
return
|
|
903
|
+
function wr(e, t, n, i, r, o) {
|
|
904
|
+
const l = Yn("ResizeObserver"), s = Gn("observe-visibility");
|
|
905
|
+
return Ee((z(), X(
|
|
647
906
|
"div",
|
|
648
907
|
{
|
|
649
908
|
class: de(["vue-recycle-scroller", {
|
|
650
909
|
ready: r.ready,
|
|
651
|
-
"page-mode":
|
|
652
|
-
[`direction-${
|
|
910
|
+
"page-mode": n.pageMode,
|
|
911
|
+
[`direction-${e.direction}`]: !0
|
|
653
912
|
}]),
|
|
654
|
-
onScrollPassive:
|
|
913
|
+
onScrollPassive: t[0] || (t[0] = (...a) => o.handleScroll && o.handleScroll(...a))
|
|
655
914
|
},
|
|
656
915
|
[
|
|
657
|
-
|
|
916
|
+
e.$slots.before ? (z(), X(
|
|
658
917
|
"div",
|
|
659
|
-
|
|
918
|
+
br,
|
|
660
919
|
[
|
|
661
|
-
|
|
920
|
+
ye(e.$slots, "before")
|
|
662
921
|
],
|
|
663
922
|
512
|
|
664
923
|
/* NEED_PATCH */
|
|
665
924
|
)) : Q("v-if", !0),
|
|
666
|
-
(
|
|
925
|
+
(z(), le(Yt(n.listTag), {
|
|
667
926
|
ref: "wrapper",
|
|
668
|
-
style:
|
|
669
|
-
class: de(["vue-recycle-scroller__item-wrapper",
|
|
927
|
+
style: fn({ [e.direction === "vertical" ? "minHeight" : "minWidth"]: r.totalSize + "px" }),
|
|
928
|
+
class: de(["vue-recycle-scroller__item-wrapper", n.listClass])
|
|
670
929
|
}, {
|
|
671
|
-
default:
|
|
672
|
-
(
|
|
673
|
-
|
|
930
|
+
default: nt(() => [
|
|
931
|
+
(z(!0), X(
|
|
932
|
+
At,
|
|
674
933
|
null,
|
|
675
|
-
|
|
934
|
+
Nt(r.pool, (a) => (z(), le(Yt(n.itemTag), Un({
|
|
676
935
|
key: a.nr.id,
|
|
677
936
|
style: r.ready ? {
|
|
678
|
-
transform: `translate${
|
|
679
|
-
width:
|
|
680
|
-
height:
|
|
937
|
+
transform: `translate${e.direction === "vertical" ? "Y" : "X"}(${a.position}px) translate${e.direction === "vertical" ? "X" : "Y"}(${a.offset}px)`,
|
|
938
|
+
width: n.gridItems ? `${e.direction === "vertical" && n.itemSecondarySize || n.itemSize}px` : void 0,
|
|
939
|
+
height: n.gridItems ? `${e.direction === "horizontal" && n.itemSecondarySize || n.itemSize}px` : void 0
|
|
681
940
|
} : null,
|
|
682
941
|
class: ["vue-recycle-scroller__item-view", [
|
|
683
|
-
|
|
942
|
+
n.itemClass,
|
|
684
943
|
{
|
|
685
|
-
hover: !
|
|
944
|
+
hover: !n.skipHover && r.hoverKey === a.nr.key
|
|
686
945
|
}
|
|
687
946
|
]]
|
|
688
|
-
},
|
|
947
|
+
}, Kn(n.skipHover ? {} : {
|
|
689
948
|
mouseenter: () => {
|
|
690
949
|
r.hoverKey = a.nr.key;
|
|
691
950
|
},
|
|
@@ -693,8 +952,8 @@ function hn(t, e, i, n, r, o) {
|
|
|
693
952
|
r.hoverKey = null;
|
|
694
953
|
}
|
|
695
954
|
})), {
|
|
696
|
-
default:
|
|
697
|
-
|
|
955
|
+
default: nt(() => [
|
|
956
|
+
ye(e.$slots, "default", {
|
|
698
957
|
item: a.item,
|
|
699
958
|
index: a.nr.index,
|
|
700
959
|
active: a.nr.used
|
|
@@ -706,21 +965,21 @@ function hn(t, e, i, n, r, o) {
|
|
|
706
965
|
128
|
|
707
966
|
/* KEYED_FRAGMENT */
|
|
708
967
|
)),
|
|
709
|
-
|
|
968
|
+
ye(e.$slots, "empty")
|
|
710
969
|
]),
|
|
711
970
|
_: 3
|
|
712
971
|
/* FORWARDED */
|
|
713
972
|
}, 8, ["style", "class"])),
|
|
714
|
-
|
|
973
|
+
e.$slots.after ? (z(), X(
|
|
715
974
|
"div",
|
|
716
|
-
|
|
975
|
+
yr,
|
|
717
976
|
[
|
|
718
|
-
|
|
977
|
+
ye(e.$slots, "after")
|
|
719
978
|
],
|
|
720
979
|
512
|
|
721
980
|
/* NEED_PATCH */
|
|
722
981
|
)) : Q("v-if", !0),
|
|
723
|
-
|
|
982
|
+
qn(l, { onNotify: o.handleResize }, null, 8, ["onNotify"])
|
|
724
983
|
],
|
|
725
984
|
34
|
|
726
985
|
/* CLASS, HYDRATE_EVENTS */
|
|
@@ -728,47 +987,47 @@ function hn(t, e, i, n, r, o) {
|
|
|
728
987
|
[s, o.handleVisibilityChange]
|
|
729
988
|
]);
|
|
730
989
|
}
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
const
|
|
734
|
-
const
|
|
735
|
-
let
|
|
736
|
-
return typeof s.value.disabled == "string" ?
|
|
990
|
+
Ht.render = wr;
|
|
991
|
+
Ht.__file = "src/components/RecycleScroller.vue";
|
|
992
|
+
const Sr = (e, t) => {
|
|
993
|
+
const n = $e(), i = $e(), r = pn(e, "modelValue"), o = e.valueKey, l = it(() => e.selectedNum ? e.selectedNum : `${e.customTitle || Ue("das-select-list-selected").value}${Ue("das-select-list-parentheses-left").value}${r.value.length}${Ue("das-select-list-parentheses-right").value}`), s = it(() => ({ disabled: "disabled", ...e.props })), a = (p) => {
|
|
994
|
+
let f = !1;
|
|
995
|
+
return typeof s.value.disabled == "string" ? f = p[s.value.disabled] : f = s.value.disabled(p) ?? !1, f;
|
|
737
996
|
}, u = (p) => {
|
|
738
|
-
const
|
|
739
|
-
|
|
997
|
+
const f = r.value.filter((T) => T[o] !== p[o]);
|
|
998
|
+
t("item-remove", p), t("update:modelValue", f);
|
|
999
|
+
}, c = () => {
|
|
1000
|
+
const p = r.value.filter((T) => !a(T)), f = r.value.filter((T) => a(T));
|
|
1001
|
+
t("remove-all", p), t("update:modelValue", f);
|
|
740
1002
|
}, d = () => {
|
|
741
|
-
|
|
742
|
-
e("remove-all", p), e("update:modelValue", c);
|
|
743
|
-
}, f = () => {
|
|
744
|
-
t.infiniteScroll && t.infiniteScroll().then((p) => {
|
|
1003
|
+
e.infiniteScroll && e.infiniteScroll().then((p) => {
|
|
745
1004
|
if (p && p.length) {
|
|
746
|
-
let
|
|
747
|
-
|
|
748
|
-
(
|
|
1005
|
+
let f = [];
|
|
1006
|
+
f = p, f = f.filter(
|
|
1007
|
+
(D) => !r.value.map((w) => w[e.valueKey]).includes(D[e.valueKey])
|
|
749
1008
|
);
|
|
750
|
-
const
|
|
751
|
-
|
|
1009
|
+
const T = r.value.concat(f);
|
|
1010
|
+
t("update:modelValue", T);
|
|
752
1011
|
}
|
|
753
1012
|
});
|
|
754
1013
|
};
|
|
755
1014
|
let m = 0;
|
|
756
|
-
const
|
|
757
|
-
var
|
|
758
|
-
const
|
|
759
|
-
m !== 0 && p === 0 &&
|
|
760
|
-
}, S =
|
|
761
|
-
return
|
|
762
|
-
var
|
|
763
|
-
if (
|
|
764
|
-
const p = (
|
|
765
|
-
S.value =
|
|
766
|
-
|
|
1015
|
+
const y = (p) => {
|
|
1016
|
+
var T;
|
|
1017
|
+
const f = ((T = i.value) == null ? void 0 : T.offsetHeight) || 0;
|
|
1018
|
+
m !== 0 && p === 0 && d(), m = p, p !== 0 && p - f < 10 && d();
|
|
1019
|
+
}, S = $e();
|
|
1020
|
+
return hn(() => {
|
|
1021
|
+
var f;
|
|
1022
|
+
if (e.infiniteDisabled) return;
|
|
1023
|
+
const p = (f = i.value) == null ? void 0 : f.querySelector(".selected-group");
|
|
1024
|
+
S.value = ii((T) => {
|
|
1025
|
+
y(T.height);
|
|
767
1026
|
}, p);
|
|
768
|
-
}),
|
|
1027
|
+
}), Jn(() => {
|
|
769
1028
|
var p;
|
|
770
1029
|
(p = S.value) == null || p.disconnect();
|
|
771
|
-
}), { selectListRef:
|
|
1030
|
+
}), { selectListRef: n, $list: i, disabledFlag: a, itemGroups: r, selectedLabel: l, itemRemove: u, removeAll: c, infiniteLoad: d };
|
|
772
1031
|
};
|
|
773
1032
|
/**!
|
|
774
1033
|
* Sortable 1.15.2
|
|
@@ -776,197 +1035,197 @@ const pn = (t, e) => {
|
|
|
776
1035
|
* @author owenm <owen23355@gmail.com>
|
|
777
1036
|
* @license MIT
|
|
778
1037
|
*/
|
|
779
|
-
function
|
|
780
|
-
var
|
|
1038
|
+
function nn(e, t) {
|
|
1039
|
+
var n = Object.keys(e);
|
|
781
1040
|
if (Object.getOwnPropertySymbols) {
|
|
782
|
-
var
|
|
783
|
-
|
|
784
|
-
return Object.getOwnPropertyDescriptor(
|
|
785
|
-
})),
|
|
1041
|
+
var i = Object.getOwnPropertySymbols(e);
|
|
1042
|
+
t && (i = i.filter(function(r) {
|
|
1043
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
1044
|
+
})), n.push.apply(n, i);
|
|
786
1045
|
}
|
|
787
|
-
return
|
|
1046
|
+
return n;
|
|
788
1047
|
}
|
|
789
|
-
function
|
|
790
|
-
for (var
|
|
791
|
-
var
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
795
|
-
Object.defineProperty(
|
|
1048
|
+
function oe(e) {
|
|
1049
|
+
for (var t = 1; t < arguments.length; t++) {
|
|
1050
|
+
var n = arguments[t] != null ? arguments[t] : {};
|
|
1051
|
+
t % 2 ? nn(Object(n), !0).forEach(function(i) {
|
|
1052
|
+
Er(e, i, n[i]);
|
|
1053
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : nn(Object(n)).forEach(function(i) {
|
|
1054
|
+
Object.defineProperty(e, i, Object.getOwnPropertyDescriptor(n, i));
|
|
796
1055
|
});
|
|
797
1056
|
}
|
|
798
|
-
return
|
|
1057
|
+
return e;
|
|
799
1058
|
}
|
|
800
|
-
function
|
|
1059
|
+
function Je(e) {
|
|
801
1060
|
"@babel/helpers - typeof";
|
|
802
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
|
803
|
-
return typeof
|
|
804
|
-
} :
|
|
805
|
-
return
|
|
806
|
-
},
|
|
807
|
-
}
|
|
808
|
-
function
|
|
809
|
-
return
|
|
810
|
-
value:
|
|
1061
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Je = function(t) {
|
|
1062
|
+
return typeof t;
|
|
1063
|
+
} : Je = function(t) {
|
|
1064
|
+
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
1065
|
+
}, Je(e);
|
|
1066
|
+
}
|
|
1067
|
+
function Er(e, t, n) {
|
|
1068
|
+
return t in e ? Object.defineProperty(e, t, {
|
|
1069
|
+
value: n,
|
|
811
1070
|
enumerable: !0,
|
|
812
1071
|
configurable: !0,
|
|
813
1072
|
writable: !0
|
|
814
|
-
}) : t
|
|
815
|
-
}
|
|
816
|
-
function
|
|
817
|
-
return
|
|
818
|
-
for (var
|
|
819
|
-
var
|
|
820
|
-
for (var
|
|
821
|
-
Object.prototype.hasOwnProperty.call(
|
|
1073
|
+
}) : e[t] = n, e;
|
|
1074
|
+
}
|
|
1075
|
+
function se() {
|
|
1076
|
+
return se = Object.assign || function(e) {
|
|
1077
|
+
for (var t = 1; t < arguments.length; t++) {
|
|
1078
|
+
var n = arguments[t];
|
|
1079
|
+
for (var i in n)
|
|
1080
|
+
Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
|
|
822
1081
|
}
|
|
823
|
-
return
|
|
824
|
-
},
|
|
1082
|
+
return e;
|
|
1083
|
+
}, se.apply(this, arguments);
|
|
825
1084
|
}
|
|
826
|
-
function
|
|
827
|
-
if (
|
|
828
|
-
var
|
|
829
|
-
for (o = 0; o <
|
|
830
|
-
r =
|
|
831
|
-
return
|
|
1085
|
+
function _r(e, t) {
|
|
1086
|
+
if (e == null) return {};
|
|
1087
|
+
var n = {}, i = Object.keys(e), r, o;
|
|
1088
|
+
for (o = 0; o < i.length; o++)
|
|
1089
|
+
r = i[o], !(t.indexOf(r) >= 0) && (n[r] = e[r]);
|
|
1090
|
+
return n;
|
|
832
1091
|
}
|
|
833
|
-
function
|
|
834
|
-
if (
|
|
835
|
-
var
|
|
1092
|
+
function Tr(e, t) {
|
|
1093
|
+
if (e == null) return {};
|
|
1094
|
+
var n = _r(e, t), i, r;
|
|
836
1095
|
if (Object.getOwnPropertySymbols) {
|
|
837
|
-
var o = Object.getOwnPropertySymbols(
|
|
1096
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
838
1097
|
for (r = 0; r < o.length; r++)
|
|
839
|
-
|
|
1098
|
+
i = o[r], !(t.indexOf(i) >= 0) && Object.prototype.propertyIsEnumerable.call(e, i) && (n[i] = e[i]);
|
|
840
1099
|
}
|
|
841
|
-
return
|
|
1100
|
+
return n;
|
|
842
1101
|
}
|
|
843
|
-
var
|
|
844
|
-
function
|
|
1102
|
+
var Dr = "1.15.2";
|
|
1103
|
+
function ae(e) {
|
|
845
1104
|
if (typeof window < "u" && window.navigator)
|
|
846
|
-
return !!/* @__PURE__ */ navigator.userAgent.match(
|
|
1105
|
+
return !!/* @__PURE__ */ navigator.userAgent.match(e);
|
|
847
1106
|
}
|
|
848
|
-
var
|
|
1107
|
+
var ue = ae(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), He = ae(/Edge/i), rn = ae(/firefox/i), Me = ae(/safari/i) && !ae(/chrome/i) && !ae(/android/i), En = ae(/iP(ad|od|hone)/i), _n = ae(/chrome/i) && ae(/android/i), Tn = {
|
|
849
1108
|
capture: !1,
|
|
850
1109
|
passive: !1
|
|
851
1110
|
};
|
|
852
|
-
function
|
|
853
|
-
|
|
1111
|
+
function A(e, t, n) {
|
|
1112
|
+
e.addEventListener(t, n, !ue && Tn);
|
|
854
1113
|
}
|
|
855
|
-
function
|
|
856
|
-
|
|
1114
|
+
function C(e, t, n) {
|
|
1115
|
+
e.removeEventListener(t, n, !ue && Tn);
|
|
857
1116
|
}
|
|
858
|
-
function
|
|
859
|
-
if (
|
|
860
|
-
if (
|
|
1117
|
+
function lt(e, t) {
|
|
1118
|
+
if (t) {
|
|
1119
|
+
if (t[0] === ">" && (t = t.substring(1)), e)
|
|
861
1120
|
try {
|
|
862
|
-
if (
|
|
863
|
-
return
|
|
864
|
-
if (
|
|
865
|
-
return
|
|
866
|
-
if (
|
|
867
|
-
return
|
|
1121
|
+
if (e.matches)
|
|
1122
|
+
return e.matches(t);
|
|
1123
|
+
if (e.msMatchesSelector)
|
|
1124
|
+
return e.msMatchesSelector(t);
|
|
1125
|
+
if (e.webkitMatchesSelector)
|
|
1126
|
+
return e.webkitMatchesSelector(t);
|
|
868
1127
|
} catch {
|
|
869
1128
|
return !1;
|
|
870
1129
|
}
|
|
871
1130
|
return !1;
|
|
872
1131
|
}
|
|
873
1132
|
}
|
|
874
|
-
function
|
|
875
|
-
return
|
|
1133
|
+
function Ir(e) {
|
|
1134
|
+
return e.host && e !== document && e.host.nodeType ? e.host : e.parentNode;
|
|
876
1135
|
}
|
|
877
|
-
function
|
|
878
|
-
if (
|
|
879
|
-
|
|
1136
|
+
function ne(e, t, n, i) {
|
|
1137
|
+
if (e) {
|
|
1138
|
+
n = n || document;
|
|
880
1139
|
do {
|
|
881
|
-
if (
|
|
882
|
-
return
|
|
883
|
-
if (
|
|
884
|
-
} while (
|
|
1140
|
+
if (t != null && (t[0] === ">" ? e.parentNode === n && lt(e, t) : lt(e, t)) || i && e === n)
|
|
1141
|
+
return e;
|
|
1142
|
+
if (e === n) break;
|
|
1143
|
+
} while (e = Ir(e));
|
|
885
1144
|
}
|
|
886
1145
|
return null;
|
|
887
1146
|
}
|
|
888
|
-
var
|
|
889
|
-
function q(
|
|
890
|
-
if (
|
|
891
|
-
if (
|
|
892
|
-
|
|
1147
|
+
var on = /\s+/g;
|
|
1148
|
+
function q(e, t, n) {
|
|
1149
|
+
if (e && t)
|
|
1150
|
+
if (e.classList)
|
|
1151
|
+
e.classList[n ? "add" : "remove"](t);
|
|
893
1152
|
else {
|
|
894
|
-
var
|
|
895
|
-
|
|
1153
|
+
var i = (" " + e.className + " ").replace(on, " ").replace(" " + t + " ", " ");
|
|
1154
|
+
e.className = (i + (n ? " " + t : "")).replace(on, " ");
|
|
896
1155
|
}
|
|
897
1156
|
}
|
|
898
|
-
function v(
|
|
899
|
-
var
|
|
900
|
-
if (
|
|
901
|
-
if (
|
|
902
|
-
return document.defaultView && document.defaultView.getComputedStyle ?
|
|
903
|
-
!(
|
|
1157
|
+
function v(e, t, n) {
|
|
1158
|
+
var i = e && e.style;
|
|
1159
|
+
if (i) {
|
|
1160
|
+
if (n === void 0)
|
|
1161
|
+
return document.defaultView && document.defaultView.getComputedStyle ? n = document.defaultView.getComputedStyle(e, "") : e.currentStyle && (n = e.currentStyle), t === void 0 ? n : n[t];
|
|
1162
|
+
!(t in i) && t.indexOf("webkit") === -1 && (t = "-webkit-" + t), i[t] = n + (typeof n == "string" ? "" : "px");
|
|
904
1163
|
}
|
|
905
1164
|
}
|
|
906
|
-
function De(
|
|
907
|
-
var
|
|
908
|
-
if (typeof
|
|
909
|
-
|
|
1165
|
+
function De(e, t) {
|
|
1166
|
+
var n = "";
|
|
1167
|
+
if (typeof e == "string")
|
|
1168
|
+
n = e;
|
|
910
1169
|
else
|
|
911
1170
|
do {
|
|
912
|
-
var
|
|
913
|
-
|
|
914
|
-
} while (!
|
|
1171
|
+
var i = v(e, "transform");
|
|
1172
|
+
i && i !== "none" && (n = i + " " + n);
|
|
1173
|
+
} while (!t && (e = e.parentNode));
|
|
915
1174
|
var r = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;
|
|
916
|
-
return r && new r(
|
|
1175
|
+
return r && new r(n);
|
|
917
1176
|
}
|
|
918
|
-
function
|
|
919
|
-
if (
|
|
920
|
-
var
|
|
921
|
-
if (
|
|
1177
|
+
function Dn(e, t, n) {
|
|
1178
|
+
if (e) {
|
|
1179
|
+
var i = e.getElementsByTagName(t), r = 0, o = i.length;
|
|
1180
|
+
if (n)
|
|
922
1181
|
for (; r < o; r++)
|
|
923
|
-
i
|
|
924
|
-
return
|
|
1182
|
+
n(i[r], r);
|
|
1183
|
+
return i;
|
|
925
1184
|
}
|
|
926
1185
|
return [];
|
|
927
1186
|
}
|
|
928
|
-
function
|
|
929
|
-
var
|
|
930
|
-
return
|
|
1187
|
+
function re() {
|
|
1188
|
+
var e = document.scrollingElement;
|
|
1189
|
+
return e || document.documentElement;
|
|
931
1190
|
}
|
|
932
|
-
function
|
|
933
|
-
if (!(!
|
|
934
|
-
var o, l, s, a, u,
|
|
935
|
-
if (
|
|
1191
|
+
function j(e, t, n, i, r) {
|
|
1192
|
+
if (!(!e.getBoundingClientRect && e !== window)) {
|
|
1193
|
+
var o, l, s, a, u, c, d;
|
|
1194
|
+
if (e !== window && e.parentNode && e !== re() ? (o = e.getBoundingClientRect(), l = o.top, s = o.left, a = o.bottom, u = o.right, c = o.height, d = o.width) : (l = 0, s = 0, a = window.innerHeight, u = window.innerWidth, c = window.innerHeight, d = window.innerWidth), (t || n) && e !== window && (r = r || e.parentNode, !ue))
|
|
936
1195
|
do
|
|
937
|
-
if (r && r.getBoundingClientRect && (v(r, "transform") !== "none" ||
|
|
1196
|
+
if (r && r.getBoundingClientRect && (v(r, "transform") !== "none" || n && v(r, "position") !== "static")) {
|
|
938
1197
|
var m = r.getBoundingClientRect();
|
|
939
1198
|
l -= m.top + parseInt(v(r, "border-top-width")), s -= m.left + parseInt(v(r, "border-left-width")), a = l + o.height, u = s + o.width;
|
|
940
1199
|
break;
|
|
941
1200
|
}
|
|
942
1201
|
while (r = r.parentNode);
|
|
943
|
-
if (
|
|
944
|
-
var
|
|
945
|
-
|
|
1202
|
+
if (i && e !== window) {
|
|
1203
|
+
var y = De(r || e), S = y && y.a, p = y && y.d;
|
|
1204
|
+
y && (l /= p, s /= S, d /= S, c /= p, a = l + c, u = s + d);
|
|
946
1205
|
}
|
|
947
1206
|
return {
|
|
948
1207
|
top: l,
|
|
949
1208
|
left: s,
|
|
950
1209
|
bottom: a,
|
|
951
1210
|
right: u,
|
|
952
|
-
width:
|
|
953
|
-
height:
|
|
1211
|
+
width: d,
|
|
1212
|
+
height: c
|
|
954
1213
|
};
|
|
955
1214
|
}
|
|
956
1215
|
}
|
|
957
|
-
function
|
|
958
|
-
for (var
|
|
959
|
-
var o =
|
|
960
|
-
if (l = r >= o, !l) return
|
|
961
|
-
if (
|
|
962
|
-
|
|
1216
|
+
function ln(e, t, n) {
|
|
1217
|
+
for (var i = pe(e, !0), r = j(e)[t]; i; ) {
|
|
1218
|
+
var o = j(i)[n], l = void 0;
|
|
1219
|
+
if (l = r >= o, !l) return i;
|
|
1220
|
+
if (i === re()) break;
|
|
1221
|
+
i = pe(i, !1);
|
|
963
1222
|
}
|
|
964
1223
|
return !1;
|
|
965
1224
|
}
|
|
966
|
-
function
|
|
967
|
-
for (var r = 0, o = 0, l =
|
|
968
|
-
if (l[o].style.display !== "none" && l[o] !== b.ghost && (
|
|
969
|
-
if (r ===
|
|
1225
|
+
function Oe(e, t, n, i) {
|
|
1226
|
+
for (var r = 0, o = 0, l = e.children; o < l.length; ) {
|
|
1227
|
+
if (l[o].style.display !== "none" && l[o] !== b.ghost && (i || l[o] !== b.dragged) && ne(l[o], n.draggable, e, !1)) {
|
|
1228
|
+
if (r === t)
|
|
970
1229
|
return l[o];
|
|
971
1230
|
r++;
|
|
972
1231
|
}
|
|
@@ -974,105 +1233,105 @@ function Ie(t, e, i, n) {
|
|
|
974
1233
|
}
|
|
975
1234
|
return null;
|
|
976
1235
|
}
|
|
977
|
-
function
|
|
978
|
-
for (var
|
|
979
|
-
|
|
980
|
-
return
|
|
1236
|
+
function jt(e, t) {
|
|
1237
|
+
for (var n = e.lastElementChild; n && (n === b.ghost || v(n, "display") === "none" || t && !lt(n, t)); )
|
|
1238
|
+
n = n.previousElementSibling;
|
|
1239
|
+
return n || null;
|
|
981
1240
|
}
|
|
982
|
-
function ee(
|
|
983
|
-
var
|
|
984
|
-
if (!
|
|
1241
|
+
function ee(e, t) {
|
|
1242
|
+
var n = 0;
|
|
1243
|
+
if (!e || !e.parentNode)
|
|
985
1244
|
return -1;
|
|
986
|
-
for (;
|
|
987
|
-
|
|
988
|
-
return
|
|
1245
|
+
for (; e = e.previousElementSibling; )
|
|
1246
|
+
e.nodeName.toUpperCase() !== "TEMPLATE" && e !== b.clone && (!t || lt(e, t)) && n++;
|
|
1247
|
+
return n;
|
|
989
1248
|
}
|
|
990
|
-
function
|
|
991
|
-
var
|
|
992
|
-
if (
|
|
1249
|
+
function an(e) {
|
|
1250
|
+
var t = 0, n = 0, i = re();
|
|
1251
|
+
if (e)
|
|
993
1252
|
do {
|
|
994
|
-
var r = De(
|
|
995
|
-
|
|
996
|
-
} while (
|
|
997
|
-
return [
|
|
998
|
-
}
|
|
999
|
-
function
|
|
1000
|
-
for (var
|
|
1001
|
-
if (
|
|
1002
|
-
for (var
|
|
1003
|
-
if (
|
|
1253
|
+
var r = De(e), o = r.a, l = r.d;
|
|
1254
|
+
t += e.scrollLeft * o, n += e.scrollTop * l;
|
|
1255
|
+
} while (e !== i && (e = e.parentNode));
|
|
1256
|
+
return [t, n];
|
|
1257
|
+
}
|
|
1258
|
+
function Or(e, t) {
|
|
1259
|
+
for (var n in e)
|
|
1260
|
+
if (e.hasOwnProperty(n)) {
|
|
1261
|
+
for (var i in t)
|
|
1262
|
+
if (t.hasOwnProperty(i) && t[i] === e[n][i]) return Number(n);
|
|
1004
1263
|
}
|
|
1005
1264
|
return -1;
|
|
1006
1265
|
}
|
|
1007
|
-
function
|
|
1008
|
-
if (!
|
|
1009
|
-
var
|
|
1266
|
+
function pe(e, t) {
|
|
1267
|
+
if (!e || !e.getBoundingClientRect) return re();
|
|
1268
|
+
var n = e, i = !1;
|
|
1010
1269
|
do
|
|
1011
|
-
if (
|
|
1012
|
-
var r = v(
|
|
1013
|
-
if (
|
|
1014
|
-
if (!
|
|
1015
|
-
if (
|
|
1016
|
-
|
|
1270
|
+
if (n.clientWidth < n.scrollWidth || n.clientHeight < n.scrollHeight) {
|
|
1271
|
+
var r = v(n);
|
|
1272
|
+
if (n.clientWidth < n.scrollWidth && (r.overflowX == "auto" || r.overflowX == "scroll") || n.clientHeight < n.scrollHeight && (r.overflowY == "auto" || r.overflowY == "scroll")) {
|
|
1273
|
+
if (!n.getBoundingClientRect || n === document.body) return re();
|
|
1274
|
+
if (i || t) return n;
|
|
1275
|
+
i = !0;
|
|
1017
1276
|
}
|
|
1018
1277
|
}
|
|
1019
|
-
while (
|
|
1020
|
-
return
|
|
1278
|
+
while (n = n.parentNode);
|
|
1279
|
+
return re();
|
|
1021
1280
|
}
|
|
1022
|
-
function
|
|
1023
|
-
if (
|
|
1024
|
-
for (var
|
|
1025
|
-
|
|
1026
|
-
return
|
|
1281
|
+
function Cr(e, t) {
|
|
1282
|
+
if (e && t)
|
|
1283
|
+
for (var n in t)
|
|
1284
|
+
t.hasOwnProperty(n) && (e[n] = t[n]);
|
|
1285
|
+
return e;
|
|
1027
1286
|
}
|
|
1028
|
-
function
|
|
1029
|
-
return Math.round(
|
|
1287
|
+
function wt(e, t) {
|
|
1288
|
+
return Math.round(e.top) === Math.round(t.top) && Math.round(e.left) === Math.round(t.left) && Math.round(e.height) === Math.round(t.height) && Math.round(e.width) === Math.round(t.width);
|
|
1030
1289
|
}
|
|
1031
|
-
var
|
|
1032
|
-
function
|
|
1290
|
+
var Re;
|
|
1291
|
+
function In(e, t) {
|
|
1033
1292
|
return function() {
|
|
1034
|
-
if (!
|
|
1035
|
-
var
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
},
|
|
1293
|
+
if (!Re) {
|
|
1294
|
+
var n = arguments, i = this;
|
|
1295
|
+
n.length === 1 ? e.call(i, n[0]) : e.apply(i, n), Re = setTimeout(function() {
|
|
1296
|
+
Re = void 0;
|
|
1297
|
+
}, t);
|
|
1039
1298
|
}
|
|
1040
1299
|
};
|
|
1041
1300
|
}
|
|
1042
|
-
function
|
|
1043
|
-
clearTimeout(
|
|
1301
|
+
function Ar() {
|
|
1302
|
+
clearTimeout(Re), Re = void 0;
|
|
1044
1303
|
}
|
|
1045
|
-
function
|
|
1046
|
-
|
|
1304
|
+
function On(e, t, n) {
|
|
1305
|
+
e.scrollLeft += t, e.scrollTop += n;
|
|
1047
1306
|
}
|
|
1048
|
-
function
|
|
1049
|
-
var
|
|
1050
|
-
return
|
|
1307
|
+
function Cn(e) {
|
|
1308
|
+
var t = window.Polymer, n = window.jQuery || window.Zepto;
|
|
1309
|
+
return t && t.dom ? t.dom(e).cloneNode(!0) : n ? n(e).clone(!0)[0] : e.cloneNode(!0);
|
|
1051
1310
|
}
|
|
1052
|
-
function
|
|
1053
|
-
var
|
|
1054
|
-
return Array.from(
|
|
1311
|
+
function An(e, t, n) {
|
|
1312
|
+
var i = {};
|
|
1313
|
+
return Array.from(e.children).forEach(function(r) {
|
|
1055
1314
|
var o, l, s, a;
|
|
1056
|
-
if (!(!
|
|
1057
|
-
var u =
|
|
1058
|
-
|
|
1315
|
+
if (!(!ne(r, t.draggable, e, !1) || r.animated || r === n)) {
|
|
1316
|
+
var u = j(r);
|
|
1317
|
+
i.left = Math.min((o = i.left) !== null && o !== void 0 ? o : 1 / 0, u.left), i.top = Math.min((l = i.top) !== null && l !== void 0 ? l : 1 / 0, u.top), i.right = Math.max((s = i.right) !== null && s !== void 0 ? s : -1 / 0, u.right), i.bottom = Math.max((a = i.bottom) !== null && a !== void 0 ? a : -1 / 0, u.bottom);
|
|
1059
1318
|
}
|
|
1060
|
-
}),
|
|
1319
|
+
}), i.width = i.right - i.left, i.height = i.bottom - i.top, i.x = i.left, i.y = i.top, i;
|
|
1061
1320
|
}
|
|
1062
1321
|
var Z = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
|
|
1063
|
-
function
|
|
1064
|
-
var
|
|
1322
|
+
function Nr() {
|
|
1323
|
+
var e = [], t;
|
|
1065
1324
|
return {
|
|
1066
1325
|
captureAnimationState: function() {
|
|
1067
|
-
if (
|
|
1068
|
-
var
|
|
1069
|
-
|
|
1326
|
+
if (e = [], !!this.options.animation) {
|
|
1327
|
+
var i = [].slice.call(this.el.children);
|
|
1328
|
+
i.forEach(function(r) {
|
|
1070
1329
|
if (!(v(r, "display") === "none" || r === b.ghost)) {
|
|
1071
|
-
|
|
1330
|
+
e.push({
|
|
1072
1331
|
target: r,
|
|
1073
|
-
rect:
|
|
1332
|
+
rect: j(r)
|
|
1074
1333
|
});
|
|
1075
|
-
var o =
|
|
1334
|
+
var o = oe({}, e[e.length - 1].rect);
|
|
1076
1335
|
if (r.thisAnimationDuration) {
|
|
1077
1336
|
var l = De(r, !0);
|
|
1078
1337
|
l && (o.top -= l.f, o.left -= l.e);
|
|
@@ -1082,247 +1341,247 @@ function En() {
|
|
|
1082
1341
|
});
|
|
1083
1342
|
}
|
|
1084
1343
|
},
|
|
1085
|
-
addAnimationState: function(
|
|
1086
|
-
|
|
1344
|
+
addAnimationState: function(i) {
|
|
1345
|
+
e.push(i);
|
|
1087
1346
|
},
|
|
1088
|
-
removeAnimationState: function(
|
|
1089
|
-
|
|
1090
|
-
target:
|
|
1347
|
+
removeAnimationState: function(i) {
|
|
1348
|
+
e.splice(Or(e, {
|
|
1349
|
+
target: i
|
|
1091
1350
|
}), 1);
|
|
1092
1351
|
},
|
|
1093
|
-
animateAll: function(
|
|
1352
|
+
animateAll: function(i) {
|
|
1094
1353
|
var r = this;
|
|
1095
1354
|
if (!this.options.animation) {
|
|
1096
|
-
clearTimeout(
|
|
1355
|
+
clearTimeout(t), typeof i == "function" && i();
|
|
1097
1356
|
return;
|
|
1098
1357
|
}
|
|
1099
1358
|
var o = !1, l = 0;
|
|
1100
|
-
|
|
1101
|
-
var a = 0, u = s.target,
|
|
1102
|
-
p && (
|
|
1103
|
-
(S.top -
|
|
1359
|
+
e.forEach(function(s) {
|
|
1360
|
+
var a = 0, u = s.target, c = u.fromRect, d = j(u), m = u.prevFromRect, y = u.prevToRect, S = s.rect, p = De(u, !0);
|
|
1361
|
+
p && (d.top -= p.f, d.left -= p.e), u.toRect = d, u.thisAnimationDuration && wt(m, d) && !wt(c, d) && // Make sure animatingRect is on line between toRect & fromRect
|
|
1362
|
+
(S.top - d.top) / (S.left - d.left) === (c.top - d.top) / (c.left - d.left) && (a = Pr(S, m, y, r.options)), wt(d, c) || (u.prevFromRect = c, u.prevToRect = d, a || (a = r.options.animation), r.animate(u, S, d, a)), a && (o = !0, l = Math.max(l, a), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
|
|
1104
1363
|
u.animationTime = 0, u.prevFromRect = null, u.fromRect = null, u.prevToRect = null, u.thisAnimationDuration = null;
|
|
1105
1364
|
}, a), u.thisAnimationDuration = a);
|
|
1106
|
-
}), clearTimeout(
|
|
1107
|
-
typeof
|
|
1108
|
-
}, l) : typeof
|
|
1365
|
+
}), clearTimeout(t), o ? t = setTimeout(function() {
|
|
1366
|
+
typeof i == "function" && i();
|
|
1367
|
+
}, l) : typeof i == "function" && i(), e = [];
|
|
1109
1368
|
},
|
|
1110
|
-
animate: function(
|
|
1369
|
+
animate: function(i, r, o, l) {
|
|
1111
1370
|
if (l) {
|
|
1112
|
-
v(
|
|
1113
|
-
var s = De(this.el), a = s && s.a, u = s && s.d,
|
|
1114
|
-
|
|
1115
|
-
v(
|
|
1371
|
+
v(i, "transition", ""), v(i, "transform", "");
|
|
1372
|
+
var s = De(this.el), a = s && s.a, u = s && s.d, c = (r.left - o.left) / (a || 1), d = (r.top - o.top) / (u || 1);
|
|
1373
|
+
i.animatingX = !!c, i.animatingY = !!d, v(i, "transform", "translate3d(" + c + "px," + d + "px,0)"), this.forRepaintDummy = zr(i), v(i, "transition", "transform " + l + "ms" + (this.options.easing ? " " + this.options.easing : "")), v(i, "transform", "translate3d(0,0,0)"), typeof i.animated == "number" && clearTimeout(i.animated), i.animated = setTimeout(function() {
|
|
1374
|
+
v(i, "transition", ""), v(i, "transform", ""), i.animated = !1, i.animatingX = !1, i.animatingY = !1;
|
|
1116
1375
|
}, l);
|
|
1117
1376
|
}
|
|
1118
1377
|
}
|
|
1119
1378
|
};
|
|
1120
1379
|
}
|
|
1121
|
-
function
|
|
1122
|
-
return
|
|
1380
|
+
function zr(e) {
|
|
1381
|
+
return e.offsetWidth;
|
|
1123
1382
|
}
|
|
1124
|
-
function
|
|
1125
|
-
return Math.sqrt(Math.pow(
|
|
1383
|
+
function Pr(e, t, n, i) {
|
|
1384
|
+
return Math.sqrt(Math.pow(t.top - e.top, 2) + Math.pow(t.left - e.left, 2)) / Math.sqrt(Math.pow(t.top - n.top, 2) + Math.pow(t.left - n.left, 2)) * i.animation;
|
|
1126
1385
|
}
|
|
1127
|
-
var
|
|
1386
|
+
var we = [], St = {
|
|
1128
1387
|
initializeByDefault: !0
|
|
1129
|
-
},
|
|
1130
|
-
mount: function(
|
|
1131
|
-
for (var
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
if (
|
|
1135
|
-
throw "Sortable: Cannot mount plugin ".concat(
|
|
1136
|
-
}),
|
|
1388
|
+
}, je = {
|
|
1389
|
+
mount: function(t) {
|
|
1390
|
+
for (var n in St)
|
|
1391
|
+
St.hasOwnProperty(n) && !(n in t) && (t[n] = St[n]);
|
|
1392
|
+
we.forEach(function(i) {
|
|
1393
|
+
if (i.pluginName === t.pluginName)
|
|
1394
|
+
throw "Sortable: Cannot mount plugin ".concat(t.pluginName, " more than once");
|
|
1395
|
+
}), we.push(t);
|
|
1137
1396
|
},
|
|
1138
|
-
pluginEvent: function(
|
|
1397
|
+
pluginEvent: function(t, n, i) {
|
|
1139
1398
|
var r = this;
|
|
1140
|
-
this.eventCanceled = !1,
|
|
1399
|
+
this.eventCanceled = !1, i.cancel = function() {
|
|
1141
1400
|
r.eventCanceled = !0;
|
|
1142
1401
|
};
|
|
1143
|
-
var o =
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
sortable:
|
|
1147
|
-
},
|
|
1148
|
-
sortable:
|
|
1149
|
-
},
|
|
1402
|
+
var o = t + "Global";
|
|
1403
|
+
we.forEach(function(l) {
|
|
1404
|
+
n[l.pluginName] && (n[l.pluginName][o] && n[l.pluginName][o](oe({
|
|
1405
|
+
sortable: n
|
|
1406
|
+
}, i)), n.options[l.pluginName] && n[l.pluginName][t] && n[l.pluginName][t](oe({
|
|
1407
|
+
sortable: n
|
|
1408
|
+
}, i)));
|
|
1150
1409
|
});
|
|
1151
1410
|
},
|
|
1152
|
-
initializePlugins: function(
|
|
1153
|
-
|
|
1411
|
+
initializePlugins: function(t, n, i, r) {
|
|
1412
|
+
we.forEach(function(s) {
|
|
1154
1413
|
var a = s.pluginName;
|
|
1155
|
-
if (!(!
|
|
1156
|
-
var u = new s(
|
|
1157
|
-
u.sortable =
|
|
1414
|
+
if (!(!t.options[a] && !s.initializeByDefault)) {
|
|
1415
|
+
var u = new s(t, n, t.options);
|
|
1416
|
+
u.sortable = t, u.options = t.options, t[a] = u, se(i, u.defaults);
|
|
1158
1417
|
}
|
|
1159
1418
|
});
|
|
1160
|
-
for (var o in
|
|
1161
|
-
if (
|
|
1162
|
-
var l = this.modifyOption(
|
|
1163
|
-
typeof l < "u" && (
|
|
1419
|
+
for (var o in t.options)
|
|
1420
|
+
if (t.options.hasOwnProperty(o)) {
|
|
1421
|
+
var l = this.modifyOption(t, o, t.options[o]);
|
|
1422
|
+
typeof l < "u" && (t.options[o] = l);
|
|
1164
1423
|
}
|
|
1165
1424
|
},
|
|
1166
|
-
getEventProperties: function(
|
|
1167
|
-
var
|
|
1168
|
-
return
|
|
1169
|
-
typeof r.eventProperties == "function" &&
|
|
1170
|
-
}),
|
|
1425
|
+
getEventProperties: function(t, n) {
|
|
1426
|
+
var i = {};
|
|
1427
|
+
return we.forEach(function(r) {
|
|
1428
|
+
typeof r.eventProperties == "function" && se(i, r.eventProperties.call(n[r.pluginName], t));
|
|
1429
|
+
}), i;
|
|
1171
1430
|
},
|
|
1172
|
-
modifyOption: function(
|
|
1431
|
+
modifyOption: function(t, n, i) {
|
|
1173
1432
|
var r;
|
|
1174
|
-
return
|
|
1175
|
-
|
|
1433
|
+
return we.forEach(function(o) {
|
|
1434
|
+
t[o.pluginName] && o.optionListeners && typeof o.optionListeners[n] == "function" && (r = o.optionListeners[n].call(t[o.pluginName], i));
|
|
1176
1435
|
}), r;
|
|
1177
1436
|
}
|
|
1178
1437
|
};
|
|
1179
|
-
function
|
|
1180
|
-
var
|
|
1181
|
-
if (
|
|
1182
|
-
var p,
|
|
1183
|
-
window.CustomEvent && !
|
|
1438
|
+
function kr(e) {
|
|
1439
|
+
var t = e.sortable, n = e.rootEl, i = e.name, r = e.targetEl, o = e.cloneEl, l = e.toEl, s = e.fromEl, a = e.oldIndex, u = e.newIndex, c = e.oldDraggableIndex, d = e.newDraggableIndex, m = e.originalEvent, y = e.putSortable, S = e.extraEventProperties;
|
|
1440
|
+
if (t = t || n && n[Z], !!t) {
|
|
1441
|
+
var p, f = t.options, T = "on" + i.charAt(0).toUpperCase() + i.substr(1);
|
|
1442
|
+
window.CustomEvent && !ue && !He ? p = new CustomEvent(i, {
|
|
1184
1443
|
bubbles: !0,
|
|
1185
1444
|
cancelable: !0
|
|
1186
|
-
}) : (p = document.createEvent("Event"), p.initEvent(
|
|
1187
|
-
var
|
|
1188
|
-
for (var
|
|
1189
|
-
p[
|
|
1190
|
-
|
|
1445
|
+
}) : (p = document.createEvent("Event"), p.initEvent(i, !0, !0)), p.to = l || n, p.from = s || n, p.item = r || n, p.clone = o, p.oldIndex = a, p.newIndex = u, p.oldDraggableIndex = c, p.newDraggableIndex = d, p.originalEvent = m, p.pullMode = y ? y.lastPutMode : void 0;
|
|
1446
|
+
var D = oe(oe({}, S), je.getEventProperties(i, t));
|
|
1447
|
+
for (var w in D)
|
|
1448
|
+
p[w] = D[w];
|
|
1449
|
+
n && n.dispatchEvent(p), f[T] && f[T].call(t, p);
|
|
1191
1450
|
}
|
|
1192
1451
|
}
|
|
1193
|
-
var
|
|
1194
|
-
var
|
|
1195
|
-
|
|
1452
|
+
var xr = ["evt"], U = function(t, n) {
|
|
1453
|
+
var i = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, r = i.evt, o = Tr(i, xr);
|
|
1454
|
+
je.pluginEvent.bind(b)(t, n, oe({
|
|
1196
1455
|
dragEl: h,
|
|
1197
|
-
parentEl:
|
|
1198
|
-
ghostEl:
|
|
1199
|
-
rootEl:
|
|
1200
|
-
nextEl:
|
|
1201
|
-
lastDownEl:
|
|
1202
|
-
cloneEl:
|
|
1203
|
-
cloneHidden:
|
|
1204
|
-
dragStarted:
|
|
1205
|
-
putSortable:
|
|
1456
|
+
parentEl: M,
|
|
1457
|
+
ghostEl: E,
|
|
1458
|
+
rootEl: k,
|
|
1459
|
+
nextEl: be,
|
|
1460
|
+
lastDownEl: Ze,
|
|
1461
|
+
cloneEl: $,
|
|
1462
|
+
cloneHidden: he,
|
|
1463
|
+
dragStarted: Pe,
|
|
1464
|
+
putSortable: W,
|
|
1206
1465
|
activeSortable: b.active,
|
|
1207
1466
|
originalEvent: r,
|
|
1208
|
-
oldIndex:
|
|
1209
|
-
oldDraggableIndex:
|
|
1467
|
+
oldIndex: Te,
|
|
1468
|
+
oldDraggableIndex: Ve,
|
|
1210
1469
|
newIndex: J,
|
|
1211
|
-
newDraggableIndex:
|
|
1212
|
-
hideGhostForTarget:
|
|
1213
|
-
unhideGhostForTarget:
|
|
1470
|
+
newDraggableIndex: fe,
|
|
1471
|
+
hideGhostForTarget: kn,
|
|
1472
|
+
unhideGhostForTarget: xn,
|
|
1214
1473
|
cloneNowHidden: function() {
|
|
1215
|
-
|
|
1474
|
+
he = !0;
|
|
1216
1475
|
},
|
|
1217
1476
|
cloneNowShown: function() {
|
|
1218
|
-
|
|
1477
|
+
he = !1;
|
|
1219
1478
|
},
|
|
1220
1479
|
dispatchSortableEvent: function(s) {
|
|
1221
|
-
|
|
1222
|
-
sortable:
|
|
1480
|
+
G({
|
|
1481
|
+
sortable: n,
|
|
1223
1482
|
name: s,
|
|
1224
1483
|
originalEvent: r
|
|
1225
1484
|
});
|
|
1226
1485
|
}
|
|
1227
1486
|
}, o));
|
|
1228
1487
|
};
|
|
1229
|
-
function
|
|
1230
|
-
|
|
1231
|
-
putSortable:
|
|
1232
|
-
cloneEl:
|
|
1488
|
+
function G(e) {
|
|
1489
|
+
kr(oe({
|
|
1490
|
+
putSortable: W,
|
|
1491
|
+
cloneEl: $,
|
|
1233
1492
|
targetEl: h,
|
|
1234
|
-
rootEl:
|
|
1235
|
-
oldIndex:
|
|
1236
|
-
oldDraggableIndex:
|
|
1493
|
+
rootEl: k,
|
|
1494
|
+
oldIndex: Te,
|
|
1495
|
+
oldDraggableIndex: Ve,
|
|
1237
1496
|
newIndex: J,
|
|
1238
|
-
newDraggableIndex:
|
|
1239
|
-
},
|
|
1497
|
+
newDraggableIndex: fe
|
|
1498
|
+
}, e));
|
|
1240
1499
|
}
|
|
1241
|
-
var h,
|
|
1242
|
-
if (
|
|
1243
|
-
if (
|
|
1500
|
+
var h, M, E, k, be, Ze, $, he, Te, J, Ve, fe, We, W, _e = !1, at = !1, st = [], ge, te, Et, _t, sn, un, Pe, Se, Fe, Le = !1, Xe = !1, Qe, Y, Tt = [], Mt = !1, ut = [], ht = typeof document < "u", Ye = En, cn = He || ue ? "cssFloat" : "float", $r = ht && !_n && !En && "draggable" in document.createElement("div"), Nn = function() {
|
|
1501
|
+
if (ht) {
|
|
1502
|
+
if (ue)
|
|
1244
1503
|
return !1;
|
|
1245
|
-
var
|
|
1246
|
-
return
|
|
1504
|
+
var e = document.createElement("x");
|
|
1505
|
+
return e.style.cssText = "pointer-events:auto", e.style.pointerEvents === "auto";
|
|
1247
1506
|
}
|
|
1248
|
-
}(),
|
|
1249
|
-
var
|
|
1250
|
-
if (
|
|
1251
|
-
return
|
|
1252
|
-
if (
|
|
1253
|
-
return
|
|
1507
|
+
}(), zn = function(t, n) {
|
|
1508
|
+
var i = v(t), r = parseInt(i.width) - parseInt(i.paddingLeft) - parseInt(i.paddingRight) - parseInt(i.borderLeftWidth) - parseInt(i.borderRightWidth), o = Oe(t, 0, n), l = Oe(t, 1, n), s = o && v(o), a = l && v(l), u = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + j(o).width, c = a && parseInt(a.marginLeft) + parseInt(a.marginRight) + j(l).width;
|
|
1509
|
+
if (i.display === "flex")
|
|
1510
|
+
return i.flexDirection === "column" || i.flexDirection === "column-reverse" ? "vertical" : "horizontal";
|
|
1511
|
+
if (i.display === "grid")
|
|
1512
|
+
return i.gridTemplateColumns.split(" ").length <= 1 ? "vertical" : "horizontal";
|
|
1254
1513
|
if (o && s.float && s.float !== "none") {
|
|
1255
|
-
var
|
|
1256
|
-
return l && (a.clear === "both" || a.clear ===
|
|
1514
|
+
var d = s.float === "left" ? "left" : "right";
|
|
1515
|
+
return l && (a.clear === "both" || a.clear === d) ? "vertical" : "horizontal";
|
|
1257
1516
|
}
|
|
1258
|
-
return o && (s.display === "block" || s.display === "flex" || s.display === "table" || s.display === "grid" || u >= r &&
|
|
1259
|
-
},
|
|
1260
|
-
var r =
|
|
1517
|
+
return o && (s.display === "block" || s.display === "flex" || s.display === "table" || s.display === "grid" || u >= r && i[cn] === "none" || l && i[cn] === "none" && u + c > r) ? "vertical" : "horizontal";
|
|
1518
|
+
}, Mr = function(t, n, i) {
|
|
1519
|
+
var r = i ? t.left : t.top, o = i ? t.right : t.bottom, l = i ? t.width : t.height, s = i ? n.left : n.top, a = i ? n.right : n.bottom, u = i ? n.width : n.height;
|
|
1261
1520
|
return r === s || o === a || r + l / 2 === s + u / 2;
|
|
1262
|
-
},
|
|
1263
|
-
var
|
|
1264
|
-
return
|
|
1521
|
+
}, Rr = function(t, n) {
|
|
1522
|
+
var i;
|
|
1523
|
+
return st.some(function(r) {
|
|
1265
1524
|
var o = r[Z].options.emptyInsertThreshold;
|
|
1266
|
-
if (!(!o ||
|
|
1267
|
-
var l =
|
|
1525
|
+
if (!(!o || jt(r))) {
|
|
1526
|
+
var l = j(r), s = t >= l.left - o && t <= l.right + o, a = n >= l.top - o && n <= l.bottom + o;
|
|
1268
1527
|
if (s && a)
|
|
1269
|
-
return
|
|
1528
|
+
return i = r;
|
|
1270
1529
|
}
|
|
1271
|
-
}),
|
|
1272
|
-
},
|
|
1273
|
-
function
|
|
1274
|
-
return function(s, a, u,
|
|
1275
|
-
var
|
|
1276
|
-
if (o == null && (l ||
|
|
1530
|
+
}), i;
|
|
1531
|
+
}, Pn = function(t) {
|
|
1532
|
+
function n(o, l) {
|
|
1533
|
+
return function(s, a, u, c) {
|
|
1534
|
+
var d = s.options.group.name && a.options.group.name && s.options.group.name === a.options.group.name;
|
|
1535
|
+
if (o == null && (l || d))
|
|
1277
1536
|
return !0;
|
|
1278
1537
|
if (o == null || o === !1)
|
|
1279
1538
|
return !1;
|
|
1280
1539
|
if (l && o === "clone")
|
|
1281
1540
|
return o;
|
|
1282
1541
|
if (typeof o == "function")
|
|
1283
|
-
return
|
|
1542
|
+
return n(o(s, a, u, c), l)(s, a, u, c);
|
|
1284
1543
|
var m = (l ? s : a).options.group.name;
|
|
1285
1544
|
return o === !0 || typeof o == "string" && o === m || o.join && o.indexOf(m) > -1;
|
|
1286
1545
|
};
|
|
1287
1546
|
}
|
|
1288
|
-
var
|
|
1289
|
-
(!r ||
|
|
1547
|
+
var i = {}, r = t.group;
|
|
1548
|
+
(!r || Je(r) != "object") && (r = {
|
|
1290
1549
|
name: r
|
|
1291
|
-
}),
|
|
1292
|
-
},
|
|
1293
|
-
!
|
|
1294
|
-
},
|
|
1295
|
-
!
|
|
1550
|
+
}), i.name = r.name, i.checkPull = n(r.pull, !0), i.checkPut = n(r.put), i.revertClone = r.revertClone, t.group = i;
|
|
1551
|
+
}, kn = function() {
|
|
1552
|
+
!Nn && E && v(E, "display", "none");
|
|
1553
|
+
}, xn = function() {
|
|
1554
|
+
!Nn && E && v(E, "display", "");
|
|
1296
1555
|
};
|
|
1297
|
-
|
|
1298
|
-
if (
|
|
1299
|
-
return
|
|
1556
|
+
ht && !_n && document.addEventListener("click", function(e) {
|
|
1557
|
+
if (at)
|
|
1558
|
+
return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(), at = !1, !1;
|
|
1300
1559
|
}, !0);
|
|
1301
|
-
var
|
|
1560
|
+
var ve = function(t) {
|
|
1302
1561
|
if (h) {
|
|
1303
|
-
|
|
1304
|
-
var
|
|
1305
|
-
if (
|
|
1306
|
-
var
|
|
1307
|
-
for (var r in
|
|
1308
|
-
|
|
1309
|
-
|
|
1562
|
+
t = t.touches ? t.touches[0] : t;
|
|
1563
|
+
var n = Rr(t.clientX, t.clientY);
|
|
1564
|
+
if (n) {
|
|
1565
|
+
var i = {};
|
|
1566
|
+
for (var r in t)
|
|
1567
|
+
t.hasOwnProperty(r) && (i[r] = t[r]);
|
|
1568
|
+
i.target = i.rootEl = n, i.preventDefault = void 0, i.stopPropagation = void 0, n[Z]._onDragOver(i);
|
|
1310
1569
|
}
|
|
1311
1570
|
}
|
|
1312
|
-
},
|
|
1313
|
-
h && h.parentNode[Z]._isOutsideThisEl(
|
|
1571
|
+
}, Vr = function(t) {
|
|
1572
|
+
h && h.parentNode[Z]._isOutsideThisEl(t.target);
|
|
1314
1573
|
};
|
|
1315
|
-
function b(
|
|
1316
|
-
if (!(
|
|
1317
|
-
throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(
|
|
1318
|
-
this.el =
|
|
1319
|
-
var
|
|
1574
|
+
function b(e, t) {
|
|
1575
|
+
if (!(e && e.nodeType && e.nodeType === 1))
|
|
1576
|
+
throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));
|
|
1577
|
+
this.el = e, this.options = t = se({}, t), e[Z] = this;
|
|
1578
|
+
var n = {
|
|
1320
1579
|
group: null,
|
|
1321
1580
|
sort: !0,
|
|
1322
1581
|
disabled: !1,
|
|
1323
1582
|
store: null,
|
|
1324
1583
|
handle: null,
|
|
1325
|
-
draggable: /^[uo]l$/i.test(
|
|
1584
|
+
draggable: /^[uo]l$/i.test(e.nodeName) ? ">li" : ">*",
|
|
1326
1585
|
swapThreshold: 1,
|
|
1327
1586
|
// percentage; 0 <= x <= 1
|
|
1328
1587
|
invertSwap: !1,
|
|
@@ -1331,7 +1590,7 @@ function b(t, e) {
|
|
|
1331
1590
|
// will be set to same as swapThreshold if default
|
|
1332
1591
|
removeCloneOnHide: !0,
|
|
1333
1592
|
direction: function() {
|
|
1334
|
-
return
|
|
1593
|
+
return zn(e, this.options);
|
|
1335
1594
|
},
|
|
1336
1595
|
ghostClass: "sortable-ghost",
|
|
1337
1596
|
chosenClass: "sortable-chosen",
|
|
@@ -1358,368 +1617,368 @@ function b(t, e) {
|
|
|
1358
1617
|
x: 0,
|
|
1359
1618
|
y: 0
|
|
1360
1619
|
},
|
|
1361
|
-
supportPointer: b.supportPointer !== !1 && "PointerEvent" in window && !
|
|
1620
|
+
supportPointer: b.supportPointer !== !1 && "PointerEvent" in window && !Me,
|
|
1362
1621
|
emptyInsertThreshold: 5
|
|
1363
1622
|
};
|
|
1364
|
-
|
|
1365
|
-
for (var
|
|
1366
|
-
!(
|
|
1367
|
-
|
|
1623
|
+
je.initializePlugins(this, e, n);
|
|
1624
|
+
for (var i in n)
|
|
1625
|
+
!(i in t) && (t[i] = n[i]);
|
|
1626
|
+
Pn(t);
|
|
1368
1627
|
for (var r in this)
|
|
1369
1628
|
r.charAt(0) === "_" && typeof this[r] == "function" && (this[r] = this[r].bind(this));
|
|
1370
|
-
this.nativeDraggable =
|
|
1629
|
+
this.nativeDraggable = t.forceFallback ? !1 : $r, this.nativeDraggable && (this.options.touchStartThreshold = 1), t.supportPointer ? A(e, "pointerdown", this._onTapStart) : (A(e, "mousedown", this._onTapStart), A(e, "touchstart", this._onTapStart)), this.nativeDraggable && (A(e, "dragover", this), A(e, "dragenter", this)), st.push(this.el), t.store && t.store.get && this.sort(t.store.get(this) || []), se(this, Nr());
|
|
1371
1630
|
}
|
|
1372
1631
|
b.prototype = /** @lends Sortable.prototype */
|
|
1373
1632
|
{
|
|
1374
1633
|
constructor: b,
|
|
1375
|
-
_isOutsideThisEl: function(
|
|
1376
|
-
!this.el.contains(
|
|
1634
|
+
_isOutsideThisEl: function(t) {
|
|
1635
|
+
!this.el.contains(t) && t !== this.el && (Se = null);
|
|
1377
1636
|
},
|
|
1378
|
-
_getDirection: function(
|
|
1379
|
-
return typeof this.options.direction == "function" ? this.options.direction.call(this,
|
|
1637
|
+
_getDirection: function(t, n) {
|
|
1638
|
+
return typeof this.options.direction == "function" ? this.options.direction.call(this, t, n, h) : this.options.direction;
|
|
1380
1639
|
},
|
|
1381
|
-
_onTapStart: function(
|
|
1382
|
-
if (
|
|
1383
|
-
var
|
|
1384
|
-
if (
|
|
1385
|
-
if (
|
|
1386
|
-
if (
|
|
1387
|
-
|
|
1388
|
-
sortable:
|
|
1640
|
+
_onTapStart: function(t) {
|
|
1641
|
+
if (t.cancelable) {
|
|
1642
|
+
var n = this, i = this.el, r = this.options, o = r.preventOnFilter, l = t.type, s = t.touches && t.touches[0] || t.pointerType && t.pointerType === "touch" && t, a = (s || t).target, u = t.target.shadowRoot && (t.path && t.path[0] || t.composedPath && t.composedPath()[0]) || a, c = r.filter;
|
|
1643
|
+
if (Yr(i), !h && !(/mousedown|pointerdown/.test(l) && t.button !== 0 || r.disabled) && !u.isContentEditable && !(!this.nativeDraggable && Me && a && a.tagName.toUpperCase() === "SELECT") && (a = ne(a, r.draggable, i, !1), !(a && a.animated) && Ze !== a)) {
|
|
1644
|
+
if (Te = ee(a), Ve = ee(a, r.draggable), typeof c == "function") {
|
|
1645
|
+
if (c.call(this, t, a, this)) {
|
|
1646
|
+
G({
|
|
1647
|
+
sortable: n,
|
|
1389
1648
|
rootEl: u,
|
|
1390
1649
|
name: "filter",
|
|
1391
1650
|
targetEl: a,
|
|
1392
|
-
toEl:
|
|
1393
|
-
fromEl:
|
|
1394
|
-
}),
|
|
1395
|
-
evt:
|
|
1396
|
-
}), o &&
|
|
1651
|
+
toEl: i,
|
|
1652
|
+
fromEl: i
|
|
1653
|
+
}), U("filter", n, {
|
|
1654
|
+
evt: t
|
|
1655
|
+
}), o && t.cancelable && t.preventDefault();
|
|
1397
1656
|
return;
|
|
1398
1657
|
}
|
|
1399
|
-
} else if (
|
|
1400
|
-
if (
|
|
1401
|
-
return
|
|
1402
|
-
sortable:
|
|
1403
|
-
rootEl:
|
|
1658
|
+
} else if (c && (c = c.split(",").some(function(d) {
|
|
1659
|
+
if (d = ne(u, d.trim(), i, !1), d)
|
|
1660
|
+
return G({
|
|
1661
|
+
sortable: n,
|
|
1662
|
+
rootEl: d,
|
|
1404
1663
|
name: "filter",
|
|
1405
1664
|
targetEl: a,
|
|
1406
|
-
fromEl:
|
|
1407
|
-
toEl:
|
|
1408
|
-
}),
|
|
1409
|
-
evt:
|
|
1665
|
+
fromEl: i,
|
|
1666
|
+
toEl: i
|
|
1667
|
+
}), U("filter", n, {
|
|
1668
|
+
evt: t
|
|
1410
1669
|
}), !0;
|
|
1411
|
-
}),
|
|
1412
|
-
o &&
|
|
1670
|
+
}), c)) {
|
|
1671
|
+
o && t.cancelable && t.preventDefault();
|
|
1413
1672
|
return;
|
|
1414
1673
|
}
|
|
1415
|
-
r.handle && !
|
|
1674
|
+
r.handle && !ne(u, r.handle, i, !1) || this._prepareDragStart(t, s, a);
|
|
1416
1675
|
}
|
|
1417
1676
|
}
|
|
1418
1677
|
},
|
|
1419
|
-
_prepareDragStart: function(
|
|
1678
|
+
_prepareDragStart: function(t, n, i) {
|
|
1420
1679
|
var r = this, o = r.el, l = r.options, s = o.ownerDocument, a;
|
|
1421
|
-
if (
|
|
1422
|
-
var u =
|
|
1423
|
-
if (
|
|
1680
|
+
if (i && !h && i.parentNode === o) {
|
|
1681
|
+
var u = j(i);
|
|
1682
|
+
if (k = o, h = i, M = h.parentNode, be = h.nextSibling, Ze = i, We = l.group, b.dragged = h, ge = {
|
|
1424
1683
|
target: h,
|
|
1425
|
-
clientX: (
|
|
1426
|
-
clientY: (
|
|
1427
|
-
},
|
|
1428
|
-
if (
|
|
1429
|
-
evt:
|
|
1684
|
+
clientX: (n || t).clientX,
|
|
1685
|
+
clientY: (n || t).clientY
|
|
1686
|
+
}, sn = ge.clientX - u.left, un = ge.clientY - u.top, this._lastX = (n || t).clientX, this._lastY = (n || t).clientY, h.style["will-change"] = "all", a = function() {
|
|
1687
|
+
if (U("delayEnded", r, {
|
|
1688
|
+
evt: t
|
|
1430
1689
|
}), b.eventCanceled) {
|
|
1431
1690
|
r._onDrop();
|
|
1432
1691
|
return;
|
|
1433
1692
|
}
|
|
1434
|
-
r._disableDelayedDragEvents(), !
|
|
1693
|
+
r._disableDelayedDragEvents(), !rn && r.nativeDraggable && (h.draggable = !0), r._triggerDragStart(t, n), G({
|
|
1435
1694
|
sortable: r,
|
|
1436
1695
|
name: "choose",
|
|
1437
|
-
originalEvent:
|
|
1696
|
+
originalEvent: t
|
|
1438
1697
|
}), q(h, l.chosenClass, !0);
|
|
1439
|
-
}, l.ignore.split(",").forEach(function(
|
|
1440
|
-
|
|
1441
|
-
}),
|
|
1442
|
-
evt:
|
|
1443
|
-
}), l.delay && (!l.delayOnTouchOnly ||
|
|
1698
|
+
}, l.ignore.split(",").forEach(function(c) {
|
|
1699
|
+
Dn(h, c.trim(), Dt);
|
|
1700
|
+
}), A(s, "dragover", ve), A(s, "mousemove", ve), A(s, "touchmove", ve), A(s, "mouseup", r._onDrop), A(s, "touchend", r._onDrop), A(s, "touchcancel", r._onDrop), rn && this.nativeDraggable && (this.options.touchStartThreshold = 4, h.draggable = !0), U("delayStart", this, {
|
|
1701
|
+
evt: t
|
|
1702
|
+
}), l.delay && (!l.delayOnTouchOnly || n) && (!this.nativeDraggable || !(He || ue))) {
|
|
1444
1703
|
if (b.eventCanceled) {
|
|
1445
1704
|
this._onDrop();
|
|
1446
1705
|
return;
|
|
1447
1706
|
}
|
|
1448
|
-
|
|
1707
|
+
A(s, "mouseup", r._disableDelayedDrag), A(s, "touchend", r._disableDelayedDrag), A(s, "touchcancel", r._disableDelayedDrag), A(s, "mousemove", r._delayedDragTouchMoveHandler), A(s, "touchmove", r._delayedDragTouchMoveHandler), l.supportPointer && A(s, "pointermove", r._delayedDragTouchMoveHandler), r._dragStartTimer = setTimeout(a, l.delay);
|
|
1449
1708
|
} else
|
|
1450
1709
|
a();
|
|
1451
1710
|
}
|
|
1452
1711
|
},
|
|
1453
|
-
_delayedDragTouchMoveHandler: function(
|
|
1454
|
-
var
|
|
1455
|
-
Math.max(Math.abs(
|
|
1712
|
+
_delayedDragTouchMoveHandler: function(t) {
|
|
1713
|
+
var n = t.touches ? t.touches[0] : t;
|
|
1714
|
+
Math.max(Math.abs(n.clientX - this._lastX), Math.abs(n.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1)) && this._disableDelayedDrag();
|
|
1456
1715
|
},
|
|
1457
1716
|
_disableDelayedDrag: function() {
|
|
1458
|
-
h &&
|
|
1717
|
+
h && Dt(h), clearTimeout(this._dragStartTimer), this._disableDelayedDragEvents();
|
|
1459
1718
|
},
|
|
1460
1719
|
_disableDelayedDragEvents: function() {
|
|
1461
|
-
var
|
|
1462
|
-
|
|
1720
|
+
var t = this.el.ownerDocument;
|
|
1721
|
+
C(t, "mouseup", this._disableDelayedDrag), C(t, "touchend", this._disableDelayedDrag), C(t, "touchcancel", this._disableDelayedDrag), C(t, "mousemove", this._delayedDragTouchMoveHandler), C(t, "touchmove", this._delayedDragTouchMoveHandler), C(t, "pointermove", this._delayedDragTouchMoveHandler);
|
|
1463
1722
|
},
|
|
1464
|
-
_triggerDragStart: function(
|
|
1465
|
-
|
|
1723
|
+
_triggerDragStart: function(t, n) {
|
|
1724
|
+
n = n || t.pointerType == "touch" && t, !this.nativeDraggable || n ? this.options.supportPointer ? A(document, "pointermove", this._onTouchMove) : n ? A(document, "touchmove", this._onTouchMove) : A(document, "mousemove", this._onTouchMove) : (A(h, "dragend", this), A(k, "dragstart", this._onDragStart));
|
|
1466
1725
|
try {
|
|
1467
|
-
document.selection ?
|
|
1726
|
+
document.selection ? et(function() {
|
|
1468
1727
|
document.selection.empty();
|
|
1469
1728
|
}) : window.getSelection().removeAllRanges();
|
|
1470
1729
|
} catch {
|
|
1471
1730
|
}
|
|
1472
1731
|
},
|
|
1473
|
-
_dragStarted: function(
|
|
1474
|
-
if (_e = !1,
|
|
1475
|
-
|
|
1476
|
-
evt:
|
|
1477
|
-
}), this.nativeDraggable &&
|
|
1478
|
-
var
|
|
1479
|
-
!
|
|
1732
|
+
_dragStarted: function(t, n) {
|
|
1733
|
+
if (_e = !1, k && h) {
|
|
1734
|
+
U("dragStarted", this, {
|
|
1735
|
+
evt: n
|
|
1736
|
+
}), this.nativeDraggable && A(document, "dragover", Vr);
|
|
1737
|
+
var i = this.options;
|
|
1738
|
+
!t && q(h, i.dragClass, !1), q(h, i.ghostClass, !0), b.active = this, t && this._appendGhost(), G({
|
|
1480
1739
|
sortable: this,
|
|
1481
1740
|
name: "start",
|
|
1482
|
-
originalEvent:
|
|
1741
|
+
originalEvent: n
|
|
1483
1742
|
});
|
|
1484
1743
|
} else
|
|
1485
1744
|
this._nulling();
|
|
1486
1745
|
},
|
|
1487
1746
|
_emulateDragOver: function() {
|
|
1488
1747
|
if (te) {
|
|
1489
|
-
this._lastX = te.clientX, this._lastY = te.clientY,
|
|
1490
|
-
for (var
|
|
1491
|
-
|
|
1492
|
-
if (h.parentNode[Z]._isOutsideThisEl(
|
|
1748
|
+
this._lastX = te.clientX, this._lastY = te.clientY, kn();
|
|
1749
|
+
for (var t = document.elementFromPoint(te.clientX, te.clientY), n = t; t && t.shadowRoot && (t = t.shadowRoot.elementFromPoint(te.clientX, te.clientY), t !== n); )
|
|
1750
|
+
n = t;
|
|
1751
|
+
if (h.parentNode[Z]._isOutsideThisEl(t), n)
|
|
1493
1752
|
do {
|
|
1494
|
-
if (
|
|
1495
|
-
var
|
|
1496
|
-
if (
|
|
1753
|
+
if (n[Z]) {
|
|
1754
|
+
var i = void 0;
|
|
1755
|
+
if (i = n[Z]._onDragOver({
|
|
1497
1756
|
clientX: te.clientX,
|
|
1498
1757
|
clientY: te.clientY,
|
|
1499
|
-
target:
|
|
1500
|
-
rootEl:
|
|
1501
|
-
}),
|
|
1758
|
+
target: t,
|
|
1759
|
+
rootEl: n
|
|
1760
|
+
}), i && !this.options.dragoverBubble)
|
|
1502
1761
|
break;
|
|
1503
1762
|
}
|
|
1504
|
-
|
|
1505
|
-
} while (
|
|
1506
|
-
|
|
1763
|
+
t = n;
|
|
1764
|
+
} while (n = n.parentNode);
|
|
1765
|
+
xn();
|
|
1507
1766
|
}
|
|
1508
1767
|
},
|
|
1509
|
-
_onTouchMove: function(
|
|
1510
|
-
if (
|
|
1511
|
-
var
|
|
1768
|
+
_onTouchMove: function(t) {
|
|
1769
|
+
if (ge) {
|
|
1770
|
+
var n = this.options, i = n.fallbackTolerance, r = n.fallbackOffset, o = t.touches ? t.touches[0] : t, l = E && De(E, !0), s = E && l && l.a, a = E && l && l.d, u = Ye && Y && an(Y), c = (o.clientX - ge.clientX + r.x) / (s || 1) + (u ? u[0] - Tt[0] : 0) / (s || 1), d = (o.clientY - ge.clientY + r.y) / (a || 1) + (u ? u[1] - Tt[1] : 0) / (a || 1);
|
|
1512
1771
|
if (!b.active && !_e) {
|
|
1513
|
-
if (
|
|
1772
|
+
if (i && Math.max(Math.abs(o.clientX - this._lastX), Math.abs(o.clientY - this._lastY)) < i)
|
|
1514
1773
|
return;
|
|
1515
|
-
this._onDragStart(
|
|
1774
|
+
this._onDragStart(t, !0);
|
|
1516
1775
|
}
|
|
1517
|
-
if (
|
|
1518
|
-
l ? (l.e +=
|
|
1776
|
+
if (E) {
|
|
1777
|
+
l ? (l.e += c - (Et || 0), l.f += d - (_t || 0)) : l = {
|
|
1519
1778
|
a: 1,
|
|
1520
1779
|
b: 0,
|
|
1521
1780
|
c: 0,
|
|
1522
1781
|
d: 1,
|
|
1523
|
-
e:
|
|
1524
|
-
f
|
|
1782
|
+
e: c,
|
|
1783
|
+
f: d
|
|
1525
1784
|
};
|
|
1526
1785
|
var m = "matrix(".concat(l.a, ",").concat(l.b, ",").concat(l.c, ",").concat(l.d, ",").concat(l.e, ",").concat(l.f, ")");
|
|
1527
|
-
v(
|
|
1786
|
+
v(E, "webkitTransform", m), v(E, "mozTransform", m), v(E, "msTransform", m), v(E, "transform", m), Et = c, _t = d, te = o;
|
|
1528
1787
|
}
|
|
1529
|
-
|
|
1788
|
+
t.cancelable && t.preventDefault();
|
|
1530
1789
|
}
|
|
1531
1790
|
},
|
|
1532
1791
|
_appendGhost: function() {
|
|
1533
|
-
if (!
|
|
1534
|
-
var
|
|
1792
|
+
if (!E) {
|
|
1793
|
+
var t = this.options.fallbackOnBody ? document.body : k, n = j(h, !0, Ye, !0, t), i = this.options;
|
|
1535
1794
|
if (Ye) {
|
|
1536
|
-
for (
|
|
1537
|
-
|
|
1538
|
-
|
|
1795
|
+
for (Y = t; v(Y, "position") === "static" && v(Y, "transform") === "none" && Y !== document; )
|
|
1796
|
+
Y = Y.parentNode;
|
|
1797
|
+
Y !== document.body && Y !== document.documentElement ? (Y === document && (Y = re()), n.top += Y.scrollTop, n.left += Y.scrollLeft) : Y = re(), Tt = an(Y);
|
|
1539
1798
|
}
|
|
1540
|
-
|
|
1799
|
+
E = h.cloneNode(!0), q(E, i.ghostClass, !1), q(E, i.fallbackClass, !0), q(E, i.dragClass, !0), v(E, "transition", ""), v(E, "transform", ""), v(E, "box-sizing", "border-box"), v(E, "margin", 0), v(E, "top", n.top), v(E, "left", n.left), v(E, "width", n.width), v(E, "height", n.height), v(E, "opacity", "0.8"), v(E, "position", Ye ? "absolute" : "fixed"), v(E, "zIndex", "100000"), v(E, "pointerEvents", "none"), b.ghost = E, t.appendChild(E), v(E, "transform-origin", sn / parseInt(E.style.width) * 100 + "% " + un / parseInt(E.style.height) * 100 + "%");
|
|
1541
1800
|
}
|
|
1542
1801
|
},
|
|
1543
|
-
_onDragStart: function(
|
|
1544
|
-
var
|
|
1545
|
-
if (
|
|
1546
|
-
evt:
|
|
1802
|
+
_onDragStart: function(t, n) {
|
|
1803
|
+
var i = this, r = t.dataTransfer, o = i.options;
|
|
1804
|
+
if (U("dragStart", this, {
|
|
1805
|
+
evt: t
|
|
1547
1806
|
}), b.eventCanceled) {
|
|
1548
1807
|
this._onDrop();
|
|
1549
1808
|
return;
|
|
1550
1809
|
}
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
sortable:
|
|
1810
|
+
U("setupClone", this), b.eventCanceled || ($ = Cn(h), $.removeAttribute("id"), $.draggable = !1, $.style["will-change"] = "", this._hideClone(), q($, this.options.chosenClass, !1), b.clone = $), i.cloneId = et(function() {
|
|
1811
|
+
U("clone", i), !b.eventCanceled && (i.options.removeCloneOnHide || k.insertBefore($, h), i._hideClone(), G({
|
|
1812
|
+
sortable: i,
|
|
1554
1813
|
name: "clone"
|
|
1555
1814
|
}));
|
|
1556
|
-
}), !
|
|
1815
|
+
}), !n && q(h, o.dragClass, !0), n ? (at = !0, i._loopId = setInterval(i._emulateDragOver, 50)) : (C(document, "mouseup", i._onDrop), C(document, "touchend", i._onDrop), C(document, "touchcancel", i._onDrop), r && (r.effectAllowed = "move", o.setData && o.setData.call(i, r, h)), A(document, "drop", i), v(h, "transform", "translateZ(0)")), _e = !0, i._dragStartId = et(i._dragStarted.bind(i, n, t)), A(document, "selectstart", i), Pe = !0, Me && v(document.body, "user-select", "none");
|
|
1557
1816
|
},
|
|
1558
1817
|
// Returns true - if no further action is needed (either inserted or another condition)
|
|
1559
|
-
_onDragOver: function(
|
|
1560
|
-
var
|
|
1561
|
-
if (
|
|
1562
|
-
function
|
|
1563
|
-
|
|
1564
|
-
evt:
|
|
1565
|
-
isOwner:
|
|
1566
|
-
axis:
|
|
1818
|
+
_onDragOver: function(t) {
|
|
1819
|
+
var n = this.el, i = t.target, r, o, l, s = this.options, a = s.group, u = b.active, c = We === a, d = s.sort, m = W || u, y, S = this, p = !1;
|
|
1820
|
+
if (Mt) return;
|
|
1821
|
+
function f(Ce, Mn) {
|
|
1822
|
+
U(Ce, S, oe({
|
|
1823
|
+
evt: t,
|
|
1824
|
+
isOwner: c,
|
|
1825
|
+
axis: y ? "vertical" : "horizontal",
|
|
1567
1826
|
revert: l,
|
|
1568
1827
|
dragRect: r,
|
|
1569
1828
|
targetRect: o,
|
|
1570
|
-
canSort:
|
|
1829
|
+
canSort: d,
|
|
1571
1830
|
fromSortable: m,
|
|
1572
|
-
target:
|
|
1573
|
-
completed:
|
|
1574
|
-
onMove: function(
|
|
1575
|
-
return
|
|
1831
|
+
target: i,
|
|
1832
|
+
completed: D,
|
|
1833
|
+
onMove: function(Xt, Rn) {
|
|
1834
|
+
return Ge(k, n, h, r, Xt, j(Xt), t, Rn);
|
|
1576
1835
|
},
|
|
1577
|
-
changed:
|
|
1578
|
-
},
|
|
1836
|
+
changed: w
|
|
1837
|
+
}, Mn));
|
|
1579
1838
|
}
|
|
1580
|
-
function
|
|
1581
|
-
|
|
1839
|
+
function T() {
|
|
1840
|
+
f("dragOverAnimationCapture"), S.captureAnimationState(), S !== m && m.captureAnimationState();
|
|
1582
1841
|
}
|
|
1583
|
-
function
|
|
1584
|
-
return
|
|
1585
|
-
insertion:
|
|
1586
|
-
}),
|
|
1587
|
-
|
|
1588
|
-
}), S !== m && (m.animateAll(), m._ignoreWhileAnimating = null)), (
|
|
1842
|
+
function D(Ce) {
|
|
1843
|
+
return f("dragOverCompleted", {
|
|
1844
|
+
insertion: Ce
|
|
1845
|
+
}), Ce && (c ? u._hideClone() : u._showClone(S), S !== m && (q(h, W ? W.options.ghostClass : u.options.ghostClass, !1), q(h, s.ghostClass, !0)), W !== S && S !== b.active ? W = S : S === b.active && W && (W = null), m === S && (S._ignoreWhileAnimating = i), S.animateAll(function() {
|
|
1846
|
+
f("dragOverAnimationComplete"), S._ignoreWhileAnimating = null;
|
|
1847
|
+
}), S !== m && (m.animateAll(), m._ignoreWhileAnimating = null)), (i === h && !h.animated || i === n && !i.animated) && (Se = null), !s.dragoverBubble && !t.rootEl && i !== document && (h.parentNode[Z]._isOutsideThisEl(t.target), !Ce && ve(t)), !s.dragoverBubble && t.stopPropagation && t.stopPropagation(), p = !0;
|
|
1589
1848
|
}
|
|
1590
|
-
function
|
|
1591
|
-
J = ee(h),
|
|
1849
|
+
function w() {
|
|
1850
|
+
J = ee(h), fe = ee(h, s.draggable), G({
|
|
1592
1851
|
sortable: S,
|
|
1593
1852
|
name: "change",
|
|
1594
|
-
toEl:
|
|
1853
|
+
toEl: n,
|
|
1595
1854
|
newIndex: J,
|
|
1596
|
-
newDraggableIndex:
|
|
1597
|
-
originalEvent:
|
|
1855
|
+
newDraggableIndex: fe,
|
|
1856
|
+
originalEvent: t
|
|
1598
1857
|
});
|
|
1599
1858
|
}
|
|
1600
|
-
if (
|
|
1601
|
-
if (h.contains(
|
|
1602
|
-
return
|
|
1603
|
-
if (
|
|
1604
|
-
if (
|
|
1859
|
+
if (t.preventDefault !== void 0 && t.cancelable && t.preventDefault(), i = ne(i, s.draggable, n, !0), f("dragOver"), b.eventCanceled) return p;
|
|
1860
|
+
if (h.contains(t.target) || i.animated && i.animatingX && i.animatingY || S._ignoreWhileAnimating === i)
|
|
1861
|
+
return D(!1);
|
|
1862
|
+
if (at = !1, u && !s.disabled && (c ? d || (l = M !== k) : W === this || (this.lastPutMode = We.checkPull(this, u, h, t)) && a.checkPut(this, u, h, t))) {
|
|
1863
|
+
if (y = this._getDirection(t, i) === "vertical", r = j(h), f("dragOverValid"), b.eventCanceled) return p;
|
|
1605
1864
|
if (l)
|
|
1606
|
-
return
|
|
1607
|
-
var g =
|
|
1608
|
-
if (!g ||
|
|
1865
|
+
return M = k, T(), this._hideClone(), f("revert"), b.eventCanceled || (be ? k.insertBefore(h, be) : k.appendChild(h)), D(!0);
|
|
1866
|
+
var g = jt(n, s.draggable);
|
|
1867
|
+
if (!g || jr(t, y, this) && !g.animated) {
|
|
1609
1868
|
if (g === h)
|
|
1610
|
-
return
|
|
1611
|
-
if (g &&
|
|
1612
|
-
return
|
|
1613
|
-
} else if (g &&
|
|
1614
|
-
var
|
|
1615
|
-
if (
|
|
1616
|
-
return
|
|
1617
|
-
if (
|
|
1618
|
-
return
|
|
1619
|
-
} else if (
|
|
1620
|
-
o =
|
|
1621
|
-
var
|
|
1622
|
-
|
|
1623
|
-
var
|
|
1624
|
-
if (
|
|
1625
|
-
var
|
|
1869
|
+
return D(!1);
|
|
1870
|
+
if (g && n === t.target && (i = g), i && (o = j(i)), Ge(k, n, h, r, i, o, t, !!i) !== !1)
|
|
1871
|
+
return T(), g && g.nextSibling ? n.insertBefore(h, g.nextSibling) : n.appendChild(h), M = n, w(), D(!0);
|
|
1872
|
+
} else if (g && Hr(t, y, this)) {
|
|
1873
|
+
var B = Oe(n, 0, s, !0);
|
|
1874
|
+
if (B === h)
|
|
1875
|
+
return D(!1);
|
|
1876
|
+
if (i = B, o = j(i), Ge(k, n, h, r, i, o, t, !1) !== !1)
|
|
1877
|
+
return T(), n.insertBefore(h, B), M = n, w(), D(!0);
|
|
1878
|
+
} else if (i.parentNode === n) {
|
|
1879
|
+
o = j(i);
|
|
1880
|
+
var I = 0, P, L = h.parentNode !== n, R = !Mr(h.animated && h.toRect || r, i.animated && i.toRect || o, y), _ = y ? "top" : "left", V = ln(i, "top", "top") || ln(h, "top", "top"), x = V ? V.scrollTop : void 0;
|
|
1881
|
+
Se !== i && (P = o[_], Le = !1, Xe = !R && s.invertSwap || L), I = Br(t, i, o, y, R ? 1 : s.swapThreshold, s.invertedSwapThreshold == null ? s.swapThreshold : s.invertedSwapThreshold, Xe, Se === i);
|
|
1882
|
+
var N;
|
|
1883
|
+
if (I !== 0) {
|
|
1884
|
+
var K = ee(h);
|
|
1626
1885
|
do
|
|
1627
|
-
|
|
1628
|
-
while (
|
|
1886
|
+
K -= I, N = M.children[K];
|
|
1887
|
+
while (N && (v(N, "display") === "none" || N === E));
|
|
1629
1888
|
}
|
|
1630
|
-
if (
|
|
1631
|
-
return
|
|
1632
|
-
|
|
1633
|
-
var
|
|
1634
|
-
|
|
1635
|
-
var
|
|
1636
|
-
if (
|
|
1637
|
-
return (
|
|
1889
|
+
if (I === 0 || N === i)
|
|
1890
|
+
return D(!1);
|
|
1891
|
+
Se = i, Fe = I;
|
|
1892
|
+
var ce = i.nextElementSibling, F = !1;
|
|
1893
|
+
F = I === 1;
|
|
1894
|
+
var me = Ge(k, n, h, r, i, o, t, F);
|
|
1895
|
+
if (me !== !1)
|
|
1896
|
+
return (me === 1 || me === -1) && (F = me === 1), Mt = !0, setTimeout(Lr, 30), T(), F && !ce ? n.appendChild(h) : i.parentNode.insertBefore(h, F ? ce : i), V && On(V, 0, x - V.scrollTop), M = h.parentNode, P !== void 0 && !Xe && (Qe = Math.abs(P - j(i)[_])), w(), D(!0);
|
|
1638
1897
|
}
|
|
1639
|
-
if (
|
|
1640
|
-
return
|
|
1898
|
+
if (n.contains(h))
|
|
1899
|
+
return D(!1);
|
|
1641
1900
|
}
|
|
1642
1901
|
return !1;
|
|
1643
1902
|
},
|
|
1644
1903
|
_ignoreWhileAnimating: null,
|
|
1645
1904
|
_offMoveEvents: function() {
|
|
1646
|
-
|
|
1905
|
+
C(document, "mousemove", this._onTouchMove), C(document, "touchmove", this._onTouchMove), C(document, "pointermove", this._onTouchMove), C(document, "dragover", ve), C(document, "mousemove", ve), C(document, "touchmove", ve);
|
|
1647
1906
|
},
|
|
1648
1907
|
_offUpEvents: function() {
|
|
1649
|
-
var
|
|
1650
|
-
|
|
1908
|
+
var t = this.el.ownerDocument;
|
|
1909
|
+
C(t, "mouseup", this._onDrop), C(t, "touchend", this._onDrop), C(t, "pointerup", this._onDrop), C(t, "touchcancel", this._onDrop), C(document, "selectstart", this);
|
|
1651
1910
|
},
|
|
1652
|
-
_onDrop: function(
|
|
1653
|
-
var
|
|
1654
|
-
if (J = ee(h),
|
|
1655
|
-
evt:
|
|
1656
|
-
}),
|
|
1911
|
+
_onDrop: function(t) {
|
|
1912
|
+
var n = this.el, i = this.options;
|
|
1913
|
+
if (J = ee(h), fe = ee(h, i.draggable), U("drop", this, {
|
|
1914
|
+
evt: t
|
|
1915
|
+
}), M = h && h.parentNode, J = ee(h), fe = ee(h, i.draggable), b.eventCanceled) {
|
|
1657
1916
|
this._nulling();
|
|
1658
1917
|
return;
|
|
1659
1918
|
}
|
|
1660
|
-
_e = !1,
|
|
1919
|
+
_e = !1, Xe = !1, Le = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), Rt(this.cloneId), Rt(this._dragStartId), this.nativeDraggable && (C(document, "drop", this), C(n, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), Me && v(document.body, "user-select", ""), v(h, "transform", ""), t && (Pe && (t.cancelable && t.preventDefault(), !i.dropBubble && t.stopPropagation()), E && E.parentNode && E.parentNode.removeChild(E), (k === M || W && W.lastPutMode !== "clone") && $ && $.parentNode && $.parentNode.removeChild($), h && (this.nativeDraggable && C(h, "dragend", this), Dt(h), h.style["will-change"] = "", Pe && !_e && q(h, W ? W.options.ghostClass : this.options.ghostClass, !1), q(h, this.options.chosenClass, !1), G({
|
|
1661
1920
|
sortable: this,
|
|
1662
1921
|
name: "unchoose",
|
|
1663
|
-
toEl:
|
|
1922
|
+
toEl: M,
|
|
1664
1923
|
newIndex: null,
|
|
1665
1924
|
newDraggableIndex: null,
|
|
1666
|
-
originalEvent:
|
|
1667
|
-
}),
|
|
1668
|
-
rootEl:
|
|
1925
|
+
originalEvent: t
|
|
1926
|
+
}), k !== M ? (J >= 0 && (G({
|
|
1927
|
+
rootEl: M,
|
|
1669
1928
|
name: "add",
|
|
1670
|
-
toEl:
|
|
1671
|
-
fromEl:
|
|
1672
|
-
originalEvent:
|
|
1673
|
-
}),
|
|
1929
|
+
toEl: M,
|
|
1930
|
+
fromEl: k,
|
|
1931
|
+
originalEvent: t
|
|
1932
|
+
}), G({
|
|
1674
1933
|
sortable: this,
|
|
1675
1934
|
name: "remove",
|
|
1676
|
-
toEl:
|
|
1677
|
-
originalEvent:
|
|
1678
|
-
}),
|
|
1679
|
-
rootEl:
|
|
1935
|
+
toEl: M,
|
|
1936
|
+
originalEvent: t
|
|
1937
|
+
}), G({
|
|
1938
|
+
rootEl: M,
|
|
1680
1939
|
name: "sort",
|
|
1681
|
-
toEl:
|
|
1682
|
-
fromEl:
|
|
1683
|
-
originalEvent:
|
|
1684
|
-
}),
|
|
1940
|
+
toEl: M,
|
|
1941
|
+
fromEl: k,
|
|
1942
|
+
originalEvent: t
|
|
1943
|
+
}), G({
|
|
1685
1944
|
sortable: this,
|
|
1686
1945
|
name: "sort",
|
|
1687
|
-
toEl:
|
|
1688
|
-
originalEvent:
|
|
1689
|
-
})),
|
|
1946
|
+
toEl: M,
|
|
1947
|
+
originalEvent: t
|
|
1948
|
+
})), W && W.save()) : J !== Te && J >= 0 && (G({
|
|
1690
1949
|
sortable: this,
|
|
1691
1950
|
name: "update",
|
|
1692
|
-
toEl:
|
|
1693
|
-
originalEvent:
|
|
1694
|
-
}),
|
|
1951
|
+
toEl: M,
|
|
1952
|
+
originalEvent: t
|
|
1953
|
+
}), G({
|
|
1695
1954
|
sortable: this,
|
|
1696
1955
|
name: "sort",
|
|
1697
|
-
toEl:
|
|
1698
|
-
originalEvent:
|
|
1699
|
-
})), b.active && ((J == null || J === -1) && (J =
|
|
1956
|
+
toEl: M,
|
|
1957
|
+
originalEvent: t
|
|
1958
|
+
})), b.active && ((J == null || J === -1) && (J = Te, fe = Ve), G({
|
|
1700
1959
|
sortable: this,
|
|
1701
1960
|
name: "end",
|
|
1702
|
-
toEl:
|
|
1703
|
-
originalEvent:
|
|
1961
|
+
toEl: M,
|
|
1962
|
+
originalEvent: t
|
|
1704
1963
|
}), this.save()))), this._nulling();
|
|
1705
1964
|
},
|
|
1706
1965
|
_nulling: function() {
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
}),
|
|
1966
|
+
U("nulling", this), k = h = M = E = be = $ = Ze = he = ge = te = Pe = J = fe = Te = Ve = Se = Fe = W = We = b.dragged = b.ghost = b.clone = b.active = null, ut.forEach(function(t) {
|
|
1967
|
+
t.checked = !0;
|
|
1968
|
+
}), ut.length = Et = _t = 0;
|
|
1710
1969
|
},
|
|
1711
|
-
handleEvent: function(
|
|
1712
|
-
switch (
|
|
1970
|
+
handleEvent: function(t) {
|
|
1971
|
+
switch (t.type) {
|
|
1713
1972
|
case "drop":
|
|
1714
1973
|
case "dragend":
|
|
1715
|
-
this._onDrop(
|
|
1974
|
+
this._onDrop(t);
|
|
1716
1975
|
break;
|
|
1717
1976
|
case "dragenter":
|
|
1718
1977
|
case "dragover":
|
|
1719
|
-
h && (this._onDragOver(
|
|
1978
|
+
h && (this._onDragOver(t), Fr(t));
|
|
1720
1979
|
break;
|
|
1721
1980
|
case "selectstart":
|
|
1722
|
-
|
|
1981
|
+
t.preventDefault();
|
|
1723
1982
|
break;
|
|
1724
1983
|
}
|
|
1725
1984
|
},
|
|
@@ -1728,29 +1987,29 @@ b.prototype = /** @lends Sortable.prototype */
|
|
|
1728
1987
|
* @returns {String[]}
|
|
1729
1988
|
*/
|
|
1730
1989
|
toArray: function() {
|
|
1731
|
-
for (var
|
|
1732
|
-
|
|
1733
|
-
return
|
|
1990
|
+
for (var t = [], n, i = this.el.children, r = 0, o = i.length, l = this.options; r < o; r++)
|
|
1991
|
+
n = i[r], ne(n, l.draggable, this.el, !1) && t.push(n.getAttribute(l.dataIdAttr) || Xr(n));
|
|
1992
|
+
return t;
|
|
1734
1993
|
},
|
|
1735
1994
|
/**
|
|
1736
1995
|
* Sorts the elements according to the array.
|
|
1737
1996
|
* @param {String[]} order order of the items
|
|
1738
1997
|
*/
|
|
1739
|
-
sort: function(
|
|
1740
|
-
var
|
|
1998
|
+
sort: function(t, n) {
|
|
1999
|
+
var i = {}, r = this.el;
|
|
1741
2000
|
this.toArray().forEach(function(o, l) {
|
|
1742
2001
|
var s = r.children[l];
|
|
1743
|
-
|
|
1744
|
-
}, this),
|
|
1745
|
-
|
|
1746
|
-
}),
|
|
2002
|
+
ne(s, this.options.draggable, r, !1) && (i[o] = s);
|
|
2003
|
+
}, this), n && this.captureAnimationState(), t.forEach(function(o) {
|
|
2004
|
+
i[o] && (r.removeChild(i[o]), r.appendChild(i[o]));
|
|
2005
|
+
}), n && this.animateAll();
|
|
1747
2006
|
},
|
|
1748
2007
|
/**
|
|
1749
2008
|
* Save the current sorting
|
|
1750
2009
|
*/
|
|
1751
2010
|
save: function() {
|
|
1752
|
-
var
|
|
1753
|
-
|
|
2011
|
+
var t = this.options.store;
|
|
2012
|
+
t && t.set && t.set(this);
|
|
1754
2013
|
},
|
|
1755
2014
|
/**
|
|
1756
2015
|
* For each element in the set, get the first element that matches the selector by testing the element itself and traversing up through its ancestors in the DOM tree.
|
|
@@ -1758,8 +2017,8 @@ b.prototype = /** @lends Sortable.prototype */
|
|
|
1758
2017
|
* @param {String} [selector] default: `options.draggable`
|
|
1759
2018
|
* @returns {HTMLElement|null}
|
|
1760
2019
|
*/
|
|
1761
|
-
closest: function(
|
|
1762
|
-
return
|
|
2020
|
+
closest: function(t, n) {
|
|
2021
|
+
return ne(t, n || this.options.draggable, this.el, !1);
|
|
1763
2022
|
},
|
|
1764
2023
|
/**
|
|
1765
2024
|
* Set/get option
|
|
@@ -1767,139 +2026,139 @@ b.prototype = /** @lends Sortable.prototype */
|
|
|
1767
2026
|
* @param {*} [value]
|
|
1768
2027
|
* @returns {*}
|
|
1769
2028
|
*/
|
|
1770
|
-
option: function(
|
|
1771
|
-
var
|
|
1772
|
-
if (
|
|
1773
|
-
return
|
|
1774
|
-
var r =
|
|
1775
|
-
typeof r < "u" ?
|
|
2029
|
+
option: function(t, n) {
|
|
2030
|
+
var i = this.options;
|
|
2031
|
+
if (n === void 0)
|
|
2032
|
+
return i[t];
|
|
2033
|
+
var r = je.modifyOption(this, t, n);
|
|
2034
|
+
typeof r < "u" ? i[t] = r : i[t] = n, t === "group" && Pn(i);
|
|
1776
2035
|
},
|
|
1777
2036
|
/**
|
|
1778
2037
|
* Destroy
|
|
1779
2038
|
*/
|
|
1780
2039
|
destroy: function() {
|
|
1781
|
-
|
|
1782
|
-
var
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
}), this._onDrop(), this._disableDelayedDragEvents(),
|
|
2040
|
+
U("destroy", this);
|
|
2041
|
+
var t = this.el;
|
|
2042
|
+
t[Z] = null, C(t, "mousedown", this._onTapStart), C(t, "touchstart", this._onTapStart), C(t, "pointerdown", this._onTapStart), this.nativeDraggable && (C(t, "dragover", this), C(t, "dragenter", this)), Array.prototype.forEach.call(t.querySelectorAll("[draggable]"), function(n) {
|
|
2043
|
+
n.removeAttribute("draggable");
|
|
2044
|
+
}), this._onDrop(), this._disableDelayedDragEvents(), st.splice(st.indexOf(this.el), 1), this.el = t = null;
|
|
1786
2045
|
},
|
|
1787
2046
|
_hideClone: function() {
|
|
1788
|
-
if (!
|
|
1789
|
-
if (
|
|
1790
|
-
v(
|
|
2047
|
+
if (!he) {
|
|
2048
|
+
if (U("hideClone", this), b.eventCanceled) return;
|
|
2049
|
+
v($, "display", "none"), this.options.removeCloneOnHide && $.parentNode && $.parentNode.removeChild($), he = !0;
|
|
1791
2050
|
}
|
|
1792
2051
|
},
|
|
1793
|
-
_showClone: function(
|
|
1794
|
-
if (
|
|
2052
|
+
_showClone: function(t) {
|
|
2053
|
+
if (t.lastPutMode !== "clone") {
|
|
1795
2054
|
this._hideClone();
|
|
1796
2055
|
return;
|
|
1797
2056
|
}
|
|
1798
|
-
if (
|
|
1799
|
-
if (
|
|
1800
|
-
h.parentNode ==
|
|
2057
|
+
if (he) {
|
|
2058
|
+
if (U("showClone", this), b.eventCanceled) return;
|
|
2059
|
+
h.parentNode == k && !this.options.group.revertClone ? k.insertBefore($, h) : be ? k.insertBefore($, be) : k.appendChild($), this.options.group.revertClone && this.animate(h, $), v($, "display", ""), he = !1;
|
|
1801
2060
|
}
|
|
1802
2061
|
}
|
|
1803
2062
|
};
|
|
1804
|
-
function
|
|
1805
|
-
|
|
2063
|
+
function Fr(e) {
|
|
2064
|
+
e.dataTransfer && (e.dataTransfer.dropEffect = "move"), e.cancelable && e.preventDefault();
|
|
1806
2065
|
}
|
|
1807
|
-
function
|
|
1808
|
-
var a, u =
|
|
1809
|
-
return window.CustomEvent && !
|
|
2066
|
+
function Ge(e, t, n, i, r, o, l, s) {
|
|
2067
|
+
var a, u = e[Z], c = u.options.onMove, d;
|
|
2068
|
+
return window.CustomEvent && !ue && !He ? a = new CustomEvent("move", {
|
|
1810
2069
|
bubbles: !0,
|
|
1811
2070
|
cancelable: !0
|
|
1812
|
-
}) : (a = document.createEvent("Event"), a.initEvent("move", !0, !0)), a.to =
|
|
2071
|
+
}) : (a = document.createEvent("Event"), a.initEvent("move", !0, !0)), a.to = t, a.from = e, a.dragged = n, a.draggedRect = i, a.related = r || t, a.relatedRect = o || j(t), a.willInsertAfter = s, a.originalEvent = l, e.dispatchEvent(a), c && (d = c.call(u, a, l)), d;
|
|
1813
2072
|
}
|
|
1814
|
-
function
|
|
1815
|
-
|
|
2073
|
+
function Dt(e) {
|
|
2074
|
+
e.draggable = !1;
|
|
1816
2075
|
}
|
|
1817
|
-
function
|
|
1818
|
-
|
|
2076
|
+
function Lr() {
|
|
2077
|
+
Mt = !1;
|
|
1819
2078
|
}
|
|
1820
|
-
function
|
|
1821
|
-
var
|
|
1822
|
-
return
|
|
2079
|
+
function Hr(e, t, n) {
|
|
2080
|
+
var i = j(Oe(n.el, 0, n.options, !0)), r = An(n.el, n.options, E), o = 10;
|
|
2081
|
+
return t ? e.clientX < r.left - o || e.clientY < i.top && e.clientX < i.right : e.clientY < r.top - o || e.clientY < i.bottom && e.clientX < i.left;
|
|
1823
2082
|
}
|
|
1824
|
-
function
|
|
1825
|
-
var
|
|
1826
|
-
return
|
|
2083
|
+
function jr(e, t, n) {
|
|
2084
|
+
var i = j(jt(n.el, n.options.draggable)), r = An(n.el, n.options, E), o = 10;
|
|
2085
|
+
return t ? e.clientX > r.right + o || e.clientY > i.bottom && e.clientX > i.left : e.clientY > r.bottom + o || e.clientX > i.right && e.clientY > i.top;
|
|
1827
2086
|
}
|
|
1828
|
-
function
|
|
1829
|
-
var a =
|
|
2087
|
+
function Br(e, t, n, i, r, o, l, s) {
|
|
2088
|
+
var a = i ? e.clientY : e.clientX, u = i ? n.height : n.width, c = i ? n.top : n.left, d = i ? n.bottom : n.right, m = !1;
|
|
1830
2089
|
if (!l) {
|
|
1831
|
-
if (s &&
|
|
1832
|
-
if (!
|
|
2090
|
+
if (s && Qe < u * r) {
|
|
2091
|
+
if (!Le && (Fe === 1 ? a > c + u * o / 2 : a < d - u * o / 2) && (Le = !0), Le)
|
|
1833
2092
|
m = !0;
|
|
1834
|
-
else if (
|
|
1835
|
-
return -
|
|
1836
|
-
} else if (a >
|
|
1837
|
-
return
|
|
2093
|
+
else if (Fe === 1 ? a < c + Qe : a > d - Qe)
|
|
2094
|
+
return -Fe;
|
|
2095
|
+
} else if (a > c + u * (1 - r) / 2 && a < d - u * (1 - r) / 2)
|
|
2096
|
+
return Wr(t);
|
|
1838
2097
|
}
|
|
1839
|
-
return m = m || l, m && (a <
|
|
2098
|
+
return m = m || l, m && (a < c + u * o / 2 || a > d - u * o / 2) ? a > c + u / 2 ? 1 : -1 : 0;
|
|
1840
2099
|
}
|
|
1841
|
-
function
|
|
1842
|
-
return ee(h) < ee(
|
|
2100
|
+
function Wr(e) {
|
|
2101
|
+
return ee(h) < ee(e) ? 1 : -1;
|
|
1843
2102
|
}
|
|
1844
|
-
function
|
|
1845
|
-
for (var
|
|
1846
|
-
|
|
1847
|
-
return
|
|
2103
|
+
function Xr(e) {
|
|
2104
|
+
for (var t = e.tagName + e.className + e.src + e.href + e.textContent, n = t.length, i = 0; n--; )
|
|
2105
|
+
i += t.charCodeAt(n);
|
|
2106
|
+
return i.toString(36);
|
|
1848
2107
|
}
|
|
1849
|
-
function
|
|
1850
|
-
|
|
1851
|
-
for (var
|
|
1852
|
-
var
|
|
1853
|
-
|
|
2108
|
+
function Yr(e) {
|
|
2109
|
+
ut.length = 0;
|
|
2110
|
+
for (var t = e.getElementsByTagName("input"), n = t.length; n--; ) {
|
|
2111
|
+
var i = t[n];
|
|
2112
|
+
i.checked && ut.push(i);
|
|
1854
2113
|
}
|
|
1855
2114
|
}
|
|
1856
|
-
function
|
|
1857
|
-
return setTimeout(
|
|
2115
|
+
function et(e) {
|
|
2116
|
+
return setTimeout(e, 0);
|
|
1858
2117
|
}
|
|
1859
|
-
function
|
|
1860
|
-
return clearTimeout(
|
|
2118
|
+
function Rt(e) {
|
|
2119
|
+
return clearTimeout(e);
|
|
1861
2120
|
}
|
|
1862
|
-
|
|
1863
|
-
(b.active || _e) &&
|
|
2121
|
+
ht && A(document, "touchmove", function(e) {
|
|
2122
|
+
(b.active || _e) && e.cancelable && e.preventDefault();
|
|
1864
2123
|
});
|
|
1865
2124
|
b.utils = {
|
|
1866
|
-
on:
|
|
1867
|
-
off:
|
|
2125
|
+
on: A,
|
|
2126
|
+
off: C,
|
|
1868
2127
|
css: v,
|
|
1869
|
-
find:
|
|
1870
|
-
is: function(
|
|
1871
|
-
return !!
|
|
2128
|
+
find: Dn,
|
|
2129
|
+
is: function(t, n) {
|
|
2130
|
+
return !!ne(t, n, t, !1);
|
|
1872
2131
|
},
|
|
1873
|
-
extend:
|
|
1874
|
-
throttle:
|
|
1875
|
-
closest:
|
|
2132
|
+
extend: Cr,
|
|
2133
|
+
throttle: In,
|
|
2134
|
+
closest: ne,
|
|
1876
2135
|
toggleClass: q,
|
|
1877
|
-
clone:
|
|
2136
|
+
clone: Cn,
|
|
1878
2137
|
index: ee,
|
|
1879
|
-
nextTick:
|
|
1880
|
-
cancelNextTick:
|
|
1881
|
-
detectDirection:
|
|
1882
|
-
getChild:
|
|
2138
|
+
nextTick: et,
|
|
2139
|
+
cancelNextTick: Rt,
|
|
2140
|
+
detectDirection: zn,
|
|
2141
|
+
getChild: Oe
|
|
1883
2142
|
};
|
|
1884
|
-
b.get = function(
|
|
1885
|
-
return
|
|
2143
|
+
b.get = function(e) {
|
|
2144
|
+
return e[Z];
|
|
1886
2145
|
};
|
|
1887
2146
|
b.mount = function() {
|
|
1888
|
-
for (var
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
if (!
|
|
1892
|
-
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(
|
|
1893
|
-
|
|
2147
|
+
for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++)
|
|
2148
|
+
t[n] = arguments[n];
|
|
2149
|
+
t[0].constructor === Array && (t = t[0]), t.forEach(function(i) {
|
|
2150
|
+
if (!i.prototype || !i.prototype.constructor)
|
|
2151
|
+
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(i));
|
|
2152
|
+
i.utils && (b.utils = oe(oe({}, b.utils), i.utils)), je.mount(i);
|
|
1894
2153
|
});
|
|
1895
2154
|
};
|
|
1896
|
-
b.create = function(
|
|
1897
|
-
return new b(
|
|
2155
|
+
b.create = function(e, t) {
|
|
2156
|
+
return new b(e, t);
|
|
1898
2157
|
};
|
|
1899
|
-
b.version =
|
|
1900
|
-
var
|
|
1901
|
-
function
|
|
1902
|
-
function
|
|
2158
|
+
b.version = Dr;
|
|
2159
|
+
var H = [], ke, Vt, Ft = !1, It, Ot, ct, xe;
|
|
2160
|
+
function Gr() {
|
|
2161
|
+
function e() {
|
|
1903
2162
|
this.defaults = {
|
|
1904
2163
|
scroll: !0,
|
|
1905
2164
|
forceAutoScrollFallback: !1,
|
|
@@ -1907,166 +2166,166 @@ function Hn() {
|
|
|
1907
2166
|
scrollSpeed: 10,
|
|
1908
2167
|
bubbleScroll: !0
|
|
1909
2168
|
};
|
|
1910
|
-
for (var
|
|
1911
|
-
|
|
2169
|
+
for (var t in this)
|
|
2170
|
+
t.charAt(0) === "_" && typeof this[t] == "function" && (this[t] = this[t].bind(this));
|
|
1912
2171
|
}
|
|
1913
|
-
return
|
|
1914
|
-
dragStarted: function(
|
|
1915
|
-
var
|
|
1916
|
-
this.sortable.nativeDraggable ?
|
|
2172
|
+
return e.prototype = {
|
|
2173
|
+
dragStarted: function(n) {
|
|
2174
|
+
var i = n.originalEvent;
|
|
2175
|
+
this.sortable.nativeDraggable ? A(document, "dragover", this._handleAutoScroll) : this.options.supportPointer ? A(document, "pointermove", this._handleFallbackAutoScroll) : i.touches ? A(document, "touchmove", this._handleFallbackAutoScroll) : A(document, "mousemove", this._handleFallbackAutoScroll);
|
|
1917
2176
|
},
|
|
1918
|
-
dragOverCompleted: function(
|
|
1919
|
-
var
|
|
1920
|
-
!this.options.dragOverBubble && !
|
|
2177
|
+
dragOverCompleted: function(n) {
|
|
2178
|
+
var i = n.originalEvent;
|
|
2179
|
+
!this.options.dragOverBubble && !i.rootEl && this._handleAutoScroll(i);
|
|
1921
2180
|
},
|
|
1922
2181
|
drop: function() {
|
|
1923
|
-
this.sortable.nativeDraggable ?
|
|
2182
|
+
this.sortable.nativeDraggable ? C(document, "dragover", this._handleAutoScroll) : (C(document, "pointermove", this._handleFallbackAutoScroll), C(document, "touchmove", this._handleFallbackAutoScroll), C(document, "mousemove", this._handleFallbackAutoScroll)), dn(), tt(), Ar();
|
|
1924
2183
|
},
|
|
1925
2184
|
nulling: function() {
|
|
1926
|
-
|
|
2185
|
+
ct = Vt = ke = Ft = xe = It = Ot = null, H.length = 0;
|
|
1927
2186
|
},
|
|
1928
|
-
_handleFallbackAutoScroll: function(
|
|
1929
|
-
this._handleAutoScroll(
|
|
2187
|
+
_handleFallbackAutoScroll: function(n) {
|
|
2188
|
+
this._handleAutoScroll(n, !0);
|
|
1930
2189
|
},
|
|
1931
|
-
_handleAutoScroll: function(
|
|
1932
|
-
var r = this, o = (
|
|
1933
|
-
if (
|
|
1934
|
-
|
|
1935
|
-
var a =
|
|
1936
|
-
|
|
1937
|
-
var u =
|
|
1938
|
-
u !== a && (a = u,
|
|
1939
|
-
}, 10),
|
|
2190
|
+
_handleAutoScroll: function(n, i) {
|
|
2191
|
+
var r = this, o = (n.touches ? n.touches[0] : n).clientX, l = (n.touches ? n.touches[0] : n).clientY, s = document.elementFromPoint(o, l);
|
|
2192
|
+
if (ct = n, i || this.options.forceAutoScrollFallback || He || ue || Me) {
|
|
2193
|
+
Ct(n, this.options, s, i);
|
|
2194
|
+
var a = pe(s, !0);
|
|
2195
|
+
Ft && (!xe || o !== It || l !== Ot) && (xe && dn(), xe = setInterval(function() {
|
|
2196
|
+
var u = pe(document.elementFromPoint(o, l), !0);
|
|
2197
|
+
u !== a && (a = u, tt()), Ct(n, r.options, u, i);
|
|
2198
|
+
}, 10), It = o, Ot = l);
|
|
1940
2199
|
} else {
|
|
1941
|
-
if (!this.options.bubbleScroll ||
|
|
1942
|
-
|
|
2200
|
+
if (!this.options.bubbleScroll || pe(s, !0) === re()) {
|
|
2201
|
+
tt();
|
|
1943
2202
|
return;
|
|
1944
2203
|
}
|
|
1945
|
-
|
|
2204
|
+
Ct(n, this.options, pe(s, !1), !1);
|
|
1946
2205
|
}
|
|
1947
2206
|
}
|
|
1948
|
-
},
|
|
2207
|
+
}, se(e, {
|
|
1949
2208
|
pluginName: "scroll",
|
|
1950
2209
|
initializeByDefault: !0
|
|
1951
2210
|
});
|
|
1952
2211
|
}
|
|
1953
|
-
function
|
|
1954
|
-
|
|
1955
|
-
clearInterval(
|
|
1956
|
-
}),
|
|
2212
|
+
function tt() {
|
|
2213
|
+
H.forEach(function(e) {
|
|
2214
|
+
clearInterval(e.pid);
|
|
2215
|
+
}), H = [];
|
|
1957
2216
|
}
|
|
1958
|
-
function
|
|
1959
|
-
clearInterval(
|
|
2217
|
+
function dn() {
|
|
2218
|
+
clearInterval(xe);
|
|
1960
2219
|
}
|
|
1961
|
-
var
|
|
1962
|
-
if (
|
|
1963
|
-
var r = (
|
|
1964
|
-
|
|
1965
|
-
var
|
|
2220
|
+
var Ct = In(function(e, t, n, i) {
|
|
2221
|
+
if (t.scroll) {
|
|
2222
|
+
var r = (e.touches ? e.touches[0] : e).clientX, o = (e.touches ? e.touches[0] : e).clientY, l = t.scrollSensitivity, s = t.scrollSpeed, a = re(), u = !1, c;
|
|
2223
|
+
Vt !== n && (Vt = n, tt(), ke = t.scroll, c = t.scrollFn, ke === !0 && (ke = pe(n, !0)));
|
|
2224
|
+
var d = 0, m = ke;
|
|
1966
2225
|
do {
|
|
1967
|
-
var
|
|
1968
|
-
|
|
1969
|
-
var
|
|
1970
|
-
if (!
|
|
1971
|
-
for (var
|
|
1972
|
-
|
|
1973
|
-
(
|
|
1974
|
-
|
|
1975
|
-
var
|
|
1976
|
-
typeof
|
|
2226
|
+
var y = m, S = j(y), p = S.top, f = S.bottom, T = S.left, D = S.right, w = S.width, g = S.height, B = void 0, I = void 0, P = y.scrollWidth, L = y.scrollHeight, R = v(y), _ = y.scrollLeft, V = y.scrollTop;
|
|
2227
|
+
y === a ? (B = w < P && (R.overflowX === "auto" || R.overflowX === "scroll" || R.overflowX === "visible"), I = g < L && (R.overflowY === "auto" || R.overflowY === "scroll" || R.overflowY === "visible")) : (B = w < P && (R.overflowX === "auto" || R.overflowX === "scroll"), I = g < L && (R.overflowY === "auto" || R.overflowY === "scroll"));
|
|
2228
|
+
var x = B && (Math.abs(D - r) <= l && _ + w < P) - (Math.abs(T - r) <= l && !!_), N = I && (Math.abs(f - o) <= l && V + g < L) - (Math.abs(p - o) <= l && !!V);
|
|
2229
|
+
if (!H[d])
|
|
2230
|
+
for (var K = 0; K <= d; K++)
|
|
2231
|
+
H[K] || (H[K] = {});
|
|
2232
|
+
(H[d].vx != x || H[d].vy != N || H[d].el !== y) && (H[d].el = y, H[d].vx = x, H[d].vy = N, clearInterval(H[d].pid), (x != 0 || N != 0) && (u = !0, H[d].pid = setInterval((function() {
|
|
2233
|
+
i && this.layer === 0 && b.active._onTouchMove(ct);
|
|
2234
|
+
var ce = H[this.layer].vy ? H[this.layer].vy * s : 0, F = H[this.layer].vx ? H[this.layer].vx * s : 0;
|
|
2235
|
+
typeof c == "function" && c.call(b.dragged.parentNode[Z], F, ce, e, ct, H[this.layer].el) !== "continue" || On(H[this.layer].el, F, ce);
|
|
1977
2236
|
}).bind({
|
|
1978
|
-
layer:
|
|
1979
|
-
}), 24))),
|
|
1980
|
-
} while (
|
|
1981
|
-
|
|
2237
|
+
layer: d
|
|
2238
|
+
}), 24))), d++;
|
|
2239
|
+
} while (t.bubbleScroll && m !== a && (m = pe(m, !1)));
|
|
2240
|
+
Ft = u;
|
|
1982
2241
|
}
|
|
1983
|
-
}, 30),
|
|
1984
|
-
var
|
|
1985
|
-
if (
|
|
1986
|
-
var u =
|
|
2242
|
+
}, 30), $n = function(t) {
|
|
2243
|
+
var n = t.originalEvent, i = t.putSortable, r = t.dragEl, o = t.activeSortable, l = t.dispatchSortableEvent, s = t.hideGhostForTarget, a = t.unhideGhostForTarget;
|
|
2244
|
+
if (n) {
|
|
2245
|
+
var u = i || o;
|
|
1987
2246
|
s();
|
|
1988
|
-
var
|
|
1989
|
-
a(), u && !u.el.contains(
|
|
2247
|
+
var c = n.changedTouches && n.changedTouches.length ? n.changedTouches[0] : n, d = document.elementFromPoint(c.clientX, c.clientY);
|
|
2248
|
+
a(), u && !u.el.contains(d) && (l("spill"), this.onSpill({
|
|
1990
2249
|
dragEl: r,
|
|
1991
|
-
putSortable:
|
|
2250
|
+
putSortable: i
|
|
1992
2251
|
}));
|
|
1993
2252
|
}
|
|
1994
2253
|
};
|
|
1995
|
-
function
|
|
2254
|
+
function Bt() {
|
|
1996
2255
|
}
|
|
1997
|
-
|
|
2256
|
+
Bt.prototype = {
|
|
1998
2257
|
startIndex: null,
|
|
1999
|
-
dragStart: function(
|
|
2000
|
-
var
|
|
2001
|
-
this.startIndex =
|
|
2258
|
+
dragStart: function(t) {
|
|
2259
|
+
var n = t.oldDraggableIndex;
|
|
2260
|
+
this.startIndex = n;
|
|
2002
2261
|
},
|
|
2003
|
-
onSpill: function(
|
|
2004
|
-
var
|
|
2005
|
-
this.sortable.captureAnimationState(),
|
|
2006
|
-
var r =
|
|
2007
|
-
r ? this.sortable.el.insertBefore(
|
|
2262
|
+
onSpill: function(t) {
|
|
2263
|
+
var n = t.dragEl, i = t.putSortable;
|
|
2264
|
+
this.sortable.captureAnimationState(), i && i.captureAnimationState();
|
|
2265
|
+
var r = Oe(this.sortable.el, this.startIndex, this.options);
|
|
2266
|
+
r ? this.sortable.el.insertBefore(n, r) : this.sortable.el.appendChild(n), this.sortable.animateAll(), i && i.animateAll();
|
|
2008
2267
|
},
|
|
2009
|
-
drop:
|
|
2268
|
+
drop: $n
|
|
2010
2269
|
};
|
|
2011
|
-
|
|
2270
|
+
se(Bt, {
|
|
2012
2271
|
pluginName: "revertOnSpill"
|
|
2013
2272
|
});
|
|
2014
|
-
function
|
|
2273
|
+
function Wt() {
|
|
2015
2274
|
}
|
|
2016
|
-
|
|
2017
|
-
onSpill: function(
|
|
2018
|
-
var
|
|
2019
|
-
r.captureAnimationState(),
|
|
2275
|
+
Wt.prototype = {
|
|
2276
|
+
onSpill: function(t) {
|
|
2277
|
+
var n = t.dragEl, i = t.putSortable, r = i || this.sortable;
|
|
2278
|
+
r.captureAnimationState(), n.parentNode && n.parentNode.removeChild(n), r.animateAll();
|
|
2020
2279
|
},
|
|
2021
|
-
drop:
|
|
2280
|
+
drop: $n
|
|
2022
2281
|
};
|
|
2023
|
-
|
|
2282
|
+
se(Wt, {
|
|
2024
2283
|
pluginName: "removeOnSpill"
|
|
2025
2284
|
});
|
|
2026
|
-
b.mount(new
|
|
2027
|
-
b.mount(
|
|
2028
|
-
const
|
|
2029
|
-
const r =
|
|
2030
|
-
let o = null, l =
|
|
2031
|
-
|
|
2285
|
+
b.mount(new Gr());
|
|
2286
|
+
b.mount(Wt, Bt);
|
|
2287
|
+
const Ur = (e, t, n, i) => {
|
|
2288
|
+
const r = pn(e, "dragSort");
|
|
2289
|
+
let o = null, l = $e(0);
|
|
2290
|
+
Gt(
|
|
2032
2291
|
r,
|
|
2033
2292
|
(u) => {
|
|
2034
|
-
|
|
2293
|
+
Ie(() => {
|
|
2035
2294
|
u ? s() : a();
|
|
2036
2295
|
});
|
|
2037
2296
|
},
|
|
2038
2297
|
{
|
|
2039
2298
|
immediate: !0
|
|
2040
2299
|
}
|
|
2041
|
-
),
|
|
2042
|
-
|
|
2300
|
+
), Gt(i, (u, c) => {
|
|
2301
|
+
Ie(() => {
|
|
2043
2302
|
r.value ? s() : a();
|
|
2044
2303
|
});
|
|
2045
2304
|
});
|
|
2046
2305
|
const s = () => {
|
|
2047
|
-
const u =
|
|
2306
|
+
const u = n.value;
|
|
2048
2307
|
u.style.cursor = "move", o = b.create(u, {
|
|
2049
2308
|
draggable: ".selected-item.enable",
|
|
2050
2309
|
//指定样式类的元素才允许拖动
|
|
2051
2310
|
animation: 300,
|
|
2052
2311
|
//过渡动画时间
|
|
2053
2312
|
//拖拽结束时事件
|
|
2054
|
-
onEnd: (
|
|
2055
|
-
const
|
|
2056
|
-
m.splice(
|
|
2057
|
-
const
|
|
2058
|
-
m.splice(
|
|
2313
|
+
onEnd: (c) => {
|
|
2314
|
+
const d = JSON.parse(JSON.stringify(i.value)), m = JSON.parse(JSON.stringify(i.value));
|
|
2315
|
+
m.splice(c.oldIndex, 1)[0];
|
|
2316
|
+
const y = d[c.oldIndex];
|
|
2317
|
+
m.splice(c.newIndex, 0, y), t("update:modelValue", m), l.value = Date.now(), t("sortEnd", d, m, c.oldIndex, c.newIndex);
|
|
2059
2318
|
}
|
|
2060
2319
|
});
|
|
2061
2320
|
}, a = () => {
|
|
2062
|
-
const u =
|
|
2321
|
+
const u = n.value;
|
|
2063
2322
|
u.style.cursor = "default", o == null || o.option("disabled", !0);
|
|
2064
2323
|
};
|
|
2065
2324
|
return { timeStamp: l };
|
|
2066
|
-
},
|
|
2325
|
+
}, Kr = {
|
|
2067
2326
|
key: 0,
|
|
2068
2327
|
class: "selected-number-header"
|
|
2069
|
-
},
|
|
2328
|
+
}, qr = { class: "selected-num" }, Jr = { class: "name" }, Zr = { class: "name" }, Qr = ["infinite-scroll-disabled"], eo = { class: "selected-group" }, to = { class: "name" }, no = /* @__PURE__ */ Zn({
|
|
2070
2329
|
__name: "Index",
|
|
2071
2330
|
props: {
|
|
2072
2331
|
width: { default: "100%" },
|
|
@@ -2087,171 +2346,171 @@ const Ln = (t, e, i, n) => {
|
|
|
2087
2346
|
hideHeader: { type: Boolean, default: !1 }
|
|
2088
2347
|
},
|
|
2089
2348
|
emits: ["update:modelValue", "item-remove", "remove-all", "sortEnd", "update:infiniteDisabled"],
|
|
2090
|
-
setup(
|
|
2091
|
-
|
|
2349
|
+
setup(e, { expose: t, emit: n }) {
|
|
2350
|
+
Qn((f) => ({
|
|
2092
2351
|
"9fdfd546": o.value
|
|
2093
2352
|
}));
|
|
2094
|
-
const
|
|
2095
|
-
|
|
2096
|
-
const p =
|
|
2097
|
-
return
|
|
2353
|
+
const i = e, r = n, o = it(() => i.itemHeight + "px"), l = it(() => i.dragSort || i.infiniteScroll ? !1 : i.virtual), { selectListRef: s, $list: a, disabledFlag: u, itemGroups: c, selectedLabel: d, itemRemove: m, removeAll: y, infiniteLoad: S } = Sr(i, r);
|
|
2354
|
+
Ur(i, r, a, c);
|
|
2355
|
+
const p = $e(!0);
|
|
2356
|
+
return hn(() => {
|
|
2098
2357
|
p.value = !1, setTimeout(() => {
|
|
2099
2358
|
p.value = !0;
|
|
2100
2359
|
}, 300);
|
|
2101
|
-
}),
|
|
2360
|
+
}), t({
|
|
2102
2361
|
infiniteLoad: S
|
|
2103
|
-
}), (
|
|
2104
|
-
const
|
|
2105
|
-
return
|
|
2362
|
+
}), (f, T) => {
|
|
2363
|
+
const D = Gi;
|
|
2364
|
+
return z(), X("div", {
|
|
2106
2365
|
ref_key: "selectListRef",
|
|
2107
2366
|
ref: s,
|
|
2108
2367
|
class: "das-ui-select-list",
|
|
2109
|
-
style:
|
|
2368
|
+
style: fn({ width: f.width, height: f.height, ...f.customStyle })
|
|
2110
2369
|
}, [
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2370
|
+
f.hideHeader ? Q("", !0) : (z(), X("div", Kr, [
|
|
2371
|
+
Ae("div", qr, Ne(O(d)), 1),
|
|
2372
|
+
f.isView ? Q("", !0) : (z(), le(O(ei), {
|
|
2114
2373
|
key: 0,
|
|
2115
2374
|
"btn-type": "primary-text",
|
|
2116
2375
|
block: "",
|
|
2117
|
-
onClick:
|
|
2118
|
-
disabled: !
|
|
2376
|
+
onClick: O(y),
|
|
2377
|
+
disabled: !O(c) || !O(c).length
|
|
2119
2378
|
}, {
|
|
2120
|
-
default:
|
|
2121
|
-
|
|
2379
|
+
default: nt(() => [
|
|
2380
|
+
Be(Ne(O(Ue)("das-select-list-removeAll").value), 1)
|
|
2122
2381
|
]),
|
|
2123
2382
|
_: 1
|
|
2124
2383
|
}, 8, ["onClick", "disabled"]))
|
|
2125
2384
|
])),
|
|
2126
|
-
!
|
|
2385
|
+
!f.infiniteScroll && !l.value ? Ee((z(), X("div", {
|
|
2127
2386
|
key: 1,
|
|
2128
2387
|
ref_key: "$list",
|
|
2129
2388
|
ref: a,
|
|
2130
|
-
class: de(["selected-container", { "hide-header":
|
|
2389
|
+
class: de(["selected-container", { "hide-header": f.hideHeader }])
|
|
2131
2390
|
}, [
|
|
2132
|
-
(
|
|
2133
|
-
class: de(["selected-item", { disabled: !
|
|
2134
|
-
key:
|
|
2391
|
+
(z(!0), X(At, null, Nt(O(c), (w, g) => (z(), X("div", {
|
|
2392
|
+
class: de(["selected-item", { disabled: !f.isView && O(u)(w), enable: !f.isView && !O(u)(w) }]),
|
|
2393
|
+
key: w[f.valueKey] + g
|
|
2135
2394
|
}, [
|
|
2136
|
-
|
|
2395
|
+
f.dragSort ? (z(), le(O(ni), {
|
|
2137
2396
|
key: 0,
|
|
2138
2397
|
class: "drag-icon",
|
|
2139
2398
|
size: "medium",
|
|
2140
2399
|
style: { "margin-right": "8px" }
|
|
2141
2400
|
})) : Q("", !0),
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2401
|
+
Ae("div", Jr, [
|
|
2402
|
+
ye(f.$slots, "default", { item: w }, () => [
|
|
2403
|
+
Ee((z(), X("div", null, [
|
|
2404
|
+
Be(Ne(w[f.labelKey]), 1)
|
|
2146
2405
|
])), [
|
|
2147
|
-
[
|
|
2406
|
+
[O(mt)]
|
|
2148
2407
|
])
|
|
2149
2408
|
], !0)
|
|
2150
2409
|
]),
|
|
2151
|
-
|
|
2410
|
+
f.isView ? Q("", !0) : (z(), le(O(gt), {
|
|
2152
2411
|
key: 1,
|
|
2153
2412
|
size: "small",
|
|
2154
2413
|
class: "close-icon",
|
|
2155
|
-
"icon-color":
|
|
2156
|
-
onClick: (
|
|
2414
|
+
"icon-color": O(pt)("--das-ui-color-secondary"),
|
|
2415
|
+
onClick: (B) => O(m)(w)
|
|
2157
2416
|
}, null, 8, ["icon-color", "onClick"]))
|
|
2158
2417
|
], 2))), 128))
|
|
2159
2418
|
], 2)), [
|
|
2160
|
-
[
|
|
2419
|
+
[O(ti), { usePrevOverlay: !0 }]
|
|
2161
2420
|
]) : Q("", !0),
|
|
2162
|
-
!
|
|
2421
|
+
!f.dragSort && l.value ? (z(), X("div", {
|
|
2163
2422
|
key: 2,
|
|
2164
2423
|
ref_key: "$list",
|
|
2165
2424
|
ref: a,
|
|
2166
|
-
class: de(["selected-container", { "hide-header":
|
|
2425
|
+
class: de(["selected-container", { "hide-header": f.hideHeader }])
|
|
2167
2426
|
}, [
|
|
2168
|
-
p.value &&
|
|
2169
|
-
key:
|
|
2170
|
-
items:
|
|
2171
|
-
"item-size":
|
|
2172
|
-
"key-field":
|
|
2427
|
+
p.value && O(c).length > 0 ? (z(), le(O(Ht), {
|
|
2428
|
+
key: O(c).length,
|
|
2429
|
+
items: O(c),
|
|
2430
|
+
"item-size": f.itemHeight,
|
|
2431
|
+
"key-field": f.valueKey,
|
|
2173
2432
|
class: "virtual-list"
|
|
2174
2433
|
}, {
|
|
2175
|
-
default:
|
|
2176
|
-
(
|
|
2177
|
-
class: de(["selected-item", { disabled: !
|
|
2178
|
-
key:
|
|
2434
|
+
default: nt(({ item: w, index: g }) => [
|
|
2435
|
+
(z(), X("div", {
|
|
2436
|
+
class: de(["selected-item", { disabled: !f.isView && O(u)(w), enable: !f.isView && !O(u)(w) }]),
|
|
2437
|
+
key: w[f.valueKey]
|
|
2179
2438
|
}, [
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2439
|
+
Ae("div", Zr, [
|
|
2440
|
+
ye(f.$slots, "default", { item: w }, () => [
|
|
2441
|
+
Ee((z(), X("div", null, [
|
|
2442
|
+
Be(Ne(w[f.labelKey]), 1)
|
|
2184
2443
|
])), [
|
|
2185
|
-
[
|
|
2444
|
+
[O(mt)]
|
|
2186
2445
|
])
|
|
2187
2446
|
], !0)
|
|
2188
2447
|
]),
|
|
2189
|
-
|
|
2448
|
+
f.isView ? Q("", !0) : (z(), le(O(gt), {
|
|
2190
2449
|
key: 0,
|
|
2191
2450
|
size: "small",
|
|
2192
2451
|
class: "close-icon",
|
|
2193
|
-
"icon-color":
|
|
2194
|
-
onClick: (
|
|
2452
|
+
"icon-color": O(pt)("--das-ui-color-secondary"),
|
|
2453
|
+
onClick: (B) => O(m)(w)
|
|
2195
2454
|
}, null, 8, ["icon-color", "onClick"]))
|
|
2196
2455
|
], 2))
|
|
2197
2456
|
]),
|
|
2198
2457
|
_: 3
|
|
2199
2458
|
}, 8, ["items", "item-size", "key-field"])) : Q("", !0)
|
|
2200
2459
|
], 2)) : Q("", !0),
|
|
2201
|
-
!
|
|
2460
|
+
!f.dragSort && f.infiniteScroll ? Ee((z(), X("div", {
|
|
2202
2461
|
key: 3,
|
|
2203
2462
|
ref_key: "$list",
|
|
2204
2463
|
ref: a,
|
|
2205
|
-
class: de(["selected-container selected-page-container", { "hide-header":
|
|
2206
|
-
"infinite-scroll-disabled":
|
|
2464
|
+
class: de(["selected-container selected-page-container", { "hide-header": f.hideHeader }]),
|
|
2465
|
+
"infinite-scroll-disabled": f.infiniteDisabled,
|
|
2207
2466
|
style: { overflow: "overlay" }
|
|
2208
2467
|
}, [
|
|
2209
|
-
|
|
2210
|
-
(
|
|
2211
|
-
class: de(["selected-item", { disabled: !
|
|
2212
|
-
key:
|
|
2468
|
+
Ae("div", eo, [
|
|
2469
|
+
(z(!0), X(At, null, Nt(O(c), (w) => (z(), X("div", {
|
|
2470
|
+
class: de(["selected-item", { disabled: !f.isView && O(u)(w), enable: !f.isView && !O(u)(w) }]),
|
|
2471
|
+
key: w[f.valueKey]
|
|
2213
2472
|
}, [
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2473
|
+
Ae("div", to, [
|
|
2474
|
+
ye(f.$slots, "default", { item: w }, () => [
|
|
2475
|
+
Ee((z(), X("div", null, [
|
|
2476
|
+
Be(Ne(w[f.labelKey]), 1)
|
|
2218
2477
|
])), [
|
|
2219
|
-
[
|
|
2478
|
+
[O(mt)]
|
|
2220
2479
|
])
|
|
2221
2480
|
], !0)
|
|
2222
2481
|
]),
|
|
2223
|
-
|
|
2482
|
+
f.isView ? Q("", !0) : (z(), le(O(gt), {
|
|
2224
2483
|
key: 0,
|
|
2225
2484
|
size: "small",
|
|
2226
2485
|
class: "close-icon",
|
|
2227
|
-
"icon-color":
|
|
2228
|
-
onClick: (g) =>
|
|
2486
|
+
"icon-color": O(pt)("--das-ui-color-secondary"),
|
|
2487
|
+
onClick: (g) => O(m)(w)
|
|
2229
2488
|
}, null, 8, ["icon-color", "onClick"]))
|
|
2230
2489
|
], 2))), 128))
|
|
2231
2490
|
])
|
|
2232
|
-
], 10,
|
|
2233
|
-
[
|
|
2491
|
+
], 10, Qr)), [
|
|
2492
|
+
[D, O(S)]
|
|
2234
2493
|
]) : Q("", !0)
|
|
2235
2494
|
], 4);
|
|
2236
2495
|
};
|
|
2237
2496
|
}
|
|
2238
|
-
}),
|
|
2239
|
-
const
|
|
2240
|
-
for (const [
|
|
2241
|
-
i
|
|
2242
|
-
return
|
|
2243
|
-
},
|
|
2497
|
+
}), io = (e, t) => {
|
|
2498
|
+
const n = e.__vccOpts || e;
|
|
2499
|
+
for (const [i, r] of t)
|
|
2500
|
+
n[i] = r;
|
|
2501
|
+
return n;
|
|
2502
|
+
}, ro = /* @__PURE__ */ io(no, [["__scopeId", "data-v-f1ab7a71"]]), oo = {
|
|
2244
2503
|
"das-select-list-removeAll": { "zh-CN": "清空", en: "test" },
|
|
2245
2504
|
"das-select-list-selected": { "zh-CN": "已选", en: "test" },
|
|
2246
2505
|
"das-select-list-parentheses-left": { "zh-CN": "(", en: "test" },
|
|
2247
2506
|
"das-select-list-parentheses-right": { "zh-CN": ")", en: "test" }
|
|
2248
|
-
},
|
|
2507
|
+
}, lo = {
|
|
2249
2508
|
"--das-ui-select-list-hover-bg": { light: "#F2F2F2" },
|
|
2250
2509
|
"--das-ui-select-list-close-btn-hover": { light: "#5582F3" }
|
|
2251
|
-
},
|
|
2252
|
-
|
|
2253
|
-
|
|
2510
|
+
}, To = Vn(ro);
|
|
2511
|
+
Fn(oo);
|
|
2512
|
+
Ln(lo);
|
|
2254
2513
|
export {
|
|
2255
|
-
|
|
2256
|
-
|
|
2514
|
+
To as DasSelectList,
|
|
2515
|
+
To as default
|
|
2257
2516
|
};
|