@voicenter-team/voicenter-ui-plus 2.0.4 → 2.0.6

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 (92) hide show
  1. package/library/core/{entry-9waO-ii2.mjs → entry-DDDwx3pr.mjs} +1288 -229
  2. package/library/core/entry-DDDwx3pr.mjs.br +0 -0
  3. package/library/core/entry-DDDwx3pr.mjs.gz +0 -0
  4. package/library/core/{index-DAPqny2s.mjs → index-B3DxZAFq.mjs} +1 -1
  5. package/library/core/index-B3DxZAFq.mjs.br +0 -0
  6. package/library/core/index-B3DxZAFq.mjs.gz +0 -0
  7. package/library/core/{index-Djf2HmOn.mjs → index-BGJQiclS.mjs} +1 -1
  8. package/library/core/index-BGJQiclS.mjs.br +0 -0
  9. package/library/core/index-BGJQiclS.mjs.gz +0 -0
  10. package/library/core/{index-CApVvY4i.mjs → index-B_bildVv.mjs} +1 -1
  11. package/library/core/index-B_bildVv.mjs.br +0 -0
  12. package/library/core/index-B_bildVv.mjs.gz +0 -0
  13. package/library/core/{index-D0jRT024.mjs → index-Bju5LdiT.mjs} +1 -1
  14. package/library/core/index-Bju5LdiT.mjs.br +0 -0
  15. package/library/core/index-Bju5LdiT.mjs.gz +0 -0
  16. package/library/core/{index-D6ztvlVx.mjs → index-CeFBm9ea.mjs} +1 -1
  17. package/library/core/index-CeFBm9ea.mjs.br +0 -0
  18. package/library/core/index-CeFBm9ea.mjs.gz +0 -0
  19. package/library/core/{index-UOZNryNK.mjs → index-CkfLio6C.mjs} +1 -1
  20. package/library/core/index-CkfLio6C.mjs.br +0 -0
  21. package/library/core/index-CkfLio6C.mjs.gz +0 -0
  22. package/library/core/{index-BW6WQkYN.mjs → index-D6humb3h.mjs} +1 -1
  23. package/library/core/index-D6humb3h.mjs.br +0 -0
  24. package/library/core/index-D6humb3h.mjs.gz +0 -0
  25. package/library/core/{index-BIuNzHq0.mjs → index-DHgyBRn8.mjs} +1 -1
  26. package/library/core/index-DHgyBRn8.mjs.br +0 -0
  27. package/library/core/index-DHgyBRn8.mjs.gz +0 -0
  28. package/library/core/{index-D51jpGiF.mjs → index-DQrGwq4Z.mjs} +1 -1
  29. package/library/core/index-DQrGwq4Z.mjs.br +0 -0
  30. package/library/core/index-DQrGwq4Z.mjs.gz +0 -0
  31. package/library/core/{index-wJLOQ-wI.mjs → index-DknIur64.mjs} +1 -1
  32. package/library/core/index-DknIur64.mjs.br +0 -0
  33. package/library/core/index-DknIur64.mjs.gz +0 -0
  34. package/library/core/{index-5XTYllf8.mjs → index-N0wzFp0j.mjs} +1 -1
  35. package/library/core/index-N0wzFp0j.mjs.br +0 -0
  36. package/library/core/{index-5XTYllf8.mjs.gz → index-N0wzFp0j.mjs.gz} +0 -0
  37. package/library/core/{index-D4_mrv79.mjs → index-pOvLJNkD.mjs} +1 -1
  38. package/library/core/index-pOvLJNkD.mjs.br +0 -0
  39. package/library/core/index-pOvLJNkD.mjs.gz +0 -0
  40. package/library/core/{index-BWexRHi1.mjs → index-sHXxzmmN.mjs} +1 -1
  41. package/library/core/index-sHXxzmmN.mjs.br +0 -0
  42. package/library/core/index-sHXxzmmN.mjs.gz +0 -0
  43. package/library/core/{index-BvQvCT4b.mjs → index-u_Dj56FR.mjs} +1 -1
  44. package/library/core/index-u_Dj56FR.mjs.br +0 -0
  45. package/library/core/index-u_Dj56FR.mjs.gz +0 -0
  46. package/library/core/{index-BJJ7G1kH.mjs → index-ya5Il1Qw.mjs} +1 -1
  47. package/library/core/index-ya5Il1Qw.mjs.br +0 -0
  48. package/library/core/index-ya5Il1Qw.mjs.gz +0 -0
  49. package/library/core/index.mjs +32 -31
  50. package/library/core/index.mjs.br +0 -0
  51. package/library/core/index.mjs.gz +0 -0
  52. package/library/core/index.umd.js +5 -5
  53. package/library/core/index.umd.js.br +0 -0
  54. package/library/core/index.umd.js.gz +0 -0
  55. package/library/core/style.css +1 -1
  56. package/library/core/style.css.br +0 -0
  57. package/library/core/style.css.gz +0 -0
  58. package/library/core/types/components/VcMdEditor/VcMdEditor.vue.d.ts +51 -4
  59. package/library/core/types/components/VcMdEditor/VcMdEditorToolbar.vue.d.ts +3 -3
  60. package/library/core/types/types/VcMdEditor.types.d.ts +6 -0
  61. package/package.json +1 -1
  62. package/library/core/entry-9waO-ii2.mjs.br +0 -0
  63. package/library/core/entry-9waO-ii2.mjs.gz +0 -0
  64. package/library/core/index-5XTYllf8.mjs.br +0 -0
  65. package/library/core/index-BIuNzHq0.mjs.br +0 -0
  66. package/library/core/index-BIuNzHq0.mjs.gz +0 -0
  67. package/library/core/index-BJJ7G1kH.mjs.br +0 -0
  68. package/library/core/index-BJJ7G1kH.mjs.gz +0 -0
  69. package/library/core/index-BW6WQkYN.mjs.br +0 -0
  70. package/library/core/index-BW6WQkYN.mjs.gz +0 -0
  71. package/library/core/index-BWexRHi1.mjs.br +0 -0
  72. package/library/core/index-BWexRHi1.mjs.gz +0 -0
  73. package/library/core/index-BvQvCT4b.mjs.br +0 -0
  74. package/library/core/index-BvQvCT4b.mjs.gz +0 -0
  75. package/library/core/index-CApVvY4i.mjs.br +0 -0
  76. package/library/core/index-CApVvY4i.mjs.gz +0 -0
  77. package/library/core/index-D0jRT024.mjs.br +0 -0
  78. package/library/core/index-D0jRT024.mjs.gz +0 -0
  79. package/library/core/index-D4_mrv79.mjs.br +0 -0
  80. package/library/core/index-D4_mrv79.mjs.gz +0 -0
  81. package/library/core/index-D51jpGiF.mjs.br +0 -0
  82. package/library/core/index-D51jpGiF.mjs.gz +0 -0
  83. package/library/core/index-D6ztvlVx.mjs.br +0 -0
  84. package/library/core/index-D6ztvlVx.mjs.gz +0 -0
  85. package/library/core/index-DAPqny2s.mjs.br +0 -0
  86. package/library/core/index-DAPqny2s.mjs.gz +0 -0
  87. package/library/core/index-Djf2HmOn.mjs.br +0 -0
  88. package/library/core/index-Djf2HmOn.mjs.gz +0 -0
  89. package/library/core/index-UOZNryNK.mjs.br +0 -0
  90. package/library/core/index-UOZNryNK.mjs.gz +0 -0
  91. package/library/core/index-wJLOQ-wI.mjs.br +0 -0
  92. package/library/core/index-wJLOQ-wI.mjs.gz +0 -0
@@ -10,7 +10,7 @@ var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot
10
10
  var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value);
11
11
  var __privateMethod = (obj, member, method4) => (__accessCheck(obj, member, "access private method"), method4);
12
12
  var _watchers, _value, _emit, _meta, _container, _clock, _injectedSlices, _consumedSlices, _recordedTimers, _waitTimers, _getSlice, _getTimer, _container2, _clock2, _meta2, _inspector, _promise, _listener, _eventUniqId, _status, _removeListener, _waitTimeout, _container3, _ctx2, _ctx3, _keymap, _enableInspector, _status2, _configureList, _onStatusChange, _container4, _clock3, _usrPluginStore, _sysPluginStore, _ctx4, _loadInternal, _prepare, _cleanup, _cleanupInternal, _setStatus, _loadPluginInStore, _ctx5, _createSelection, _activeSelection, _active, _activeDOMRect, _dragging, _BlockService_instances, filterNodes_get, view_get, _notify, _hide2, _show2, _handleMouseDown, _handleMouseUp, _handleDragStart, _mousemoveCallback, _dragEnd, _element, _ctx6, _service, _activeNode, _root2, _initialized, _middleware, _floatingUIOptions, _getOffset, _getPosition, _getPlacement, _BlockProvider_instances, init_fn, _initialized2, _middleware2, _floatingUIOptions2, _root3, _debounce, _trigger, _shouldShow2, _updater, _offset, _onUpdate, _SlashProvider_instances, _shouldShow_fn, _debounce2, _shouldShow3, _middleware3, _floatingUIOptions3, _root4, _initialized3, _offset2, _shift, _updater2, _onUpdate2, _TooltipProvider_instances, _shouldShow_fn2;
