@qy_better_lib/pc 0.2.18 → 0.2.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@qy_better_lib/pc.min.js +1 -1
- package/lib/node_modules/@ctrl/tinycolor/dist/module/conversion.js +115 -0
- package/lib/node_modules/@ctrl/tinycolor/dist/module/css-color-names.js +153 -0
- package/lib/node_modules/@ctrl/tinycolor/dist/module/format-input.js +68 -0
- package/lib/node_modules/@ctrl/tinycolor/dist/module/index.js +183 -0
- package/lib/node_modules/@ctrl/tinycolor/dist/module/util.js +32 -0
- package/lib/node_modules/@element-plus/icons-vue/dist/index.js +167 -0
- package/lib/node_modules/@vue/shared/dist/shared.esm-bundler.js +22 -0
- package/lib/node_modules/@vueuse/core/index.js +112 -0
- package/lib/node_modules/@vueuse/shared/index.js +68 -0
- package/lib/node_modules/element-plus/es/_virtual/plugin-vue_export-helper.js +9 -0
- package/lib/node_modules/element-plus/es/components/badge/index.js +7 -0
- package/lib/node_modules/element-plus/es/components/button/index.js +11 -0
- package/lib/node_modules/element-plus/es/components/icon/index.js +7 -0
- package/lib/node_modules/element-plus/es/components/input/index.js +7 -0
- package/lib/node_modules/element-plus/es/components/message/index.js +7 -0
- package/lib/node_modules/element-plus/es/components/message-box/index.js +10 -0
- package/lib/node_modules/element-plus/es/components/notification/index.js +7 -0
- package/lib/node_modules/element-plus/es/components/overlay/index.js +9 -0
- package/lib/node_modules/element-plus/es/constants/aria.js +9 -0
- package/lib/node_modules/element-plus/es/constants/event.js +6 -0
- package/lib/node_modules/element-plus/es/constants/size.js +4 -0
- package/lib/node_modules/element-plus/es/directives/trap-focus/index.js +32 -0
- package/lib/node_modules/element-plus/es/hooks/use-aria/index.js +14 -0
- package/lib/node_modules/element-plus/es/hooks/use-attrs/index.js +12 -0
- package/lib/node_modules/element-plus/es/hooks/use-composition/index.js +29 -0
- package/lib/node_modules/element-plus/es/hooks/use-cursor/index.js +39 -0
- package/lib/node_modules/element-plus/es/hooks/use-deprecated/index.js +10 -0
- package/lib/node_modules/element-plus/es/hooks/use-draggable/index.js +45 -0
- package/lib/node_modules/element-plus/es/hooks/use-empty-values/index.js +20 -0
- package/lib/node_modules/element-plus/es/hooks/use-escape-keydown/index.js +16 -0
- package/lib/node_modules/element-plus/es/hooks/use-focus-controller/index.js +34 -0
- package/lib/node_modules/element-plus/es/hooks/use-id/index.js +15 -0
- package/lib/node_modules/element-plus/es/hooks/use-locale/index.js +24 -0
- package/lib/node_modules/element-plus/es/hooks/use-lockscreen/index.js +30 -0
- package/lib/node_modules/element-plus/es/hooks/use-namespace/index.js +44 -0
- package/lib/node_modules/element-plus/es/hooks/use-prop/index.js +11 -0
- package/lib/node_modules/element-plus/es/hooks/use-same-target/index.js +16 -0
- package/lib/node_modules/element-plus/es/hooks/use-size/index.js +16 -0
- package/lib/node_modules/element-plus/es/hooks/use-z-index/index.js +22 -0
- package/lib/node_modules/element-plus/es/locale/lang/en.js +182 -0
- package/lib/node_modules/element-plus/es/utils/browser.js +6 -0
- package/lib/node_modules/element-plus/es/utils/dom/aria.js +29 -0
- package/lib/node_modules/element-plus/es/utils/dom/scroll.js +20 -0
- package/lib/node_modules/element-plus/es/utils/dom/style.js +45 -0
- package/lib/node_modules/element-plus/es/utils/error.js +14 -0
- package/lib/node_modules/element-plus/es/utils/i18n.js +4 -0
- package/lib/node_modules/element-plus/es/utils/objects.js +4 -0
- package/lib/node_modules/element-plus/es/utils/types.js +13 -0
- package/lib/node_modules/element-plus/es/utils/typescript.js +4 -0
- package/lib/node_modules/element-plus/es/utils/vue/icon.js +29 -0
- package/lib/node_modules/element-plus/es/utils/vue/install.js +17 -0
- package/lib/node_modules/element-plus/es/utils/vue/props/runtime.js +31 -0
- package/lib/node_modules/element-plus/es/utils/vue/validator.js +5 -0
- package/lib/node_modules/element-plus/es/utils/vue/vnode.js +5 -0
- package/lib/node_modules/lodash-es/_Hash.js +20 -0
- package/lib/node_modules/lodash-es/_ListCache.js +20 -0
- package/lib/node_modules/lodash-es/_Map.js +6 -0
- package/lib/node_modules/lodash-es/_MapCache.js +20 -0
- package/lib/node_modules/lodash-es/_Symbol.js +5 -0
- package/lib/node_modules/lodash-es/_apply.js +16 -0
- package/lib/node_modules/lodash-es/_arrayMap.js +8 -0
- package/lib/node_modules/lodash-es/_arrayPush.js +8 -0
- package/lib/node_modules/lodash-es/_assignValue.js +10 -0
- package/lib/node_modules/lodash-es/_assocIndexOf.js +10 -0
- package/lib/node_modules/lodash-es/_baseAssignValue.js +12 -0
- package/lib/node_modules/lodash-es/_baseFlatten.js +13 -0
- package/lib/node_modules/lodash-es/_baseGet.js +11 -0
- package/lib/node_modules/lodash-es/_baseGetTag.js +10 -0
- package/lib/node_modules/lodash-es/_baseHasIn.js +6 -0
- package/lib/node_modules/lodash-es/_baseIsArguments.js +9 -0
- package/lib/node_modules/lodash-es/_baseIsNative.js +16 -0
- package/lib/node_modules/lodash-es/_basePick.js +10 -0
- package/lib/node_modules/lodash-es/_basePickBy.js +13 -0
- package/lib/node_modules/lodash-es/_baseSet.js +24 -0
- package/lib/node_modules/lodash-es/_baseSetToString.js +14 -0
- package/lib/node_modules/lodash-es/_baseToString.js +18 -0
- package/lib/node_modules/lodash-es/_castPath.js +10 -0
- package/lib/node_modules/lodash-es/_coreJsData.js +5 -0
- package/lib/node_modules/lodash-es/_defineProperty.js +11 -0
- package/lib/node_modules/lodash-es/_flatRest.js +9 -0
- package/lib/node_modules/lodash-es/_freeGlobal.js +4 -0
- package/lib/node_modules/lodash-es/_getMapData.js +8 -0
- package/lib/node_modules/lodash-es/_getNative.js +9 -0
- package/lib/node_modules/lodash-es/_getRawTag.js +15 -0
- package/lib/node_modules/lodash-es/_getValue.js +6 -0
- package/lib/node_modules/lodash-es/_hasPath.js +19 -0
- package/lib/node_modules/lodash-es/_hashClear.js +7 -0
- package/lib/node_modules/lodash-es/_hashDelete.js +7 -0
- package/lib/node_modules/lodash-es/_hashGet.js +13 -0
- package/lib/node_modules/lodash-es/_hashHas.js +9 -0
- package/lib/node_modules/lodash-es/_hashSet.js +9 -0
- package/lib/node_modules/lodash-es/_isFlattenable.js +10 -0
- package/lib/node_modules/lodash-es/_isIndex.js +8 -0
- package/lib/node_modules/lodash-es/_isKey.js +12 -0
- package/lib/node_modules/lodash-es/_isKeyable.js +7 -0
- package/lib/node_modules/lodash-es/_isMasked.js +11 -0
- package/lib/node_modules/lodash-es/_listCacheClear.js +6 -0
- package/lib/node_modules/lodash-es/_listCacheDelete.js +12 -0
- package/lib/node_modules/lodash-es/_listCacheGet.js +8 -0
- package/lib/node_modules/lodash-es/_listCacheHas.js +7 -0
- package/lib/node_modules/lodash-es/_listCacheSet.js +8 -0
- package/lib/node_modules/lodash-es/_mapCacheClear.js +13 -0
- package/lib/node_modules/lodash-es/_mapCacheDelete.js +8 -0
- package/lib/node_modules/lodash-es/_mapCacheGet.js +7 -0
- package/lib/node_modules/lodash-es/_mapCacheHas.js +7 -0
- package/lib/node_modules/lodash-es/_mapCacheSet.js +8 -0
- package/lib/node_modules/lodash-es/_memoizeCapped.js +11 -0
- package/lib/node_modules/lodash-es/_nativeCreate.js +5 -0
- package/lib/node_modules/lodash-es/_objectToString.js +7 -0
- package/lib/node_modules/lodash-es/_overRest.js +15 -0
- package/lib/node_modules/lodash-es/_root.js +5 -0
- package/lib/node_modules/lodash-es/_setToString.js +6 -0
- package/lib/node_modules/lodash-es/_shortOut.js +16 -0
- package/lib/node_modules/lodash-es/_stringToPath.js +10 -0
- package/lib/node_modules/lodash-es/_toKey.js +10 -0
- package/lib/node_modules/lodash-es/_toSource.js +17 -0
- package/lib/node_modules/lodash-es/constant.js +8 -0
- package/lib/node_modules/lodash-es/eq.js +6 -0
- package/lib/node_modules/lodash-es/flatten.js +8 -0
- package/lib/node_modules/lodash-es/fromPairs.js +10 -0
- package/lib/node_modules/lodash-es/get.js +8 -0
- package/lib/node_modules/lodash-es/hasIn.js +8 -0
- package/lib/node_modules/lodash-es/identity.js +6 -0
- package/lib/node_modules/lodash-es/isArguments.js +10 -0
- package/lib/node_modules/lodash-es/isArray.js +4 -0
- package/lib/node_modules/lodash-es/isFunction.js +12 -0
- package/lib/node_modules/lodash-es/isLength.js +7 -0
- package/lib/node_modules/lodash-es/isNil.js +6 -0
- package/lib/node_modules/lodash-es/isObject.js +7 -0
- package/lib/node_modules/lodash-es/isObjectLike.js +6 -0
- package/lib/node_modules/lodash-es/isSymbol.js +9 -0
- package/lib/node_modules/lodash-es/memoize.js +18 -0
- package/lib/node_modules/lodash-es/pick.js +8 -0
- package/lib/node_modules/lodash-es/toString.js +7 -0
- package/lib/{utils → src/utils}/index.js +24 -22
- package/lib/styles/contextMenu.scss +3 -3
- package/package.json +1 -1
- package/lib/contextMenu/src/index.vue.js +0 -104
- package/lib/contextMenu/src/index.vue2.js +0 -4
- package/lib/describeView/src/index.vue.js +0 -81
- package/lib/describeView/src/index.vue2.js +0 -4
- package/lib/simpleVirtualList/src/index.vue.js +0 -84
- package/lib/simpleVirtualList/src/index.vue2.js +0 -4
- package/lib/tableExtend/src/colVisible.vue.js +0 -103
- package/lib/tableExtend/src/colVisible.vue2.js +0 -4
- package/lib/tableExtend/src/index.vue.js +0 -220
- package/lib/tableExtend/src/index.vue2.js +0 -4
- package/lib/tableExtend/src/valueCol.vue.js +0 -26
- package/lib/tableExtend/src/valueCol.vue2.js +0 -4
- package/lib/textButton/src/index.vue.js +0 -56
- package/lib/textButton/src/index.vue2.js +0 -4
- /package/lib/{contextMenu → src/contextMenu}/index.js +0 -0
- /package/lib/{describeView → src/describeView}/index.js +0 -0
- /package/lib/{index.js → src/index.js} +0 -0
- /package/lib/{simpleVirtualList → src/simpleVirtualList}/index.js +0 -0
- /package/lib/{tableExtend → src/tableExtend}/index.js +0 -0
- /package/lib/{tableExtend → src/tableExtend}/props.js +0 -0
- /package/lib/{tableExtend → src/tableExtend}/type.js +0 -0
- /package/lib/{tableExtend → src/tableExtend}/useTable.js +0 -0
- /package/lib/{textButton → src/textButton}/index.js +0 -0
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import { defineComponent as l, createElementBlock as a, openBlock as _, createElementVNode as e } from "vue";
|
|
2
|
+
/*! Element Plus Icons Vue v2.3.1 */
|
|
3
|
+
var s = /* @__PURE__ */ l({
|
|
4
|
+
name: "CircleCheck",
|
|
5
|
+
__name: "circle-check",
|
|
6
|
+
setup(r) {
|
|
7
|
+
return (t, c) => (_(), a("svg", {
|
|
8
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
9
|
+
viewBox: "0 0 1024 1024"
|
|
10
|
+
}, [
|
|
11
|
+
e("path", {
|
|
12
|
+
fill: "currentColor",
|
|
13
|
+
d: "M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"
|
|
14
|
+
}),
|
|
15
|
+
e("path", {
|
|
16
|
+
fill: "currentColor",
|
|
17
|
+
d: "M745.344 361.344a32 32 0 0 1 45.312 45.312l-288 288a32 32 0 0 1-45.312 0l-160-160a32 32 0 1 1 45.312-45.312L480 626.752l265.344-265.408z"
|
|
18
|
+
})
|
|
19
|
+
]));
|
|
20
|
+
}
|
|
21
|
+
}), g = s, u = /* @__PURE__ */ l({
|
|
22
|
+
name: "CircleCloseFilled",
|
|
23
|
+
__name: "circle-close-filled",
|
|
24
|
+
setup(r) {
|
|
25
|
+
return (t, c) => (_(), a("svg", {
|
|
26
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
27
|
+
viewBox: "0 0 1024 1024"
|
|
28
|
+
}, [
|
|
29
|
+
e("path", {
|
|
30
|
+
fill: "currentColor",
|
|
31
|
+
d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336z"
|
|
32
|
+
})
|
|
33
|
+
]));
|
|
34
|
+
}
|
|
35
|
+
}), h = u, i = /* @__PURE__ */ l({
|
|
36
|
+
name: "CircleClose",
|
|
37
|
+
__name: "circle-close",
|
|
38
|
+
setup(r) {
|
|
39
|
+
return (t, c) => (_(), a("svg", {
|
|
40
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
41
|
+
viewBox: "0 0 1024 1024"
|
|
42
|
+
}, [
|
|
43
|
+
e("path", {
|
|
44
|
+
fill: "currentColor",
|
|
45
|
+
d: "m466.752 512-90.496-90.496a32 32 0 0 1 45.248-45.248L512 466.752l90.496-90.496a32 32 0 1 1 45.248 45.248L557.248 512l90.496 90.496a32 32 0 1 1-45.248 45.248L512 557.248l-90.496 90.496a32 32 0 0 1-45.248-45.248z"
|
|
46
|
+
}),
|
|
47
|
+
e("path", {
|
|
48
|
+
fill: "currentColor",
|
|
49
|
+
d: "M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"
|
|
50
|
+
})
|
|
51
|
+
]));
|
|
52
|
+
}
|
|
53
|
+
}), C = i, o = /* @__PURE__ */ l({
|
|
54
|
+
name: "Close",
|
|
55
|
+
__name: "close",
|
|
56
|
+
setup(r) {
|
|
57
|
+
return (t, c) => (_(), a("svg", {
|
|
58
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
59
|
+
viewBox: "0 0 1024 1024"
|
|
60
|
+
}, [
|
|
61
|
+
e("path", {
|
|
62
|
+
fill: "currentColor",
|
|
63
|
+
d: "M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"
|
|
64
|
+
})
|
|
65
|
+
]));
|
|
66
|
+
}
|
|
67
|
+
}), x = o, n = /* @__PURE__ */ l({
|
|
68
|
+
name: "Hide",
|
|
69
|
+
__name: "hide",
|
|
70
|
+
setup(r) {
|
|
71
|
+
return (t, c) => (_(), a("svg", {
|
|
72
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
73
|
+
viewBox: "0 0 1024 1024"
|
|
74
|
+
}, [
|
|
75
|
+
e("path", {
|
|
76
|
+
fill: "currentColor",
|
|
77
|
+
d: "M876.8 156.8c0-9.6-3.2-16-9.6-22.4-6.4-6.4-12.8-9.6-22.4-9.6-9.6 0-16 3.2-22.4 9.6L736 220.8c-64-32-137.6-51.2-224-60.8-160 16-288 73.6-377.6 176C44.8 438.4 0 496 0 512s48 73.6 134.4 176c22.4 25.6 44.8 48 73.6 67.2l-86.4 89.6c-6.4 6.4-9.6 12.8-9.6 22.4 0 9.6 3.2 16 9.6 22.4 6.4 6.4 12.8 9.6 22.4 9.6 9.6 0 16-3.2 22.4-9.6l704-710.4c3.2-6.4 6.4-12.8 6.4-22.4Zm-646.4 528c-76.8-70.4-128-128-153.6-172.8 28.8-48 80-105.6 153.6-172.8C304 272 400 230.4 512 224c64 3.2 124.8 19.2 176 44.8l-54.4 54.4C598.4 300.8 560 288 512 288c-64 0-115.2 22.4-160 64s-64 96-64 160c0 48 12.8 89.6 35.2 124.8L256 707.2c-9.6-6.4-19.2-16-25.6-22.4Zm140.8-96c-12.8-22.4-19.2-48-19.2-76.8 0-44.8 16-83.2 48-112 32-28.8 67.2-48 112-48 28.8 0 54.4 6.4 73.6 19.2zM889.599 336c-12.8-16-28.8-28.8-41.6-41.6l-48 48c73.6 67.2 124.8 124.8 150.4 169.6-28.8 48-80 105.6-153.6 172.8-73.6 67.2-172.8 108.8-284.8 115.2-51.2-3.2-99.2-12.8-140.8-28.8l-48 48c57.6 22.4 118.4 38.4 188.8 44.8 160-16 288-73.6 377.6-176C979.199 585.6 1024 528 1024 512s-48.001-73.6-134.401-176Z"
|
|
78
|
+
}),
|
|
79
|
+
e("path", {
|
|
80
|
+
fill: "currentColor",
|
|
81
|
+
d: "M511.998 672c-12.8 0-25.6-3.2-38.4-6.4l-51.2 51.2c28.8 12.8 57.6 19.2 89.6 19.2 64 0 115.2-22.4 160-64 41.6-41.6 64-96 64-160 0-32-6.4-64-19.2-89.6l-51.2 51.2c3.2 12.8 6.4 25.6 6.4 38.4 0 44.8-16 83.2-48 112-32 28.8-67.2 48-112 48Z"
|
|
82
|
+
})
|
|
83
|
+
]));
|
|
84
|
+
}
|
|
85
|
+
}), L = n, p = /* @__PURE__ */ l({
|
|
86
|
+
name: "InfoFilled",
|
|
87
|
+
__name: "info-filled",
|
|
88
|
+
setup(r) {
|
|
89
|
+
return (t, c) => (_(), a("svg", {
|
|
90
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
91
|
+
viewBox: "0 0 1024 1024"
|
|
92
|
+
}, [
|
|
93
|
+
e("path", {
|
|
94
|
+
fill: "currentColor",
|
|
95
|
+
d: "M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64m67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344M590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.992 12.992 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z"
|
|
96
|
+
})
|
|
97
|
+
]));
|
|
98
|
+
}
|
|
99
|
+
}), M = p, v = /* @__PURE__ */ l({
|
|
100
|
+
name: "Loading",
|
|
101
|
+
__name: "loading",
|
|
102
|
+
setup(r) {
|
|
103
|
+
return (t, c) => (_(), a("svg", {
|
|
104
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
105
|
+
viewBox: "0 0 1024 1024"
|
|
106
|
+
}, [
|
|
107
|
+
e("path", {
|
|
108
|
+
fill: "currentColor",
|
|
109
|
+
d: "M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248zM828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0z"
|
|
110
|
+
})
|
|
111
|
+
]));
|
|
112
|
+
}
|
|
113
|
+
}), B = v, d = /* @__PURE__ */ l({
|
|
114
|
+
name: "SuccessFilled",
|
|
115
|
+
__name: "success-filled",
|
|
116
|
+
setup(r) {
|
|
117
|
+
return (t, c) => (_(), a("svg", {
|
|
118
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
119
|
+
viewBox: "0 0 1024 1024"
|
|
120
|
+
}, [
|
|
121
|
+
e("path", {
|
|
122
|
+
fill: "currentColor",
|
|
123
|
+
d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.272 38.272 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336z"
|
|
124
|
+
})
|
|
125
|
+
]));
|
|
126
|
+
}
|
|
127
|
+
}), z = d, w = /* @__PURE__ */ l({
|
|
128
|
+
name: "View",
|
|
129
|
+
__name: "view",
|
|
130
|
+
setup(r) {
|
|
131
|
+
return (t, c) => (_(), a("svg", {
|
|
132
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
133
|
+
viewBox: "0 0 1024 1024"
|
|
134
|
+
}, [
|
|
135
|
+
e("path", {
|
|
136
|
+
fill: "currentColor",
|
|
137
|
+
d: "M512 160c320 0 512 352 512 352S832 864 512 864 0 512 0 512s192-352 512-352m0 64c-225.28 0-384.128 208.064-436.8 288 52.608 79.872 211.456 288 436.8 288 225.28 0 384.128-208.064 436.8-288-52.608-79.872-211.456-288-436.8-288zm0 64a224 224 0 1 1 0 448 224 224 0 0 1 0-448m0 64a160.192 160.192 0 0 0-160 160c0 88.192 71.744 160 160 160s160-71.808 160-160-71.744-160-160-160"
|
|
138
|
+
})
|
|
139
|
+
]));
|
|
140
|
+
}
|
|
141
|
+
}), y = w, m = /* @__PURE__ */ l({
|
|
142
|
+
name: "WarningFilled",
|
|
143
|
+
__name: "warning-filled",
|
|
144
|
+
setup(r) {
|
|
145
|
+
return (t, c) => (_(), a("svg", {
|
|
146
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
147
|
+
viewBox: "0 0 1024 1024"
|
|
148
|
+
}, [
|
|
149
|
+
e("path", {
|
|
150
|
+
fill: "currentColor",
|
|
151
|
+
d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 192a58.432 58.432 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.432 58.432 0 0 0 512 256m0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4"
|
|
152
|
+
})
|
|
153
|
+
]));
|
|
154
|
+
}
|
|
155
|
+
}), F = m;
|
|
156
|
+
export {
|
|
157
|
+
g as CircleCheck,
|
|
158
|
+
C as CircleClose,
|
|
159
|
+
h as CircleCloseFilled,
|
|
160
|
+
x as Close,
|
|
161
|
+
L as Hide,
|
|
162
|
+
M as InfoFilled,
|
|
163
|
+
B as Loading,
|
|
164
|
+
z as SuccessFilled,
|
|
165
|
+
y as View,
|
|
166
|
+
F as WarningFilled
|
|
167
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @vue/shared v3.5.21
|
|
3
|
+
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
|
+
* @license MIT
|
|
5
|
+
**/
|
|
6
|
+
process.env.NODE_ENV !== "production" && Object.freeze({});
|
|
7
|
+
process.env.NODE_ENV !== "production" && Object.freeze([]);
|
|
8
|
+
const i = () => {
|
|
9
|
+
}, n = Object.prototype.hasOwnProperty, p = (e, t) => n.call(e, t), O = (e) => typeof e == "function", a = (e) => typeof e == "string", u = (e) => e !== null && typeof e == "object", o = (e) => {
|
|
10
|
+
const t = /* @__PURE__ */ Object.create(null);
|
|
11
|
+
return ((c) => t[c] || (t[c] = e(c)));
|
|
12
|
+
}, r = /-\w/g, l = o(
|
|
13
|
+
(e) => e.replace(r, (t) => t.slice(1).toUpperCase())
|
|
14
|
+
);
|
|
15
|
+
export {
|
|
16
|
+
i as NOOP,
|
|
17
|
+
l as camelize,
|
|
18
|
+
p as hasOwn,
|
|
19
|
+
O as isFunction,
|
|
20
|
+
u as isObject,
|
|
21
|
+
a as isString
|
|
22
|
+
};
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { tryOnScopeDispose as I, isString as P, noop as Q, resolveUnref as g, isClient as S, tryOnMounted as C, identity as T } from "../shared/index.js";
|
|
2
|
+
import { computedEager as K, computedEager as V, useTimeoutFn as q } from "../shared/index.js";
|
|
3
|
+
import { watch as w, ref as N } from "vue";
|
|
4
|
+
function E(e) {
|
|
5
|
+
var r;
|
|
6
|
+
const t = g(e);
|
|
7
|
+
return (r = t?.$el) != null ? r : t;
|
|
8
|
+
}
|
|
9
|
+
const h = S ? window : void 0;
|
|
10
|
+
function G(...e) {
|
|
11
|
+
let r, t, n, s;
|
|
12
|
+
if (P(e[0]) || Array.isArray(e[0]) ? ([t, n, s] = e, r = h) : [r, t, n, s] = e, !r)
|
|
13
|
+
return Q;
|
|
14
|
+
Array.isArray(t) || (t = [t]), Array.isArray(n) || (n = [n]);
|
|
15
|
+
const i = [], o = () => {
|
|
16
|
+
i.forEach((a) => a()), i.length = 0;
|
|
17
|
+
}, l = (a, u, c, O) => (a.addEventListener(u, c, O), () => a.removeEventListener(u, c, O)), p = w(() => [E(r), g(s)], ([a, u]) => {
|
|
18
|
+
o(), a && i.push(...t.flatMap((c) => n.map((O) => l(a, c, O, u))));
|
|
19
|
+
}, { immediate: !0, flush: "post" }), f = () => {
|
|
20
|
+
p(), o();
|
|
21
|
+
};
|
|
22
|
+
return I(f), f;
|
|
23
|
+
}
|
|
24
|
+
function j(e, r = !1) {
|
|
25
|
+
const t = N(), n = () => t.value = !!e();
|
|
26
|
+
return n(), C(n, r), t;
|
|
27
|
+
}
|
|
28
|
+
const d = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, v = "__vueuse_ssr_handlers__";
|
|
29
|
+
d[v] = d[v] || {};
|
|
30
|
+
var _ = Object.getOwnPropertySymbols, x = Object.prototype.hasOwnProperty, A = Object.prototype.propertyIsEnumerable, R = (e, r) => {
|
|
31
|
+
var t = {};
|
|
32
|
+
for (var n in e)
|
|
33
|
+
x.call(e, n) && r.indexOf(n) < 0 && (t[n] = e[n]);
|
|
34
|
+
if (e != null && _)
|
|
35
|
+
for (var n of _(e))
|
|
36
|
+
r.indexOf(n) < 0 && A.call(e, n) && (t[n] = e[n]);
|
|
37
|
+
return t;
|
|
38
|
+
};
|
|
39
|
+
function H(e, r, t = {}) {
|
|
40
|
+
const n = t, { window: s = h } = n, i = R(n, ["window"]);
|
|
41
|
+
let o;
|
|
42
|
+
const l = j(() => s && "ResizeObserver" in s), p = () => {
|
|
43
|
+
o && (o.disconnect(), o = void 0);
|
|
44
|
+
}, f = w(() => E(e), (u) => {
|
|
45
|
+
p(), l.value && s && u && (o = new ResizeObserver(r), o.observe(u, i));
|
|
46
|
+
}, { immediate: !0, flush: "post" }), a = () => {
|
|
47
|
+
p(), f();
|
|
48
|
+
};
|
|
49
|
+
return I(a), {
|
|
50
|
+
isSupported: l,
|
|
51
|
+
stop: a
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
var y;
|
|
55
|
+
(function(e) {
|
|
56
|
+
e.UP = "UP", e.RIGHT = "RIGHT", e.DOWN = "DOWN", e.LEFT = "LEFT", e.NONE = "NONE";
|
|
57
|
+
})(y || (y = {}));
|
|
58
|
+
var L = Object.defineProperty, m = Object.getOwnPropertySymbols, W = Object.prototype.hasOwnProperty, $ = Object.prototype.propertyIsEnumerable, b = (e, r, t) => r in e ? L(e, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[r] = t, B = (e, r) => {
|
|
59
|
+
for (var t in r || (r = {}))
|
|
60
|
+
W.call(r, t) && b(e, t, r[t]);
|
|
61
|
+
if (m)
|
|
62
|
+
for (var t of m(r))
|
|
63
|
+
$.call(r, t) && b(e, t, r[t]);
|
|
64
|
+
return e;
|
|
65
|
+
};
|
|
66
|
+
const z = {
|
|
67
|
+
easeInSine: [0.12, 0, 0.39, 0],
|
|
68
|
+
easeOutSine: [0.61, 1, 0.88, 1],
|
|
69
|
+
easeInOutSine: [0.37, 0, 0.63, 1],
|
|
70
|
+
easeInQuad: [0.11, 0, 0.5, 0],
|
|
71
|
+
easeOutQuad: [0.5, 1, 0.89, 1],
|
|
72
|
+
easeInOutQuad: [0.45, 0, 0.55, 1],
|
|
73
|
+
easeInCubic: [0.32, 0, 0.67, 0],
|
|
74
|
+
easeOutCubic: [0.33, 1, 0.68, 1],
|
|
75
|
+
easeInOutCubic: [0.65, 0, 0.35, 1],
|
|
76
|
+
easeInQuart: [0.5, 0, 0.75, 0],
|
|
77
|
+
easeOutQuart: [0.25, 1, 0.5, 1],
|
|
78
|
+
easeInOutQuart: [0.76, 0, 0.24, 1],
|
|
79
|
+
easeInQuint: [0.64, 0, 0.78, 0],
|
|
80
|
+
easeOutQuint: [0.22, 1, 0.36, 1],
|
|
81
|
+
easeInOutQuint: [0.83, 0, 0.17, 1],
|
|
82
|
+
easeInExpo: [0.7, 0, 0.84, 0],
|
|
83
|
+
easeOutExpo: [0.16, 1, 0.3, 1],
|
|
84
|
+
easeInOutExpo: [0.87, 0, 0.13, 1],
|
|
85
|
+
easeInCirc: [0.55, 0, 1, 0.45],
|
|
86
|
+
easeOutCirc: [0, 0.55, 0.45, 1],
|
|
87
|
+
easeInOutCirc: [0.85, 0, 0.15, 1],
|
|
88
|
+
easeInBack: [0.36, 0, 0.66, -0.56],
|
|
89
|
+
easeOutBack: [0.34, 1.56, 0.64, 1],
|
|
90
|
+
easeInOutBack: [0.68, -0.6, 0.32, 1.6]
|
|
91
|
+
};
|
|
92
|
+
B({
|
|
93
|
+
linear: T
|
|
94
|
+
}, z);
|
|
95
|
+
export {
|
|
96
|
+
y as SwipeDirection,
|
|
97
|
+
K as computedEager,
|
|
98
|
+
h as defaultWindow,
|
|
99
|
+
V as eagerComputed,
|
|
100
|
+
T as identity,
|
|
101
|
+
S as isClient,
|
|
102
|
+
P as isString,
|
|
103
|
+
Q as noop,
|
|
104
|
+
g as resolveUnref,
|
|
105
|
+
C as tryOnMounted,
|
|
106
|
+
I as tryOnScopeDispose,
|
|
107
|
+
E as unrefElement,
|
|
108
|
+
G as useEventListener,
|
|
109
|
+
H as useResizeObserver,
|
|
110
|
+
j as useSupported,
|
|
111
|
+
q as useTimeoutFn
|
|
112
|
+
};
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { shallowRef as _, watchEffect as g, readonly as p, getCurrentScope as w, onScopeDispose as m, unref as y, getCurrentInstance as P, onMounted as O, nextTick as $, ref as b } from "vue";
|
|
2
|
+
var h = Object.defineProperty, S = Object.defineProperties, j = Object.getOwnPropertyDescriptors, l = Object.getOwnPropertySymbols, C = Object.prototype.hasOwnProperty, D = Object.prototype.propertyIsEnumerable, f = (e, t, r) => t in e ? h(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, E = (e, t) => {
|
|
3
|
+
for (var r in t || (t = {}))
|
|
4
|
+
C.call(t, r) && f(e, r, t[r]);
|
|
5
|
+
if (l)
|
|
6
|
+
for (var r of l(t))
|
|
7
|
+
D.call(t, r) && f(e, r, t[r]);
|
|
8
|
+
return e;
|
|
9
|
+
}, T = (e, t) => S(e, j(t));
|
|
10
|
+
function M(e, t) {
|
|
11
|
+
var r;
|
|
12
|
+
const i = _();
|
|
13
|
+
return g(() => {
|
|
14
|
+
i.value = e();
|
|
15
|
+
}, T(E({}, t), {
|
|
16
|
+
flush: (r = void 0) != null ? r : "sync"
|
|
17
|
+
})), p(i);
|
|
18
|
+
}
|
|
19
|
+
var c;
|
|
20
|
+
const d = typeof window < "u", F = (e) => typeof e == "string", N = () => {
|
|
21
|
+
};
|
|
22
|
+
d && ((c = window?.navigator) != null && c.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
23
|
+
function I(e) {
|
|
24
|
+
return typeof e == "function" ? e() : y(e);
|
|
25
|
+
}
|
|
26
|
+
function R(e) {
|
|
27
|
+
return e;
|
|
28
|
+
}
|
|
29
|
+
function x(e) {
|
|
30
|
+
return w() ? (m(e), !0) : !1;
|
|
31
|
+
}
|
|
32
|
+
function U(e, t = !0) {
|
|
33
|
+
P() ? O(e) : t ? e() : $(e);
|
|
34
|
+
}
|
|
35
|
+
function V(e, t, r = {}) {
|
|
36
|
+
const {
|
|
37
|
+
immediate: i = !0
|
|
38
|
+
} = r, n = b(!1);
|
|
39
|
+
let o = null;
|
|
40
|
+
function u() {
|
|
41
|
+
o && (clearTimeout(o), o = null);
|
|
42
|
+
}
|
|
43
|
+
function s() {
|
|
44
|
+
n.value = !1, u();
|
|
45
|
+
}
|
|
46
|
+
function a(...v) {
|
|
47
|
+
u(), n.value = !0, o = setTimeout(() => {
|
|
48
|
+
n.value = !1, o = null, e(...v);
|
|
49
|
+
}, I(t));
|
|
50
|
+
}
|
|
51
|
+
return i && (n.value = !0, d && a()), x(s), {
|
|
52
|
+
isPending: p(n),
|
|
53
|
+
start: a,
|
|
54
|
+
stop: s
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
export {
|
|
58
|
+
M as computedEager,
|
|
59
|
+
M as eagerComputed,
|
|
60
|
+
R as identity,
|
|
61
|
+
d as isClient,
|
|
62
|
+
F as isString,
|
|
63
|
+
N as noop,
|
|
64
|
+
I as resolveUnref,
|
|
65
|
+
U as tryOnMounted,
|
|
66
|
+
x as tryOnScopeDispose,
|
|
67
|
+
V as useTimeoutFn
|
|
68
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import o from "./src/button2.js";
|
|
2
|
+
import t from "./src/button-group2.js";
|
|
3
|
+
import { withInstall as r, withNoopInstall as l } from "../../utils/vue/install.js";
|
|
4
|
+
const i = r(o, {
|
|
5
|
+
ButtonGroup: t
|
|
6
|
+
});
|
|
7
|
+
l(t);
|
|
8
|
+
export {
|
|
9
|
+
i as ElButton,
|
|
10
|
+
i as default
|
|
11
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import r from "./src/messageBox.js";
|
|
2
|
+
const o = r;
|
|
3
|
+
o.install = (e) => {
|
|
4
|
+
o._context = e._context, e.config.globalProperties.$msgbox = o, e.config.globalProperties.$messageBox = o, e.config.globalProperties.$alert = o.alert, e.config.globalProperties.$confirm = o.confirm, e.config.globalProperties.$prompt = o.prompt;
|
|
5
|
+
};
|
|
6
|
+
const s = o;
|
|
7
|
+
export {
|
|
8
|
+
s as ElMessageBox,
|
|
9
|
+
o as default
|
|
10
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { nextTick as u } from "vue";
|
|
2
|
+
import { obtainAllFocusableElements as r } from "../../utils/dom/aria.js";
|
|
3
|
+
import { EVENT_CODE as a } from "../../constants/aria.js";
|
|
4
|
+
const o = "_trap-focus-children", n = [], c = (t) => {
|
|
5
|
+
if (n.length === 0)
|
|
6
|
+
return;
|
|
7
|
+
const e = n[n.length - 1][o];
|
|
8
|
+
if (e.length > 0 && t.code === a.tab) {
|
|
9
|
+
if (e.length === 1) {
|
|
10
|
+
t.preventDefault(), document.activeElement !== e[0] && e[0].focus();
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
const s = t.shiftKey, f = t.target === e[0], i = t.target === e[e.length - 1];
|
|
14
|
+
f && s && (t.preventDefault(), e[e.length - 1].focus()), i && !s && (t.preventDefault(), e[0].focus());
|
|
15
|
+
}
|
|
16
|
+
}, g = {
|
|
17
|
+
beforeMount(t) {
|
|
18
|
+
t[o] = r(t), n.push(t), n.length <= 1 && document.addEventListener("keydown", c);
|
|
19
|
+
},
|
|
20
|
+
updated(t) {
|
|
21
|
+
u(() => {
|
|
22
|
+
t[o] = r(t);
|
|
23
|
+
});
|
|
24
|
+
},
|
|
25
|
+
unmounted() {
|
|
26
|
+
n.shift(), n.length === 0 && document.removeEventListener("keydown", c);
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
o as FOCUSABLE_CHILDREN,
|
|
31
|
+
g as default
|
|
32
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { buildProps as i } from "../../utils/vue/props/runtime.js";
|
|
2
|
+
import o from "../../../../lodash-es/pick.js";
|
|
3
|
+
const t = i({
|
|
4
|
+
ariaLabel: String,
|
|
5
|
+
ariaOrientation: {
|
|
6
|
+
type: String,
|
|
7
|
+
values: ["horizontal", "vertical", "undefined"]
|
|
8
|
+
},
|
|
9
|
+
ariaControls: String
|
|
10
|
+
}), e = (r) => o(t, r);
|
|
11
|
+
export {
|
|
12
|
+
t as ariaProps,
|
|
13
|
+
e as useAriaProps
|
|
14
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { computed as t, getCurrentInstance as u } from "vue";
|
|
2
|
+
import a from "../../../../lodash-es/fromPairs.js";
|
|
3
|
+
const i = ["class", "style"], E = /^on[A-Z]/, m = (o = {}) => {
|
|
4
|
+
const { excludeListeners: c = !1, excludeKeys: e } = o, l = t(() => (e?.value || []).concat(i)), r = u();
|
|
5
|
+
return r ? t(() => {
|
|
6
|
+
var s;
|
|
7
|
+
return a(Object.entries((s = r.proxy) == null ? void 0 : s.$attrs).filter(([n]) => !l.value.includes(n) && !(c && E.test(n))));
|
|
8
|
+
}) : t(() => ({}));
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
m as useAttrs
|
|
12
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ref as c, nextTick as d } from "vue";
|
|
2
|
+
import { isKorean as u } from "../../utils/i18n.js";
|
|
3
|
+
function h({
|
|
4
|
+
afterComposition: p,
|
|
5
|
+
emit: n
|
|
6
|
+
}) {
|
|
7
|
+
const t = c(!1), r = (o) => {
|
|
8
|
+
n?.("compositionstart", o), t.value = !0;
|
|
9
|
+
}, i = (o) => {
|
|
10
|
+
var a;
|
|
11
|
+
n?.("compositionupdate", o);
|
|
12
|
+
const l = (a = o.target) == null ? void 0 : a.value, e = l[l.length - 1] || "";
|
|
13
|
+
t.value = !u(e);
|
|
14
|
+
}, s = (o) => {
|
|
15
|
+
n?.("compositionend", o), t.value && (t.value = !1, d(() => p(o)));
|
|
16
|
+
};
|
|
17
|
+
return {
|
|
18
|
+
isComposing: t,
|
|
19
|
+
handleComposition: (o) => {
|
|
20
|
+
o.type === "compositionend" ? s(o) : i(o);
|
|
21
|
+
},
|
|
22
|
+
handleCompositionStart: r,
|
|
23
|
+
handleCompositionUpdate: i,
|
|
24
|
+
handleCompositionEnd: s
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
h as useComposition
|
|
29
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
function u(r) {
|
|
2
|
+
let l;
|
|
3
|
+
function a() {
|
|
4
|
+
if (r.value == null)
|
|
5
|
+
return;
|
|
6
|
+
const { selectionStart: e, selectionEnd: t, value: n } = r.value;
|
|
7
|
+
if (e == null || t == null)
|
|
8
|
+
return;
|
|
9
|
+
const s = n.slice(0, Math.max(0, e)), o = n.slice(Math.max(0, t));
|
|
10
|
+
l = {
|
|
11
|
+
selectionStart: e,
|
|
12
|
+
selectionEnd: t,
|
|
13
|
+
value: n,
|
|
14
|
+
beforeTxt: s,
|
|
15
|
+
afterTxt: o
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
function c() {
|
|
19
|
+
if (r.value == null || l == null)
|
|
20
|
+
return;
|
|
21
|
+
const { value: e } = r.value, { beforeTxt: t, afterTxt: n, selectionStart: s } = l;
|
|
22
|
+
if (t == null || n == null || s == null)
|
|
23
|
+
return;
|
|
24
|
+
let o = e.length;
|
|
25
|
+
if (e.endsWith(n))
|
|
26
|
+
o = e.length - n.length;
|
|
27
|
+
else if (e.startsWith(t))
|
|
28
|
+
o = t.length;
|
|
29
|
+
else {
|
|
30
|
+
const f = t[s - 1], i = e.indexOf(f, s - 1);
|
|
31
|
+
i !== -1 && (o = i + 1);
|
|
32
|
+
}
|
|
33
|
+
r.value.setSelectionRange(o, o);
|
|
34
|
+
}
|
|
35
|
+
return [a, c];
|
|
36
|
+
}
|
|
37
|
+
export {
|
|
38
|
+
u as useCursor
|
|
39
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { ref as P, onMounted as T, watchEffect as W, onBeforeUnmount as y } from "vue";
|
|
2
|
+
import { addUnit as w } from "../../utils/dom/style.js";
|
|
3
|
+
const U = (n, u, M, h) => {
|
|
4
|
+
const o = {
|
|
5
|
+
offsetX: 0,
|
|
6
|
+
offsetY: 0
|
|
7
|
+
}, a = P(!1), g = (t, e) => {
|
|
8
|
+
if (n.value) {
|
|
9
|
+
const { offsetX: f, offsetY: l } = o, s = n.value.getBoundingClientRect(), i = s.left, c = s.top, m = s.width, d = s.height, v = document.documentElement.clientWidth, L = document.documentElement.clientHeight, x = -i + f, D = -c + l, b = v - i - m + f, H = L - c - (d < L ? d : 0) + l;
|
|
10
|
+
h?.value || (t = Math.min(Math.max(t, x), b), e = Math.min(Math.max(e, D), H)), o.offsetX = t, o.offsetY = e, n.value.style.transform = `translate(${w(t)}, ${w(e)})`;
|
|
11
|
+
}
|
|
12
|
+
}, p = (t) => {
|
|
13
|
+
const e = t.clientX, f = t.clientY, { offsetX: l, offsetY: s } = o, i = (m) => {
|
|
14
|
+
a.value || (a.value = !0);
|
|
15
|
+
const d = l + m.clientX - e, v = s + m.clientY - f;
|
|
16
|
+
g(d, v);
|
|
17
|
+
}, c = () => {
|
|
18
|
+
a.value = !1, document.removeEventListener("mousemove", i), document.removeEventListener("mouseup", c);
|
|
19
|
+
};
|
|
20
|
+
document.addEventListener("mousemove", i), document.addEventListener("mouseup", c);
|
|
21
|
+
}, X = () => {
|
|
22
|
+
u.value && n.value && (u.value.addEventListener("mousedown", p), window.addEventListener("resize", r));
|
|
23
|
+
}, E = () => {
|
|
24
|
+
u.value && n.value && (u.value.removeEventListener("mousedown", p), window.removeEventListener("resize", r));
|
|
25
|
+
}, Y = () => {
|
|
26
|
+
o.offsetX = 0, o.offsetY = 0, n.value && (n.value.style.transform = "");
|
|
27
|
+
}, r = () => {
|
|
28
|
+
const { offsetX: t, offsetY: e } = o;
|
|
29
|
+
g(t, e);
|
|
30
|
+
};
|
|
31
|
+
return T(() => {
|
|
32
|
+
W(() => {
|
|
33
|
+
M.value ? X() : E();
|
|
34
|
+
});
|
|
35
|
+
}), y(() => {
|
|
36
|
+
E();
|
|
37
|
+
}), {
|
|
38
|
+
isDragging: a,
|
|
39
|
+
resetPosition: Y,
|
|
40
|
+
updatePosition: r
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
export {
|
|
44
|
+
U as useDraggable
|
|
45
|
+
};
|