hzzt-plus 1.0.0 → 1.0.1

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 (100) hide show
  1. package/dist/index.full.js +1838 -1451
  2. package/dist/index.full.min.js +14 -14
  3. package/dist/index.full.min.js.map +1 -1
  4. package/dist/index.full.min.mjs +14 -14
  5. package/dist/index.full.min.mjs.map +1 -1
  6. package/dist/index.full.mjs +1836 -1453
  7. package/es/component.mjs +3 -1
  8. package/es/component.mjs.map +1 -1
  9. package/es/components/confirm-password/index.d.ts +46 -22
  10. package/es/components/confirm-password/src/confirm-password.vue.d.ts +46 -22
  11. package/es/components/icon/src/index.vue.d.ts +4 -4
  12. package/es/components/index.d.ts +1 -0
  13. package/es/components/index.mjs +2 -0
  14. package/es/components/index.mjs.map +1 -1
  15. package/es/components/page-size/index.d.ts +10224 -531
  16. package/es/components/page-size/src/index.vue.d.ts +10224 -531
  17. package/es/components/pagination/index.d.ts +4 -4
  18. package/es/components/pagination/src/index.vue.d.ts +4 -4
  19. package/es/components/quarter-picker/index.d.ts +121 -97
  20. package/es/components/quarter-picker/src/index.vue.d.ts +121 -97
  21. package/es/components/scan/src/scan.vue.d.ts +46 -22
  22. package/es/components/select-input/index.d.ts +826 -0
  23. package/es/components/select-input/index.mjs +9 -0
  24. package/es/components/select-input/index.mjs.map +1 -0
  25. package/es/components/select-input/src/select-input.d.ts +41 -0
  26. package/es/components/select-input/src/select-input.mjs +50 -0
  27. package/es/components/select-input/src/select-input.mjs.map +1 -0
  28. package/es/components/select-input/src/select-input.vue.d.ts +826 -0
  29. package/es/components/select-input/src/select-input2.mjs +129 -0
  30. package/es/components/select-input/src/select-input2.mjs.map +1 -0
  31. package/es/components/select-input/style/css.d.ts +2 -0
  32. package/es/components/select-input/style/css.mjs +3 -0
  33. package/es/components/select-input/style/css.mjs.map +1 -0
  34. package/es/components/select-input/style/index.d.ts +2 -0
  35. package/es/components/select-input/style/index.mjs +3 -0
  36. package/es/components/select-input/style/index.mjs.map +1 -0
  37. package/es/components/tab/index.d.ts +4 -4
  38. package/es/components/tab/src/index.vue.d.ts +4 -4
  39. package/es/components/title/index.mjs +2 -2
  40. package/es/components/title/index.mjs.map +1 -1
  41. package/es/components/title/src/title2.mjs +2 -2
  42. package/es/components/tooltip/index.d.ts +7615 -316
  43. package/es/components/tooltip/src/tooltip.vue.d.ts +7615 -316
  44. package/es/hooks/index.d.ts +1 -0
  45. package/es/hooks/index.mjs +1 -0
  46. package/es/hooks/index.mjs.map +1 -1
  47. package/es/hooks/use-letter/index.d.ts +1 -0
  48. package/es/hooks/use-letter/index.mjs +13 -0
  49. package/es/hooks/use-letter/index.mjs.map +1 -0
  50. package/es/index.mjs +3 -0
  51. package/es/index.mjs.map +1 -1
  52. package/global.d.ts +1 -0
  53. package/lib/component.js +3 -1
  54. package/lib/component.js.map +1 -1
  55. package/lib/components/confirm-password/index.d.ts +46 -22
  56. package/lib/components/confirm-password/src/confirm-password.vue.d.ts +46 -22
  57. package/lib/components/icon/src/index.vue.d.ts +4 -4
  58. package/lib/components/index.d.ts +1 -0
  59. package/lib/components/index.js +5 -0
  60. package/lib/components/index.js.map +1 -1
  61. package/lib/components/page-size/index.d.ts +10224 -531
  62. package/lib/components/page-size/src/index.vue.d.ts +10224 -531
  63. package/lib/components/pagination/index.d.ts +4 -4
  64. package/lib/components/pagination/src/index.vue.d.ts +4 -4
  65. package/lib/components/quarter-picker/index.d.ts +121 -97
  66. package/lib/components/quarter-picker/src/index.vue.d.ts +121 -97
  67. package/lib/components/scan/src/scan.vue.d.ts +46 -22
  68. package/lib/components/select-input/index.d.ts +826 -0
  69. package/lib/components/select-input/index.js +16 -0
  70. package/lib/components/select-input/index.js.map +1 -0
  71. package/lib/components/select-input/src/select-input.d.ts +41 -0
  72. package/lib/components/select-input/src/select-input.js +55 -0
  73. package/lib/components/select-input/src/select-input.js.map +1 -0
  74. package/lib/components/select-input/src/select-input.vue.d.ts +826 -0
  75. package/lib/components/select-input/src/select-input2.js +133 -0
  76. package/lib/components/select-input/src/select-input2.js.map +1 -0
  77. package/lib/components/select-input/style/css.d.ts +2 -0
  78. package/lib/components/select-input/style/css.js +6 -0
  79. package/lib/components/select-input/style/css.js.map +1 -0
  80. package/lib/components/select-input/style/index.d.ts +2 -0
  81. package/lib/components/select-input/style/index.js +6 -0
  82. package/lib/components/select-input/style/index.js.map +1 -0
  83. package/lib/components/tab/index.d.ts +4 -4
  84. package/lib/components/tab/src/index.vue.d.ts +4 -4
  85. package/lib/components/title/index.js.map +1 -1
  86. package/lib/components/title/src/title2.js +2 -2
  87. package/lib/components/tooltip/index.d.ts +7615 -316
  88. package/lib/components/tooltip/src/tooltip.vue.d.ts +7615 -316
  89. package/lib/hooks/index.d.ts +1 -0
  90. package/lib/hooks/index.js +2 -0
  91. package/lib/hooks/index.js.map +1 -1
  92. package/lib/hooks/use-letter/index.d.ts +1 -0
  93. package/lib/hooks/use-letter/index.js +17 -0
  94. package/lib/hooks/use-letter/index.js.map +1 -0
  95. package/lib/index.js +33 -26
  96. package/lib/index.js.map +1 -1
  97. package/package.json +3 -3
  98. package/theme/hzzt-select-input.css +0 -0
  99. package/theme/src/index.scss +1 -0
  100. package/theme/src/select-input.scss +0 -0
@@ -1,6 +1,36 @@
1
1
  /*! Hzzt Plus v0.0.1 */
2
2
 
3
- import { getCurrentScope, onScopeDispose, unref, getCurrentInstance, onMounted, nextTick, watch, ref, defineComponent, openBlock, createElementBlock, createElementVNode, warn, computed, isRef, inject, provide, renderSlot, shallowRef, onBeforeUnmount, onBeforeMount, mergeProps, toRef, onUnmounted, useAttrs as useAttrs$1, useSlots, createCommentVNode, Fragment, normalizeClass, createBlock, withCtx, resolveDynamicComponent, withModifiers, createVNode, toDisplayString, normalizeStyle, Transition, withDirectives, vShow, reactive, onActivated, onUpdated, cloneVNode, Text, Comment, Teleport as Teleport$1, readonly, onDeactivated, withKeys, toRaw, toRefs, watchEffect, resolveComponent, resolveDirective, toHandlerKey, renderList, createTextVNode, vModelText, normalizeProps, guardReactiveProps, createSlots } from 'vue';
3
+ import { readonly, shallowRef, watchEffect, getCurrentScope, onScopeDispose, unref, getCurrentInstance, onMounted, nextTick, watch, ref, defineComponent, openBlock, createElementBlock, createElementVNode, warn, computed, isRef, inject, provide, renderSlot, mergeProps, toRef, onUnmounted, useAttrs as useAttrs$1, useSlots, normalizeClass, normalizeStyle, createCommentVNode, Fragment, createBlock, withCtx, resolveDynamicComponent, withModifiers, createVNode, toDisplayString, onBeforeUnmount, Transition, withDirectives, vShow, reactive, onActivated, onUpdated, cloneVNode, Text, Comment, Teleport as Teleport$1, onBeforeMount, onDeactivated, withKeys, createSlots, toRaw, toRefs, resolveComponent, resolveDirective, toHandlerKey, renderList, createTextVNode, vModelText, normalizeProps, guardReactiveProps } from 'vue';
4
+
5
+ var __defProp$9 = Object.defineProperty;
6
+ var __defProps$6 = Object.defineProperties;
7
+ var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;
8
+ var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
9
+ var __hasOwnProp$b = Object.prototype.hasOwnProperty;
10
+ var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
11
+ var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
12
+ var __spreadValues$9 = (a, b) => {
13
+ for (var prop in b || (b = {}))
14
+ if (__hasOwnProp$b.call(b, prop))
15
+ __defNormalProp$9(a, prop, b[prop]);
16
+ if (__getOwnPropSymbols$b)
17
+ for (var prop of __getOwnPropSymbols$b(b)) {
18
+ if (__propIsEnum$b.call(b, prop))
19
+ __defNormalProp$9(a, prop, b[prop]);
20
+ }
21
+ return a;
22
+ };
23
+ var __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));
24
+ function computedEager(fn, options) {
25
+ var _a;
26
+ const result = shallowRef();
27
+ watchEffect(() => {
28
+ result.value = fn();
29
+ }, __spreadProps$6(__spreadValues$9({}, options), {
30
+ flush: (_a = options == null ? void 0 : options.flush) != null ? _a : "sync"
31
+ }));
32
+ return readonly(result);
33
+ }
4
34
 
5
35
  var _a;
6
36
  const isClient = typeof window !== "undefined";
@@ -282,9 +312,7 @@ const isString$1 = (val) => typeof val === "string";
282
312
  const isObject$1 = (val) => val !== null && typeof val === "object";
283
313
  const objectToString$1 = Object.prototype.toString;
284
314
  const toTypeString = (value) => objectToString$1.call(value);
285
- const toRawType = (value) => {
286
- return toTypeString(value).slice(8, -1);
287
- };
315
+ const isPlainObject$1 = (val) => toTypeString(val) === "[object Object]";
288
316
 
289
317
  var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
290
318
 
@@ -12803,6 +12831,17 @@ const useNamespace$1 = (block, namespaceOverrides) => {
12803
12831
  };
12804
12832
  };
12805
12833
 
12834
+ function numberToLetter(index) {
12835
+ const start = "A".charCodeAt(0);
12836
+ if (index < 26) {
12837
+ return String.fromCharCode(start + index);
12838
+ } else if (index < 52) {
12839
+ return String.fromCharCode(start + index + 6);
12840
+ } else {
12841
+ return index - 51;
12842
+ }
12843
+ }
12844
+
12806
12845
  const configProviderContextKey$1 = Symbol();
12807
12846
 
12808
12847
  const globalConfig$1 = ref();
@@ -12894,18 +12933,81 @@ const makeInstaller = (components = []) => {
12894
12933
  };
12895
12934
  };
12896
12935
 