13
- import { ref, defineComponent, computed, createElementBlock, openBlock, normalizeClass, createElementVNode, createCommentVNode, renderSlot, toDisplayString, getCurrentInstance, inject, unref, watch, getCurrentScope, onScopeDispose, shallowRef, watchEffect, readonly, isRef, reactive, customRef, onMounted, nextTick, warn, mergeProps, toRef, onUnmounted, useAttrs as useAttrs$1, useSlots, normalizeStyle, Fragment as Fragment$1, createBlock, withCtx, resolveDynamicComponent, withModifiers, onBeforeUnmount, Transition, withDirectives, vShow, createVNode, provide, onActivated, onUpdated, cloneVNode, Comment, Text as Text$3, Teleport as Teleport$1, onBeforeMount, onDeactivated, withKeys, createSlots, renderList, createTextVNode, isVNode, toRaw, vModelCheckbox, toRefs, vModelRadio, toHandlers, resolveComponent, normalizeProps, guardReactiveProps, TransitionGroup, resolveDirective, toHandlerKey, vModelText, h as h$2, mergeModels, useModel, useCssVars, createStaticVNode, markRaw, createApp } from "vue";
13
+ import { ref, defineComponent, computed, createElementBlock, openBlock, normalizeClass, createElementVNode, createCommentVNode, renderSlot, toDisplayString, getCurrentInstance, inject, unref, watch, getCurrentScope, onScopeDispose, shallowRef, watchEffect, readonly, isRef, reactive, customRef, onMounted, nextTick, warn, mergeProps, toRef, onUnmounted, useAttrs as useAttrs$1, useSlots, normalizeStyle, Fragment as Fragment$1, createBlock, withCtx, resolveDynamicComponent, withModifiers, onBeforeUnmount, Transition, withDirectives, vShow, createVNode, provide, onActivated, onUpdated, cloneVNode, Comment, Text as Text$3, Teleport as Teleport$1, onBeforeMount, onDeactivated, withKeys, createSlots, renderList, createTextVNode, isVNode, toRaw, vModelCheckbox, toRefs, vModelRadio, onBeforeUpdate, toHandlers, resolveComponent, normalizeProps, guardReactiveProps, TransitionGroup, resolveDirective, toHandlerKey, vModelText, h as h$2, mergeModels, useModel, useCssVars, createStaticVNode, markRaw, createApp } from "vue";
14
14
  const blue = {
15
15
  "card-shadow-color": "#E0E2E5",
16
16
  "card-bg-color": "#fff",
@@ -529,7 +529,7 @@ const DEFAULT_SIZE$a = "middle";
529
529
  const DEFAULT_TYPE$3 = "default";
530
530
  const DEFAULT_COLOR$a = "primary";
531
531
  const DEFAULT_LOAD_ICON$1 = "vc-icon-load";
532
- const _sfc_main$2T = /* @__PURE__ */ defineComponent({
532
+ const _sfc_main$2W = /* @__PURE__ */ defineComponent({
533
533
  __name: "VcButton",
534
534
  props: {
535
535
  disabled: { type: Boolean, default: false },
@@ -615,7 +615,7 @@ const CLASS_FILLED_COLOR = "filled-";
615
615
  const CLASS_HOVERLESS = "vc-button-icon-type--hoverless";
616
616
  const CLASS_FOR_TYPE = "vc-button-icon-type--";
617
617
  const CLASS_FOR_COLOR$4 = "vc-button-icon-color--";
618
- const _sfc_main$2S = /* @__PURE__ */ defineComponent({
618
+ const _sfc_main$2V = /* @__PURE__ */ defineComponent({
619
619
  __name: "VcButtonIcon",
620
620
  props: {
621
621
  type: { default: DEFAULT_TYPE$2 },
@@ -691,11 +691,11 @@ const _export_sfc$1 = (sfc, props) => {
691
691
  }
692
692
  return target;
693
693
  };
694
- const VcButtonIcon = /* @__PURE__ */ _export_sfc$1(_sfc_main$2S, [["__scopeId", "data-v-8c261120"]]);
694
+ const VcButtonIcon = /* @__PURE__ */ _export_sfc$1(_sfc_main$2V, [["__scopeId", "data-v-8c261120"]]);
695
695
  const _hoisted_1$1e = ["tabindex", "disabled", "aria-pressed", "data-p-checked", "data-p-disabled", "data-test"];
696
696
  const _hoisted_2$T = { class: "vc-toggle-button__content" };
697
697
  const _hoisted_3$J = { class: "vc-toggle-button__label" };
698
- const _sfc_main$2R = /* @__PURE__ */ defineComponent({
698
+ const _sfc_main$2U = /* @__PURE__ */ defineComponent({
699
699
  __name: "VcToggleButton",
700
700
  props: {
701
701
  modelValue: { type: Boolean, default: void 0 },
@@ -996,8 +996,8 @@ function isFunction$6(value) {
996
996
  }
997
997
  var coreJsData$2 = root$b["__core-js_shared__"];
998
998
  var maskSrcKey$1 = function() {
999
- var uid = /[^.]+$/.exec(coreJsData$2 && coreJsData$2.keys && coreJsData$2.keys.IE_PROTO || "");
1000
- return uid ? "Symbol(src)_1." + uid : "";
999
+ var uid2 = /[^.]+$/.exec(coreJsData$2 && coreJsData$2.keys && coreJsData$2.keys.IE_PROTO || "");
1000
+ return uid2 ? "Symbol(src)_1." + uid2 : "";
1001
1001
  }();
1002
1002
  function isMasked$2(func) {
1003
1003
  return !!maskSrcKey$1 && maskSrcKey$1 in func;
@@ -1619,8 +1619,10 @@ function baseFlatten$2(array4, depth, predicate, isStrict, result2) {
1619
1619
  result2 || (result2 = []);
1620
1620
  while (++index2 < length) {
1621
1621
  var value = array4[index2];
1622
- if (predicate(value)) {
1623
- {
1622
+ if (depth > 0 && predicate(value)) {
1623
+ if (depth > 1) {
1624
+ baseFlatten$2(value, depth - 1, predicate, isStrict, result2);
1625
+ } else {
1624
1626
  arrayPush$5(result2, value);
1625
1627
  }
1626
1628
  } else {
@@ -1631,7 +1633,7 @@ function baseFlatten$2(array4, depth, predicate, isStrict, result2) {
1631
1633
  }
1632
1634
  function flatten$1(array4) {
1633
1635
  var length = array4 == null ? 0 : array4.length;
1634
- return length ? baseFlatten$2(array4) : [];
1636
+ return length ? baseFlatten$2(array4, 1) : [];
1635
1637
  }
1636
1638
  function flatRest(func) {
1637
1639
  return setToString$2(overRest$2(func, void 0, flatten$1), func + "");
@@ -1765,6 +1767,9 @@ function baseGetAllKeys$3(object4, keysFunc, symbolsFunc) {
1765
1767
  function getAllKeys$3(object4) {
1766
1768
  return baseGetAllKeys$3(object4, keys$7, getSymbols$4);
1767
1769
  }
1770
+ function getAllKeysIn$2(object4) {
1771
+ return baseGetAllKeys$3(object4, keysIn$6, getSymbolsIn$3);
1772
+ }
1768
1773
  var DataView$2 = getNative$8(root$b, "DataView");
1769
1774
  var Promise$3 = getNative$8(root$b, "Promise");
1770
1775
  var Set$4 = getNative$8(root$b, "Set");
@@ -1809,7 +1814,7 @@ function cloneArrayBuffer$4(arrayBuffer) {
1809
1814
  return result2;
1810
1815
  }
1811
1816
  function cloneDataView$2(dataView, isDeep) {
1812
- var buffer2 = dataView.buffer;
1817
+ var buffer2 = isDeep ? cloneArrayBuffer$4(dataView.buffer) : dataView.buffer;
1813
1818
  return new dataView.constructor(buffer2, dataView.byteOffset, dataView.byteLength);
1814
1819
  }
1815
1820
  var reFlags$1 = /\w*$/;
@@ -1837,7 +1842,7 @@ function initCloneByTag$2(object4, tag, isDeep) {
1837
1842
  case dateTag$6:
1838
1843
  return new Ctor(+object4);
1839
1844
  case dataViewTag$7:
1840
- return cloneDataView$2(object4);
1845
+ return cloneDataView$2(object4, isDeep);
1841
1846
  case float32Tag$4:
1842
1847
  case float64Tag$4:
1843
1848
  case int8Tag$4:
@@ -1876,14 +1881,14 @@ function baseIsSet$2(value) {
1876
1881
  }
1877
1882
  var nodeIsSet$1 = nodeUtil$3 && nodeUtil$3.isSet;
1878
1883
  var isSet$2 = nodeIsSet$1 ? baseUnary$5(nodeIsSet$1) : baseIsSet$2;
1879
- var CLONE_DEEP_FLAG$2 = 1, CLONE_FLAT_FLAG$1 = 2;
1884
+ var CLONE_DEEP_FLAG$3 = 1, CLONE_FLAT_FLAG$1 = 2, CLONE_SYMBOLS_FLAG$4 = 4;
1880
1885
  var argsTag$5 = "[object Arguments]", arrayTag$4 = "[object Array]", boolTag$5 = "[object Boolean]", dateTag$5 = "[object Date]", errorTag$4 = "[object Error]", funcTag$3 = "[object Function]", genTag$2 = "[object GeneratorFunction]", mapTag$7 = "[object Map]", numberTag$5 = "[object Number]", objectTag$6 = "[object Object]", regexpTag$5 = "[object RegExp]", setTag$7 = "[object Set]", stringTag$5 = "[object String]", symbolTag$5 = "[object Symbol]", weakMapTag$3 = "[object WeakMap]";
1881
1886
  var arrayBufferTag$5 = "[object ArrayBuffer]", dataViewTag$6 = "[object DataView]", float32Tag$3 = "[object Float32Array]", float64Tag$3 = "[object Float64Array]", int8Tag$3 = "[object Int8Array]", int16Tag$3 = "[object Int16Array]", int32Tag$3 = "[object Int32Array]", uint8Tag$3 = "[object Uint8Array]", uint8ClampedTag$3 = "[object Uint8ClampedArray]", uint16Tag$3 = "[object Uint16Array]", uint32Tag$3 = "[object Uint32Array]";
1882
1887
  var cloneableTags$1 = {};
1883
1888
  cloneableTags$1[argsTag$5] = cloneableTags$1[arrayTag$4] = cloneableTags$1[arrayBufferTag$5] = cloneableTags$1[dataViewTag$6] = cloneableTags$1[boolTag$5] = cloneableTags$1[dateTag$5] = cloneableTags$1[float32Tag$3] = cloneableTags$1[float64Tag$3] = cloneableTags$1[int8Tag$3] = cloneableTags$1[int16Tag$3] = cloneableTags$1[int32Tag$3] = cloneableTags$1[mapTag$7] = cloneableTags$1[numberTag$5] = cloneableTags$1[objectTag$6] = cloneableTags$1[regexpTag$5] = cloneableTags$1[setTag$7] = cloneableTags$1[stringTag$5] = cloneableTags$1[symbolTag$5] = cloneableTags$1[uint8Tag$3] = cloneableTags$1[uint8ClampedTag$3] = cloneableTags$1[uint16Tag$3] = cloneableTags$1[uint32Tag$3] = true;
1884
1889
  cloneableTags$1[errorTag$4] = cloneableTags$1[funcTag$3] = cloneableTags$1[weakMapTag$3] = false;
1885
1890
  function baseClone$2(value, bitmask, customizer, key2, object4, stack) {
1886
- var result2, isDeep = bitmask & CLONE_DEEP_FLAG$2, isFlat = bitmask & CLONE_FLAT_FLAG$1;
1891
+ var result2, isDeep = bitmask & CLONE_DEEP_FLAG$3, isFlat = bitmask & CLONE_FLAT_FLAG$1, isFull = bitmask & CLONE_SYMBOLS_FLAG$4;
1887
1892
  if (result2 !== void 0) {
1888
1893
  return result2;
1889
1894
  }
@@ -1893,7 +1898,7 @@ function baseClone$2(value, bitmask, customizer, key2, object4, stack) {
1893
1898
  var isArr = isArray$b(value);
1894
1899
  if (isArr) {
1895
1900
  result2 = initCloneArray$2(value);
1896
- {
1901
+ if (!isDeep) {
1897
1902
  return copyArray$3(value, result2);
1898
1903
  }
1899
1904
  } else {
@@ -1902,8 +1907,8 @@ function baseClone$2(value, bitmask, customizer, key2, object4, stack) {
1902
1907
  return cloneBuffer$2(value, isDeep);
1903
1908
  }
1904
1909
  if (tag == objectTag$6 || tag == argsTag$5 || isFunc && !object4) {
1905
- result2 = isFunc ? {} : initCloneObject$3(value);
1906
- {
1910
+ result2 = isFlat || isFunc ? {} : initCloneObject$3(value);
1911
+ if (!isDeep) {
1907
1912
  return isFlat ? copySymbolsIn$2(value, baseAssignIn$2(result2, value)) : copySymbols$2(value, baseAssign$2(result2, value));
1908
1913
  }
1909
1914
  } else {
@@ -1928,7 +1933,7 @@ function baseClone$2(value, bitmask, customizer, key2, object4, stack) {
1928
1933
  result2.set(key3, baseClone$2(subValue, bitmask, customizer, key3, value, stack));
1929
1934
  });
1930
1935
  }
1931
- var keysFunc = getAllKeys$3;
1936
+ var keysFunc = isFull ? isFlat ? getAllKeysIn$2 : getAllKeys$3 : isFlat ? keysIn$6 : keys$7;
1932
1937
  var props = isArr ? void 0 : keysFunc(value);
1933
1938
  arrayEach$2(props || value, function(subValue, key3) {
1934
1939
  if (props) {
@@ -1939,9 +1944,13 @@ function baseClone$2(value, bitmask, customizer, key2, object4, stack) {
1939
1944
  });
1940
1945
  return result2;
1941
1946
  }
1942
- var CLONE_SYMBOLS_FLAG$2 = 4;
1947
+ var CLONE_SYMBOLS_FLAG$3 = 4;
1943
1948
  function clone$1(value) {
1944
- return baseClone$2(value, CLONE_SYMBOLS_FLAG$2);
1949
+ return baseClone$2(value, CLONE_SYMBOLS_FLAG$3);
1950
+ }
1951
+ var CLONE_DEEP_FLAG$2 = 1, CLONE_SYMBOLS_FLAG$2 = 4;
1952
+ function cloneDeep$2(value) {
1953
+ return baseClone$2(value, CLONE_DEEP_FLAG$2 | CLONE_SYMBOLS_FLAG$2);
1945
1954
  }
1946
1955
  var HASH_UNDEFINED$3 = "__lodash_hash_undefined__";
1947
1956
  function setCacheAdd$2(value) {
@@ -2486,6 +2495,11 @@ function findLastIndex(array4, predicate, fromIndex) {
2486
2495
  var index2 = length - 1;
2487
2496
  return baseFindIndex$2(array4, baseIteratee(predicate), index2);
2488
2497
  }
2498
+ var INFINITY$1 = 1 / 0;
2499
+ function flattenDeep(array4) {
2500
+ var length = array4 == null ? 0 : array4.length;
2501
+ return length ? baseFlatten$2(array4, INFINITY$1) : [];
2502
+ }
2489
2503
  function fromPairs(pairs) {
2490
2504
  var index2 = -1, length = pairs == null ? 0 : pairs.length, result2 = {};
2491
2505
  while (++index2 < length) {
@@ -3493,12 +3507,12 @@ const iconProps = buildProps({
3493
3507
  type: String
3494
3508
  }
3495
3509
  });
3496
- const __default__$C = defineComponent({
3510
+ const __default__$F = defineComponent({
3497
3511
  name: "ElIcon",
3498
3512
  inheritAttrs: false
3499
3513
  });
3500
- const _sfc_main$2Q = /* @__PURE__ */ defineComponent({
3501
- ...__default__$C,
3514
+ const _sfc_main$2T = /* @__PURE__ */ defineComponent({
3515
+ ...__default__$F,
3502
3516
  props: iconProps,
3503
3517
  setup(__props) {
3504
3518
  const props = __props;
@@ -3522,7 +3536,7 @@ const _sfc_main$2Q = /* @__PURE__ */ defineComponent({
3522
3536
  };
3523
3537
  }
3524
3538
  });
3525
- var Icon$7 = /* @__PURE__ */ _export_sfc(_sfc_main$2Q, [["__file", "icon.vue"]]);
3539
+ var Icon$7 = /* @__PURE__ */ _export_sfc(_sfc_main$2T, [["__file", "icon.vue"]]);
3526
3540
  const ElIcon = withInstall(Icon$7);
3527
3541
  function useTimeout() {
3528
3542
  let timeoutHandle;
@@ -3682,6 +3696,22 @@ var caret_right_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ de
3682
3696
  }
3683
3697
  });
3684
3698
  var caret_right_default = caret_right_vue_vue_type_script_setup_true_lang_default;
3699
+ var check_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
3700
+ name: "Check",
3701
+ __name: "check",
3702
+ setup(__props) {
3703
+ return (_ctx7, _cache) => (openBlock(), createElementBlock("svg", {
3704
+ xmlns: "http://www.w3.org/2000/svg",
3705
+ viewBox: "0 0 1024 1024"
3706
+ }, [
3707
+ createElementVNode("path", {
3708
+ fill: "currentColor",
3709
+ d: "M406.656 706.944 195.84 496.256a32 32 0 1 0-45.248 45.248l256 256 512-512a32 32 0 0 0-45.248-45.248L406.592 706.944z"
3710
+ })
3711
+ ]));
3712
+ }
3713
+ });
3714
+ var check_default = check_vue_vue_type_script_setup_true_lang_default;
3685
3715
  var circle_check_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
3686
3716
  name: "CircleCheck",
3687
3717
  __name: "circle-check",
@@ -4245,6 +4275,15 @@ const isFocusable = (element2) => {
4245
4275
  }
4246
4276
  }
4247
4277
  };
4278
+ const isLeaf = (el) => !el.getAttribute("aria-owns");
4279
+ const getSibling = (el, distance, elClass) => {
4280
+ const { parentNode: parentNode2 } = el;
4281
+ if (!parentNode2)
4282
+ return null;
4283
+ const siblings = parentNode2.querySelectorAll(elClass);
4284
+ const index2 = Array.prototype.indexOf.call(siblings, el);
4285
+ return siblings[index2 + distance] || null;
4286
+ };
4248
4287
  const focusElement = (el, options) => {
4249
4288
  if (!el || !el.focus)
4250
4289
  return;
@@ -4258,6 +4297,12 @@ const focusElement = (el, options) => {
4258
4297
  el.removeAttribute("tabindex");
4259
4298
  }
4260
4299
  };
4300
+ const focusNode = (el) => {
4301
+ if (!el)
4302
+ return;
4303
+ focusElement(el);
4304
+ !isLeaf(el) && el.click();
4305
+ };
4261
4306
  function useFocusController(target, {
4262
4307
  disabled,
4263
4308
  beforeFocus,
@@ -4388,12 +4433,12 @@ function useCursor(input) {
4388
4433
  return [recordCursor, setCursor];
4389
4434
  }
4390
4435
  const COMPONENT_NAME$9 = "ElInput";
4391
- const __default__$B = defineComponent({
4436
+ const __default__$E = defineComponent({
4392
4437
  name: COMPONENT_NAME$9,
4393
4438
  inheritAttrs: false
4394
4439
  });
4395
- const _sfc_main$2P = /* @__PURE__ */ defineComponent({
4396
- ...__default__$B,
4440
+ const _sfc_main$2S = /* @__PURE__ */ defineComponent({
4441
+ ...__default__$E,
4397
4442
  props: inputProps,
4398
4443
  emits: inputEmits,
4399
4444
  setup(__props, { expose, emit }) {
@@ -4802,7 +4847,7 @@ const _sfc_main$2P = /* @__PURE__ */ defineComponent({
4802
4847
  };
4803
4848
  }
4804
4849
  });
4805
- var Input = /* @__PURE__ */ _export_sfc(_sfc_main$2P, [["__file", "input.vue"]]);
4850
+ var Input = /* @__PURE__ */ _export_sfc(_sfc_main$2S, [["__file", "input.vue"]]);
4806
4851
  const ElInput = withInstall(Input);
4807
4852
  const GAP = 4;
4808
4853
  const BAR_MAP = {
@@ -4847,7 +4892,7 @@ const thumbProps = buildProps({
4847
4892
  always: Boolean
4848
4893
  });
4849
4894
  const COMPONENT_NAME$8 = "Thumb";
4850
- const _sfc_main$2O = /* @__PURE__ */ defineComponent({
4895
+ const _sfc_main$2R = /* @__PURE__ */ defineComponent({
4851
4896
  __name: "thumb",
4852
4897
  props: thumbProps,
4853
4898
  setup(__props) {
@@ -4976,7 +5021,7 @@ const _sfc_main$2O = /* @__PURE__ */ defineComponent({
4976
5021
  };
4977
5022
  }
4978
5023
  });
4979
- var Thumb = /* @__PURE__ */ _export_sfc(_sfc_main$2O, [["__file", "thumb.vue"]]);
5024
+ var Thumb = /* @__PURE__ */ _export_sfc(_sfc_main$2R, [["__file", "thumb.vue"]]);
4980
5025
  const barProps = buildProps({
4981
5026
  always: {
4982
5027
  type: Boolean,
@@ -4987,7 +5032,7 @@ const barProps = buildProps({
4987
5032
  required: true
4988
5033
  }
4989
5034
  });
4990
- const _sfc_main$2N = /* @__PURE__ */ defineComponent({
5035
+ const _sfc_main$2Q = /* @__PURE__ */ defineComponent({
4991
5036
  __name: "bar",
4992
5037
  props: barProps,
4993
5038
  setup(__props, { expose }) {
@@ -5045,7 +5090,7 @@ const _sfc_main$2N = /* @__PURE__ */ defineComponent({
5045
5090
  };
5046
5091
  }
5047
5092
  });
5048
- var Bar = /* @__PURE__ */ _export_sfc(_sfc_main$2N, [["__file", "bar.vue"]]);
5093
+ var Bar = /* @__PURE__ */ _export_sfc(_sfc_main$2Q, [["__file", "bar.vue"]]);
5049
5094
  const scrollbarProps = buildProps({
5050
5095
  distance: {
5051
5096
  type: Number,
@@ -5102,11 +5147,11 @@ const scrollbarEmits = {
5102
5147
  }) => [scrollTop, scrollLeft].every(isNumber)
5103
5148
  };
5104
5149
  const COMPONENT_NAME$7 = "ElScrollbar";
5105
- const __default__$A = defineComponent({
5150
+ const __default__$D = defineComponent({
5106
5151
  name: COMPONENT_NAME$7
5107
5152
  });
5108
- const _sfc_main$2M = /* @__PURE__ */ defineComponent({
5109
- ...__default__$A,
5153
+ const _sfc_main$2P = /* @__PURE__ */ defineComponent({
5154
+ ...__default__$D,
5110
5155
  props: scrollbarProps,
5111
5156
  emits: scrollbarEmits,
5112
5157
  setup(__props, { expose, emit }) {
@@ -5314,7 +5359,7 @@ const _sfc_main$2M = /* @__PURE__ */ defineComponent({
5314
5359
  };
5315
5360
  }
5316
5361
  });
5317
- var Scrollbar = /* @__PURE__ */ _export_sfc(_sfc_main$2M, [["__file", "scrollbar.vue"]]);
5362
+ var Scrollbar = /* @__PURE__ */ _export_sfc(_sfc_main$2P, [["__file", "scrollbar.vue"]]);
5318
5363
  const ElScrollbar = withInstall(Scrollbar);
5319
5364
  const POPPER_INJECTION_KEY = Symbol("popper");
5320
5365
  const POPPER_CONTENT_INJECTION_KEY = Symbol("popperContent");
@@ -5335,12 +5380,12 @@ const popperProps = buildProps({
5335
5380
  default: "tooltip"
5336
5381
  }
5337
5382
  });
5338
- const __default__$z = defineComponent({
5383
+ const __default__$C = defineComponent({
5339
5384
  name: "ElPopper",
5340
5385
  inheritAttrs: false
5341
5386
  });
5342
- const _sfc_main$2L = /* @__PURE__ */ defineComponent({
5343
- ...__default__$z,
5387
+ const _sfc_main$2O = /* @__PURE__ */ defineComponent({
5388
+ ...__default__$C,
5344
5389
  props: popperProps,
5345
5390
  setup(__props, { expose }) {
5346
5391
  const props = __props;
@@ -5363,13 +5408,13 @@ const _sfc_main$2L = /* @__PURE__ */ defineComponent({
5363
5408
  };
5364
5409
  }
5365
5410
  });
5366
- var Popper = /* @__PURE__ */ _export_sfc(_sfc_main$2L, [["__file", "popper.vue"]]);
5367
- const __default__$y = defineComponent({
5411
+ var Popper = /* @__PURE__ */ _export_sfc(_sfc_main$2O, [["__file", "popper.vue"]]);
5412
+ const __default__$B = defineComponent({
5368
5413
  name: "ElPopperArrow",
5369
5414
  inheritAttrs: false
5370
5415
  });
5371
- const _sfc_main$2K = /* @__PURE__ */ defineComponent({
5372
- ...__default__$y,
5416
+ const _sfc_main$2N = /* @__PURE__ */ defineComponent({
5417
+ ...__default__$B,
5373
5418
  setup(__props, { expose }) {
5374
5419
  const ns = useNamespace("popper");
5375
5420
  const { arrowRef, arrowStyle } = inject(POPPER_CONTENT_INJECTION_KEY, void 0);
@@ -5390,7 +5435,7 @@ const _sfc_main$2K = /* @__PURE__ */ defineComponent({
5390
5435
  };
5391
5436
  }
5392
5437
  });
5393
- var ElPopperArrow = /* @__PURE__ */ _export_sfc(_sfc_main$2K, [["__file", "arrow.vue"]]);
5438
+ var ElPopperArrow = /* @__PURE__ */ _export_sfc(_sfc_main$2N, [["__file", "arrow.vue"]]);
5394
5439
  const popperTriggerProps = buildProps({
5395
5440
  virtualRef: {
5396
5441
  type: definePropType(Object)
@@ -5494,12 +5539,12 @@ function wrapTextContent(s2) {
5494
5539
  "class": ns.e("content")
5495
5540
  }, [s2]);
5496
5541
  }
5497
- const __default__$x = defineComponent({
5542
+ const __default__$A = defineComponent({
5498
5543
  name: "ElPopperTrigger",
5499
5544
  inheritAttrs: false
5500
5545
  });
5501
- const _sfc_main$2J = /* @__PURE__ */ defineComponent({
5502
- ...__default__$x,
5546
+ const _sfc_main$2M = /* @__PURE__ */ defineComponent({
5547
+ ...__default__$A,
5503
5548
  props: popperTriggerProps,
5504
5549
  setup(__props, { expose }) {
5505
5550
  const props = __props;
@@ -5610,7 +5655,7 @@ const _sfc_main$2J = /* @__PURE__ */ defineComponent({
5610
5655
  };
5611
5656
  }
5612
5657
  });
5613
- var ElPopperTrigger = /* @__PURE__ */ _export_sfc(_sfc_main$2J, [["__file", "trigger.vue"]]);
5658
+ var ElPopperTrigger = /* @__PURE__ */ _export_sfc(_sfc_main$2M, [["__file", "trigger.vue"]]);
5614
5659
  const FOCUS_AFTER_TRAPPED = "focus-trap.focus-after-trapped";
5615
5660
  const FOCUS_AFTER_RELEASED = "focus-trap.focus-after-released";
5616
5661
  const FOCUSOUT_PREVENTED = "focus-trap.focusout-prevented";
@@ -5795,7 +5840,7 @@ const useEscapeKeydown = (handler2) => {
5795
5840
  }
5796
5841
  });
5797
5842
  };
5798
- const _sfc_main$2I = defineComponent({
5843
+ const _sfc_main$2L = defineComponent({
5799
5844
  name: "ElFocusTrap",
5800
5845
  inheritAttrs: false,
5801
5846
  props: {
@@ -6042,7 +6087,7 @@ const _sfc_main$2I = defineComponent({
6042
6087
  function _sfc_render$i(_ctx7, _cache, $props, $setup, $data, $options) {
6043
6088
  return renderSlot(_ctx7.$slots, "default", { handleKeydown: _ctx7.onKeydown });
6044
6089
  }
6045
- var ElFocusTrap = /* @__PURE__ */ _export_sfc(_sfc_main$2I, [["render", _sfc_render$i], ["__file", "focus-trap.vue"]]);
6090
+ var ElFocusTrap = /* @__PURE__ */ _export_sfc(_sfc_main$2L, [["render", _sfc_render$i], ["__file", "focus-trap.vue"]]);
6046
6091
  var E$1 = "top", R = "bottom", W = "right", P$1 = "left", me = "auto", G$1 = [E$1, R, W, P$1], U = "start", J$1 = "end", Xe = "clippingParents", je = "viewport", K = "popper", Ye = "reference", De = G$1.reduce(function(t2, e3) {
6047
6092
  return t2.concat([e3 + "-" + U, e3 + "-" + J$1]);
6048
6093
  }, []), Ee = [].concat(G$1, [me]).reduce(function(t2, e3) {
@@ -6951,11 +6996,11 @@ const usePopperContentDOM = (props, {
6951
6996
  updateZIndex
6952
6997
  };
6953
6998
  };
6954
- const __default__$w = defineComponent({
6999
+ const __default__$z = defineComponent({
6955
7000
  name: "ElPopperContent"
6956
7001
  });
6957
- const _sfc_main$2H = /* @__PURE__ */ defineComponent({
6958
- ...__default__$w,
7002
+ const _sfc_main$2K = /* @__PURE__ */ defineComponent({
7003
+ ...__default__$z,
6959
7004
  props: popperContentProps,
6960
7005
  emits: popperContentEmits,
6961
7006
  setup(__props, { expose, emit }) {
@@ -7069,7 +7114,7 @@ const _sfc_main$2H = /* @__PURE__ */ defineComponent({
7069
7114
  };
7070
7115
  }
7071
7116
  });
7072
- var ElPopperContent = /* @__PURE__ */ _export_sfc(_sfc_main$2H, [["__file", "content.vue"]]);
7117
+ var ElPopperContent = /* @__PURE__ */ _export_sfc(_sfc_main$2K, [["__file", "content.vue"]]);
7073
7118
  const ElPopper = withInstall(Popper);
7074
7119
  const TOOLTIP_INJECTION_KEY = Symbol("elTooltip");
7075
7120
  const teleportProps = buildProps({
@@ -7286,11 +7331,11 @@ const composeEventHandlers = (theirsHandler, oursHandler, { checkForDefaultPreve
7286
7331
  const whenMouse = (handler2) => {
7287
7332
  return (e3) => e3.pointerType === "mouse" ? handler2(e3) : void 0;
7288
7333
  };
7289
- const __default__$v = defineComponent({
7334
+ const __default__$y = defineComponent({
7290
7335
  name: "ElTooltipTrigger"
7291
7336
  });
7292
- const _sfc_main$2G = /* @__PURE__ */ defineComponent({
7293
- ...__default__$v,
7337
+ const _sfc_main$2J = /* @__PURE__ */ defineComponent({
7338
+ ...__default__$y,
7294
7339
  props: useTooltipTriggerProps,
7295
7340
  setup(__props, { expose }) {
7296
7341
  const props = __props;
@@ -7356,8 +7401,8 @@ const _sfc_main$2G = /* @__PURE__ */ defineComponent({
7356
7401
  };
7357
7402
  }
7358
7403
  });
7359
- var ElTooltipTrigger = /* @__PURE__ */ _export_sfc(_sfc_main$2G, [["__file", "trigger.vue"]]);
7360
- const _sfc_main$2F = /* @__PURE__ */ defineComponent({
7404
+ var ElTooltipTrigger = /* @__PURE__ */ _export_sfc(_sfc_main$2J, [["__file", "trigger.vue"]]);
7405
+ const _sfc_main$2I = /* @__PURE__ */ defineComponent({
7361
7406
  __name: "teleport",
7362
7407
  props: teleportProps,
7363
7408
  setup(__props) {
@@ -7371,7 +7416,7 @@ const _sfc_main$2F = /* @__PURE__ */ defineComponent({
7371
7416
  };
7372
7417
  }
7373
7418
  });
7374
- var Teleport = /* @__PURE__ */ _export_sfc(_sfc_main$2F, [["__file", "teleport.vue"]]);
7419
+ var Teleport = /* @__PURE__ */ _export_sfc(_sfc_main$2I, [["__file", "teleport.vue"]]);
7375
7420
  const ElTeleport = withInstall(Teleport);
7376
7421
  const usePopperContainerId = () => {
7377
7422
  const namespace = useGetDerivedNamespace();
@@ -7405,6 +7450,7 @@ const usePopperContainer = () => {
7405
7450
  selector
7406
7451
  };
7407
7452
  };
7453
+ const unique = (arr) => [...new Set(arr)];
7408
7454
  const extractFirst = (arr) => {
7409
7455
  return isArray$c(arr) ? arr[0] : arr;
7410
7456
  };
@@ -7413,12 +7459,12 @@ const castArray = (arr) => {
7413
7459
  return [];
7414
7460
  return isArray$c(arr) ? arr : [arr];
7415
7461
  };
7416
- const __default__$u = defineComponent({
7462
+ const __default__$x = defineComponent({
7417
7463
  name: "ElTooltipContent",
7418
7464
  inheritAttrs: false
7419
7465
  });
7420
- const _sfc_main$2E = /* @__PURE__ */ defineComponent({
7421
- ...__default__$u,
7466
+ const _sfc_main$2H = /* @__PURE__ */ defineComponent({
7467
+ ...__default__$x,
7422
7468
  props: useTooltipContentProps,
7423
7469
  setup(__props, { expose }) {
7424
7470
  const props = __props;
@@ -7595,12 +7641,12 @@ const _sfc_main$2E = /* @__PURE__ */ defineComponent({
7595
7641
  };
7596
7642
  }
7597
7643
  });
7598
- var ElTooltipContent = /* @__PURE__ */ _export_sfc(_sfc_main$2E, [["__file", "content.vue"]]);
7599
- const __default__$t = defineComponent({
7644
+ var ElTooltipContent = /* @__PURE__ */ _export_sfc(_sfc_main$2H, [["__file", "content.vue"]]);
7645
+ const __default__$w = defineComponent({
7600
7646
  name: "ElTooltip"
7601
7647
  });
7602
- const _sfc_main$2D = /* @__PURE__ */ defineComponent({
7603
- ...__default__$t,
7648
+ const _sfc_main$2G = /* @__PURE__ */ defineComponent({
7649
+ ...__default__$w,
7604
7650
  props: useTooltipProps,
7605
7651
  emits: tooltipEmits,
7606
7652
  setup(__props, { expose, emit }) {
@@ -7749,7 +7795,7 @@ const _sfc_main$2D = /* @__PURE__ */ defineComponent({
7749
7795
  };
7750
7796
  }
7751
7797
  });
7752
- var Tooltip = /* @__PURE__ */ _export_sfc(_sfc_main$2D, [["__file", "tooltip.vue"]]);
7798
+ var Tooltip = /* @__PURE__ */ _export_sfc(_sfc_main$2G, [["__file", "tooltip.vue"]]);
7753
7799
  const ElTooltip = withInstall(Tooltip);
7754
7800
  const autocompleteProps = buildProps({
7755
7801
  ...inputProps,
@@ -7806,12 +7852,12 @@ const autocompleteEmits = {
7806
7852
  select: (item) => isObject$g(item)
7807
7853
  };
7808
7854
  const COMPONENT_NAME$6 = "ElAutocomplete";
7809
- const __default__$s = defineComponent({
7855
+ const __default__$v = defineComponent({
7810
7856
  name: COMPONENT_NAME$6,
7811
7857
  inheritAttrs: false
7812
7858
  });
7813
- const _sfc_main$2C = /* @__PURE__ */ defineComponent({
7814
- ...__default__$s,
7859
+ const _sfc_main$2F = /* @__PURE__ */ defineComponent({
7860
+ ...__default__$v,
7815
7861
  props: autocompleteProps,
7816
7862
  emits: autocompleteEmits,
7817
7863
  setup(__props, { expose, emit }) {
@@ -8184,7 +8230,7 @@ const _sfc_main$2C = /* @__PURE__ */ defineComponent({
8184
8230
  };
8185
8231
  }
8186
8232
  });
8187
- var Autocomplete = /* @__PURE__ */ _export_sfc(_sfc_main$2C, [["__file", "autocomplete.vue"]]);
8233
+ var Autocomplete = /* @__PURE__ */ _export_sfc(_sfc_main$2F, [["__file", "autocomplete.vue"]]);
8188
8234
  const ElAutocomplete = withInstall(Autocomplete);
8189
8235
  const buttonGroupContextKey = Symbol("buttonGroupContextKey");
8190
8236
  const useDeprecated = ({ from: from2, replacement, scope, version: version2, ref: ref2, type: type4 = "API" }, condition) => {
@@ -9276,11 +9322,11 @@ function useButtonCustomStyle(props) {
9276
9322
  return styles2;
9277
9323
  });
9278
9324
  }
9279
- const __default__$r = defineComponent({
9325
+ const __default__$u = defineComponent({
9280
9326
  name: "ElButton"
9281
9327
  });
9282
- const _sfc_main$2B = /* @__PURE__ */ defineComponent({
9283
- ...__default__$r,
9328
+ const _sfc_main$2E = /* @__PURE__ */ defineComponent({
9329
+ ...__default__$u,
9284
9330
  props: buttonProps,
9285
9331
  emits: buttonEmits,
9286
9332
  setup(__props, { expose, emit }) {
@@ -9357,16 +9403,16 @@ const _sfc_main$2B = /* @__PURE__ */ defineComponent({
9357
9403
  };
9358
9404
  }
9359
9405
  });
9360
- var Button = /* @__PURE__ */ _export_sfc(_sfc_main$2B, [["__file", "button.vue"]]);
9406
+ var Button = /* @__PURE__ */ _export_sfc(_sfc_main$2E, [["__file", "button.vue"]]);
9361
9407
  const buttonGroupProps = {
9362
9408
  size: buttonProps.size,
9363
9409
  type: buttonProps.type
9364
9410
  };
9365
- const __default__$q = defineComponent({
9411
+ const __default__$t = defineComponent({
9366
9412
  name: "ElButtonGroup"
9367
9413
  });
9368
- const _sfc_main$2A = /* @__PURE__ */ defineComponent({
9369
- ...__default__$q,
9414
+ const _sfc_main$2D = /* @__PURE__ */ defineComponent({
9415
+ ...__default__$t,
9370
9416
  props: buttonGroupProps,
9371
9417
  setup(__props) {
9372
9418
  const props = __props;
@@ -9384,7 +9430,7 @@ const _sfc_main$2A = /* @__PURE__ */ defineComponent({
9384
9430
  };
9385
9431
  }
9386
9432
  });
9387
- var ButtonGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2A, [["__file", "button-group.vue"]]);
9433
+ var ButtonGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2D, [["__file", "button-group.vue"]]);
9388
9434
  const ElButton = withInstall(Button, {
9389
9435
  ButtonGroup
9390
9436
  });
@@ -10105,11 +10151,11 @@ const useCheckbox = (props, slots) => {
10105
10151
  onClickRoot
10106
10152
  };
10107
10153
  };
10108
- const __default__$p = defineComponent({
10154
+ const __default__$s = defineComponent({
10109
10155
  name: "ElCheckbox"
10110
10156
  });
10111
- const _sfc_main$2z = /* @__PURE__ */ defineComponent({
10112
- ...__default__$p,
10157
+ const _sfc_main$2C = /* @__PURE__ */ defineComponent({
10158
+ ...__default__$s,
10113
10159
  props: checkboxProps,
10114
10160
  emits: checkboxEmits,
10115
10161
  setup(__props) {
@@ -10206,12 +10252,12 @@ const _sfc_main$2z = /* @__PURE__ */ defineComponent({
10206
10252
  };
10207
10253
  }
10208
10254
  });
10209
- var Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main$2z, [["__file", "checkbox.vue"]]);
10210
- const __default__$o = defineComponent({
10255
+ var Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main$2C, [["__file", "checkbox.vue"]]);
10256
+ const __default__$r = defineComponent({
10211
10257
  name: "ElCheckboxButton"
10212
10258
  });
10213
- const _sfc_main$2y = /* @__PURE__ */ defineComponent({
10214
- ...__default__$o,
10259
+ const _sfc_main$2B = /* @__PURE__ */ defineComponent({
10260
+ ...__default__$r,
10215
10261
  props: checkboxProps,
10216
10262
  emits: checkboxEmits,
10217
10263
  setup(__props) {
@@ -10292,7 +10338,7 @@ const _sfc_main$2y = /* @__PURE__ */ defineComponent({
10292
10338
  };
10293
10339
  }
10294
10340
  });
10295
- var CheckboxButton = /* @__PURE__ */ _export_sfc(_sfc_main$2y, [["__file", "checkbox-button.vue"]]);
10341
+ var CheckboxButton = /* @__PURE__ */ _export_sfc(_sfc_main$2B, [["__file", "checkbox-button.vue"]]);
10296
10342
  const checkboxGroupProps = buildProps({
10297
10343
  modelValue: {
10298
10344
  type: definePropType(Array),
@@ -10330,11 +10376,11 @@ const checkboxDefaultProps = {
10330
10376
  value: "value",
10331
10377
  disabled: "disabled"
10332
10378
  };
10333
- const __default__$n = defineComponent({
10379
+ const __default__$q = defineComponent({
10334
10380
  name: "ElCheckboxGroup"
10335
10381
  });
10336
- const _sfc_main$2x = /* @__PURE__ */ defineComponent({
10337
- ...__default__$n,
10382
+ const _sfc_main$2A = /* @__PURE__ */ defineComponent({
10383
+ ...__default__$q,
10338
10384
  props: checkboxGroupProps,
10339
10385
  emits: checkboxGroupEmits,
10340
10386
  setup(__props, { emit }) {
@@ -10408,7 +10454,7 @@ const _sfc_main$2x = /* @__PURE__ */ defineComponent({
10408
10454
  };
10409
10455
  }
10410
10456
  });
10411
- var CheckboxGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2x, [["__file", "checkbox-group.vue"]]);
10457
+ var CheckboxGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2A, [["__file", "checkbox-group.vue"]]);
10412
10458
  const ElCheckbox = withInstall(Checkbox, {
10413
10459
  CheckboxButton,
10414
10460
  CheckboxGroup
@@ -10492,11 +10538,11 @@ const useRadio = (props, emit) => {
10492
10538
  actualValue
10493
10539
  };
10494
10540
  };
10495
- const __default__$m = defineComponent({
10541
+ const __default__$p = defineComponent({
10496
10542
  name: "ElRadio"
10497
10543
  });
10498
- const _sfc_main$2w = /* @__PURE__ */ defineComponent({
10499
- ...__default__$m,
10544
+ const _sfc_main$2z = /* @__PURE__ */ defineComponent({
10545
+ ...__default__$p,
10500
10546
  props: radioProps,
10501
10547
  emits: radioEmits,
10502
10548
  setup(__props, { emit }) {
@@ -10560,15 +10606,15 @@ const _sfc_main$2w = /* @__PURE__ */ defineComponent({
10560
10606
  };
10561
10607
  }
10562
10608
  });
10563
- var Radio = /* @__PURE__ */ _export_sfc(_sfc_main$2w, [["__file", "radio.vue"]]);
10609
+ var Radio = /* @__PURE__ */ _export_sfc(_sfc_main$2z, [["__file", "radio.vue"]]);
10564
10610
  const radioButtonProps = buildProps({
10565
10611
  ...radioPropsBase
10566
10612
  });
10567
- const __default__$l = defineComponent({
10613
+ const __default__$o = defineComponent({
10568
10614
  name: "ElRadioButton"
10569
10615
  });
10570
- const _sfc_main$2v = /* @__PURE__ */ defineComponent({
10571
- ...__default__$l,
10616
+ const _sfc_main$2y = /* @__PURE__ */ defineComponent({
10617
+ ...__default__$o,
10572
10618
  props: radioButtonProps,
10573
10619
  setup(__props) {
10574
10620
  const props = __props;
@@ -10623,7 +10669,7 @@ const _sfc_main$2v = /* @__PURE__ */ defineComponent({
10623
10669
  };
10624
10670
  }
10625
10671
  });
10626
- var RadioButton = /* @__PURE__ */ _export_sfc(_sfc_main$2v, [["__file", "radio-button.vue"]]);
10672
+ var RadioButton = /* @__PURE__ */ _export_sfc(_sfc_main$2y, [["__file", "radio-button.vue"]]);
10627
10673
  const radioGroupProps = buildProps({
10628
10674
  id: {
10629
10675
  type: String,
@@ -10666,11 +10712,11 @@ const radioDefaultProps = {
10666
10712
  value: "value",
10667
10713
  disabled: "disabled"
10668
10714
  };
10669
- const __default__$k = defineComponent({
10715
+ const __default__$n = defineComponent({
10670
10716
  name: "ElRadioGroup"
10671
10717
  });
10672
- const _sfc_main$2u = /* @__PURE__ */ defineComponent({
10673
- ...__default__$k,
10718
+ const _sfc_main$2x = /* @__PURE__ */ defineComponent({
10719
+ ...__default__$n,
10674
10720
  props: radioGroupProps,
10675
10721
  emits: radioGroupEmits,
10676
10722
  setup(__props, { emit }) {
@@ -10737,13 +10783,869 @@ const _sfc_main$2u = /* @__PURE__ */ defineComponent({
10737
10783
  };
10738
10784
  }
10739
10785
  });
10740
- var RadioGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2u, [["__file", "radio-group.vue"]]);
10786
+ var RadioGroup = /* @__PURE__ */ _export_sfc(_sfc_main$2x, [["__file", "radio-group.vue"]]);
10741
10787
  const ElRadio = withInstall(Radio, {
10742
10788
  RadioButton,
10743
10789
  RadioGroup
10744
10790
  });
10745
10791
  const ElRadioGroup = withNoopInstall(RadioGroup);
10746
10792
  const ElRadioButton = withNoopInstall(RadioButton);
10793
+ const CASCADER_PANEL_INJECTION_KEY = Symbol();
10794
+ function isVNodeEmpty(vnodes) {
10795
+ return !!(isArray$c(vnodes) ? vnodes.every(({
10796
+ type: type4
10797
+ }) => type4 === Comment) : (vnodes == null ? void 0 : vnodes.type) === Comment);
10798
+ }
10799
+ var NodeContent$1 = defineComponent({
10800
+ name: "NodeContent",
10801
+ props: {
10802
+ node: {
10803
+ type: Object,
10804
+ required: true
10805
+ }
10806
+ },
10807
+ setup(props) {
10808
+ const ns = useNamespace("cascader-node");
10809
+ const {
10810
+ renderLabelFn
10811
+ } = inject(CASCADER_PANEL_INJECTION_KEY);
10812
+ const {
10813
+ node: node2
10814
+ } = props;
10815
+ const {
10816
+ data: data2,
10817
+ label: nodeLabel
10818
+ } = node2;
10819
+ const label = () => {
10820
+ const renderLabel = renderLabelFn == null ? void 0 : renderLabelFn({
10821
+ node: node2,
10822
+ data: data2
10823
+ });
10824
+ return isVNodeEmpty(renderLabel) ? nodeLabel : renderLabel != null ? renderLabel : nodeLabel;
10825
+ };
10826
+ return () => createVNode("span", {
10827
+ "class": ns.e("label")
10828
+ }, [label()]);
10829
+ }
10830
+ });
10831
+ const __default__$m = defineComponent({
10832
+ name: "ElCascaderNode"
10833
+ });
10834
+ const _sfc_main$2w = /* @__PURE__ */ defineComponent({
10835
+ ...__default__$m,
10836
+ props: {
10837
+ node: {
10838
+ type: Object,
10839
+ required: true
10840
+ },
10841
+ menuId: String
10842
+ },
10843
+ emits: ["expand"],
10844
+ setup(__props, { emit }) {
10845
+ const props = __props;
10846
+ const panel = inject(CASCADER_PANEL_INJECTION_KEY);
10847
+ const ns = useNamespace("cascader-node");
10848
+ const isHoverMenu = computed(() => panel.isHoverMenu);
10849
+ const multiple = computed(() => panel.config.multiple);
10850
+ const checkStrictly = computed(() => panel.config.checkStrictly);
10851
+ const showPrefix = computed(() => panel.config.showPrefix);
10852
+ const checkedNodeId = computed(() => {
10853
+ var _a2;
10854
+ return (_a2 = panel.checkedNodes[0]) == null ? void 0 : _a2.uid;
10855
+ });
10856
+ const isDisabled = computed(() => props.node.isDisabled);
10857
+ const isLeaf2 = computed(() => props.node.isLeaf);
10858
+ const expandable = computed(() => checkStrictly.value && !isLeaf2.value || !isDisabled.value);
10859
+ const inExpandingPath = computed(() => isInPath(panel.expandingNode));
10860
+ const inCheckedPath = computed(() => checkStrictly.value && panel.checkedNodes.some(isInPath));
10861
+ const isInPath = (node2) => {
10862
+ var _a2;
10863
+ const { level, uid: uid2 } = props.node;
10864
+ return ((_a2 = node2 == null ? void 0 : node2.pathNodes[level - 1]) == null ? void 0 : _a2.uid) === uid2;
10865
+ };
10866
+ const doExpand = () => {
10867
+ if (inExpandingPath.value)
10868
+ return;
10869
+ panel.expandNode(props.node);
10870
+ };
10871
+ const doCheck = (checked) => {
10872
+ const { node: node2 } = props;
10873
+ if (checked === node2.checked)
10874
+ return;
10875
+ panel.handleCheckChange(node2, checked);
10876
+ };
10877
+ const doLoad = () => {
10878
+ panel.lazyLoad(props.node, () => {
10879
+ if (!isLeaf2.value)
10880
+ doExpand();
10881
+ });
10882
+ };
10883
+ const handleHoverExpand = (e3) => {
10884
+ if (!isHoverMenu.value)
10885
+ return;
10886
+ handleExpand();
10887
+ !isLeaf2.value && emit("expand", e3);
10888
+ };
10889
+ const handleExpand = () => {
10890
+ const { node: node2 } = props;
10891
+ if (!expandable.value || node2.loading)
10892
+ return;
10893
+ node2.loaded ? doExpand() : doLoad();
10894
+ };
10895
+ const handleClick2 = () => {
10896
+ if (isLeaf2.value && !isDisabled.value && !checkStrictly.value && !multiple.value) {
10897
+ handleCheck(true);
10898
+ } else if ((panel.config.checkOnClickNode && (multiple.value || checkStrictly.value) || isLeaf2.value && panel.config.checkOnClickLeaf) && !isDisabled.value) {
10899
+ handleSelectCheck(!props.node.checked);
10900
+ } else if (!isHoverMenu.value) {
10901
+ handleExpand();
10902
+ }
10903
+ };
10904
+ const handleSelectCheck = (checked) => {
10905
+ if (checkStrictly.value) {
10906
+ doCheck(checked);
10907
+ if (props.node.loaded) {
10908
+ doExpand();
10909
+ }
10910
+ } else {
10911
+ handleCheck(checked);
10912
+ }
10913
+ };
10914
+ const handleCheck = (checked) => {
10915
+ if (!props.node.loaded) {
10916
+ doLoad();
10917
+ } else {
10918
+ doCheck(checked);
10919
+ !checkStrictly.value && doExpand();
10920
+ }
10921
+ };
10922
+ return (_ctx7, _cache) => {
10923
+ return openBlock(), createElementBlock("li", {
10924
+ id: `${__props.menuId}-${__props.node.uid}`,
10925
+ role: "menuitem",
10926
+ "aria-haspopup": !unref(isLeaf2),
10927
+ "aria-owns": unref(isLeaf2) ? void 0 : __props.menuId,
10928
+ "aria-expanded": unref(inExpandingPath),
10929
+ tabindex: unref(expandable) ? -1 : void 0,
10930
+ class: normalizeClass([
10931
+ unref(ns).b(),
10932
+ unref(ns).is("selectable", unref(checkStrictly)),
10933
+ unref(ns).is("active", __props.node.checked),
10934
+ unref(ns).is("disabled", !unref(expandable)),
10935
+ unref(inExpandingPath) && "in-active-path",
10936
+ unref(inCheckedPath) && "in-checked-path"
10937
+ ]),
10938
+ onMouseenter: handleHoverExpand,
10939
+ onFocus: handleHoverExpand,
10940
+ onClick: handleClick2
10941
+ }, [
10942
+ createCommentVNode(" prefix "),
10943
+ unref(multiple) && unref(showPrefix) ? (openBlock(), createBlock(unref(ElCheckbox), {
10944
+ key: 0,
10945
+ "model-value": __props.node.checked,
10946
+ indeterminate: __props.node.indeterminate,
10947
+ disabled: unref(isDisabled),
10948
+ onClick: withModifiers(() => {
10949
+ }, ["stop"]),
10950
+ "onUpdate:modelValue": handleSelectCheck
10951
+ }, null, 8, ["model-value", "indeterminate", "disabled", "onClick"])) : unref(checkStrictly) && unref(showPrefix) ? (openBlock(), createBlock(unref(ElRadio), {
10952
+ key: 1,
10953
+ "model-value": unref(checkedNodeId),
10954
+ label: __props.node.uid,
10955
+ disabled: unref(isDisabled),
10956
+ "onUpdate:modelValue": handleSelectCheck,
10957
+ onClick: withModifiers(() => {
10958
+ }, ["stop"])
10959
+ }, {
10960
+ default: withCtx(() => [
10961
+ createCommentVNode("\n Add an empty element to avoid render label,\n do not use empty fragment here for https://github.com/vuejs/vue-next/pull/2485\n "),
10962
+ createElementVNode("span")
10963
+ ]),
10964
+ _: 1
10965
+ }, 8, ["model-value", "label", "disabled", "onClick"])) : unref(isLeaf2) && __props.node.checked ? (openBlock(), createBlock(unref(ElIcon), {
10966
+ key: 2,
10967
+ class: normalizeClass(unref(ns).e("prefix"))
10968
+ }, {
10969
+ default: withCtx(() => [
10970
+ createVNode(unref(check_default))
10971
+ ]),
10972
+ _: 1
10973
+ }, 8, ["class"])) : createCommentVNode("v-if", true),
10974
+ createCommentVNode(" content "),
10975
+ createVNode(unref(NodeContent$1), { node: __props.node }, null, 8, ["node"]),
10976
+ createCommentVNode(" postfix "),
10977
+ !unref(isLeaf2) ? (openBlock(), createElementBlock(Fragment$1, { key: 3 }, [
10978
+ __props.node.loading ? (openBlock(), createBlock(unref(ElIcon), {
10979
+ key: 0,
10980
+ class: normalizeClass([unref(ns).is("loading"), unref(ns).e("postfix")])
10981
+ }, {
10982
+ default: withCtx(() => [
10983
+ createVNode(unref(loading_default))
10984
+ ]),
10985
+ _: 1
10986
+ }, 8, ["class"])) : (openBlock(), createBlock(unref(ElIcon), {
10987
+ key: 1,
10988
+ class: normalizeClass(["arrow-right", unref(ns).e("postfix")])
10989
+ }, {
10990
+ default: withCtx(() => [
10991
+ createVNode(unref(arrow_right_default))
10992
+ ]),
10993
+ _: 1
10994
+ }, 8, ["class"]))
10995
+ ], 64)) : createCommentVNode("v-if", true)
10996
+ ], 42, ["id", "aria-haspopup", "aria-owns", "aria-expanded", "tabindex"]);
10997
+ };
10998
+ }
10999
+ });
11000
+ var ElCascaderNode = /* @__PURE__ */ _export_sfc(_sfc_main$2w, [["__file", "node.vue"]]);
11001
+ const __default__$l = defineComponent({
11002
+ name: "ElCascaderMenu"
11003
+ });
11004
+ const _sfc_main$2v = /* @__PURE__ */ defineComponent({
11005
+ ...__default__$l,
11006
+ props: {
11007
+ nodes: {
11008
+ type: Array,
11009
+ required: true
11010
+ },
11011
+ index: {
11012
+ type: Number,
11013
+ required: true
11014
+ }
11015
+ },
11016
+ setup(__props) {
11017
+ const props = __props;
11018
+ const instance = getCurrentInstance();
11019
+ const ns = useNamespace("cascader-menu");
11020
+ const { t: t2 } = useLocale();
11021
+ const id2 = useId();
11022
+ let activeNode;
11023
+ let hoverTimer;
11024
+ const panel = inject(CASCADER_PANEL_INJECTION_KEY);
11025
+ const hoverZone = ref();
11026
+ const isEmpty2 = computed(() => !props.nodes.length);
11027
+ const isLoading = computed(() => !panel.initialLoaded);
11028
+ const menuId = computed(() => `${id2.value}-${props.index}`);
11029
+ const handleExpand = (e3) => {
11030
+ activeNode = e3.target;
11031
+ };
11032
+ const handleMouseMove2 = (e3) => {
11033
+ if (!panel.isHoverMenu || !activeNode || !hoverZone.value)
11034
+ return;
11035
+ if (activeNode.contains(e3.target)) {
11036
+ clearHoverTimer();
11037
+ const el = instance.vnode.el;
11038
+ const { left } = el.getBoundingClientRect();
11039
+ const { offsetWidth, offsetHeight } = el;
11040
+ const startX = e3.clientX - left;
11041
+ const top2 = activeNode.offsetTop;
11042
+ const bottom = top2 + activeNode.offsetHeight;
11043
+ hoverZone.value.innerHTML = `
11044
+ <path style="pointer-events: auto;" fill="transparent" d="M${startX} ${top2} L${offsetWidth} 0 V${top2} Z" />
11045
+ <path style="pointer-events: auto;" fill="transparent" d="M${startX} ${bottom} L${offsetWidth} ${offsetHeight} V${bottom} Z" />
11046
+ `;
11047
+ } else if (!hoverTimer) {
11048
+ hoverTimer = window.setTimeout(clearHoverZone, panel.config.hoverThreshold);
11049
+ }
11050
+ };
11051
+ const clearHoverTimer = () => {
11052
+ if (!hoverTimer)
11053
+ return;
11054
+ clearTimeout(hoverTimer);
11055
+ hoverTimer = void 0;
11056
+ };
11057
+ const clearHoverZone = () => {
11058
+ if (!hoverZone.value)
11059
+ return;
11060
+ hoverZone.value.innerHTML = "";
11061
+ clearHoverTimer();
11062
+ };
11063
+ return (_ctx7, _cache) => {
11064
+ return openBlock(), createBlock(unref(ElScrollbar), {
11065
+ key: unref(menuId),
11066
+ tag: "ul",
11067
+ role: "menu",
11068
+ class: normalizeClass(unref(ns).b()),
11069
+ "wrap-class": unref(ns).e("wrap"),
11070
+ "view-class": [unref(ns).e("list"), unref(ns).is("empty", unref(isEmpty2))],
11071
+ onMousemove: handleMouseMove2,
11072
+ onMouseleave: clearHoverZone
11073
+ }, {
11074
+ default: withCtx(() => {
11075
+ var _a2;
11076
+ return [
11077
+ (openBlock(true), createElementBlock(Fragment$1, null, renderList(__props.nodes, (node2) => {
11078
+ return openBlock(), createBlock(ElCascaderNode, {
11079
+ key: node2.uid,
11080
+ node: node2,
11081
+ "menu-id": unref(menuId),
11082
+ onExpand: handleExpand
11083
+ }, null, 8, ["node", "menu-id"]);
11084
+ }), 128)),
11085
+ unref(isLoading) ? (openBlock(), createElementBlock("div", {
11086
+ key: 0,
11087
+ class: normalizeClass(unref(ns).e("empty-text"))
11088
+ }, [
11089
+ createVNode(unref(ElIcon), {
11090
+ size: "14",
11091
+ class: normalizeClass(unref(ns).is("loading"))
11092
+ }, {
11093
+ default: withCtx(() => [
11094
+ createVNode(unref(loading_default))
11095
+ ]),
11096
+ _: 1
11097
+ }, 8, ["class"]),
11098
+ createTextVNode(" " + toDisplayString(unref(t2)("el.cascader.loading")), 1)
11099
+ ], 2)) : unref(isEmpty2) ? (openBlock(), createElementBlock("div", {
11100
+ key: 1,
11101
+ class: normalizeClass(unref(ns).e("empty-text"))
11102
+ }, [
11103
+ renderSlot(_ctx7.$slots, "empty", {}, () => [
11104
+ createTextVNode(toDisplayString(unref(t2)("el.cascader.noData")), 1)
11105
+ ])
11106
+ ], 2)) : ((_a2 = unref(panel)) == null ? void 0 : _a2.isHoverMenu) ? (openBlock(), createElementBlock(Fragment$1, { key: 2 }, [
11107
+ createCommentVNode(" eslint-disable-next-line vue/html-self-closing "),
11108
+ (openBlock(), createElementBlock("svg", {
11109
+ ref_key: "hoverZone",
11110
+ ref: hoverZone,
11111
+ class: normalizeClass(unref(ns).e("hover-zone"))
11112
+ }, null, 2))
11113
+ ], 2112)) : createCommentVNode("v-if", true)
11114
+ ];
11115
+ }),
11116
+ _: 3
11117
+ }, 8, ["class", "wrap-class", "view-class"]);
11118
+ };
11119
+ }
11120
+ });
11121
+ var ElCascaderMenu = /* @__PURE__ */ _export_sfc(_sfc_main$2v, [["__file", "menu.vue"]]);
11122
+ let uid = 0;
11123
+ const calculatePathNodes = (node2) => {
11124
+ const nodes = [node2];
11125
+ let { parent } = node2;
11126
+ while (parent) {
11127
+ nodes.unshift(parent);
11128
+ parent = parent.parent;
11129
+ }
11130
+ return nodes;
11131
+ };
11132
+ let Node$3 = class Node2 {
11133
+ constructor(data2, config2, parent, root2 = false) {
11134
+ this.data = data2;
11135
+ this.config = config2;
11136
+ this.parent = parent;
11137
+ this.root = root2;
11138
+ this.uid = uid++;
11139
+ this.checked = false;
11140
+ this.indeterminate = false;
11141
+ this.loading = false;
11142
+ const { value: valueKey, label: labelKey, children: childrenKey } = config2;
11143
+ const childrenData = data2[childrenKey];
11144
+ const pathNodes = calculatePathNodes(this);
11145
+ this.level = root2 ? 0 : parent ? parent.level + 1 : 1;
11146
+ this.value = data2[valueKey];
11147
+ this.label = data2[labelKey];
11148
+ this.pathNodes = pathNodes;
11149
+ this.pathValues = pathNodes.map((node2) => node2.value);
11150
+ this.pathLabels = pathNodes.map((node2) => node2.label);
11151
+ this.childrenData = childrenData;
11152
+ this.children = (childrenData || []).map((child) => new Node2(child, config2, this));
11153
+ this.loaded = !config2.lazy || this.isLeaf || !isEmpty(childrenData);
11154
+ this.text = "";
11155
+ }
11156
+ get isDisabled() {
11157
+ const { data: data2, parent, config: config2 } = this;
11158
+ const { disabled, checkStrictly } = config2;
11159
+ const isDisabled = isFunction$7(disabled) ? disabled(data2, this) : !!data2[disabled];
11160
+ return isDisabled || !checkStrictly && !!(parent == null ? void 0 : parent.isDisabled);
11161
+ }
11162
+ get isLeaf() {
11163
+ const { data: data2, config: config2, childrenData, loaded } = this;
11164
+ const { lazy, leaf } = config2;
11165
+ const isLeaf2 = isFunction$7(leaf) ? leaf(data2, this) : data2[leaf];
11166
+ return isUndefined(isLeaf2) ? lazy && !loaded ? false : !(isArray$c(childrenData) && childrenData.length) : !!isLeaf2;
11167
+ }
11168
+ get valueByOption() {
11169
+ return this.config.emitPath ? this.pathValues : this.value;
11170
+ }
11171
+ appendChild(childData) {
11172
+ const { childrenData, children } = this;
11173
+ const node2 = new Node2(childData, this.config, this);
11174
+ if (isArray$c(childrenData)) {
11175
+ childrenData.push(childData);
11176
+ } else {
11177
+ this.childrenData = [childData];
11178
+ }
11179
+ children.push(node2);
11180
+ return node2;
11181
+ }
11182
+ calcText(allLevels, separator) {
11183
+ const text2 = allLevels ? this.pathLabels.join(separator) : this.label;
11184
+ this.text = text2;
11185
+ return text2;
11186
+ }
11187
+ broadcast(checked) {
11188
+ this.children.forEach((child) => {
11189
+ var _a2;
11190
+ if (child) {
11191
+ child.broadcast(checked);
11192
+ (_a2 = child.onParentCheck) == null ? void 0 : _a2.call(child, checked);
11193
+ }
11194
+ });
11195
+ }
11196
+ emit() {
11197
+ var _a2;
11198
+ const { parent } = this;
11199
+ if (parent) {
11200
+ (_a2 = parent.onChildCheck) == null ? void 0 : _a2.call(parent);
11201
+ parent.emit();
11202
+ }
11203
+ }
11204
+ onParentCheck(checked) {
11205
+ if (!this.isDisabled) {
11206
+ this.setCheckState(checked);
11207
+ }
11208
+ }
11209
+ onChildCheck() {
11210
+ const { children } = this;
11211
+ const validChildren = children.filter((child) => !child.isDisabled);
11212
+ const checked = validChildren.length ? validChildren.every((child) => child.checked) : false;
11213
+ this.setCheckState(checked);
11214
+ }
11215
+ setCheckState(checked) {
11216
+ const totalNum = this.children.length;
11217
+ const checkedNum = this.children.reduce((c2, p2) => {
11218
+ const num = p2.checked ? 1 : p2.indeterminate ? 0.5 : 0;
11219
+ return c2 + num;
11220
+ }, 0);
11221
+ this.checked = this.loaded && this.children.filter((child) => !child.isDisabled).every((child) => child.loaded && child.checked) && checked;
11222
+ this.indeterminate = this.loaded && checkedNum !== totalNum && checkedNum > 0;
11223
+ }
11224
+ doCheck(checked) {
11225
+ if (this.checked === checked)
11226
+ return;
11227
+ const { checkStrictly, multiple } = this.config;
11228
+ if (checkStrictly || !multiple) {
11229
+ this.checked = checked;
11230
+ } else {
11231
+ this.broadcast(checked);
11232
+ this.setCheckState(checked);
11233
+ this.emit();
11234
+ }
11235
+ }
11236
+ };
11237
+ const flatNodes = (nodes, leafOnly) => {
11238
+ return nodes.reduce((res, node2) => {
11239
+ if (node2.isLeaf) {
11240
+ res.push(node2);
11241
+ } else {
11242
+ !leafOnly && res.push(node2);
11243
+ res = res.concat(flatNodes(node2.children, leafOnly));
11244
+ }
11245
+ return res;
11246
+ }, []);
11247
+ };
11248
+ class Store {
11249
+ constructor(data2, config2) {
11250
+ this.config = config2;
11251
+ const nodes = (data2 || []).map((nodeData) => new Node$3(nodeData, this.config));
11252
+ this.nodes = nodes;
11253
+ this.allNodes = flatNodes(nodes, false);
11254
+ this.leafNodes = flatNodes(nodes, true);
11255
+ }
11256
+ getNodes() {
11257
+ return this.nodes;
11258
+ }
11259
+ getFlattedNodes(leafOnly) {
11260
+ return leafOnly ? this.leafNodes : this.allNodes;
11261
+ }
11262
+ appendNode(nodeData, parentNode2) {
11263
+ const node2 = parentNode2 ? parentNode2.appendChild(nodeData) : new Node$3(nodeData, this.config);
11264
+ if (!parentNode2)
11265
+ this.nodes.push(node2);
11266
+ this.appendAllNodesAndLeafNodes(node2);
11267
+ }
11268
+ appendNodes(nodeDataList, parentNode2) {
11269
+ if (nodeDataList.length > 0) {
11270
+ nodeDataList.forEach((nodeData) => this.appendNode(nodeData, parentNode2));
11271
+ } else {
11272
+ parentNode2 && parentNode2.isLeaf && this.leafNodes.push(parentNode2);
11273
+ }
11274
+ }
11275
+ appendAllNodesAndLeafNodes(node2) {
11276
+ this.allNodes.push(node2);
11277
+ node2.isLeaf && this.leafNodes.push(node2);
11278
+ if (node2.children) {
11279
+ node2.children.forEach((subNode) => {
11280
+ this.appendAllNodesAndLeafNodes(subNode);
11281
+ });
11282
+ }
11283
+ }
11284
+ getNodeByValue(value, leafOnly = false) {
11285
+ if (isPropAbsent(value))
11286
+ return null;
11287
+ const node2 = this.getFlattedNodes(leafOnly).find((node22) => isEqual$2(node22.value, value) || isEqual$2(node22.pathValues, value));
11288
+ return node2 || null;
11289
+ }
11290
+ getSameNode(node2) {
11291
+ if (!node2)
11292
+ return null;
11293
+ const node_ = this.getFlattedNodes(false).find(({ value, level }) => isEqual$2(node2.value, value) && node2.level === level);
11294
+ return node_ || null;
11295
+ }
11296
+ }
11297
+ const CommonProps = buildProps({
11298
+ modelValue: {
11299
+ type: definePropType([Number, String, Array, Object])
11300
+ },
11301
+ options: {
11302
+ type: definePropType(Array),
11303
+ default: () => []
11304
+ },
11305
+ props: {
11306
+ type: definePropType(Object),
11307
+ default: () => ({})
11308
+ }
11309
+ });
11310
+ const DefaultProps = {
11311
+ expandTrigger: "click",
11312
+ multiple: false,
11313
+ checkStrictly: false,
11314
+ emitPath: true,
11315
+ lazy: false,
11316
+ lazyLoad: NOOP,
11317
+ value: "value",
11318
+ label: "label",
11319
+ children: "children",
11320
+ leaf: "leaf",
11321
+ disabled: "disabled",
11322
+ hoverThreshold: 500,
11323
+ checkOnClickNode: false,
11324
+ checkOnClickLeaf: true,
11325
+ showPrefix: true
11326
+ };
11327
+ const cascaderPanelProps = buildProps({
11328
+ ...CommonProps,
11329
+ border: {
11330
+ type: Boolean,
11331
+ default: true
11332
+ },
11333
+ renderLabel: {
11334
+ type: Function
11335
+ }
11336
+ });
11337
+ const emitChangeFn = (value) => true;
11338
+ const cascaderPanelEmits = {
11339
+ [UPDATE_MODEL_EVENT$1]: emitChangeFn,
11340
+ [CHANGE_EVENT$1]: emitChangeFn,
11341
+ close: () => true,
11342
+ "expand-change": (value) => value
11343
+ };
11344
+ const useCascaderConfig = (props) => {
11345
+ return computed(() => ({
11346
+ ...DefaultProps,
11347
+ ...props.props
11348
+ }));
11349
+ };
11350
+ const getMenuIndex = (el) => {
11351
+ if (!el)
11352
+ return 0;
11353
+ const pieces = el.id.split("-");
11354
+ return Number(pieces[pieces.length - 2]);
11355
+ };
11356
+ const checkNode = (el) => {
11357
+ if (!el)
11358
+ return;
11359
+ const input = el.querySelector("input");
11360
+ if (input) {
11361
+ input.click();
11362
+ } else if (isLeaf(el)) {
11363
+ el.click();
11364
+ }
11365
+ };
11366
+ const sortByOriginalOrder = (oldNodes, newNodes) => {
11367
+ const newNodesCopy = newNodes.slice(0);
11368
+ const newIds = newNodesCopy.map((node2) => node2.uid);
11369
+ const res = oldNodes.reduce((acc, item) => {
11370
+ const index2 = newIds.indexOf(item.uid);
11371
+ if (index2 > -1) {
11372
+ acc.push(item);
11373
+ newNodesCopy.splice(index2, 1);
11374
+ newIds.splice(index2, 1);
11375
+ }
11376
+ return acc;
11377
+ }, []);
11378
+ res.push(...newNodesCopy);
11379
+ return res;
11380
+ };
11381
+ const __default__$k = defineComponent({
11382
+ name: "ElCascaderPanel",
11383
+ inheritAttrs: false
11384
+ });
11385
+ const _sfc_main$2u = /* @__PURE__ */ defineComponent({
11386
+ ...__default__$k,
11387
+ props: cascaderPanelProps,
11388
+ emits: cascaderPanelEmits,
11389
+ setup(__props, { expose, emit }) {
11390
+ const props = __props;
11391
+ let manualChecked = false;
11392
+ const ns = useNamespace("cascader");
11393
+ const config2 = useCascaderConfig(props);
11394
+ const slots = useSlots();
11395
+ let store;
11396
+ const initialLoaded = ref(true);
11397
+ const menuList = ref([]);
11398
+ const checkedValue = ref();
11399
+ const menus = ref([]);
11400
+ const expandingNode = ref();
11401
+ const checkedNodes = ref([]);
11402
+ const isHoverMenu = computed(() => config2.value.expandTrigger === "hover");
11403
+ const renderLabelFn = computed(() => props.renderLabel || slots.default);
11404
+ const initStore = () => {
11405
+ const { options } = props;
11406
+ const cfg = config2.value;
11407
+ manualChecked = false;
11408
+ store = new Store(options, cfg);
11409
+ menus.value = [store.getNodes()];
11410
+ if (cfg.lazy && isEmpty(props.options)) {
11411
+ initialLoaded.value = false;
11412
+ lazyLoad(void 0, (list2) => {
11413
+ if (list2) {
11414
+ store = new Store(list2, cfg);
11415
+ menus.value = [store.getNodes()];
11416
+ }
11417
+ initialLoaded.value = true;
11418
+ syncCheckedValue(false, true);
11419
+ });
11420
+ } else {
11421
+ syncCheckedValue(false, true);
11422
+ }
11423
+ };
11424
+ const lazyLoad = (node2, cb) => {
11425
+ const cfg = config2.value;
11426
+ node2 = node2 || new Node$3({}, cfg, void 0, true);
11427
+ node2.loading = true;
11428
+ const resolve = (dataList) => {
11429
+ const _node = node2;
11430
+ const parent = _node.root ? null : _node;
11431
+ _node.loading = false;
11432
+ _node.loaded = true;
11433
+ _node.childrenData = _node.childrenData || [];
11434
+ dataList && (store == null ? void 0 : store.appendNodes(dataList, parent));
11435
+ dataList && (cb == null ? void 0 : cb(dataList));
11436
+ };
11437
+ cfg.lazyLoad(node2, resolve);
11438
+ };
11439
+ const expandNode = (node2, silent) => {
11440
+ var _a2;
11441
+ const { level } = node2;
11442
+ const newMenus = menus.value.slice(0, level);
11443
+ let newExpandingNode;
11444
+ if (node2.isLeaf) {
11445
+ newExpandingNode = node2.pathNodes[level - 2];
11446
+ } else {
11447
+ newExpandingNode = node2;
11448
+ newMenus.push(node2.children);
11449
+ }
11450
+ if (((_a2 = expandingNode.value) == null ? void 0 : _a2.uid) !== (newExpandingNode == null ? void 0 : newExpandingNode.uid)) {
11451
+ expandingNode.value = node2;
11452
+ menus.value = newMenus;
11453
+ !silent && emit("expand-change", (node2 == null ? void 0 : node2.pathValues) || []);
11454
+ }
11455
+ };
11456
+ const handleCheckChange = (node2, checked, emitClose = true) => {
11457
+ const { checkStrictly, multiple } = config2.value;
11458
+ const oldNode = checkedNodes.value[0];
11459
+ manualChecked = true;
11460
+ !multiple && (oldNode == null ? void 0 : oldNode.doCheck(false));
11461
+ node2.doCheck(checked);
11462
+ calculateCheckedValue();
11463
+ emitClose && !multiple && !checkStrictly && emit("close");
11464
+ !emitClose && !multiple && !checkStrictly && expandParentNode(node2);
11465
+ };
11466
+ const expandParentNode = (node2) => {
11467
+ if (!node2)
11468
+ return;
11469
+ node2 = node2.parent;
11470
+ expandParentNode(node2);
11471
+ node2 && expandNode(node2);
11472
+ };
11473
+ const getFlattedNodes = (leafOnly) => store == null ? void 0 : store.getFlattedNodes(leafOnly);
11474
+ const getCheckedNodes = (leafOnly) => {
11475
+ var _a2;
11476
+ return (_a2 = getFlattedNodes(leafOnly)) == null ? void 0 : _a2.filter(({ checked }) => checked !== false);
11477
+ };
11478
+ const clearCheckedNodes = () => {
11479
+ checkedNodes.value.forEach((node2) => node2.doCheck(false));
11480
+ calculateCheckedValue();
11481
+ menus.value = menus.value.slice(0, 1);
11482
+ expandingNode.value = void 0;
11483
+ emit("expand-change", []);
11484
+ };
11485
+ const calculateCheckedValue = () => {
11486
+ var _a2;
11487
+ const { checkStrictly, multiple } = config2.value;
11488
+ const oldNodes = checkedNodes.value;
11489
+ const newNodes = getCheckedNodes(!checkStrictly);
11490
+ const nodes = sortByOriginalOrder(oldNodes, newNodes);
11491
+ const values2 = nodes.map((node2) => node2.valueByOption);
11492
+ checkedNodes.value = nodes;
11493
+ checkedValue.value = multiple ? values2 : (_a2 = values2[0]) != null ? _a2 : null;
11494
+ };
11495
+ const syncCheckedValue = (loaded = false, forced = false) => {
11496
+ const { modelValue } = props;
11497
+ const { lazy, multiple, checkStrictly } = config2.value;
11498
+ const leafOnly = !checkStrictly;
11499
+ if (!initialLoaded.value || manualChecked || !forced && isEqual$2(modelValue, checkedValue.value))
11500
+ return;
11501
+ if (lazy && !loaded) {
11502
+ const values2 = unique(flattenDeep(castArray(modelValue)));
11503
+ const nodes = values2.map((val) => store == null ? void 0 : store.getNodeByValue(val)).filter((node2) => !!node2 && !node2.loaded && !node2.loading);
11504
+ if (nodes.length) {
11505
+ nodes.forEach((node2) => {
11506
+ lazyLoad(node2, () => syncCheckedValue(false, forced));
11507
+ });
11508
+ } else {
11509
+ syncCheckedValue(true, forced);
11510
+ }
11511
+ } else {
11512
+ const values2 = multiple ? castArray(modelValue) : [modelValue];
11513
+ const nodes = unique(values2.map((val) => store == null ? void 0 : store.getNodeByValue(val, leafOnly)));
11514
+ syncMenuState(nodes, forced);
11515
+ checkedValue.value = cloneDeep$2(modelValue != null ? modelValue : void 0);
11516
+ }
11517
+ };
11518
+ const syncMenuState = (newCheckedNodes, reserveExpandingState = true) => {
11519
+ const { checkStrictly } = config2.value;
11520
+ const oldNodes = checkedNodes.value;
11521
+ const newNodes = newCheckedNodes.filter((node2) => !!node2 && (checkStrictly || node2.isLeaf));
11522
+ const oldExpandingNode = store == null ? void 0 : store.getSameNode(expandingNode.value);
11523
+ const newExpandingNode = reserveExpandingState && oldExpandingNode || newNodes[0];
11524
+ if (newExpandingNode) {
11525
+ newExpandingNode.pathNodes.forEach((node2) => expandNode(node2, true));
11526
+ } else {
11527
+ expandingNode.value = void 0;
11528
+ }
11529
+ oldNodes.forEach((node2) => node2.doCheck(false));
11530
+ reactive(newNodes).forEach((node2) => node2.doCheck(true));
11531
+ checkedNodes.value = newNodes;
11532
+ nextTick(scrollToExpandingNode);
11533
+ };
11534
+ const scrollToExpandingNode = () => {
11535
+ if (!isClient$1)
11536
+ return;
11537
+ menuList.value.forEach((menu2) => {
11538
+ const menuElement = menu2 == null ? void 0 : menu2.$el;
11539
+ if (menuElement) {
11540
+ const container = menuElement.querySelector(`.${ns.namespace.value}-scrollbar__wrap`);
11541
+ const activeNode = menuElement.querySelector(`.${ns.b("node")}.${ns.is("active")}:last-child`) || menuElement.querySelector(`.${ns.b("node")}.in-active-path`);
11542
+ scrollIntoView$2(container, activeNode);
11543
+ }
11544
+ });
11545
+ };
11546
+ const handleKeyDown2 = (e3) => {
11547
+ const target = e3.target;
11548
+ const { code: code2 } = e3;
11549
+ switch (code2) {
11550
+ case EVENT_CODE$1.up:
11551
+ case EVENT_CODE$1.down: {
11552
+ e3.preventDefault();
11553
+ const distance = code2 === EVENT_CODE$1.up ? -1 : 1;
11554
+ focusNode(getSibling(target, distance, `.${ns.b("node")}[tabindex="-1"]`));
11555
+ break;
11556
+ }
11557
+ case EVENT_CODE$1.left: {
11558
+ e3.preventDefault();
11559
+ const preMenu = menuList.value[getMenuIndex(target) - 1];
11560
+ const expandedNode = preMenu == null ? void 0 : preMenu.$el.querySelector(`.${ns.b("node")}[aria-expanded="true"]`);
11561
+ focusNode(expandedNode);
11562
+ break;
11563
+ }
11564
+ case EVENT_CODE$1.right: {
11565
+ e3.preventDefault();
11566
+ const nextMenu = menuList.value[getMenuIndex(target) + 1];
11567
+ const firstNode = nextMenu == null ? void 0 : nextMenu.$el.querySelector(`.${ns.b("node")}[tabindex="-1"]`);
11568
+ focusNode(firstNode);
11569
+ break;
11570
+ }
11571
+ case EVENT_CODE$1.enter:
11572
+ case EVENT_CODE$1.numpadEnter:
11573
+ checkNode(target);
11574
+ break;
11575
+ }
11576
+ };
11577
+ provide(CASCADER_PANEL_INJECTION_KEY, reactive({
11578
+ config: config2,
11579
+ expandingNode,
11580
+ checkedNodes,
11581
+ isHoverMenu,
11582
+ initialLoaded,
11583
+ renderLabelFn,
11584
+ lazyLoad,
11585
+ expandNode,
11586
+ handleCheckChange
11587
+ }));
11588
+ watch(config2, (newVal, oldVal) => {
11589
+ if (isEqual$2(newVal, oldVal))
11590
+ return;
11591
+ initStore();
11592
+ }, {
11593
+ immediate: true
11594
+ });
11595
+ watch(() => props.options, initStore, {
11596
+ deep: true
11597
+ });
11598
+ watch(() => props.modelValue, () => {
11599
+ manualChecked = false;
11600
+ syncCheckedValue();
11601
+ }, {
11602
+ deep: true
11603
+ });
11604
+ watch(() => checkedValue.value, (val) => {
11605
+ if (!isEqual$2(val, props.modelValue)) {
11606
+ emit(UPDATE_MODEL_EVENT$1, val);
11607
+ emit(CHANGE_EVENT$1, val);
11608
+ }
11609
+ });
11610
+ onBeforeUpdate(() => menuList.value = []);
11611
+ onMounted(() => !isEmpty(props.modelValue) && syncCheckedValue());
11612
+ expose({
11613
+ menuList,
11614
+ menus,
11615
+ checkedNodes,
11616
+ handleKeyDown: handleKeyDown2,
11617
+ handleCheckChange,
11618
+ getFlattedNodes,
11619
+ getCheckedNodes,
11620
+ clearCheckedNodes,
11621
+ calculateCheckedValue,
11622
+ scrollToExpandingNode
11623
+ });
11624
+ return (_ctx7, _cache) => {
11625
+ return openBlock(), createElementBlock("div", {
11626
+ class: normalizeClass([unref(ns).b("panel"), unref(ns).is("bordered", _ctx7.border)]),
11627
+ onKeydown: handleKeyDown2
11628
+ }, [
11629
+ (openBlock(true), createElementBlock(Fragment$1, null, renderList(menus.value, (menu2, index2) => {
11630
+ return openBlock(), createBlock(ElCascaderMenu, {
11631
+ key: index2,
11632
+ ref_for: true,
11633
+ ref: (item) => menuList.value[index2] = item,
11634
+ index: index2,
11635
+ nodes: [...menu2]
11636
+ }, {
11637
+ empty: withCtx(() => [
11638
+ renderSlot(_ctx7.$slots, "empty")
11639
+ ]),
11640
+ _: 2
11641
+ }, 1032, ["index", "nodes"]);
11642
+ }), 128))
11643
+ ], 34);
11644
+ };
11645
+ }
11646
+ });
11647
+ var CascaderPanel = /* @__PURE__ */ _export_sfc(_sfc_main$2u, [["__file", "index.vue"]]);
11648
+ const ElCascaderPanel = withInstall(CascaderPanel);
10747
11649
  const tagProps = buildProps({
10748
11650
  type: {
10749
11651
  type: String,
@@ -25705,7 +26607,7 @@ const setCanFocus = function(childNodes, focus) {
25705
26607
  });
25706
26608
  };
25707
26609
  let nodeIdSeed = 0;
25708
- let Node$2 = class Node2 {
26610
+ let Node$2 = class Node3 {
25709
26611
  constructor(options) {
25710
26612
  this.isLeafByUser = void 0;
25711
26613
  this.isLeaf = void 0;
@@ -25741,9 +26643,9 @@ let Node$2 = class Node2 {
25741
26643
  store.registerNode(this);
25742
26644
  const props = store.props;
25743
26645
  if (props && typeof props.isLeaf !== "undefined") {
25744
- const isLeaf = getPropertyFromData(this, "isLeaf");
25745
- if (isBoolean(isLeaf)) {
25746
- this.isLeafByUser = isLeaf;
26646
+ const isLeaf2 = getPropertyFromData(this, "isLeaf");
26647
+ if (isBoolean(isLeaf2)) {
26648
+ this.isLeafByUser = isLeaf2;
25747
26649
  }
25748
26650
  }
25749
26651
  if (store.lazy !== true && this.data) {
@@ -25836,7 +26738,7 @@ let Node$2 = class Node2 {
25836
26738
  insertChild(child, index2, batch) {
25837
26739
  if (!child)
25838
26740
  throw new Error("InsertChild error: child is required.");
25839
- if (!(child instanceof Node2)) {
26741
+ if (!(child instanceof Node3)) {
25840
26742
  if (!batch) {
25841
26743
  const children = this.getChildren(true);
25842
26744
  if (!(children == null ? void 0 : children.includes(child.data))) {
@@ -25851,8 +26753,8 @@ let Node$2 = class Node2 {
25851
26753
  parent: this,
25852
26754
  store: this.store
25853
26755
  });
25854
- child = reactive(new Node2(child));
25855
- if (child instanceof Node2) {
26756
+ child = reactive(new Node3(child));
26757
+ if (child instanceof Node3) {
25856
26758
  child.initialize();
25857
26759
  }
25858
26760
  }
@@ -27898,8 +28800,8 @@ var coreJsData$1 = root$8["__core-js_shared__"];
27898
28800
  var _coreJsData = coreJsData$1;
27899
28801
  var coreJsData = _coreJsData;
27900
28802
  var maskSrcKey = function() {
27901
- var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
27902
- return uid ? "Symbol(src)_1." + uid : "";
28803
+ var uid2 = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
28804
+ return uid2 ? "Symbol(src)_1." + uid2 : "";
27903
28805
  }();
27904
28806
  function isMasked$1(func) {
27905
28807
  return !!maskSrcKey && maskSrcKey in func;
@@ -32800,7 +33702,7 @@ const _sfc_main$1l = /* @__PURE__ */ defineComponent({
32800
33702
  color: _ctx7.color
32801
33703
  }, null, 8, ["model-value", "color"]),
32802
33704
  createElementVNode("div", _hoisted_2$O, [
32803
- createVNode(_sfc_main$2T, {
33705
+ createVNode(_sfc_main$2W, {
32804
33706
  type: "default",
32805
33707
  size: "middle",
32806
33708
  icon: "vc-icon-save",
@@ -41111,7 +42013,7 @@ const _sfc_main$14 = /* @__PURE__ */ defineComponent({
41111
42013
  createElementVNode("div", _hoisted_2$C, [
41112
42014
  renderSlot(_ctx7.$slots, "action", { click: triggerInputClick }, () => [
41113
42015
  createElementVNode("div", _hoisted_3$y, [
41114
- createVNode(_sfc_main$2T, {
42016
+ createVNode(_sfc_main$2W, {
41115
42017
  type: _ctx7.buttonType,
41116
42018
  color: _ctx7.buttonColor,
41117
42019
  icon: _ctx7.buttonIcon,
@@ -43075,7 +43977,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
43075
43977
  return openBlock(), createElementBlock("div", _hoisted_1$F, [
43076
43978
  renderSlot(_ctx7.$slots, "navigation", {}, () => [
43077
43979
  createElementVNode("div", _hoisted_2$r, [
43078
- createVNode(_sfc_main$2T, {
43980
+ createVNode(_sfc_main$2W, {
43079
43981
  block: _ctx7.isMobile,
43080
43982
  size: _ctx7.isMobile ? "middle" : "large",
43081
43983
  color: "secondary",
@@ -43095,7 +43997,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
43095
43997
  createElementVNode("div", _hoisted_4$j, [
43096
43998
  createElementVNode("div", _hoisted_5$f, [
43097
43999
  createElementVNode("div", _hoisted_6$c, [
43098
- _ctx7.showPrevBtn ? (openBlock(), createBlock(_sfc_main$2T, {
44000
+ _ctx7.showPrevBtn ? (openBlock(), createBlock(_sfc_main$2W, {
43099
44001
  key: 0,
43100
44002
  block: _ctx7.isMobile,
43101
44003
  size: _ctx7.isMobile ? "middle" : "large",
@@ -43111,7 +44013,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
43111
44013
  }, 8, ["block", "size"])) : createCommentVNode("", true)
43112
44014
  ]),
43113
44015
  _ctx7.showNextBtn ? (openBlock(), createElementBlock("div", _hoisted_7$9, [
43114
- createVNode(_sfc_main$2T, {
44016
+ createVNode(_sfc_main$2W, {
43115
44017
  block: _ctx7.isMobile,
43116
44018
  size: _ctx7.isMobile ? "middle" : "large",
43117
44019
  loading: _ctx7.loading,
@@ -43127,7 +44029,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
43127
44029
  }, 8, ["block", "size", "loading", "disabled"])
43128
44030
  ])) : createCommentVNode("", true),
43129
44031
  _ctx7.showFinalBtn ? (openBlock(), createElementBlock("div", _hoisted_8$6, [
43130
- createVNode(_sfc_main$2T, {
44032
+ createVNode(_sfc_main$2W, {
43131
44033
  size: _ctx7.isMobile ? "middle" : "large",
43132
44034
  block: _ctx7.isMobile,
43133
44035
  loading: _ctx7.loading,
@@ -45642,8 +46544,8 @@ const _sfc_main$G = /* @__PURE__ */ defineComponent({
45642
46544
  setup(__props) {
45643
46545
  const props = __props;
45644
46546
  const slots = useSlots();
45645
- const uid = uniqueComponentId("vc-trend-");
45646
- const componentId = computed(() => props.id || uid);
46547
+ const uid2 = uniqueComponentId("vc-trend-");
46548
+ const componentId = computed(() => props.id || uid2);
45647
46549
  const bars = computed(() => genBars(items.value, boundary.value));
45648
46550
  const offsetX = computed(() => (Math.abs(bars.value[0].x - bars.value[1].x) - lineWidth.value) / 2);
45649
46551
  const autoDrawDuration = computed(() => Number(props.autoDrawDuration) || 500);
@@ -45834,10 +46736,10 @@ const _sfc_main$F = /* @__PURE__ */ defineComponent({
45834
46736
  setup(__props) {
45835
46737
  const props = __props;
45836
46738
  const slots = useSlots();
45837
- const uid = uniqueComponentId("vc-trendline-");
46739
+ const uid2 = uniqueComponentId("vc-trendline-");
45838
46740
  const lastLength = ref(0);
45839
46741
  const pathRef = ref();
45840
- const componentId = computed(() => props.id || uid);
46742
+ const componentId = computed(() => props.id || uid2);
45841
46743
  const gradientData = computed(() => {
45842
46744
  return !props.gradient.slice().length ? [""] : props.gradient.slice().reverse();
45843
46745
  });
@@ -53613,13 +54515,13 @@ class DOMSelectionState {
53613
54515
  return this.anchorNode == domSel.anchorNode && this.anchorOffset == domSel.anchorOffset && this.focusNode == domSel.focusNode && this.focusOffset == domSel.focusOffset;
53614
54516
  }
53615
54517
  setRange(range3) {
53616
- let { anchorNode, focusNode } = range3;
53617
- this.set(anchorNode, Math.min(range3.anchorOffset, anchorNode ? maxOffset(anchorNode) : 0), focusNode, Math.min(range3.focusOffset, focusNode ? maxOffset(focusNode) : 0));
54518
+ let { anchorNode, focusNode: focusNode2 } = range3;
54519
+ this.set(anchorNode, Math.min(range3.anchorOffset, anchorNode ? maxOffset(anchorNode) : 0), focusNode2, Math.min(range3.focusOffset, focusNode2 ? maxOffset(focusNode2) : 0));
53618
54520
  }
53619
- set(anchorNode, anchorOffset, focusNode, focusOffset) {
54521
+ set(anchorNode, anchorOffset, focusNode2, focusOffset) {
53620
54522
  this.anchorNode = anchorNode;
53621
54523
  this.anchorOffset = anchorOffset;
53622
- this.focusNode = focusNode;
54524
+ this.focusNode = focusNode2;
53623
54525
  this.focusOffset = focusOffset;
53624
54526
  }
53625
54527
  }
@@ -57137,11 +58039,11 @@ function selectionPoints(view) {
57137
58039
  let result2 = [];
57138
58040
  if (view.root.activeElement != view.contentDOM)
57139
58041
  return result2;
57140
- let { anchorNode, anchorOffset, focusNode, focusOffset } = view.observer.selectionRange;
58042
+ let { anchorNode, anchorOffset, focusNode: focusNode2, focusOffset } = view.observer.selectionRange;
57141
58043
  if (anchorNode) {
57142
58044
  result2.push(new DOMPoint(anchorNode, anchorOffset));
57143
- if (focusNode != anchorNode || focusOffset != anchorOffset)
57144
- result2.push(new DOMPoint(focusNode, focusOffset));
58045
+ if (focusNode2 != anchorNode || focusOffset != anchorOffset)
58046
+ result2.push(new DOMPoint(focusNode2, focusOffset));
57145
58047
  }
57146
58048
  return result2;
57147
58049
  }
@@ -59937,11 +60839,11 @@ function findChild(cView, dom, dir) {
59937
60839
  }
59938
60840
  function buildSelectionRangeFromRange(view, range3) {
59939
60841
  let anchorNode = range3.startContainer, anchorOffset = range3.startOffset;
59940
- let focusNode = range3.endContainer, focusOffset = range3.endOffset;
60842
+ let focusNode2 = range3.endContainer, focusOffset = range3.endOffset;
59941
60843
  let curAnchor = view.docView.domAtPos(view.state.selection.main.anchor);
59942
- if (isEquivalentPosition$1(curAnchor.node, curAnchor.offset, focusNode, focusOffset))
59943
- [anchorNode, anchorOffset, focusNode, focusOffset] = [focusNode, focusOffset, anchorNode, anchorOffset];
59944
- return { anchorNode, anchorOffset, focusNode, focusOffset };
60844
+ if (isEquivalentPosition$1(curAnchor.node, curAnchor.offset, focusNode2, focusOffset))
60845
+ [anchorNode, anchorOffset, focusNode2, focusOffset] = [focusNode2, focusOffset, anchorNode, anchorOffset];
60846
+ return { anchorNode, anchorOffset, focusNode: focusNode2, focusOffset };
59945
60847
  }
59946
60848
  function safariSelectionRangeHack(view, selection2) {
59947
60849
  if (selection2.getComposedRanges) {
@@ -66170,7 +67072,7 @@ function legacy(parser2) {
66170
67072
  return new LanguageSupport(StreamLanguage.define(parser2));
66171
67073
  }
66172
67074
  function sql(dialectName) {
66173
- return import("./index-BWexRHi1.mjs").then((m2) => m2.sql({ dialect: m2[dialectName] }));
67075
+ return import("./index-sHXxzmmN.mjs").then((m2) => m2.sql({ dialect: m2[dialectName] }));
66174
67076
  }
66175
67077
  const languages = [
66176
67078
  // New-style language modes
@@ -66178,7 +67080,7 @@ const languages = [
66178
67080
  name: "C",
66179
67081
  extensions: ["c", "h", "ino"],
66180
67082
  load() {
66181
- return import("./index-5XTYllf8.mjs").then((m2) => m2.cpp());
67083
+ return import("./index-N0wzFp0j.mjs").then((m2) => m2.cpp());
66182
67084
  }
66183
67085
  }),
66184
67086
  /* @__PURE__ */ LanguageDescription.of({
@@ -66186,7 +67088,7 @@ const languages = [
66186
67088
  alias: ["cpp"],
66187
67089
  extensions: ["cpp", "c++", "cc", "cxx", "hpp", "h++", "hh", "hxx"],
66188
67090
  load() {
66189
- return import("./index-5XTYllf8.mjs").then((m2) => m2.cpp());
67091
+ return import("./index-N0wzFp0j.mjs").then((m2) => m2.cpp());
66190
67092
  }
66191
67093
  }),
66192
67094
  /* @__PURE__ */ LanguageDescription.of({
@@ -66208,7 +67110,7 @@ const languages = [
66208
67110
  name: "Go",
66209
67111
  extensions: ["go"],
66210
67112
  load() {
66211
- return import("./index-Djf2HmOn.mjs").then((m2) => m2.go());
67113
+ return import("./index-BGJQiclS.mjs").then((m2) => m2.go());
66212
67114
  }
66213
67115
  }),
66214
67116
  /* @__PURE__ */ LanguageDescription.of({
@@ -66223,7 +67125,7 @@ const languages = [
66223
67125
  name: "Java",
66224
67126
  extensions: ["java"],
66225
67127
  load() {
66226
- return import("./index-D0jRT024.mjs").then((m2) => m2.java());
67128
+ return import("./index-Bju5LdiT.mjs").then((m2) => m2.java());
66227
67129
  }
66228
67130
  }),
66229
67131
  /* @__PURE__ */ LanguageDescription.of({
@@ -66253,14 +67155,14 @@ const languages = [
66253
67155
  name: "LESS",
66254
67156
  extensions: ["less"],
66255
67157
  load() {
66256
- return import("./index-CApVvY4i.mjs").then((m2) => m2.less());
67158
+ return import("./index-B_bildVv.mjs").then((m2) => m2.less());
66257
67159
  }
66258
67160
  }),
66259
67161
  /* @__PURE__ */ LanguageDescription.of({
66260
67162
  name: "Liquid",
66261
67163
  extensions: ["liquid"],
66262
67164
  load() {
66263
- return import("./index-D4_mrv79.mjs").then((m2) => m2.liquid());
67165
+ return import("./index-pOvLJNkD.mjs").then((m2) => m2.liquid());
66264
67166
  }
66265
67167
  }),
66266
67168
  /* @__PURE__ */ LanguageDescription.of({
@@ -66292,7 +67194,7 @@ const languages = [
66292
67194
  name: "PHP",
66293
67195
  extensions: ["php", "php3", "php4", "php5", "php7", "phtml"],
66294
67196
  load() {
66295
- return import("./index-BJJ7G1kH.mjs").then((m2) => m2.php());
67197
+ return import("./index-ya5Il1Qw.mjs").then((m2) => m2.php());
66296
67198
  }
66297
67199
  }),
66298
67200
  /* @__PURE__ */ LanguageDescription.of({
@@ -66313,28 +67215,28 @@ const languages = [
66313
67215
  extensions: ["BUILD", "bzl", "py", "pyw"],
66314
67216
  filename: /^(BUCK|BUILD)$/,
66315
67217
  load() {
66316
- return import("./index-BIuNzHq0.mjs").then((m2) => m2.python());
67218
+ return import("./index-DHgyBRn8.mjs").then((m2) => m2.python());
66317
67219
  }
66318
67220
  }),
66319
67221
  /* @__PURE__ */ LanguageDescription.of({
66320
67222
  name: "Rust",
66321
67223
  extensions: ["rs"],
66322
67224
  load() {
66323
- return import("./index-UOZNryNK.mjs").then((m2) => m2.rust());
67225
+ return import("./index-CkfLio6C.mjs").then((m2) => m2.rust());
66324
67226
  }
66325
67227
  }),
66326
67228
  /* @__PURE__ */ LanguageDescription.of({
66327
67229
  name: "Sass",
66328
67230
  extensions: ["sass"],
66329
67231
  load() {
66330
- return import("./index-wJLOQ-wI.mjs").then((m2) => m2.sass({ indented: true }));
67232
+ return import("./index-DknIur64.mjs").then((m2) => m2.sass({ indented: true }));
66331
67233
  }
66332
67234
  }),
66333
67235
  /* @__PURE__ */ LanguageDescription.of({
66334
67236
  name: "SCSS",
66335
67237
  extensions: ["scss"],
66336
67238
  load() {
66337
- return import("./index-wJLOQ-wI.mjs").then((m2) => m2.sass());
67239
+ return import("./index-DknIur64.mjs").then((m2) => m2.sass());
66338
67240
  }
66339
67241
  }),
66340
67242
  /* @__PURE__ */ LanguageDescription.of({
@@ -66369,7 +67271,7 @@ const languages = [
66369
67271
  name: "WebAssembly",
66370
67272
  extensions: ["wat", "wast"],
66371
67273
  load() {
66372
- return import("./index-BW6WQkYN.mjs").then((m2) => m2.wast());
67274
+ return import("./index-D6humb3h.mjs").then((m2) => m2.wast());
66373
67275
  }
66374
67276
  }),
66375
67277
  /* @__PURE__ */ LanguageDescription.of({
@@ -66377,7 +67279,7 @@ const languages = [
66377
67279
  alias: ["rss", "wsdl", "xsd"],
66378
67280
  extensions: ["xml", "xsl", "xsd", "svg"],
66379
67281
  load() {
66380
- return import("./index-DAPqny2s.mjs").then((m2) => m2.xml());
67282
+ return import("./index-B3DxZAFq.mjs").then((m2) => m2.xml());
66381
67283
  }
66382
67284
  }),
66383
67285
  /* @__PURE__ */ LanguageDescription.of({
@@ -66385,7 +67287,7 @@ const languages = [
66385
67287
  alias: ["yml"],
66386
67288
  extensions: ["yaml", "yml"],
66387
67289
  load() {
66388
- return import("./index-D51jpGiF.mjs").then((m2) => m2.yaml());
67290
+ return import("./index-DQrGwq4Z.mjs").then((m2) => m2.yaml());
66389
67291
  }
66390
67292
  }),
66391
67293
  // Legacy modes ported from CodeMirror 5
@@ -67181,13 +68083,13 @@ const languages = [
67181
68083
  name: "Vue",
67182
68084
  extensions: ["vue"],
67183
68085
  load() {
67184
- return import("./index-D6ztvlVx.mjs").then((m2) => m2.vue());
68086
+ return import("./index-CeFBm9ea.mjs").then((m2) => m2.vue());
67185
68087
  }
67186
68088
  }),
67187
68089
  /* @__PURE__ */ LanguageDescription.of({
67188
68090
  name: "Angular Template",
67189
68091
  load() {
67190
- return import("./index-BvQvCT4b.mjs").then((m2) => m2.angular());
68092
+ return import("./index-u_Dj56FR.mjs").then((m2) => m2.angular());
67191
68093
  }
67192
68094
  })
67193
68095
  ];
@@ -68462,7 +69364,7 @@ class NodeRange {
68462
69364
  }
68463
69365
  }
68464
69366
  const emptyAttrs = /* @__PURE__ */ Object.create(null);
68465
- let Node$1 = class Node3 {
69367
+ let Node$1 = class Node4 {
68466
69368
  /**
68467
69369
  @internal
68468
69370
  */
@@ -68592,14 +69494,14 @@ let Node$1 = class Node3 {
68592
69494
  copy(content2 = null) {
68593
69495
  if (content2 == this.content)
68594
69496
  return this;
68595
- return new Node3(this.type, this.attrs, content2, this.marks);
69497
+ return new Node4(this.type, this.attrs, content2, this.marks);
68596
69498
  }
68597
69499
  /**
68598
69500
  Create a copy of this node, with the given set of marks instead
68599
69501
  of the node's own marks.
68600
69502
  */
68601
69503
  mark(marks) {
68602
- return marks == this.marks ? this : new Node3(this.type, this.attrs, this.content, marks);
69504
+ return marks == this.marks ? this : new Node4(this.type, this.attrs, this.content, marks);
68603
69505
  }
68604
69506
  /**
68605
69507
  Create a copy of this node with only the content between the
@@ -85677,9 +86579,9 @@ function switchEditable(view, node2, state) {
85677
86579
  function safariDownArrowBug(view) {
85678
86580
  if (!safari$1 || view.state.selection.$head.parentOffset > 0)
85679
86581
  return false;
85680
- let { focusNode, focusOffset } = view.domSelectionRange();
85681
- if (focusNode && focusNode.nodeType == 1 && focusOffset == 0 && focusNode.firstChild && focusNode.firstChild.contentEditable == "false") {
85682
- let child = focusNode.firstChild;
86582
+ let { focusNode: focusNode2, focusOffset } = view.domSelectionRange();
86583
+ if (focusNode2 && focusNode2.nodeType == 1 && focusOffset == 0 && focusNode2.firstChild && focusNode2.firstChild.contentEditable == "false") {
86584
+ let child = focusNode2.firstChild;
85683
86585
  switchEditable(view, child, "true");
85684
86586
  setTimeout(() => switchEditable(view, child, "false"), 20);
85685
86587
  }
@@ -87460,10 +88362,10 @@ class DOMObserver2 {
87460
88362
  else
87461
88363
  a2.remove();
87462
88364
  } else {
87463
- let { focusNode } = this.currentSelection;
88365
+ let { focusNode: focusNode2 } = this.currentSelection;
87464
88366
  for (let br of brs) {
87465
88367
  let parent = br.parentNode;
87466
- if (parent && parent.nodeName == "LI" && (!focusNode || blockParent(view, focusNode) != parent))
88368
+ if (parent && parent.nodeName == "LI" && (!focusNode2 || blockParent(view, focusNode2) != parent))
87467
88369
  br.remove();
87468
88370
  }
87469
88371
  }
@@ -87551,11 +88453,11 @@ function checkCSS(view) {
87551
88453
  }
87552
88454
  function rangeToSelectionRange(view, range3) {
87553
88455
  let anchorNode = range3.startContainer, anchorOffset = range3.startOffset;
87554
- let focusNode = range3.endContainer, focusOffset = range3.endOffset;
88456
+ let focusNode2 = range3.endContainer, focusOffset = range3.endOffset;
87555
88457
  let currentAnchor = view.domAtPos(view.state.selection.anchor);
87556
- if (isEquivalentPosition(currentAnchor.node, currentAnchor.offset, focusNode, focusOffset))
87557
- [anchorNode, anchorOffset, focusNode, focusOffset] = [focusNode, focusOffset, anchorNode, anchorOffset];
87558
- return { anchorNode, anchorOffset, focusNode, focusOffset };
88458
+ if (isEquivalentPosition(currentAnchor.node, currentAnchor.offset, focusNode2, focusOffset))
88459
+ [anchorNode, anchorOffset, focusNode2, focusOffset] = [focusNode2, focusOffset, anchorNode, anchorOffset];
88460
+ return { anchorNode, anchorOffset, focusNode: focusNode2, focusOffset };
87559
88461
  }
87560
88462
  function safariShadowSelectionRange(view, selection2) {
87561
88463
  if (selection2.getComposedRanges) {
@@ -92699,7 +93601,7 @@ function createDOMPurify() {
92699
93601
  const {
92700
93602
  DocumentFragment: DocumentFragment2,
92701
93603
  HTMLTemplateElement,
92702
- Node: Node4,
93604
+ Node: Node5,
92703
93605
  Element: Element3,
92704
93606
  NodeFilter: NodeFilter2,
92705
93607
  NamedNodeMap = window2.NamedNodeMap || window2.MozNamedAttrMap,
@@ -93078,7 +93980,7 @@ function createDOMPurify() {
93078
93980
  return element2 instanceof HTMLFormElement && (typeof element2.nodeName !== "string" || typeof element2.textContent !== "string" || typeof element2.removeChild !== "function" || !(element2.attributes instanceof NamedNodeMap) || typeof element2.removeAttribute !== "function" || typeof element2.setAttribute !== "function" || typeof element2.namespaceURI !== "string" || typeof element2.insertBefore !== "function" || typeof element2.hasChildNodes !== "function");
93079
93981
  };
93080
93982
  const _isNode = function _isNode2(value) {
93081
- return typeof Node4 === "function" && value instanceof Node4;
93983
+ return typeof Node5 === "function" && value instanceof Node5;
93082
93984
  };
93083
93985
  function _executeHooks(hooks2, currentNode, data2) {
93084
93986
  arrayForEach(hooks2, (hook) => {
@@ -93327,7 +94229,7 @@ function createDOMPurify() {
93327
94229
  throw typeErrorCreate("root node is forbidden and cannot be sanitized in-place");
93328
94230
  }
93329
94231
  }
93330
- } else if (dirty instanceof Node4) {
94232
+ } else if (dirty instanceof Node5) {
93331
94233
  body = _initDocument("<!---->");
93332
94234
  importedNode = body.ownerDocument.importNode(dirty, true);
93333
94235
  if (importedNode.nodeType === NODE_TYPE.element && importedNode.nodeName === "BODY") {
@@ -127323,6 +128225,7 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
127323
128225
  const emit = __emit;
127324
128226
  let crepeInstance = null;
127325
128227
  const crepeMounted = ref(false);
128228
+ let isUpdatingFromParent = false;
127326
128229
  const { currentZIndex } = useZIndex();
127327
128230
  useEditor((root2) => {
127328
128231
  var _a2;
@@ -127339,7 +128242,10 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
127339
128242
  }
127340
128243
  });
127341
128244
  if (props.useParameters || ((_a2 = props.parameters) == null ? void 0 : _a2.length)) {
127342
- crepe.editor.use(useMustachePlugin(replaceTest, widgetViewFactory));
128245
+ try {
128246
+ crepe.editor.use(useMustachePlugin(replaceTest, widgetViewFactory));
128247
+ } catch (error) {
128248
+ }
127343
128249
  }
127344
128250
  crepe.editor.use(rtlCursorPlugin);
127345
128251
  const originalGetMarkdown = crepe.getMarkdown.bind(crepe);
@@ -127352,12 +128258,15 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
127352
128258
  crepe.on((listener2) => {
127353
128259
  listener2.markdownUpdated(
127354
128260
  () => {
127355
- if (props.readonly || props.disabled) {
128261
+ if (props.readonly || props.disabled || isUpdatingFromParent) {
127356
128262
  return;
127357
128263
  }
127358
- const currentMarkdown = crepe.getMarkdown();
127359
- emit("change", currentMarkdown);
127360
- emit("update:modelValue", currentMarkdown);
128264
+ try {
128265
+ const currentMarkdown = crepe.getMarkdown();
128266
+ emit("change", currentMarkdown);
128267
+ emit("update:modelValue", currentMarkdown);
128268
+ } catch (e3) {
128269
+ }
127361
128270
  const htmlOutput = getHTMLFromEditor(crepe);
127362
128271
  emit("update:html", htmlOutput);
127363
128272
  }
@@ -127384,7 +128293,19 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
127384
128293
  }
127385
128294
  const currentMarkdown = crepeInstance.getMarkdown();
127386
128295
  if (currentMarkdown !== value) {
127387
- crepeInstance.editor.action(replaceAll$1(value));
128296
+ isUpdatingFromParent = true;
128297
+ try {
128298
+ crepeInstance.editor.action(replaceAll$1(value));
128299
+ } catch (error) {
128300
+ } finally {
128301
+ if (crepeInstance && crepeMounted.value) {
128302
+ const htmlOutput = getHTMLFromEditor(crepeInstance);
128303
+ emit("update:html", htmlOutput);
128304
+ }
128305
+ nextTick(() => {
128306
+ isUpdatingFromParent = false;
128307
+ });
128308
+ }
127388
128309
  }
127389
128310
  }
127390
128311
  function addBlockType(actionType) {
@@ -127443,7 +128364,8 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
127443
128364
  }
127444
128365
  watch(
127445
128366
  () => props.modelValue,
127446
- updateCrepeValue
128367
+ updateCrepeValue,
128368
+ { flush: "post" }
127447
128369
  );
127448
128370
  watch(
127449
128371
  crepeMounted,
@@ -134779,6 +135701,9 @@ var oe = defineComponent({
134779
135701
  );
134780
135702
  }
134781
135703
  });
135704
+ function isGroupParameter(item) {
135705
+ return "options" in item && Array.isArray(item.options);
135706
+ }
134782
135707
  const _hoisted_1$j = { class: "vc-markdown-editor__toolbar flex items-center divide-x divide-ui-lines space h-full" };
134783
135708
  const _hoisted_2$b = { class: "flex items-center px-1" };
134784
135709
  const _hoisted_3$b = { class: "hidden md:inline-flex" };
@@ -134797,7 +135722,10 @@ const _hoisted_14$2 = {
134797
135722
  class: "flex items-center gap-1 px-1"
134798
135723
  };
134799
135724
  const _hoisted_15$2 = { class: "hidden md:inline-flex" };
134800
- const _hoisted_16 = { class: "p-2 rounded divide-y divide-ui-lines max-h-96 overflow-x-auto" };
135725
+ const _hoisted_16 = {
135726
+ key: 1,
135727
+ class: "p-2 rounded divide-y divide-ui-lines max-h-96 overflow-x-auto"
135728
+ };
134801
135729
  const _hoisted_17 = { class: "w-full flex items-center gap-2" };
134802
135730
  const _hoisted_18 = { class: "capitalize" };
134803
135731
  const _hoisted_19 = { key: 1 };
@@ -134807,6 +135735,9 @@ const _hoisted_22 = { class: "p-2 rounded divide-y divide-ui-lines" };
134807
135735
  const _hoisted_23 = { class: "py-0.5" };
134808
135736
  const _hoisted_24 = { class: "py-0.5" };
134809
135737
  const _hoisted_25 = { class: "py-0.5" };
135738
+ const CASCADER_ACTION_OPENING = "__opening__";
135739
+ const CASCADER_ACTION_CLOSING = "__closing__";
135740
+ const CASCADER_ACTION_VALUE = "__value__";
134810
135741
  const NAV_ACTIONS_COLOR = "primary";
134811
135742
  const _sfc_main$j = /* @__PURE__ */ defineComponent({
134812
135743
  __name: "VcMdEditorToolbar",
@@ -134825,7 +135756,111 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
134825
135756
  const listActionsTooltipRef = ref();
134826
135757
  const addActionsTooltipRef = ref();
134827
135758
  const paramsActionsTooltipRef = ref();
135759
+ const cascaderValue = ref([]);
135760
+ const props = __props;
134828
135761
  const emit = __emit;
135762
+ const isGrouped = computed(() => {
135763
+ var _a2;
135764
+ return ((_a2 = props.parameters) == null ? void 0 : _a2.some((item) => isGroupParameter(item))) ?? false;
135765
+ });
135766
+ const flatParameters = computed(() => {
135767
+ if (!props.parameters) return [];
135768
+ return props.parameters.filter(
135769
+ (item) => !isGroupParameter(item)
135770
+ );
135771
+ });
135772
+ const parameterMap = computed(() => {
135773
+ const map3 = /* @__PURE__ */ new Map();
135774
+ if (!props.parameters) return map3;
135775
+ for (const item of props.parameters) {
135776
+ if (isGroupParameter(item)) {
135777
+ for (const option of item.options) {
135778
+ map3.set(option.tag, option);
135779
+ }
135780
+ } else {
135781
+ map3.set(item.tag, item);
135782
+ }
135783
+ }
135784
+ return map3;
135785
+ });
135786
+ const cascaderProps = {
135787
+ expandTrigger: "click",
135788
+ emitPath: true,
135789
+ value: "value",
135790
+ label: "label",
135791
+ children: "children"
135792
+ };
135793
+ const cascaderOptions = computed(() => {
135794
+ if (!props.parameters) return [];
135795
+ return props.parameters.map((item) => {
135796
+ if (isGroupParameter(item)) {
135797
+ return {
135798
+ value: item.label,
135799
+ label: item.label,
135800
+ children: item.options.map(buildParameterCascaderNode)
135801
+ };
135802
+ }
135803
+ return buildParameterCascaderNode(item);
135804
+ });
135805
+ });
135806
+ function buildParameterCascaderNode(param) {
135807
+ if (param.schema) {
135808
+ return {
135809
+ value: param.tag,
135810
+ label: param.label,
135811
+ leaf: true
135812
+ };
135813
+ }
135814
+ return {
135815
+ value: param.tag,
135816
+ label: param.label,
135817
+ children: [
135818
+ {
135819
+ value: CASCADER_ACTION_OPENING,
135820
+ label: "Opening If",
135821
+ leaf: true
135822
+ },
135823
+ {
135824
+ value: CASCADER_ACTION_CLOSING,
135825
+ label: "Closing If",
135826
+ leaf: true
135827
+ },
135828
+ {
135829
+ value: CASCADER_ACTION_VALUE,
135830
+ label: "Value",
135831
+ leaf: true
135832
+ }
135833
+ ]
135834
+ };
135835
+ }
135836
+ function onCascaderChange(value) {
135837
+ var _a2, _b;
135838
+ if (!value || !Array.isArray(value) || !value.length) return;
135839
+ const path2 = value;
135840
+ const isGroupedData = (_a2 = props.parameters) == null ? void 0 : _a2.some((item) => isGroupParameter(item));
135841
+ let paramTag;
135842
+ let action;
135843
+ if (isGroupedData && path2.length >= 2) {
135844
+ paramTag = path2[1];
135845
+ action = path2[2];
135846
+ } else {
135847
+ paramTag = path2[0];
135848
+ action = path2[1];
135849
+ }
135850
+ const parameter = parameterMap.value.get(paramTag);
135851
+ if (!parameter) return;
135852
+ let insertState;
135853
+ if (action === CASCADER_ACTION_OPENING) {
135854
+ insertState = "opening";
135855
+ } else if (action === CASCADER_ACTION_CLOSING) {
135856
+ insertState = "closing";
135857
+ }
135858
+ emit("insert-parameter", parameter, insertState);
135859
+ (_b = parameterPopoverRef.value) == null ? void 0 : _b.hide();
135860
+ nextTick(() => {
135861
+ cascaderValue.value = [];
135862
+ });
135863
+ }
134829
135864
  function closeAllPopovers() {
134830
135865
  var _a2, _b, _c;
134831
135866
  (_a2 = headingPopoverRef.value) == null ? void 0 : _a2.hide();
@@ -135019,9 +136054,10 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135019
136054
  teleported: _ctx7.isTeleported,
135020
136055
  disabled: _ctx7.disabled,
135021
136056
  trigger: "click",
136057
+ "popover-class": "vc-markdown-editor__parameter-popover",
135022
136058
  placement: "bottom",
135023
136059
  "popover-width": "auto",
135024
- "popover-max-width": "420px"
136060
+ "popover-max-width": isGrouped.value ? "600px" : "420px"
135025
136061
  }, {
135026
136062
  reference: withCtx(() => [
135027
136063
  createVNode(_component_VcButton, {
@@ -135039,8 +136075,17 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135039
136075
  }, 512)
135040
136076
  ]),
135041
136077
  default: withCtx(() => [
135042
- createElementVNode("div", _hoisted_16, [
135043
- (openBlock(true), createElementBlock(Fragment$1, null, renderList(_ctx7.parameters, (parameter, index2) => {
136078
+ isGrouped.value ? (openBlock(), createBlock(unref(ElCascaderPanel), {
136079
+ key: 0,
136080
+ modelValue: cascaderValue.value,
136081
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => cascaderValue.value = $event),
136082
+ options: cascaderOptions.value,
136083
+ props: cascaderProps,
136084
+ teleported: _ctx7.isTeleported,
136085
+ class: "vc-markdown-editor__cascader-panel",
136086
+ onChange: onCascaderChange
136087
+ }, null, 8, ["modelValue", "options", "teleported"])) : (openBlock(), createElementBlock("div", _hoisted_16, [
136088
+ (openBlock(true), createElementBlock(Fragment$1, null, renderList(flatParameters.value, (parameter, index2) => {
135044
136089
  return openBlock(), createElementBlock("div", {
135045
136090
  key: `${parameter.tag}-${index2}`,
135046
136091
  class: "py-0.5"
@@ -135054,7 +136099,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135054
136099
  }, {
135055
136100
  default: withCtx(() => [
135056
136101
  createElementVNode("div", _hoisted_17, [
135057
- _cache[0] || (_cache[0] = createElementVNode("i", { class: "vc-lc-braces" }, null, -1)),
136102
+ _cache[1] || (_cache[1] = createElementVNode("i", { class: "vc-lc-braces" }, null, -1)),
135058
136103
  createElementVNode("span", _hoisted_18, toDisplayString(parameter.label), 1)
135059
136104
  ])
135060
136105
  ]),
@@ -135075,7 +136120,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135075
136120
  default: withCtx(() => [
135076
136121
  createElementVNode("div", _hoisted_20, [
135077
136122
  createElementVNode("span", _hoisted_21, toDisplayString(parameter.label), 1),
135078
- _cache[1] || (_cache[1] = createElementVNode("i", { class: "vc-lc-chevron-right" }, null, -1))
136123
+ _cache[2] || (_cache[2] = createElementVNode("i", { class: "vc-lc-chevron-right" }, null, -1))
135079
136124
  ])
135080
136125
  ]),
135081
136126
  _: 2
@@ -135090,7 +136135,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135090
136135
  type: "borderless",
135091
136136
  onClick: ($event) => handleInsertParameter(parameter, "opening")
135092
136137
  }, {
135093
- default: withCtx(() => [..._cache[2] || (_cache[2] = [
136138
+ default: withCtx(() => [..._cache[3] || (_cache[3] = [
135094
136139
  createElementVNode("div", { class: "w-full flex items-center gap-2" }, [
135095
136140
  createElementVNode("span", { class: "capitalize" }, "Opening If")
135096
136141
  ], -1)
@@ -135105,7 +136150,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135105
136150
  type: "borderless",
135106
136151
  onClick: ($event) => handleInsertParameter(parameter, "closing")
135107
136152
  }, {
135108
- default: withCtx(() => [..._cache[3] || (_cache[3] = [
136153
+ default: withCtx(() => [..._cache[4] || (_cache[4] = [
135109
136154
  createElementVNode("div", { class: "w-full flex items-center gap-2" }, [
135110
136155
  createElementVNode("span", { class: "capitalize" }, "Closing If")
135111
136156
  ], -1)
@@ -135120,7 +136165,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135120
136165
  type: "borderless",
135121
136166
  onClick: ($event) => handleInsertParameter(parameter)
135122
136167
  }, {
135123
- default: withCtx(() => [..._cache[4] || (_cache[4] = [
136168
+ default: withCtx(() => [..._cache[5] || (_cache[5] = [
135124
136169
  createElementVNode("div", { class: "w-full flex items-center gap-2" }, [
135125
136170
  createElementVNode("span", { class: "capitalize" }, "Value")
135126
136171
  ], -1)
@@ -135135,10 +136180,10 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
135135
136180
  ]))
135136
136181
  ]);
135137
136182
  }), 128))
135138
- ])
136183
+ ]))
135139
136184
  ]),
135140
136185
  _: 1
135141
- }, 8, ["teleported", "disabled"])
136186
+ }, 8, ["teleported", "disabled", "popover-max-width"])
135142
136187
  ])) : createCommentVNode("", true),
135143
136188
  createVNode(unref(ElTooltip), {
135144
136189
  content: _ctx7.$tVU.t("voicenterUi.mdEditor.toolbar.textActions"),
@@ -135184,15 +136229,16 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
135184
136229
  ...{ inheritAttrs: false },
135185
136230
  __name: "VcMdEditor",
135186
136231
  props: {
135187
- modelValue: {},
135188
- html: {},
135189
- disabled: { type: Boolean },
135190
- useParameters: { type: Boolean },
135191
- minHeight: {},
135192
- maxHeight: {},
135193
- parameters: {},
135194
- isTeleported: { type: Boolean },
135195
- readonly: { type: Boolean }
136232
+ modelValue: { default: "" },
136233
+ html: { default: "" },
136234
+ disabled: { type: Boolean, default: false },
136235
+ useParameters: { type: Boolean, default: false },
136236
+ minHeight: { default: 400 },
136237
+ maxHeight: { default: void 0 },
136238
+ parameters: { default: void 0 },
136239
+ isTeleported: { type: Boolean, default: void 0 },
136240
+ readonly: { type: Boolean },
136241
+ hideToolbar: { type: Boolean }
135196
136242
  },
135197
136243
  emits: ["update:modelValue", "update:html"],
135198
136244
  setup(__props, { expose: __expose, emit: __emit }) {
@@ -135206,6 +136252,18 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
135206
136252
  const mounted = ref(false);
135207
136253
  const milkdownEditorContentRef = ref();
135208
136254
  const alignMode = ref("ltr");
136255
+ const flatParameters = computed(() => {
136256
+ if (!props.parameters) return void 0;
136257
+ const result2 = [];
136258
+ for (const item of props.parameters) {
136259
+ if (isGroupParameter(item)) {
136260
+ result2.push(...item.options);
136261
+ } else {
136262
+ result2.push(item);
136263
+ }
136264
+ }
136265
+ return result2;
136266
+ });
135209
136267
  const minHeightProperty = computed(() => {
135210
136268
  return convertToUnit(props.minHeight || 400);
135211
136269
  });
@@ -135310,7 +136368,7 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
135310
136368
  "--max-md-height": maxHeightProperty.value
135311
136369
  })
135312
136370
  }, [
135313
- !_ctx7.disabled ? (openBlock(), createElementBlock("div", _hoisted_1$i, [
136371
+ !_ctx7.disabled && !_ctx7.hideToolbar ? (openBlock(), createElementBlock("div", _hoisted_1$i, [
135314
136372
  createElementVNode("div", _hoisted_2$a, [
135315
136373
  editorMode.value && !_ctx7.readonly ? (openBlock(), createBlock(_sfc_main$j, {
135316
136374
  key: 0,
@@ -135370,7 +136428,7 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
135370
136428
  "onUpdate:html": _cache[2] || (_cache[2] = ($event) => isRef(localHtml) ? localHtml.value = $event : null),
135371
136429
  disabled: _ctx7.disabled,
135372
136430
  "min-height": _ctx7.minHeight,
135373
- parameters: _ctx7.parameters,
136431
+ parameters: flatParameters.value,
135374
136432
  "use-parameters": _ctx7.useParameters,
135375
136433
  readonly: _ctx7.readonly
135376
136434
  }, unref(attributes)), null, 16, ["modelValue", "html", "disabled", "min-height", "parameters", "use-parameters", "readonly"])) : (openBlock(), createBlock(unref(oe), {
@@ -140011,7 +141069,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
140011
141069
  const components = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
140012
141070
  __proto__: null,
140013
141071
  VcAutocomplete: _sfc_main$1A,
140014
- VcButton: _sfc_main$2T,
141072
+ VcButton: _sfc_main$2W,
140015
141073
  VcButtonIcon,
140016
141074
  VcCard: _sfc_main$13,
140017
141075
  VcCheckbox: _sfc_main$1F,
@@ -140075,7 +141133,7 @@ const components = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePr
140075
141133
  VcTag: _sfc_main$1e,
140076
141134
  VcTagInput: _sfc_main$1d,
140077
141135
  VcTimeInput: _sfc_main$1h,
140078
- VcToggleButton: _sfc_main$2R,
141136
+ VcToggleButton: _sfc_main$2U,
140079
141137
  VcTransfer: _sfc_main$H,
140080
141138
  VcTree: _sfc_main$J,
140081
141139
  VcTreeSelect: _sfc_main$I,
@@ -149462,9 +150520,9 @@ export {
149462
150520
  subFp as af,
149463
150521
  useRTL as ag,
149464
150522
  buildMustacheSnippet as ah,
149465
- _sfc_main$2T as ai,
150523
+ _sfc_main$2W as ai,
149466
150524
  VcButtonIcon as aj,
149467
- _sfc_main$2R as ak,
150525
+ _sfc_main$2U as ak,
149468
150526
  _sfc_main$1L as al,
149469
150527
  _sfc_main$1K as am,
149470
150528
  _sfc_main$1J as an,
@@ -149481,6 +150539,7 @@ export {
149481
150539
  _sfc_main$1v as ay,
149482
150540
  _sfc_main$1u as az,
149483
150541
  LanguageSupport as b,
150542
+ _sfc_main$b as b$,
149484
150543
  VcTable as b0,
149485
150544
  _sfc_main$L as b1,
149486
150545
  _sfc_main$J as b2,
@@ -149491,33 +150550,33 @@ export {
149491
150550
  _sfc_main$E as b7,
149492
150551
  _sfc_main$D as b8,
149493
150552
  _sfc_main$C as b9,
149494
- iconSizes as bA,
149495
- DEFAULT_COMPONENT_SIZE as bB,
149496
- UPDATE_MODEL_EVENT as bC,
149497
- CHANGE_EVENT as bD,
149498
- INPUT_EVENT as bE,
149499
- EVENT_CODE as bF,
149500
- isComponentColor as bG,
149501
- EDITABLE_TAB_SUB_SECTION_QUERY_PARAM_NAME as bH,
149502
- LIST_TAB_QUERY_VALUE as bI,
149503
- CREATE_TAB_QUERY_VALUE as bJ,
149504
- TEXT_COLORS as bK,
149505
- DEFAULT_COLOR$8 as bL,
149506
- DEFAULT_SIZE$9 as bM,
149507
- DEFAULT_ICON_SIZE as bN,
149508
- CLASS_FOR_COLOR$3 as bO,
149509
- CLASS_FOR_ICON_COLOR$1 as bP,
149510
- CLASS_FOR_ICON_SIZE as bQ,
149511
- _sfc_main$1 as bR,
149512
- _sfc_main as bS,
149513
- _sfc_main$f as bT,
149514
- _sfc_main$e as bU,
149515
- _sfc_main$d as bV,
149516
- _sfc_main$c as bW,
149517
- _sfc_main$g as bX,
149518
- _sfc_main$a as bY,
149519
- _sfc_main$9 as bZ,
149520
- _sfc_main$b as b_,
150553
+ textSizes as bA,
150554
+ iconSizes as bB,
150555
+ DEFAULT_COMPONENT_SIZE as bC,
150556
+ UPDATE_MODEL_EVENT as bD,
150557
+ CHANGE_EVENT as bE,
150558
+ INPUT_EVENT as bF,
150559
+ EVENT_CODE as bG,
150560
+ isComponentColor as bH,
150561
+ EDITABLE_TAB_SUB_SECTION_QUERY_PARAM_NAME as bI,
150562
+ LIST_TAB_QUERY_VALUE as bJ,
150563
+ CREATE_TAB_QUERY_VALUE as bK,
150564
+ TEXT_COLORS as bL,
150565
+ DEFAULT_COLOR$8 as bM,
150566
+ DEFAULT_SIZE$9 as bN,
150567
+ DEFAULT_ICON_SIZE as bO,
150568
+ CLASS_FOR_COLOR$3 as bP,
150569
+ CLASS_FOR_ICON_COLOR$1 as bQ,
150570
+ CLASS_FOR_ICON_SIZE as bR,
150571
+ _sfc_main$1 as bS,
150572
+ _sfc_main as bT,
150573
+ _sfc_main$f as bU,
150574
+ _sfc_main$e as bV,
150575
+ _sfc_main$d as bW,
150576
+ _sfc_main$c as bX,
150577
+ _sfc_main$g as bY,
150578
+ _sfc_main$a as bZ,
150579
+ _sfc_main$9 as b_,
149521
150580
  VcLoading as ba,
149522
150581
  _sfc_main$B as bb,
149523
150582
  _sfc_main$A as bc,
@@ -149541,9 +150600,9 @@ export {
149541
150600
  VcTabPaneProvideKey as bu,
149542
150601
  VcRTLToken as bv,
149543
150602
  VcSoundPlayerProvideKey as bw,
149544
- componentSizes as bx,
149545
- componentColors as by,
149546
- textSizes as bz,
150603
+ isGroupParameter as bx,
150604
+ componentSizes as by,
150605
+ componentColors as bz,
149547
150606
  continuedIndent as c,
149548
150607
  ifNotIn as d,
149549
150608
  completeFromList as e,