@tagplus/components 5.3.11 → 5.3.12

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.
Files changed (69) hide show
  1. package/dist/es/node_modules/@element-plus/icons-vue/dist/index.mjs +29 -20
  2. package/dist/es/node_modules/@popperjs/core/lib/enums.mjs +22 -0
  3. package/dist/es/node_modules/@vue/shared/dist/shared.esm-bundler.mjs +5 -0
  4. package/dist/es/node_modules/@vueuse/core/index.mjs +103 -58
  5. package/dist/es/node_modules/@vueuse/shared/index.mjs +47 -16
  6. package/dist/es/node_modules/element-plus/es/constants/size.mjs +1 -6
  7. package/dist/es/node_modules/element-plus/es/hooks/use-focus-controller/index.mjs +39 -14
  8. package/dist/es/node_modules/element-plus/es/hooks/use-id/index.mjs +8 -5
  9. package/dist/es/node_modules/element-plus/es/hooks/use-locale/index.mjs +12 -7
  10. package/dist/es/node_modules/element-plus/es/hooks/use-namespace/index.mjs +22 -7
  11. package/dist/es/node_modules/element-plus/es/hooks/use-prop/index.mjs +4 -1
  12. package/dist/es/node_modules/element-plus/es/hooks/use-size/index.mjs +3 -3
  13. package/dist/es/node_modules/element-plus/es/locale/lang/en.mjs +31 -28
  14. package/dist/es/node_modules/element-plus/es/utils/dom/aria.mjs +14 -6
  15. package/dist/es/node_modules/element-plus/es/utils/error.mjs +3 -4
  16. package/dist/es/node_modules/element-plus/es/utils/types.mjs +9 -0
  17. package/dist/es/node_modules/element-plus/es/utils/vue/props/runtime.mjs +25 -19
  18. package/dist/es/src/components/Autosuggest/Autosuggest.vue.mjs +1 -1
  19. package/dist/es/src/components/Autosuggest/autosuggest-props.mjs +2 -2
  20. package/dist/es/src/components/Autosuggest/option.vue.mjs +2 -2
  21. package/dist/es/src/components/Autosuggest/select-dropdown.vue.mjs +2 -2
  22. package/dist/es/src/components/Autosuggest/useSelect.mjs +1 -1
  23. package/dist/es/src/components/Inline/Inline.vue.mjs +1 -1
  24. package/dist/es/src/components/InputNumber/InputNumber.vue.mjs +2 -2
  25. package/dist/es/src/components/InputNumber/input-number.mjs +1 -1
  26. package/dist/es/src/components/Loader/Loader.vue.mjs +1 -1
  27. package/dist/es/src/components/Money/Money.vue.mjs +1 -1
  28. package/dist/es/src/components/OptionsList/OptionsList.vue.mjs +1 -1
  29. package/dist/es/src/components/OptionsListItem/OptionsListItem.vue.mjs +1 -1
  30. package/dist/es/src/components/Percent/Percent.vue.mjs +3 -3
  31. package/dist/es/src/components/Skeleton/Skeleton.vue.mjs +1 -1
  32. package/dist/es/src/components/Step/Step.vue.mjs +1 -1
  33. package/dist/es/src/components/Tip/Tip.vue.mjs +9 -7
  34. package/dist/es/src/utils/constants.mjs +2 -2
  35. package/dist/es/src/utils/use-derived-namespace.mjs +1 -1
  36. package/dist/es/src/utils/use-form-common-props.mjs +1 -1
  37. package/dist/es/src/utils/use-id.mjs +2 -2
  38. package/dist/lib/node_modules/@element-plus/icons-vue/dist/index.js +28 -19
  39. package/dist/lib/node_modules/@popperjs/core/lib/enums.js +22 -0
  40. package/dist/lib/node_modules/@vue/shared/dist/shared.esm-bundler.js +5 -0
  41. package/dist/lib/node_modules/@vueuse/core/index.js +100 -56
  42. package/dist/lib/node_modules/@vueuse/shared/index.js +46 -15
  43. package/dist/lib/node_modules/element-plus/es/constants/size.js +1 -6
  44. package/dist/lib/node_modules/element-plus/es/hooks/use-focus-controller/index.js +39 -14
  45. package/dist/lib/node_modules/element-plus/es/hooks/use-id/index.js +8 -5
  46. package/dist/lib/node_modules/element-plus/es/hooks/use-locale/index.js +11 -6
  47. package/dist/lib/node_modules/element-plus/es/hooks/use-namespace/index.js +22 -7
  48. package/dist/lib/node_modules/element-plus/es/hooks/use-prop/index.js +4 -1
  49. package/dist/lib/node_modules/element-plus/es/hooks/use-size/index.js +3 -3
  50. package/dist/lib/node_modules/element-plus/es/locale/lang/en.js +31 -28
  51. package/dist/lib/node_modules/element-plus/es/utils/dom/aria.js +14 -6
  52. package/dist/lib/node_modules/element-plus/es/utils/error.js +3 -4
  53. package/dist/lib/node_modules/element-plus/es/utils/types.js +9 -0
  54. package/dist/lib/node_modules/element-plus/es/utils/vue/props/runtime.js +25 -19
  55. package/dist/lib/src/components/Autosuggest/autosuggest-props.js +2 -2
  56. package/dist/lib/src/components/Autosuggest/option.vue.js +2 -2
  57. package/dist/lib/src/components/Autosuggest/select-dropdown.vue.js +1 -1
  58. package/dist/lib/src/components/Autosuggest/useSelect.js +1 -1
  59. package/dist/lib/src/components/InputNumber/InputNumber.vue.js +1 -1
  60. package/dist/lib/src/components/InputNumber/input-number.js +1 -1
  61. package/dist/lib/src/components/Percent/Percent.vue.js +2 -2
  62. package/dist/lib/src/components/Tip/Tip.vue.js +8 -6
  63. package/dist/lib/src/utils/constants.js +2 -2
  64. package/dist/lib/src/utils/use-derived-namespace.js +1 -1
  65. package/dist/lib/src/utils/use-form-common-props.js +1 -1
  66. package/dist/lib/src/utils/use-id.js +1 -1
  67. package/package.json +1 -2
  68. package/dist/es/node_modules/@popperjs/core/dist/index.mjs +0 -586
  69. package/dist/lib/node_modules/@popperjs/core/dist/index.js +0 -586