12897
- const composeEventHandlers = (theirsHandler, oursHandler, { checkForDefaultPrevented = true } = {}) => {
12898
- const handleEvent = (event) => {
12899
- const shouldPrevent = theirsHandler == null ? void 0 : theirsHandler(event);
12900
- if (checkForDefaultPrevented === false || !shouldPrevent) {
12901
- return oursHandler == null ? void 0 : oursHandler(event);
12936
+ const configProviderContextKey = Symbol();
12937
+
12938
+ const defaultNamespace = "el";
12939
+ const statePrefix = "is-";
12940
+ const _bem = (namespace, block, blockSuffix, element, modifier) => {
12941
+ let cls = `${namespace}-${block}`;
12942
+ if (blockSuffix) {
12943
+ cls += `-${blockSuffix}`;
12944
+ }
12945
+ if (element) {
12946
+ cls += `__${element}`;
12947
+ }
12948
+ if (modifier) {
12949
+ cls += `--${modifier}`;
12950
+ }
12951
+ return cls;
12952
+ };
12953
+ const namespaceContextKey = Symbol("namespaceContextKey");
12954
+ const useGetDerivedNamespace = (namespaceOverrides) => {
12955
+ const derivedNamespace = namespaceOverrides || (getCurrentInstance() ? inject(namespaceContextKey, ref(defaultNamespace)) : ref(defaultNamespace));
12956
+ const namespace = computed(() => {
12957
+ return unref(derivedNamespace) || defaultNamespace;
12958
+ });
12959
+ return namespace;
12960
+ };
12961
+ const useNamespace = (block, namespaceOverrides) => {
12962
+ const namespace = useGetDerivedNamespace(namespaceOverrides);
12963
+ const b = (blockSuffix = "") => _bem(namespace.value, block, blockSuffix, "", "");
12964
+ const e = (element) => element ? _bem(namespace.value, block, "", element, "") : "";
12965
+ const m = (modifier) => modifier ? _bem(namespace.value, block, "", "", modifier) : "";
12966
+ const be = (blockSuffix, element) => blockSuffix && element ? _bem(namespace.value, block, blockSuffix, element, "") : "";
12967
+ const em = (element, modifier) => element && modifier ? _bem(namespace.value, block, "", element, modifier) : "";
12968
+ const bm = (blockSuffix, modifier) => blockSuffix && modifier ? _bem(namespace.value, block, blockSuffix, "", modifier) : "";
12969
+ const bem = (blockSuffix, element, modifier) => blockSuffix && element && modifier ? _bem(namespace.value, block, blockSuffix, element, modifier) : "";
12970
+ const is = (name, ...args) => {
12971
+ const state = args.length >= 1 ? args[0] : true;
12972
+ return name && state ? `${statePrefix}${name}` : "";
12973
+ };
12974
+ const cssVar = (object) => {
12975
+ const styles = {};
12976
+ for (const key in object) {
12977
+ if (object[key]) {
12978
+ styles[`--${namespace.value}-${key}`] = object[key];
12979
+ }
12902
12980
  }
12981
+ return styles;
12982
+ };
12983
+ const cssVarBlock = (object) => {
12984
+ const styles = {};
12985
+ for (const key in object) {
12986
+ if (object[key]) {
12987
+ styles[`--${namespace.value}-${block}-${key}`] = object[key];
12988
+ }
12989
+ }
12990
+ return styles;
12991
+ };
12992
+ const cssVarName = (name) => `--${namespace.value}-${name}`;
12993
+ const cssVarBlockName = (name) => `--${namespace.value}-${block}-${name}`;
12994
+ return {
12995
+ namespace,
12996
+ b,
12997
+ e,
12998
+ m,
12999
+ be,
13000
+ em,
13001
+ bm,
13002
+ bem,
13003
+ is,
13004
+ cssVar,
13005
+ cssVarName,
13006
+ cssVarBlock,
13007
+ cssVarBlockName
12903
13008
  };
12904
- return handleEvent;
12905
13009
  };
12906
13010
 
12907
- const isFirefox = () => isClient && /firefox/i.test(window.navigator.userAgent);
12908
-
12909
13011
  const isUndefined = (val) => val === void 0;
12910
13012
  const isBoolean = (val) => typeof val === "boolean";
12911
13013
  const isNumber = (val) => typeof val === "number";
@@ -12921,8 +13023,6 @@ const isStringNumber = (val) => {
12921
13023
  return !Number.isNaN(Number(val));
12922
13024
  };
12923
13025
 
12924
- const escapeStringRegexp = (string = "") => string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
12925
-
12926
13026
  class ElementPlusError extends Error {
12927
13027
  constructor(m) {
12928
13028
  super(m);
@@ -12935,165 +13035,32 @@ function throwError(scope, m) {
12935
13035
  function debugWarn(scope, message) {
12936
13036
  }
12937
13037
 
12938
- function addUnit(value, defaultUnit = "px") {
12939
- if (!value)
12940
- return "";
12941
- if (isNumber(value) || isStringNumber(value)) {
12942
- return `${value}${defaultUnit}`;
12943
- } else if (isString$1(value)) {
12944
- return value;
12945
- }
12946
- }
12947
-
12948
- function scrollIntoView(container, selected) {
12949
- if (!isClient)
12950
- return;
12951
- if (!selected) {
12952
- container.scrollTop = 0;
12953
- return;
12954
- }
12955
- const offsetParents = [];
12956
- let pointer = selected.offsetParent;
12957
- while (pointer !== null && container !== pointer && container.contains(pointer)) {
12958
- offsetParents.push(pointer);
12959
- pointer = pointer.offsetParent;
12960
- }
12961
- const top = selected.offsetTop + offsetParents.reduce((prev, curr) => prev + curr.offsetTop, 0);
12962
- const bottom = top + selected.offsetHeight;
12963
- const viewRectTop = container.scrollTop;
12964
- const viewRectBottom = viewRectTop + container.clientHeight;
12965
- if (top < viewRectTop) {
12966
- container.scrollTop = top;
12967
- } else if (bottom > viewRectBottom) {
12968
- container.scrollTop = bottom - container.clientHeight;
12969
- }
12970
- }
12971
-
12972
- const epPropKey = "__epPropKey";
12973
- const definePropType = (val) => val;
12974
- const isEpProp = (val) => isObject$1(val) && !!val[epPropKey];
12975
- const buildProp = (prop, key) => {
12976
- if (!isObject$1(prop) || isEpProp(prop))
12977
- return prop;
12978
- const { values, required, default: defaultValue, type, validator } = prop;
12979
- const _validator = values || validator ? (val) => {
12980
- let valid = false;
12981
- let allowedValues = [];
12982
- if (values) {
12983
- allowedValues = Array.from(values);
12984
- if (hasOwn(prop, "default")) {
12985
- allowedValues.push(defaultValue);
12986
- }
12987
- valid || (valid = allowedValues.includes(val));
12988
- }
12989
- if (validator)
12990
- valid || (valid = validator(val));
12991
- if (!valid && allowedValues.length > 0) {
12992
- const allowValuesText = [...new Set(allowedValues)].map((value) => JSON.stringify(value)).join(", ");
12993
- warn(`Invalid prop: validation failed${key ? ` for prop "${key}"` : ""}. Expected one of [${allowValuesText}], got value ${JSON.stringify(val)}.`);
12994
- }
12995
- return valid;
12996
- } : void 0;
12997
- const epProp = {
12998
- type,
12999
- required: !!required,
13000
- validator: _validator,
13001
- [epPropKey]: true
13002
- };
13003
- if (hasOwn(prop, "default"))
13004
- epProp.default = defaultValue;
13005
- return epProp;
13006
- };
13007
- const buildProps = (props) => fromPairs(Object.entries(props).map(([key, option]) => [
13008
- key,
13009
- buildProp(option, key)
13010
- ]));
13011
-
13012
- const iconPropType = definePropType([
13013
- String,
13014
- Object,
13015
- Function
13016
- ]);
13017
- const ValidateComponentsMap = {
13018
- validating: loading_default,
13019
- success: circle_check_default,
13020
- error: circle_close_default
13038
+ const initial = {
13039
+ current: 0
13021
13040
  };
13022
-
13023
- const withInstall = (main, extra) => {
13024
- main.install = (app) => {
13025
- for (const comp of [main, ...Object.values(extra != null ? extra : {})]) {
13026
- app.component(comp.name, comp);
13027
- }
13041
+ const zIndex = ref(0);
13042
+ const defaultInitialZIndex = 2e3;
13043
+ const ZINDEX_INJECTION_KEY = Symbol("elZIndexContextKey");
13044
+ const zIndexContextKey = Symbol("zIndexContextKey");
13045
+ const useZIndex = (zIndexOverrides) => {
13046
+ const increasingInjection = getCurrentInstance() ? inject(ZINDEX_INJECTION_KEY, initial) : initial;
13047
+ const zIndexInjection = zIndexOverrides || (getCurrentInstance() ? inject(zIndexContextKey, void 0) : void 0);
13048
+ const initialZIndex = computed(() => {
13049
+ const zIndexFromInjection = unref(zIndexInjection);
13050
+ return isNumber(zIndexFromInjection) ? zIndexFromInjection : defaultInitialZIndex;
13051
+ });
13052
+ const currentZIndex = computed(() => initialZIndex.value + zIndex.value);
13053
+ const nextZIndex = () => {
13054
+ increasingInjection.current++;
13055
+ zIndex.value = increasingInjection.current;
13056
+ return currentZIndex.value;
13028
13057
  };
13029
- if (extra) {
13030
- for (const [key, comp] of Object.entries(extra)) {
13031
- main[key] = comp;
13032
- }
13033
- }
13034
- return main;
13035
- };
13036
- const withInstallDirective = (directive, name) => {
13037
- directive.install = (app) => {
13038
- app.directive(name, directive);
13058
+ if (!isClient && !inject(ZINDEX_INJECTION_KEY)) ;
13059
+ return {
13060
+ initialZIndex,
13061
+ currentZIndex,
13062
+ nextZIndex
13039
13063
  };
13040
- return directive;
13041
- };
13042
- const withNoopInstall = (component) => {
13043
- component.install = NOOP;
13044
- return component;
13045
- };
13046
-
13047
- const EVENT_CODE = {
13048
- tab: "Tab",
13049
- enter: "Enter",
13050
- space: "Space",
13051
- left: "ArrowLeft",
13052
- up: "ArrowUp",
13053
- right: "ArrowRight",
13054
- down: "ArrowDown",
13055
- esc: "Escape",
13056
- delete: "Delete",
13057
- backspace: "Backspace",
13058
- numpadEnter: "NumpadEnter",
13059
- pageUp: "PageUp",
13060
- pageDown: "PageDown",
13061
- home: "Home",
13062
- end: "End"
13063
- };
13064
-
13065
- const UPDATE_MODEL_EVENT = "update:modelValue";
13066
- const CHANGE_EVENT = "change";
13067
- const INPUT_EVENT = "input";
13068
-
13069
- const componentSizes = ["", "default", "small", "large"];
13070
-
13071
- const isKorean = (text) => /([\uAC00-\uD7AF\u3130-\u318F])+/gi.test(text);
13072
-
13073
- const mutable = (val) => val;
13074
-
13075
- const DEFAULT_EXCLUDE_KEYS = ["class", "style"];
13076
- const LISTENER_PREFIX = /^on[A-Z]/;
13077
- const useAttrs = (params = {}) => {
13078
- const { excludeListeners = false, excludeKeys } = params;
13079
- const allExcludeKeys = computed(() => {
13080
- return ((excludeKeys == null ? void 0 : excludeKeys.value) || []).concat(DEFAULT_EXCLUDE_KEYS);
13081
- });
13082
- const instance = getCurrentInstance();
13083
- if (!instance) {
13084
- return computed(() => ({}));
13085
- }
13086
- return computed(() => {
13087
- var _a;
13088
- return fromPairs(Object.entries((_a = instance.proxy) == null ? void 0 : _a.$attrs).filter(([key]) => !allExcludeKeys.value.includes(key) && !(excludeListeners && LISTENER_PREFIX.test(key))));
13089
- });
13090
- };
13091
-
13092
- const useDeprecated = ({ from, replacement, scope, version, ref, type = "API" }, condition) => {
13093
- watch(() => unref(condition), (val) => {
13094
- }, {
13095
- immediate: true
13096
- });
13097
13064
  };
13098
13065
 
13099
13066
  var English = {
@@ -13296,627 +13263,61 @@ const useLocale = (localeOverrides) => {
13296
13263
  return buildLocaleContext(computed(() => locale.value || English));
13297
13264
  };
13298
13265
 
13299
- const defaultNamespace = "el";
13300
- const statePrefix = "is-";
13301
- const _bem = (namespace, block, blockSuffix, element, modifier) => {
13302
- let cls = `${namespace}-${block}`;
13303
- if (blockSuffix) {
13304
- cls += `-${blockSuffix}`;
13305
- }
13306
- if (element) {
13307
- cls += `__${element}`;
13308
- }
13309
- if (modifier) {
13310
- cls += `--${modifier}`;
13311
- }
13312
- return cls;
13313
- };
13314
- const namespaceContextKey = Symbol("namespaceContextKey");
13315
- const useGetDerivedNamespace = (namespaceOverrides) => {
13316
- const derivedNamespace = namespaceOverrides || (getCurrentInstance() ? inject(namespaceContextKey, ref(defaultNamespace)) : ref(defaultNamespace));
13317
- const namespace = computed(() => {
13318
- return unref(derivedNamespace) || defaultNamespace;
13319
- });
13320
- return namespace;
13321
- };
13322
- const useNamespace = (block, namespaceOverrides) => {
13323
- const namespace = useGetDerivedNamespace(namespaceOverrides);
13324
- const b = (blockSuffix = "") => _bem(namespace.value, block, blockSuffix, "", "");
13325
- const e = (element) => element ? _bem(namespace.value, block, "", element, "") : "";
13326
- const m = (modifier) => modifier ? _bem(namespace.value, block, "", "", modifier) : "";
13327
- const be = (blockSuffix, element) => blockSuffix && element ? _bem(namespace.value, block, blockSuffix, element, "") : "";
13328
- const em = (element, modifier) => element && modifier ? _bem(namespace.value, block, "", element, modifier) : "";
13329
- const bm = (blockSuffix, modifier) => blockSuffix && modifier ? _bem(namespace.value, block, blockSuffix, "", modifier) : "";
13330
- const bem = (blockSuffix, element, modifier) => blockSuffix && element && modifier ? _bem(namespace.value, block, blockSuffix, element, modifier) : "";
13331
- const is = (name, ...args) => {
13332
- const state = args.length >= 1 ? args[0] : true;
13333
- return name && state ? `${statePrefix}${name}` : "";
13334
- };
13335
- const cssVar = (object) => {
13336
- const styles = {};
13337
- for (const key in object) {
13338
- if (object[key]) {
13339
- styles[`--${namespace.value}-${key}`] = object[key];
13266
+ const epPropKey = "__epPropKey";
13267
+ const definePropType = (val) => val;
13268
+ const isEpProp = (val) => isObject$1(val) && !!val[epPropKey];
13269
+ const buildProp = (prop, key) => {
13270
+ if (!isObject$1(prop) || isEpProp(prop))
13271
+ return prop;
13272
+ const { values, required, default: defaultValue, type, validator } = prop;
13273
+ const _validator = values || validator ? (val) => {
13274
+ let valid = false;
13275
+ let allowedValues = [];
13276
+ if (values) {
13277
+ allowedValues = Array.from(values);
13278
+ if (hasOwn(prop, "default")) {
13279
+ allowedValues.push(defaultValue);
13340
13280
  }
13281
+ valid || (valid = allowedValues.includes(val));
13341
13282
  }
13342
- return styles;
13343
- };
13344
- const cssVarBlock = (object) => {
13345
- const styles = {};
13346
- for (const key in object) {
13347
- if (object[key]) {
13348
- styles[`--${namespace.value}-${block}-${key}`] = object[key];
13349
- }
13283
+ if (validator)
13284
+ valid || (valid = validator(val));
13285
+ if (!valid && allowedValues.length > 0) {
13286
+ const allowValuesText = [...new Set(allowedValues)].map((value) => JSON.stringify(value)).join(", ");
13287
+ warn(`Invalid prop: validation failed${key ? ` for prop "${key}"` : ""}. Expected one of [${allowValuesText}], got value ${JSON.stringify(val)}.`);
13350
13288
  }
13351
- return styles;
13352
- };
13353
- const cssVarName = (name) => `--${namespace.value}-${name}`;
13354
- const cssVarBlockName = (name) => `--${namespace.value}-${block}-${name}`;
13355
- return {
13356
- namespace,
13357
- b,
13358
- e,
13359
- m,
13360
- be,
13361
- em,
13362
- bm,
13363
- bem,
13364
- is,
13365
- cssVar,
13366
- cssVarName,
13367
- cssVarBlock,
13368
- cssVarBlockName
13289
+ return valid;
13290
+ } : void 0;
13291
+ const epProp = {
13292
+ type,
13293
+ required: !!required,
13294
+ validator: _validator,
13295
+ [epPropKey]: true
13369
13296
  };
13297
+ if (hasOwn(prop, "default"))
13298
+ epProp.default = defaultValue;
13299
+ return epProp;
13370
13300
  };
13301
+ const buildProps = (props) => fromPairs(Object.entries(props).map(([key, option]) => [
13302
+ key,
13303
+ buildProp(option, key)
13304
+ ]));
13371
13305
 
13372
- const _prop = buildProp({
13373
- type: definePropType(Boolean),
13374
- default: null
13375
- });
13376
- const _event = buildProp({
13377
- type: definePropType(Function)
13378
- });
13379
- const createModelToggleComposable = (name) => {
13380
- const updateEventKey = `update:${name}`;
13381
- const updateEventKeyRaw = `onUpdate:${name}`;
13382
- const useModelToggleEmits2 = [updateEventKey];
13383
- const useModelToggleProps2 = {
13384
- [name]: _prop,
13385
- [updateEventKeyRaw]: _event
13386
- };
13387
- const useModelToggle2 = ({
13388
- indicator,
13389
- toggleReason,
13390
- shouldHideWhenRouteChanges,
13391
- shouldProceed,
13392
- onShow,
13393
- onHide
13394
- }) => {
13395
- const instance = getCurrentInstance();
13396
- const { emit } = instance;
13397
- const props = instance.props;
13398
- const hasUpdateHandler = computed(() => isFunction$1(props[updateEventKeyRaw]));
13399
- const isModelBindingAbsent = computed(() => props[name] === null);
13400
- const doShow = (event) => {
13401
- if (indicator.value === true) {
13402
- return;
13403
- }
13404
- indicator.value = true;
13405
- if (toggleReason) {
13406
- toggleReason.value = event;
13407
- }
13408
- if (isFunction$1(onShow)) {
13409
- onShow(event);
13410
- }
13411
- };
13412
- const doHide = (event) => {
13413
- if (indicator.value === false) {
13414
- return;
13415
- }
13416
- indicator.value = false;
13417
- if (toggleReason) {
13418
- toggleReason.value = event;
13419
- }
13420
- if (isFunction$1(onHide)) {
13421
- onHide(event);
13422
- }
13423
- };
13424
- const show = (event) => {
13425
- if (props.disabled === true || isFunction$1(shouldProceed) && !shouldProceed())
13426
- return;
13427
- const shouldEmit = hasUpdateHandler.value && isClient;
13428
- if (shouldEmit) {
13429
- emit(updateEventKey, true);
13430
- }
13431
- if (isModelBindingAbsent.value || !shouldEmit) {
13432
- doShow(event);
13433
- }
13434
- };
13435
- const hide = (event) => {
13436
- if (props.disabled === true || !isClient)
13437
- return;
13438
- const shouldEmit = hasUpdateHandler.value && isClient;
13439
- if (shouldEmit) {
13440
- emit(updateEventKey, false);
13441
- }
13442
- if (isModelBindingAbsent.value || !shouldEmit) {
13443
- doHide(event);
13444
- }
13445
- };
13446
- const onChange = (val) => {
13447
- if (!isBoolean(val))
13448
- return;
13449
- if (props.disabled && val) {
13450
- if (hasUpdateHandler.value) {
13451
- emit(updateEventKey, false);
13452
- }
13453
- } else if (indicator.value !== val) {
13454
- if (val) {
13455
- doShow();
13456
- } else {
13457
- doHide();
13458
- }
13459
- }
13460
- };
13461
- const toggle = () => {
13462
- if (indicator.value) {
13463
- hide();
13464
- } else {
13465
- show();
13466
- }
13467
- };
13468
- watch(() => props[name], onChange);
13469
- if (shouldHideWhenRouteChanges && instance.appContext.config.globalProperties.$route !== void 0) {
13470
- watch(() => ({
13471
- ...instance.proxy.$route
13472
- }), () => {
13473
- if (shouldHideWhenRouteChanges.value && indicator.value) {
13474
- hide();
13475
- }
13476
- });
13477
- }
13478
- onMounted(() => {
13479
- onChange(props[name]);
13480
- });
13481
- return {
13482
- hide,
13483
- show,
13484
- toggle,
13485
- hasUpdateHandler
13486
- };
13487
- };
13488
- return {
13489
- useModelToggle: useModelToggle2,
13490
- useModelToggleProps: useModelToggleProps2,
13491
- useModelToggleEmits: useModelToggleEmits2
13492
- };
13493
- };
13306
+ const componentSizes = ["", "default", "small", "large"];
13494
13307
 
13495
- const useProp = (name) => {
13496
- const vm = getCurrentInstance();
13308
+ const useSizeProp = buildProp({
13309
+ type: String,
13310
+ values: componentSizes,
13311
+ required: false
13312
+ });
13313
+ const SIZE_INJECTION_KEY = Symbol("size");
13314
+ const useGlobalSize = () => {
13315
+ const injectedSize = inject(SIZE_INJECTION_KEY, {});
13497
13316
  return computed(() => {
13498
- var _a, _b;
13499
- return (_b = (_a = vm == null ? void 0 : vm.proxy) == null ? void 0 : _a.$props) == null ? void 0 : _b[name];
13317
+ return unref(injectedSize.size) || "";
13500
13318
  });
13501
13319
  };
13502
13320
 
13503
- var E="top",R="bottom",W="right",P="left",me="auto",G=[E,R,W,P],U="start",J="end",Xe="clippingParents",je="viewport",K="popper",Ye="reference",De=G.reduce(function(t,e){return t.concat([e+"-"+U,e+"-"+J])},[]),Ee=[].concat(G,[me]).reduce(function(t,e){return t.concat([e,e+"-"+U,e+"-"+J])},[]),Ge="beforeRead",Je="read",Ke="afterRead",Qe="beforeMain",Ze="main",et="afterMain",tt="beforeWrite",nt="write",rt="afterWrite",ot=[Ge,Je,Ke,Qe,Ze,et,tt,nt,rt];function C(t){return t?(t.nodeName||"").toLowerCase():null}function H(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function Q(t){var e=H(t).Element;return t instanceof e||t instanceof Element}function B(t){var e=H(t).HTMLElement;return t instanceof e||t instanceof HTMLElement}function Pe(t){if(typeof ShadowRoot=="undefined")return !1;var e=H(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}function Mt(t){var e=t.state;Object.keys(e.elements).forEach(function(n){var r=e.styles[n]||{},o=e.attributes[n]||{},i=e.elements[n];!B(i)||!C(i)||(Object.assign(i.style,r),Object.keys(o).forEach(function(a){var s=o[a];s===!1?i.removeAttribute(a):i.setAttribute(a,s===!0?"":s);}));});}function Rt(t){var e=t.state,n={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,n.popper),e.styles=n,e.elements.arrow&&Object.assign(e.elements.arrow.style,n.arrow),function(){Object.keys(e.elements).forEach(function(r){var o=e.elements[r],i=e.attributes[r]||{},a=Object.keys(e.styles.hasOwnProperty(r)?e.styles[r]:n[r]),s=a.reduce(function(f,c){return f[c]="",f},{});!B(o)||!C(o)||(Object.assign(o.style,s),Object.keys(i).forEach(function(f){o.removeAttribute(f);}));});}}var Ae={name:"applyStyles",enabled:!0,phase:"write",fn:Mt,effect:Rt,requires:["computeStyles"]};function q(t){return t.split("-")[0]}var X=Math.max,ve=Math.min,Z=Math.round;function ee(t,e){e===void 0&&(e=!1);var n=t.getBoundingClientRect(),r=1,o=1;if(B(t)&&e){var i=t.offsetHeight,a=t.offsetWidth;a>0&&(r=Z(n.width)/a||1),i>0&&(o=Z(n.height)/i||1);}return {width:n.width/r,height:n.height/o,top:n.top/o,right:n.right/r,bottom:n.bottom/o,left:n.left/r,x:n.left/r,y:n.top/o}}function ke(t){var e=ee(t),n=t.offsetWidth,r=t.offsetHeight;return Math.abs(e.width-n)<=1&&(n=e.width),Math.abs(e.height-r)<=1&&(r=e.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:r}}function it(t,e){var n=e.getRootNode&&e.getRootNode();if(t.contains(e))return !0;if(n&&Pe(n)){var r=e;do{if(r&&t.isSameNode(r))return !0;r=r.parentNode||r.host;}while(r)}return !1}function N(t){return H(t).getComputedStyle(t)}function Wt(t){return ["table","td","th"].indexOf(C(t))>=0}function I(t){return ((Q(t)?t.ownerDocument:t.document)||window.document).documentElement}function ge(t){return C(t)==="html"?t:t.assignedSlot||t.parentNode||(Pe(t)?t.host:null)||I(t)}function at(t){return !B(t)||N(t).position==="fixed"?null:t.offsetParent}function Bt(t){var e=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,n=navigator.userAgent.indexOf("Trident")!==-1;if(n&&B(t)){var r=N(t);if(r.position==="fixed")return null}var o=ge(t);for(Pe(o)&&(o=o.host);B(o)&&["html","body"].indexOf(C(o))<0;){var i=N(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||e&&i.willChange==="filter"||e&&i.filter&&i.filter!=="none")return o;o=o.parentNode;}return null}function se(t){for(var e=H(t),n=at(t);n&&Wt(n)&&N(n).position==="static";)n=at(n);return n&&(C(n)==="html"||C(n)==="body"&&N(n).position==="static")?e:n||Bt(t)||e}function Le(t){return ["top","bottom"].indexOf(t)>=0?"x":"y"}function fe(t,e,n){return X(t,ve(e,n))}function St(t,e,n){var r=fe(t,e,n);return r>n?n:r}function st(){return {top:0,right:0,bottom:0,left:0}}function ft(t){return Object.assign({},st(),t)}function ct(t,e){return e.reduce(function(n,r){return n[r]=t,n},{})}var Tt=function(t,e){return t=typeof t=="function"?t(Object.assign({},e.rects,{placement:e.placement})):t,ft(typeof t!="number"?t:ct(t,G))};function Ht(t){var e,n=t.state,r=t.name,o=t.options,i=n.elements.arrow,a=n.modifiersData.popperOffsets,s=q(n.placement),f=Le(s),c=[P,W].indexOf(s)>=0,u=c?"height":"width";if(!(!i||!a)){var m=Tt(o.padding,n),v=ke(i),l=f==="y"?E:P,h=f==="y"?R:W,p=n.rects.reference[u]+n.rects.reference[f]-a[f]-n.rects.popper[u],g=a[f]-n.rects.reference[f],x=se(i),y=x?f==="y"?x.clientHeight||0:x.clientWidth||0:0,$=p/2-g/2,d=m[l],b=y-v[u]-m[h],w=y/2-v[u]/2+$,O=fe(d,w,b),j=f;n.modifiersData[r]=(e={},e[j]=O,e.centerOffset=O-w,e);}}function Ct(t){var e=t.state,n=t.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=e.elements.popper.querySelector(o),!o)||!it(e.elements.popper,o)||(e.elements.arrow=o));}var pt={name:"arrow",enabled:!0,phase:"main",fn:Ht,effect:Ct,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function te(t){return t.split("-")[1]}var qt={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Vt(t){var e=t.x,n=t.y,r=window,o=r.devicePixelRatio||1;return {x:Z(e*o)/o||0,y:Z(n*o)/o||0}}function ut(t){var e,n=t.popper,r=t.popperRect,o=t.placement,i=t.variation,a=t.offsets,s=t.position,f=t.gpuAcceleration,c=t.adaptive,u=t.roundOffsets,m=t.isFixed,v=a.x,l=v===void 0?0:v,h=a.y,p=h===void 0?0:h,g=typeof u=="function"?u({x:l,y:p}):{x:l,y:p};l=g.x,p=g.y;var x=a.hasOwnProperty("x"),y=a.hasOwnProperty("y"),$=P,d=E,b=window;if(c){var w=se(n),O="clientHeight",j="clientWidth";if(w===H(n)&&(w=I(n),N(w).position!=="static"&&s==="absolute"&&(O="scrollHeight",j="scrollWidth")),w=w,o===E||(o===P||o===W)&&i===J){d=R;var A=m&&w===b&&b.visualViewport?b.visualViewport.height:w[O];p-=A-r.height,p*=f?1:-1;}if(o===P||(o===E||o===R)&&i===J){$=W;var k=m&&w===b&&b.visualViewport?b.visualViewport.width:w[j];l-=k-r.width,l*=f?1:-1;}}var D=Object.assign({position:s},c&&qt),S=u===!0?Vt({x:l,y:p}):{x:l,y:p};if(l=S.x,p=S.y,f){var L;return Object.assign({},D,(L={},L[d]=y?"0":"",L[$]=x?"0":"",L.transform=(b.devicePixelRatio||1)<=1?"translate("+l+"px, "+p+"px)":"translate3d("+l+"px, "+p+"px, 0)",L))}return Object.assign({},D,(e={},e[d]=y?p+"px":"",e[$]=x?l+"px":"",e.transform="",e))}function Nt(t){var e=t.state,n=t.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,a=i===void 0?!0:i,s=n.roundOffsets,f=s===void 0?!0:s,c={placement:q(e.placement),variation:te(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:e.options.strategy==="fixed"};e.modifiersData.popperOffsets!=null&&(e.styles.popper=Object.assign({},e.styles.popper,ut(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:a,roundOffsets:f})))),e.modifiersData.arrow!=null&&(e.styles.arrow=Object.assign({},e.styles.arrow,ut(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:f})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement});}var Me={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Nt,data:{}},ye={passive:!0};function It(t){var e=t.state,n=t.instance,r=t.options,o=r.scroll,i=o===void 0?!0:o,a=r.resize,s=a===void 0?!0:a,f=H(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return i&&c.forEach(function(u){u.addEventListener("scroll",n.update,ye);}),s&&f.addEventListener("resize",n.update,ye),function(){i&&c.forEach(function(u){u.removeEventListener("scroll",n.update,ye);}),s&&f.removeEventListener("resize",n.update,ye);}}var Re={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:It,data:{}},_t={left:"right",right:"left",bottom:"top",top:"bottom"};function be(t){return t.replace(/left|right|bottom|top/g,function(e){return _t[e]})}var zt={start:"end",end:"start"};function lt(t){return t.replace(/start|end/g,function(e){return zt[e]})}function We(t){var e=H(t),n=e.pageXOffset,r=e.pageYOffset;return {scrollLeft:n,scrollTop:r}}function Be(t){return ee(I(t)).left+We(t).scrollLeft}function Ft(t){var e=H(t),n=I(t),r=e.visualViewport,o=n.clientWidth,i=n.clientHeight,a=0,s=0;return r&&(o=r.width,i=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(a=r.offsetLeft,s=r.offsetTop)),{width:o,height:i,x:a+Be(t),y:s}}function Ut(t){var e,n=I(t),r=We(t),o=(e=t.ownerDocument)==null?void 0:e.body,i=X(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),a=X(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),s=-r.scrollLeft+Be(t),f=-r.scrollTop;return N(o||n).direction==="rtl"&&(s+=X(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:a,x:s,y:f}}function Se(t){var e=N(t),n=e.overflow,r=e.overflowX,o=e.overflowY;return /auto|scroll|overlay|hidden/.test(n+o+r)}function dt(t){return ["html","body","#document"].indexOf(C(t))>=0?t.ownerDocument.body:B(t)&&Se(t)?t:dt(ge(t))}function ce(t,e){var n;e===void 0&&(e=[]);var r=dt(t),o=r===((n=t.ownerDocument)==null?void 0:n.body),i=H(r),a=o?[i].concat(i.visualViewport||[],Se(r)?r:[]):r,s=e.concat(a);return o?s:s.concat(ce(ge(a)))}function Te(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Xt(t){var e=ee(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}function ht(t,e){return e===je?Te(Ft(t)):Q(e)?Xt(e):Te(Ut(I(t)))}function Yt(t){var e=ce(ge(t)),n=["absolute","fixed"].indexOf(N(t).position)>=0,r=n&&B(t)?se(t):t;return Q(r)?e.filter(function(o){return Q(o)&&it(o,r)&&C(o)!=="body"}):[]}function Gt(t,e,n){var r=e==="clippingParents"?Yt(t):[].concat(e),o=[].concat(r,[n]),i=o[0],a=o.reduce(function(s,f){var c=ht(t,f);return s.top=X(c.top,s.top),s.right=ve(c.right,s.right),s.bottom=ve(c.bottom,s.bottom),s.left=X(c.left,s.left),s},ht(t,i));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function mt(t){var e=t.reference,n=t.element,r=t.placement,o=r?q(r):null,i=r?te(r):null,a=e.x+e.width/2-n.width/2,s=e.y+e.height/2-n.height/2,f;switch(o){case E:f={x:a,y:e.y-n.height};break;case R:f={x:a,y:e.y+e.height};break;case W:f={x:e.x+e.width,y:s};break;case P:f={x:e.x-n.width,y:s};break;default:f={x:e.x,y:e.y};}var c=o?Le(o):null;if(c!=null){var u=c==="y"?"height":"width";switch(i){case U:f[c]=f[c]-(e[u]/2-n[u]/2);break;case J:f[c]=f[c]+(e[u]/2-n[u]/2);break}}return f}function ne(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=r===void 0?t.placement:r,i=n.boundary,a=i===void 0?Xe:i,s=n.rootBoundary,f=s===void 0?je:s,c=n.elementContext,u=c===void 0?K:c,m=n.altBoundary,v=m===void 0?!1:m,l=n.padding,h=l===void 0?0:l,p=ft(typeof h!="number"?h:ct(h,G)),g=u===K?Ye:K,x=t.rects.popper,y=t.elements[v?g:u],$=Gt(Q(y)?y:y.contextElement||I(t.elements.popper),a,f),d=ee(t.elements.reference),b=mt({reference:d,element:x,strategy:"absolute",placement:o}),w=Te(Object.assign({},x,b)),O=u===K?w:d,j={top:$.top-O.top+p.top,bottom:O.bottom-$.bottom+p.bottom,left:$.left-O.left+p.left,right:O.right-$.right+p.right},A=t.modifiersData.offset;if(u===K&&A){var k=A[o];Object.keys(j).forEach(function(D){var S=[W,R].indexOf(D)>=0?1:-1,L=[E,R].indexOf(D)>=0?"y":"x";j[D]+=k[L]*S;});}return j}function Jt(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=n.boundary,i=n.rootBoundary,a=n.padding,s=n.flipVariations,f=n.allowedAutoPlacements,c=f===void 0?Ee:f,u=te(r),m=u?s?De:De.filter(function(h){return te(h)===u}):G,v=m.filter(function(h){return c.indexOf(h)>=0});v.length===0&&(v=m);var l=v.reduce(function(h,p){return h[p]=ne(t,{placement:p,boundary:o,rootBoundary:i,padding:a})[q(p)],h},{});return Object.keys(l).sort(function(h,p){return l[h]-l[p]})}function Kt(t){if(q(t)===me)return [];var e=be(t);return [lt(t),e,lt(e)]}function Qt(t){var e=t.state,n=t.options,r=t.name;if(!e.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!0:a,f=n.fallbackPlacements,c=n.padding,u=n.boundary,m=n.rootBoundary,v=n.altBoundary,l=n.flipVariations,h=l===void 0?!0:l,p=n.allowedAutoPlacements,g=e.options.placement,x=q(g),y=x===g,$=f||(y||!h?[be(g)]:Kt(g)),d=[g].concat($).reduce(function(z,V){return z.concat(q(V)===me?Jt(e,{placement:V,boundary:u,rootBoundary:m,padding:c,flipVariations:h,allowedAutoPlacements:p}):V)},[]),b=e.rects.reference,w=e.rects.popper,O=new Map,j=!0,A=d[0],k=0;k<d.length;k++){var D=d[k],S=q(D),L=te(D)===U,re=[E,R].indexOf(S)>=0,oe=re?"width":"height",M=ne(e,{placement:D,boundary:u,rootBoundary:m,altBoundary:v,padding:c}),T=re?L?W:P:L?R:E;b[oe]>w[oe]&&(T=be(T));var pe=be(T),_=[];if(i&&_.push(M[S]<=0),s&&_.push(M[T]<=0,M[pe]<=0),_.every(function(z){return z})){A=D,j=!1;break}O.set(D,_);}if(j)for(var ue=h?3:1,xe=function(z){var V=d.find(function(de){var ae=O.get(de);if(ae)return ae.slice(0,z).every(function(Y){return Y})});if(V)return A=V,"break"},ie=ue;ie>0;ie--){var le=xe(ie);if(le==="break")break}e.placement!==A&&(e.modifiersData[r]._skip=!0,e.placement=A,e.reset=!0);}}var vt={name:"flip",enabled:!0,phase:"main",fn:Qt,requiresIfExists:["offset"],data:{_skip:!1}};function gt(t,e,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function yt(t){return [E,W,R,P].some(function(e){return t[e]>=0})}function Zt(t){var e=t.state,n=t.name,r=e.rects.reference,o=e.rects.popper,i=e.modifiersData.preventOverflow,a=ne(e,{elementContext:"reference"}),s=ne(e,{altBoundary:!0}),f=gt(a,r),c=gt(s,o,i),u=yt(f),m=yt(c);e.modifiersData[n]={referenceClippingOffsets:f,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:m},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":m});}var bt={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Zt};function en(t,e,n){var r=q(t),o=[P,E].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},e,{placement:t})):n,a=i[0],s=i[1];return a=a||0,s=(s||0)*o,[P,W].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function tn(t){var e=t.state,n=t.options,r=t.name,o=n.offset,i=o===void 0?[0,0]:o,a=Ee.reduce(function(u,m){return u[m]=en(m,e.rects,i),u},{}),s=a[e.placement],f=s.x,c=s.y;e.modifiersData.popperOffsets!=null&&(e.modifiersData.popperOffsets.x+=f,e.modifiersData.popperOffsets.y+=c),e.modifiersData[r]=a;}var wt={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:tn};function nn(t){var e=t.state,n=t.name;e.modifiersData[n]=mt({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement});}var He={name:"popperOffsets",enabled:!0,phase:"read",fn:nn,data:{}};function rn(t){return t==="x"?"y":"x"}function on(t){var e=t.state,n=t.options,r=t.name,o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!1:a,f=n.boundary,c=n.rootBoundary,u=n.altBoundary,m=n.padding,v=n.tether,l=v===void 0?!0:v,h=n.tetherOffset,p=h===void 0?0:h,g=ne(e,{boundary:f,rootBoundary:c,padding:m,altBoundary:u}),x=q(e.placement),y=te(e.placement),$=!y,d=Le(x),b=rn(d),w=e.modifiersData.popperOffsets,O=e.rects.reference,j=e.rects.popper,A=typeof p=="function"?p(Object.assign({},e.rects,{placement:e.placement})):p,k=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),D=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,S={x:0,y:0};if(w){if(i){var L,re=d==="y"?E:P,oe=d==="y"?R:W,M=d==="y"?"height":"width",T=w[d],pe=T+g[re],_=T-g[oe],ue=l?-j[M]/2:0,xe=y===U?O[M]:j[M],ie=y===U?-j[M]:-O[M],le=e.elements.arrow,z=l&&le?ke(le):{width:0,height:0},V=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:st(),de=V[re],ae=V[oe],Y=fe(0,O[M],z[M]),jt=$?O[M]/2-ue-Y-de-k.mainAxis:xe-Y-de-k.mainAxis,Dt=$?-O[M]/2+ue+Y+ae+k.mainAxis:ie+Y+ae+k.mainAxis,Oe=e.elements.arrow&&se(e.elements.arrow),Et=Oe?d==="y"?Oe.clientTop||0:Oe.clientLeft||0:0,Ce=(L=D==null?void 0:D[d])!=null?L:0,Pt=T+jt-Ce-Et,At=T+Dt-Ce,qe=fe(l?ve(pe,Pt):pe,T,l?X(_,At):_);w[d]=qe,S[d]=qe-T;}if(s){var Ve,kt=d==="x"?E:P,Lt=d==="x"?R:W,F=w[b],he=b==="y"?"height":"width",Ne=F+g[kt],Ie=F-g[Lt],$e=[E,P].indexOf(x)!==-1,_e=(Ve=D==null?void 0:D[b])!=null?Ve:0,ze=$e?Ne:F-O[he]-j[he]-_e+k.altAxis,Fe=$e?F+O[he]+j[he]-_e-k.altAxis:Ie,Ue=l&&$e?St(ze,F,Fe):fe(l?ze:Ne,F,l?Fe:Ie);w[b]=Ue,S[b]=Ue-F;}e.modifiersData[r]=S;}}var xt={name:"preventOverflow",enabled:!0,phase:"main",fn:on,requiresIfExists:["offset"]};function an(t){return {scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function sn(t){return t===H(t)||!B(t)?We(t):an(t)}function fn(t){var e=t.getBoundingClientRect(),n=Z(e.width)/t.offsetWidth||1,r=Z(e.height)/t.offsetHeight||1;return n!==1||r!==1}function cn(t,e,n){n===void 0&&(n=!1);var r=B(e),o=B(e)&&fn(e),i=I(e),a=ee(t,o),s={scrollLeft:0,scrollTop:0},f={x:0,y:0};return (r||!r&&!n)&&((C(e)!=="body"||Se(i))&&(s=sn(e)),B(e)?(f=ee(e,!0),f.x+=e.clientLeft,f.y+=e.clientTop):i&&(f.x=Be(i))),{x:a.left+s.scrollLeft-f.x,y:a.top+s.scrollTop-f.y,width:a.width,height:a.height}}function pn(t){var e=new Map,n=new Set,r=[];t.forEach(function(i){e.set(i.name,i);});function o(i){n.add(i.name);var a=[].concat(i.requires||[],i.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var f=e.get(s);f&&o(f);}}),r.push(i);}return t.forEach(function(i){n.has(i.name)||o(i);}),r}function un(t){var e=pn(t);return ot.reduce(function(n,r){return n.concat(e.filter(function(o){return o.phase===r}))},[])}function ln(t){var e;return function(){return e||(e=new Promise(function(n){Promise.resolve().then(function(){e=void 0,n(t());});})),e}}function dn(t){var e=t.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(e).map(function(n){return e[n]})}var Ot={placement:"bottom",modifiers:[],strategy:"absolute"};function $t(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return !e.some(function(r){return !(r&&typeof r.getBoundingClientRect=="function")})}function we(t){t===void 0&&(t={});var e=t,n=e.defaultModifiers,r=n===void 0?[]:n,o=e.defaultOptions,i=o===void 0?Ot:o;return function(a,s,f){f===void 0&&(f=i);var c={placement:"bottom",orderedModifiers:[],options:Object.assign({},Ot,i),modifiersData:{},elements:{reference:a,popper:s},attributes:{},styles:{}},u=[],m=!1,v={state:c,setOptions:function(p){var g=typeof p=="function"?p(c.options):p;h(),c.options=Object.assign({},i,c.options,g),c.scrollParents={reference:Q(a)?ce(a):a.contextElement?ce(a.contextElement):[],popper:ce(s)};var x=un(dn([].concat(r,c.options.modifiers)));return c.orderedModifiers=x.filter(function(y){return y.enabled}),l(),v.update()},forceUpdate:function(){if(!m){var p=c.elements,g=p.reference,x=p.popper;if($t(g,x)){c.rects={reference:cn(g,se(x),c.options.strategy==="fixed"),popper:ke(x)},c.reset=!1,c.placement=c.options.placement,c.orderedModifiers.forEach(function(j){return c.modifiersData[j.name]=Object.assign({},j.data)});for(var y=0;y<c.orderedModifiers.length;y++){if(c.reset===!0){c.reset=!1,y=-1;continue}var $=c.orderedModifiers[y],d=$.fn,b=$.options,w=b===void 0?{}:b,O=$.name;typeof d=="function"&&(c=d({state:c,options:w,name:O,instance:v})||c);}}}},update:ln(function(){return new Promise(function(p){v.forceUpdate(),p(c);})}),destroy:function(){h(),m=!0;}};if(!$t(a,s))return v;v.setOptions(f).then(function(p){!m&&f.onFirstUpdate&&f.onFirstUpdate(p);});function l(){c.orderedModifiers.forEach(function(p){var g=p.name,x=p.options,y=x===void 0?{}:x,$=p.effect;if(typeof $=="function"){var d=$({state:c,name:g,instance:v,options:y}),b=function(){};u.push(d||b);}});}function h(){u.forEach(function(p){return p()}),u=[];}return v}}we();var mn=[Re,He,Me,Ae];we({defaultModifiers:mn});var gn=[Re,He,Me,Ae,wt,vt,xt,pt,bt],yn=we({defaultModifiers:gn});
13504
-
13505
- const usePopper = (referenceElementRef, popperElementRef, opts = {}) => {
13506
- const stateUpdater = {
13507
- name: "updateState",
13508
- enabled: true,
13509
- phase: "write",
13510
- fn: ({ state }) => {
13511
- const derivedState = deriveState(state);
13512
- Object.assign(states.value, derivedState);
13513
- },
13514
- requires: ["computeStyles"]
13515
- };
13516
- const options = computed(() => {
13517
- const { onFirstUpdate, placement, strategy, modifiers } = unref(opts);
13518
- return {
13519
- onFirstUpdate,
13520
- placement: placement || "bottom",
13521
- strategy: strategy || "absolute",
13522
- modifiers: [
13523
- ...modifiers || [],
13524
- stateUpdater,
13525
- { name: "applyStyles", enabled: false }
13526
- ]
13527
- };
13528
- });
13529
- const instanceRef = shallowRef();
13530
- const states = ref({
13531
- styles: {
13532
- popper: {
13533
- position: unref(options).strategy,
13534
- left: "0",
13535
- top: "0"
13536
- },
13537
- arrow: {
13538
- position: "absolute"
13539
- }
13540
- },
13541
- attributes: {}
13542
- });
13543
- const destroy = () => {
13544
- if (!instanceRef.value)
13545
- return;
13546
- instanceRef.value.destroy();
13547
- instanceRef.value = void 0;
13548
- };
13549
- watch(options, (newOptions) => {
13550
- const instance = unref(instanceRef);
13551
- if (instance) {
13552
- instance.setOptions(newOptions);
13553
- }
13554
- }, {
13555
- deep: true
13556
- });
13557
- watch([referenceElementRef, popperElementRef], ([referenceElement, popperElement]) => {
13558
- destroy();
13559
- if (!referenceElement || !popperElement)
13560
- return;
13561
- instanceRef.value = yn(referenceElement, popperElement, unref(options));
13562
- });
13563
- onBeforeUnmount(() => {
13564
- destroy();
13565
- });
13566
- return {
13567
- state: computed(() => {
13568
- var _a;
13569
- return { ...((_a = unref(instanceRef)) == null ? void 0 : _a.state) || {} };
13570
- }),
13571
- styles: computed(() => unref(states).styles),
13572
- attributes: computed(() => unref(states).attributes),
13573
- update: () => {
13574
- var _a;
13575
- return (_a = unref(instanceRef)) == null ? void 0 : _a.update();
13576
- },
13577
- forceUpdate: () => {
13578
- var _a;
13579
- return (_a = unref(instanceRef)) == null ? void 0 : _a.forceUpdate();
13580
- },
13581
- instanceRef: computed(() => unref(instanceRef))
13582
- };
13583
- };
13584
- function deriveState(state) {
13585
- const elements = Object.keys(state.elements);
13586
- const styles = fromPairs(elements.map((element) => [element, state.styles[element] || {}]));
13587
- const attributes = fromPairs(elements.map((element) => [element, state.attributes[element]]));
13588
- return {
13589
- styles,
13590
- attributes
13591
- };
13592
- }
13593
-
13594
- function useTimeout() {
13595
- let timeoutHandle;
13596
- const registerTimeout = (fn, delay) => {
13597
- cancelTimeout();
13598
- timeoutHandle = window.setTimeout(fn, delay);
13599
- };
13600
- const cancelTimeout = () => window.clearTimeout(timeoutHandle);
13601
- tryOnScopeDispose(() => cancelTimeout());
13602
- return {
13603
- registerTimeout,
13604
- cancelTimeout
13605
- };
13606
- }
13607
-
13608
- const defaultIdInjection = {
13609
- prefix: Math.floor(Math.random() * 1e4),
13610
- current: 0
13611
- };
13612
- const ID_INJECTION_KEY = Symbol("elIdInjection");
13613
- const useIdInjection = () => {
13614
- return getCurrentInstance() ? inject(ID_INJECTION_KEY, defaultIdInjection) : defaultIdInjection;
13615
- };
13616
- const useId = (deterministicId) => {
13617
- const idInjection = useIdInjection();
13618
- const namespace = useGetDerivedNamespace();
13619
- const idRef = computed(() => unref(deterministicId) || `${namespace.value}-id-${idInjection.prefix}-${idInjection.current++}`);
13620
- return idRef;
13621
- };
13622
-
13623
- let registeredEscapeHandlers = [];
13624
- const cachedHandler = (e) => {
13625
- const event = e;
13626
- if (event.key === EVENT_CODE.esc) {
13627
- registeredEscapeHandlers.forEach((registeredHandler) => registeredHandler(event));
13628
- }
13629
- };
13630
- const useEscapeKeydown = (handler) => {
13631
- onMounted(() => {
13632
- if (registeredEscapeHandlers.length === 0) {
13633
- document.addEventListener("keydown", cachedHandler);
13634
- }
13635
- if (isClient)
13636
- registeredEscapeHandlers.push(handler);
13637
- });
13638
- onBeforeUnmount(() => {
13639
- registeredEscapeHandlers = registeredEscapeHandlers.filter((registeredHandler) => registeredHandler !== handler);
13640
- if (registeredEscapeHandlers.length === 0) {
13641
- if (isClient)
13642
- document.removeEventListener("keydown", cachedHandler);
13643
- }
13644
- });
13645
- };
13646
-
13647
- let cachedContainer;
13648
- const usePopperContainerId = () => {
13649
- const namespace = useGetDerivedNamespace();
13650
- const idInjection = useIdInjection();
13651
- const id = computed(() => {
13652
- return `${namespace.value}-popper-container-${idInjection.prefix}`;
13653
- });
13654
- const selector = computed(() => `#${id.value}`);
13655
- return {
13656
- id,
13657
- selector
13658
- };
13659
- };
13660
- const createContainer = (id) => {
13661
- const container = document.createElement("div");
13662
- container.id = id;
13663
- document.body.appendChild(container);
13664
- return container;
13665
- };
13666
- const usePopperContainer = () => {
13667
- const { id, selector } = usePopperContainerId();
13668
- onBeforeMount(() => {
13669
- if (!isClient)
13670
- return;
13671
- if (!cachedContainer || !document.body.querySelector(selector.value)) {
13672
- cachedContainer = createContainer(id.value);
13673
- }
13674
- });
13675
- return {
13676
- id,
13677
- selector
13678
- };
13679
- };
13680
-
13681
- const useDelayedToggleProps = buildProps({
13682
- showAfter: {
13683
- type: Number,
13684
- default: 0
13685
- },
13686
- hideAfter: {
13687
- type: Number,
13688
- default: 200
13689
- },
13690
- autoClose: {
13691
- type: Number,
13692
- default: 0
13693
- }
13694
- });
13695
- const useDelayedToggle = ({
13696
- showAfter,
13697
- hideAfter,
13698
- autoClose,
13699
- open,
13700
- close
13701
- }) => {
13702
- const { registerTimeout } = useTimeout();
13703
- const {
13704
- registerTimeout: registerTimeoutForAutoClose,
13705
- cancelTimeout: cancelTimeoutForAutoClose
13706
- } = useTimeout();
13707
- const onOpen = (event) => {
13708
- registerTimeout(() => {
13709
- open(event);
13710
- const _autoClose = unref(autoClose);
13711
- if (isNumber(_autoClose) && _autoClose > 0) {
13712
- registerTimeoutForAutoClose(() => {
13713
- close(event);
13714
- }, _autoClose);
13715
- }
13716
- }, unref(showAfter));
13717
- };
13718
- const onClose = (event) => {
13719
- cancelTimeoutForAutoClose();
13720
- registerTimeout(() => {
13721
- close(event);
13722
- }, unref(hideAfter));
13723
- };
13724
- return {
13725
- onOpen,
13726
- onClose
13727
- };
13728
- };
13729
-
13730
- const FORWARD_REF_INJECTION_KEY = Symbol("elForwardRef");
13731
- const useForwardRef = (forwardRef) => {
13732
- const setForwardRef = (el) => {
13733
- forwardRef.value = el;
13734
- };
13735
- provide(FORWARD_REF_INJECTION_KEY, {
13736
- setForwardRef
13737
- });
13738
- };
13739
- const useForwardRefDirective = (setForwardRef) => {
13740
- return {
13741
- mounted(el) {
13742
- setForwardRef(el);
13743
- },
13744
- updated(el) {
13745
- setForwardRef(el);
13746
- },
13747
- unmounted() {
13748
- setForwardRef(null);
13749
- }
13750
- };
13751
- };
13752
-
13753
- const initial = {
13754
- current: 0
13755
- };
13756
- const zIndex = ref(0);
13757
- const defaultInitialZIndex = 2e3;
13758
- const ZINDEX_INJECTION_KEY = Symbol("elZIndexContextKey");
13759
- const zIndexContextKey = Symbol("zIndexContextKey");
13760
- const useZIndex = (zIndexOverrides) => {
13761
- const increasingInjection = getCurrentInstance() ? inject(ZINDEX_INJECTION_KEY, initial) : initial;
13762
- const zIndexInjection = zIndexOverrides || (getCurrentInstance() ? inject(zIndexContextKey, void 0) : void 0);
13763
- const initialZIndex = computed(() => {
13764
- const zIndexFromInjection = unref(zIndexInjection);
13765
- return isNumber(zIndexFromInjection) ? zIndexFromInjection : defaultInitialZIndex;
13766
- });
13767
- const currentZIndex = computed(() => initialZIndex.value + zIndex.value);
13768
- const nextZIndex = () => {
13769
- increasingInjection.current++;
13770
- zIndex.value = increasingInjection.current;
13771
- return currentZIndex.value;
13772
- };
13773
- if (!isClient && !inject(ZINDEX_INJECTION_KEY)) ;
13774
- return {
13775
- initialZIndex,
13776
- currentZIndex,
13777
- nextZIndex
13778
- };
13779
- };
13780
-
13781
- function useCursor(input) {
13782
- let selectionInfo;
13783
- function recordCursor() {
13784
- if (input.value == void 0)
13785
- return;
13786
- const { selectionStart, selectionEnd, value } = input.value;
13787
- if (selectionStart == null || selectionEnd == null)
13788
- return;
13789
- const beforeTxt = value.slice(0, Math.max(0, selectionStart));
13790
- const afterTxt = value.slice(Math.max(0, selectionEnd));
13791
- selectionInfo = {
13792
- selectionStart,
13793
- selectionEnd,
13794
- value,
13795
- beforeTxt,
13796
- afterTxt
13797
- };
13798
- }
13799
- function setCursor() {
13800
- if (input.value == void 0 || selectionInfo == void 0)
13801
- return;
13802
- const { value } = input.value;
13803
- const { beforeTxt, afterTxt, selectionStart } = selectionInfo;
13804
- if (beforeTxt == void 0 || afterTxt == void 0 || selectionStart == void 0)
13805
- return;
13806
- let startPos = value.length;
13807
- if (value.endsWith(afterTxt)) {
13808
- startPos = value.length - afterTxt.length;
13809
- } else if (value.startsWith(beforeTxt)) {
13810
- startPos = beforeTxt.length;
13811
- } else {
13812
- const beforeLastChar = beforeTxt[selectionStart - 1];
13813
- const newIndex = value.indexOf(beforeLastChar, selectionStart - 1);
13814
- if (newIndex !== -1) {
13815
- startPos = newIndex + 1;
13816
- }
13817
- }
13818
- input.value.setSelectionRange(startPos, startPos);
13819
- }
13820
- return [recordCursor, setCursor];
13821
- }
13822
-
13823
- const useSizeProp = buildProp({
13824
- type: String,
13825
- values: componentSizes,
13826
- required: false
13827
- });
13828
- const SIZE_INJECTION_KEY = Symbol("size");
13829
- const useGlobalSize = () => {
13830
- const injectedSize = inject(SIZE_INJECTION_KEY, {});
13831
- return computed(() => {
13832
- return unref(injectedSize.size) || "";
13833
- });
13834
- };
13835
-
13836
- function useFocusController(target, {
13837
- beforeFocus,
13838
- afterFocus,
13839
- beforeBlur,
13840
- afterBlur
13841
- } = {}) {
13842
- const instance = getCurrentInstance();
13843
- const { emit } = instance;
13844
- const wrapperRef = shallowRef();
13845
- const isFocused = ref(false);
13846
- const handleFocus = (event) => {
13847
- const cancelFocus = isFunction$1(beforeFocus) ? beforeFocus(event) : false;
13848
- if (cancelFocus || isFocused.value)
13849
- return;
13850
- isFocused.value = true;
13851
- emit("focus", event);
13852
- afterFocus == null ? void 0 : afterFocus();
13853
- };
13854
- const handleBlur = (event) => {
13855
- var _a;
13856
- const cancelBlur = isFunction$1(beforeBlur) ? beforeBlur(event) : false;
13857
- if (cancelBlur || event.relatedTarget && ((_a = wrapperRef.value) == null ? void 0 : _a.contains(event.relatedTarget)))
13858
- return;
13859
- isFocused.value = false;
13860
- emit("blur", event);
13861
- afterBlur == null ? void 0 : afterBlur();
13862
- };
13863
- const handleClick = () => {
13864
- var _a, _b;
13865
- if (((_a = wrapperRef.value) == null ? void 0 : _a.contains(document.activeElement)) && wrapperRef.value !== document.activeElement)
13866
- return;
13867
- (_b = target.value) == null ? void 0 : _b.focus();
13868
- };
13869
- watch(wrapperRef, (el) => {
13870
- if (el) {
13871
- el.setAttribute("tabindex", "-1");
13872
- }
13873
- });
13874
- useEventListener(wrapperRef, "focus", handleFocus, true);
13875
- useEventListener(wrapperRef, "blur", handleBlur, true);
13876
- useEventListener(wrapperRef, "click", handleClick, true);
13877
- return {
13878
- isFocused,
13879
- wrapperRef,
13880
- handleFocus,
13881
- handleBlur
13882
- };
13883
- }
13884
-
13885
- function useComposition({
13886
- afterComposition,
13887
- emit
13888
- }) {
13889
- const isComposing = ref(false);
13890
- const handleCompositionStart = (event) => {
13891
- emit == null ? void 0 : emit("compositionstart", event);
13892
- isComposing.value = true;
13893
- };
13894
- const handleCompositionUpdate = (event) => {
13895
- var _a;
13896
- emit == null ? void 0 : emit("compositionupdate", event);
13897
- const text = (_a = event.target) == null ? void 0 : _a.value;
13898
- const lastCharacter = text[text.length - 1] || "";
13899
- isComposing.value = !isKorean(lastCharacter);
13900
- };
13901
- const handleCompositionEnd = (event) => {
13902
- emit == null ? void 0 : emit("compositionend", event);
13903
- if (isComposing.value) {
13904
- isComposing.value = false;
13905
- nextTick(() => afterComposition(event));
13906
- }
13907
- };
13908
- const handleComposition = (event) => {
13909
- event.type === "compositionend" ? handleCompositionEnd(event) : handleCompositionUpdate(event);
13910
- };
13911
- return {
13912
- isComposing,
13913
- handleComposition,
13914
- handleCompositionStart,
13915
- handleCompositionUpdate,
13916
- handleCompositionEnd
13917
- };
13918
- }
13919
-
13920
13321
  const emptyValuesContextKey = Symbol("emptyValuesContextKey");
13921
13322
  const DEFAULT_EMPTY_VALUES = ["", void 0, null];
13922
13323
  const DEFAULT_VALUE_ON_CLEAR = void 0;
@@ -13950,24 +13351,10 @@ const useEmptyValues = (props, defaultValue) => {
13950
13351
  return {
13951
13352
  emptyValues,
13952
13353
  valueOnClear,
13953
- isEmptyValue
13954
- };
13955
- };
13956
-
13957
- const ariaProps = buildProps({
13958
- ariaLabel: String,
13959
- ariaOrientation: {
13960
- type: String,
13961
- values: ["horizontal", "vertical", "undefined"]
13962
- },
13963
- ariaControls: String
13964
- });
13965
- const useAriaProps = (arias) => {
13966
- return pick(ariaProps, arias);
13354
+ isEmptyValue
13355
+ };
13967
13356
  };
13968
13357
 
13969
- const configProviderContextKey = Symbol();
13970
-
13971
13358
  const globalConfig = ref();
13972
13359
  function useGlobalConfig(key, defaultValue = void 0) {
13973
13360
  const config = getCurrentInstance() ? inject(configProviderContextKey, globalConfig) : globalConfig;
@@ -13981,6 +13368,10 @@ function useGlobalConfig(key, defaultValue = void 0) {
13981
13368
  }
13982
13369
  }
13983
13370
 
13371
+ const UPDATE_MODEL_EVENT = "update:modelValue";
13372
+ const CHANGE_EVENT = "change";
13373
+ const INPUT_EVENT = "input";
13374
+
13984
13375
  var _export_sfc$1 = (sfc, props) => {
13985
13376
  const target = sfc.__vccOpts || sfc;
13986
13377
  for (const [key, val] of props) {
@@ -13989,6 +13380,64 @@ var _export_sfc$1 = (sfc, props) => {
13989
13380
  return target;
13990
13381
  };
13991
13382
 
13383
+ function addUnit(value, defaultUnit = "px") {
13384
+ if (!value)
13385
+ return "";
13386
+ if (isNumber(value) || isStringNumber(value)) {
13387
+ return `${value}${defaultUnit}`;
13388
+ } else if (isString$1(value)) {
13389
+ return value;
13390
+ }
13391
+ }
13392
+
13393
+ function scrollIntoView(container, selected) {
13394
+ if (!isClient)
13395
+ return;
13396
+ if (!selected) {
13397
+ container.scrollTop = 0;
13398
+ return;
13399
+ }
13400
+ const offsetParents = [];
13401
+ let pointer = selected.offsetParent;
13402
+ while (pointer !== null && container !== pointer && container.contains(pointer)) {
13403
+ offsetParents.push(pointer);
13404
+ pointer = pointer.offsetParent;
13405
+ }
13406
+ const top = selected.offsetTop + offsetParents.reduce((prev, curr) => prev + curr.offsetTop, 0);
13407
+ const bottom = top + selected.offsetHeight;
13408
+ const viewRectTop = container.scrollTop;
13409
+ const viewRectBottom = viewRectTop + container.clientHeight;
13410
+ if (top < viewRectTop) {
13411
+ container.scrollTop = top;
13412
+ } else if (bottom > viewRectBottom) {
13413
+ container.scrollTop = bottom - container.clientHeight;
13414
+ }
13415
+ }
13416
+
13417
+ const withInstall = (main, extra) => {
13418
+ main.install = (app) => {
13419
+ for (const comp of [main, ...Object.values(extra != null ? extra : {})]) {
13420
+ app.component(comp.name, comp);
13421
+ }
13422
+ };
13423
+ if (extra) {
13424
+ for (const [key, comp] of Object.entries(extra)) {
13425
+ main[key] = comp;
13426
+ }
13427
+ }
13428
+ return main;
13429
+ };
13430
+ const withInstallDirective = (directive, name) => {
13431
+ directive.install = (app) => {
13432
+ app.directive(name, directive);
13433
+ };
13434
+ return directive;
13435
+ };
13436
+ const withNoopInstall = (component) => {
13437
+ component.install = NOOP;
13438
+ return component;
13439
+ };
13440
+
13992
13441
  const iconProps = buildProps({
13993
13442
  size: {
13994
13443
  type: definePropType([Number, String])
@@ -13998,12 +13447,12 @@ const iconProps = buildProps({
13998
13447
  }
13999
13448
  });
14000
13449
 
14001
- const __default__$p = defineComponent({
13450
+ const __default__$r = defineComponent({
14002
13451
  name: "ElIcon",
14003
13452
  inheritAttrs: false
14004
13453
  });
14005
- const _sfc_main$A = /* @__PURE__ */ defineComponent({
14006
- ...__default__$p,
13454
+ const _sfc_main$C = /* @__PURE__ */ defineComponent({
13455
+ ...__default__$r,
14007
13456
  props: iconProps,
14008
13457
  setup(__props) {
14009
13458
  const props = __props;
@@ -14027,25 +13476,241 @@ const _sfc_main$A = /* @__PURE__ */ defineComponent({
14027
13476
  };
14028
13477
  }
14029
13478
  });
14030
- var Icon = /* @__PURE__ */ _export_sfc$1(_sfc_main$A, [["__file", "icon.vue"]]);
13479
+ var Icon = /* @__PURE__ */ _export_sfc$1(_sfc_main$C, [["__file", "icon.vue"]]);
13480
+
13481
+ const ElIcon = withInstall(Icon);
13482
+
13483
+ const iconPropType = definePropType([
13484
+ String,
13485
+ Object,
13486
+ Function
13487
+ ]);
13488
+ const ValidateComponentsMap = {
13489
+ validating: loading_default,
13490
+ success: circle_check_default,
13491
+ error: circle_close_default
13492
+ };
13493
+
13494
+ const isFirefox = () => isClient && /firefox/i.test(window.navigator.userAgent);
13495
+
13496
+ let hiddenTextarea = void 0;
13497
+ const HIDDEN_STYLE = `
13498
+ height:0 !important;
13499
+ visibility:hidden !important;
13500
+ ${isFirefox() ? "" : "overflow:hidden !important;"}
13501
+ position:absolute !important;
13502
+ z-index:-1000 !important;
13503
+ top:0 !important;
13504
+ right:0 !important;
13505
+ `;
13506
+ const CONTEXT_STYLE = [
13507
+ "letter-spacing",
13508
+ "line-height",
13509
+ "padding-top",
13510
+ "padding-bottom",
13511
+ "font-family",
13512
+ "font-weight",
13513
+ "font-size",
13514
+ "text-rendering",
13515
+ "text-transform",
13516
+ "width",
13517
+ "text-indent",
13518
+ "padding-left",
13519
+ "padding-right",
13520
+ "border-width",
13521
+ "box-sizing"
13522
+ ];
13523
+ function calculateNodeStyling(targetElement) {
13524
+ const style = window.getComputedStyle(targetElement);
13525
+ const boxSizing = style.getPropertyValue("box-sizing");
13526
+ const paddingSize = Number.parseFloat(style.getPropertyValue("padding-bottom")) + Number.parseFloat(style.getPropertyValue("padding-top"));
13527
+ const borderSize = Number.parseFloat(style.getPropertyValue("border-bottom-width")) + Number.parseFloat(style.getPropertyValue("border-top-width"));
13528
+ const contextStyle = CONTEXT_STYLE.map((name) => `${name}:${style.getPropertyValue(name)}`).join(";");
13529
+ return { contextStyle, paddingSize, borderSize, boxSizing };
13530
+ }
13531
+ function calcTextareaHeight(targetElement, minRows = 1, maxRows) {
13532
+ var _a;
13533
+ if (!hiddenTextarea) {
13534
+ hiddenTextarea = document.createElement("textarea");
13535
+ document.body.appendChild(hiddenTextarea);
13536
+ }
13537
+ const { paddingSize, borderSize, boxSizing, contextStyle } = calculateNodeStyling(targetElement);
13538
+ hiddenTextarea.setAttribute("style", `${contextStyle};${HIDDEN_STYLE}`);
13539
+ hiddenTextarea.value = targetElement.value || targetElement.placeholder || "";
13540
+ let height = hiddenTextarea.scrollHeight;
13541
+ const result = {};
13542
+ if (boxSizing === "border-box") {
13543
+ height = height + borderSize;
13544
+ } else if (boxSizing === "content-box") {
13545
+ height = height - paddingSize;
13546
+ }
13547
+ hiddenTextarea.value = "";
13548
+ const singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;
13549
+ if (isNumber(minRows)) {
13550
+ let minHeight = singleRowHeight * minRows;
13551
+ if (boxSizing === "border-box") {
13552
+ minHeight = minHeight + paddingSize + borderSize;
13553
+ }
13554
+ height = Math.max(minHeight, height);
13555
+ result.minHeight = `${minHeight}px`;
13556
+ }
13557
+ if (isNumber(maxRows)) {
13558
+ let maxHeight = singleRowHeight * maxRows;
13559
+ if (boxSizing === "border-box") {
13560
+ maxHeight = maxHeight + paddingSize + borderSize;
13561
+ }
13562
+ height = Math.min(maxHeight, height);
13563
+ }
13564
+ result.height = `${height}px`;
13565
+ (_a = hiddenTextarea.parentNode) == null ? void 0 : _a.removeChild(hiddenTextarea);
13566
+ hiddenTextarea = void 0;
13567
+ return result;
13568
+ }
13569
+
13570
+ const mutable = (val) => val;
13571
+
13572
+ const ariaProps = buildProps({
13573
+ ariaLabel: String,
13574
+ ariaOrientation: {
13575
+ type: String,
13576
+ values: ["horizontal", "vertical", "undefined"]
13577
+ },
13578
+ ariaControls: String
13579
+ });
13580
+ const useAriaProps = (arias) => {
13581
+ return pick(ariaProps, arias);
13582
+ };
13583
+
13584
+ const inputProps = buildProps({
13585
+ id: {
13586
+ type: String,
13587
+ default: void 0
13588
+ },
13589
+ size: useSizeProp,
13590
+ disabled: Boolean,
13591
+ modelValue: {
13592
+ type: definePropType([
13593
+ String,
13594
+ Number,
13595
+ Object
13596
+ ]),
13597
+ default: ""
13598
+ },
13599
+ maxlength: {
13600
+ type: [String, Number]
13601
+ },
13602
+ minlength: {
13603
+ type: [String, Number]
13604
+ },
13605
+ type: {
13606
+ type: String,
13607
+ default: "text"
13608
+ },
13609
+ resize: {
13610
+ type: String,
13611
+ values: ["none", "both", "horizontal", "vertical"]
13612
+ },
13613
+ autosize: {
13614
+ type: definePropType([Boolean, Object]),
13615
+ default: false
13616
+ },
13617
+ autocomplete: {
13618
+ type: String,
13619
+ default: "off"
13620
+ },
13621
+ formatter: {
13622
+ type: Function
13623
+ },
13624
+ parser: {
13625
+ type: Function
13626
+ },
13627
+ placeholder: {
13628
+ type: String
13629
+ },
13630
+ form: {
13631
+ type: String
13632
+ },
13633
+ readonly: Boolean,
13634
+ clearable: Boolean,
13635
+ showPassword: Boolean,
13636
+ showWordLimit: Boolean,
13637
+ suffixIcon: {
13638
+ type: iconPropType
13639
+ },
13640
+ prefixIcon: {
13641
+ type: iconPropType
13642
+ },
13643
+ containerRole: {
13644
+ type: String,
13645
+ default: void 0
13646
+ },
13647
+ tabindex: {
13648
+ type: [String, Number],
13649
+ default: 0
13650
+ },
13651
+ validateEvent: {
13652
+ type: Boolean,
13653
+ default: true
13654
+ },
13655
+ inputStyle: {
13656
+ type: definePropType([Object, Array, String]),
13657
+ default: () => mutable({})
13658
+ },
13659
+ autofocus: Boolean,
13660
+ rows: {
13661
+ type: Number,
13662
+ default: 2
13663
+ },
13664
+ ...useAriaProps(["ariaLabel"])
13665
+ });
13666
+ const inputEmits = {
13667
+ [UPDATE_MODEL_EVENT]: (value) => isString$1(value),
13668
+ input: (value) => isString$1(value),
13669
+ change: (value) => isString$1(value),
13670
+ focus: (evt) => evt instanceof FocusEvent,
13671
+ blur: (evt) => evt instanceof FocusEvent,
13672
+ clear: () => true,
13673
+ mouseleave: (evt) => evt instanceof MouseEvent,
13674
+ mouseenter: (evt) => evt instanceof MouseEvent,
13675
+ keydown: (evt) => evt instanceof Event,
13676
+ compositionstart: (evt) => evt instanceof CompositionEvent,
13677
+ compositionupdate: (evt) => evt instanceof CompositionEvent,
13678
+ compositionend: (evt) => evt instanceof CompositionEvent
13679
+ };
14031
13680
 
14032
- const ElIcon = withInstall(Icon);
13681
+ const DEFAULT_EXCLUDE_KEYS = ["class", "style"];
13682
+ const LISTENER_PREFIX = /^on[A-Z]/;
13683
+ const useAttrs = (params = {}) => {
13684
+ const { excludeListeners = false, excludeKeys } = params;
13685
+ const allExcludeKeys = computed(() => {
13686
+ return ((excludeKeys == null ? void 0 : excludeKeys.value) || []).concat(DEFAULT_EXCLUDE_KEYS);
13687
+ });
13688
+ const instance = getCurrentInstance();
13689
+ if (!instance) {
13690
+ return computed(() => ({}));
13691
+ }
13692
+ return computed(() => {
13693
+ var _a;
13694
+ return fromPairs(Object.entries((_a = instance.proxy) == null ? void 0 : _a.$attrs).filter(([key]) => !allExcludeKeys.value.includes(key) && !(excludeListeners && LISTENER_PREFIX.test(key))));
13695
+ });
13696
+ };
14033
13697
 
14034
13698
  const formContextKey = Symbol("formContextKey");
14035
13699
  const formItemContextKey = Symbol("formItemContextKey");
14036
13700
 
14037
- const useFormSize = (fallback, ignore = {}) => {
14038
- const emptyRef = ref(void 0);
14039
- const size = ignore.prop ? emptyRef : useProp("size");
14040
- const globalConfig = ignore.global ? emptyRef : useGlobalSize();
14041
- const form = ignore.form ? { size: void 0 } : inject(formContextKey, void 0);
14042
- const formItem = ignore.formItem ? { size: void 0 } : inject(formItemContextKey, void 0);
14043
- return computed(() => size.value || unref(fallback) || (formItem == null ? void 0 : formItem.size) || (form == null ? void 0 : form.size) || globalConfig.value || "");
13701
+ const defaultIdInjection = {
13702
+ prefix: Math.floor(Math.random() * 1e4),
13703
+ current: 0
14044
13704
  };
14045
- const useFormDisabled = (fallback) => {
14046
- const disabled = useProp("disabled");
14047
- const form = inject(formContextKey, void 0);
14048
- return computed(() => disabled.value || unref(fallback) || (form == null ? void 0 : form.disabled) || false);
13705
+ const ID_INJECTION_KEY = Symbol("elIdInjection");
13706
+ const useIdInjection = () => {
13707
+ return getCurrentInstance() ? inject(ID_INJECTION_KEY, defaultIdInjection) : defaultIdInjection;
13708
+ };
13709
+ const useId = (deterministicId) => {
13710
+ const idInjection = useIdInjection();
13711
+ const namespace = useGetDerivedNamespace();
13712
+ const idRef = computedEager(() => unref(deterministicId) || `${namespace.value}-id-${idInjection.prefix}-${idInjection.current++}`);
13713
+ return idRef;
14049
13714
  };
14050
13715
 
14051
13716
  const useFormItem = () => {
@@ -14099,198 +13764,169 @@ const useFormItemInputId = (props, {
14099
13764
  };
14100
13765
  };
14101
13766
 
14102
- let hiddenTextarea = void 0;
14103
- const HIDDEN_STYLE = `
14104
- height:0 !important;
14105
- visibility:hidden !important;
14106
- ${isFirefox() ? "" : "overflow:hidden !important;"}
14107
- position:absolute !important;
14108
- z-index:-1000 !important;
14109
- top:0 !important;
14110
- right:0 !important;
14111
- `;
14112
- const CONTEXT_STYLE = [
14113
- "letter-spacing",
14114
- "line-height",
14115
- "padding-top",
14116
- "padding-bottom",
14117
- "font-family",
14118
- "font-weight",
14119
- "font-size",
14120
- "text-rendering",
14121
- "text-transform",
14122
- "width",
14123
- "text-indent",
14124
- "padding-left",
14125
- "padding-right",
14126
- "border-width",
14127
- "box-sizing"
14128
- ];
14129
- function calculateNodeStyling(targetElement) {
14130
- const style = window.getComputedStyle(targetElement);
14131
- const boxSizing = style.getPropertyValue("box-sizing");
14132
- const paddingSize = Number.parseFloat(style.getPropertyValue("padding-bottom")) + Number.parseFloat(style.getPropertyValue("padding-top"));
14133
- const borderSize = Number.parseFloat(style.getPropertyValue("border-bottom-width")) + Number.parseFloat(style.getPropertyValue("border-top-width"));
14134
- const contextStyle = CONTEXT_STYLE.map((name) => `${name}:${style.getPropertyValue(name)}`).join(";");
14135
- return { contextStyle, paddingSize, borderSize, boxSizing };
13767
+ const useProp = (name) => {
13768
+ const vm = getCurrentInstance();
13769
+ return computed(() => {
13770
+ var _a, _b;
13771
+ return (_b = (_a = vm == null ? void 0 : vm.proxy) == null ? void 0 : _a.$props) == null ? void 0 : _b[name];
13772
+ });
13773
+ };
13774
+
13775
+ const useFormSize = (fallback, ignore = {}) => {
13776
+ const emptyRef = ref(void 0);
13777
+ const size = ignore.prop ? emptyRef : useProp("size");
13778
+ const globalConfig = ignore.global ? emptyRef : useGlobalSize();
13779
+ const form = ignore.form ? { size: void 0 } : inject(formContextKey, void 0);
13780
+ const formItem = ignore.formItem ? { size: void 0 } : inject(formItemContextKey, void 0);
13781
+ return computed(() => size.value || unref(fallback) || (formItem == null ? void 0 : formItem.size) || (form == null ? void 0 : form.size) || globalConfig.value || "");
13782
+ };
13783
+ const useFormDisabled = (fallback) => {
13784
+ const disabled = useProp("disabled");
13785
+ const form = inject(formContextKey, void 0);
13786
+ return computed(() => disabled.value || unref(fallback) || (form == null ? void 0 : form.disabled) || false);
13787
+ };
13788
+
13789
+ function useFocusController(target, {
13790
+ beforeFocus,
13791
+ afterFocus,
13792
+ beforeBlur,
13793
+ afterBlur
13794
+ } = {}) {
13795
+ const instance = getCurrentInstance();
13796
+ const { emit } = instance;
13797
+ const wrapperRef = shallowRef();
13798
+ const isFocused = ref(false);
13799
+ const handleFocus = (event) => {
13800
+ const cancelFocus = isFunction$1(beforeFocus) ? beforeFocus(event) : false;
13801
+ if (cancelFocus || isFocused.value)
13802
+ return;
13803
+ isFocused.value = true;
13804
+ emit("focus", event);
13805
+ afterFocus == null ? void 0 : afterFocus();
13806
+ };
13807
+ const handleBlur = (event) => {
13808
+ var _a;
13809
+ const cancelBlur = isFunction$1(beforeBlur) ? beforeBlur(event) : false;
13810
+ if (cancelBlur || event.relatedTarget && ((_a = wrapperRef.value) == null ? void 0 : _a.contains(event.relatedTarget)))
13811
+ return;
13812
+ isFocused.value = false;
13813
+ emit("blur", event);
13814
+ afterBlur == null ? void 0 : afterBlur();
13815
+ };
13816
+ const handleClick = () => {
13817
+ var _a, _b;
13818
+ if (((_a = wrapperRef.value) == null ? void 0 : _a.contains(document.activeElement)) && wrapperRef.value !== document.activeElement)
13819
+ return;
13820
+ (_b = target.value) == null ? void 0 : _b.focus();
13821
+ };
13822
+ watch(wrapperRef, (el) => {
13823
+ if (el) {
13824
+ el.setAttribute("tabindex", "-1");
13825
+ }
13826
+ });
13827
+ useEventListener(wrapperRef, "focus", handleFocus, true);
13828
+ useEventListener(wrapperRef, "blur", handleBlur, true);
13829
+ useEventListener(wrapperRef, "click", handleClick, true);
13830
+ return {
13831
+ isFocused,
13832
+ wrapperRef,
13833
+ handleFocus,
13834
+ handleBlur
13835
+ };
14136
13836
  }
14137
- function calcTextareaHeight(targetElement, minRows = 1, maxRows) {
14138
- var _a;
14139
- if (!hiddenTextarea) {
14140
- hiddenTextarea = document.createElement("textarea");
14141
- document.body.appendChild(hiddenTextarea);
14142
- }
14143
- const { paddingSize, borderSize, boxSizing, contextStyle } = calculateNodeStyling(targetElement);
14144
- hiddenTextarea.setAttribute("style", `${contextStyle};${HIDDEN_STYLE}`);
14145
- hiddenTextarea.value = targetElement.value || targetElement.placeholder || "";
14146
- let height = hiddenTextarea.scrollHeight;
14147
- const result = {};
14148
- if (boxSizing === "border-box") {
14149
- height = height + borderSize;
14150
- } else if (boxSizing === "content-box") {
14151
- height = height - paddingSize;
14152
- }
14153
- hiddenTextarea.value = "";
14154
- const singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;
14155
- if (isNumber(minRows)) {
14156
- let minHeight = singleRowHeight * minRows;
14157
- if (boxSizing === "border-box") {
14158
- minHeight = minHeight + paddingSize + borderSize;
13837
+
13838
+ const isKorean = (text) => /([\uAC00-\uD7AF\u3130-\u318F])+/gi.test(text);
13839
+
13840
+ function useComposition({
13841
+ afterComposition,
13842
+ emit
13843
+ }) {
13844
+ const isComposing = ref(false);
13845
+ const handleCompositionStart = (event) => {
13846
+ emit == null ? void 0 : emit("compositionstart", event);
13847
+ isComposing.value = true;
13848
+ };
13849
+ const handleCompositionUpdate = (event) => {
13850
+ var _a;
13851
+ emit == null ? void 0 : emit("compositionupdate", event);
13852
+ const text = (_a = event.target) == null ? void 0 : _a.value;
13853
+ const lastCharacter = text[text.length - 1] || "";
13854
+ isComposing.value = !isKorean(lastCharacter);
13855
+ };
13856
+ const handleCompositionEnd = (event) => {
13857
+ emit == null ? void 0 : emit("compositionend", event);
13858
+ if (isComposing.value) {
13859
+ isComposing.value = false;
13860
+ nextTick(() => afterComposition(event));
14159
13861
  }
14160
- height = Math.max(minHeight, height);
14161
- result.minHeight = `${minHeight}px`;
13862
+ };
13863
+ const handleComposition = (event) => {
13864
+ event.type === "compositionend" ? handleCompositionEnd(event) : handleCompositionUpdate(event);
13865
+ };
13866
+ return {
13867
+ isComposing,
13868
+ handleComposition,
13869
+ handleCompositionStart,
13870
+ handleCompositionUpdate,
13871
+ handleCompositionEnd
13872
+ };
13873
+ }
13874
+
13875
+ function useCursor(input) {
13876
+ let selectionInfo;
13877
+ function recordCursor() {
13878
+ if (input.value == void 0)
13879
+ return;
13880
+ const { selectionStart, selectionEnd, value } = input.value;
13881
+ if (selectionStart == null || selectionEnd == null)
13882
+ return;
13883
+ const beforeTxt = value.slice(0, Math.max(0, selectionStart));
13884
+ const afterTxt = value.slice(Math.max(0, selectionEnd));
13885
+ selectionInfo = {
13886
+ selectionStart,
13887
+ selectionEnd,
13888
+ value,
13889
+ beforeTxt,
13890
+ afterTxt
13891
+ };
14162
13892
  }
14163
- if (isNumber(maxRows)) {
14164
- let maxHeight = singleRowHeight * maxRows;
14165
- if (boxSizing === "border-box") {
14166
- maxHeight = maxHeight + paddingSize + borderSize;
13893
+ function setCursor() {
13894
+ if (input.value == void 0 || selectionInfo == void 0)
13895
+ return;
13896
+ const { value } = input.value;
13897
+ const { beforeTxt, afterTxt, selectionStart } = selectionInfo;
13898
+ if (beforeTxt == void 0 || afterTxt == void 0 || selectionStart == void 0)
13899
+ return;
13900
+ let startPos = value.length;
13901
+ if (value.endsWith(afterTxt)) {
13902
+ startPos = value.length - afterTxt.length;
13903
+ } else if (value.startsWith(beforeTxt)) {
13904
+ startPos = beforeTxt.length;
13905
+ } else {
13906
+ const beforeLastChar = beforeTxt[selectionStart - 1];
13907
+ const newIndex = value.indexOf(beforeLastChar, selectionStart - 1);
13908
+ if (newIndex !== -1) {
13909
+ startPos = newIndex + 1;
13910
+ }
14167
13911
  }
14168
- height = Math.min(maxHeight, height);
13912
+ input.value.setSelectionRange(startPos, startPos);
14169
13913
  }
14170
- result.height = `${height}px`;
14171
- (_a = hiddenTextarea.parentNode) == null ? void 0 : _a.removeChild(hiddenTextarea);
14172
- hiddenTextarea = void 0;
14173
- return result;
13914
+ return [recordCursor, setCursor];
14174
13915
  }
14175
13916
 
14176
- const inputProps = buildProps({
14177
- id: {
14178
- type: String,
14179
- default: void 0
14180
- },
14181
- size: useSizeProp,
14182
- disabled: Boolean,
14183
- modelValue: {
14184
- type: definePropType([
14185
- String,
14186
- Number,
14187
- Object
14188
- ]),
14189
- default: ""
14190
- },
14191
- maxlength: {
14192
- type: [String, Number]
14193
- },
14194
- minlength: {
14195
- type: [String, Number]
14196
- },
14197
- type: {
14198
- type: String,
14199
- default: "text"
14200
- },
14201
- resize: {
14202
- type: String,
14203
- values: ["none", "both", "horizontal", "vertical"]
14204
- },
14205
- autosize: {
14206
- type: definePropType([Boolean, Object]),
14207
- default: false
14208
- },
14209
- autocomplete: {
14210
- type: String,
14211
- default: "off"
14212
- },
14213
- formatter: {
14214
- type: Function
14215
- },
14216
- parser: {
14217
- type: Function
14218
- },
14219
- placeholder: {
14220
- type: String
14221
- },
14222
- form: {
14223
- type: String
14224
- },
14225
- readonly: Boolean,
14226
- clearable: Boolean,
14227
- showPassword: Boolean,
14228
- showWordLimit: Boolean,
14229
- suffixIcon: {
14230
- type: iconPropType
14231
- },
14232
- prefixIcon: {
14233
- type: iconPropType
14234
- },
14235
- containerRole: {
14236
- type: String,
14237
- default: void 0
14238
- },
14239
- tabindex: {
14240
- type: [String, Number],
14241
- default: 0
14242
- },
14243
- validateEvent: {
14244
- type: Boolean,
14245
- default: true
14246
- },
14247
- inputStyle: {
14248
- type: definePropType([Object, Array, String]),
14249
- default: () => mutable({})
14250
- },
14251
- autofocus: Boolean,
14252
- rows: {
14253
- type: Number,
14254
- default: 2
14255
- },
14256
- ...useAriaProps(["ariaLabel"])
14257
- });
14258
- const inputEmits = {
14259
- [UPDATE_MODEL_EVENT]: (value) => isString$1(value),
14260
- input: (value) => isString$1(value),
14261
- change: (value) => isString$1(value),
14262
- focus: (evt) => evt instanceof FocusEvent,
14263
- blur: (evt) => evt instanceof FocusEvent,
14264
- clear: () => true,
14265
- mouseleave: (evt) => evt instanceof MouseEvent,
14266
- mouseenter: (evt) => evt instanceof MouseEvent,
14267
- keydown: (evt) => evt instanceof Event,
14268
- compositionstart: (evt) => evt instanceof CompositionEvent,
14269
- compositionupdate: (evt) => evt instanceof CompositionEvent,
14270
- compositionend: (evt) => evt instanceof CompositionEvent
14271
- };
14272
-
14273
- const __default__$o = defineComponent({
13917
+ const __default__$q = defineComponent({
14274
13918
  name: "ElInput",
14275
13919
  inheritAttrs: false
14276
13920
  });
14277
- const _sfc_main$z = /* @__PURE__ */ defineComponent({
14278
- ...__default__$o,
13921
+ const _sfc_main$B = /* @__PURE__ */ defineComponent({
13922
+ ...__default__$q,
14279
13923
  props: inputProps,
14280
13924
  emits: inputEmits,
14281
13925
  setup(__props, { expose, emit }) {
14282
13926
  const props = __props;
14283
13927
  const rawAttrs = useAttrs$1();
13928
+ const attrs = useAttrs();
14284
13929
  const slots = useSlots();
14285
- const containerAttrs = computed(() => {
14286
- const comboBoxAttrs = {};
14287
- if (props.containerRole === "combobox") {
14288
- comboBoxAttrs["aria-haspopup"] = rawAttrs["aria-haspopup"];
14289
- comboBoxAttrs["aria-owns"] = rawAttrs["aria-owns"];
14290
- comboBoxAttrs["aria-expanded"] = rawAttrs["aria-expanded"];
14291
- }
14292
- return comboBoxAttrs;
14293
- });
14294
13930
  const containerKls = computed(() => [
14295
13931
  props.type === "textarea" ? nsTextarea.b() : nsInput.b(),
14296
13932
  nsInput.m(inputSize.value),
@@ -14309,11 +13945,6 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14309
13945
  nsInput.e("wrapper"),
14310
13946
  nsInput.is("focus", isFocused.value)
14311
13947
  ]);
14312
- const attrs = useAttrs({
14313
- excludeKeys: computed(() => {
14314
- return Object.keys(containerAttrs.value);
14315
- })
14316
- });
14317
13948
  const { form: elForm, formItem: elFormItem } = useFormItem();
14318
13949
  const { inputId } = useFormItemInputId(props, {
14319
13950
  formItemContext: elFormItem
@@ -14357,7 +13988,7 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14357
13988
  ]);
14358
13989
  const nativeInputValue = computed(() => isNil(props.modelValue) ? "" : String(props.modelValue));
14359
13990
  const showClear = computed(() => props.clearable && !inputDisabled.value && !props.readonly && !!nativeInputValue.value && (isFocused.value || hovering.value));
14360
- const showPwdVisible = computed(() => props.showPassword && !inputDisabled.value && !props.readonly && !!nativeInputValue.value && (!!nativeInputValue.value || isFocused.value));
13991
+ const showPwdVisible = computed(() => props.showPassword && !inputDisabled.value && !!nativeInputValue.value && (!!nativeInputValue.value || isFocused.value));
14361
13992
  const isWordLimitVisible = computed(() => props.showWordLimit && !!props.maxlength && (props.type === "text" || props.type === "textarea") && !inputDisabled.value && !props.readonly && !props.showPassword);
14362
13993
  const textLength = computed(() => nativeInputValue.value.length);
14363
13994
  const inputExceed = computed(() => !!isWordLimitVisible.value && textLength.value > Number(props.maxlength));
@@ -14444,13 +14075,13 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14444
14075
  handleCompositionEnd
14445
14076
  } = useComposition({ emit, afterComposition: handleInput });
14446
14077
  const handlePasswordVisible = () => {
14078
+ recordCursor();
14447
14079
  passwordVisible.value = !passwordVisible.value;
14448
- focus();
14080
+ setTimeout(setCursor);
14449
14081
  };
14450
- const focus = async () => {
14082
+ const focus = () => {
14451
14083
  var _a;
14452
- await nextTick();
14453
- (_a = _ref.value) == null ? void 0 : _a.focus();
14084
+ return (_a = _ref.value) == null ? void 0 : _a.focus();
14454
14085
  };
14455
14086
  const blur = () => {
14456
14087
  var _a;
@@ -14509,19 +14140,18 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14509
14140
  resizeTextarea
14510
14141
  });
14511
14142
  return (_ctx, _cache) => {
14512
- return openBlock(), createElementBlock("div", mergeProps(unref(containerAttrs), {
14513
- class: [
14143
+ return openBlock(), createElementBlock("div", {
14144
+ class: normalizeClass([
14514
14145
  unref(containerKls),
14515
14146
  {
14516
14147
  [unref(nsInput).bm("group", "append")]: _ctx.$slots.append,
14517
14148
  [unref(nsInput).bm("group", "prepend")]: _ctx.$slots.prepend
14518
14149
  }
14519
- ],
14520
- style: unref(containerStyle),
14521
- role: _ctx.containerRole,
14150
+ ]),
14151
+ style: normalizeStyle(unref(containerStyle)),
14522
14152
  onMouseenter: handleMouseEnter,
14523
14153
  onMouseleave: handleMouseLeave
14524
- }), [
14154
+ }, [
14525
14155
  createCommentVNode(" input "),
14526
14156
  _ctx.type !== "textarea" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
14527
14157
  createCommentVNode(" prepend slot "),
@@ -14574,13 +14204,14 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14574
14204
  style: _ctx.inputStyle,
14575
14205
  form: _ctx.form,
14576
14206
  autofocus: _ctx.autofocus,
14207
+ role: _ctx.containerRole,
14577
14208
  onCompositionstart: unref(handleCompositionStart),
14578
14209
  onCompositionupdate: unref(handleCompositionUpdate),
14579
14210
  onCompositionend: unref(handleCompositionEnd),
14580
14211
  onInput: handleInput,
14581
14212
  onChange: handleChange,
14582
14213
  onKeydown: handleKeydown
14583
- }), null, 16, ["id", "minlength", "maxlength", "type", "disabled", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder", "form", "autofocus", "onCompositionstart", "onCompositionupdate", "onCompositionend"]),
14214
+ }), null, 16, ["id", "minlength", "maxlength", "type", "disabled", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder", "form", "autofocus", "role", "onCompositionstart", "onCompositionupdate", "onCompositionend"]),
14584
14215
  createCommentVNode(" suffix slot "),
14585
14216
  unref(suffixVisible) ? (openBlock(), createElementBlock("span", {
14586
14217
  key: 1,
@@ -14673,6 +14304,7 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14673
14304
  form: _ctx.form,
14674
14305
  autofocus: _ctx.autofocus,
14675
14306
  rows: _ctx.rows,
14307
+ role: _ctx.containerRole,
14676
14308
  onCompositionstart: unref(handleCompositionStart),
14677
14309
  onCompositionupdate: unref(handleCompositionUpdate),
14678
14310
  onCompositionend: unref(handleCompositionEnd),
@@ -14681,18 +14313,18 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14681
14313
  onBlur: unref(handleBlur),
14682
14314
  onChange: handleChange,
14683
14315
  onKeydown: handleKeydown
14684
- }), null, 16, ["id", "minlength", "maxlength", "tabindex", "disabled", "readonly", "autocomplete", "aria-label", "placeholder", "form", "autofocus", "rows", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onFocus", "onBlur"]),
14316
+ }), null, 16, ["id", "minlength", "maxlength", "tabindex", "disabled", "readonly", "autocomplete", "aria-label", "placeholder", "form", "autofocus", "rows", "role", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onFocus", "onBlur"]),
14685
14317
  unref(isWordLimitVisible) ? (openBlock(), createElementBlock("span", {
14686
14318
  key: 0,
14687
14319
  style: normalizeStyle(countStyle.value),
14688
14320
  class: normalizeClass(unref(nsInput).e("count"))
14689
14321
  }, toDisplayString(unref(textLength)) + " / " + toDisplayString(_ctx.maxlength), 7)) : createCommentVNode("v-if", true)
14690
14322
  ], 64))
14691
- ], 16, ["role"]);
14323
+ ], 38);
14692
14324
  };
14693
14325
  }
14694
14326
  });
14695
- var Input = /* @__PURE__ */ _export_sfc$1(_sfc_main$z, [["__file", "input.vue"]]);
14327
+ var Input = /* @__PURE__ */ _export_sfc$1(_sfc_main$B, [["__file", "input.vue"]]);
14696
14328
 
14697
14329
  const ElInput = withInstall(Input);
14698
14330
 
@@ -14742,7 +14374,7 @@ const thumbProps = buildProps({
14742
14374
  });
14743
14375
 
14744
14376
  const COMPONENT_NAME$2 = "Thumb";
14745
- const _sfc_main$y = /* @__PURE__ */ defineComponent({
14377
+ const _sfc_main$A = /* @__PURE__ */ defineComponent({
14746
14378
  __name: "thumb",
14747
14379
  props: thumbProps,
14748
14380
  setup(__props) {
@@ -14861,7 +14493,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
14861
14493
  };
14862
14494
  }
14863
14495
  });
14864
- var Thumb = /* @__PURE__ */ _export_sfc$1(_sfc_main$y, [["__file", "thumb.vue"]]);
14496
+ var Thumb = /* @__PURE__ */ _export_sfc$1(_sfc_main$A, [["__file", "thumb.vue"]]);
14865
14497
 
14866
14498
  const barProps = buildProps({
14867
14499
  always: {
@@ -14874,7 +14506,7 @@ const barProps = buildProps({
14874
14506
  }
14875
14507
  });
14876
14508
 
14877
- const _sfc_main$x = /* @__PURE__ */ defineComponent({
14509
+ const _sfc_main$z = /* @__PURE__ */ defineComponent({
14878
14510
  __name: "bar",
14879
14511
  props: barProps,
14880
14512
  setup(__props, { expose }) {
@@ -14932,7 +14564,7 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
14932
14564
  };
14933
14565
  }
14934
14566
  });
14935
- var Bar = /* @__PURE__ */ _export_sfc$1(_sfc_main$x, [["__file", "bar.vue"]]);
14567
+ var Bar = /* @__PURE__ */ _export_sfc$1(_sfc_main$z, [["__file", "bar.vue"]]);
14936
14568
 
14937
14569
  const scrollbarProps = buildProps({
14938
14570
  height: {
@@ -14973,6 +14605,10 @@ const scrollbarProps = buildProps({
14973
14605
  type: Number,
14974
14606
  default: 20
14975
14607
  },
14608
+ tabindex: {
14609
+ type: [String, Number],
14610
+ default: void 0
14611
+ },
14976
14612
  id: String,
14977
14613
  role: String,
14978
14614
  ...useAriaProps(["ariaLabel", "ariaOrientation"])
@@ -14985,11 +14621,11 @@ const scrollbarEmits = {
14985
14621
  };
14986
14622
 
14987
14623
  const COMPONENT_NAME$1 = "ElScrollbar";
14988
- const __default__$n = defineComponent({
14624
+ const __default__$p = defineComponent({
14989
14625
  name: COMPONENT_NAME$1
14990
14626
  });
14991
- const _sfc_main$w = /* @__PURE__ */ defineComponent({
14992
- ...__default__$n,
14627
+ const _sfc_main$y = /* @__PURE__ */ defineComponent({
14628
+ ...__default__$p,
14993
14629
  props: scrollbarProps,
14994
14630
  emits: scrollbarEmits,
14995
14631
  setup(__props, { expose, emit }) {
@@ -15080,8 +14716,10 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
15080
14716
  wrapElement: wrapRef
15081
14717
  }));
15082
14718
  onActivated(() => {
15083
- wrapRef.value.scrollTop = wrapScrollTop;
15084
- wrapRef.value.scrollLeft = wrapScrollLeft;
14719
+ if (wrapRef.value) {
14720
+ wrapRef.value.scrollTop = wrapScrollTop;
14721
+ wrapRef.value.scrollLeft = wrapScrollLeft;
14722
+ }
15085
14723
  });
15086
14724
  onMounted(() => {
15087
14725
  if (!props.native)
@@ -15109,6 +14747,7 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
15109
14747
  ref: wrapRef,
15110
14748
  class: normalizeClass(unref(wrapKls)),
15111
14749
  style: normalizeStyle(unref(wrapStyle)),
14750
+ tabindex: _ctx.tabindex,
15112
14751
  onScroll: handleScroll
15113
14752
  }, [
15114
14753
  (openBlock(), createBlock(resolveDynamicComponent(_ctx.tag), {
@@ -15126,7 +14765,7 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
15126
14765
  ]),
15127
14766
  _: 3
15128
14767
  }, 8, ["id", "class", "style", "role", "aria-label", "aria-orientation"]))
15129
- ], 38),
14768
+ ], 46, ["tabindex"]),
15130
14769
  !_ctx.native ? (openBlock(), createBlock(Bar, {
15131
14770
  key: 0,
15132
14771
  ref_key: "barRef",
@@ -15138,7 +14777,7 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
15138
14777
  };
15139
14778
  }
15140
14779
  });
15141
- var Scrollbar = /* @__PURE__ */ _export_sfc$1(_sfc_main$w, [["__file", "scrollbar.vue"]]);
14780
+ var Scrollbar = /* @__PURE__ */ _export_sfc$1(_sfc_main$y, [["__file", "scrollbar.vue"]]);
15142
14781
 
15143
14782
  const ElScrollbar = withInstall(Scrollbar);
15144
14783
 
@@ -15163,12 +14802,12 @@ const popperProps = buildProps({
15163
14802
  }
15164
14803
  });
15165
14804
 
15166
- const __default__$m = defineComponent({
14805
+ const __default__$o = defineComponent({
15167
14806
  name: "ElPopper",
15168
14807
  inheritAttrs: false
15169
14808
  });
15170
- const _sfc_main$v = /* @__PURE__ */ defineComponent({
15171
- ...__default__$m,
14809
+ const _sfc_main$x = /* @__PURE__ */ defineComponent({
14810
+ ...__default__$o,
15172
14811
  props: popperProps,
15173
14812
  setup(__props, { expose }) {
15174
14813
  const props = __props;
@@ -15191,7 +14830,7 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
15191
14830
  };
15192
14831
  }
15193
14832
  });
15194
- var Popper = /* @__PURE__ */ _export_sfc$1(_sfc_main$v, [["__file", "popper.vue"]]);
14833
+ var Popper = /* @__PURE__ */ _export_sfc$1(_sfc_main$x, [["__file", "popper.vue"]]);
15195
14834
 
15196
14835
  const popperArrowProps = buildProps({
15197
14836
  arrowOffset: {
@@ -15200,12 +14839,12 @@ const popperArrowProps = buildProps({
15200
14839
  }
15201
14840
  });
15202
14841
 
15203
- const __default__$l = defineComponent({
14842
+ const __default__$n = defineComponent({
15204
14843
  name: "ElPopperArrow",
15205
14844
  inheritAttrs: false
15206
14845
  });
15207
- const _sfc_main$u = /* @__PURE__ */ defineComponent({
15208
- ...__default__$l,
14846
+ const _sfc_main$w = /* @__PURE__ */ defineComponent({
14847
+ ...__default__$n,
15209
14848
  props: popperArrowProps,
15210
14849
  setup(__props, { expose }) {
15211
14850
  const props = __props;
@@ -15231,7 +14870,85 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
15231
14870
  };
15232
14871
  }
15233
14872
  });
15234
- var ElPopperArrow = /* @__PURE__ */ _export_sfc$1(_sfc_main$u, [["__file", "arrow.vue"]]);
14873
+ var ElPopperArrow = /* @__PURE__ */ _export_sfc$1(_sfc_main$w, [["__file", "arrow.vue"]]);
14874
+
14875
+ const popperTriggerProps = buildProps({
14876
+ virtualRef: {
14877
+ type: definePropType(Object)
14878
+ },
14879
+ virtualTriggering: Boolean,
14880
+ onMouseenter: {
14881
+ type: definePropType(Function)
14882
+ },
14883
+ onMouseleave: {
14884
+ type: definePropType(Function)
14885
+ },
14886
+ onClick: {
14887
+ type: definePropType(Function)
14888
+ },
14889
+ onKeydown: {
14890
+ type: definePropType(Function)
14891
+ },
14892
+ onFocus: {
14893
+ type: definePropType(Function)
14894
+ },
14895
+ onBlur: {
14896
+ type: definePropType(Function)
14897
+ },
14898
+ onContextmenu: {
14899
+ type: definePropType(Function)
14900
+ },
14901
+ id: String,
14902
+ open: Boolean
14903
+ });
14904
+
14905
+ const FORWARD_REF_INJECTION_KEY = Symbol("elForwardRef");
14906
+ const useForwardRef = (forwardRef) => {
14907
+ const setForwardRef = (el) => {
14908
+ forwardRef.value = el;
14909
+ };
14910
+ provide(FORWARD_REF_INJECTION_KEY, {
14911
+ setForwardRef
14912
+ });
14913
+ };
14914
+ const useForwardRefDirective = (setForwardRef) => {
14915
+ return {
14916
+ mounted(el) {
14917
+ setForwardRef(el);
14918
+ },
14919
+ updated(el) {
14920
+ setForwardRef(el);
14921
+ },
14922
+ unmounted() {
14923
+ setForwardRef(null);
14924
+ }
14925
+ };
14926
+ };
14927
+
14928
+ const isFocusable = (element) => {
14929
+ if (element.tabIndex > 0 || element.tabIndex === 0 && element.getAttribute("tabIndex") !== null) {
14930
+ return true;
14931
+ }
14932
+ if (element.tabIndex < 0 || element.hasAttribute("disabled") || element.getAttribute("aria-disabled") === "true") {
14933
+ return false;
14934
+ }
14935
+ switch (element.nodeName) {
14936
+ case "A": {
14937
+ return !!element.href && element.rel !== "ignore";
14938
+ }
14939
+ case "INPUT": {
14940
+ return !(element.type === "hidden" || element.type === "file");
14941
+ }
14942
+ case "BUTTON":
14943
+ case "SELECT":
14944
+ case "TEXTAREA": {
14945
+ return true;
14946
+ }
14947
+ default: {
14948
+ return false;
14949
+ }
14950
+ }
14951
+ };
15235
14952
 
15236
14953
  const NAME = "ElOnlyChild";
15237
14954
  const OnlyChild = defineComponent({
@@ -15272,58 +14989,28 @@ function findFirstLegitChild(node) {
15272
14989
  case "svg":
15273
14990
  return wrapTextContent(child);
15274
14991
  case Fragment:
15275
- return findFirstLegitChild(child.children);
15276
- default:
15277
- return child;
15278
- }
15279
- }
15280
- return wrapTextContent(child);
15281
- }
15282
- return null;
15283
- }
15284
- function wrapTextContent(s) {
15285
- const ns = useNamespace("only-child");
15286
- return createVNode("span", {
15287
- "class": ns.e("content")
15288
- }, [s]);
15289
- }
15290
-
15291
- const popperTriggerProps = buildProps({
15292
- virtualRef: {
15293
- type: definePropType(Object)
15294
- },
15295
- virtualTriggering: Boolean,
15296
- onMouseenter: {
15297
- type: definePropType(Function)
15298
- },
15299
- onMouseleave: {
15300
- type: definePropType(Function)
15301
- },
15302
- onClick: {
15303
- type: definePropType(Function)
15304
- },
15305
- onKeydown: {
15306
- type: definePropType(Function)
15307
- },
15308
- onFocus: {
15309
- type: definePropType(Function)
15310
- },
15311
- onBlur: {
15312
- type: definePropType(Function)
15313
- },
15314
- onContextmenu: {
15315
- type: definePropType(Function)
15316
- },
15317
- id: String,
15318
- open: Boolean
15319
- });
14992
+ return findFirstLegitChild(child.children);
14993
+ default:
14994
+ return child;
14995
+ }
14996
+ }
14997
+ return wrapTextContent(child);
14998
+ }
14999
+ return null;
15000
+ }
15001
+ function wrapTextContent(s) {
15002
+ const ns = useNamespace("only-child");
15003
+ return createVNode("span", {
15004
+ "class": ns.e("content")
15005
+ }, [s]);
15006
+ }
15320
15007
 
15321
- const __default__$k = defineComponent({
15008
+ const __default__$m = defineComponent({
15322
15009
  name: "ElPopperTrigger",
15323
15010
  inheritAttrs: false
15324
15011
  });
15325
- const _sfc_main$t = /* @__PURE__ */ defineComponent({
15326
- ...__default__$k,
15012
+ const _sfc_main$v = /* @__PURE__ */ defineComponent({
15013
+ ...__default__$m,
15327
15014
  props: popperTriggerProps,
15328
15015
  setup(__props, { expose }) {
15329
15016
  const props = __props;
@@ -15377,18 +15064,20 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
15377
15064
  (_a = prevEl == null ? void 0 : prevEl.removeEventListener) == null ? void 0 : _a.call(prevEl, eventName.slice(2).toLowerCase(), handler);
15378
15065
  }
15379
15066
  });
15380
- virtualTriggerAriaStopWatch = watch([ariaControls, ariaDescribedby, ariaHaspopup, ariaExpanded], (watches) => {
15381
- [
15382
- "aria-controls",
15383
- "aria-describedby",
15384
- "aria-haspopup",
15385
- "aria-expanded"
15386
- ].forEach((key, idx) => {
15387
- isNil(watches[idx]) ? el.removeAttribute(key) : el.setAttribute(key, watches[idx]);
15388
- });
15389
- }, { immediate: true });
15067
+ if (isFocusable(el)) {
15068
+ virtualTriggerAriaStopWatch = watch([ariaControls, ariaDescribedby, ariaHaspopup, ariaExpanded], (watches) => {
15069
+ [
15070
+ "aria-controls",
15071
+ "aria-describedby",
15072
+ "aria-haspopup",
15073
+ "aria-expanded"
15074
+ ].forEach((key, idx) => {
15075
+ isNil(watches[idx]) ? el.removeAttribute(key) : el.setAttribute(key, watches[idx]);
15076
+ });
15077
+ }, { immediate: true });
15078
+ }
15390
15079
  }
15391
- if (isElement(prevEl)) {
15080
+ if (isElement(prevEl) && isFocusable(prevEl)) {
15392
15081
  [
15393
15082
  "aria-controls",
15394
15083
  "aria-describedby",
@@ -15432,7 +15121,7 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
15432
15121
  };
15433
15122
  }
15434
15123
  });
15435
- var ElPopperTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$t, [["__file", "trigger.vue"]]);
15124
+ var ElPopperTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$v, [["__file", "trigger.vue"]]);
15436
15125
 
15437
15126
  const FOCUS_AFTER_TRAPPED = "focus-trap.focus-after-trapped";
15438
15127
  const FOCUS_AFTER_RELEASED = "focus-trap.focus-after-released";
@@ -15497,11 +15186,19 @@ const isSelectable = (element) => {
15497
15186
  const tryFocus = (element, shouldSelect) => {
15498
15187
  if (element && element.focus) {
15499
15188
  const prevFocusedElement = document.activeElement;
15189
+ let cleanup = false;
15190
+ if (isElement(element) && !isFocusable(element) && !element.getAttribute("tabindex")) {
15191
+ element.setAttribute("tabindex", "-1");
15192
+ cleanup = true;
15193
+ }
15500
15194
  element.focus({ preventScroll: true });
15501
15195
  lastAutomatedFocusTimestamp.value = window.performance.now();
15502
15196
  if (element !== prevFocusedElement && isSelectable(element) && shouldSelect) {
15503
15197
  element.select();
15504
15198
  }
15199
+ if (isElement(element) && cleanup) {
15200
+ element.removeAttribute("tabindex");
15201
+ }
15505
15202
  }
15506
15203
  };
15507
15204
  function removeFromStack(list, item) {
@@ -15582,7 +15279,48 @@ const createFocusOutPreventedEvent = (detail) => {
15582
15279
  });
15583
15280
  };
15584
15281
 
15585
- const _sfc_main$s = defineComponent({
15282
+ const EVENT_CODE = {
15283
+ tab: "Tab",
15284
+ enter: "Enter",
15285
+ space: "Space",
15286
+ left: "ArrowLeft",
15287
+ up: "ArrowUp",
15288
+ right: "ArrowRight",
15289
+ down: "ArrowDown",
15290
+ esc: "Escape",
15291
+ delete: "Delete",
15292
+ backspace: "Backspace",
15293
+ numpadEnter: "NumpadEnter",
15294
+ pageUp: "PageUp",
15295
+ pageDown: "PageDown",
15296
+ home: "Home",
15297
+ end: "End"
15298
+ };
15299
+
15300
+ let registeredEscapeHandlers = [];
15301
+ const cachedHandler = (event) => {
15302
+ if (event.code === EVENT_CODE.esc) {
15303
+ registeredEscapeHandlers.forEach((registeredHandler) => registeredHandler(event));
15304
+ }
15305
+ };
15306
+ const useEscapeKeydown = (handler) => {
15307
+ onMounted(() => {
15308
+ if (registeredEscapeHandlers.length === 0) {
15309
+ document.addEventListener("keydown", cachedHandler);
15310
+ }
15311
+ if (isClient)
15312
+ registeredEscapeHandlers.push(handler);
15313
+ });
15314
+ onBeforeUnmount(() => {
15315
+ registeredEscapeHandlers = registeredEscapeHandlers.filter((registeredHandler) => registeredHandler !== handler);
15316
+ if (registeredEscapeHandlers.length === 0) {
15317
+ if (isClient)
15318
+ document.removeEventListener("keydown", cachedHandler);
15319
+ }
15320
+ });
15321
+ };
15322
+
15323
+ const _sfc_main$u = defineComponent({
15586
15324
  name: "ElFocusTrap",
15587
15325
  inheritAttrs: false,
15588
15326
  props: {
@@ -15626,9 +15364,9 @@ const _sfc_main$s = defineComponent({
15626
15364
  return;
15627
15365
  if (focusLayer.paused)
15628
15366
  return;
15629
- const { key, altKey, ctrlKey, metaKey, currentTarget, shiftKey } = e;
15367
+ const { code, altKey, ctrlKey, metaKey, currentTarget, shiftKey } = e;
15630
15368
  const { loop } = props;
15631
- const isTabbing = key === EVENT_CODE.tab && !altKey && !ctrlKey && !metaKey;
15369
+ const isTabbing = code === EVENT_CODE.tab && !altKey && !ctrlKey && !metaKey;
15632
15370
  const currentFocusingEl = document.activeElement;
15633
15371
  if (isTabbing && currentFocusingEl) {
15634
15372
  const container = currentTarget;
@@ -15827,7 +15565,9 @@ const _sfc_main$s = defineComponent({
15827
15565
  function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
15828
15566
  return renderSlot(_ctx.$slots, "default", { handleKeydown: _ctx.onKeydown });
15829
15567
  }
15830
- var ElFocusTrap = /* @__PURE__ */ _export_sfc$1(_sfc_main$s, [["render", _sfc_render$6], ["__file", "focus-trap.vue"]]);
15568
+ var ElFocusTrap = /* @__PURE__ */ _export_sfc$1(_sfc_main$u, [["render", _sfc_render$6], ["__file", "focus-trap.vue"]]);
15569
+
15570
+ var E="top",R="bottom",W="right",P="left",me="auto",G=[E,R,W,P],U="start",J="end",Xe="clippingParents",je="viewport",K="popper",Ye="reference",De=G.reduce(function(t,e){return t.concat([e+"-"+U,e+"-"+J])},[]),Ee=[].concat(G,[me]).reduce(function(t,e){return t.concat([e,e+"-"+U,e+"-"+J])},[]),Ge="beforeRead",Je="read",Ke="afterRead",Qe="beforeMain",Ze="main",et="afterMain",tt="beforeWrite",nt="write",rt="afterWrite",ot=[Ge,Je,Ke,Qe,Ze,et,tt,nt,rt];function C(t){return t?(t.nodeName||"").toLowerCase():null}function H(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function Q(t){var e=H(t).Element;return t instanceof e||t instanceof Element}function B(t){var e=H(t).HTMLElement;return t instanceof e||t instanceof HTMLElement}function Pe(t){if(typeof ShadowRoot=="undefined")return !1;var e=H(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}function Mt(t){var e=t.state;Object.keys(e.elements).forEach(function(n){var r=e.styles[n]||{},o=e.attributes[n]||{},i=e.elements[n];!B(i)||!C(i)||(Object.assign(i.style,r),Object.keys(o).forEach(function(a){var s=o[a];s===!1?i.removeAttribute(a):i.setAttribute(a,s===!0?"":s);}));});}function Rt(t){var e=t.state,n={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,n.popper),e.styles=n,e.elements.arrow&&Object.assign(e.elements.arrow.style,n.arrow),function(){Object.keys(e.elements).forEach(function(r){var o=e.elements[r],i=e.attributes[r]||{},a=Object.keys(e.styles.hasOwnProperty(r)?e.styles[r]:n[r]),s=a.reduce(function(f,c){return f[c]="",f},{});!B(o)||!C(o)||(Object.assign(o.style,s),Object.keys(i).forEach(function(f){o.removeAttribute(f);}));});}}var Ae={name:"applyStyles",enabled:!0,phase:"write",fn:Mt,effect:Rt,requires:["computeStyles"]};function q(t){return t.split("-")[0]}var X=Math.max,ve=Math.min,Z=Math.round;function ee(t,e){e===void 0&&(e=!1);var n=t.getBoundingClientRect(),r=1,o=1;if(B(t)&&e){var i=t.offsetHeight,a=t.offsetWidth;a>0&&(r=Z(n.width)/a||1),i>0&&(o=Z(n.height)/i||1);}return {width:n.width/r,height:n.height/o,top:n.top/o,right:n.right/r,bottom:n.bottom/o,left:n.left/r,x:n.left/r,y:n.top/o}}function ke(t){var e=ee(t),n=t.offsetWidth,r=t.offsetHeight;return Math.abs(e.width-n)<=1&&(n=e.width),Math.abs(e.height-r)<=1&&(r=e.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:r}}function it(t,e){var n=e.getRootNode&&e.getRootNode();if(t.contains(e))return !0;if(n&&Pe(n)){var r=e;do{if(r&&t.isSameNode(r))return !0;r=r.parentNode||r.host;}while(r)}return !1}function N(t){return H(t).getComputedStyle(t)}function Wt(t){return ["table","td","th"].indexOf(C(t))>=0}function I(t){return ((Q(t)?t.ownerDocument:t.document)||window.document).documentElement}function ge(t){return C(t)==="html"?t:t.assignedSlot||t.parentNode||(Pe(t)?t.host:null)||I(t)}function at(t){return !B(t)||N(t).position==="fixed"?null:t.offsetParent}function Bt(t){var e=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,n=navigator.userAgent.indexOf("Trident")!==-1;if(n&&B(t)){var r=N(t);if(r.position==="fixed")return null}var o=ge(t);for(Pe(o)&&(o=o.host);B(o)&&["html","body"].indexOf(C(o))<0;){var i=N(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||e&&i.willChange==="filter"||e&&i.filter&&i.filter!=="none")return o;o=o.parentNode;}return null}function se(t){for(var e=H(t),n=at(t);n&&Wt(n)&&N(n).position==="static";)n=at(n);return n&&(C(n)==="html"||C(n)==="body"&&N(n).position==="static")?e:n||Bt(t)||e}function Le(t){return ["top","bottom"].indexOf(t)>=0?"x":"y"}function fe(t,e,n){return X(t,ve(e,n))}function St(t,e,n){var r=fe(t,e,n);return r>n?n:r}function st(){return {top:0,right:0,bottom:0,left:0}}function ft(t){return Object.assign({},st(),t)}function ct(t,e){return e.reduce(function(n,r){return n[r]=t,n},{})}var Tt=function(t,e){return t=typeof t=="function"?t(Object.assign({},e.rects,{placement:e.placement})):t,ft(typeof t!="number"?t:ct(t,G))};function Ht(t){var e,n=t.state,r=t.name,o=t.options,i=n.elements.arrow,a=n.modifiersData.popperOffsets,s=q(n.placement),f=Le(s),c=[P,W].indexOf(s)>=0,u=c?"height":"width";if(!(!i||!a)){var m=Tt(o.padding,n),v=ke(i),l=f==="y"?E:P,h=f==="y"?R:W,p=n.rects.reference[u]+n.rects.reference[f]-a[f]-n.rects.popper[u],g=a[f]-n.rects.reference[f],x=se(i),y=x?f==="y"?x.clientHeight||0:x.clientWidth||0:0,$=p/2-g/2,d=m[l],b=y-v[u]-m[h],w=y/2-v[u]/2+$,O=fe(d,w,b),j=f;n.modifiersData[r]=(e={},e[j]=O,e.centerOffset=O-w,e);}}function Ct(t){var e=t.state,n=t.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=e.elements.popper.querySelector(o),!o)||!it(e.elements.popper,o)||(e.elements.arrow=o));}var pt={name:"arrow",enabled:!0,phase:"main",fn:Ht,effect:Ct,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function te(t){return t.split("-")[1]}var qt={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Vt(t){var e=t.x,n=t.y,r=window,o=r.devicePixelRatio||1;return {x:Z(e*o)/o||0,y:Z(n*o)/o||0}}function ut(t){var e,n=t.popper,r=t.popperRect,o=t.placement,i=t.variation,a=t.offsets,s=t.position,f=t.gpuAcceleration,c=t.adaptive,u=t.roundOffsets,m=t.isFixed,v=a.x,l=v===void 0?0:v,h=a.y,p=h===void 0?0:h,g=typeof u=="function"?u({x:l,y:p}):{x:l,y:p};l=g.x,p=g.y;var x=a.hasOwnProperty("x"),y=a.hasOwnProperty("y"),$=P,d=E,b=window;if(c){var w=se(n),O="clientHeight",j="clientWidth";if(w===H(n)&&(w=I(n),N(w).position!=="static"&&s==="absolute"&&(O="scrollHeight",j="scrollWidth")),w=w,o===E||(o===P||o===W)&&i===J){d=R;var A=m&&w===b&&b.visualViewport?b.visualViewport.height:w[O];p-=A-r.height,p*=f?1:-1;}if(o===P||(o===E||o===R)&&i===J){$=W;var k=m&&w===b&&b.visualViewport?b.visualViewport.width:w[j];l-=k-r.width,l*=f?1:-1;}}var D=Object.assign({position:s},c&&qt),S=u===!0?Vt({x:l,y:p}):{x:l,y:p};if(l=S.x,p=S.y,f){var L;return Object.assign({},D,(L={},L[d]=y?"0":"",L[$]=x?"0":"",L.transform=(b.devicePixelRatio||1)<=1?"translate("+l+"px, "+p+"px)":"translate3d("+l+"px, "+p+"px, 0)",L))}return Object.assign({},D,(e={},e[d]=y?p+"px":"",e[$]=x?l+"px":"",e.transform="",e))}function Nt(t){var e=t.state,n=t.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,a=i===void 0?!0:i,s=n.roundOffsets,f=s===void 0?!0:s,c={placement:q(e.placement),variation:te(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:e.options.strategy==="fixed"};e.modifiersData.popperOffsets!=null&&(e.styles.popper=Object.assign({},e.styles.popper,ut(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:a,roundOffsets:f})))),e.modifiersData.arrow!=null&&(e.styles.arrow=Object.assign({},e.styles.arrow,ut(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:f})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement});}var Me={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Nt,data:{}},ye={passive:!0};function It(t){var e=t.state,n=t.instance,r=t.options,o=r.scroll,i=o===void 0?!0:o,a=r.resize,s=a===void 0?!0:a,f=H(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return i&&c.forEach(function(u){u.addEventListener("scroll",n.update,ye);}),s&&f.addEventListener("resize",n.update,ye),function(){i&&c.forEach(function(u){u.removeEventListener("scroll",n.update,ye);}),s&&f.removeEventListener("resize",n.update,ye);}}var Re={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:It,data:{}},_t={left:"right",right:"left",bottom:"top",top:"bottom"};function be(t){return t.replace(/left|right|bottom|top/g,function(e){return _t[e]})}var zt={start:"end",end:"start"};function lt(t){return t.replace(/start|end/g,function(e){return zt[e]})}function We(t){var e=H(t),n=e.pageXOffset,r=e.pageYOffset;return {scrollLeft:n,scrollTop:r}}function Be(t){return ee(I(t)).left+We(t).scrollLeft}function Ft(t){var e=H(t),n=I(t),r=e.visualViewport,o=n.clientWidth,i=n.clientHeight,a=0,s=0;return r&&(o=r.width,i=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(a=r.offsetLeft,s=r.offsetTop)),{width:o,height:i,x:a+Be(t),y:s}}function Ut(t){var e,n=I(t),r=We(t),o=(e=t.ownerDocument)==null?void 0:e.body,i=X(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),a=X(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),s=-r.scrollLeft+Be(t),f=-r.scrollTop;return N(o||n).direction==="rtl"&&(s+=X(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:a,x:s,y:f}}function Se(t){var e=N(t),n=e.overflow,r=e.overflowX,o=e.overflowY;return /auto|scroll|overlay|hidden/.test(n+o+r)}function dt(t){return ["html","body","#document"].indexOf(C(t))>=0?t.ownerDocument.body:B(t)&&Se(t)?t:dt(ge(t))}function ce(t,e){var n;e===void 0&&(e=[]);var r=dt(t),o=r===((n=t.ownerDocument)==null?void 0:n.body),i=H(r),a=o?[i].concat(i.visualViewport||[],Se(r)?r:[]):r,s=e.concat(a);return o?s:s.concat(ce(ge(a)))}function Te(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Xt(t){var e=ee(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}function ht(t,e){return e===je?Te(Ft(t)):Q(e)?Xt(e):Te(Ut(I(t)))}function Yt(t){var e=ce(ge(t)),n=["absolute","fixed"].indexOf(N(t).position)>=0,r=n&&B(t)?se(t):t;return Q(r)?e.filter(function(o){return Q(o)&&it(o,r)&&C(o)!=="body"}):[]}function Gt(t,e,n){var r=e==="clippingParents"?Yt(t):[].concat(e),o=[].concat(r,[n]),i=o[0],a=o.reduce(function(s,f){var c=ht(t,f);return s.top=X(c.top,s.top),s.right=ve(c.right,s.right),s.bottom=ve(c.bottom,s.bottom),s.left=X(c.left,s.left),s},ht(t,i));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function mt(t){var e=t.reference,n=t.element,r=t.placement,o=r?q(r):null,i=r?te(r):null,a=e.x+e.width/2-n.width/2,s=e.y+e.height/2-n.height/2,f;switch(o){case E:f={x:a,y:e.y-n.height};break;case R:f={x:a,y:e.y+e.height};break;case W:f={x:e.x+e.width,y:s};break;case P:f={x:e.x-n.width,y:s};break;default:f={x:e.x,y:e.y};}var c=o?Le(o):null;if(c!=null){var u=c==="y"?"height":"width";switch(i){case U:f[c]=f[c]-(e[u]/2-n[u]/2);break;case J:f[c]=f[c]+(e[u]/2-n[u]/2);break}}return f}function ne(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=r===void 0?t.placement:r,i=n.boundary,a=i===void 0?Xe:i,s=n.rootBoundary,f=s===void 0?je:s,c=n.elementContext,u=c===void 0?K:c,m=n.altBoundary,v=m===void 0?!1:m,l=n.padding,h=l===void 0?0:l,p=ft(typeof h!="number"?h:ct(h,G)),g=u===K?Ye:K,x=t.rects.popper,y=t.elements[v?g:u],$=Gt(Q(y)?y:y.contextElement||I(t.elements.popper),a,f),d=ee(t.elements.reference),b=mt({reference:d,element:x,strategy:"absolute",placement:o}),w=Te(Object.assign({},x,b)),O=u===K?w:d,j={top:$.top-O.top+p.top,bottom:O.bottom-$.bottom+p.bottom,left:$.left-O.left+p.left,right:O.right-$.right+p.right},A=t.modifiersData.offset;if(u===K&&A){var k=A[o];Object.keys(j).forEach(function(D){var S=[W,R].indexOf(D)>=0?1:-1,L=[E,R].indexOf(D)>=0?"y":"x";j[D]+=k[L]*S;});}return j}function Jt(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=n.boundary,i=n.rootBoundary,a=n.padding,s=n.flipVariations,f=n.allowedAutoPlacements,c=f===void 0?Ee:f,u=te(r),m=u?s?De:De.filter(function(h){return te(h)===u}):G,v=m.filter(function(h){return c.indexOf(h)>=0});v.length===0&&(v=m);var l=v.reduce(function(h,p){return h[p]=ne(t,{placement:p,boundary:o,rootBoundary:i,padding:a})[q(p)],h},{});return Object.keys(l).sort(function(h,p){return l[h]-l[p]})}function Kt(t){if(q(t)===me)return [];var e=be(t);return [lt(t),e,lt(e)]}function Qt(t){var e=t.state,n=t.options,r=t.name;if(!e.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!0:a,f=n.fallbackPlacements,c=n.padding,u=n.boundary,m=n.rootBoundary,v=n.altBoundary,l=n.flipVariations,h=l===void 0?!0:l,p=n.allowedAutoPlacements,g=e.options.placement,x=q(g),y=x===g,$=f||(y||!h?[be(g)]:Kt(g)),d=[g].concat($).reduce(function(z,V){return z.concat(q(V)===me?Jt(e,{placement:V,boundary:u,rootBoundary:m,padding:c,flipVariations:h,allowedAutoPlacements:p}):V)},[]),b=e.rects.reference,w=e.rects.popper,O=new Map,j=!0,A=d[0],k=0;k<d.length;k++){var D=d[k],S=q(D),L=te(D)===U,re=[E,R].indexOf(S)>=0,oe=re?"width":"height",M=ne(e,{placement:D,boundary:u,rootBoundary:m,altBoundary:v,padding:c}),T=re?L?W:P:L?R:E;b[oe]>w[oe]&&(T=be(T));var pe=be(T),_=[];if(i&&_.push(M[S]<=0),s&&_.push(M[T]<=0,M[pe]<=0),_.every(function(z){return z})){A=D,j=!1;break}O.set(D,_);}if(j)for(var ue=h?3:1,xe=function(z){var V=d.find(function(de){var ae=O.get(de);if(ae)return ae.slice(0,z).every(function(Y){return Y})});if(V)return A=V,"break"},ie=ue;ie>0;ie--){var le=xe(ie);if(le==="break")break}e.placement!==A&&(e.modifiersData[r]._skip=!0,e.placement=A,e.reset=!0);}}var vt={name:"flip",enabled:!0,phase:"main",fn:Qt,requiresIfExists:["offset"],data:{_skip:!1}};function gt(t,e,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function yt(t){return [E,W,R,P].some(function(e){return t[e]>=0})}function Zt(t){var e=t.state,n=t.name,r=e.rects.reference,o=e.rects.popper,i=e.modifiersData.preventOverflow,a=ne(e,{elementContext:"reference"}),s=ne(e,{altBoundary:!0}),f=gt(a,r),c=gt(s,o,i),u=yt(f),m=yt(c);e.modifiersData[n]={referenceClippingOffsets:f,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:m},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":m});}var bt={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Zt};function en(t,e,n){var r=q(t),o=[P,E].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},e,{placement:t})):n,a=i[0],s=i[1];return a=a||0,s=(s||0)*o,[P,W].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function tn(t){var e=t.state,n=t.options,r=t.name,o=n.offset,i=o===void 0?[0,0]:o,a=Ee.reduce(function(u,m){return u[m]=en(m,e.rects,i),u},{}),s=a[e.placement],f=s.x,c=s.y;e.modifiersData.popperOffsets!=null&&(e.modifiersData.popperOffsets.x+=f,e.modifiersData.popperOffsets.y+=c),e.modifiersData[r]=a;}var wt={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:tn};function nn(t){var e=t.state,n=t.name;e.modifiersData[n]=mt({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement});}var He={name:"popperOffsets",enabled:!0,phase:"read",fn:nn,data:{}};function rn(t){return t==="x"?"y":"x"}function on(t){var e=t.state,n=t.options,r=t.name,o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!1:a,f=n.boundary,c=n.rootBoundary,u=n.altBoundary,m=n.padding,v=n.tether,l=v===void 0?!0:v,h=n.tetherOffset,p=h===void 0?0:h,g=ne(e,{boundary:f,rootBoundary:c,padding:m,altBoundary:u}),x=q(e.placement),y=te(e.placement),$=!y,d=Le(x),b=rn(d),w=e.modifiersData.popperOffsets,O=e.rects.reference,j=e.rects.popper,A=typeof p=="function"?p(Object.assign({},e.rects,{placement:e.placement})):p,k=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),D=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,S={x:0,y:0};if(w){if(i){var L,re=d==="y"?E:P,oe=d==="y"?R:W,M=d==="y"?"height":"width",T=w[d],pe=T+g[re],_=T-g[oe],ue=l?-j[M]/2:0,xe=y===U?O[M]:j[M],ie=y===U?-j[M]:-O[M],le=e.elements.arrow,z=l&&le?ke(le):{width:0,height:0},V=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:st(),de=V[re],ae=V[oe],Y=fe(0,O[M],z[M]),jt=$?O[M]/2-ue-Y-de-k.mainAxis:xe-Y-de-k.mainAxis,Dt=$?-O[M]/2+ue+Y+ae+k.mainAxis:ie+Y+ae+k.mainAxis,Oe=e.elements.arrow&&se(e.elements.arrow),Et=Oe?d==="y"?Oe.clientTop||0:Oe.clientLeft||0:0,Ce=(L=D==null?void 0:D[d])!=null?L:0,Pt=T+jt-Ce-Et,At=T+Dt-Ce,qe=fe(l?ve(pe,Pt):pe,T,l?X(_,At):_);w[d]=qe,S[d]=qe-T;}if(s){var Ve,kt=d==="x"?E:P,Lt=d==="x"?R:W,F=w[b],he=b==="y"?"height":"width",Ne=F+g[kt],Ie=F-g[Lt],$e=[E,P].indexOf(x)!==-1,_e=(Ve=D==null?void 0:D[b])!=null?Ve:0,ze=$e?Ne:F-O[he]-j[he]-_e+k.altAxis,Fe=$e?F+O[he]+j[he]-_e-k.altAxis:Ie,Ue=l&&$e?St(ze,F,Fe):fe(l?ze:Ne,F,l?Fe:Ie);w[b]=Ue,S[b]=Ue-F;}e.modifiersData[r]=S;}}var xt={name:"preventOverflow",enabled:!0,phase:"main",fn:on,requiresIfExists:["offset"]};function an(t){return {scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function sn(t){return t===H(t)||!B(t)?We(t):an(t)}function fn(t){var e=t.getBoundingClientRect(),n=Z(e.width)/t.offsetWidth||1,r=Z(e.height)/t.offsetHeight||1;return n!==1||r!==1}function cn(t,e,n){n===void 0&&(n=!1);var r=B(e),o=B(e)&&fn(e),i=I(e),a=ee(t,o),s={scrollLeft:0,scrollTop:0},f={x:0,y:0};return (r||!r&&!n)&&((C(e)!=="body"||Se(i))&&(s=sn(e)),B(e)?(f=ee(e,!0),f.x+=e.clientLeft,f.y+=e.clientTop):i&&(f.x=Be(i))),{x:a.left+s.scrollLeft-f.x,y:a.top+s.scrollTop-f.y,width:a.width,height:a.height}}function pn(t){var e=new Map,n=new Set,r=[];t.forEach(function(i){e.set(i.name,i);});function o(i){n.add(i.name);var a=[].concat(i.requires||[],i.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var f=e.get(s);f&&o(f);}}),r.push(i);}return t.forEach(function(i){n.has(i.name)||o(i);}),r}function un(t){var e=pn(t);return ot.reduce(function(n,r){return n.concat(e.filter(function(o){return o.phase===r}))},[])}function ln(t){var e;return function(){return e||(e=new Promise(function(n){Promise.resolve().then(function(){e=void 0,n(t());});})),e}}function dn(t){var e=t.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(e).map(function(n){return e[n]})}var Ot={placement:"bottom",modifiers:[],strategy:"absolute"};function $t(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return !e.some(function(r){return !(r&&typeof r.getBoundingClientRect=="function")})}function we(t){t===void 0&&(t={});var e=t,n=e.defaultModifiers,r=n===void 0?[]:n,o=e.defaultOptions,i=o===void 0?Ot:o;return function(a,s,f){f===void 0&&(f=i);var c={placement:"bottom",orderedModifiers:[],options:Object.assign({},Ot,i),modifiersData:{},elements:{reference:a,popper:s},attributes:{},styles:{}},u=[],m=!1,v={state:c,setOptions:function(p){var g=typeof p=="function"?p(c.options):p;h(),c.options=Object.assign({},i,c.options,g),c.scrollParents={reference:Q(a)?ce(a):a.contextElement?ce(a.contextElement):[],popper:ce(s)};var x=un(dn([].concat(r,c.options.modifiers)));return c.orderedModifiers=x.filter(function(y){return y.enabled}),l(),v.update()},forceUpdate:function(){if(!m){var p=c.elements,g=p.reference,x=p.popper;if($t(g,x)){c.rects={reference:cn(g,se(x),c.options.strategy==="fixed"),popper:ke(x)},c.reset=!1,c.placement=c.options.placement,c.orderedModifiers.forEach(function(j){return c.modifiersData[j.name]=Object.assign({},j.data)});for(var y=0;y<c.orderedModifiers.length;y++){if(c.reset===!0){c.reset=!1,y=-1;continue}var $=c.orderedModifiers[y],d=$.fn,b=$.options,w=b===void 0?{}:b,O=$.name;typeof d=="function"&&(c=d({state:c,options:w,name:O,instance:v})||c);}}}},update:ln(function(){return new Promise(function(p){v.forceUpdate(),p(c);})}),destroy:function(){h(),m=!0;}};if(!$t(a,s))return v;v.setOptions(f).then(function(p){!m&&f.onFirstUpdate&&f.onFirstUpdate(p);});function l(){c.orderedModifiers.forEach(function(p){var g=p.name,x=p.options,y=x===void 0?{}:x,$=p.effect;if(typeof $=="function"){var d=$({state:c,name:g,instance:v,options:y}),b=function(){};u.push(d||b);}});}function h(){u.forEach(function(p){return p()}),u=[];}return v}}we();var mn=[Re,He,Me,Ae];we({defaultModifiers:mn});var gn=[Re,He,Me,Ae,wt,vt,xt,pt,bt],yn=we({defaultModifiers:gn});
15831
15571
 
15832
15572
  const POSITIONING_STRATEGIES = ["fixed", "absolute"];
15833
15573
  const popperCoreConfigProps = buildProps({
@@ -15917,6 +15657,50 @@ const popperContentEmits = {
15917
15657
  close: () => true
15918
15658
  };
15919
15659
 
15660
+ const usePopperContentFocusTrap = (props, emit) => {
15661
+ const trapped = ref(false);
15662
+ const focusStartRef = ref();
15663
+ const onFocusAfterTrapped = () => {
15664
+ emit("focus");
15665
+ };
15666
+ const onFocusAfterReleased = (event) => {
15667
+ var _a;
15668
+ if (((_a = event.detail) == null ? void 0 : _a.focusReason) !== "pointer") {
15669
+ focusStartRef.value = "first";
15670
+ emit("blur");
15671
+ }
15672
+ };
15673
+ const onFocusInTrap = (event) => {
15674
+ if (props.visible && !trapped.value) {
15675
+ if (event.target) {
15676
+ focusStartRef.value = event.target;
15677
+ }
15678
+ trapped.value = true;
15679
+ }
15680
+ };
15681
+ const onFocusoutPrevented = (event) => {
15682
+ if (!props.trapping) {
15683
+ if (event.detail.focusReason === "pointer") {
15684
+ event.preventDefault();
15685
+ }
15686
+ trapped.value = false;
15687
+ }
15688
+ };
15689
+ const onReleaseRequested = () => {
15690
+ trapped.value = false;
15691
+ emit("close");
15692
+ };
15693
+ return {
15694
+ focusStartRef,
15695
+ trapped,
15696
+ onFocusAfterReleased,
15697
+ onFocusAfterTrapped,
15698
+ onFocusInTrap,
15699
+ onFocusoutPrevented,
15700
+ onReleaseRequested
15701
+ };
15702
+ };
15703
+
15920
15704
  const buildPopperOptions = (props, modifiers = []) => {
15921
15705
  const { placement, strategy, popperOptions } = props;
15922
15706
  const options = {
@@ -15974,6 +15758,95 @@ function deriveExtraModifiers(options, modifiers) {
15974
15758
  }
15975
15759
  }
15976
15760
 
15761
+ const usePopper = (referenceElementRef, popperElementRef, opts = {}) => {
15762
+ const stateUpdater = {
15763
+ name: "updateState",
15764
+ enabled: true,
15765
+ phase: "write",
15766
+ fn: ({ state }) => {
15767
+ const derivedState = deriveState(state);
15768
+ Object.assign(states.value, derivedState);
15769
+ },
15770
+ requires: ["computeStyles"]
15771
+ };
15772
+ const options = computed(() => {
15773
+ const { onFirstUpdate, placement, strategy, modifiers } = unref(opts);
15774
+ return {
15775
+ onFirstUpdate,
15776
+ placement: placement || "bottom",
15777
+ strategy: strategy || "absolute",
15778
+ modifiers: [
15779
+ ...modifiers || [],
15780
+ stateUpdater,
15781
+ { name: "applyStyles", enabled: false }
15782
+ ]
15783
+ };
15784
+ });
15785
+ const instanceRef = shallowRef();
15786
+ const states = ref({
15787
+ styles: {
15788
+ popper: {
15789
+ position: unref(options).strategy,
15790
+ left: "0",
15791
+ top: "0"
15792
+ },
15793
+ arrow: {
15794
+ position: "absolute"
15795
+ }
15796
+ },
15797
+ attributes: {}
15798
+ });
15799
+ const destroy = () => {
15800
+ if (!instanceRef.value)
15801
+ return;
15802
+ instanceRef.value.destroy();
15803
+ instanceRef.value = void 0;
15804
+ };
15805
+ watch(options, (newOptions) => {
15806
+ const instance = unref(instanceRef);
15807
+ if (instance) {
15808
+ instance.setOptions(newOptions);
15809
+ }
15810
+ }, {
15811
+ deep: true
15812
+ });
15813
+ watch([referenceElementRef, popperElementRef], ([referenceElement, popperElement]) => {
15814
+ destroy();
15815
+ if (!referenceElement || !popperElement)
15816
+ return;
15817
+ instanceRef.value = yn(referenceElement, popperElement, unref(options));
15818
+ });
15819
+ onBeforeUnmount(() => {
15820
+ destroy();
15821
+ });
15822
+ return {
15823
+ state: computed(() => {
15824
+ var _a;
15825
+ return { ...((_a = unref(instanceRef)) == null ? void 0 : _a.state) || {} };
15826
+ }),
15827
+ styles: computed(() => unref(states).styles),
15828
+ attributes: computed(() => unref(states).attributes),
15829
+ update: () => {
15830
+ var _a;
15831
+ return (_a = unref(instanceRef)) == null ? void 0 : _a.update();
15832
+ },
15833
+ forceUpdate: () => {
15834
+ var _a;
15835
+ return (_a = unref(instanceRef)) == null ? void 0 : _a.forceUpdate();
15836
+ },
15837
+ instanceRef: computed(() => unref(instanceRef))
15838
+ };
15839
+ };
15840
+ function deriveState(state) {
15841
+ const elements = Object.keys(state.elements);
15842
+ const styles = fromPairs(elements.map((element) => [element, state.styles[element] || {}]));
15843
+ const attributes = fromPairs(elements.map((element) => [element, state.attributes[element]]));
15844
+ return {
15845
+ styles,
15846
+ attributes
15847
+ };
15848
+ }
15849
+
15977
15850
  const DEFAULT_ARROW_OFFSET = 0;
15978
15851
  const usePopperContent = (props) => {
15979
15852
  const { popperInstanceRef, contentRef, triggerRef, role } = inject(POPPER_INJECTION_KEY, void 0);
@@ -16058,68 +15931,24 @@ const usePopperContentDOM = (props, {
16058
15931
  const ariaModal = computed(() => role.value === "dialog" ? "false" : void 0);
16059
15932
  const arrowStyle = computed(() => unref(styles).arrow || {});
16060
15933
  const updateZIndex = () => {
16061
- contentZIndex.value = isNumber(props.zIndex) ? props.zIndex : nextZIndex();
16062
- };
16063
- return {
16064
- ariaModal,
16065
- arrowStyle,
16066
- contentAttrs,
16067
- contentClass,
16068
- contentStyle,
16069
- contentZIndex,
16070
- updateZIndex
16071
- };
16072
- };
16073
-
16074
- const usePopperContentFocusTrap = (props, emit) => {
16075
- const trapped = ref(false);
16076
- const focusStartRef = ref();
16077
- const onFocusAfterTrapped = () => {
16078
- emit("focus");
16079
- };
16080
- const onFocusAfterReleased = (event) => {
16081
- var _a;
16082
- if (((_a = event.detail) == null ? void 0 : _a.focusReason) !== "pointer") {
16083
- focusStartRef.value = "first";
16084
- emit("blur");
16085
- }
16086
- };
16087
- const onFocusInTrap = (event) => {
16088
- if (props.visible && !trapped.value) {
16089
- if (event.target) {
16090
- focusStartRef.value = event.target;
16091
- }
16092
- trapped.value = true;
16093
- }
16094
- };
16095
- const onFocusoutPrevented = (event) => {
16096
- if (!props.trapping) {
16097
- if (event.detail.focusReason === "pointer") {
16098
- event.preventDefault();
16099
- }
16100
- trapped.value = false;
16101
- }
16102
- };
16103
- const onReleaseRequested = () => {
16104
- trapped.value = false;
16105
- emit("close");
16106
- };
16107
- return {
16108
- focusStartRef,
16109
- trapped,
16110
- onFocusAfterReleased,
16111
- onFocusAfterTrapped,
16112
- onFocusInTrap,
16113
- onFocusoutPrevented,
16114
- onReleaseRequested
15934
+ contentZIndex.value = isNumber(props.zIndex) ? props.zIndex : nextZIndex();
15935
+ };
15936
+ return {
15937
+ ariaModal,
15938
+ arrowStyle,
15939
+ contentAttrs,
15940
+ contentClass,
15941
+ contentStyle,
15942
+ contentZIndex,
15943
+ updateZIndex
16115
15944
  };
16116
15945
  };
16117
15946
 
16118
- const __default__$j = defineComponent({
15947
+ const __default__$l = defineComponent({
16119
15948
  name: "ElPopperContent"
16120
15949
  });
16121
- const _sfc_main$r = /* @__PURE__ */ defineComponent({
16122
- ...__default__$j,
15950
+ const _sfc_main$t = /* @__PURE__ */ defineComponent({
15951
+ ...__default__$l,
16123
15952
  props: popperContentProps,
16124
15953
  emits: popperContentEmits,
16125
15954
  setup(__props, { expose, emit }) {
@@ -16235,12 +16064,75 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
16235
16064
  };
16236
16065
  }
16237
16066
  });
16238
- var ElPopperContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$r, [["__file", "content.vue"]]);
16067
+ var ElPopperContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$t, [["__file", "content.vue"]]);
16239
16068
 
16240
16069
  const ElPopper = withInstall(Popper);
16241
16070
 
16242
16071
  const TOOLTIP_INJECTION_KEY = Symbol("elTooltip");
16243
16072
 
16073
+ function useTimeout() {
16074
+ let timeoutHandle;
16075
+ const registerTimeout = (fn, delay) => {
16076
+ cancelTimeout();
16077
+ timeoutHandle = window.setTimeout(fn, delay);
16078
+ };
16079
+ const cancelTimeout = () => window.clearTimeout(timeoutHandle);
16080
+ tryOnScopeDispose(() => cancelTimeout());
16081
+ return {
16082
+ registerTimeout,
16083
+ cancelTimeout
16084
+ };
16085
+ }
16086
+
16087
+ const useDelayedToggleProps = buildProps({
16088
+ showAfter: {
16089
+ type: Number,
16090
+ default: 0
16091
+ },
16092
+ hideAfter: {
16093
+ type: Number,
16094
+ default: 200
16095
+ },
16096
+ autoClose: {
16097
+ type: Number,
16098
+ default: 0
16099
+ }
16100
+ });
16101
+ const useDelayedToggle = ({
16102
+ showAfter,
16103
+ hideAfter,
16104
+ autoClose,
16105
+ open,
16106
+ close
16107
+ }) => {
16108
+ const { registerTimeout } = useTimeout();
16109
+ const {
16110
+ registerTimeout: registerTimeoutForAutoClose,
16111
+ cancelTimeout: cancelTimeoutForAutoClose
16112
+ } = useTimeout();
16113
+ const onOpen = (event) => {
16114
+ registerTimeout(() => {
16115
+ open(event);
16116
+ const _autoClose = unref(autoClose);
16117
+ if (isNumber(_autoClose) && _autoClose > 0) {
16118
+ registerTimeoutForAutoClose(() => {
16119
+ close(event);
16120
+ }, _autoClose);
16121
+ }
16122
+ }, unref(showAfter));
16123
+ };
16124
+ const onClose = (event) => {
16125
+ cancelTimeoutForAutoClose();
16126
+ registerTimeout(() => {
16127
+ close(event);
16128
+ }, unref(hideAfter));
16129
+ };
16130
+ return {
16131
+ onOpen,
16132
+ onClose
16133
+ };
16134
+ };
16135
+
16244
16136
  const useTooltipContentProps = buildProps({
16245
16137
  ...useDelayedToggleProps,
16246
16138
  ...popperContentProps,
@@ -16275,10 +16167,133 @@ const useTooltipTriggerProps = buildProps({
16275
16167
  },
16276
16168
  triggerKeys: {
16277
16169
  type: definePropType(Array),
16278
- default: () => [EVENT_CODE.enter, EVENT_CODE.space]
16170
+ default: () => [EVENT_CODE.enter, EVENT_CODE.numpadEnter, EVENT_CODE.space]
16279
16171
  }
16280
16172
  });
16281
16173
 
16174
+ const _prop = buildProp({
16175
+ type: definePropType(Boolean),
16176
+ default: null
16177
+ });
16178
+ const _event = buildProp({
16179
+ type: definePropType(Function)
16180
+ });
16181
+ const createModelToggleComposable = (name) => {
16182
+ const updateEventKey = `update:${name}`;
16183
+ const updateEventKeyRaw = `onUpdate:${name}`;
16184
+ const useModelToggleEmits2 = [updateEventKey];
16185
+ const useModelToggleProps2 = {
16186
+ [name]: _prop,
16187
+ [updateEventKeyRaw]: _event
16188
+ };
16189
+ const useModelToggle2 = ({
16190
+ indicator,
16191
+ toggleReason,
16192
+ shouldHideWhenRouteChanges,
16193
+ shouldProceed,
16194
+ onShow,
16195
+ onHide
16196
+ }) => {
16197
+ const instance = getCurrentInstance();
16198
+ const { emit } = instance;
16199
+ const props = instance.props;
16200
+ const hasUpdateHandler = computed(() => isFunction$1(props[updateEventKeyRaw]));
16201
+ const isModelBindingAbsent = computed(() => props[name] === null);
16202
+ const doShow = (event) => {
16203
+ if (indicator.value === true) {
16204
+ return;
16205
+ }
16206
+ indicator.value = true;
16207
+ if (toggleReason) {
16208
+ toggleReason.value = event;
16209
+ }
16210
+ if (isFunction$1(onShow)) {
16211
+ onShow(event);
16212
+ }
16213
+ };
16214
+ const doHide = (event) => {
16215
+ if (indicator.value === false) {
16216
+ return;
16217
+ }
16218
+ indicator.value = false;
16219
+ if (toggleReason) {
16220
+ toggleReason.value = event;
16221
+ }
16222
+ if (isFunction$1(onHide)) {
16223
+ onHide(event);
16224
+ }
16225
+ };
16226
+ const show = (event) => {
16227
+ if (props.disabled === true || isFunction$1(shouldProceed) && !shouldProceed())
16228
+ return;
16229
+ const shouldEmit = hasUpdateHandler.value && isClient;
16230
+ if (shouldEmit) {
16231
+ emit(updateEventKey, true);
16232
+ }
16233
+ if (isModelBindingAbsent.value || !shouldEmit) {
16234
+ doShow(event);
16235
+ }
16236
+ };
16237
+ const hide = (event) => {
16238
+ if (props.disabled === true || !isClient)
16239
+ return;
16240
+ const shouldEmit = hasUpdateHandler.value && isClient;
16241
+ if (shouldEmit) {
16242
+ emit(updateEventKey, false);
16243
+ }
16244
+ if (isModelBindingAbsent.value || !shouldEmit) {
16245
+ doHide(event);
16246
+ }
16247
+ };
16248
+ const onChange = (val) => {
16249
+ if (!isBoolean(val))
16250
+ return;
16251
+ if (props.disabled && val) {
16252
+ if (hasUpdateHandler.value) {
16253
+ emit(updateEventKey, false);
16254
+ }
16255
+ } else if (indicator.value !== val) {
16256
+ if (val) {
16257
+ doShow();
16258
+ } else {
16259
+ doHide();
16260
+ }
16261
+ }
16262
+ };
16263
+ const toggle = () => {
16264
+ if (indicator.value) {
16265
+ hide();
16266
+ } else {
16267
+ show();
16268
+ }
16269
+ };
16270
+ watch(() => props[name], onChange);
16271
+ if (shouldHideWhenRouteChanges && instance.appContext.config.globalProperties.$route !== void 0) {
16272
+ watch(() => ({
16273
+ ...instance.proxy.$route
16274
+ }), () => {
16275
+ if (shouldHideWhenRouteChanges.value && indicator.value) {
16276
+ hide();
16277
+ }
16278
+ });
16279
+ }
16280
+ onMounted(() => {
16281
+ onChange(props[name]);
16282
+ });
16283
+ return {
16284
+ hide,
16285
+ show,
16286
+ toggle,
16287
+ hasUpdateHandler
16288
+ };
16289
+ };
16290
+ return {
16291
+ useModelToggle: useModelToggle2,
16292
+ useModelToggleProps: useModelToggleProps2,
16293
+ useModelToggleEmits: useModelToggleEmits2
16294
+ };
16295
+ };
16296
+
16282
16297
  const {
16283
16298
  useModelToggleProps: useTooltipModelToggleProps,
16284
16299
  useModelToggleEmits: useTooltipModelToggleEmits,
@@ -16317,11 +16332,21 @@ const whenTrigger = (trigger, type, handler) => {
16317
16332
  };
16318
16333
  };
16319
16334
 
16320
- const __default__$i = defineComponent({
16335
+ const composeEventHandlers = (theirsHandler, oursHandler, { checkForDefaultPrevented = true } = {}) => {
16336
+ const handleEvent = (event) => {
16337
+ const shouldPrevent = theirsHandler == null ? void 0 : theirsHandler(event);
16338
+ if (checkForDefaultPrevented === false || !shouldPrevent) {
16339
+ return oursHandler == null ? void 0 : oursHandler(event);
16340
+ }
16341
+ };
16342
+ return handleEvent;
16343
+ };
16344
+
16345
+ const __default__$k = defineComponent({
16321
16346
  name: "ElTooltipTrigger"
16322
16347
  });
16323
- const _sfc_main$q = /* @__PURE__ */ defineComponent({
16324
- ...__default__$i,
16348
+ const _sfc_main$s = /* @__PURE__ */ defineComponent({
16349
+ ...__default__$k,
16325
16350
  props: useTooltipTriggerProps,
16326
16351
  setup(__props, { expose }) {
16327
16352
  const props = __props;
@@ -16380,7 +16405,7 @@ const _sfc_main$q = /* @__PURE__ */ defineComponent({
16380
16405
  };
16381
16406
  }
16382
16407
  });
16383
- var ElTooltipTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$q, [["__file", "trigger.vue"]]);
16408
+ var ElTooltipTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$s, [["__file", "trigger.vue"]]);
16384
16409
 
16385
16410
  const teleportProps = buildProps({
16386
16411
  to: {
@@ -16390,7 +16415,7 @@ const teleportProps = buildProps({
16390
16415
  disabled: Boolean
16391
16416
  });
16392
16417
 
16393
- const _sfc_main$p = /* @__PURE__ */ defineComponent({
16418
+ const _sfc_main$r = /* @__PURE__ */ defineComponent({
16394
16419
  __name: "teleport",
16395
16420
  props: teleportProps,
16396
16421
  setup(__props) {
@@ -16404,22 +16429,55 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
16404
16429
  };
16405
16430
  }
16406
16431
  });
16407
- var Teleport = /* @__PURE__ */ _export_sfc$1(_sfc_main$p, [["__file", "teleport.vue"]]);
16432
+ var Teleport = /* @__PURE__ */ _export_sfc$1(_sfc_main$r, [["__file", "teleport.vue"]]);
16408
16433
 
16409
16434
  const ElTeleport = withInstall(Teleport);
16410
16435
 
16411
- const __default__$h = defineComponent({
16436
+ const usePopperContainerId = () => {
16437
+ const namespace = useGetDerivedNamespace();
16438
+ const idInjection = useIdInjection();
16439
+ const id = computed(() => {
16440
+ return `${namespace.value}-popper-container-${idInjection.prefix}`;
16441
+ });
16442
+ const selector = computed(() => `#${id.value}`);
16443
+ return {
16444
+ id,
16445
+ selector
16446
+ };
16447
+ };
16448
+ const createContainer = (id) => {
16449
+ const container = document.createElement("div");
16450
+ container.id = id;
16451
+ document.body.appendChild(container);
16452
+ return container;
16453
+ };
16454
+ const usePopperContainer = () => {
16455
+ const { id, selector } = usePopperContainerId();
16456
+ onBeforeMount(() => {
16457
+ if (!isClient)
16458
+ return;
16459
+ if (!document.body.querySelector(selector.value)) {
16460
+ createContainer(id.value);
16461
+ }
16462
+ });
16463
+ return {
16464
+ id,
16465
+ selector
16466
+ };
16467
+ };
16468
+
16469
+ const __default__$j = defineComponent({
16412
16470
  name: "ElTooltipContent",
16413
16471
  inheritAttrs: false
16414
16472
  });
16415
- const _sfc_main$o = /* @__PURE__ */ defineComponent({
16416
- ...__default__$h,
16473
+ const _sfc_main$q = /* @__PURE__ */ defineComponent({
16474
+ ...__default__$j,
16417
16475
  props: useTooltipContentProps,
16418
16476
  setup(__props, { expose }) {
16419
16477
  const props = __props;
16420
16478
  const { selector } = usePopperContainerId();
16421
16479
  const ns = useNamespace("tooltip");
16422
- const contentRef = ref(null);
16480
+ const contentRef = ref();
16423
16481
  let stopHandle;
16424
16482
  const {
16425
16483
  controlled,
@@ -16455,9 +16513,11 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
16455
16513
  var _a;
16456
16514
  return (_a = props.style) != null ? _a : {};
16457
16515
  });
16458
- const ariaHidden = computed(() => !unref(open));
16516
+ const ariaHidden = ref(true);
16459
16517
  const onTransitionLeave = () => {
16460
16518
  onHide();
16519
+ isFocusInsideContent() && tryFocus(document.body);
16520
+ ariaHidden.value = true;
16461
16521
  };
16462
16522
  const stopWhenControlled = () => {
16463
16523
  if (unref(controlled))
@@ -16500,9 +16560,17 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
16500
16560
  onClose();
16501
16561
  }
16502
16562
  };
16563
+ const isFocusInsideContent = (event) => {
16564
+ var _a;
16565
+ const popperContent = (_a = contentRef.value) == null ? void 0 : _a.popperContentRef;
16566
+ const activeElement = (event == null ? void 0 : event.relatedTarget) || document.activeElement;
16567
+ return popperContent == null ? void 0 : popperContent.contains(activeElement);
16568
+ };
16503
16569
  watch(() => unref(open), (val) => {
16504
16570
  if (!val) {
16505
16571
  stopHandle == null ? void 0 : stopHandle();
16572
+ } else {
16573
+ ariaHidden.value = false;
16506
16574
  }
16507
16575
  }, {
16508
16576
  flush: "post"
@@ -16512,7 +16580,8 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
16512
16580
  (_b = (_a = contentRef.value) == null ? void 0 : _a.updatePopper) == null ? void 0 : _b.call(_a);
16513
16581
  });
16514
16582
  expose({
16515
- contentRef
16583
+ contentRef,
16584
+ isFocusInsideContent
16516
16585
  });
16517
16586
  return (_ctx, _cache) => {
16518
16587
  return openBlock(), createBlock(unref(ElTeleport), {
@@ -16535,7 +16604,7 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
16535
16604
  ref: contentRef
16536
16605
  }, _ctx.$attrs, {
16537
16606
  "aria-label": _ctx.ariaLabel,
16538
- "aria-hidden": unref(ariaHidden),
16607
+ "aria-hidden": ariaHidden.value,
16539
16608
  "boundaries-padding": _ctx.boundariesPadding,
16540
16609
  "fallback-placements": _ctx.fallbackPlacements,
16541
16610
  "gpu-acceleration": _ctx.gpuAcceleration,
@@ -16573,13 +16642,13 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
16573
16642
  };
16574
16643
  }
16575
16644
  });
16576
- var ElTooltipContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$o, [["__file", "content.vue"]]);
16645
+ var ElTooltipContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$q, [["__file", "content.vue"]]);
16577
16646
 
16578
- const __default__$g = defineComponent({
16647
+ const __default__$i = defineComponent({
16579
16648
  name: "ElTooltip"
16580
16649
  });
16581
- const _sfc_main$n = /* @__PURE__ */ defineComponent({
16582
- ...__default__$g,
16650
+ const _sfc_main$p = /* @__PURE__ */ defineComponent({
16651
+ ...__default__$i,
16583
16652
  props: useTooltipProps,
16584
16653
  emits: tooltipEmits,
16585
16654
  setup(__props, { expose, emit }) {
@@ -16647,10 +16716,8 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
16647
16716
  }
16648
16717
  });
16649
16718
  const isFocusInsideContent = (event) => {
16650
- var _a, _b;
16651
- const popperContent = (_b = (_a = contentRef.value) == null ? void 0 : _a.contentRef) == null ? void 0 : _b.popperContentRef;
16652
- const activeElement = (event == null ? void 0 : event.relatedTarget) || document.activeElement;
16653
- return popperContent && popperContent.contains(activeElement);
16719
+ var _a;
16720
+ return (_a = contentRef.value) == null ? void 0 : _a.isFocusInsideContent(event);
16654
16721
  };
16655
16722
  onDeactivated(() => open.value && hide());
16656
16723
  expose({
@@ -16731,12 +16798,19 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
16731
16798
  };
16732
16799
  }
16733
16800
  });
16734
- var Tooltip$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$n, [["__file", "tooltip.vue"]]);
16801
+ var Tooltip$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$p, [["__file", "tooltip.vue"]]);
16735
16802
 
16736
16803
  const ElTooltip = withInstall(Tooltip$1);
16737
16804
 
16738
16805
  const buttonGroupContextKey = Symbol("buttonGroupContextKey");
16739
16806
 
16807
+ const useDeprecated = ({ from, replacement, scope, version, ref, type = "API" }, condition) => {
16808
+ watch(() => unref(condition), (val) => {
16809
+ }, {
16810
+ immediate: true
16811
+ });
16812
+ };
16813
+
16740
16814
  const useButton = (props, emit) => {
16741
16815
  useDeprecated({
16742
16816
  from: "type.text",
@@ -17798,11 +17872,11 @@ function useButtonCustomStyle(props) {
17798
17872
  });
17799
17873
  }
17800
17874
 
17801
- const __default__$f = defineComponent({
17875
+ const __default__$h = defineComponent({
17802
17876
  name: "ElButton"
17803
17877
  });
17804
- const _sfc_main$m = /* @__PURE__ */ defineComponent({
17805
- ...__default__$f,
17878
+ const _sfc_main$o = /* @__PURE__ */ defineComponent({
17879
+ ...__default__$h,
17806
17880
  props: buttonProps,
17807
17881
  emits: buttonEmits,
17808
17882
  setup(__props, { expose, emit }) {
@@ -17868,18 +17942,18 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
17868
17942
  };
17869
17943
  }
17870
17944
  });
17871
- var Button = /* @__PURE__ */ _export_sfc$1(_sfc_main$m, [["__file", "button.vue"]]);
17945
+ var Button = /* @__PURE__ */ _export_sfc$1(_sfc_main$o, [["__file", "button.vue"]]);
17872
17946
 
17873
17947
  const buttonGroupProps = {
17874
17948
  size: buttonProps.size,
17875
17949
  type: buttonProps.type
17876
17950
  };
17877
17951
 
17878
- const __default__$e = defineComponent({
17952
+ const __default__$g = defineComponent({
17879
17953
  name: "ElButtonGroup"
17880
17954
  });
17881
- const _sfc_main$l = /* @__PURE__ */ defineComponent({
17882
- ...__default__$e,
17955
+ const _sfc_main$n = /* @__PURE__ */ defineComponent({
17956
+ ...__default__$g,
17883
17957
  props: buttonGroupProps,
17884
17958
  setup(__props) {
17885
17959
  const props = __props;
@@ -17897,7 +17971,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
17897
17971
  };
17898
17972
  }
17899
17973
  });
17900
- var ButtonGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$l, [["__file", "button-group.vue"]]);
17974
+ var ButtonGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$n, [["__file", "button-group.vue"]]);
17901
17975
 
17902
17976
  const ElButton = withInstall(Button, {
17903
17977
  ButtonGroup
@@ -17906,110 +17980,7 @@ withNoopInstall(ButtonGroup);
17906
17980
 
17907
17981
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
17908
17982
 
17909
- const nodeList$1 = /* @__PURE__ */ new Map();
17910
- if (isClient) {
17911
- let startClick;
17912
- document.addEventListener("mousedown", (e) => startClick = e);
17913
- document.addEventListener("mouseup", (e) => {
17914
- if (startClick) {
17915
- for (const handlers of nodeList$1.values()) {
17916
- for (const { documentHandler } of handlers) {
17917
- documentHandler(e, startClick);
17918
- }
17919
- }
17920
- startClick = void 0;
17921
- }
17922
- });
17923
- }
17924
- function createDocumentHandler$1(el, binding) {
17925
- let excludes = [];
17926
- if (Array.isArray(binding.arg)) {
17927
- excludes = binding.arg;
17928
- } else if (isElement(binding.arg)) {
17929
- excludes.push(binding.arg);
17930
- }
17931
- return function(mouseup, mousedown) {
17932
- const popperRef = binding.instance.popperRef;
17933
- const mouseUpTarget = mouseup.target;
17934
- const mouseDownTarget = mousedown == null ? void 0 : mousedown.target;
17935
- const isBound = !binding || !binding.instance;
17936
- const isTargetExists = !mouseUpTarget || !mouseDownTarget;
17937
- const isContainedByEl = el.contains(mouseUpTarget) || el.contains(mouseDownTarget);
17938
- const isSelf = el === mouseUpTarget;
17939
- const isTargetExcluded = excludes.length && excludes.some((item) => item == null ? void 0 : item.contains(mouseUpTarget)) || excludes.length && excludes.includes(mouseDownTarget);
17940
- const isContainedByPopper = popperRef && (popperRef.contains(mouseUpTarget) || popperRef.contains(mouseDownTarget));
17941
- if (isBound || isTargetExists || isContainedByEl || isSelf || isTargetExcluded || isContainedByPopper) {
17942
- return;
17943
- }
17944
- binding.value(mouseup, mousedown);
17945
- };
17946
- }
17947
- const ClickOutside = {
17948
- beforeMount(el, binding) {
17949
- if (!nodeList$1.has(el)) {
17950
- nodeList$1.set(el, []);
17951
- }
17952
- nodeList$1.get(el).push({
17953
- documentHandler: createDocumentHandler$1(el, binding),
17954
- bindingFn: binding.value
17955
- });
17956
- },
17957
- updated(el, binding) {
17958
- if (!nodeList$1.has(el)) {
17959
- nodeList$1.set(el, []);
17960
- }
17961
- const handlers = nodeList$1.get(el);
17962
- const oldHandlerIndex = handlers.findIndex((item) => item.bindingFn === binding.oldValue);
17963
- const newHandler = {
17964
- documentHandler: createDocumentHandler$1(el, binding),
17965
- bindingFn: binding.value
17966
- };
17967
- if (oldHandlerIndex >= 0) {
17968
- handlers.splice(oldHandlerIndex, 1, newHandler);
17969
- } else {
17970
- handlers.push(newHandler);
17971
- }
17972
- },
17973
- unmounted(el) {
17974
- nodeList$1.delete(el);
17975
- }
17976
- };
17977
-
17978
- const REPEAT_INTERVAL = 100;
17979
- const REPEAT_DELAY = 600;
17980
- const vRepeatClick = {
17981
- beforeMount(el, binding) {
17982
- const value = binding.value;
17983
- const { interval = REPEAT_INTERVAL, delay = REPEAT_DELAY } = isFunction$1(value) ? {} : value;
17984
- let intervalId;
17985
- let delayId;
17986
- const handler = () => isFunction$1(value) ? value() : value.handler();
17987
- const clear = () => {
17988
- if (delayId) {
17989
- clearTimeout(delayId);
17990
- delayId = void 0;
17991
- }
17992
- if (intervalId) {
17993
- clearInterval(intervalId);
17994
- intervalId = void 0;
17995
- }
17996
- };
17997
- el.addEventListener("mousedown", (evt) => {
17998
- if (evt.button !== 0)
17999
- return;
18000
- clear();
18001
- handler();
18002
- document.addEventListener("mouseup", () => clear(), {
18003
- once: true
18004
- });
18005
- delayId = setTimeout(() => {
18006
- intervalId = setInterval(() => {
18007
- handler();
18008
- }, interval);
18009
- }, delay);
18010
- });
18011
- }
18012
- };
17983
+ const escapeStringRegexp = (string = "") => string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
18013
17984
 
18014
17985
  const tagProps = buildProps({
18015
17986
  type: {
@@ -18037,11 +18008,11 @@ const tagEmits = {
18037
18008
  click: (evt) => evt instanceof MouseEvent
18038
18009
  };
18039
18010
 
18040
- const __default__$d = defineComponent({
18011
+ const __default__$f = defineComponent({
18041
18012
  name: "ElTag"
18042
18013
  });
18043
- const _sfc_main$k = /* @__PURE__ */ defineComponent({
18044
- ...__default__$d,
18014
+ const _sfc_main$m = /* @__PURE__ */ defineComponent({
18015
+ ...__default__$f,
18045
18016
  props: tagProps,
18046
18017
  emits: tagEmits,
18047
18018
  setup(__props, { emit }) {
@@ -18067,7 +18038,10 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
18067
18038
  emit("click", event);
18068
18039
  };
18069
18040
  const handleVNodeMounted = (vnode) => {
18070
- vnode.component.subTree.component.bum = null;
18041
+ var _a, _b, _c;
18042
+ if ((_c = (_b = (_a = vnode == null ? void 0 : vnode.component) == null ? void 0 : _a.subTree) == null ? void 0 : _b.component) == null ? void 0 : _c.bum) {
18043
+ vnode.component.subTree.component.bum = null;
18044
+ }
18071
18045
  };
18072
18046
  return (_ctx, _cache) => {
18073
18047
  return _ctx.disableTransitions ? (openBlock(), createElementBlock("span", {
@@ -18125,26 +18099,131 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
18125
18099
  };
18126
18100
  }
18127
18101
  });
18128
- var Tag = /* @__PURE__ */ _export_sfc$1(_sfc_main$k, [["__file", "tag.vue"]]);
18102
+ var Tag = /* @__PURE__ */ _export_sfc$1(_sfc_main$m, [["__file", "tag.vue"]]);
18129
18103
 
18130
18104
  const ElTag = withInstall(Tag);
18131
18105
 
18132
- const _sfc_main$j = /* @__PURE__ */ defineComponent({
18106
+ const nodeList$1 = /* @__PURE__ */ new Map();
18107
+ if (isClient) {
18108
+ let startClick;
18109
+ document.addEventListener("mousedown", (e) => startClick = e);
18110
+ document.addEventListener("mouseup", (e) => {
18111
+ if (startClick) {
18112
+ for (const handlers of nodeList$1.values()) {
18113
+ for (const { documentHandler } of handlers) {
18114
+ documentHandler(e, startClick);
18115
+ }
18116
+ }
18117
+ startClick = void 0;
18118
+ }
18119
+ });
18120
+ }
18121
+ function createDocumentHandler$1(el, binding) {
18122
+ let excludes = [];
18123
+ if (isArray$1(binding.arg)) {
18124
+ excludes = binding.arg;
18125
+ } else if (isElement(binding.arg)) {
18126
+ excludes.push(binding.arg);
18127
+ }
18128
+ return function(mouseup, mousedown) {
18129
+ const popperRef = binding.instance.popperRef;
18130
+ const mouseUpTarget = mouseup.target;
18131
+ const mouseDownTarget = mousedown == null ? void 0 : mousedown.target;
18132
+ const isBound = !binding || !binding.instance;
18133
+ const isTargetExists = !mouseUpTarget || !mouseDownTarget;
18134
+ const isContainedByEl = el.contains(mouseUpTarget) || el.contains(mouseDownTarget);
18135
+ const isSelf = el === mouseUpTarget;
18136
+ const isTargetExcluded = excludes.length && excludes.some((item) => item == null ? void 0 : item.contains(mouseUpTarget)) || excludes.length && excludes.includes(mouseDownTarget);
18137
+ const isContainedByPopper = popperRef && (popperRef.contains(mouseUpTarget) || popperRef.contains(mouseDownTarget));
18138
+ if (isBound || isTargetExists || isContainedByEl || isSelf || isTargetExcluded || isContainedByPopper) {
18139
+ return;
18140
+ }
18141
+ binding.value(mouseup, mousedown);
18142
+ };
18143
+ }
18144
+ const ClickOutside = {
18145
+ beforeMount(el, binding) {
18146
+ if (!nodeList$1.has(el)) {
18147
+ nodeList$1.set(el, []);
18148
+ }
18149
+ nodeList$1.get(el).push({
18150
+ documentHandler: createDocumentHandler$1(el, binding),
18151
+ bindingFn: binding.value
18152
+ });
18153
+ },
18154
+ updated(el, binding) {
18155
+ if (!nodeList$1.has(el)) {
18156
+ nodeList$1.set(el, []);
18157
+ }
18158
+ const handlers = nodeList$1.get(el);
18159
+ const oldHandlerIndex = handlers.findIndex((item) => item.bindingFn === binding.oldValue);
18160
+ const newHandler = {
18161
+ documentHandler: createDocumentHandler$1(el, binding),
18162
+ bindingFn: binding.value
18163
+ };
18164
+ if (oldHandlerIndex >= 0) {
18165
+ handlers.splice(oldHandlerIndex, 1, newHandler);
18166
+ } else {
18167
+ handlers.push(newHandler);
18168
+ }
18169
+ },
18170
+ unmounted(el) {
18171
+ nodeList$1.delete(el);
18172
+ }
18173
+ };
18174
+
18175
+ const REPEAT_INTERVAL = 100;
18176
+ const REPEAT_DELAY = 600;
18177
+ const vRepeatClick = {
18178
+ beforeMount(el, binding) {
18179
+ const value = binding.value;
18180
+ const { interval = REPEAT_INTERVAL, delay = REPEAT_DELAY } = isFunction$1(value) ? {} : value;
18181
+ let intervalId;
18182
+ let delayId;
18183
+ const handler = () => isFunction$1(value) ? value() : value.handler();
18184
+ const clear = () => {
18185
+ if (delayId) {
18186
+ clearTimeout(delayId);
18187
+ delayId = void 0;
18188
+ }
18189
+ if (intervalId) {
18190
+ clearInterval(intervalId);
18191
+ intervalId = void 0;
18192
+ }
18193
+ };
18194
+ el.addEventListener("mousedown", (evt) => {
18195
+ if (evt.button !== 0)
18196
+ return;
18197
+ clear();
18198
+ handler();
18199
+ document.addEventListener("mouseup", () => clear(), {
18200
+ once: true
18201
+ });
18202
+ delayId = setTimeout(() => {
18203
+ intervalId = setInterval(() => {
18204
+ handler();
18205
+ }, interval);
18206
+ }, delay);
18207
+ });
18208
+ }
18209
+ };
18210
+
18211
+ const _sfc_main$l = /* @__PURE__ */ defineComponent({
18133
18212
  inheritAttrs: false
18134
18213
  });
18135
18214
  function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
18136
18215
  return renderSlot(_ctx.$slots, "default");
18137
18216
  }
18138
- var Collection = /* @__PURE__ */ _export_sfc$1(_sfc_main$j, [["render", _sfc_render$5], ["__file", "collection.vue"]]);
18217
+ var Collection = /* @__PURE__ */ _export_sfc$1(_sfc_main$l, [["render", _sfc_render$5], ["__file", "collection.vue"]]);
18139
18218
 
18140
- const _sfc_main$i = /* @__PURE__ */ defineComponent({
18219
+ const _sfc_main$k = /* @__PURE__ */ defineComponent({
18141
18220
  name: "ElCollectionItem",
18142
18221
  inheritAttrs: false
18143
18222
  });
18144
18223
  function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
18145
18224
  return renderSlot(_ctx.$slots, "default");
18146
18225
  }
18147
- var CollectionItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$i, [["render", _sfc_render$4], ["__file", "collection-item.vue"]]);
18226
+ var CollectionItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$k, [["render", _sfc_render$4], ["__file", "collection-item.vue"]]);
18148
18227
 
18149
18228
  const COLLECTION_ITEM_SIGN = `data-el-collection-item`;
18150
18229
  const createCollectionWithScope = (name) => {
@@ -18207,6 +18286,15 @@ const createCollectionWithScope = (name) => {
18207
18286
 
18208
18287
  const dropdownProps = buildProps({
18209
18288
  trigger: useTooltipTriggerProps.trigger,
18289
+ triggerKeys: {
18290
+ type: definePropType(Array),
18291
+ default: () => [
18292
+ EVENT_CODE.enter,
18293
+ EVENT_CODE.numpadEnter,
18294
+ EVENT_CODE.space,
18295
+ EVENT_CODE.down
18296
+ ]
18297
+ },
18210
18298
  effect: {
18211
18299
  ...useTooltipContentProps.effect,
18212
18300
  default: "light"
@@ -18345,11 +18433,11 @@ const inputNumberEmits = {
18345
18433
  [UPDATE_MODEL_EVENT]: (val) => isNumber(val) || isNil(val)
18346
18434
  };
18347
18435
 
18348
- const __default__$c = defineComponent({
18436
+ const __default__$e = defineComponent({
18349
18437
  name: "ElInputNumber"
18350
18438
  });
18351
- const _sfc_main$h = /* @__PURE__ */ defineComponent({
18352
- ...__default__$c,
18439
+ const _sfc_main$j = /* @__PURE__ */ defineComponent({
18440
+ ...__default__$e,
18353
18441
  props: inputNumberProps,
18354
18442
  emits: inputNumberEmits,
18355
18443
  setup(__props, { expose, emit }) {
@@ -18464,6 +18552,9 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
18464
18552
  }
18465
18553
  if (stepStrictly) {
18466
18554
  newVal = toPrecision(Math.round(newVal / step) * step, precision);
18555
+ if (newVal !== value) {
18556
+ update && emit(UPDATE_MODEL_EVENT, newVal);
18557
+ }
18467
18558
  }
18468
18559
  if (!isUndefined(precision)) {
18469
18560
  newVal = toPrecision(newVal, precision);
@@ -18520,11 +18611,14 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
18520
18611
  emit("focus", event);
18521
18612
  };
18522
18613
  const handleBlur = (event) => {
18523
- var _a;
18614
+ var _a, _b;
18524
18615
  data.userInput = null;
18616
+ if (isFirefox() && data.currentValue === null && ((_a = input.value) == null ? void 0 : _a.input)) {
18617
+ input.value.input.value = "";
18618
+ }
18525
18619
  emit("blur", event);
18526
18620
  if (props.validateEvent) {
18527
- (_a = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a.call(formItem, "blur").catch((err) => debugWarn());
18621
+ (_b = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _b.call(formItem, "blur").catch((err) => debugWarn());
18528
18622
  }
18529
18623
  };
18530
18624
  const setCurrentValueToModelValue = () => {
@@ -18649,15 +18743,121 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
18649
18743
  onFocus: handleFocus,
18650
18744
  onInput: handleInput,
18651
18745
  onChange: handleInputChange
18652
- }, null, 8, ["id", "step", "model-value", "placeholder", "readonly", "disabled", "size", "max", "min", "name", "aria-label", "onKeydown"])
18746
+ }, createSlots({
18747
+ _: 2
18748
+ }, [
18749
+ _ctx.$slots.prefix ? {
18750
+ name: "prefix",
18751
+ fn: withCtx(() => [
18752
+ renderSlot(_ctx.$slots, "prefix")
18753
+ ])
18754
+ } : void 0,
18755
+ _ctx.$slots.suffix ? {
18756
+ name: "suffix",
18757
+ fn: withCtx(() => [
18758
+ renderSlot(_ctx.$slots, "suffix")
18759
+ ])
18760
+ } : void 0
18761
+ ]), 1032, ["id", "step", "model-value", "placeholder", "readonly", "disabled", "size", "max", "min", "name", "aria-label", "onKeydown"])
18653
18762
  ], 42, ["onDragstart"]);
18654
18763
  };
18655
18764
  }
18656
18765
  });
18657
- var InputNumber = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["__file", "input-number.vue"]]);
18766
+ var InputNumber = /* @__PURE__ */ _export_sfc$1(_sfc_main$j, [["__file", "input-number.vue"]]);
18658
18767
 
18659
18768
  const ElInputNumber = withInstall(InputNumber);
18660
18769
 
18770
+ function useCalcInputWidth() {
18771
+ const calculatorRef = shallowRef();
18772
+ const calculatorWidth = ref(0);
18773
+ const MINIMUM_INPUT_WIDTH = 11;
18774
+ const inputStyle = computed(() => ({
18775
+ minWidth: `${Math.max(calculatorWidth.value, MINIMUM_INPUT_WIDTH)}px`
18776
+ }));
18777
+ const resetCalculatorWidth = () => {
18778
+ var _a, _b;
18779
+ calculatorWidth.value = (_b = (_a = calculatorRef.value) == null ? void 0 : _a.getBoundingClientRect().width) != null ? _b : 0;
18780
+ };
18781
+ useResizeObserver(calculatorRef, resetCalculatorWidth);
18782
+ return {
18783
+ calculatorRef,
18784
+ calculatorWidth,
18785
+ inputStyle
18786
+ };
18787
+ }
18788
+
18789
+ const linkProps = buildProps({
18790
+ type: {
18791
+ type: String,
18792
+ values: ["primary", "success", "warning", "info", "danger", "default"],
18793
+ default: "default"
18794
+ },
18795
+ underline: {
18796
+ type: Boolean,
18797
+ default: true
18798
+ },
18799
+ disabled: Boolean,
18800
+ href: { type: String, default: "" },
18801
+ target: {
18802
+ type: String,
18803
+ default: "_self"
18804
+ },
18805
+ icon: {
18806
+ type: iconPropType
18807
+ }
18808
+ });
18809
+ const linkEmits = {
18810
+ click: (evt) => evt instanceof MouseEvent
18811
+ };
18812
+
18813
+ const __default__$d = defineComponent({
18814
+ name: "ElLink"
18815
+ });
18816
+ const _sfc_main$i = /* @__PURE__ */ defineComponent({
18817
+ ...__default__$d,
18818
+ props: linkProps,
18819
+ emits: linkEmits,
18820
+ setup(__props, { emit }) {
18821
+ const props = __props;
18822
+ const ns = useNamespace("link");
18823
+ const linkKls = computed(() => [
18824
+ ns.b(),
18825
+ ns.m(props.type),
18826
+ ns.is("disabled", props.disabled),
18827
+ ns.is("underline", props.underline && !props.disabled)
18828
+ ]);
18829
+ function handleClick(event) {
18830
+ if (!props.disabled)
18831
+ emit("click", event);
18832
+ }
18833
+ return (_ctx, _cache) => {
18834
+ return openBlock(), createElementBlock("a", {
18835
+ class: normalizeClass(unref(linkKls)),
18836
+ href: _ctx.disabled || !_ctx.href ? void 0 : _ctx.href,
18837
+ target: _ctx.disabled || !_ctx.href ? void 0 : _ctx.target,
18838
+ onClick: handleClick
18839
+ }, [
18840
+ _ctx.icon ? (openBlock(), createBlock(unref(ElIcon), { key: 0 }, {
18841
+ default: withCtx(() => [
18842
+ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon)))
18843
+ ]),
18844
+ _: 1
18845
+ })) : createCommentVNode("v-if", true),
18846
+ _ctx.$slots.default ? (openBlock(), createElementBlock("span", {
18847
+ key: 1,
18848
+ class: normalizeClass(unref(ns).e("inner"))
18849
+ }, [
18850
+ renderSlot(_ctx.$slots, "default")
18851
+ ], 2)) : createCommentVNode("v-if", true),
18852
+ _ctx.$slots.icon ? renderSlot(_ctx.$slots, "icon", { key: 2 }) : createCommentVNode("v-if", true)
18853
+ ], 10, ["href", "target"]);
18854
+ };
18855
+ }
18856
+ });
18857
+ var Link = /* @__PURE__ */ _export_sfc$1(_sfc_main$i, [["__file", "link.vue"]]);
18858
+
18859
+ const ElLink = withInstall(Link);
18860
+
18661
18861
  const selectGroupKey = Symbol("ElSelectGroup");
18662
18862
  const selectKey = Symbol("ElSelect");
18663
18863
 
@@ -18736,7 +18936,7 @@ function useOption(props, states) {
18736
18936
  };
18737
18937
  }
18738
18938
 
18739
- const _sfc_main$g = defineComponent({
18939
+ const _sfc_main$h = defineComponent({
18740
18940
  name: "ElOption",
18741
18941
  componentName: "ElOption",
18742
18942
  props: {
@@ -18776,8 +18976,7 @@ const _sfc_main$g = defineComponent({
18776
18976
  select.onOptionCreate(vm);
18777
18977
  onBeforeUnmount(() => {
18778
18978
  const key = vm.value;
18779
- const { selected } = select.states;
18780
- const selectedOptions = select.props.multiple ? selected : [selected];
18979
+ const { selected: selectedOptions } = select.states;
18781
18980
  const doesSelected = selectedOptions.some((item) => {
18782
18981
  return item.value === vm.value;
18783
18982
  });
@@ -18817,19 +19016,19 @@ function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
18817
19016
  role: "option",
18818
19017
  "aria-disabled": _ctx.isDisabled || void 0,
18819
19018
  "aria-selected": _ctx.itemSelected,
18820
- onMouseenter: _ctx.hoverItem,
19019
+ onMousemove: _ctx.hoverItem,
18821
19020
  onClick: withModifiers(_ctx.selectOptionClick, ["stop"])
18822
19021
  }, [
18823
19022
  renderSlot(_ctx.$slots, "default", {}, () => [
18824
19023
  createElementVNode("span", null, toDisplayString(_ctx.currentLabel), 1)
18825
19024
  ])
18826
- ], 42, ["id", "aria-disabled", "aria-selected", "onMouseenter", "onClick"])), [
19025
+ ], 42, ["id", "aria-disabled", "aria-selected", "onMousemove", "onClick"])), [
18827
19026
  [vShow, _ctx.visible]
18828
19027
  ]);
18829
19028
  }
18830
- var Option = /* @__PURE__ */ _export_sfc$1(_sfc_main$g, [["render", _sfc_render$3], ["__file", "option.vue"]]);
19029
+ var Option = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["render", _sfc_render$3], ["__file", "option.vue"]]);
18831
19030
 
18832
- const _sfc_main$f = defineComponent({
19031
+ const _sfc_main$g = defineComponent({
18833
19032
  name: "ElSelectDropdown",
18834
19033
  componentName: "ElSelectDropdown",
18835
19034
  setup() {
@@ -18876,9 +19075,8 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
18876
19075
  ], 2)) : createCommentVNode("v-if", true)
18877
19076
  ], 6);
18878
19077
  }
18879
- var ElSelectMenu = /* @__PURE__ */ _export_sfc$1(_sfc_main$f, [["render", _sfc_render$2], ["__file", "select-dropdown.vue"]]);
19078
+ var ElSelectMenu = /* @__PURE__ */ _export_sfc$1(_sfc_main$g, [["render", _sfc_render$2], ["__file", "select-dropdown.vue"]]);
18880
19079
 
18881
- const MINIMUM_INPUT_WIDTH = 11;
18882
19080
  const useSelect = (props, emit) => {
18883
19081
  const { t } = useLocale();
18884
19082
  const contentId = useId();
@@ -18888,11 +19086,9 @@ const useSelect = (props, emit) => {
18888
19086
  inputValue: "",
18889
19087
  options: /* @__PURE__ */ new Map(),
18890
19088
  cachedOptions: /* @__PURE__ */ new Map(),
18891
- disabledOptions: /* @__PURE__ */ new Map(),
18892
19089
  optionValues: [],
18893
19090
  selected: [],
18894
19091
  selectionWidth: 0,
18895
- calculatorWidth: 0,
18896
19092
  collapseItemWidth: 0,
18897
19093
  selectedLabel: "",
18898
19094
  hoveringIndex: -1,
@@ -18906,7 +19102,6 @@ const useSelect = (props, emit) => {
18906
19102
  const tooltipRef = ref(null);
18907
19103
  const tagTooltipRef = ref(null);
18908
19104
  const inputRef = ref(null);
18909
- const calculatorRef = ref(null);
18910
19105
  const prefixRef = ref(null);
18911
19106
  const suffixRef = ref(null);
18912
19107
  const menuRef = ref(null);
@@ -18921,7 +19116,7 @@ const useSelect = (props, emit) => {
18921
19116
  } = useComposition({
18922
19117
  afterComposition: (e) => onInput(e)
18923
19118
  });
18924
- const { wrapperRef, isFocused } = useFocusController(inputRef, {
19119
+ const { wrapperRef, isFocused, handleBlur } = useFocusController(inputRef, {
18925
19120
  beforeFocus() {
18926
19121
  return selectDisabled.value;
18927
19122
  },
@@ -18951,6 +19146,10 @@ const useSelect = (props, emit) => {
18951
19146
  const hasModelValue = computed(() => {
18952
19147
  return isArray$1(props.modelValue) ? props.modelValue.length > 0 : !isEmptyValue(props.modelValue);
18953
19148
  });
19149
+ const needStatusIcon = computed(() => {
19150
+ var _a;
19151
+ return (_a = form == null ? void 0 : form.statusIcon) != null ? _a : false;
19152
+ });
18954
19153
  const showClose = computed(() => {
18955
19154
  return props.clearable && !selectDisabled.value && states.inputHovering && hasModelValue.value;
18956
19155
  });
@@ -18959,12 +19158,11 @@ const useSelect = (props, emit) => {
18959
19158
  const validateState = computed(() => (formItem == null ? void 0 : formItem.validateState) || "");
18960
19159
  const validateIcon = computed(() => ValidateComponentsMap[validateState.value]);
18961
19160
  const debounce$1 = computed(() => props.remote ? 300 : 0);
19161
+ const isRemoteSearchEmpty = computed(() => props.remote && !states.inputValue && states.options.size === 0);
18962
19162
  const emptyText = computed(() => {
18963
19163
  if (props.loading) {
18964
19164
  return props.loadingText || t("el.select.loading");
18965
19165
  } else {
18966
- if (props.remote && !states.inputValue && states.options.size === 0)
18967
- return false;
18968
19166
  if (props.filterable && states.inputValue && states.options.size > 0 && filteredOptionsCount.value === 0) {
18969
19167
  return props.noMatchText || t("el.select.noMatch");
18970
19168
  }
@@ -19009,7 +19207,7 @@ const useSelect = (props, emit) => {
19009
19207
  const collapseTagSize = computed(() => ["small"].includes(selectSize.value) ? "small" : "default");
19010
19208
  const dropdownMenuVisible = computed({
19011
19209
  get() {
19012
- return expanded.value && emptyText.value !== false;
19210
+ return expanded.value && !isRemoteSearchEmpty.value;
19013
19211
  },
19014
19212
  set(val) {
19015
19213
  expanded.value = val;
@@ -19054,13 +19252,9 @@ const useSelect = (props, emit) => {
19054
19252
  emit("visible-change", val);
19055
19253
  });
19056
19254
  watch(() => states.options.entries(), () => {
19057
- var _a;
19058
19255
  if (!isClient)
19059
19256
  return;
19060
- const inputs = ((_a = selectRef.value) == null ? void 0 : _a.querySelectorAll("input")) || [];
19061
- if (!props.filterable && !props.defaultFirstOption && !isUndefined(props.modelValue) || !Array.from(inputs).includes(document.activeElement)) {
19062
- setSelected();
19063
- }
19257
+ setSelected();
19064
19258
  if (props.defaultFirstOption && (props.filterable || props.remote) && filteredOptionsCount.value) {
19065
19259
  checkDefaultFirstOption();
19066
19260
  }
@@ -19102,7 +19296,8 @@ const useSelect = (props, emit) => {
19102
19296
  const optionsInDropdown = optionsArray.value.filter((n) => n.visible && !n.disabled && !n.states.groupDisabled);
19103
19297
  const userCreatedOption = optionsInDropdown.find((n) => n.created);
19104
19298
  const firstOriginOption = optionsInDropdown[0];
19105
- states.hoveringIndex = getValueIndex(optionsArray.value, userCreatedOption || firstOriginOption);
19299
+ const valueList = optionsArray.value.map((item) => item.value);
19300
+ states.hoveringIndex = getValueIndex(valueList, userCreatedOption || firstOriginOption);
19106
19301
  };
19107
19302
  const setSelected = () => {
19108
19303
  if (!props.multiple) {
@@ -19124,9 +19319,7 @@ const useSelect = (props, emit) => {
19124
19319
  };
19125
19320
  const getOption = (value) => {
19126
19321
  let option;
19127
- const isObjectValue = toRawType(value).toLowerCase() === "object";
19128
- const isNull = toRawType(value).toLowerCase() === "null";
19129
- const isUndefined2 = toRawType(value).toLowerCase() === "undefined";
19322
+ const isObjectValue = isPlainObject$1(value);
19130
19323
  for (let i = states.cachedOptions.size - 1; i >= 0; i--) {
19131
19324
  const cachedOption = cachedOptionsArray.value[i];
19132
19325
  const isEqualValue = isObjectValue ? get(cachedOption.value, props.valueKey) === get(value, props.valueKey) : cachedOption.value === value;
@@ -19143,7 +19336,7 @@ const useSelect = (props, emit) => {
19143
19336
  }
19144
19337
  if (option)
19145
19338
  return option;
19146
- const label = isObjectValue ? value.label : !isNull && !isUndefined2 ? value : "";
19339
+ const label = isObjectValue ? value.label : value != null ? value : "";
19147
19340
  const newOption = {
19148
19341
  value,
19149
19342
  currentLabel: label
@@ -19156,9 +19349,6 @@ const useSelect = (props, emit) => {
19156
19349
  const resetSelectionWidth = () => {
19157
19350
  states.selectionWidth = selectionRef.value.getBoundingClientRect().width;
19158
19351
  };
19159
- const resetCalculatorWidth = () => {
19160
- states.calculatorWidth = calculatorRef.value.getBoundingClientRect().width;
19161
- };
19162
19352
  const resetCollapseItemWidth = () => {
19163
19353
  states.collapseItemWidth = collapseItemRef.value.getBoundingClientRect().width;
19164
19354
  };
@@ -19192,7 +19382,10 @@ const useSelect = (props, emit) => {
19192
19382
  emit(CHANGE_EVENT, val);
19193
19383
  }
19194
19384
  };
19195
- const getLastNotDisabledIndex = (value) => findLastIndex(value, (it) => !states.disabledOptions.has(it));
19385
+ const getLastNotDisabledIndex = (value) => findLastIndex(value, (it) => {
19386
+ const option = states.cachedOptions.get(it);
19387
+ return option && !option.disabled && !option.states.groupDisabled;
19388
+ });
19196
19389
  const deletePrevTag = (e) => {
19197
19390
  if (!props.multiple)
19198
19391
  return;
@@ -19242,7 +19435,7 @@ const useSelect = (props, emit) => {
19242
19435
  var _a;
19243
19436
  if (props.multiple) {
19244
19437
  const value = castArray((_a = props.modelValue) != null ? _a : []).slice();
19245
- const optionIndex = getValueIndex(value, option.value);
19438
+ const optionIndex = getValueIndex(value, option);
19246
19439
  if (optionIndex > -1) {
19247
19440
  value.splice(optionIndex, 1);
19248
19441
  } else if (props.multipleLimit <= 0 || value.length < props.multipleLimit) {
@@ -19268,19 +19461,14 @@ const useSelect = (props, emit) => {
19268
19461
  scrollToOption(option);
19269
19462
  });
19270
19463
  };
19271
- const getValueIndex = (arr = [], value) => {
19272
- if (!isObject$1(value))
19273
- return arr.indexOf(value);
19274
- const valueKey = props.valueKey;
19275
- let index = -1;
19276
- arr.some((item, i) => {
19277
- if (toRaw(get(item, valueKey)) === get(value, valueKey)) {
19278
- index = i;
19279
- return true;
19280
- }
19281
- return false;
19464
+ const getValueIndex = (arr = [], option) => {
19465
+ if (isUndefined(option))
19466
+ return -1;
19467
+ if (!isObject$1(option.value))
19468
+ return arr.indexOf(option.value);
19469
+ return arr.findIndex((item) => {
19470
+ return isEqual(get(item, props.valueKey), getValueKey(option));
19282
19471
  });
19283
- return index;
19284
19472
  };
19285
19473
  const scrollToOption = (option) => {
19286
19474
  var _a, _b, _c, _d, _e;
@@ -19303,7 +19491,6 @@ const useSelect = (props, emit) => {
19303
19491
  const onOptionCreate = (vm) => {
19304
19492
  states.options.set(vm.value, vm);
19305
19493
  states.cachedOptions.set(vm.value, vm);
19306
- vm.disabled && states.disabledOptions.set(vm.value, vm);
19307
19494
  };
19308
19495
  const onOptionDestroy = (key, vm) => {
19309
19496
  if (states.options.get(key) === vm) {
@@ -19324,14 +19511,25 @@ const useSelect = (props, emit) => {
19324
19511
  };
19325
19512
  const blur = () => {
19326
19513
  var _a;
19514
+ if (expanded.value) {
19515
+ expanded.value = false;
19516
+ nextTick(() => {
19517
+ var _a2;
19518
+ return (_a2 = inputRef.value) == null ? void 0 : _a2.blur();
19519
+ });
19520
+ return;
19521
+ }
19327
19522
  (_a = inputRef.value) == null ? void 0 : _a.blur();
19328
19523
  };
19329
19524
  const handleClearClick = (event) => {
19330
19525
  deleteSelected(event);
19331
19526
  };
19332
- const handleClickOutside = () => {
19527
+ const handleClickOutside = (event) => {
19333
19528
  expanded.value = false;
19334
- isFocused.value && blur();
19529
+ if (isFocused.value) {
19530
+ const _event = new FocusEvent("focus", event);
19531
+ nextTick(() => handleBlur(_event));
19532
+ }
19335
19533
  };
19336
19534
  const handleEsc = () => {
19337
19535
  if (states.inputValue.length > 0) {
@@ -19355,15 +19553,16 @@ const useSelect = (props, emit) => {
19355
19553
  if (!expanded.value) {
19356
19554
  toggleMenu();
19357
19555
  } else {
19358
- if (optionsArray.value[states.hoveringIndex]) {
19359
- handleOptionSelect(optionsArray.value[states.hoveringIndex]);
19556
+ const option = optionsArray.value[states.hoveringIndex];
19557
+ if (option && !option.isDisabled) {
19558
+ handleOptionSelect(option);
19360
19559
  }
19361
19560
  }
19362
19561
  };
19363
19562
  const getValueKey = (item) => {
19364
19563
  return isObject$1(item.value) ? get(item.value, props.valueKey) : item.value;
19365
19564
  };
19366
- const optionsAllDisabled = computed(() => optionsArray.value.filter((option) => option.visible).every((option) => option.disabled));
19565
+ const optionsAllDisabled = computed(() => optionsArray.value.filter((option) => option.visible).every((option) => option.isDisabled));
19367
19566
  const showTagList = computed(() => {
19368
19567
  if (!props.multiple) {
19369
19568
  return [];
@@ -19381,7 +19580,7 @@ const useSelect = (props, emit) => {
19381
19580
  expanded.value = true;
19382
19581
  return;
19383
19582
  }
19384
- if (states.options.size === 0 || states.filteredOptionsCount === 0 || isComposing.value)
19583
+ if (states.options.size === 0 || filteredOptionsCount.value === 0 || isComposing.value)
19385
19584
  return;
19386
19585
  if (!optionsAllDisabled.value) {
19387
19586
  if (direction === "next") {
@@ -19396,7 +19595,7 @@ const useSelect = (props, emit) => {
19396
19595
  }
19397
19596
  }
19398
19597
  const option = optionsArray.value[states.hoveringIndex];
19399
- if (option.disabled === true || option.states.groupDisabled === true || !option.visible) {
19598
+ if (option.isDisabled || !option.visible) {
19400
19599
  navigateOptions(direction);
19401
19600
  }
19402
19601
  nextTick(() => scrollToOption(hoverOption.value));
@@ -19416,11 +19615,7 @@ const useSelect = (props, emit) => {
19416
19615
  const collapseTagStyle = computed(() => {
19417
19616
  return { maxWidth: `${states.selectionWidth}px` };
19418
19617
  });
19419
- const inputStyle = computed(() => ({
19420
- width: `${Math.max(states.calculatorWidth, MINIMUM_INPUT_WIDTH)}px`
19421
- }));
19422
19618
  useResizeObserver(selectionRef, resetSelectionWidth);
19423
- useResizeObserver(calculatorRef, resetCalculatorWidth);
19424
19619
  useResizeObserver(menuRef, updateTooltip);
19425
19620
  useResizeObserver(wrapperRef, updateTooltip);
19426
19621
  useResizeObserver(tagMenuRef, updateTagTooltip);
@@ -19440,7 +19635,6 @@ const useSelect = (props, emit) => {
19440
19635
  hoverOption,
19441
19636
  selectSize,
19442
19637
  filteredOptionsCount,
19443
- resetCalculatorWidth,
19444
19638
  updateTooltip,
19445
19639
  updateTagTooltip,
19446
19640
  debouncedOnInputChange,
@@ -19454,6 +19648,7 @@ const useSelect = (props, emit) => {
19454
19648
  shouldShowPlaceholder,
19455
19649
  currentPlaceholder,
19456
19650
  mouseEnterEventName,
19651
+ needStatusIcon,
19457
19652
  showClose,
19458
19653
  iconComponent,
19459
19654
  iconReverse,
@@ -19485,12 +19680,10 @@ const useSelect = (props, emit) => {
19485
19680
  collapseTagList,
19486
19681
  tagStyle,
19487
19682
  collapseTagStyle,
19488
- inputStyle,
19489
19683
  popperRef,
19490
19684
  inputRef,
19491
19685
  tooltipRef,
19492
19686
  tagTooltipRef,
19493
- calculatorRef,
19494
19687
  prefixRef,
19495
19688
  suffixRef,
19496
19689
  selectRef,
@@ -19621,6 +19814,14 @@ const SelectProps = buildProps({
19621
19814
  default: true
19622
19815
  },
19623
19816
  remoteShowSuffix: Boolean,
19817
+ showArrow: {
19818
+ type: Boolean,
19819
+ default: true
19820
+ },
19821
+ offset: {
19822
+ type: Number,
19823
+ default: 12
19824
+ },
19624
19825
  placement: {
19625
19826
  type: definePropType(String),
19626
19827
  values: Ee,
@@ -19630,12 +19831,17 @@ const SelectProps = buildProps({
19630
19831
  type: definePropType(Array),
19631
19832
  default: ["bottom-start", "top-start", "right", "left"]
19632
19833
  },
19834
+ tabindex: {
19835
+ type: [String, Number],
19836
+ default: 0
19837
+ },
19838
+ appendTo: String,
19633
19839
  ...useEmptyValuesProps,
19634
19840
  ...useAriaProps(["ariaLabel"])
19635
19841
  });
19636
19842
 
19637
19843
  const COMPONENT_NAME = "ElSelect";
19638
- const _sfc_main$e = defineComponent({
19844
+ const _sfc_main$f = defineComponent({
19639
19845
  name: COMPONENT_NAME,
19640
19846
  componentName: COMPONENT_NAME,
19641
19847
  components: {
@@ -19672,6 +19878,7 @@ const _sfc_main$e = defineComponent({
19672
19878
  modelValue
19673
19879
  });
19674
19880
  const API = useSelect(_props, emit);
19881
+ const { calculatorRef, inputStyle } = useCalcInputWidth();
19675
19882
  provide(selectKey, reactive({
19676
19883
  props: _props,
19677
19884
  states: API.states,
@@ -19682,9 +19889,18 @@ const _sfc_main$e = defineComponent({
19682
19889
  selectRef: API.selectRef,
19683
19890
  setSelected: API.setSelected
19684
19891
  }));
19892
+ const selectedLabel = computed(() => {
19893
+ if (!props.multiple) {
19894
+ return API.states.selectedLabel;
19895
+ }
19896
+ return API.states.selected.map((i) => i.currentLabel);
19897
+ });
19685
19898
  return {
19686
19899
  ...API,
19687
- modelValue
19900
+ modelValue,
19901
+ selectedLabel,
19902
+ calculatorRef,
19903
+ inputStyle
19688
19904
  };
19689
19905
  }
19690
19906
  });
@@ -19718,6 +19934,9 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19718
19934
  "stop-popper-mouse-event": false,
19719
19935
  "gpu-acceleration": false,
19720
19936
  persistent: _ctx.persistent,
19937
+ "append-to": _ctx.appendTo,
19938
+ "show-arrow": _ctx.showArrow,
19939
+ offset: _ctx.offset,
19721
19940
  onBeforeShow: _ctx.handleMenuEnter,
19722
19941
  onHide: ($event) => _ctx.states.isBeforeHide = false
19723
19942
  }, {
@@ -19851,8 +20070,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19851
20070
  _: 3
19852
20071
  }, 8, ["disabled", "effect", "teleported"])) : createCommentVNode("v-if", true)
19853
20072
  ]) : createCommentVNode("v-if", true),
19854
- !_ctx.selectDisabled ? (openBlock(), createElementBlock("div", {
19855
- key: 1,
20073
+ createElementVNode("div", {
19856
20074
  class: normalizeClass([
19857
20075
  _ctx.nsSelect.e("selected-item"),
19858
20076
  _ctx.nsSelect.e("input-wrapper"),
@@ -19869,6 +20087,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19869
20087
  disabled: _ctx.selectDisabled,
19870
20088
  autocomplete: _ctx.autocomplete,
19871
20089
  style: normalizeStyle(_ctx.inputStyle),
20090
+ tabindex: _ctx.tabindex,
19872
20091
  role: "combobox",
19873
20092
  readonly: !_ctx.filterable,
19874
20093
  spellcheck: "false",
@@ -19890,7 +20109,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19890
20109
  onCompositionend: _ctx.handleCompositionEnd,
19891
20110
  onInput: _ctx.onInput,
19892
20111
  onClick: withModifiers(_ctx.toggleMenu, ["stop"])
19893
- }, null, 46, ["id", "onUpdate:modelValue", "name", "disabled", "autocomplete", "readonly", "aria-activedescendant", "aria-controls", "aria-expanded", "aria-label", "onKeydown", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onInput", "onClick"]), [
20112
+ }, null, 46, ["id", "onUpdate:modelValue", "name", "disabled", "autocomplete", "tabindex", "readonly", "aria-activedescendant", "aria-controls", "aria-expanded", "aria-label", "onKeydown", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onInput", "onClick"]), [
19894
20113
  [vModelText, _ctx.states.inputValue]
19895
20114
  ]),
19896
20115
  _ctx.filterable ? (openBlock(), createElementBlock("span", {
@@ -19900,9 +20119,9 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19900
20119
  class: normalizeClass(_ctx.nsSelect.e("input-calculator")),
19901
20120
  textContent: toDisplayString(_ctx.states.inputValue)
19902
20121
  }, null, 10, ["textContent"])) : createCommentVNode("v-if", true)
19903
- ], 2)) : createCommentVNode("v-if", true),
20122
+ ], 2),
19904
20123
  _ctx.shouldShowPlaceholder ? (openBlock(), createElementBlock("div", {
19905
- key: 2,
20124
+ key: 1,
19906
20125
  class: normalizeClass([
19907
20126
  _ctx.nsSelect.e("selected-item"),
19908
20127
  _ctx.nsSelect.e("placeholder"),
@@ -19945,9 +20164,13 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
19945
20164
  ]),
19946
20165
  _: 1
19947
20166
  }, 8, ["class", "onClick"])) : createCommentVNode("v-if", true),
19948
- _ctx.validateState && _ctx.validateIcon ? (openBlock(), createBlock(_component_el_icon, {
20167
+ _ctx.validateState && _ctx.validateIcon && _ctx.needStatusIcon ? (openBlock(), createBlock(_component_el_icon, {
19949
20168
  key: 2,
19950
- class: normalizeClass([_ctx.nsInput.e("icon"), _ctx.nsInput.e("validateIcon")])
20169
+ class: normalizeClass([
20170
+ _ctx.nsInput.e("icon"),
20171
+ _ctx.nsInput.e("validateIcon"),
20172
+ _ctx.nsInput.is("loading", _ctx.validateState === "validating")
20173
+ ])
19951
20174
  }, {
19952
20175
  default: withCtx(() => [
19953
20176
  (openBlock(), createBlock(resolveDynamicComponent(_ctx.validateIcon)))
@@ -20023,14 +20246,14 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
20023
20246
  }, 512)
20024
20247
  ]),
20025
20248
  _: 3
20026
- }, 8, ["visible", "placement", "teleported", "popper-class", "popper-options", "fallback-placements", "effect", "transition", "persistent", "onBeforeShow", "onHide"])
20249
+ }, 8, ["visible", "placement", "teleported", "popper-class", "popper-options", "fallback-placements", "effect", "transition", "persistent", "append-to", "show-arrow", "offset", "onBeforeShow", "onHide"])
20027
20250
  ], 16, ["onMouseleave"])), [
20028
20251
  [_directive_click_outside, _ctx.handleClickOutside, _ctx.popperRef]
20029
20252
  ]);
20030
20253
  }
20031
- var Select = /* @__PURE__ */ _export_sfc$1(_sfc_main$e, [["render", _sfc_render$1], ["__file", "select.vue"]]);
20254
+ var Select = /* @__PURE__ */ _export_sfc$1(_sfc_main$f, [["render", _sfc_render$1], ["__file", "select.vue"]]);
20032
20255
 
20033
- const _sfc_main$d = defineComponent({
20256
+ const _sfc_main$e = defineComponent({
20034
20257
  name: "ElOptionGroup",
20035
20258
  componentName: "ElOptionGroup",
20036
20259
  props: {
@@ -20102,7 +20325,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
20102
20325
  [vShow, _ctx.visible]
20103
20326
  ]);
20104
20327
  }
20105
- var OptionGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$d, [["render", _sfc_render], ["__file", "option-group.vue"]]);
20328
+ var OptionGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$e, [["render", _sfc_render], ["__file", "option-group.vue"]]);
20106
20329
 
20107
20330
  const ElSelect = withInstall(Select, {
20108
20331
  Option,
@@ -20173,11 +20396,11 @@ const popoverEmits = {
20173
20396
  };
20174
20397
 
20175
20398
  const updateEventKeyRaw = `onUpdate:visible`;
20176
- const __default__$b = defineComponent({
20399
+ const __default__$c = defineComponent({
20177
20400
  name: "ElPopover"
20178
20401
  });
20179
- const _sfc_main$c = /* @__PURE__ */ defineComponent({
20180
- ...__default__$b,
20402
+ const _sfc_main$d = /* @__PURE__ */ defineComponent({
20403
+ ...__default__$c,
20181
20404
  props: popoverProps,
20182
20405
  emits: popoverEmits,
20183
20406
  setup(__props, { expose, emit }) {
@@ -20276,7 +20499,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
20276
20499
  };
20277
20500
  }
20278
20501
  });
20279
- var Popover = /* @__PURE__ */ _export_sfc$1(_sfc_main$c, [["__file", "popover.vue"]]);
20502
+ var Popover = /* @__PURE__ */ _export_sfc$1(_sfc_main$d, [["__file", "popover.vue"]]);
20280
20503
 
20281
20504
  const attachEvents = (el, binding) => {
20282
20505
  const popperComponent = binding.arg || binding.value;
@@ -20308,18 +20531,18 @@ var _export_sfc = (sfc, props) => {
20308
20531
  return target;
20309
20532
  };
20310
20533
 
20311
- const _hoisted_1$9 = ["onClick"];
20312
- const _hoisted_2$8 = { class: "hzzt-dropdown-name" };
20534
+ const _hoisted_1$a = ["onClick"];
20535
+ const _hoisted_2$9 = { class: "hzzt-dropdown-name" };
20313
20536
  const _hoisted_3$7 = /* @__PURE__ */ createElementVNode("span", { class: "caret" }, null, -1);
20314
20537
  const _hoisted_4$5 = { class: "hzzt-dropdown-menu" };
20315
20538
  const _hoisted_5$3 = ["onClick"];
20316
20539
  const _hoisted_6$3 = { class: "submenu" };
20317
20540
  const _hoisted_7$3 = ["onClick"];
20318
- const __default__$a = defineComponent({
20541
+ const __default__$b = defineComponent({
20319
20542
  name: "HzztDropDown"
20320
20543
  });
20321
- const _sfc_main$b = /* @__PURE__ */ defineComponent({
20322
- ...__default__$a,
20544
+ const _sfc_main$c = /* @__PURE__ */ defineComponent({
20545
+ ...__default__$b,
20323
20546
  props: {
20324
20547
  options: {
20325
20548
  type: Array,
@@ -20374,7 +20597,7 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
20374
20597
  createElementVNode("li", {
20375
20598
  class: normalizeClass({ "hzzt-dropdown-li": true, "hzzt-dropdown-li-show": toggle.value })
20376
20599
  }, [
20377
- createElementVNode("span", _hoisted_2$8, toDisplayString(__props.label), 1),
20600
+ createElementVNode("span", _hoisted_2$9, toDisplayString(__props.label), 1),
20378
20601
  _hoisted_3$7,
20379
20602
  createElementVNode("ul", _hoisted_4$5, [
20380
20603
  (openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (option, index) => {
@@ -20422,18 +20645,18 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
20422
20645
  }), 256))
20423
20646
  ])
20424
20647
  ], 2)
20425
- ], 8, _hoisted_1$9)), [
20648
+ ], 8, _hoisted_1$a)), [
20426
20649
  [unref(ClickOutside), close]
20427
20650
  ]);
20428
20651
  };
20429
20652
  }
20430
20653
  });
20431
- var Dropdown = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__file", "index.vue"]]);
20654
+ var Dropdown = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__file", "index.vue"]]);
20432
20655
 
20433
20656
  const HzztDropdown = withInstall$1(Dropdown);
20434
20657
 
20435
- const _hoisted_1$8 = { class: "hzzt-collapse" };
20436
- const _hoisted_2$7 = { class: "flex align-items-center" };
20658
+ const _hoisted_1$9 = { class: "hzzt-collapse" };
20659
+ const _hoisted_2$8 = { class: "flex align-items-center" };
20437
20660
  const _hoisted_3$6 = { class: "hzzt-collapse-title-wrapper" };
20438
20661
  const _hoisted_4$4 = /* @__PURE__ */ createElementVNode("div", { class: "hzzt-collapse-title-block" }, null, -1);
20439
20662
  const _hoisted_5$2 = { class: "hzzt-collapse-title" };
@@ -20442,11 +20665,11 @@ const _hoisted_7$2 = {
20442
20665
  key: 0,
20443
20666
  class: "hzzt-collapse-text"
20444
20667
  };
20445
- const __default__$9 = defineComponent({
20668
+ const __default__$a = defineComponent({
20446
20669
  name: "HzztCollapse"
20447
20670
  });
20448
- const _sfc_main$a = /* @__PURE__ */ defineComponent({
20449
- ...__default__$9,
20671
+ const _sfc_main$b = /* @__PURE__ */ defineComponent({
20672
+ ...__default__$a,
20450
20673
  props: {
20451
20674
  defaultActive: {
20452
20675
  type: Boolean,
@@ -20472,12 +20695,12 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
20472
20695
  active.value = !active.value;
20473
20696
  }
20474
20697
  return (_ctx, _cache) => {
20475
- return openBlock(), createElementBlock("div", _hoisted_1$8, [
20698
+ return openBlock(), createElementBlock("div", _hoisted_1$9, [
20476
20699
  createElementVNode("div", {
20477
20700
  class: "hzzt-collapse-header",
20478
20701
  onClick: toggle
20479
20702
  }, [
20480
- createElementVNode("div", _hoisted_2$7, [
20703
+ createElementVNode("div", _hoisted_2$8, [
20481
20704
  createElementVNode("div", _hoisted_3$6, [
20482
20705
  _hoisted_4$4,
20483
20706
  createElementVNode("div", _hoisted_5$2, toDisplayString(__props.title), 1)
@@ -20492,11 +20715,11 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
20492
20715
  };
20493
20716
  }
20494
20717
  });
20495
- var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__file", "collapse.vue"]]);
20718
+ var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__file", "collapse.vue"]]);
20496
20719
 
20497
20720
  const HzztCollapse = withInstall$1(Collapse);
20498
20721
 
20499
- const _sfc_main$9 = /* @__PURE__ */ defineComponent({
20722
+ const _sfc_main$a = /* @__PURE__ */ defineComponent({
20500
20723
  __name: "index",
20501
20724
  props: {
20502
20725
  name: {
@@ -20522,10 +20745,10 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
20522
20745
  };
20523
20746
  }
20524
20747
  });
20525
- var HzztIcon$1 = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__file", "index.vue"]]);
20748
+ var HzztIcon$1 = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__file", "index.vue"]]);
20526
20749
 
20527
- const _hoisted_1$7 = { class: "hzzt-tab flex align-items-center justify-content-between wrap" };
20528
- const _hoisted_2$6 = { class: "flex align-items-center" };
20750
+ const _hoisted_1$8 = { class: "hzzt-tab flex align-items-center justify-content-between wrap" };
20751
+ const _hoisted_2$7 = { class: "flex align-items-center" };
20529
20752
  const _hoisted_3$5 = { class: "flex" };
20530
20753
  const _hoisted_4$3 = ["onClick"];
20531
20754
  const _hoisted_5$1 = { class: "hzzt-tab-badge" };
@@ -20534,11 +20757,11 @@ const _hoisted_6$1 = {
20534
20757
  class: "hzzt-tab-badge-count"
20535
20758
  };
20536
20759
  const _hoisted_7$1 = { class: "flex wrap" };
20537
- const __default__$8 = defineComponent({
20760
+ const __default__$9 = defineComponent({
20538
20761
  name: "HzztTab"
20539
20762
  });
20540
- const _sfc_main$8 = /* @__PURE__ */ defineComponent({
20541
- ...__default__$8,
20763
+ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
20764
+ ...__default__$9,
20542
20765
  props: {
20543
20766
  tabList: {
20544
20767
  type: Array,
@@ -20575,8 +20798,8 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
20575
20798
  emit("tab-close", index);
20576
20799
  }
20577
20800
  return (_ctx, _cache) => {
20578
- return openBlock(), createElementBlock("div", _hoisted_1$7, [
20579
- createElementVNode("div", _hoisted_2$6, [
20801
+ return openBlock(), createElementBlock("div", _hoisted_1$8, [
20802
+ createElementVNode("div", _hoisted_2$7, [
20580
20803
  createElementVNode("div", _hoisted_3$5, [
20581
20804
  (openBlock(true), createElementBlock(Fragment, null, renderList(unref(customTabList), (tab, index) => {
20582
20805
  return openBlock(), createElementBlock("div", {
@@ -20609,7 +20832,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
20609
20832
  };
20610
20833
  }
20611
20834
  });
20612
- var Tab = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__file", "index.vue"]]);
20835
+ var Tab = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__file", "index.vue"]]);
20613
20836
 
20614
20837
  const HzztTab = withInstall$1(Tab);
20615
20838
 
@@ -20625,15 +20848,15 @@ function tarnsElIconName(name) {
20625
20848
  return `hzzt-el${name.replace(/[A-Z]/g, (match) => `-${match.toLocaleLowerCase()}`)}`;
20626
20849
  }
20627
20850
 
20628
- const _hoisted_1$6 = { class: "flex justify-content-between hzzt-pagination" };
20629
- const _hoisted_2$5 = { class: "flex align-items-center font-12 hzzt-pagination-total" };
20851
+ const _hoisted_1$7 = { class: "flex justify-content-between hzzt-pagination" };
20852
+ const _hoisted_2$6 = { class: "flex align-items-center font-12 hzzt-pagination-total" };
20630
20853
  const _hoisted_3$4 = { class: "flex align-items-center hzzt-pagination-page font-14" };
20631
20854
  const _hoisted_4$2 = { class: "flex" };
20632
- const __default__$7 = defineComponent({
20855
+ const __default__$8 = defineComponent({
20633
20856
  name: "HzztPagination"
20634
20857
  });
20635
- const _sfc_main$7 = /* @__PURE__ */ defineComponent({
20636
- ...__default__$7,
20858
+ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
20859
+ ...__default__$8,
20637
20860
  props: {
20638
20861
  pagination: {
20639
20862
  type: Object,
@@ -20663,8 +20886,8 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
20663
20886
  }
20664
20887
  }
20665
20888
  return (_ctx, _cache) => {
20666
- return openBlock(), createElementBlock("div", _hoisted_1$6, [
20667
- createElementVNode("p", _hoisted_2$5, toDisplayString(unref(t)("hzzt.pagination.total")) + toDisplayString(__props.pagination.total) + toDisplayString(unref(t)("hzzt.pagination.strip")), 1),
20889
+ return openBlock(), createElementBlock("div", _hoisted_1$7, [
20890
+ createElementVNode("p", _hoisted_2$6, toDisplayString(unref(t)("hzzt.pagination.total")) + toDisplayString(__props.pagination.total) + toDisplayString(unref(t)("hzzt.pagination.strip")), 1),
20668
20891
  createElementVNode("div", _hoisted_3$4, [
20669
20892
  renderSlot(_ctx.$slots, "right"),
20670
20893
  createVNode(HzztIcon$1, {
@@ -20683,18 +20906,18 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
20683
20906
  };
20684
20907
  }
20685
20908
  });
20686
- var Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__file", "index.vue"]]);
20909
+ var Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__file", "index.vue"]]);
20687
20910
 
20688
20911
  const HzztPagination = withInstall$1(Pagination);
20689
20912
 
20690
- const _hoisted_1$5 = { class: "flex align-content-center" };
20691
- const _hoisted_2$4 = { style: { "max-width": "300px" } };
20913
+ const _hoisted_1$6 = { class: "flex align-content-center" };
20914
+ const _hoisted_2$5 = { style: { "max-width": "300px" } };
20692
20915
  const _hoisted_3$3 = { style: { "padding": "0", "margin": "0", "word-break": "break-all", "white-space": "pre-wrap" } };
20693
- const __default__$6 = defineComponent({
20916
+ const __default__$7 = defineComponent({
20694
20917
  name: "HzztTooltip"
20695
20918
  });
20696
- const _sfc_main$6 = /* @__PURE__ */ defineComponent({
20697
- ...__default__$6,
20919
+ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
20920
+ ...__default__$7,
20698
20921
  props: {
20699
20922
  content: {
20700
20923
  type: String,
@@ -20705,11 +20928,11 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
20705
20928
  setup(__props, { emit }) {
20706
20929
  const attrs = useAttrs$1();
20707
20930
  return (_ctx, _cache) => {
20708
- return openBlock(), createElementBlock("div", _hoisted_1$5, [
20931
+ return openBlock(), createElementBlock("div", _hoisted_1$6, [
20709
20932
  createVNode(unref(ElTooltip), mergeProps({ effect: "dark" }, unref(attrs)), {
20710
20933
  content: withCtx(() => [
20711
20934
  renderSlot(_ctx.$slots, "content", {}, () => [
20712
- createElementVNode("div", _hoisted_2$4, [
20935
+ createElementVNode("div", _hoisted_2$5, [
20713
20936
  createElementVNode("pre", _hoisted_3$3, toDisplayString(__props.content), 1)
20714
20937
  ])
20715
20938
  ])
@@ -20728,15 +20951,15 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
20728
20951
  };
20729
20952
  }
20730
20953
  });
20731
- var Tooltip = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__file", "tooltip.vue"]]);
20954
+ var Tooltip = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__file", "tooltip.vue"]]);
20732
20955
 
20733
20956
  const HzztTooltip = withInstall$1(Tooltip);
20734
20957
 
20735
- const _hoisted_1$4 = {
20958
+ const _hoisted_1$5 = {
20736
20959
  key: 0,
20737
20960
  style: { "white-space": "nowrap" }
20738
20961
  };
20739
- const _hoisted_2$3 = {
20962
+ const _hoisted_2$4 = {
20740
20963
  key: 1,
20741
20964
  style: { "white-space": "nowrap" }
20742
20965
  };
@@ -20745,11 +20968,11 @@ const _hoisted_4$1 = {
20745
20968
  key: 0,
20746
20969
  class: "margin-l-1 margin-r-2"
20747
20970
  };
20748
- const __default__$5 = defineComponent({
20971
+ const __default__$6 = defineComponent({
20749
20972
  name: "HzztPageSize"
20750
20973
  });
20751
- const _sfc_main$5 = /* @__PURE__ */ defineComponent({
20752
- ...__default__$5,
20974
+ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
20975
+ ...__default__$6,
20753
20976
  props: {
20754
20977
  modelValue: {
20755
20978
  type: Number,
@@ -20806,8 +21029,8 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
20806
21029
  return openBlock(), createElementBlock("main", {
20807
21030
  class: normalizeClass([unref(compKls), "flex wrap align-items-center justify-content-end"])
20808
21031
  }, [
20809
- __props.total > 0 && !__props.isManual ? (openBlock(), createElementBlock("span", _hoisted_1$4, toDisplayString(unref(t)("hzzt.pageSize.total")) + toDisplayString(__props.total) + toDisplayString(unref(t)("hzzt.pageSize.strip")), 1)) : createCommentVNode("v-if", true),
20810
- __props.isManual ? (openBlock(), createElementBlock("span", _hoisted_2$3, toDisplayString(unref(t)("hzzt.pageSize.d")) + toDisplayString(__props.modelValue) + toDisplayString(unref(t)("hzzt.pageSize.page")), 1)) : createCommentVNode("v-if", true),
21032
+ __props.total > 0 && !__props.isManual ? (openBlock(), createElementBlock("span", _hoisted_1$5, toDisplayString(unref(t)("hzzt.pageSize.total")) + toDisplayString(__props.total) + toDisplayString(unref(t)("hzzt.pageSize.strip")), 1)) : createCommentVNode("v-if", true),
21033
+ __props.isManual ? (openBlock(), createElementBlock("span", _hoisted_2$4, toDisplayString(unref(t)("hzzt.pageSize.d")) + toDisplayString(__props.modelValue) + toDisplayString(unref(t)("hzzt.pageSize.page")), 1)) : createCommentVNode("v-if", true),
20811
21034
  __props.pageSizeOptions.length ? (openBlock(), createElementBlock("div", {
20812
21035
  key: 2,
20813
21036
  class: normalizeClass([unref(ns).e("option"), "flex align-items-center"])
@@ -20876,15 +21099,15 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
20876
21099
  };
20877
21100
  }
20878
21101
  });
20879
- var PageSize = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__file", "index.vue"]]);
21102
+ var PageSize = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__file", "index.vue"]]);
20880
21103
 
20881
21104
  const HzztPageSize = withInstall$1(PageSize);
20882
21105
 
20883
- const __default__$4 = defineComponent({
21106
+ const __default__$5 = defineComponent({
20884
21107
  name: "HzztConfirmPassword"
20885
21108
  });
20886
- const _sfc_main$4 = /* @__PURE__ */ defineComponent({
20887
- ...__default__$4,
21109
+ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
21110
+ ...__default__$5,
20888
21111
  props: {
20889
21112
  placeholder: {
20890
21113
  type: String,
@@ -20944,16 +21167,16 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
20944
21167
  };
20945
21168
  }
20946
21169
  });
20947
- var ConfirmPassword = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__file", "confirm-password.vue"]]);
21170
+ var ConfirmPassword = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__file", "confirm-password.vue"]]);
20948
21171
 
20949
21172
  const HzztConfirmPassword = withInstall$1(ConfirmPassword);
20950
21173
 
20951
- const _hoisted_1$3 = ["onClick"];
20952
- const __default__$3 = defineComponent({
21174
+ const _hoisted_1$4 = ["onClick"];
21175
+ const __default__$4 = defineComponent({
20953
21176
  name: "HzztCheckButton"
20954
21177
  });
20955
- const _sfc_main$3 = /* @__PURE__ */ defineComponent({
20956
- ...__default__$3,
21178
+ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
21179
+ ...__default__$4,
20957
21180
  props: {
20958
21181
  options: {
20959
21182
  type: Array,
@@ -21014,7 +21237,7 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
21014
21237
  ...unref(spanKls)
21015
21238
  ], "flex-1"]),
21016
21239
  onClick: ($event) => selectValue(item.value)
21017
- }, toDisplayString(item.label), 11, _hoisted_1$3)
21240
+ }, toDisplayString(item.label), 11, _hoisted_1$4)
21018
21241
  ]),
21019
21242
  _: 2
21020
21243
  }, 1032, ["hidden", "value"]);
@@ -21023,7 +21246,7 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
21023
21246
  };
21024
21247
  }
21025
21248
  });
21026
- var CheckButton = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__file", "index.vue"]]);
21249
+ var CheckButton = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__file", "index.vue"]]);
21027
21250
 
21028
21251
  const HzztCheckButton = withInstall$1(CheckButton);
21029
21252
 
@@ -21264,8 +21487,8 @@ function range(n) {
21264
21487
  return Array.from({ length: n }).map((_, n2) => n2);
21265
21488
  }
21266
21489
 
21267
- const _hoisted_1$2 = { class: "el-date-picker" };
21268
- const _hoisted_2$2 = { class: "el-picker-panel__body" };
21490
+ const _hoisted_1$3 = { class: "el-date-picker" };
21491
+ const _hoisted_2$3 = { class: "el-picker-panel__body" };
21269
21492
  const _hoisted_3$1 = {
21270
21493
  class: "el-date-picker__header el-date-picker__header--bordered",
21271
21494
  style: { "margin": "0px", "line-height": "30px" }
@@ -21281,11 +21504,11 @@ const _hoisted_8 = { class: "cell" };
21281
21504
  const _hoisted_9 = { class: "cell" };
21282
21505
  const _hoisted_10 = { class: "cell" };
21283
21506
  const _hoisted_11 = { class: "cell" };
21284
- const __default__$2 = defineComponent({
21507
+ const __default__$3 = defineComponent({
21285
21508
  name: "HzztQuarterPicker"
21286
21509
  });
21287
- const _sfc_main$2 = /* @__PURE__ */ defineComponent({
21288
- ...__default__$2,
21510
+ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
21511
+ ...__default__$3,
21289
21512
  props: {
21290
21513
  size: useSizeProp$1,
21291
21514
  format: {
@@ -21463,8 +21686,8 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
21463
21686
  }, 16, ["disabled", "size", "placeholder", "value"])
21464
21687
  ]),
21465
21688
  default: withCtx(() => [
21466
- createElementVNode("div", _hoisted_1$2, [
21467
- createElementVNode("div", _hoisted_2$2, [
21689
+ createElementVNode("div", _hoisted_1$3, [
21690
+ createElementVNode("div", _hoisted_2$3, [
21468
21691
  createElementVNode("div", _hoisted_3$1, [
21469
21692
  createElementVNode("button", {
21470
21693
  type: "button",
@@ -21525,7 +21748,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
21525
21748
  };
21526
21749
  }
21527
21750
  });
21528
- var QuarterPicker = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__file", "index.vue"]]);
21751
+ var QuarterPicker = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__file", "index.vue"]]);
21529
21752
 
21530
21753
  const HzztQuarterPicker = withInstall$1(QuarterPicker);
21531
21754
 
@@ -21549,7 +21772,7 @@ const scanEmits = {
21549
21772
  [INPUT_EVENT$1]: (value) => isString$1(value)
21550
21773
  };
21551
21774
 
21552
- const _hoisted_1$1 = /* @__PURE__ */ createElementVNode("div", { style: { "width": "0", "height": "0", "overflow": "hidden" } }, [
21775
+ const _hoisted_1$2 = /* @__PURE__ */ createElementVNode("div", { style: { "width": "0", "height": "0", "overflow": "hidden" } }, [
21553
21776
  /* @__PURE__ */ createElementVNode("input", {
21554
21777
  readonly: "",
21555
21778
  style: { "width": "0", "height": "0", "overflow": "hidden" }
@@ -21561,16 +21784,16 @@ const _hoisted_1$1 = /* @__PURE__ */ createElementVNode("div", { style: { "width
21561
21784
  style: { "width": "0", "height": "0", "overflow": "hidden" }
21562
21785
  })
21563
21786
  ], -1);
21564
- const _hoisted_2$1 = {
21787
+ const _hoisted_2$2 = {
21565
21788
  class: "width-100%",
21566
21789
  style: { "overflow": "hidden" }
21567
21790
  };
21568
- const __default__$1 = defineComponent({
21791
+ const __default__$2 = defineComponent({
21569
21792
  inheritAttrs: false,
21570
21793
  name: "HzztScan"
21571
21794
  });
21572
- const _sfc_main$1 = /* @__PURE__ */ defineComponent({
21573
- ...__default__$1,
21795
+ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
21796
+ ...__default__$2,
21574
21797
  props: scanProps,
21575
21798
  emits: scanEmits,
21576
21799
  setup(__props, { expose, emit }) {
@@ -21649,7 +21872,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
21649
21872
  class: normalizeClass(["hzzt-scan", _ctx.$attrs.class]),
21650
21873
  style: normalizeStyle([{ "position": "relative" }, _ctx.$attrs.style])
21651
21874
  }, [
21652
- _hoisted_1$1,
21875
+ _hoisted_1$2,
21653
21876
  createVNode(unref(ElInput), mergeProps({
21654
21877
  ref_key: "inputRef",
21655
21878
  ref: inputRef,
@@ -21683,16 +21906,175 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
21683
21906
  createElementVNode("div", {
21684
21907
  class: normalizeClass(["hzzt-scan-input-backup", { "placeholder-color": innerValue.value === " " }])
21685
21908
  }, [
21686
- createElementVNode("div", _hoisted_2$1, toDisplayString(unref(showValue)), 1)
21909
+ createElementVNode("div", _hoisted_2$2, toDisplayString(unref(showValue)), 1)
21687
21910
  ], 2)
21688
21911
  ], 6);
21689
21912
  };
21690
21913
  }
21691
21914
  });
21692
- var Scan = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__file", "scan.vue"]]);
21915
+ var Scan = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__file", "scan.vue"]]);
21693
21916
 
21694
21917
  const HzztScan = withInstall$1(Scan);
21695
21918
 
21919
+ const selectInputProps = buildProps$1({
21920
+ modelValue: {
21921
+ type: definePropType$1([
21922
+ String,
21923
+ Number
21924
+ ]),
21925
+ default: ""
21926
+ },
21927
+ indexType: {
21928
+ type: String,
21929
+ default: "number"
21930
+ },
21931
+ disabled: Boolean,
21932
+ replace: Boolean,
21933
+ label: String,
21934
+ data: {
21935
+ type: definePropType$1(Array),
21936
+ default: () => []
21937
+ },
21938
+ inputProps: Object,
21939
+ customProps: Object,
21940
+ position: {
21941
+ type: String,
21942
+ default: "left"
21943
+ },
21944
+ formatLabel: {
21945
+ type: Function
21946
+ },
21947
+ split: {
21948
+ type: String,
21949
+ default: ""
21950
+ },
21951
+ size: useSizeProp$1
21952
+ });
21953
+ const selectInputEmits = {
21954
+ [UPDATE_MODEL_EVENT$1]: (value) => isString$1(value),
21955
+ input: (value) => isString$1(value),
21956
+ change: (value) => isString$1(value)
21957
+ };
21958
+
21959
+ const _hoisted_1$1 = { slot: "append" };
21960
+ const _hoisted_2$1 = { key: 0 };
21961
+ const __default__$1 = defineComponent({
21962
+ name: "HzztSelectInput"
21963
+ });
21964
+ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
21965
+ ...__default__$1,
21966
+ props: selectInputProps,
21967
+ emits: selectInputEmits,
21968
+ setup(__props, { emit }) {
21969
+ const props = __props;
21970
+ const inputVal = ref(props.modelValue);
21971
+ const nsInput = useNamespace$1("select-input");
21972
+ const formSize = useFormSize();
21973
+ const formDisabled = useFormDisabled();
21974
+ const trueSize = computed(() => props.size || formSize.value || useGlobalSize$1().value);
21975
+ const trueDisabled = computed(() => props.disabled || formDisabled.value);
21976
+ const containerCls = computed(() => [
21977
+ nsInput.b(),
21978
+ nsInput.m(trueSize.value)
21979
+ ]);
21980
+ const inputContainerCls = computed(() => [
21981
+ "flex",
21982
+ props.position === "top" ? "column" : "row align-items-center"
21983
+ ]);
21984
+ const inputCls = computed(() => [
21985
+ "flex-1",
21986
+ props.label ? props.position === "top" ? "margin-b-1" : "margin-l-1" : ""
21987
+ ]);
21988
+ const _inputProps = computed(() => ({
21989
+ disabled: trueDisabled.value,
21990
+ clearable: true,
21991
+ ...props.inputProps
21992
+ }));
21993
+ watch(() => props.modelValue, (v) => {
21994
+ inputVal.value = v;
21995
+ });
21996
+ function input(val) {
21997
+ emit("update:modelValue", val);
21998
+ emit("input", val);
21999
+ }
22000
+ function change(val) {
22001
+ emit("change", val);
22002
+ }
22003
+ function getLinkName(item, index) {
22004
+ let prefix = "";
22005
+ if (props.indexType == "number") {
22006
+ prefix = `\uFF08${index + 1}\uFF09`;
22007
+ } else if (props.indexType == "letter") {
22008
+ prefix = `\uFF08${numberToLetter(index)}\uFF09`;
22009
+ }
22010
+ return prefix + (item.label || item.value);
22011
+ }
22012
+ function select(item) {
22013
+ const value = item.value || item.label;
22014
+ let content = "";
22015
+ if (!inputVal.value)
22016
+ inputVal.value = "";
22017
+ if (props.formatLabel) {
22018
+ content = props.formatLabel(value);
22019
+ } else if (props.replace) {
22020
+ content = value;
22021
+ } else {
22022
+ content = inputVal.value ? `${inputVal.value}${props.split}${value}` : value;
22023
+ }
22024
+ inputVal.value = content;
22025
+ input(content);
22026
+ change(content);
22027
+ }
22028
+ return (_ctx, _cache) => {
22029
+ return openBlock(), createElementBlock("div", {
22030
+ class: normalizeClass(unref(containerCls))
22031
+ }, [
22032
+ createElementVNode("div", {
22033
+ class: normalizeClass(unref(inputContainerCls))
22034
+ }, [
22035
+ renderSlot(_ctx.$slots, "title", {}, () => [
22036
+ createVNode(Title, { label: _ctx.label }, null, 8, ["label"])
22037
+ ]),
22038
+ createVNode(unref(ElInput), mergeProps({
22039
+ ref: "inputRef",
22040
+ class: unref(inputCls),
22041
+ modelValue: inputVal.value,
22042
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputVal.value = $event)
22043
+ }, unref(_inputProps), {
22044
+ onInput: input,
22045
+ onChange: change
22046
+ }), {
22047
+ default: withCtx(() => [
22048
+ createElementVNode("template", _hoisted_1$1, [
22049
+ renderSlot(_ctx.$slots, "append")
22050
+ ])
22051
+ ]),
22052
+ _: 3
22053
+ }, 16, ["class", "modelValue"])
22054
+ ], 2),
22055
+ _ctx.data.length && !unref(trueDisabled) ? (openBlock(), createElementBlock("div", _hoisted_2$1, [
22056
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.data, (item, index) => {
22057
+ return openBlock(), createBlock(unref(ElLink), mergeProps({
22058
+ key: index,
22059
+ class: "margin-r-4"
22060
+ }, _ctx.customProps, {
22061
+ onClick: ($event) => select(item)
22062
+ }), {
22063
+ default: withCtx(() => [
22064
+ createTextVNode(toDisplayString(getLinkName(item, index)), 1)
22065
+ ]),
22066
+ _: 2
22067
+ }, 1040, ["onClick"]);
22068
+ }), 128))
22069
+ ])) : createCommentVNode("v-if", true)
22070
+ ], 2);
22071
+ };
22072
+ }
22073
+ });
22074
+ var SelectInput = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__file", "select-input.vue"]]);
22075
+
22076
+ const HzztSelectInput = withInstall$1(SelectInput);
22077
+
21696
22078
  const _hoisted_1 = {
21697
22079
  key: 0,
21698
22080
  class: "hzzt-title flex align-items-center"
@@ -21753,7 +22135,8 @@ var Components = [
21753
22135
  HzztConfirmPassword,
21754
22136
  HzztCheckButton,
21755
22137
  HzztQuarterPicker,
21756
- HzztScan
22138
+ HzztScan,
22139
+ HzztSelectInput
21757
22140
  ];
21758
22141
 
21759
22142
  var Plugins = [];
@@ -21965,4 +22348,4 @@ function initMouseEvent(el, callback) {
21965
22348
  const install = installer.install;
21966
22349
  const version = installer.version;
21967
22350
 
21968
- export { Blur, CHANGE_EVENT$1 as CHANGE_EVENT, Download, Drag, Height, Highlight, HzztCheckButton, HzztCollapse, HzztConfigProvider, HzztConfirmPassword, HzztDropdown, HzztIcon, HzztPageSize, HzztPagination, HzztQuarterPicker, HzztScan, HzztTab, HzztTitle, HzztTooltip, INPUT_EVENT$1 as INPUT_EVENT, INSTALLED_KEY, SIZE_INJECTION_KEY$1 as SIZE_INJECTION_KEY, UPDATE_MODEL_EVENT$1 as UPDATE_MODEL_EVENT, WEEK_DAYS, buildLocaleContext$1 as buildLocaleContext, buildTranslator$1 as buildTranslator, componentSizeMap, componentSizes$1 as componentSizes, configProviderContextKey$1 as configProviderContextKey, configProviderProps, datePickTypes, installer as default, defaultNamespace$1 as defaultNamespace, install, localeContextKey$1 as localeContextKey, makeInstaller, namespaceContextKey$1 as namespaceContextKey, provideGlobalConfig, scanEmits, scanProps, titleProps, translate$1 as translate, useGetDerivedNamespace$1 as useGetDerivedNamespace, useGlobalConfig$1 as useGlobalConfig, useGlobalSize$1 as useGlobalSize, useLocale$1 as useLocale, useNamespace$1 as useNamespace, useSizeProp$1 as useSizeProp, useSizeProps, version };
22351
+ export { Blur, CHANGE_EVENT$1 as CHANGE_EVENT, Download, Drag, Height, Highlight, HzztCheckButton, HzztCollapse, HzztConfigProvider, HzztConfirmPassword, HzztDropdown, HzztIcon, HzztPageSize, HzztPagination, HzztQuarterPicker, HzztScan, HzztSelectInput, HzztTab, HzztTitle, HzztTooltip, INPUT_EVENT$1 as INPUT_EVENT, INSTALLED_KEY, SIZE_INJECTION_KEY$1 as SIZE_INJECTION_KEY, UPDATE_MODEL_EVENT$1 as UPDATE_MODEL_EVENT, WEEK_DAYS, buildLocaleContext$1 as buildLocaleContext, buildTranslator$1 as buildTranslator, componentSizeMap, componentSizes$1 as componentSizes, configProviderContextKey$1 as configProviderContextKey, configProviderProps, datePickTypes, installer as default, defaultNamespace$1 as defaultNamespace, install, localeContextKey$1 as localeContextKey, makeInstaller, namespaceContextKey$1 as namespaceContextKey, numberToLetter, provideGlobalConfig, scanEmits, scanProps, selectInputEmits, selectInputProps, titleProps, translate$1 as translate, useGetDerivedNamespace$1 as useGetDerivedNamespace, useGlobalConfig$1 as useGlobalConfig, useGlobalSize$1 as useGlobalSize, useLocale$1 as useLocale, useNamespace$1 as useNamespace, useSizeProp$1 as useSizeProp, useSizeProps, version };