lew-ui 2.7.59 → 2.7.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -14851,7 +14851,8 @@ const _sfc_main$T = /* @__PURE__ */ defineComponent({
14851
14851
  }
14852
14852
  });
14853
14853
  const selectedItemsText = computed(() => {
14854
- if (!hasSelectedItems.value) return "";
14854
+ if (!hasSelectedItems.value)
14855
+ return "";
14855
14856
  if (props.multiple) {
14856
14857
  return "";
14857
14858
  } else {
@@ -14996,7 +14997,7 @@ const _sfc_main$T = /* @__PURE__ */ defineComponent({
14996
14997
  };
14997
14998
  }
14998
14999
  });
14999
- const CommonInput = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["__scopeId", "data-v-f8a0c098"]]);
15000
+ const CommonInput = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["__scopeId", "data-v-51b98d83"]]);
15000
15001
  function vue3h(ele, props, children) {
15001
15002
  const { attrs, on, ...rest } = props;
15002
15003
  let event = {};
@@ -16367,7 +16368,8 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
16367
16368
  }
16368
16369
  }
16369
16370
  async function selectItem(item, level) {
16370
- if (item.disabled) return;
16371
+ if (item.disabled)
16372
+ return;
16371
16373
  if (!item.isLeaf && !isEqual(item.valuePaths, state.activeValues)) {
16372
16374
  state.optionsGroup = state.optionsGroup.slice(0, level + 1);
16373
16375
  if (_loadMethod.value && !item.isLeaf) {
@@ -16427,7 +16429,8 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
16427
16429
  }, 100);
16428
16430
  }
16429
16431
  }
16430
- if (item.isLeaf) return;
16432
+ if (item.isLeaf)
16433
+ return;
16431
16434
  if (isEqual(item.valuePaths, state.activeValues)) {
16432
16435
  state.activeValues = item.parentValuePaths || [];
16433
16436
  if (level < state.optionsGroup.length - 1) {
@@ -16656,7 +16659,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
16656
16659
  };
16657
16660
  }
16658
16661
  });
16659
- const LewCascader = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-7f2ab0af"]]);
16662
+ const LewCascader = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-7cea69f7"]]);
16660
16663
  const cascaderModel = {
16661
16664
  modelValue: {
16662
16665
  type: String
@@ -29341,7 +29344,8 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
29341
29344
  }
29342
29345
  );
29343
29346
  async function handleClose() {
29344
- if (props.disabled || isClosing.value) return;
29347
+ if (props.disabled || isClosing.value)
29348
+ return;
29345
29349
  if (props.close) {
29346
29350
  isClosing.value = true;
29347
29351
  let result = false;
@@ -30453,8 +30457,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
30453
30457
  return proxy;
30454
30458
  }
30455
30459
  function clickItem(item) {
30456
- if (item.disabled)
30457
- return;
30460
+ if (item.disabled) return;
30458
30461
  const instance = props.dropdownInstance || window.LewContextMenu?.instance || null;
30459
30462
  if (isFunction$1(item.onClick)) {
30460
30463
  const proxyItem = createItemProxy(item);
@@ -30464,7 +30467,8 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
30464
30467
  }
30465
30468
  });
30466
30469
  item.onClick?.(proxyItem, proxyOptions, instance);
30467
- } else {
30470
+ }
30471
+ if (item.hideMenuOnClick || item.hideMenuOnClick === void 0) {
30468
30472
  instance?.hide();
30469
30473
  }
30470
30474
  emit("change", item);
@@ -30612,7 +30616,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
30612
30616
  };
30613
30617
  }
30614
30618
  });
30615
- const LewContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__scopeId", "data-v-10d9d549"]]);
30619
+ const LewContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__scopeId", "data-v-7dfed0eb"]]);
30616
30620
  const dropdownModel = {
30617
30621
  selectedKeys: {
30618
30622
  type: Array,
@@ -31195,8 +31199,10 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
31195
31199
  };
31196
31200
  });
31197
31201
  function handleClick(index2) {
31198
- if (!props.canClickItem) return;
31199
- if (!props.canCrossSteps && Math.abs((stepsValue.value || 1) - 1 - index2) > 1) return;
31202
+ if (!props.canClickItem)
31203
+ return;
31204
+ if (!props.canCrossSteps && Math.abs((stepsValue.value || 1) - 1 - index2) > 1)
31205
+ return;
31200
31206
  if (stepsValue.value !== index2 + 1) {
31201
31207
  stepsValue.value = index2 + 1;
31202
31208
  emit("change", stepsValue.value);