@qy_better_lib/pc 0.2.20 → 0.2.22
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/contextMenu/src/index.vue.js +104 -0
- package/lib/contextMenu/src/index.vue2.js +4 -0
- package/lib/describeView/src/index.vue.js +81 -0
- package/lib/describeView/src/index.vue2.js +4 -0
- package/lib/simpleVirtualList/src/index.vue.js +84 -0
- package/lib/simpleVirtualList/src/index.vue2.js +4 -0
- package/lib/tableExtend/src/colVisible.vue.js +103 -0
- package/lib/tableExtend/src/colVisible.vue2.js +4 -0
- package/lib/tableExtend/src/index.vue.js +220 -0
- package/lib/tableExtend/src/index.vue2.js +4 -0
- package/lib/tableExtend/src/valueCol.vue.js +26 -0
- package/lib/tableExtend/src/valueCol.vue2.js +4 -0
- package/lib/textButton/src/index.vue.js +56 -0
- package/lib/textButton/src/index.vue2.js +4 -0
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/index.js +80 -0
- package/package.json +1 -1
- package/lib/node_modules/@ctrl/tinycolor/dist/module/conversion.js +0 -115
- package/lib/node_modules/@ctrl/tinycolor/dist/module/css-color-names.js +0 -153
- package/lib/node_modules/@ctrl/tinycolor/dist/module/format-input.js +0 -68
- package/lib/node_modules/@ctrl/tinycolor/dist/module/index.js +0 -183
- package/lib/node_modules/@ctrl/tinycolor/dist/module/util.js +0 -32
- package/lib/node_modules/@element-plus/icons-vue/dist/index.js +0 -167
- package/lib/node_modules/@vue/shared/dist/shared.esm-bundler.js +0 -22
- package/lib/node_modules/@vueuse/core/index.js +0 -112
- package/lib/node_modules/@vueuse/shared/index.js +0 -68
- package/lib/node_modules/element-plus/es/_virtual/plugin-vue_export-helper.js +0 -9
- package/lib/node_modules/element-plus/es/components/badge/index.js +0 -7
- package/lib/node_modules/element-plus/es/components/button/index.js +0 -11
- package/lib/node_modules/element-plus/es/components/icon/index.js +0 -7
- package/lib/node_modules/element-plus/es/components/input/index.js +0 -7
- package/lib/node_modules/element-plus/es/components/message/index.js +0 -7
- package/lib/node_modules/element-plus/es/components/message-box/index.js +0 -10
- package/lib/node_modules/element-plus/es/components/notification/index.js +0 -7
- package/lib/node_modules/element-plus/es/components/overlay/index.js +0 -9
- package/lib/node_modules/element-plus/es/constants/aria.js +0 -9
- package/lib/node_modules/element-plus/es/constants/event.js +0 -6
- package/lib/node_modules/element-plus/es/constants/size.js +0 -4
- package/lib/node_modules/element-plus/es/directives/trap-focus/index.js +0 -32
- package/lib/node_modules/element-plus/es/hooks/use-aria/index.js +0 -14
- package/lib/node_modules/element-plus/es/hooks/use-attrs/index.js +0 -12
- package/lib/node_modules/element-plus/es/hooks/use-composition/index.js +0 -29
- package/lib/node_modules/element-plus/es/hooks/use-cursor/index.js +0 -39
- package/lib/node_modules/element-plus/es/hooks/use-deprecated/index.js +0 -10
- package/lib/node_modules/element-plus/es/hooks/use-draggable/index.js +0 -45
- package/lib/node_modules/element-plus/es/hooks/use-empty-values/index.js +0 -20
- package/lib/node_modules/element-plus/es/hooks/use-escape-keydown/index.js +0 -16
- package/lib/node_modules/element-plus/es/hooks/use-focus-controller/index.js +0 -34
- package/lib/node_modules/element-plus/es/hooks/use-id/index.js +0 -15
- package/lib/node_modules/element-plus/es/hooks/use-locale/index.js +0 -24
- package/lib/node_modules/element-plus/es/hooks/use-lockscreen/index.js +0 -30
- package/lib/node_modules/element-plus/es/hooks/use-namespace/index.js +0 -44
- package/lib/node_modules/element-plus/es/hooks/use-prop/index.js +0 -11
- package/lib/node_modules/element-plus/es/hooks/use-same-target/index.js +0 -16
- package/lib/node_modules/element-plus/es/hooks/use-size/index.js +0 -16
- package/lib/node_modules/element-plus/es/hooks/use-z-index/index.js +0 -22
- package/lib/node_modules/element-plus/es/locale/lang/en.js +0 -182
- package/lib/node_modules/element-plus/es/utils/browser.js +0 -6
- package/lib/node_modules/element-plus/es/utils/dom/aria.js +0 -29
- package/lib/node_modules/element-plus/es/utils/dom/scroll.js +0 -20
- package/lib/node_modules/element-plus/es/utils/dom/style.js +0 -45
- package/lib/node_modules/element-plus/es/utils/error.js +0 -14
- package/lib/node_modules/element-plus/es/utils/i18n.js +0 -4
- package/lib/node_modules/element-plus/es/utils/objects.js +0 -4
- package/lib/node_modules/element-plus/es/utils/types.js +0 -13
- package/lib/node_modules/element-plus/es/utils/typescript.js +0 -4
- package/lib/node_modules/element-plus/es/utils/vue/icon.js +0 -29
- package/lib/node_modules/element-plus/es/utils/vue/install.js +0 -17
- package/lib/node_modules/element-plus/es/utils/vue/props/runtime.js +0 -31
- package/lib/node_modules/element-plus/es/utils/vue/validator.js +0 -5
- package/lib/node_modules/element-plus/es/utils/vue/vnode.js +0 -5
- package/lib/node_modules/lodash-es/_Hash.js +0 -20
- package/lib/node_modules/lodash-es/_ListCache.js +0 -20
- package/lib/node_modules/lodash-es/_Map.js +0 -6
- package/lib/node_modules/lodash-es/_MapCache.js +0 -20
- package/lib/node_modules/lodash-es/_Symbol.js +0 -5
- package/lib/node_modules/lodash-es/_apply.js +0 -16
- package/lib/node_modules/lodash-es/_arrayMap.js +0 -8
- package/lib/node_modules/lodash-es/_arrayPush.js +0 -8
- package/lib/node_modules/lodash-es/_assignValue.js +0 -10
- package/lib/node_modules/lodash-es/_assocIndexOf.js +0 -10
- package/lib/node_modules/lodash-es/_baseAssignValue.js +0 -12
- package/lib/node_modules/lodash-es/_baseFlatten.js +0 -13
- package/lib/node_modules/lodash-es/_baseGet.js +0 -11
- package/lib/node_modules/lodash-es/_baseGetTag.js +0 -10
- package/lib/node_modules/lodash-es/_baseHasIn.js +0 -6
- package/lib/node_modules/lodash-es/_baseIsArguments.js +0 -9
- package/lib/node_modules/lodash-es/_baseIsNative.js +0 -16
- package/lib/node_modules/lodash-es/_basePick.js +0 -10
- package/lib/node_modules/lodash-es/_basePickBy.js +0 -13
- package/lib/node_modules/lodash-es/_baseSet.js +0 -24
- package/lib/node_modules/lodash-es/_baseSetToString.js +0 -14
- package/lib/node_modules/lodash-es/_baseToString.js +0 -18
- package/lib/node_modules/lodash-es/_castPath.js +0 -10
- package/lib/node_modules/lodash-es/_coreJsData.js +0 -5
- package/lib/node_modules/lodash-es/_defineProperty.js +0 -11
- package/lib/node_modules/lodash-es/_flatRest.js +0 -9
- package/lib/node_modules/lodash-es/_freeGlobal.js +0 -4
- package/lib/node_modules/lodash-es/_getMapData.js +0 -8
- package/lib/node_modules/lodash-es/_getNative.js +0 -9
- package/lib/node_modules/lodash-es/_getRawTag.js +0 -15
- package/lib/node_modules/lodash-es/_getValue.js +0 -6
- package/lib/node_modules/lodash-es/_hasPath.js +0 -19
- package/lib/node_modules/lodash-es/_hashClear.js +0 -7
- package/lib/node_modules/lodash-es/_hashDelete.js +0 -7
- package/lib/node_modules/lodash-es/_hashGet.js +0 -13
- package/lib/node_modules/lodash-es/_hashHas.js +0 -9
- package/lib/node_modules/lodash-es/_hashSet.js +0 -9
- package/lib/node_modules/lodash-es/_isFlattenable.js +0 -10
- package/lib/node_modules/lodash-es/_isIndex.js +0 -8
- package/lib/node_modules/lodash-es/_isKey.js +0 -12
- package/lib/node_modules/lodash-es/_isKeyable.js +0 -7
- package/lib/node_modules/lodash-es/_isMasked.js +0 -11
- package/lib/node_modules/lodash-es/_listCacheClear.js +0 -6
- package/lib/node_modules/lodash-es/_listCacheDelete.js +0 -12
- package/lib/node_modules/lodash-es/_listCacheGet.js +0 -8
- package/lib/node_modules/lodash-es/_listCacheHas.js +0 -7
- package/lib/node_modules/lodash-es/_listCacheSet.js +0 -8
- package/lib/node_modules/lodash-es/_mapCacheClear.js +0 -13
- package/lib/node_modules/lodash-es/_mapCacheDelete.js +0 -8
- package/lib/node_modules/lodash-es/_mapCacheGet.js +0 -7
- package/lib/node_modules/lodash-es/_mapCacheHas.js +0 -7
- package/lib/node_modules/lodash-es/_mapCacheSet.js +0 -8
- package/lib/node_modules/lodash-es/_memoizeCapped.js +0 -11
- package/lib/node_modules/lodash-es/_nativeCreate.js +0 -5
- package/lib/node_modules/lodash-es/_objectToString.js +0 -7
- package/lib/node_modules/lodash-es/_overRest.js +0 -15
- package/lib/node_modules/lodash-es/_root.js +0 -5
- package/lib/node_modules/lodash-es/_setToString.js +0 -6
- package/lib/node_modules/lodash-es/_shortOut.js +0 -16
- package/lib/node_modules/lodash-es/_stringToPath.js +0 -10
- package/lib/node_modules/lodash-es/_toKey.js +0 -10
- package/lib/node_modules/lodash-es/_toSource.js +0 -17
- package/lib/node_modules/lodash-es/constant.js +0 -8
- package/lib/node_modules/lodash-es/eq.js +0 -6
- package/lib/node_modules/lodash-es/flatten.js +0 -8
- package/lib/node_modules/lodash-es/fromPairs.js +0 -10
- package/lib/node_modules/lodash-es/get.js +0 -8
- package/lib/node_modules/lodash-es/hasIn.js +0 -8
- package/lib/node_modules/lodash-es/identity.js +0 -6
- package/lib/node_modules/lodash-es/isArguments.js +0 -10
- package/lib/node_modules/lodash-es/isArray.js +0 -4
- package/lib/node_modules/lodash-es/isFunction.js +0 -12
- package/lib/node_modules/lodash-es/isLength.js +0 -7
- package/lib/node_modules/lodash-es/isNil.js +0 -6
- package/lib/node_modules/lodash-es/isObject.js +0 -7
- package/lib/node_modules/lodash-es/isObjectLike.js +0 -6
- package/lib/node_modules/lodash-es/isSymbol.js +0 -9
- package/lib/node_modules/lodash-es/memoize.js +0 -18
- package/lib/node_modules/lodash-es/pick.js +0 -8
- package/lib/node_modules/lodash-es/toString.js +0 -7
- package/lib/src/utils/index.js +0 -82
- /package/lib/{src/contextMenu → contextMenu}/index.js +0 -0
- /package/lib/{src/describeView → describeView}/index.js +0 -0
- /package/lib/{src/index.js → index.js} +0 -0
- /package/lib/{src/simpleVirtualList → simpleVirtualList}/index.js +0 -0
- /package/lib/{src/tableExtend → tableExtend}/index.js +0 -0
- /package/lib/{src/tableExtend → tableExtend}/props.js +0 -0
- /package/lib/{src/tableExtend → tableExtend}/type.js +0 -0
- /package/lib/{src/tableExtend → tableExtend}/useTable.js +0 -0
- /package/lib/{src/textButton → textButton}/index.js +0 -0
|
@@ -1,11 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,12 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,29 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,39 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,45 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import "vue";
|
|
2
|
-
import { buildProps as o, definePropType as t } from "../../utils/vue/props/runtime.js";
|
|
3
|
-
import { isFunction as r } from "../../../../@vue/shared/dist/shared.esm-bundler.js";
|
|
4
|
-
const m = Symbol("emptyValuesContextKey"), u = o({
|
|
5
|
-
emptyValues: Array,
|
|
6
|
-
valueOnClear: {
|
|
7
|
-
type: t([
|
|
8
|
-
String,
|
|
9
|
-
Number,
|
|
10
|
-
Boolean,
|
|
11
|
-
Function
|
|
12
|
-
]),
|
|
13
|
-
default: void 0,
|
|
14
|
-
validator: (e) => r(e) ? !e() : !e
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
export {
|
|
18
|
-
m as emptyValuesContextKey,
|
|
19
|
-
u as useEmptyValuesProps
|
|
20
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { onMounted as i, onBeforeUnmount as d } from "vue";
|
|
2
|
-
import { EVENT_CODE as s } from "../../constants/aria.js";
|
|
3
|
-
import { isClient as t } from "../../../../@vueuse/shared/index.js";
|
|
4
|
-
let e = [];
|
|
5
|
-
const r = (o) => {
|
|
6
|
-
o.code === s.esc && e.forEach((n) => n(o));
|
|
7
|
-
}, E = (o) => {
|
|
8
|
-
i(() => {
|
|
9
|
-
e.length === 0 && document.addEventListener("keydown", r), t && e.push(o);
|
|
10
|
-
}), d(() => {
|
|
11
|
-
e = e.filter((n) => n !== o), e.length === 0 && t && document.removeEventListener("keydown", r);
|
|
12
|
-
});
|
|
13
|
-
};
|
|
14
|
-
export {
|
|
15
|
-
E as useEscapeKeydown
|
|
16
|
-
};
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { getCurrentInstance as b, shallowRef as w, ref as x, watch as C, unref as l } from "vue";
|
|
2
|
-
import { useEventListener as c } from "../../../../@vueuse/core/index.js";
|
|
3
|
-
import { isFocusable as E } from "../../utils/dom/aria.js";
|
|
4
|
-
import { isFunction as p } from "../../../../@vue/shared/dist/shared.esm-bundler.js";
|
|
5
|
-
function T(h, {
|
|
6
|
-
disabled: r,
|
|
7
|
-
beforeFocus: a,
|
|
8
|
-
afterFocus: i,
|
|
9
|
-
beforeBlur: s,
|
|
10
|
-
afterBlur: f
|
|
11
|
-
} = {}) {
|
|
12
|
-
const g = b(), { emit: m } = g, n = w(), u = x(!1), v = (t) => {
|
|
13
|
-
const e = p(a) ? a(t) : !1;
|
|
14
|
-
l(r) || u.value || e || (u.value = !0, m("focus", t), i?.());
|
|
15
|
-
}, d = (t) => {
|
|
16
|
-
var e;
|
|
17
|
-
const o = p(s) ? s(t) : !1;
|
|
18
|
-
l(r) || t.relatedTarget && ((e = n.value) != null && e.contains(t.relatedTarget)) || o || (u.value = !1, m("blur", t), f?.());
|
|
19
|
-
}, F = (t) => {
|
|
20
|
-
var e, o;
|
|
21
|
-
l(r) || E(t.target) || (e = n.value) != null && e.contains(document.activeElement) && n.value !== document.activeElement || (o = h.value) == null || o.focus();
|
|
22
|
-
};
|
|
23
|
-
return C([n, () => l(r)], ([t, e]) => {
|
|
24
|
-
t && (e ? t.removeAttribute("tabindex") : t.setAttribute("tabindex", "-1"));
|
|
25
|
-
}), c(n, "focus", v, !0), c(n, "blur", d, !0), c(n, "click", F, !0), {
|
|
26
|
-
isFocused: u,
|
|
27
|
-
wrapperRef: n,
|
|
28
|
-
handleFocus: v,
|
|
29
|
-
handleBlur: d
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
export {
|
|
33
|
-
T as useFocusController
|
|
34
|
-
};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { inject as o, getCurrentInstance as c, unref as i } from "vue";
|
|
2
|
-
import { useGetDerivedNamespace as s } from "../use-namespace/index.js";
|
|
3
|
-
import { computedEager as d } from "../../../../@vueuse/shared/index.js";
|
|
4
|
-
const t = {
|
|
5
|
-
prefix: Math.floor(Math.random() * 1e4),
|
|
6
|
-
current: 0
|
|
7
|
-
}, u = Symbol("elIdInjection"), I = () => c() ? o(u, t) : t, j = (n) => {
|
|
8
|
-
const e = I(), r = s();
|
|
9
|
-
return d(() => i(n) || `${r.value}-id-${e.prefix}-${e.current++}`);
|
|
10
|
-
};
|
|
11
|
-
export {
|
|
12
|
-
u as ID_INJECTION_KEY,
|
|
13
|
-
j as useId,
|
|
14
|
-
I as useIdInjection
|
|
15
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { inject as a, ref as l, computed as c, unref as s, isRef as u } from "vue";
|
|
2
|
-
import m from "../../locale/lang/en.js";
|
|
3
|
-
import i from "../../../../lodash-es/get.js";
|
|
4
|
-
const f = (t) => (e, o) => d(e, o, s(t)), d = (t, e, o) => i(o, t, t).replace(/\{(\w+)\}/g, (x, n) => {
|
|
5
|
-
var r;
|
|
6
|
-
return `${(r = e?.[n]) != null ? r : `{${n}}`}`;
|
|
7
|
-
}), g = (t) => {
|
|
8
|
-
const e = c(() => s(t).name), o = u(t) ? t : l(t);
|
|
9
|
-
return {
|
|
10
|
-
lang: e,
|
|
11
|
-
locale: o,
|
|
12
|
-
t: f(t)
|
|
13
|
-
};
|
|
14
|
-
}, p = Symbol("localeContextKey"), y = (t) => {
|
|
15
|
-
const e = t || a(p, l());
|
|
16
|
-
return g(c(() => e.value || m));
|
|
17
|
-
};
|
|
18
|
-
export {
|
|
19
|
-
g as buildLocaleContext,
|
|
20
|
-
f as buildTranslator,
|
|
21
|
-
p as localeContextKey,
|
|
22
|
-
d as translate,
|
|
23
|
-
y as useLocale
|
|
24
|
-
};
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { isRef as a, computed as f, watch as p, onScopeDispose as y } from "vue";
|
|
2
|
-
import { useNamespace as h } from "../use-namespace/index.js";
|
|
3
|
-
import { throwError as b } from "../../utils/error.js";
|
|
4
|
-
import { hasClass as r, addClass as v, getStyle as w, removeClass as C } from "../../utils/dom/style.js";
|
|
5
|
-
import { getScrollBarWidth as H } from "../../utils/dom/scroll.js";
|
|
6
|
-
import { isClient as S } from "../../../../@vueuse/shared/index.js";
|
|
7
|
-
const E = (d, l = {}) => {
|
|
8
|
-
a(d) || b("[useLockscreen]", "You need to pass a ref param to this function");
|
|
9
|
-
const n = l.ns || h("popup"), e = f(() => n.bm("parent", "hidden"));
|
|
10
|
-
if (!S || r(document.body, e.value))
|
|
11
|
-
return;
|
|
12
|
-
let t = 0, o = !1, s = "0";
|
|
13
|
-
const c = () => {
|
|
14
|
-
setTimeout(() => {
|
|
15
|
-
typeof document > "u" || o && document && (document.body.style.width = s, C(document.body, e.value));
|
|
16
|
-
}, 200);
|
|
17
|
-
};
|
|
18
|
-
p(d, (i) => {
|
|
19
|
-
if (!i) {
|
|
20
|
-
c();
|
|
21
|
-
return;
|
|
22
|
-
}
|
|
23
|
-
o = !r(document.body, e.value), o && (s = document.body.style.width, v(document.body, e.value)), t = H(n.namespace.value);
|
|
24
|
-
const m = document.documentElement.clientHeight < document.body.scrollHeight, u = w(document.body, "overflowY");
|
|
25
|
-
t > 0 && (m || u === "scroll") && o && (document.body.style.width = `calc(100% - ${t}px)`);
|
|
26
|
-
}), y(() => c());
|
|
27
|
-
};
|
|
28
|
-
export {
|
|
29
|
-
E as useLockscreen
|
|
30
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { getCurrentInstance as p, inject as N, ref as v, computed as V, unref as y } from "vue";
|
|
2
|
-
const m = "el", l = "is-", c = (a, r, t, o, $) => {
|
|
3
|
-
let u = `${a}-${r}`;
|
|
4
|
-
return t && (u += `-${t}`), o && (u += `__${o}`), $ && (u += `--${$}`), u;
|
|
5
|
-
}, B = Symbol("namespaceContextKey"), C = (a) => {
|
|
6
|
-
const r = a || (p() ? N(B, v(m)) : v(m));
|
|
7
|
-
return V(() => y(r) || m);
|
|
8
|
-
}, q = (a, r) => {
|
|
9
|
-
const t = C(r);
|
|
10
|
-
return {
|
|
11
|
-
namespace: t,
|
|
12
|
-
b: (s = "") => c(t.value, a, s, "", ""),
|
|
13
|
-
e: (s) => s ? c(t.value, a, "", s, "") : "",
|
|
14
|
-
m: (s) => s ? c(t.value, a, "", "", s) : "",
|
|
15
|
-
be: (s, e) => s && e ? c(t.value, a, s, e, "") : "",
|
|
16
|
-
em: (s, e) => s && e ? c(t.value, a, "", s, e) : "",
|
|
17
|
-
bm: (s, e) => s && e ? c(t.value, a, s, "", e) : "",
|
|
18
|
-
bem: (s, e, n) => s && e && n ? c(t.value, a, s, e, n) : "",
|
|
19
|
-
is: (s, ...e) => {
|
|
20
|
-
const n = e.length >= 1 ? e[0] : !0;
|
|
21
|
-
return s && n ? `${l}${s}` : "";
|
|
22
|
-
},
|
|
23
|
-
cssVar: (s) => {
|
|
24
|
-
const e = {};
|
|
25
|
-
for (const n in s)
|
|
26
|
-
s[n] && (e[`--${t.value}-${n}`] = s[n]);
|
|
27
|
-
return e;
|
|
28
|
-
},
|
|
29
|
-
cssVarName: (s) => `--${t.value}-${s}`,
|
|
30
|
-
cssVarBlock: (s) => {
|
|
31
|
-
const e = {};
|
|
32
|
-
for (const n in s)
|
|
33
|
-
s[n] && (e[`--${t.value}-${a}-${n}`] = s[n]);
|
|
34
|
-
return e;
|
|
35
|
-
},
|
|
36
|
-
cssVarBlockName: (s) => `--${t.value}-${a}-${s}`
|
|
37
|
-
};
|
|
38
|
-
};
|
|
39
|
-
export {
|
|
40
|
-
m as defaultNamespace,
|
|
41
|
-
B as namespaceContextKey,
|
|
42
|
-
C as useGetDerivedNamespace,
|
|
43
|
-
q as useNamespace
|
|
44
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { NOOP as n } from "../../../../@vue/shared/dist/shared.esm-bundler.js";
|
|
2
|
-
const g = (r) => {
|
|
3
|
-
if (!r)
|
|
4
|
-
return { onClick: n, onMousedown: n, onMouseup: n };
|
|
5
|
-
let e = !1, t = !1;
|
|
6
|
-
return { onClick: (o) => {
|
|
7
|
-
e && t && r(o), e = t = !1;
|
|
8
|
-
}, onMousedown: (o) => {
|
|
9
|
-
e = o.target === o.currentTarget;
|
|
10
|
-
}, onMouseup: (o) => {
|
|
11
|
-
t = o.target === o.currentTarget;
|
|
12
|
-
} };
|
|
13
|
-
};
|
|
14
|
-
export {
|
|
15
|
-
g as useSameTarget
|
|
16
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { inject as o, computed as r, unref as t } from "vue";
|
|
2
|
-
import { buildProp as i } from "../../utils/vue/props/runtime.js";
|
|
3
|
-
import { componentSizes as n } from "../../constants/size.js";
|
|
4
|
-
const c = i({
|
|
5
|
-
type: String,
|
|
6
|
-
values: n,
|
|
7
|
-
required: !1
|
|
8
|
-
}), s = Symbol("size"), S = () => {
|
|
9
|
-
const e = o(s, {});
|
|
10
|
-
return r(() => t(e.size) || "");
|
|
11
|
-
};
|
|
12
|
-
export {
|
|
13
|
-
s as SIZE_INJECTION_KEY,
|
|
14
|
-
S as useGlobalSize,
|
|
15
|
-
c as useSizeProp
|
|
16
|
-
};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { getCurrentInstance as c, inject as n, computed as i, unref as m, ref as a } from "vue";
|
|
2
|
-
import { isNumber as f } from "../../utils/types.js";
|
|
3
|
-
import { isClient as Z } from "../../../../@vueuse/shared/index.js";
|
|
4
|
-
const I = {
|
|
5
|
-
current: 0
|
|
6
|
-
}, s = a(0), v = 2e3, u = Symbol("elZIndexContextKey"), C = Symbol("zIndexContextKey"), j = (x) => {
|
|
7
|
-
const e = c() ? n(u, I) : I, d = x || (c() ? n(C, void 0) : void 0), t = i(() => {
|
|
8
|
-
const r = m(d);
|
|
9
|
-
return f(r) ? r : v;
|
|
10
|
-
}), o = i(() => t.value + s.value), l = () => (e.current++, s.value = e.current, o.value);
|
|
11
|
-
return !Z && n(u), {
|
|
12
|
-
initialZIndex: t,
|
|
13
|
-
currentZIndex: o,
|
|
14
|
-
nextZIndex: l
|
|
15
|
-
};
|
|
16
|
-
};
|
|
17
|
-
export {
|
|
18
|
-
u as ZINDEX_INJECTION_KEY,
|
|
19
|
-
v as defaultInitialZIndex,
|
|
20
|
-
j as useZIndex,
|
|
21
|
-
C as zIndexContextKey
|
|
22
|
-
};
|