@@ -1,5 +1,6 @@
1
- import { defineComponent, openBlock, createElementBlock, createElementVNode } from "vue";
2
- var _sfc_main6 = /* @__PURE__ */ defineComponent({
1
+ import { defineComponent, createElementBlock, openBlock, createElementVNode } from "vue";
2
+ /*! Element Plus Icons Vue v2.3.1 */
3
+ var arrow_down_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
3
4
  name: "ArrowDown",
4
5
  __name: "arrow-down",
5
6
  setup(__props) {
@@ -9,12 +10,13 @@ var _sfc_main6 = /* @__PURE__ */ defineComponent({
9
10
  }, [
10
11
  createElementVNode("path", {
11
12
  fill: "currentColor",
12
- d: "M831.872 340.864 512 652.672 192.128 340.864a30.59 30.59 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.59 30.59 0 0 0-42.752 0z"
13
+ d: "M831.872 340.864 512 652.672 192.128 340.864a30.592 30.592 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.592 30.592 0 0 0-42.752 0z"
13
14
  })
14
15
  ]));
15
16
  }
16
- }), arrow_down_default = _sfc_main6;
17
- var _sfc_main12 = /* @__PURE__ */ defineComponent({
17
+ });
18
+ var arrow_down_default = arrow_down_vue_vue_type_script_setup_true_lang_default;
19
+ var arrow_up_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
18
20
  name: "ArrowUp",
19
21
  __name: "arrow-up",
20
22
  setup(__props) {
@@ -28,8 +30,9 @@ var _sfc_main12 = /* @__PURE__ */ defineComponent({
28
30
  })
29
31
  ]));
30
32
  }
31
- }), arrow_up_default = _sfc_main12;
32
- var _sfc_main43 = /* @__PURE__ */ defineComponent({
33
+ });
34
+ var arrow_up_default = arrow_up_vue_vue_type_script_setup_true_lang_default;
35
+ var check_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
33
36
  name: "Check",
34
37
  __name: "check",
35
38
  setup(__props) {
@@ -43,8 +46,9 @@ var _sfc_main43 = /* @__PURE__ */ defineComponent({
43
46
  })
44
47
  ]));
45
48
  }
46
- }), check_default = _sfc_main43;
47
- var _sfc_main49 = /* @__PURE__ */ defineComponent({
49
+ });
50
+ var check_default = check_vue_vue_type_script_setup_true_lang_default;
51
+ var circle_check_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
48
52
  name: "CircleCheck",
49
53
  __name: "circle-check",
50
54
  setup(__props) {
@@ -58,12 +62,13 @@ var _sfc_main49 = /* @__PURE__ */ defineComponent({
58
62
  }),
59
63
  createElementVNode("path", {
60
64
  fill: "currentColor",
61
- 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.752z"
65
+ 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"
62
66
  })
63
67
  ]));
64
68
  }
65
- }), circle_check_default = _sfc_main49;
66
- var _sfc_main51 = /* @__PURE__ */ defineComponent({
69
+ });
70
+ var circle_check_default = circle_check_vue_vue_type_script_setup_true_lang_default;
71
+ var circle_close_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
67
72
  name: "CircleClose",
68
73
  __name: "circle-close",
69
74
  setup(__props) {
@@ -81,8 +86,9 @@ var _sfc_main51 = /* @__PURE__ */ defineComponent({
81
86
  })
82
87
  ]));
83
88
  }
84
- }), circle_close_default = _sfc_main51;
85
- var _sfc_main150 = /* @__PURE__ */ defineComponent({
89
+ });
90
+ var circle_close_default = circle_close_vue_vue_type_script_setup_true_lang_default;
91
+ var loading_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
86
92
  name: "Loading",
87
93
  __name: "loading",
88
94
  setup(__props) {
@@ -92,12 +98,13 @@ var _sfc_main150 = /* @__PURE__ */ defineComponent({
92
98
  }, [
93
99
  createElementVNode("path", {
94
100
  fill: "currentColor",
95
- 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.248m452.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.248M828.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 0"
101
+ 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"
96
102
  })
97
103
  ]));
98
104
  }
99
- }), loading_default = _sfc_main150;
100
- var _sfc_main169 = /* @__PURE__ */ defineComponent({
105
+ });
106
+ var loading_default = loading_vue_vue_type_script_setup_true_lang_default;
107
+ var minus_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
101
108
  name: "Minus",
102
109
  __name: "minus",
103
110
  setup(__props) {
@@ -111,8 +118,9 @@ var _sfc_main169 = /* @__PURE__ */ defineComponent({
111
118
  })
112
119
  ]));
113
120
  }
114
- }), minus_default = _sfc_main169;
115
- var _sfc_main201 = /* @__PURE__ */ defineComponent({
121
+ });
122
+ var minus_default = minus_vue_vue_type_script_setup_true_lang_default;
123
+ var plus_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
116
124
  name: "Plus",
117
125
  __name: "plus",
118
126
  setup(__props) {
@@ -126,7 +134,8 @@ var _sfc_main201 = /* @__PURE__ */ defineComponent({
126
134
  })
127
135
  ]));
128
136
  }
129
- }), plus_default = _sfc_main201;
137
+ });
138
+ var plus_default = plus_vue_vue_type_script_setup_true_lang_default;
130
139
  export {
131
140
  arrow_down_default as ArrowDown,
132
141
  arrow_up_default as ArrowUp,
@@ -0,0 +1,22 @@
1
+ var top = "top";
2
+ var bottom = "bottom";
3
+ var right = "right";
4
+ var left = "left";
5
+ var auto = "auto";
6
+ var basePlacements = [top, bottom, right, left];
7
+ var start = "start";
8
+ var end = "end";
9
+ var placements = /* @__PURE__ */ [].concat(basePlacements, [auto]).reduce(function(acc, placement) {
10
+ return acc.concat([placement, placement + "-" + start, placement + "-" + end]);
11
+ }, []);
12
+ export {
13
+ auto,
14
+ basePlacements,
15
+ bottom,
16
+ end,
17
+ left,
18
+ placements,
19
+ right,
20
+ start,
21
+ top
22
+ };
@@ -1,3 +1,8 @@
1
+ /**
2
+ * @vue/shared v3.5.13
3
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
+ * @license MIT
5
+ **/
1
6
  !!(process.env.NODE_ENV !== "production") ? Object.freeze({}) : {};
2
7
  !!(process.env.NODE_ENV !== "production") ? Object.freeze([]) : [];
3
8
  const hasOwnProperty = Object.prototype.hasOwnProperty;
@@ -1,18 +1,18 @@
1
- import { toValue, tryOnScopeDispose, isClient, noop, isObject } from "../shared/index.mjs";
1
+ import { tryOnScopeDispose, isClient, tryOnMounted, resolveUnref, isString, noop, identity } from "../shared/index.mjs";
2
2
  import { computedEager, computedEager as computedEager2 } from "../shared/index.mjs";
3
- import { computed, watch, ref, getCurrentInstance, onMounted } from "vue";
4
- const defaultWindow = isClient ? window : void 0;
3
+ import { watch, ref } from "vue";
5
4
  function unrefElement(elRef) {
6
5
  var _a;
7
- const plain = toValue(elRef);
6
+ const plain = resolveUnref(elRef);
8
7
  return (_a = plain == null ? void 0 : plain.$el) != null ? _a : plain;
9
8
  }
9
+ const defaultWindow = isClient ? window : void 0;
10
10
  function useEventListener(...args) {
11
11
  let target;
12
12
  let events;
13
13
  let listeners;
14
14
  let options;
15
- if (typeof args[0] === "string" || Array.isArray(args[0])) {
15
+ if (isString(args[0]) || Array.isArray(args[0])) {
16
16
  [events, listeners, options] = args;
17
17
  target = defaultWindow;
18
18
  } else {
@@ -33,21 +33,14 @@ function useEventListener(...args) {
33
33
  el.addEventListener(event, listener, options2);
34
34
  return () => el.removeEventListener(event, listener, options2);
35
35
  };
36
- const stopWatch = watch(
37
- () => [unrefElement(target), toValue(options)],
38
- ([el, options2]) => {
39
- cleanup();
40
- if (!el)
41
- return;
42
- const optionsClone = isObject(options2) ? { ...options2 } : options2;
43
- cleanups.push(
44
- ...events.flatMap((event) => {
45
- return listeners.map((listener) => register(el, event, listener, optionsClone));
46
- })
47
- );
48
- },
49
- { immediate: true, flush: "post" }
50
- );
36
+ const stopWatch = watch(() => [unrefElement(target), resolveUnref(options)], ([el, options2]) => {
37
+ cleanup();
38
+ if (!el)
39
+ return;
40
+ cleanups.push(...events.flatMap((event) => {
41
+ return listeners.map((listener) => register(el, event, listener, options2));
42
+ }));
43
+ }, { immediate: true, flush: "post" });
51
44
  const stop = () => {
52
45
  stopWatch();
53
46
  cleanup();
@@ -55,25 +48,33 @@ function useEventListener(...args) {
55
48
  tryOnScopeDispose(stop);
56
49
  return stop;
57
50
  }
58
- function useMounted() {
59
- const isMounted = ref(false);
60
- const instance = getCurrentInstance();
61
- if (instance) {
62
- onMounted(() => {
63
- isMounted.value = true;
64
- }, instance);
65
- }
66
- return isMounted;
67
- }
68
- function useSupported(callback) {
69
- const isMounted = useMounted();
70
- return computed(() => {
71
- isMounted.value;
72
- return Boolean(callback());
73
- });
51
+ function useSupported(callback, sync = false) {
52
+ const isSupported = ref();
53
+ const update = () => isSupported.value = Boolean(callback());
54
+ update();
55
+ tryOnMounted(update, sync);
56
+ return isSupported;
74
57
  }
58
+ const _global = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
59
+ const globalKey = "__vueuse_ssr_handlers__";
60
+ _global[globalKey] = _global[globalKey] || {};
61
+ var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
62
+ var __hasOwnProp$g = Object.prototype.hasOwnProperty;
63
+ var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
64
+ var __objRest$2 = (source, exclude) => {
65
+ var target = {};
66
+ for (var prop in source)
67
+ if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
68
+ target[prop] = source[prop];
69
+ if (source != null && __getOwnPropSymbols$g)
70
+ for (var prop of __getOwnPropSymbols$g(source)) {
71
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
72
+ target[prop] = source[prop];
73
+ }
74
+ return target;
75
+ };
75
76
  function useResizeObserver(target, callback, options = {}) {
76
- const { window: window2 = defaultWindow, ...observerOptions } = options;
77
+ const _a = options, { window: window2 = defaultWindow } = _a, observerOptions = __objRest$2(_a, ["window"]);
77
78
  let observer;
78
79
  const isSupported = useSupported(() => window2 && "ResizeObserver" in window2);
79
80
  const cleanup = () => {
@@ -82,24 +83,13 @@ function useResizeObserver(target, callback, options = {}) {
82
83
  observer = void 0;
83
84
  }
84
85
  };
85
- const targets = computed(() => {
86
- const _targets = toValue(target);
87
- return Array.isArray(_targets) ? _targets.map((el) => unrefElement(el)) : [unrefElement(_targets)];
88
- });
89
- const stopWatch = watch(
90
- targets,
91
- (els) => {
92
- cleanup();
93
- if (isSupported.value && window2) {
94
- observer = new ResizeObserver(callback);
95
- for (const _el of els) {
96
- if (_el)
97
- observer.observe(_el, observerOptions);
98
- }
99
- }
100
- },
101
- { immediate: true, flush: "post" }
102
- );
86
+ const stopWatch = watch(() => unrefElement(target), (el) => {
87
+ cleanup();
88
+ if (isSupported.value && window2 && el) {
89
+ observer = new ResizeObserver(callback);
90
+ observer.observe(el, observerOptions);
91
+ }
92
+ }, { immediate: true, flush: "post" });
103
93
  const stop = () => {
104
94
  cleanup();
105
95
  stopWatch();
@@ -110,18 +100,73 @@ function useResizeObserver(target, callback, options = {}) {
110
100
  stop
111
101
  };
112
102
  }
103
+ var SwipeDirection;
104
+ (function(SwipeDirection2) {
105
+ SwipeDirection2["UP"] = "UP";
106
+ SwipeDirection2["RIGHT"] = "RIGHT";
107
+ SwipeDirection2["DOWN"] = "DOWN";
108
+ SwipeDirection2["LEFT"] = "LEFT";
109
+ SwipeDirection2["NONE"] = "NONE";
110
+ })(SwipeDirection || (SwipeDirection = {}));
111
+ var __defProp = Object.defineProperty;
112
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
113
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
114
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
115
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
116
+ var __spreadValues = (a, b) => {
117
+ for (var prop in b || (b = {}))
118
+ if (__hasOwnProp.call(b, prop))
119
+ __defNormalProp(a, prop, b[prop]);
120
+ if (__getOwnPropSymbols)
121
+ for (var prop of __getOwnPropSymbols(b)) {
122
+ if (__propIsEnum.call(b, prop))
123
+ __defNormalProp(a, prop, b[prop]);
124
+ }
125
+ return a;
126
+ };
127
+ const _TransitionPresets = {
128
+ easeInSine: [0.12, 0, 0.39, 0],
129
+ easeOutSine: [0.61, 1, 0.88, 1],
130
+ easeInOutSine: [0.37, 0, 0.63, 1],
131
+ easeInQuad: [0.11, 0, 0.5, 0],
132
+ easeOutQuad: [0.5, 1, 0.89, 1],
133
+ easeInOutQuad: [0.45, 0, 0.55, 1],
134
+ easeInCubic: [0.32, 0, 0.67, 0],
135
+ easeOutCubic: [0.33, 1, 0.68, 1],
136
+ easeInOutCubic: [0.65, 0, 0.35, 1],
137
+ easeInQuart: [0.5, 0, 0.75, 0],
138
+ easeOutQuart: [0.25, 1, 0.5, 1],
139
+ easeInOutQuart: [0.76, 0, 0.24, 1],
140
+ easeInQuint: [0.64, 0, 0.78, 0],
141
+ easeOutQuint: [0.22, 1, 0.36, 1],
142
+ easeInOutQuint: [0.83, 0, 0.17, 1],
143
+ easeInExpo: [0.7, 0, 0.84, 0],
144
+ easeOutExpo: [0.16, 1, 0.3, 1],
145
+ easeInOutExpo: [0.87, 0, 0.13, 1],
146
+ easeInCirc: [0.55, 0, 1, 0.45],
147
+ easeOutCirc: [0, 0.55, 0.45, 1],
148
+ easeInOutCirc: [0.85, 0, 0.15, 1],
149
+ easeInBack: [0.36, 0, 0.66, -0.56],
150
+ easeOutBack: [0.34, 1.56, 0.64, 1],
151
+ easeInOutBack: [0.68, -0.6, 0.32, 1.6]
152
+ };
153
+ __spreadValues({
154
+ linear: identity
155
+ }, _TransitionPresets);
113
156
  export {
157
+ SwipeDirection,
114
158
  computedEager,
115
159
  defaultWindow,
116
160
  computedEager2 as eagerComputed,
161
+ identity,
117
162
  isClient,
118
- isObject,
163
+ isString,
119
164
  noop,
120
- toValue,
165
+ resolveUnref,
166
+ tryOnMounted,
121
167
  tryOnScopeDispose,
122
168
  unrefElement,
123
169
  useEventListener,
124
- useMounted,
125
170
  useResizeObserver,
126
171
  useSupported
127
172
  };
@@ -1,15 +1,45 @@
1
- import { unref, getCurrentScope, onScopeDispose, shallowRef, watchEffect, readonly } from "vue";
1
+ import { getCurrentScope, onScopeDispose, shallowRef, watchEffect, readonly, getCurrentInstance, onMounted, nextTick, unref } from "vue";
2
+ var __defProp$9 = Object.defineProperty;
3
+ var __defProps$6 = Object.defineProperties;
4
+ var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;
5
+ var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
6
+ var __hasOwnProp$b = Object.prototype.hasOwnProperty;
7
+ var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
8
+ var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
9
+ var __spreadValues$9 = (a, b) => {
10
+ for (var prop in b || (b = {}))
11
+ if (__hasOwnProp$b.call(b, prop))
12
+ __defNormalProp$9(a, prop, b[prop]);
13
+ if (__getOwnPropSymbols$b)
14
+ for (var prop of __getOwnPropSymbols$b(b)) {
15
+ if (__propIsEnum$b.call(b, prop))
16
+ __defNormalProp$9(a, prop, b[prop]);
17
+ }
18
+ return a;
19
+ };
20
+ var __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));
2
21
  function computedEager(fn, options) {
3
- var _a;
22
+ var _a2;
4
23
  const result = shallowRef();
5
24
  watchEffect(() => {
6
25
  result.value = fn();
7
- }, {
8
- ...options,
9
- flush: (_a = void 0) != null ? _a : "sync"
10
- });
26
+ }, __spreadProps$6(__spreadValues$9({}, options), {
27
+ flush: (_a2 = void 0) != null ? _a2 : "sync"
28
+ }));
11
29
  return readonly(result);
12
30
  }
31
+ var _a;
32
+ const isClient = typeof window !== "undefined";
33
+ const isString = (val) => typeof val === "string";
34
+ const noop = () => {
35
+ };
36
+ isClient && ((_a = window == null ? void 0 : window.navigator) == null ? void 0 : _a.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
37
+ function resolveUnref(r) {
38
+ return typeof r === "function" ? r() : unref(r);
39
+ }
40
+ function identity(arg) {
41
+ return arg;
42
+ }
13
43
  function tryOnScopeDispose(fn) {
14
44
  if (getCurrentScope()) {
15
45
  onScopeDispose(fn);
@@ -17,21 +47,22 @@ function tryOnScopeDispose(fn) {
17
47
  }
18
48
  return false;
19
49
  }
20
- function toValue(r) {
21
- return typeof r === "function" ? r() : unref(r);
50
+ function tryOnMounted(fn, sync = true) {
51
+ if (getCurrentInstance())
52
+ onMounted(fn);
53
+ else if (sync)
54
+ fn();
55
+ else
56
+ nextTick(fn);
22
57
  }
23
- const isClient = typeof window !== "undefined" && typeof document !== "undefined";
24
- typeof WorkerGlobalScope !== "undefined" && globalThis instanceof WorkerGlobalScope;
25
- const toString = Object.prototype.toString;
26
- const isObject = (val) => toString.call(val) === "[object Object]";
27
- const noop = () => {
28
- };
29
58
  export {
30
59
  computedEager,
31
60
  computedEager as eagerComputed,
61
+ identity,
32
62
  isClient,
33
- isObject,
63
+ isString,
34
64
  noop,
35
- toValue,
65
+ resolveUnref,
66
+ tryOnMounted,
36
67
  tryOnScopeDispose
37
68
  };
@@ -1,9 +1,4 @@
1
- const componentSizes = [
2
- "",
3
- "default",
4
- "small",
5
- "large"
6
- ];
1
+ const componentSizes = ["", "default", "small", "large"];
7
2
  export {
8
3
  componentSizes
9
4
  };
@@ -1,38 +1,63 @@
1
+ import { getCurrentInstance, shallowRef, ref, watch, unref, onMounted } from "vue";
2
+ import { useEventListener } from "../../../../@vueuse/core/index.mjs";
3
+ import { isElement } from "../../utils/types.mjs";
1
4
  import { isFocusable } from "../../utils/dom/aria.mjs";
2
5
  import { isFunction } from "../../../../@vue/shared/dist/shared.esm-bundler.mjs";
3
- import "lodash-es";
4
- import { useEventListener } from "../../../../@vueuse/core/index.mjs";
5
- import { getCurrentInstance, shallowRef, ref, watch, unref } from "vue";
6
- function useFocusController(target, { disabled, beforeFocus, afterFocus, beforeBlur, afterBlur } = {}) {
7
- const { emit } = getCurrentInstance();
6
+ function useFocusController(target, {
7
+ disabled,
8
+ beforeFocus,
9
+ afterFocus,
10
+ beforeBlur,
11
+ afterBlur
12
+ } = {}) {
13
+ const instance = getCurrentInstance();
14
+ const { emit } = instance;
8
15
  const wrapperRef = shallowRef();
9
16
  const isFocused = ref(false);
10
17
  const handleFocus = (event) => {
11
18
  const cancelFocus = isFunction(beforeFocus) ? beforeFocus(event) : false;
12
- if (unref(disabled) || isFocused.value || cancelFocus) return;
19
+ if (unref(disabled) || isFocused.value || cancelFocus)
20
+ return;
13
21
  isFocused.value = true;
14
22
  emit("focus", event);
15
- afterFocus?.();
23
+ afterFocus == null ? void 0 : afterFocus();
16
24
  };
17
25
  const handleBlur = (event) => {
26
+ var _a;
18
27
  const cancelBlur = isFunction(beforeBlur) ? beforeBlur(event) : false;
19
- if (unref(disabled) || event.relatedTarget && wrapperRef.value?.contains(event.relatedTarget) || cancelBlur) return;
28
+ if (unref(disabled) || event.relatedTarget && ((_a = wrapperRef.value) == null ? void 0 : _a.contains(event.relatedTarget)) || cancelBlur)
29
+ return;
20
30
  isFocused.value = false;
21
31
  emit("blur", event);
22
- afterBlur?.();
32
+ afterBlur == null ? void 0 : afterBlur();
23
33
  };
24
34
  const handleClick = (event) => {
25
- if (unref(disabled) || isFocusable(event.target) || wrapperRef.value?.contains(document.activeElement) && wrapperRef.value !== document.activeElement) return;
26
- target.value?.focus();
35
+ var _a, _b;
36
+ if (unref(disabled) || isFocusable(event.target) || ((_a = wrapperRef.value) == null ? void 0 : _a.contains(document.activeElement)) && wrapperRef.value !== document.activeElement)
37
+ return;
38
+ (_b = target.value) == null ? void 0 : _b.focus();
27
39
  };
28
40
  watch([wrapperRef, () => unref(disabled)], ([el, disabled2]) => {
29
- if (!el) return;
30
- if (disabled2) el.removeAttribute("tabindex");
31
- else el.setAttribute("tabindex", "-1");
41
+ if (!el)
42
+ return;
43
+ if (disabled2) {
44
+ el.removeAttribute("tabindex");
45
+ } else {
46
+ el.setAttribute("tabindex", "-1");
47
+ }
32
48
  });
33
49
  useEventListener(wrapperRef, "focus", handleFocus, true);
34
50
  useEventListener(wrapperRef, "blur", handleBlur, true);
35
51
  useEventListener(wrapperRef, "click", handleClick, true);
52
+ if (process.env.NODE_ENV === "test") {
53
+ onMounted(() => {
54
+ const targetEl = isElement(target.value) ? target.value : document.querySelector("input,textarea");
55
+ if (targetEl) {
56
+ useEventListener(targetEl, "focus", handleFocus, true);
57
+ useEventListener(targetEl, "blur", handleBlur, true);
58
+ }
59
+ });
60
+ }
36
61
  return {
37
62
  isFocused,
38
63
  wrapperRef,
@@ -1,24 +1,27 @@
1
- import { debugWarn } from "../../utils/error.mjs";
1
+ import { inject, getCurrentInstance, unref } from "vue";
2
2
  import { useGetDerivedNamespace } from "../use-namespace/index.mjs";
3
- import { getCurrentInstance, inject, unref } from "vue";
3
+ import { debugWarn } from "../../utils/error.mjs";
4
4
  import { isClient, computedEager } from "../../../../@vueuse/shared/index.mjs";
5
5
  const defaultIdInjection = {
6
6
  prefix: Math.floor(Math.random() * 1e4),
7
7
  current: 0
8
8
  };
9
- const ID_INJECTION_KEY = /* @__PURE__ */ Symbol("elIdInjection");
9
+ const ID_INJECTION_KEY = Symbol("elIdInjection");
10
10
  const useIdInjection = () => {
11
11
  return getCurrentInstance() ? inject(ID_INJECTION_KEY, defaultIdInjection) : defaultIdInjection;
12
12
  };
13
13
  const useId = (deterministicId) => {
14
14
  const idInjection = useIdInjection();
15
- if (!isClient && idInjection === defaultIdInjection) debugWarn("IdInjection", `Looks like you are using server rendering, you must provide a id provider to ensure the hydration process to be succeed
15
+ if (!isClient && idInjection === defaultIdInjection) {
16
+ debugWarn("IdInjection", `Looks like you are using server rendering, you must provide a id provider to ensure the hydration process to be succeed
16
17
  usage: app.provide(ID_INJECTION_KEY, {
17
18
  prefix: number,
18
19
  current: number,
19
20
  })`);
21
+ }
20
22
  const namespace = useGetDerivedNamespace();
21
- return computedEager(() => unref(deterministicId) || `${namespace.value}-id-${idInjection.prefix}-${idInjection.current++}`);
23
+ const idRef = computedEager(() => unref(deterministicId) || `${namespace.value}-id-${idInjection.prefix}-${idInjection.current++}`);
24
+ return idRef;
22
25
  };
23
26
  export {
24
27
  ID_INJECTION_KEY,
@@ -1,19 +1,24 @@
1
- import en_default from "../../locale/lang/en.mjs";
1
+ import { inject, ref, computed, unref, isRef } from "vue";
2
2
  import { get } from "lodash-es";
3
- import { inject, ref, computed, isRef, unref } from "vue";
3
+ import English from "../../locale/lang/en.mjs";
4
4
  const buildTranslator = (locale) => (path, option) => translate(path, option, unref(locale));
5
- const translate = (path, option, locale) => get(locale, path, path).replace(/\{(\w+)\}/g, (_, key) => `${option?.[key] ?? `{${key}}`}`);
5
+ const translate = (path, option, locale) => get(locale, path, path).replace(/\{(\w+)\}/g, (_, key) => {
6
+ var _a;
7
+ return `${(_a = option == null ? void 0 : option[key]) != null ? _a : `{${key}}`}`;
8
+ });
6
9
  const buildLocaleContext = (locale) => {
10
+ const lang = computed(() => unref(locale).name);
11
+ const localeRef = isRef(locale) ? locale : ref(locale);
7
12
  return {
8
- lang: computed(() => unref(locale).name),
9
- locale: isRef(locale) ? locale : ref(locale),
13
+ lang,
14
+ locale: localeRef,
10
15
  t: buildTranslator(locale)
11
16
  };
12
17
  };
13
- const localeContextKey = /* @__PURE__ */ Symbol("localeContextKey");
18
+ const localeContextKey = Symbol("localeContextKey");
14
19
  const useLocale = (localeOverrides) => {
15
20
  const locale = inject(localeContextKey, ref());
16
- return buildLocaleContext(computed(() => locale.value || en_default));
21
+ return buildLocaleContext(computed(() => locale.value || English));
17
22
  };
18
23
  export {
19
24
  buildLocaleContext,
@@ -3,17 +3,24 @@ const defaultNamespace = "el";
3
3
  const statePrefix = "is-";
4
4
  const _bem = (namespace, block, blockSuffix, element, modifier) => {
5
5
  let cls = `${namespace}-${block}`;
6
- if (blockSuffix) cls += `-${blockSuffix}`;
7
- if (element) cls += `__${element}`;
8
- if (modifier) cls += `--${modifier}`;
6
+ if (blockSuffix) {
7
+ cls += `-${blockSuffix}`;
8
+ }
9
+ if (element) {
10
+ cls += `__${element}`;
11
+ }
12
+ if (modifier) {
13
+ cls += `--${modifier}`;
14
+ }
9
15
  return cls;
10
16
  };
11
- const namespaceContextKey = /* @__PURE__ */ Symbol("namespaceContextKey");
17
+ const namespaceContextKey = Symbol("namespaceContextKey");
12
18
  const useGetDerivedNamespace = (namespaceOverrides) => {
13
19
  const derivedNamespace = getCurrentInstance() ? inject(namespaceContextKey, ref(defaultNamespace)) : ref(defaultNamespace);
14
- return computed(() => {
20
+ const namespace = computed(() => {
15
21
  return unref(derivedNamespace) || defaultNamespace;
16
22
  });
23
+ return namespace;
17
24
  };
18
25
  const useNamespace = (block, namespaceOverrides) => {
19
26
  const namespace = useGetDerivedNamespace();
@@ -30,12 +37,20 @@ const useNamespace = (block, namespaceOverrides) => {
30
37
  };
31
38
  const cssVar = (object) => {
32
39
  const styles = {};
33
- for (const key in object) if (object[key]) styles[`--${namespace.value}-${key}`] = object[key];
40
+ for (const key in object) {
41
+ if (object[key]) {
42
+ styles[`--${namespace.value}-${key}`] = object[key];
43
+ }
44
+ }
34
45
  return styles;
35
46
  };
36
47
  const cssVarBlock = (object) => {
37
48
  const styles = {};
38
- for (const key in object) if (object[key]) styles[`--${namespace.value}-${block}-${key}`] = object[key];
49
+ for (const key in object) {
50
+ if (object[key]) {
51
+ styles[`--${namespace.value}-${block}-${key}`] = object[key];
52
+ }
53
+ }
39
54
  return styles;
40
55
  };
41
56
  const cssVarName = (name) => `--${namespace.value}-${name}`;
@@ -1,7 +1,10 @@
1
1
  import { getCurrentInstance, computed } from "vue";
2
2
  const useProp = (name) => {
3
3
  const vm = getCurrentInstance();
4
- return computed(() => vm?.proxy?.$props?.[name]);
4
+ return computed(() => {
5
+ var _a, _b;
6
+ return (_b = (_a = vm == null ? void 0 : vm.proxy) == null ? void 0 : _a.$props) == null ? void 0 : _b[name];
7
+ });
5
8
  };
6
9
  export {
7
10
  useProp