@deot/vc 1.0.63 → 1.0.64

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.
@@ -9138,16 +9138,16 @@ var Vc = (function (exports, vue) {
9138
9138
  }
9139
9139
  }
9140
9140
  const VcInstance = new Instance();
9141
- const props$1u = {
9141
+ const props$1v = {
9142
9142
  tag: {
9143
9143
  type: String,
9144
9144
  default: "div"
9145
9145
  }
9146
9146
  };
9147
- const COMPONENT_NAME$2b = "vc-action-sheet";
9147
+ const COMPONENT_NAME$2g = "vc-action-sheet";
9148
9148
  const ActionSheet = /* @__PURE__ */ vue.defineComponent({
9149
- name: COMPONENT_NAME$2b,
9150
- props: props$1u,
9149
+ name: COMPONENT_NAME$2g,
9150
+ props: props$1v,
9151
9151
  setup(props2, {
9152
9152
  slots
9153
9153
  }) {
@@ -9159,7 +9159,7 @@ var Vc = (function (exports, vue) {
9159
9159
  }
9160
9160
  });
9161
9161
  const MActionSheet = ActionSheet;
9162
- const props$1t = {
9162
+ const props$1u = {
9163
9163
  modelValue: {
9164
9164
  type: Boolean,
9165
9165
  default: false
@@ -9217,11 +9217,11 @@ var Vc = (function (exports, vue) {
9217
9217
  const isWheel = (el2) => {
9218
9218
  return SCROLLER_WHEEL_REG.test(el2?.className || "");
9219
9219
  };
9220
- const COMPONENT_NAME$2a = "vc-affix";
9220
+ const COMPONENT_NAME$2f = "vc-affix";
9221
9221
  const Affix = /* @__PURE__ */ vue.defineComponent({
9222
- name: COMPONENT_NAME$2a,
9222
+ name: COMPONENT_NAME$2f,
9223
9223
  emits: ["update:modelValue"],
9224
- props: props$1t,
9224
+ props: props$1u,
9225
9225
  setup(props2, {
9226
9226
  slots,
9227
9227
  expose,
@@ -9381,7 +9381,7 @@ var Vc = (function (exports, vue) {
9381
9381
  }
9382
9382
  });
9383
9383
  const MAffix = Affix;
9384
- const props$1s = {
9384
+ const props$1t = {
9385
9385
  modelValue: {
9386
9386
  type: Boolean,
9387
9387
  default: true
@@ -9407,7 +9407,7 @@ var Vc = (function (exports, vue) {
9407
9407
  default: false
9408
9408
  }
9409
9409
  };
9410
- const props$1r = {
9410
+ const props$1s = {
9411
9411
  type: String,
9412
9412
  inherit: {
9413
9413
  type: Boolean,
@@ -9540,10 +9540,10 @@ var Vc = (function (exports, vue) {
9540
9540
  }
9541
9541
  }
9542
9542
  const IconManager = new Manager();
9543
- const COMPONENT_NAME$29 = "vc-icon";
9543
+ const COMPONENT_NAME$2e = "vc-icon";
9544
9544
  const Icon = /* @__PURE__ */ vue.defineComponent({
9545
- name: COMPONENT_NAME$29,
9546
- props: props$1r,
9545
+ name: COMPONENT_NAME$2e,
9546
+ props: props$1s,
9547
9547
  setup(props2) {
9548
9548
  const viewBox = vue.ref("0 0 1024 1024");
9549
9549
  const path = vue.ref([]);
@@ -9575,7 +9575,7 @@ var Vc = (function (exports, vue) {
9575
9575
  };
9576
9576
  }
9577
9577
  });
9578
- const props$1q = {
9578
+ const props$1r = {
9579
9579
  /**
9580
9580
  * 进入/离开持续时间
9581
9581
  * {enter: 300, leave: 300}
@@ -9738,10 +9738,10 @@ var Vc = (function (exports, vue) {
9738
9738
  }
9739
9739
  };
9740
9740
  };
9741
- const COMPONENT_NAME$28 = "vc-transition";
9741
+ const COMPONENT_NAME$2d = "vc-transition";
9742
9742
  const Transition = vue.defineComponent({
9743
- name: COMPONENT_NAME$28,
9744
- props: props$1q,
9743
+ name: COMPONENT_NAME$2d,
9744
+ props: props$1r,
9745
9745
  // 当不声明emits的情况下,事件存在于attrs中
9746
9746
  inheritAttrs: false,
9747
9747
  setup(props2, { slots, attrs }) {
@@ -9760,10 +9760,10 @@ var Vc = (function (exports, vue) {
9760
9760
  };
9761
9761
  }
9762
9762
  });
9763
- const COMPONENT_NAME$27 = "vc-transition-collapse";
9763
+ const COMPONENT_NAME$2c = "vc-transition-collapse";
9764
9764
  const TransitionCollapse = vue.defineComponent({
9765
- name: COMPONENT_NAME$27,
9766
- props: props$1q,
9765
+ name: COMPONENT_NAME$2c,
9766
+ props: props$1r,
9767
9767
  // 当不声明emits的情况下,事件存在于attrs中
9768
9768
  inheritAttrs: false,
9769
9769
  setup(props2, { slots, attrs: _attrs }) {
@@ -9876,11 +9876,11 @@ var Vc = (function (exports, vue) {
9876
9876
  };
9877
9877
  }
9878
9878
  });
9879
- const COMPONENT_NAME$26 = "vc-transition-fade";
9879
+ const COMPONENT_NAME$2b = "vc-transition-fade";
9880
9880
  const TransitionFade = vue.defineComponent({
9881
- name: COMPONENT_NAME$26,
9881
+ name: COMPONENT_NAME$2b,
9882
9882
  props: {
9883
- ...props$1q,
9883
+ ...props$1r,
9884
9884
  // inheritAttrs必须是false
9885
9885
  style: {
9886
9886
  type: Object,
@@ -9912,11 +9912,11 @@ var Vc = (function (exports, vue) {
9912
9912
  };
9913
9913
  }
9914
9914
  });
9915
- const COMPONENT_NAME$25 = "vc-transition-scale";
9915
+ const COMPONENT_NAME$2a = "vc-transition-scale";
9916
9916
  const TransitionScale = vue.defineComponent({
9917
- name: COMPONENT_NAME$25,
9917
+ name: COMPONENT_NAME$2a,
9918
9918
  props: {
9919
- ...props$1q,
9919
+ ...props$1r,
9920
9920
  mode: {
9921
9921
  type: String,
9922
9922
  default: "both",
@@ -9953,11 +9953,11 @@ var Vc = (function (exports, vue) {
9953
9953
  };
9954
9954
  }
9955
9955
  });
9956
- const COMPONENT_NAME$24 = "vc-transition-slide";
9956
+ const COMPONENT_NAME$29 = "vc-transition-slide";
9957
9957
  const TransitionSlide = vue.defineComponent({
9958
- name: COMPONENT_NAME$24,
9958
+ name: COMPONENT_NAME$29,
9959
9959
  props: {
9960
- ...props$1q,
9960
+ ...props$1r,
9961
9961
  mode: {
9962
9962
  type: String,
9963
9963
  default: "left",
@@ -9994,11 +9994,11 @@ var Vc = (function (exports, vue) {
9994
9994
  };
9995
9995
  }
9996
9996
  });
9997
- const COMPONENT_NAME$23 = "vc-transition-zoom";
9997
+ const COMPONENT_NAME$28 = "vc-transition-zoom";
9998
9998
  const TransitionZoom = vue.defineComponent({
9999
- name: COMPONENT_NAME$23,
9999
+ name: COMPONENT_NAME$28,
10000
10000
  props: {
10001
- ...props$1q,
10001
+ ...props$1r,
10002
10002
  mode: {
10003
10003
  type: String,
10004
10004
  default: "x",
@@ -10035,7 +10035,7 @@ var Vc = (function (exports, vue) {
10035
10035
  };
10036
10036
  }
10037
10037
  });
10038
- const COMPONENT_NAME$22 = "vc-alert";
10038
+ const COMPONENT_NAME$27 = "vc-alert";
10039
10039
  const THEME_MAP = {
10040
10040
  info: ["#456CF6", "#91d5ff", "#e6f7ff"],
10041
10041
  success: ["#52c41a", "#b7eb8f", "#f6ffed"],
@@ -10043,8 +10043,8 @@ var Vc = (function (exports, vue) {
10043
10043
  warning: ["#ffbf00", "#ffe58f", "#fffbe6"]
10044
10044
  };
10045
10045
  const Alert = /* @__PURE__ */ vue.defineComponent({
10046
- name: COMPONENT_NAME$22,
10047
- props: props$1s,
10046
+ name: COMPONENT_NAME$27,
10047
+ props: props$1t,
10048
10048
  setup(props2, {
10049
10049
  slots,
10050
10050
  emit
@@ -10130,7 +10130,7 @@ var Vc = (function (exports, vue) {
10130
10130
  }
10131
10131
  });
10132
10132
  const MAlert = Alert;
10133
- const props$1p = {
10133
+ const props$1q = {
10134
10134
  // canvas配置参数
10135
10135
  options: Object,
10136
10136
  width: {
@@ -10143,10 +10143,10 @@ var Vc = (function (exports, vue) {
10143
10143
  }
10144
10144
  };
10145
10145
  const isTouch = typeof document !== "undefined" && "ontouchend" in document;
10146
- const COMPONENT_NAME$21 = "vc-artboard";
10146
+ const COMPONENT_NAME$26 = "vc-artboard";
10147
10147
  const Artboard = /* @__PURE__ */ vue.defineComponent({
10148
- name: COMPONENT_NAME$21,
10149
- props: props$1p,
10148
+ name: COMPONENT_NAME$26,
10149
+ props: props$1q,
10150
10150
  setup(props2, {
10151
10151
  emit,
10152
10152
  expose
@@ -10321,7 +10321,7 @@ var Vc = (function (exports, vue) {
10321
10321
  }
10322
10322
  });
10323
10323
  const MArtboard = Artboard;
10324
- const props$1o = {
10324
+ const props$1p = {
10325
10325
  size: {
10326
10326
  type: Number,
10327
10327
  default: 28
@@ -10342,10 +10342,10 @@ var Vc = (function (exports, vue) {
10342
10342
  default: false
10343
10343
  }
10344
10344
  };
10345
- const COMPONENT_NAME$20 = "vc-spin";
10345
+ const COMPONENT_NAME$25 = "vc-spin";
10346
10346
  const Spin = /* @__PURE__ */ vue.defineComponent({
10347
- name: COMPONENT_NAME$20,
10348
- props: props$1o,
10347
+ name: COMPONENT_NAME$25,
10348
+ props: props$1p,
10349
10349
  setup(props2, {
10350
10350
  slots
10351
10351
  }) {
@@ -10378,7 +10378,7 @@ var Vc = (function (exports, vue) {
10378
10378
  };
10379
10379
  }
10380
10380
  });
10381
- const props$1n = {
10381
+ const props$1o = {
10382
10382
  wait: {
10383
10383
  type: Number,
10384
10384
  default: 250
@@ -10393,10 +10393,10 @@ var Vc = (function (exports, vue) {
10393
10393
  },
10394
10394
  exclude: RegExp
10395
10395
  };
10396
- const COMPONENT_NAME$1$ = "vc-debounce";
10396
+ const COMPONENT_NAME$24 = "vc-debounce";
10397
10397
  const Debounce = vue.defineComponent({
10398
- name: COMPONENT_NAME$1$,
10399
- props: props$1n,
10398
+ name: COMPONENT_NAME$24,
10399
+ props: props$1o,
10400
10400
  /**
10401
10401
  * 不声明emits使得事件被透传放入attrs中, 这样可以让所有的事件透传
10402
10402
  * 如事件onClick
@@ -10435,7 +10435,7 @@ var Vc = (function (exports, vue) {
10435
10435
  };
10436
10436
  }
10437
10437
  });
10438
- const props$1m = {
10438
+ const props$1n = {
10439
10439
  tag: {
10440
10440
  type: String,
10441
10441
  default: "button"
@@ -10464,11 +10464,11 @@ var Vc = (function (exports, vue) {
10464
10464
  default: "button"
10465
10465
  }
10466
10466
  };
10467
- const COMPONENT_NAME$1_ = "vc-button";
10467
+ const COMPONENT_NAME$23 = "vc-button";
10468
10468
  const Button = /* @__PURE__ */ vue.defineComponent({
10469
- name: COMPONENT_NAME$1_,
10469
+ name: COMPONENT_NAME$23,
10470
10470
  emits: ["click"],
10471
- props: props$1m,
10471
+ props: props$1n,
10472
10472
  setup(props2, {
10473
10473
  slots
10474
10474
  }) {
@@ -10528,7 +10528,7 @@ var Vc = (function (exports, vue) {
10528
10528
  };
10529
10529
  }
10530
10530
  });
10531
- const props$1l = {
10531
+ const props$1m = {
10532
10532
  vertical: {
10533
10533
  type: Boolean,
10534
10534
  default: false
@@ -10546,10 +10546,10 @@ var Vc = (function (exports, vue) {
10546
10546
  default: false
10547
10547
  }
10548
10548
  };
10549
- const COMPONENT_NAME$1Z = "vc-button-group";
10549
+ const COMPONENT_NAME$22 = "vc-button-group";
10550
10550
  const ButtonGroup = /* @__PURE__ */ vue.defineComponent({
10551
- name: COMPONENT_NAME$1Z,
10552
- props: props$1l,
10551
+ name: COMPONENT_NAME$22,
10552
+ props: props$1m,
10553
10553
  setup(props2, {
10554
10554
  slots
10555
10555
  }) {
@@ -10571,16 +10571,16 @@ var Vc = (function (exports, vue) {
10571
10571
  });
10572
10572
  const MButton = Button;
10573
10573
  const MButtonGroup = ButtonGroup;
10574
- const props$1k = {
10574
+ const props$1l = {
10575
10575
  tag: {
10576
10576
  type: String,
10577
10577
  default: "div"
10578
10578
  }
10579
10579
  };
10580
- const COMPONENT_NAME$1Y = "vc-calendar";
10580
+ const COMPONENT_NAME$21 = "vc-calendar";
10581
10581
  const Calendar$1 = /* @__PURE__ */ vue.defineComponent({
10582
- name: COMPONENT_NAME$1Y,
10583
- props: props$1k,
10582
+ name: COMPONENT_NAME$21,
10583
+ props: props$1l,
10584
10584
  setup(props2, {
10585
10585
  slots
10586
10586
  }) {
@@ -10592,7 +10592,7 @@ var Vc = (function (exports, vue) {
10592
10592
  }
10593
10593
  });
10594
10594
  const MCalendar = Calendar$1;
10595
- const props$1j = {
10595
+ const props$1k = {
10596
10596
  border: {
10597
10597
  type: Boolean,
10598
10598
  default: true
@@ -10612,10 +10612,10 @@ var Vc = (function (exports, vue) {
10612
10612
  type: String
10613
10613
  }
10614
10614
  };
10615
- const COMPONENT_NAME$1X = "vc-card";
10615
+ const COMPONENT_NAME$20 = "vc-card";
10616
10616
  const Card = /* @__PURE__ */ vue.defineComponent({
10617
- name: COMPONENT_NAME$1X,
10618
- props: props$1j,
10617
+ name: COMPONENT_NAME$20,
10618
+ props: props$1k,
10619
10619
  setup(props2, {
10620
10620
  slots
10621
10621
  }) {
@@ -10639,27 +10639,696 @@ var Vc = (function (exports, vue) {
10639
10639
  }
10640
10640
  });
10641
10641
  const MCard = Card;
10642
- const props$1i = {
10643
- tag: {
10642
+ const useCarousel = (wrapper, content, expose) => {
10643
+ const instance = vue.getCurrentInstance();
10644
+ const props2 = instance.props;
10645
+ const { emit } = instance;
10646
+ const items = vue.ref([]);
10647
+ const activeIndex = vue.ref(-1);
10648
+ const timer = vue.ref(null);
10649
+ const offset = vue.ref(0);
10650
+ const carouselId = vue.ref(getUid("carousel"));
10651
+ const start = vue.ref();
10652
+ const startX = vue.ref();
10653
+ const startY = vue.ref();
10654
+ const allowTransition = vue.ref(false);
10655
+ const direction = vue.computed(() => {
10656
+ return props2.vertical ? "vertical" : "horizontal";
10657
+ });
10658
+ const hasLabel = vue.computed(() => {
10659
+ return items.value.some((item) => item.props.label.toString().length > 0);
10660
+ });
10661
+ const dotsClasses = vue.computed(() => {
10662
+ const classes = ["is-" + direction.value];
10663
+ if (hasLabel.value) {
10664
+ classes.push("is-labels");
10665
+ }
10666
+ if (props2.dots === "outside" || props2.card) {
10667
+ classes.push("is-outside");
10668
+ }
10669
+ return classes;
10670
+ });
10671
+ const resetItems = (oldIndex) => {
10672
+ items.value.forEach((item, index) => {
10673
+ item.exposed?.reset?.(index, activeIndex.value, oldIndex);
10674
+ });
10675
+ };
10676
+ const playSlides = () => {
10677
+ allowTransition.value = true;
10678
+ if (activeIndex.value < items.value.length - 1) {
10679
+ activeIndex.value++;
10680
+ } else if (props2.loop) {
10681
+ activeIndex.value = 0;
10682
+ }
10683
+ };
10684
+ const pauseTimer = () => {
10685
+ if (timer.value) {
10686
+ clearInterval(timer.value);
10687
+ timer.value = null;
10688
+ }
10689
+ };
10690
+ const startTimer = () => {
10691
+ if (props2.t <= 0 || !props2.autoplay || timer.value) return;
10692
+ timer.value = setInterval(playSlides, props2.t);
10693
+ };
10694
+ const setActiveItem = (index) => {
10695
+ if (typeof index === "string") {
10696
+ const filteredItems = items.value.filter((item) => item.props.name === index);
10697
+ if (filteredItems.length > 0) {
10698
+ index = items.value.indexOf(filteredItems[0]);
10699
+ }
10700
+ }
10701
+ index = Number(index);
10702
+ if (isNaN(index) || index !== Math.floor(index)) {
10703
+ throw new VcError("carousel", "索引必须是整数");
10704
+ }
10705
+ const length = items.value.length;
10706
+ const oldIndex = activeIndex.value;
10707
+ if (index < 0) {
10708
+ activeIndex.value = props2.loop ? length - 1 : 0;
10709
+ } else if (index >= length) {
10710
+ activeIndex.value = props2.loop ? 0 : length - 1;
10711
+ } else {
10712
+ activeIndex.value = index;
10713
+ }
10714
+ if (oldIndex === activeIndex.value) {
10715
+ resetItems(oldIndex);
10716
+ }
10717
+ };
10718
+ const prev = () => {
10719
+ setActiveItem(activeIndex.value - 1);
10720
+ };
10721
+ const next = () => {
10722
+ setActiveItem(activeIndex.value + 1);
10723
+ };
10724
+ const handleDotClick = (index) => {
10725
+ activeIndex.value = index;
10726
+ };
10727
+ const handleStart = (e) => {
10728
+ allowTransition.value = true;
10729
+ if (!props2.draggable) return;
10730
+ pauseTimer();
10731
+ start.value = true;
10732
+ startX.value = e.screenX;
10733
+ startY.value = e.screenY;
10734
+ };
10735
+ const handleMove = (e) => {
10736
+ if (!start.value || !props2.draggable) return;
10737
+ offset.value = !props2.vertical ? e.screenX - startX.value : e.screenY - startY.value;
10738
+ resetItems();
10739
+ };
10740
+ const handleEnd = () => {
10741
+ if (!props2.draggable) return;
10742
+ start.value = false;
10743
+ startTimer();
10744
+ const $offset = Math.abs(offset.value);
10745
+ const $direction = offset.value > 0;
10746
+ offset.value = 0;
10747
+ if ($offset > 5) {
10748
+ $direction && prev();
10749
+ !$direction && next();
10750
+ } else {
10751
+ resetItems();
10752
+ }
10753
+ };
10754
+ vue.watch(
10755
+ () => items.value,
10756
+ (v) => {
10757
+ if (v.length > 0) setActiveItem(props2.initialIndex);
10758
+ }
10759
+ );
10760
+ vue.watch(
10761
+ () => activeIndex.value,
10762
+ (v, oldV) => {
10763
+ resetItems(oldV);
10764
+ emit("change", v, oldV);
10765
+ }
10766
+ );
10767
+ vue.watch(
10768
+ () => props2.autoplay,
10769
+ (v) => {
10770
+ v ? startTimer() : pauseTimer();
10771
+ }
10772
+ );
10773
+ vue.watch(
10774
+ () => props2.loop,
10775
+ () => {
10776
+ setActiveItem(activeIndex.value);
10777
+ }
10778
+ );
10779
+ vue.watch(
10780
+ () => props2.t,
10781
+ () => {
10782
+ pauseTimer();
10783
+ startTimer();
10784
+ }
10785
+ );
10786
+ vue.onMounted(() => {
10787
+ vue.nextTick(() => {
10788
+ if (wrapper.value) Resize.on(wrapper.value, resetItems);
10789
+ if (props2.initialIndex < items.value.length && props2.initialIndex >= 0) {
10790
+ activeIndex.value = props2.initialIndex;
10791
+ }
10792
+ startTimer();
10793
+ });
10794
+ });
10795
+ vue.onBeforeUnmount(() => {
10796
+ if (wrapper.value) Resize.off(wrapper.value, resetItems);
10797
+ pauseTimer();
10798
+ startTimer();
10799
+ });
10800
+ const add = (item) => {
10801
+ if (!item) return;
10802
+ vue.nextTick(() => {
10803
+ if (content.value) {
10804
+ const index = Array.from(content.value.children).filter((i) => /vcm?-carousel-item/.test(i.className)).indexOf(item.vnode.el);
10805
+ items.value.splice(index, 0, item);
10806
+ return;
10807
+ }
10808
+ items.value.push(item);
10809
+ });
10810
+ };
10811
+ const remove = (item) => {
10812
+ if (!item) return;
10813
+ items.value.splice(items.value.indexOf(item), 1);
10814
+ };
10815
+ vue.provide("vc-carousel", {
10816
+ props: props2,
10817
+ items,
10818
+ offset,
10819
+ allowTransition,
10820
+ setActiveItem,
10821
+ wrapper,
10822
+ content,
10823
+ add,
10824
+ remove
10825
+ });
10826
+ expose({
10827
+ setActiveItem,
10828
+ prev,
10829
+ next
10830
+ });
10831
+ return {
10832
+ carouselId,
10833
+ allowTransition,
10834
+ items,
10835
+ activeIndex,
10836
+ offset,
10837
+ direction,
10838
+ hasLabel,
10839
+ dotsClasses,
10840
+ start,
10841
+ startX,
10842
+ startY,
10843
+ handleStart,
10844
+ handleMove,
10845
+ handleEnd,
10846
+ handleDotClick,
10847
+ prev,
10848
+ next,
10849
+ setActiveItem,
10850
+ pauseTimer,
10851
+ startTimer
10852
+ };
10853
+ };
10854
+ const props$1j = {
10855
+ t: {
10856
+ type: Number,
10857
+ default: 3e3
10858
+ },
10859
+ card: Boolean,
10860
+ gutter: {
10861
+ type: Number,
10862
+ default: 0
10863
+ },
10864
+ height: [String, Number],
10865
+ initialIndex: {
10866
+ type: Number,
10867
+ default: 0
10868
+ },
10869
+ trigger: {
10644
10870
  type: String,
10645
- default: "div"
10871
+ default: "hover"
10872
+ },
10873
+ autoplay: {
10874
+ type: Boolean,
10875
+ default: true
10876
+ },
10877
+ dots: {
10878
+ type: [String, Boolean],
10879
+ default: "bottom"
10880
+ // bottom/outside | false
10881
+ },
10882
+ arrow: {
10883
+ type: [String, Boolean],
10884
+ default: "hover"
10885
+ // hover/always | false
10886
+ },
10887
+ loop: {
10888
+ type: Boolean,
10889
+ default: true
10890
+ },
10891
+ vertical: {
10892
+ type: Boolean,
10893
+ default: false
10894
+ },
10895
+ draggable: {
10896
+ type: Boolean,
10897
+ default: true
10646
10898
  }
10647
10899
  };
10648
- const COMPONENT_NAME$1W = "vc-carousel";
10900
+ const COMPONENT_NAME$1$ = "vc-carousel";
10649
10901
  const Carousel = /* @__PURE__ */ vue.defineComponent({
10650
- name: COMPONENT_NAME$1W,
10902
+ name: COMPONENT_NAME$1$,
10903
+ props: props$1j,
10904
+ setup(props2, {
10905
+ slots,
10906
+ expose
10907
+ }) {
10908
+ const isHover = vue.ref(false);
10909
+ const wrapper = vue.ref(null);
10910
+ const content = vue.ref(null);
10911
+ const arrowDisplay = vue.computed(() => {
10912
+ return props2.arrow && !props2.vertical;
10913
+ });
10914
+ const carousel = useCarousel(wrapper, content, expose);
10915
+ const itemInStage = (item, index, items) => {
10916
+ const length = items.length;
10917
+ const isInStage = item.exposed.isInStage.value;
10918
+ if (index === length - 1 && isInStage && items[0].exposed.isActive.value || isInStage && items[index + 1] && items[index + 1].exposed.isActive.value) {
10919
+ return "left";
10920
+ } else if (index === 0 && isInStage && items[length - 1].exposed.isActive.value || isInStage && items[index - 1] && items[index - 1].exposed.isActive.value) {
10921
+ return "right";
10922
+ }
10923
+ return false;
10924
+ };
10925
+ const handleButtonEnter = (arrow) => {
10926
+ if (props2.vertical) return;
10927
+ carousel.items.value.forEach((item, index, items) => {
10928
+ if (arrow === itemInStage(item, index, items)) {
10929
+ item.exposed.isHover.value = true;
10930
+ }
10931
+ });
10932
+ };
10933
+ const handleButtonLeave = () => {
10934
+ if (props2.vertical) return;
10935
+ carousel.items.value.forEach((item) => {
10936
+ item.exposed.isHover.value = false;
10937
+ });
10938
+ };
10939
+ const handleDotHover = (index) => {
10940
+ if (props2.trigger === "hover" && index !== carousel.activeIndex.value) {
10941
+ carousel.activeIndex.value = index;
10942
+ }
10943
+ };
10944
+ const handleMouseEnter = () => {
10945
+ isHover.value = true;
10946
+ carousel.pauseTimer();
10947
+ };
10948
+ const handleMouseLeave = () => {
10949
+ isHover.value = false;
10950
+ carousel.startTimer();
10951
+ };
10952
+ const throttledArrowClick = throttle$1(carousel.setActiveItem);
10953
+ const throttledDotHover = throttle$1(handleDotHover);
10954
+ return () => {
10955
+ return vue.createVNode("div", {
10956
+ "ref": wrapper,
10957
+ "class": ["vc-carousel", `is-${carousel.direction.value}`],
10958
+ "onMousedown": vue.withModifiers(carousel.handleStart, ["stop", "prevent"]),
10959
+ "onMousemove": vue.withModifiers(carousel.handleMove, ["stop", "prevent"]),
10960
+ "onMouseup": vue.withModifiers(carousel.handleEnd, ["stop", "prevent"]),
10961
+ "onMouseenter": vue.withModifiers(handleMouseEnter, ["stop"]),
10962
+ "onMouseleave": vue.withModifiers(handleMouseLeave, ["stop"])
10963
+ }, [vue.createVNode("div", {
10964
+ "ref": content,
10965
+ "class": "vc-carousel__wrapper",
10966
+ "style": {
10967
+ height: props2.height ? `${props2.height}px` : "auto"
10968
+ }
10969
+ }, [arrowDisplay.value && vue.createVNode(TransitionSlide, {
10970
+ "mode": "left-part"
10971
+ }, {
10972
+ default: () => [vue.withDirectives(vue.createVNode("button", {
10973
+ "type": "button",
10974
+ "class": "vc-carousel__arrow is-left-arrow",
10975
+ "onMouseenter": () => handleButtonEnter("left"),
10976
+ "onMouseleave": handleButtonLeave,
10977
+ "onClick": vue.withModifiers(() => throttledArrowClick(carousel.activeIndex.value - 1), ["stop"])
10978
+ }, [vue.createVNode(Icon, {
10979
+ "type": "left"
10980
+ }, null)]), [[vue.vShow, (props2.arrow === "always" || isHover.value) && (props2.loop || carousel.activeIndex.value > 0)]])]
10981
+ }), arrowDisplay.value && vue.createVNode(TransitionSlide, {
10982
+ "mode": "right-part"
10983
+ }, {
10984
+ default: () => [vue.withDirectives(vue.createVNode("button", {
10985
+ "type": "button",
10986
+ "class": "vc-carousel__arrow is-right-arrow",
10987
+ "onMouseenter": () => handleButtonEnter("right"),
10988
+ "onMouseleave": handleButtonLeave,
10989
+ "onClick": vue.withModifiers(() => throttledArrowClick(carousel.activeIndex.value + 1), ["stop"])
10990
+ }, [vue.createVNode(Icon, {
10991
+ "type": "right"
10992
+ }, null)]), [[vue.vShow, (props2.arrow === "always" || isHover.value) && (props2.loop || carousel.activeIndex.value < carousel.items.value.length - 1)]])]
10993
+ }), slots.default?.()]), props2.dots && vue.createVNode("ul", {
10994
+ "class": ["vc-carousel__dots", ...carousel.dotsClasses.value]
10995
+ }, [carousel.items.value.map((item, index) => vue.createVNode("li", {
10996
+ "key": index,
10997
+ "class": ["vc-carousel__dot", `is-${carousel.direction.value}`, {
10998
+ "is-active": index === carousel.activeIndex.value
10999
+ }],
11000
+ "onMouseenter": () => throttledDotHover(index),
11001
+ "onClick": () => carousel.handleDotClick(index)
11002
+ }, [vue.createVNode("button", {
11003
+ "class": "vc-carousel__button"
11004
+ }, [carousel.hasLabel.value && vue.createVNode("span", null, [item.props.label])])]))])]);
11005
+ };
11006
+ }
11007
+ });
11008
+ const props$1i = {
11009
+ name: String,
11010
+ label: {
11011
+ type: [String, Number],
11012
+ default: ""
11013
+ },
11014
+ // card大小
11015
+ width: {
11016
+ type: [Number, String],
11017
+ default: "70%"
11018
+ },
11019
+ // card之间间距, 或者滑动时候的间距
11020
+ gutter: {
11021
+ type: Number,
11022
+ default: 0
11023
+ },
11024
+ scale: {
11025
+ type: Number,
11026
+ default: 0.83
11027
+ }
11028
+ };
11029
+ const TRANSFORM = prefixStyle("transform").camel;
11030
+ const useCarouselItem = (expose) => {
11031
+ const instance = vue.getCurrentInstance();
11032
+ const carousel = vue.inject("vc-carousel", {});
11033
+ const props2 = instance.props;
11034
+ const translate = vue.ref(0);
11035
+ const currentScale = vue.ref(1);
11036
+ const isHover = vue.ref(false);
11037
+ const isActive = vue.ref(false);
11038
+ const isReady = vue.ref(false);
11039
+ const isInStage = vue.ref(false);
11040
+ const isAnimating = vue.ref(false);
11041
+ const isVertical = vue.computed(() => {
11042
+ return carousel.props.vertical;
11043
+ });
11044
+ const isCard = vue.computed(() => {
11045
+ return carousel.props.card;
11046
+ });
11047
+ const isMove = vue.computed(() => {
11048
+ return carousel.offset.value !== 0;
11049
+ });
11050
+ const itemGutter = vue.computed(() => {
11051
+ return props2.gutter || carousel.props.gutter || 0;
11052
+ });
11053
+ const itemStyle = vue.computed(() => {
11054
+ const translateType = isVertical.value ? "translateY" : "translateX";
11055
+ if (carousel.props.card) {
11056
+ return {
11057
+ [TRANSFORM]: `${translateType}(${translate.value}px) scale(${currentScale.value})`,
11058
+ width: props2.width
11059
+ };
11060
+ } else {
11061
+ return {
11062
+ [TRANSFORM]: `${translateType}(${translate.value}px) scale(${currentScale.value})`,
11063
+ width: itemGutter.value ? props2.width : "100%"
11064
+ };
11065
+ }
11066
+ });
11067
+ vue.onBeforeMount(() => {
11068
+ carousel.add?.(instance);
11069
+ if (!isCard.value && itemGutter.value && carousel.props.loop) {
11070
+ throw new VcError("carousel", "slide模式下loop不能为true");
11071
+ }
11072
+ });
11073
+ vue.onBeforeUnmount(() => {
11074
+ carousel.remove?.(instance);
11075
+ });
11076
+ const processIndex = (index, activeIndex, length) => {
11077
+ if (activeIndex === 0 && index === length - 1) {
11078
+ return -1;
11079
+ } else if (activeIndex === length - 1 && index === 0) {
11080
+ return length;
11081
+ } else if (index < activeIndex - 1 && activeIndex - index >= length / 2) {
11082
+ return length + 1;
11083
+ } else if (index > activeIndex + 1 && index - activeIndex >= length / 2) {
11084
+ return -2;
11085
+ }
11086
+ return index;
11087
+ };
11088
+ const calcCardTranslate = (index, activeIndex) => {
11089
+ let value;
11090
+ const widthNumber = +props2.width / 100;
11091
+ const parentW = carousel.wrapper.value.offsetWidth;
11092
+ if (isInStage.value) {
11093
+ if (index === activeIndex) {
11094
+ value = parentW * (1 - widthNumber) / 2;
11095
+ } else if (index > activeIndex) {
11096
+ value = parentW * (1 + widthNumber * props2.scale) / 2 + itemGutter.value;
11097
+ } else {
11098
+ value = -(parentW * ((widthNumber * props2.scale - 1) / 2 + widthNumber)) - itemGutter.value;
11099
+ }
11100
+ } else if (index < activeIndex) {
11101
+ value = parentW * (1 - widthNumber) / 2;
11102
+ } else {
11103
+ value = parentW * (1 - widthNumber) / 2;
11104
+ }
11105
+ return value;
11106
+ };
11107
+ const calcSlideOffset = (index, activeIndex, wrapperWidth) => {
11108
+ const { length } = carousel.items.value;
11109
+ const offset = wrapperWidth - (instance.vnode?.el?.offsetWidth || 0);
11110
+ const gutter = itemGutter.value;
11111
+ if (!gutter || isVertical.value) return 0;
11112
+ let slideOffset = 0;
11113
+ if (length === 1) {
11114
+ return offset / 2;
11115
+ }
11116
+ if (activeIndex == 0) {
11117
+ if (index - activeIndex === 0) {
11118
+ slideOffset = gutter;
11119
+ } else if (index - activeIndex === 1) {
11120
+ slideOffset = -offset + gutter * 2;
11121
+ }
11122
+ }
11123
+ if (activeIndex !== 0 && activeIndex != length - 1) {
11124
+ if (index - activeIndex === 0) {
11125
+ slideOffset = offset / 2;
11126
+ } else if (index - activeIndex === 1) {
11127
+ slideOffset = -offset / 2 + gutter;
11128
+ } else if (index - activeIndex === -1) {
11129
+ slideOffset = offset * 3 / 2 - gutter;
11130
+ }
11131
+ }
11132
+ if (activeIndex == length - 1) {
11133
+ if (index - activeIndex === 0) {
11134
+ slideOffset = offset - gutter;
11135
+ } else if (index - activeIndex === -1) {
11136
+ slideOffset = offset * 2 - gutter * 2;
11137
+ }
11138
+ }
11139
+ return slideOffset;
11140
+ };
11141
+ const calcTranslate = (index, activeIndex) => {
11142
+ const distance = carousel.vnode.el[isVertical.value ? "offsetHeight" : "offsetWidth"];
11143
+ const slideOffset = calcSlideOffset(index, activeIndex, distance);
11144
+ return distance * (index - activeIndex) + carousel.offset.value + slideOffset;
11145
+ };
11146
+ const reset = (index, activeIndex, oldIndex) => {
11147
+ const { length } = carousel.items.value;
11148
+ if (carousel.allowTransition.value && !isCard.value && oldIndex !== void 0) {
11149
+ isAnimating.value = index === activeIndex || index === oldIndex;
11150
+ if (!isVertical.value && !isAnimating.value && itemGutter.value && (index - activeIndex === 1 || index - activeIndex === -1)) {
11151
+ isAnimating.value = true;
11152
+ }
11153
+ }
11154
+ if (index !== activeIndex && length > 2 && carousel.props.loop) {
11155
+ index = processIndex(index, activeIndex, length);
11156
+ }
11157
+ if (isCard.value) {
11158
+ if (isVertical.value) {
11159
+ throw new VcError("carousel", "卡片模式不支持垂直方向");
11160
+ }
11161
+ isInStage.value = Math.round(Math.abs(index - activeIndex)) <= 1;
11162
+ isActive.value = index === activeIndex;
11163
+ translate.value = calcCardTranslate(index, activeIndex);
11164
+ currentScale.value = isActive.value ? 1 : props2.scale;
11165
+ } else {
11166
+ isActive.value = index === activeIndex;
11167
+ translate.value = calcTranslate(index, activeIndex);
11168
+ }
11169
+ isReady.value = true;
11170
+ };
11171
+ const handleItemClick = () => {
11172
+ if (parent && isCard.value) {
11173
+ const index = carousel.items.value.indexOf(instance);
11174
+ carousel.setActiveItem(index);
11175
+ }
11176
+ };
11177
+ expose({
11178
+ reset,
11179
+ isInStage,
11180
+ isHover,
11181
+ isActive
11182
+ });
11183
+ return {
11184
+ translate,
11185
+ currentScale,
11186
+ isHover,
11187
+ isActive,
11188
+ isReady,
11189
+ isInStage,
11190
+ isAnimating,
11191
+ isVertical,
11192
+ isCard,
11193
+ isMove,
11194
+ itemGutter,
11195
+ itemStyle,
11196
+ reset,
11197
+ handleItemClick
11198
+ };
11199
+ };
11200
+ const COMPONENT_NAME$1_ = "vc-carousel-item";
11201
+ const CarouselItem = /* @__PURE__ */ vue.defineComponent({
11202
+ name: COMPONENT_NAME$1_,
10651
11203
  props: props$1i,
11204
+ setup(_, {
11205
+ slots,
11206
+ expose
11207
+ }) {
11208
+ const it = useCarouselItem(expose);
11209
+ return () => {
11210
+ return vue.withDirectives(vue.createVNode("div", {
11211
+ "class": ["vc-carousel-item", {
11212
+ "is-active": it.isActive.value,
11213
+ "is-card": it.isCard.value,
11214
+ "is-in-stage": it.isInStage.value,
11215
+ "is-hover": it.isHover.value,
11216
+ "is-animating": it.isAnimating.value && !it.isMove.value
11217
+ }],
11218
+ "style": it.itemStyle.value,
11219
+ "onClick": it.handleItemClick
11220
+ }, [it.isCard.value && vue.withDirectives(vue.createVNode("div", {
11221
+ "class": "vc-carousel-item__mask"
11222
+ }, null), [[vue.vShow, !it.isActive.value]]), slots.default?.()]), [[vue.vShow, it.isReady.value]]);
11223
+ };
11224
+ }
11225
+ });
11226
+ const COMPONENT_NAME$1Z = "vcm-carousel";
11227
+ const MCarousel = /* @__PURE__ */ vue.defineComponent({
11228
+ name: COMPONENT_NAME$1Z,
11229
+ props: {
11230
+ ...props$1j,
11231
+ dots: {
11232
+ type: [String, Boolean],
11233
+ default: false
11234
+ },
11235
+ indicator: {
11236
+ type: Boolean,
11237
+ default: true
11238
+ }
11239
+ },
10652
11240
  setup(props2, {
10653
- slots
11241
+ slots,
11242
+ expose
10654
11243
  }) {
11244
+ const wrapper = vue.ref(null);
11245
+ const content = vue.ref(null);
11246
+ const carousel = useCarousel(wrapper, content, expose);
11247
+ let scrollStatus = 0;
11248
+ const handleTouchStart = (e) => {
11249
+ carousel.handleStart(e.touches[0]);
11250
+ scrollStatus = 0;
11251
+ };
11252
+ const handleTouchMove = (e) => {
11253
+ const absX = Math.abs(e.touches[0].screenX - carousel.startX.value);
11254
+ const absY = Math.abs(e.touches[0].screenY - carousel.startY.value);
11255
+ if (!props2.vertical && absX > absY && scrollStatus !== 1) {
11256
+ e.preventDefault();
11257
+ carousel.handleMove(e.touches[0]);
11258
+ scrollStatus = 2;
11259
+ return;
11260
+ }
11261
+ if (props2.vertical && absY > absX) {
11262
+ e.preventDefault();
11263
+ carousel.handleMove(e.touches[0]);
11264
+ return;
11265
+ }
11266
+ if (scrollStatus === 0) {
11267
+ scrollStatus = 1;
11268
+ }
11269
+ };
11270
+ const handleTouchEnd = () => {
11271
+ carousel.handleEnd();
11272
+ scrollStatus = 0;
11273
+ };
10655
11274
  return () => {
10656
11275
  return vue.createVNode("div", {
10657
- "class": "vc-carousel"
10658
- }, [slots?.default?.()]);
11276
+ "ref": wrapper,
11277
+ "class": ["vcm-carousel", `is-${carousel.direction.value}`],
11278
+ "onTouchstart": vue.withModifiers(handleTouchStart, ["stop"]),
11279
+ "onTouchmove": vue.withModifiers(handleTouchMove, ["stop"]),
11280
+ "onTouchend": vue.withModifiers(handleTouchEnd, ["stop"])
11281
+ }, [vue.createVNode("div", {
11282
+ "ref": content,
11283
+ "style": {
11284
+ height: props2.height ? `${props2.height}px` : "auto"
11285
+ },
11286
+ "class": "vcm-carousel__wrapper"
11287
+ }, [slots.default?.()]), props2.dots && vue.createVNode("ul", {
11288
+ "class": ["vcm-carousel__dots", ...carousel.dotsClasses.value]
11289
+ }, [carousel.items.value.map((_, index) => vue.createVNode("li", {
11290
+ "key": index,
11291
+ "class": ["vcm-carousel__dot", "is-" + carousel.direction.value, {
11292
+ "is-active": index === carousel.activeIndex.value
11293
+ }],
11294
+ "onClick": (e) => {
11295
+ e.stopPropagation();
11296
+ carousel.handleDotClick(index);
11297
+ }
11298
+ }, [vue.createVNode("button", {
11299
+ "class": "vcm-carousel__button"
11300
+ }, [carousel.hasLabel.value && vue.createVNode("span", null, [carousel.items.value[index].props.label])])]))]), !props2.card && props2.indicator && vue.createVNode("div", {
11301
+ "class": "vcm-carousel__indicator"
11302
+ }, [vue.createVNode("span", null, [carousel.activeIndex.value + 1]), vue.createVNode("span", null, [vue.createTextVNode(" / ")]), vue.createVNode("span", null, [carousel.items.value.length])])]);
11303
+ };
11304
+ }
11305
+ });
11306
+ const COMPONENT_NAME$1Y = "vcm-carousel-item";
11307
+ const MCarouselItem = /* @__PURE__ */ vue.defineComponent({
11308
+ name: COMPONENT_NAME$1Y,
11309
+ props: props$1i,
11310
+ setup(_, {
11311
+ slots,
11312
+ expose
11313
+ }) {
11314
+ const it = useCarouselItem(expose);
11315
+ return () => {
11316
+ return vue.withDirectives(vue.createVNode("div", {
11317
+ "style": it.itemStyle.value,
11318
+ "class": {
11319
+ "vcm-carousel-item": true,
11320
+ "is-active": it.isActive.value,
11321
+ "is-card": it.isCard.value,
11322
+ "is-animating": it.isAnimating.value && !it.isMove.value,
11323
+ "is-in-stage": it.isInStage.value
11324
+ },
11325
+ "onClick": it.handleItemClick
11326
+ }, [it.isCard.value && !it.isActive.value && vue.createVNode("div", {
11327
+ "class": "vcm-carousel-item__mask"
11328
+ }, null), slots.default?.()]), [[vue.vShow, it.isReady.value]]);
10659
11329
  };
10660
11330
  }
10661
11331
  });
10662
- const MCarousel = Carousel;
10663
11332
  const getSelectedData = (value = [], source = []) => {
10664
11333
  const label = [];
10665
11334
  const data = [];
@@ -10932,9 +11601,9 @@ var Vc = (function (exports, vue) {
10932
11601
  expose?.(exposed);
10933
11602
  return exposed;
10934
11603
  };
10935
- const COMPONENT_NAME$1V = "vc-input";
11604
+ const COMPONENT_NAME$1X = "vc-input";
10936
11605
  const Input$1 = /* @__PURE__ */ vue.defineComponent({
10937
- name: COMPONENT_NAME$1V,
11606
+ name: COMPONENT_NAME$1X,
10938
11607
  inheritAttrs: false,
10939
11608
  props: {
10940
11609
  ...props$1h,
@@ -11265,9 +11934,9 @@ var Vc = (function (exports, vue) {
11265
11934
  handleStepper
11266
11935
  };
11267
11936
  };
11268
- const COMPONENT_NAME$1U = "vc-input-number";
11937
+ const COMPONENT_NAME$1W = "vc-input-number";
11269
11938
  const InputNumber = /* @__PURE__ */ vue.defineComponent({
11270
- name: COMPONENT_NAME$1U,
11939
+ name: COMPONENT_NAME$1W,
11271
11940
  props: props$1g,
11272
11941
  inheritAttrs: false,
11273
11942
  setup(props2, {
@@ -11327,9 +11996,9 @@ var Vc = (function (exports, vue) {
11327
11996
  default: true
11328
11997
  }
11329
11998
  };
11330
- const COMPONENT_NAME$1T = "vc-input-search";
11999
+ const COMPONENT_NAME$1V = "vc-input-search";
11331
12000
  const InputSearch = /* @__PURE__ */ vue.defineComponent({
11332
- name: COMPONENT_NAME$1T,
12001
+ name: COMPONENT_NAME$1V,
11333
12002
  props: props$1f,
11334
12003
  inheritAttrs: false,
11335
12004
  setup(props2, {
@@ -11717,9 +12386,9 @@ var Vc = (function (exports, vue) {
11717
12386
  default: () => null
11718
12387
  }
11719
12388
  };
11720
- const COMPONENT_NAME$1S = "vc-customer";
12389
+ const COMPONENT_NAME$1U = "vc-customer";
11721
12390
  const Customer = vue.defineComponent({
11722
- name: COMPONENT_NAME$1S,
12391
+ name: COMPONENT_NAME$1U,
11723
12392
  props: props$1c,
11724
12393
  setup(props2, context) {
11725
12394
  return () => vue.h(() => {
@@ -11792,7 +12461,7 @@ var Vc = (function (exports, vue) {
11792
12461
  return this.target.finally(callback);
11793
12462
  }
11794
12463
  }
11795
- const COMPONENT_NAME$1R = "vc-portal";
12464
+ const COMPONENT_NAME$1T = "vc-portal";
11796
12465
  class Portal {
11797
12466
  /**
11798
12467
  * 清理Portals类型组件
@@ -11842,7 +12511,7 @@ var Vc = (function (exports, vue) {
11842
12511
  this.wrapper = wrapper;
11843
12512
  this.globalOptions = {
11844
12513
  ...options,
11845
- name: options?.name || wrapper.name || getUid(COMPONENT_NAME$1R)
12514
+ name: options?.name || wrapper.name || getUid(COMPONENT_NAME$1T)
11846
12515
  };
11847
12516
  }
11848
12517
  popup(propsData, options) {
@@ -11935,12 +12604,12 @@ var Vc = (function (exports, vue) {
11935
12604
  components,
11936
12605
  uses,
11937
12606
  slots,
11938
- parent,
12607
+ parent: parent2,
11939
12608
  propsData,
11940
12609
  ...rest
11941
12610
  } = options;
11942
12611
  let useAllNodes = fragment;
11943
- const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$1R)}` : name$;
12612
+ const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$1T)}` : name$;
11944
12613
  const container = document.createElement(tag);
11945
12614
  const root = typeof el2 === "object" ? el2 : document.querySelector(el2 || "body");
11946
12615
  !alive && Portal.leafs.get(name)?.destroy();
@@ -11974,8 +12643,8 @@ var Vc = (function (exports, vue) {
11974
12643
  } else {
11975
12644
  const wrapper = this.wrapper;
11976
12645
  const app = vue.createApp({
11977
- name: COMPONENT_NAME$1R,
11978
- parent,
12646
+ name: COMPONENT_NAME$1T,
12647
+ parent: parent2,
11979
12648
  setup() {
11980
12649
  if (alive) {
11981
12650
  const handleExtra = (e) => {
@@ -12083,9 +12752,9 @@ var Vc = (function (exports, vue) {
12083
12752
  default: "div"
12084
12753
  }
12085
12754
  };
12086
- const COMPONENT_NAME$1Q = "vc-portal-view";
12755
+ const COMPONENT_NAME$1S = "vc-portal-view";
12087
12756
  const PortalView = /* @__PURE__ */ vue.defineComponent({
12088
- name: COMPONENT_NAME$1Q,
12757
+ name: COMPONENT_NAME$1S,
12089
12758
  props: props$1b,
12090
12759
  setup(props2, {
12091
12760
  slots
@@ -12099,9 +12768,9 @@ var Vc = (function (exports, vue) {
12099
12768
  };
12100
12769
  }
12101
12770
  });
12102
- const COMPONENT_NAME$1P = "vc-popover-wrapper";
12771
+ const COMPONENT_NAME$1R = "vc-popover-wrapper";
12103
12772
  const PopoverWrapper = /* @__PURE__ */ vue.defineComponent({
12104
- name: COMPONENT_NAME$1P,
12773
+ name: COMPONENT_NAME$1R,
12105
12774
  props: props$1e,
12106
12775
  emits: ["portal-fulfilled", "close"],
12107
12776
  setup(props2, {
@@ -12323,9 +12992,9 @@ var Vc = (function (exports, vue) {
12323
12992
  const PopoverPortal = new Portal(PopoverWrapper, {
12324
12993
  leaveDelay: 0
12325
12994
  });
12326
- const COMPONENT_NAME$1O = "vc-popover";
12995
+ const COMPONENT_NAME$1Q = "vc-popover";
12327
12996
  const Popover$1 = /* @__PURE__ */ vue.defineComponent({
12328
- name: COMPONENT_NAME$1O,
12997
+ name: COMPONENT_NAME$1Q,
12329
12998
  props: props$1d,
12330
12999
  emits: ["update:modelValue", "visible-change", "ready", "close"],
12331
13000
  setup(props2, {
@@ -12453,9 +13122,9 @@ var Vc = (function (exports, vue) {
12453
13122
  const Popover = Object.assign(Popover$1, {
12454
13123
  open: PopoverPortal.popup.bind(PopoverPortal)
12455
13124
  });
12456
- const COMPONENT_NAME$1N = "vc-cascader-column";
13125
+ const COMPONENT_NAME$1P = "vc-cascader-column";
12457
13126
  const CascaderColumn = /* @__PURE__ */ vue.defineComponent({
12458
- name: COMPONENT_NAME$1N,
13127
+ name: COMPONENT_NAME$1P,
12459
13128
  emits: ["click", "change"],
12460
13129
  props: {
12461
13130
  data: {
@@ -12658,9 +13327,9 @@ var Vc = (function (exports, vue) {
12658
13327
  default: true
12659
13328
  }
12660
13329
  };
12661
- const COMPONENT_NAME$1M = "vc-cascader";
13330
+ const COMPONENT_NAME$1O = "vc-cascader";
12662
13331
  const Cascader = /* @__PURE__ */ vue.defineComponent({
12663
- name: COMPONENT_NAME$1M,
13332
+ name: COMPONENT_NAME$1O,
12664
13333
  inheritAttrs: false,
12665
13334
  props: props$19,
12666
13335
  emits: ["update:modelValue", "visible-change", "ready", "change", "close"],
@@ -12947,9 +13616,9 @@ var Vc = (function (exports, vue) {
12947
13616
  watchShallow: Boolean,
12948
13617
  manualUpdate: Boolean
12949
13618
  };
12950
- const COMPONENT_NAME$1L = "vc-chart";
13619
+ const COMPONENT_NAME$1N = "vc-chart";
12951
13620
  const Chart = /* @__PURE__ */ vue.defineComponent({
12952
- name: COMPONENT_NAME$1L,
13621
+ name: COMPONENT_NAME$1N,
12953
13622
  props: props$18,
12954
13623
  emits: [...EVENTS$1, "ready"],
12955
13624
  setup(props2, {
@@ -13176,9 +13845,9 @@ var Vc = (function (exports, vue) {
13176
13845
  computedLabel
13177
13846
  };
13178
13847
  };
13179
- const COMPONENT_NAME$1K = "vc-checkbox";
13848
+ const COMPONENT_NAME$1M = "vc-checkbox";
13180
13849
  const Checkbox = /* @__PURE__ */ vue.defineComponent({
13181
- name: COMPONENT_NAME$1K,
13850
+ name: COMPONENT_NAME$1M,
13182
13851
  props: props$17,
13183
13852
  emits: ["update:modelValue", "change"],
13184
13853
  setup(props2, {
@@ -13260,9 +13929,9 @@ var Vc = (function (exports, vue) {
13260
13929
  reset
13261
13930
  };
13262
13931
  };
13263
- const COMPONENT_NAME$1J = "vc-checkbox-group";
13932
+ const COMPONENT_NAME$1L = "vc-checkbox-group";
13264
13933
  const CheckboxGroup = /* @__PURE__ */ vue.defineComponent({
13265
- name: COMPONENT_NAME$1J,
13934
+ name: COMPONENT_NAME$1L,
13266
13935
  props: props$16,
13267
13936
  emits: ["update:modelValue", "change"],
13268
13937
  setup(props2, {
@@ -13277,9 +13946,9 @@ var Vc = (function (exports, vue) {
13277
13946
  };
13278
13947
  }
13279
13948
  });
13280
- const COMPONENT_NAME$1I = "vcm-checkbox";
13949
+ const COMPONENT_NAME$1K = "vcm-checkbox";
13281
13950
  const MCheckbox = /* @__PURE__ */ vue.defineComponent({
13282
- name: COMPONENT_NAME$1I,
13951
+ name: COMPONENT_NAME$1K,
13283
13952
  props: props$17,
13284
13953
  emits: ["update:modelValue", "change"],
13285
13954
  setup(props2, {
@@ -13316,9 +13985,9 @@ var Vc = (function (exports, vue) {
13316
13985
  };
13317
13986
  }
13318
13987
  });
13319
- const COMPONENT_NAME$1H = "vcm-checkbox-group";
13988
+ const COMPONENT_NAME$1J = "vcm-checkbox-group";
13320
13989
  const MCheckboxGroup = /* @__PURE__ */ vue.defineComponent({
13321
- name: COMPONENT_NAME$1H,
13990
+ name: COMPONENT_NAME$1J,
13322
13991
  props: props$16,
13323
13992
  emits: ["update:modelValue", "change"],
13324
13993
  setup(props2, {
@@ -13368,9 +14037,9 @@ var Vc = (function (exports, vue) {
13368
14037
  // 这个相当于Modal中的onCancel,支持Promise
13369
14038
  onBeforeClose: Function
13370
14039
  };
13371
- const COMPONENT_NAME$1G = "vc-message";
14040
+ const COMPONENT_NAME$1I = "vc-message";
13372
14041
  const MessageView = /* @__PURE__ */ vue.defineComponent({
13373
- name: COMPONENT_NAME$1G,
14042
+ name: COMPONENT_NAME$1I,
13374
14043
  emits: ["before-close", "close", "portal-fulfilled"],
13375
14044
  props: props$15,
13376
14045
  setup(props2, {
@@ -13613,9 +14282,9 @@ var Vc = (function (exports, vue) {
13613
14282
  };
13614
14283
  return () => vue.h(props2.tag, { onClick: handleClick, class: "vc-clipboard" }, slots?.default?.());
13615
14284
  };
13616
- const COMPONENT_NAME$1F = "vc-clipboard";
14285
+ const COMPONENT_NAME$1H = "vc-clipboard";
13617
14286
  const Clipboard$1 = vue.defineComponent({
13618
- name: COMPONENT_NAME$1F,
14287
+ name: COMPONENT_NAME$1H,
13619
14288
  props: props$14,
13620
14289
  setup() {
13621
14290
  return useClipboard((content) => Message.success({ content }));
@@ -13647,9 +14316,9 @@ var Vc = (function (exports, vue) {
13647
14316
  const MTransitionScale = TransitionScale;
13648
14317
  const MTransitionSlide = TransitionSlide;
13649
14318
  const MTransitionZoom = TransitionZoom;
13650
- const COMPONENT_NAME$1E = "vcm-toast";
14319
+ const COMPONENT_NAME$1G = "vcm-toast";
13651
14320
  const MToastView = /* @__PURE__ */ vue.defineComponent({
13652
- name: COMPONENT_NAME$1E,
14321
+ name: COMPONENT_NAME$1G,
13653
14322
  emits: ["close", "portal-fulfilled"],
13654
14323
  props: props$13,
13655
14324
  setup(props2, {
@@ -13748,9 +14417,9 @@ var Vc = (function (exports, vue) {
13748
14417
  const warning$2 = create$3({ mode: "warning" });
13749
14418
  const error$2 = create$3({ mode: "error" });
13750
14419
  const MToast = Object.assign(MToastView, { destroy: destroy$4, info: info$2, success: success$2, loading, warning: warning$2, error: error$2 });
13751
- const COMPONENT_NAME$1D = "vcm-clipboard";
14420
+ const COMPONENT_NAME$1F = "vcm-clipboard";
13752
14421
  const MClipboard$1 = vue.defineComponent({
13753
- name: COMPONENT_NAME$1D,
14422
+ name: COMPONENT_NAME$1F,
13754
14423
  props: props$14,
13755
14424
  setup() {
13756
14425
  return useClipboard((content) => MToast.info({ content }));
@@ -13779,9 +14448,9 @@ var Vc = (function (exports, vue) {
13779
14448
  default: false
13780
14449
  }
13781
14450
  };
13782
- const COMPONENT_NAME$1C = "vc-collapse";
14451
+ const COMPONENT_NAME$1E = "vc-collapse";
13783
14452
  const Collapse = vue.defineComponent({
13784
- name: COMPONENT_NAME$1C,
14453
+ name: COMPONENT_NAME$1E,
13785
14454
  props: props$12,
13786
14455
  emits: ["update:moodelValue", "change"],
13787
14456
  setup(props2, { slots, emit }) {
@@ -13893,9 +14562,9 @@ var Vc = (function (exports, vue) {
13893
14562
  function _isSlot$3(s) {
13894
14563
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
13895
14564
  }
13896
- const COMPONENT_NAME$1B = "vc-expand";
14565
+ const COMPONENT_NAME$1D = "vc-expand";
13897
14566
  const Expand$1 = /* @__PURE__ */ vue.defineComponent({
13898
- name: COMPONENT_NAME$1B,
14567
+ name: COMPONENT_NAME$1D,
13899
14568
  props: props$10,
13900
14569
  setup(props2, {
13901
14570
  slots
@@ -13922,9 +14591,9 @@ var Vc = (function (exports, vue) {
13922
14591
  };
13923
14592
  }
13924
14593
  });
13925
- const COMPONENT_NAME$1A = "vc-collapse-item";
14594
+ const COMPONENT_NAME$1C = "vc-collapse-item";
13926
14595
  const CollapseItem = /* @__PURE__ */ vue.defineComponent({
13927
- name: COMPONENT_NAME$1A,
14596
+ name: COMPONENT_NAME$1C,
13928
14597
  props: props$11,
13929
14598
  setup(props2, {
13930
14599
  slots,
@@ -13994,9 +14663,9 @@ var Vc = (function (exports, vue) {
13994
14663
  default: "div"
13995
14664
  }
13996
14665
  };
13997
- const COMPONENT_NAME$1z = "vc-color-picker";
14666
+ const COMPONENT_NAME$1B = "vc-color-picker";
13998
14667
  const ColorPicker$1 = /* @__PURE__ */ vue.defineComponent({
13999
- name: COMPONENT_NAME$1z,
14668
+ name: COMPONENT_NAME$1B,
14000
14669
  props: props$$,
14001
14670
  setup(props2, {
14002
14671
  slots
@@ -14053,9 +14722,9 @@ var Vc = (function (exports, vue) {
14053
14722
  function _isSlot$2(s) {
14054
14723
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
14055
14724
  }
14056
- const COMPONENT_NAME$1y = "vc-countdown";
14725
+ const COMPONENT_NAME$1A = "vc-countdown";
14057
14726
  const Countdown = /* @__PURE__ */ vue.defineComponent({
14058
- name: COMPONENT_NAME$1y,
14727
+ name: COMPONENT_NAME$1A,
14059
14728
  props: props$_,
14060
14729
  emits: ["change", "complete", "error"],
14061
14730
  setup(props2, {
@@ -14317,9 +14986,9 @@ var Vc = (function (exports, vue) {
14317
14986
  function _isSlot$1(s) {
14318
14987
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
14319
14988
  }
14320
- const COMPONENT_NAME$1x = "vc-counter";
14989
+ const COMPONENT_NAME$1z = "vc-counter";
14321
14990
  const Counter = /* @__PURE__ */ vue.defineComponent({
14322
- name: COMPONENT_NAME$1x,
14991
+ name: COMPONENT_NAME$1z,
14323
14992
  props: props$Z,
14324
14993
  emits: ["begin", "complete", "change"],
14325
14994
  setup(props2, {
@@ -15567,9 +16236,9 @@ var Vc = (function (exports, vue) {
15567
16236
  }
15568
16237
  return view;
15569
16238
  };
15570
- const COMPONENT_NAME$1w = "vc-date-confirm";
16239
+ const COMPONENT_NAME$1y = "vc-date-confirm";
15571
16240
  const Confirm = /* @__PURE__ */ vue.defineComponent({
15572
- name: COMPONENT_NAME$1w,
16241
+ name: COMPONENT_NAME$1y,
15573
16242
  props: {
15574
16243
  showTime: {
15575
16244
  type: Boolean,
@@ -15630,9 +16299,9 @@ var Vc = (function (exports, vue) {
15630
16299
  };
15631
16300
  }
15632
16301
  });
15633
- const COMPONENT_NAME$1v = "vc-date-header";
16302
+ const COMPONENT_NAME$1x = "vc-date-header";
15634
16303
  const DateHeader = /* @__PURE__ */ vue.defineComponent({
15635
- name: COMPONENT_NAME$1v,
16304
+ name: COMPONENT_NAME$1x,
15636
16305
  props: {
15637
16306
  panelDate: Date,
15638
16307
  showNext: {
@@ -15713,9 +16382,9 @@ var Vc = (function (exports, vue) {
15713
16382
  };
15714
16383
  }
15715
16384
  });
15716
- const COMPONENT_NAME$1u = "vc-date-table";
16385
+ const COMPONENT_NAME$1w = "vc-date-table";
15717
16386
  const DateTable = /* @__PURE__ */ vue.defineComponent({
15718
- name: COMPONENT_NAME$1u,
16387
+ name: COMPONENT_NAME$1w,
15719
16388
  props: {
15720
16389
  value: Array,
15721
16390
  firstDayOfWeek: {
@@ -15915,9 +16584,9 @@ var Vc = (function (exports, vue) {
15915
16584
  };
15916
16585
  }
15917
16586
  });
15918
- const COMPONENT_NAME$1t = "vc-month-table";
16587
+ const COMPONENT_NAME$1v = "vc-month-table";
15919
16588
  const MonthTable = /* @__PURE__ */ vue.defineComponent({
15920
- name: COMPONENT_NAME$1t,
16589
+ name: COMPONENT_NAME$1v,
15921
16590
  props: {
15922
16591
  value: Array,
15923
16592
  panelDate: Date,
@@ -16043,7 +16712,7 @@ var Vc = (function (exports, vue) {
16043
16712
  };
16044
16713
  }
16045
16714
  });
16046
- const COMPONENT_NAME$1s = "vc-quarter-table";
16715
+ const COMPONENT_NAME$1u = "vc-quarter-table";
16047
16716
  const getMonthRange = (panelDate, quarter) => {
16048
16717
  const year = panelDate.getFullYear();
16049
16718
  const [startMonth, endMonth] = [quarter * 3, quarter * 3 + 2];
@@ -16070,7 +16739,7 @@ var Vc = (function (exports, vue) {
16070
16739
  }
16071
16740
  };
16072
16741
  const QuarterTable = /* @__PURE__ */ vue.defineComponent({
16073
- name: COMPONENT_NAME$1s,
16742
+ name: COMPONENT_NAME$1u,
16074
16743
  props: {
16075
16744
  value: Array,
16076
16745
  panelDate: Date,
@@ -16188,9 +16857,9 @@ var Vc = (function (exports, vue) {
16188
16857
  };
16189
16858
  }
16190
16859
  });
16191
- const COMPONENT_NAME$1r = "vc-shortcuts-select";
16860
+ const COMPONENT_NAME$1t = "vc-shortcuts-select";
16192
16861
  const ShortcutsSelect = /* @__PURE__ */ vue.defineComponent({
16193
- name: COMPONENT_NAME$1r,
16862
+ name: COMPONENT_NAME$1t,
16194
16863
  props: {
16195
16864
  panelDate: Date,
16196
16865
  config: Array,
@@ -16227,9 +16896,9 @@ var Vc = (function (exports, vue) {
16227
16896
  };
16228
16897
  }
16229
16898
  });
16230
- const COMPONENT_NAME$1q = "vc-time-select";
16899
+ const COMPONENT_NAME$1s = "vc-time-select";
16231
16900
  const TimeSelect = /* @__PURE__ */ vue.defineComponent({
16232
- name: COMPONENT_NAME$1q,
16901
+ name: COMPONENT_NAME$1s,
16233
16902
  props: {
16234
16903
  hours: {
16235
16904
  type: [Number, String],
@@ -16505,9 +17174,9 @@ var Vc = (function (exports, vue) {
16505
17174
  };
16506
17175
  }
16507
17176
  });
16508
- const COMPONENT_NAME$1p = "vc-year-table";
17177
+ const COMPONENT_NAME$1r = "vc-year-table";
16509
17178
  const YearTable = /* @__PURE__ */ vue.defineComponent({
16510
- name: COMPONENT_NAME$1p,
17179
+ name: COMPONENT_NAME$1r,
16511
17180
  props: {
16512
17181
  value: Array,
16513
17182
  panelDate: Date,
@@ -16623,9 +17292,9 @@ var Vc = (function (exports, vue) {
16623
17292
  }
16624
17293
  return true;
16625
17294
  };
16626
- const COMPONENT_NAME$1o = "vc-date-range-panel";
17295
+ const COMPONENT_NAME$1q = "vc-date-range-panel";
16627
17296
  const DateRangePanel = /* @__PURE__ */ vue.defineComponent({
16628
- name: COMPONENT_NAME$1o,
17297
+ name: COMPONENT_NAME$1q,
16629
17298
  props: {
16630
17299
  ...props$W,
16631
17300
  confirm: {
@@ -16986,9 +17655,9 @@ var Vc = (function (exports, vue) {
16986
17655
  };
16987
17656
  }
16988
17657
  });
16989
- const COMPONENT_NAME$1n = "vc-date-panel";
17658
+ const COMPONENT_NAME$1p = "vc-date-panel";
16990
17659
  const DatePanel = /* @__PURE__ */ vue.defineComponent({
16991
- name: COMPONENT_NAME$1n,
17660
+ name: COMPONENT_NAME$1p,
16992
17661
  props: {
16993
17662
  ...props$W,
16994
17663
  type: String,
@@ -17187,9 +17856,9 @@ var Vc = (function (exports, vue) {
17187
17856
  const endYear = value[1].getFullYear();
17188
17857
  return startYear === endYear;
17189
17858
  };
17190
- const COMPONENT_NAME$1m = "vc-monthrange-panel";
17859
+ const COMPONENT_NAME$1o = "vc-monthrange-panel";
17191
17860
  const MonthRangePanel = /* @__PURE__ */ vue.defineComponent({
17192
- name: COMPONENT_NAME$1m,
17861
+ name: COMPONENT_NAME$1o,
17193
17862
  props: {
17194
17863
  ...props$W,
17195
17864
  confirm: {
@@ -17359,9 +18028,9 @@ var Vc = (function (exports, vue) {
17359
18028
  const endYear = value[1].getFullYear();
17360
18029
  return startYear === endYear;
17361
18030
  };
17362
- const COMPONENT_NAME$1l = "vc-quarterrange-panel";
18031
+ const COMPONENT_NAME$1n = "vc-quarterrange-panel";
17363
18032
  const QuarterRangePanel = /* @__PURE__ */ vue.defineComponent({
17364
- name: COMPONENT_NAME$1l,
18033
+ name: COMPONENT_NAME$1n,
17365
18034
  props: {
17366
18035
  ...props$W,
17367
18036
  confirm: {
@@ -17592,9 +18261,9 @@ var Vc = (function (exports, vue) {
17592
18261
  seconds
17593
18262
  };
17594
18263
  };
17595
- const COMPONENT_NAME$1k = "vc-timerange-panel";
18264
+ const COMPONENT_NAME$1m = "vc-timerange-panel";
17596
18265
  const TimeRangePanel = /* @__PURE__ */ vue.defineComponent({
17597
- name: COMPONENT_NAME$1k,
18266
+ name: COMPONENT_NAME$1m,
17598
18267
  props: props$V,
17599
18268
  emits: ["pick", "clear", "ok"],
17600
18269
  setup(props2, {
@@ -17692,9 +18361,9 @@ var Vc = (function (exports, vue) {
17692
18361
  };
17693
18362
  }
17694
18363
  });
17695
- const COMPONENT_NAME$1j = "vc-time-panel";
18364
+ const COMPONENT_NAME$1l = "vc-time-panel";
17696
18365
  const TimePanel = /* @__PURE__ */ vue.defineComponent({
17697
- name: COMPONENT_NAME$1j,
18366
+ name: COMPONENT_NAME$1l,
17698
18367
  props: props$V,
17699
18368
  emits: ["pick", "clear", "ok"],
17700
18369
  setup(props2, {
@@ -17746,7 +18415,7 @@ var Vc = (function (exports, vue) {
17746
18415
  };
17747
18416
  }
17748
18417
  });
17749
- const COMPONENT_NAME$1i = "vc-date-picker";
18418
+ const COMPONENT_NAME$1k = "vc-date-picker";
17750
18419
  const getPanel$1 = (type) => {
17751
18420
  if (["daterange", "datetimerange"].includes(type)) {
17752
18421
  return DateRangePanel;
@@ -17757,7 +18426,7 @@ var Vc = (function (exports, vue) {
17757
18426
  }
17758
18427
  return DatePanel;
17759
18428
  };
17760
- const DatePicker = createPicker(COMPONENT_NAME$1i, props$Y, () => {
18429
+ const DatePicker = createPicker(COMPONENT_NAME$1k, props$Y, () => {
17761
18430
  const props2 = vue.getCurrentInstance().props;
17762
18431
  const icon = vue.ref("date");
17763
18432
  const panel = vue.shallowRef({});
@@ -17793,9 +18462,9 @@ var Vc = (function (exports, vue) {
17793
18462
  }
17794
18463
  }
17795
18464
  };
17796
- const COMPONENT_NAME$1h = "vc-divider";
18465
+ const COMPONENT_NAME$1j = "vc-divider";
17797
18466
  const Divider = /* @__PURE__ */ vue.defineComponent({
17798
- name: COMPONENT_NAME$1h,
18467
+ name: COMPONENT_NAME$1j,
17799
18468
  props: props$U,
17800
18469
  setup(props2, {
17801
18470
  slots
@@ -17924,7 +18593,7 @@ var Vc = (function (exports, vue) {
17924
18593
  barTo: props$S.to,
17925
18594
  ...pick(props$S, barKeys)
17926
18595
  };
17927
- const COMPONENT_NAME$1g = "vc-scroller-track";
18596
+ const COMPONENT_NAME$1i = "vc-scroller-track";
17928
18597
  const BAR_MAP = {
17929
18598
  vertical: {
17930
18599
  scroll: "scrollTop",
@@ -17944,7 +18613,7 @@ var Vc = (function (exports, vue) {
17944
18613
  }
17945
18614
  };
17946
18615
  const Track$1 = /* @__PURE__ */ vue.defineComponent({
17947
- name: COMPONENT_NAME$1g,
18616
+ name: COMPONENT_NAME$1i,
17948
18617
  props: props$T,
17949
18618
  emits: ["change"],
17950
18619
  inheritAttrs: false,
@@ -18106,9 +18775,9 @@ var Vc = (function (exports, vue) {
18106
18775
  };
18107
18776
  }
18108
18777
  });
18109
- const COMPONENT_NAME$1f = "vc-scroller-bar";
18778
+ const COMPONENT_NAME$1h = "vc-scroller-bar";
18110
18779
  const Bar = /* @__PURE__ */ vue.defineComponent({
18111
- name: COMPONENT_NAME$1f,
18780
+ name: COMPONENT_NAME$1h,
18112
18781
  props: props$S,
18113
18782
  emits: ["change"],
18114
18783
  setup(props2, {
@@ -18339,9 +19008,9 @@ var Vc = (function (exports, vue) {
18339
19008
  refreshPosition
18340
19009
  };
18341
19010
  };
18342
- const COMPONENT_NAME$1e = "vc-scroller";
19011
+ const COMPONENT_NAME$1g = "vc-scroller";
18343
19012
  const Scroller = /* @__PURE__ */ vue.defineComponent({
18344
- name: COMPONENT_NAME$1e,
19013
+ name: COMPONENT_NAME$1g,
18345
19014
  props: props$R,
18346
19015
  emits: ["scroll"],
18347
19016
  setup(props2, {
@@ -18399,9 +19068,9 @@ var Vc = (function (exports, vue) {
18399
19068
  };
18400
19069
  }
18401
19070
  });
18402
- const COMPONENT_NAME$1d = "vc-scroller-wheel";
19071
+ const COMPONENT_NAME$1f = "vc-scroller-wheel";
18403
19072
  const ScrollerWheel = /* @__PURE__ */ vue.defineComponent({
18404
- name: COMPONENT_NAME$1d,
19073
+ name: COMPONENT_NAME$1f,
18405
19074
  props: Object.assign({}, props$R, {
18406
19075
  stopPropagation: {
18407
19076
  type: Boolean,
@@ -18582,9 +19251,9 @@ var Vc = (function (exports, vue) {
18582
19251
  type: Function
18583
19252
  }
18584
19253
  };
18585
- const COMPONENT_NAME$1c = "vc-drawer";
19254
+ const COMPONENT_NAME$1e = "vc-drawer";
18586
19255
  const DrawerView = /* @__PURE__ */ vue.defineComponent({
18587
- name: COMPONENT_NAME$1c,
19256
+ name: COMPONENT_NAME$1e,
18588
19257
  props: props$Q,
18589
19258
  emits: ["close", "update:modelValue", "visible-change"],
18590
19259
  setup(props2, {
@@ -18756,9 +19425,9 @@ var Vc = (function (exports, vue) {
18756
19425
  default: false
18757
19426
  }
18758
19427
  };
18759
- const COMPONENT_NAME$1b = "vc-dropdown";
19428
+ const COMPONENT_NAME$1d = "vc-dropdown";
18760
19429
  const Dropdown = /* @__PURE__ */ vue.defineComponent({
18761
- name: COMPONENT_NAME$1b,
19430
+ name: COMPONENT_NAME$1d,
18762
19431
  props: props$P,
18763
19432
  inheritAttrs: false,
18764
19433
  emits: ["update:modelValue", "ready", "close", "visible-change", "click"],
@@ -18821,9 +19490,9 @@ var Vc = (function (exports, vue) {
18821
19490
  };
18822
19491
  }
18823
19492
  });
18824
- const COMPONENT_NAME$1a = "vc-dropdown-menu";
19493
+ const COMPONENT_NAME$1c = "vc-dropdown-menu";
18825
19494
  const DropdownMenu = /* @__PURE__ */ vue.defineComponent({
18826
- name: COMPONENT_NAME$1a,
19495
+ name: COMPONENT_NAME$1c,
18827
19496
  setup(_, {
18828
19497
  slots
18829
19498
  }) {
@@ -18834,9 +19503,9 @@ var Vc = (function (exports, vue) {
18834
19503
  };
18835
19504
  }
18836
19505
  });
18837
- const COMPONENT_NAME$19 = "vc-dropdown-item";
19506
+ const COMPONENT_NAME$1b = "vc-dropdown-item";
18838
19507
  const DropdownItem = /* @__PURE__ */ vue.defineComponent({
18839
- name: COMPONENT_NAME$19,
19508
+ name: COMPONENT_NAME$1b,
18840
19509
  emits: ["click"],
18841
19510
  props: {
18842
19511
  value: {
@@ -19035,9 +19704,9 @@ var Vc = (function (exports, vue) {
19035
19704
  ["link", "upload/video", "upload/image", "undo", "redo"]
19036
19705
  ]
19037
19706
  };
19038
- const COMPONENT_NAME$18 = "vc-editor-toolbar";
19707
+ const COMPONENT_NAME$1a = "vc-editor-toolbar";
19039
19708
  const EditorToolbar = /* @__PURE__ */ vue.defineComponent({
19040
- name: COMPONENT_NAME$18,
19709
+ name: COMPONENT_NAME$1a,
19041
19710
  props: {
19042
19711
  options: [Array, Object],
19043
19712
  elementId: String
@@ -19237,9 +19906,9 @@ var Vc = (function (exports, vue) {
19237
19906
  default: "div"
19238
19907
  }
19239
19908
  };
19240
- const COMPONENT_NAME$17 = "vc-image-preview";
19909
+ const COMPONENT_NAME$19 = "vc-image-preview";
19241
19910
  const ImagePreview$1 = /* @__PURE__ */ vue.defineComponent({
19242
- name: COMPONENT_NAME$17,
19911
+ name: COMPONENT_NAME$19,
19243
19912
  props: props$O,
19244
19913
  setup(props2, {
19245
19914
  slots
@@ -19429,9 +20098,9 @@ var Vc = (function (exports, vue) {
19429
20098
  default: false
19430
20099
  }
19431
20100
  };
19432
- const COMPONENT_NAME$16 = "vc-upload";
20101
+ const COMPONENT_NAME$18 = "vc-upload";
19433
20102
  const Upload$1 = vue.defineComponent({
19434
- name: COMPONENT_NAME$16,
20103
+ name: COMPONENT_NAME$18,
19435
20104
  props: props$N,
19436
20105
  emits: [
19437
20106
  "message",
@@ -19954,9 +20623,9 @@ var Vc = (function (exports, vue) {
19954
20623
  default: true
19955
20624
  }
19956
20625
  };
19957
- const COMPONENT_NAME$15 = "vc-editor";
20626
+ const COMPONENT_NAME$17 = "vc-editor";
19958
20627
  const Editor$1 = /* @__PURE__ */ vue.defineComponent({
19959
- name: COMPONENT_NAME$15,
20628
+ name: COMPONENT_NAME$17,
19960
20629
  props: props$M,
19961
20630
  defaults: defaults$3,
19962
20631
  emits: ["ready", "blur", "focus", "input", "update:modelValue", "change"],
@@ -20137,7 +20806,7 @@ var Vc = (function (exports, vue) {
20137
20806
  };
20138
20807
  }
20139
20808
  });
20140
- const COMPONENT_NAME$14 = "vc-editor-view";
20809
+ const COMPONENT_NAME$16 = "vc-editor-view";
20141
20810
  const setImages = (v) => {
20142
20811
  if (!v) return;
20143
20812
  const IMG_REGX = /<img.*?(?:>|\/>)/gi;
@@ -20154,7 +20823,7 @@ var Vc = (function (exports, vue) {
20154
20823
  return;
20155
20824
  };
20156
20825
  const EditorView = /* @__PURE__ */ vue.defineComponent({
20157
- name: COMPONENT_NAME$14,
20826
+ name: COMPONENT_NAME$16,
20158
20827
  props: {
20159
20828
  value: {
20160
20829
  type: String,
@@ -20362,9 +21031,9 @@ var Vc = (function (exports, vue) {
20362
21031
  validateField
20363
21032
  });
20364
21033
  };
20365
- const COMPONENT_NAME$13 = "vc-form";
21034
+ const COMPONENT_NAME$15 = "vc-form";
20366
21035
  const Form = vue.defineComponent({
20367
- name: COMPONENT_NAME$13,
21036
+ name: COMPONENT_NAME$15,
20368
21037
  props: props$L,
20369
21038
  setup(props2, { slots, expose }) {
20370
21039
  useForm(expose);
@@ -20707,9 +21376,9 @@ var Vc = (function (exports, vue) {
20707
21376
  labelPosition
20708
21377
  };
20709
21378
  };
20710
- const COMPONENT_NAME$12 = "vc-form-item";
21379
+ const COMPONENT_NAME$14 = "vc-form-item";
20711
21380
  const FormItem = /* @__PURE__ */ vue.defineComponent({
20712
- name: COMPONENT_NAME$12,
21381
+ name: COMPONENT_NAME$14,
20713
21382
  props: props$K,
20714
21383
  setup(props2, {
20715
21384
  slots,
@@ -20775,9 +21444,9 @@ var Vc = (function (exports, vue) {
20775
21444
  default: false
20776
21445
  }
20777
21446
  };
20778
- const COMPONENT_NAME$11 = "vcm-form";
21447
+ const COMPONENT_NAME$13 = "vcm-form";
20779
21448
  const MForm = vue.defineComponent({
20780
- name: COMPONENT_NAME$11,
21449
+ name: COMPONENT_NAME$13,
20781
21450
  props: props$J,
20782
21451
  setup(props2, { slots, expose }) {
20783
21452
  useForm(expose, {
@@ -20804,9 +21473,9 @@ var Vc = (function (exports, vue) {
20804
21473
  default: 12
20805
21474
  }
20806
21475
  };
20807
- const COMPONENT_NAME$10 = "vcm-form-item";
21476
+ const COMPONENT_NAME$12 = "vcm-form-item";
20808
21477
  const MFormItem = /* @__PURE__ */ vue.defineComponent({
20809
- name: COMPONENT_NAME$10,
21478
+ name: COMPONENT_NAME$12,
20810
21479
  props: props$I,
20811
21480
  setup(props2, {
20812
21481
  slots,
@@ -20860,9 +21529,9 @@ var Vc = (function (exports, vue) {
20860
21529
  };
20861
21530
  }
20862
21531
  });
20863
- const COMPONENT_NAME$$ = "vc-fragment";
21532
+ const COMPONENT_NAME$11 = "vc-fragment";
20864
21533
  const Fragment = vue.defineComponent({
20865
- name: COMPONENT_NAME$$,
21534
+ name: COMPONENT_NAME$11,
20866
21535
  setup(_, { slots }) {
20867
21536
  return () => vue.h(vue.Fragment, slots.default?.());
20868
21537
  }
@@ -20896,9 +21565,9 @@ var Vc = (function (exports, vue) {
20896
21565
  default: () => ({})
20897
21566
  }
20898
21567
  };
20899
- const COMPONENT_NAME$_ = "vc-snapshot";
21568
+ const COMPONENT_NAME$10 = "vc-snapshot";
20900
21569
  const Snapshot = /* @__PURE__ */ vue.defineComponent({
20901
- name: COMPONENT_NAME$_,
21570
+ name: COMPONENT_NAME$10,
20902
21571
  props: props$H,
20903
21572
  emits: ["ready"],
20904
21573
  setup(props2, {
@@ -21050,7 +21719,7 @@ var Vc = (function (exports, vue) {
21050
21719
  }
21051
21720
  }
21052
21721
  const IMGStore$1 = new IMGStore();
21053
- const COMPONENT_NAME$Z = "vc-image";
21722
+ const COMPONENT_NAME$$ = "vc-image";
21054
21723
  let isSupportObjectFit = false;
21055
21724
  window.addEventListener("DOMContentLoaded", () => {
21056
21725
  isSupportObjectFit = !IS_SERVER$3 && document.documentElement.style.objectFit !== void 0;
@@ -21063,7 +21732,7 @@ var Vc = (function (exports, vue) {
21063
21732
  SCALE_DOWN: "scale-down"
21064
21733
  };
21065
21734
  const Image$1$1 = /* @__PURE__ */ vue.defineComponent({
21066
- name: COMPONENT_NAME$Z,
21735
+ name: COMPONENT_NAME$$,
21067
21736
  inheritAttrs: false,
21068
21737
  props: props$G,
21069
21738
  setup(props2, {
@@ -21271,9 +21940,9 @@ var Vc = (function (exports, vue) {
21271
21940
  default: "div"
21272
21941
  }
21273
21942
  };
21274
- const COMPONENT_NAME$Y = "vc-image-crop";
21943
+ const COMPONENT_NAME$_ = "vc-image-crop";
21275
21944
  const ImageCrop = /* @__PURE__ */ vue.defineComponent({
21276
- name: COMPONENT_NAME$Y,
21945
+ name: COMPONENT_NAME$_,
21277
21946
  props: props$F,
21278
21947
  setup(props2, {
21279
21948
  slots
@@ -21293,9 +21962,9 @@ var Vc = (function (exports, vue) {
21293
21962
  default: "div"
21294
21963
  }
21295
21964
  };
21296
- const COMPONENT_NAME$X = "vc-image-processing";
21965
+ const COMPONENT_NAME$Z = "vc-image-processing";
21297
21966
  const ImageProcessing = /* @__PURE__ */ vue.defineComponent({
21298
- name: COMPONENT_NAME$X,
21967
+ name: COMPONENT_NAME$Z,
21299
21968
  props: props$E,
21300
21969
  setup(props2, {
21301
21970
  slots
@@ -21308,9 +21977,9 @@ var Vc = (function (exports, vue) {
21308
21977
  }
21309
21978
  });
21310
21979
  const MImageProcessing = ImageProcessing;
21311
- const COMPONENT_NAME$W = "vcm-input";
21980
+ const COMPONENT_NAME$Y = "vcm-input";
21312
21981
  const MInput = /* @__PURE__ */ vue.defineComponent({
21313
- name: COMPONENT_NAME$W,
21982
+ name: COMPONENT_NAME$Y,
21314
21983
  inheritAttrs: false,
21315
21984
  props: {
21316
21985
  ...props$1h,
@@ -21397,9 +22066,9 @@ var Vc = (function (exports, vue) {
21397
22066
  };
21398
22067
  }
21399
22068
  });
21400
- const COMPONENT_NAME$V = "vcm-input-number";
22069
+ const COMPONENT_NAME$X = "vcm-input-number";
21401
22070
  const MInputNumber = /* @__PURE__ */ vue.defineComponent({
21402
- name: COMPONENT_NAME$V,
22071
+ name: COMPONENT_NAME$X,
21403
22072
  props: props$1g,
21404
22073
  inheritAttrs: false,
21405
22074
  setup(props2, {
@@ -21445,9 +22114,9 @@ var Vc = (function (exports, vue) {
21445
22114
  };
21446
22115
  }
21447
22116
  });
21448
- const COMPONENT_NAME$U = "vcm-input-search";
22117
+ const COMPONENT_NAME$W = "vcm-input-search";
21449
22118
  const MInputSearch = /* @__PURE__ */ vue.defineComponent({
21450
- name: COMPONENT_NAME$U,
22119
+ name: COMPONENT_NAME$W,
21451
22120
  props: {
21452
22121
  ...props$1f,
21453
22122
  cancelText: {
@@ -21521,9 +22190,9 @@ var Vc = (function (exports, vue) {
21521
22190
  default: true
21522
22191
  }
21523
22192
  };
21524
- const COMPONENT_NAME$T = "vcm-list";
22193
+ const COMPONENT_NAME$V = "vcm-list";
21525
22194
  const MList = vue.defineComponent({
21526
- name: COMPONENT_NAME$T,
22195
+ name: COMPONENT_NAME$V,
21527
22196
  props: props$D,
21528
22197
  setup(props2, { slots }) {
21529
22198
  vue.provide("vc-list", { props: props2 });
@@ -21574,10 +22243,10 @@ var Vc = (function (exports, vue) {
21574
22243
  // MListItem是否独立存在
21575
22244
  alone: Boolean
21576
22245
  };
21577
- const COMPONENT_NAME$S = "vcm-list-item";
22246
+ const COMPONENT_NAME$U = "vcm-list-item";
21578
22247
  const HTTP_REGEX = /[a-zA-z]+:\/\/[^\s]*/;
21579
22248
  const MListItem = /* @__PURE__ */ vue.defineComponent({
21580
- name: COMPONENT_NAME$S,
22249
+ name: COMPONENT_NAME$U,
21581
22250
  props: props$C,
21582
22251
  emits: ["click"],
21583
22252
  setup(props2, {
@@ -21661,11 +22330,11 @@ var Vc = (function (exports, vue) {
21661
22330
  default: false
21662
22331
  }
21663
22332
  };
21664
- const COMPONENT_NAME$R = "vc-marquee";
22333
+ const COMPONENT_NAME$T = "vc-marquee";
21665
22334
  const ANIMATION = prefixStyle("animation").camel;
21666
22335
  const TRANSFORM_KEBAB = prefixStyle("transform").kebab;
21667
22336
  const Marquee = /* @__PURE__ */ vue.defineComponent({
21668
- name: COMPONENT_NAME$R,
22337
+ name: COMPONENT_NAME$T,
21669
22338
  props: props$B,
21670
22339
  setup(props2, {
21671
22340
  slots
@@ -21726,9 +22395,9 @@ var Vc = (function (exports, vue) {
21726
22395
  default: true
21727
22396
  }
21728
22397
  };
21729
- const COMPONENT_NAME$Q = "vc-resizer";
22398
+ const COMPONENT_NAME$S = "vc-resizer";
21730
22399
  const Resizer = vue.defineComponent({
21731
- name: COMPONENT_NAME$Q,
22400
+ name: COMPONENT_NAME$S,
21732
22401
  props: props$A,
21733
22402
  emits: ["resize"],
21734
22403
  setup(props2, { emit, slots, expose }) {
@@ -21894,10 +22563,10 @@ var Vc = (function (exports, vue) {
21894
22563
  type: Function
21895
22564
  }
21896
22565
  };
21897
- const COMPONENT_NAME$P = "vc-modal";
22566
+ const COMPONENT_NAME$R = "vc-modal";
21898
22567
  let zIndexNumber = 1002;
21899
22568
  const ModalView = /* @__PURE__ */ vue.defineComponent({
21900
- name: COMPONENT_NAME$P,
22569
+ name: COMPONENT_NAME$R,
21901
22570
  emits: ["update:modelValue", "close", "portal-fulfilled", "visible-change", "ok", "cancel"],
21902
22571
  props: props$z,
21903
22572
  setup(props2, {
@@ -22287,9 +22956,9 @@ var Vc = (function (exports, vue) {
22287
22956
  type: Function
22288
22957
  }
22289
22958
  };
22290
- const COMPONENT_NAME$O = "vc-modal";
22959
+ const COMPONENT_NAME$Q = "vc-modal";
22291
22960
  const MModalView = /* @__PURE__ */ vue.defineComponent({
22292
- name: COMPONENT_NAME$O,
22961
+ name: COMPONENT_NAME$Q,
22293
22962
  emits: ["update:modelValue", "portal-fulfilled", "close", "ok", "cancel"],
22294
22963
  props: props$y,
22295
22964
  setup(props2, {
@@ -22484,9 +23153,9 @@ var Vc = (function (exports, vue) {
22484
23153
  // 这个相当于Modal中的onCancel,支持Promise
22485
23154
  onBeforeClose: Function
22486
23155
  };
22487
- const COMPONENT_NAME$N = "vc-notice";
23156
+ const COMPONENT_NAME$P = "vc-notice";
22488
23157
  const NoticeView = /* @__PURE__ */ vue.defineComponent({
22489
- name: COMPONENT_NAME$N,
23158
+ name: COMPONENT_NAME$P,
22490
23159
  props: props$x,
22491
23160
  emits: ["portal-fulfilled", "close", "before-close"],
22492
23161
  setup(props2, {
@@ -22652,9 +23321,9 @@ var Vc = (function (exports, vue) {
22652
23321
  default: "div"
22653
23322
  }
22654
23323
  };
22655
- const COMPONENT_NAME$M = "vc-option";
23324
+ const COMPONENT_NAME$O = "vc-option";
22656
23325
  const Option$1 = /* @__PURE__ */ vue.defineComponent({
22657
- name: COMPONENT_NAME$M,
23326
+ name: COMPONENT_NAME$O,
22658
23327
  props: props$w,
22659
23328
  setup(props2, {
22660
23329
  slots
@@ -22732,9 +23401,9 @@ var Vc = (function (exports, vue) {
22732
23401
  type: [String, Number]
22733
23402
  }
22734
23403
  };
22735
- const COMPONENT_NAME$L = "vc-tag";
23404
+ const COMPONENT_NAME$N = "vc-tag";
22736
23405
  const Tag = /* @__PURE__ */ vue.defineComponent({
22737
- name: COMPONENT_NAME$L,
23406
+ name: COMPONENT_NAME$N,
22738
23407
  props: props$u,
22739
23408
  emits: ["close", "change"],
22740
23409
  setup(props2, {
@@ -22801,9 +23470,9 @@ var Vc = (function (exports, vue) {
22801
23470
  render: [Function],
22802
23471
  row: Object
22803
23472
  };
22804
- const COMPONENT_NAME$K = "vc-select-option";
23473
+ const COMPONENT_NAME$M = "vc-select-option";
22805
23474
  const Option = /* @__PURE__ */ vue.defineComponent({
22806
- name: COMPONENT_NAME$K,
23475
+ name: COMPONENT_NAME$M,
22807
23476
  props: props$t,
22808
23477
  setup(props2, {
22809
23478
  slots,
@@ -22892,9 +23561,9 @@ var Vc = (function (exports, vue) {
22892
23561
  row: Object,
22893
23562
  render: [Function]
22894
23563
  };
22895
- const COMPONENT_NAME$J = "vc-select-option-group";
23564
+ const COMPONENT_NAME$L = "vc-select-option-group";
22896
23565
  const OptionGroup = /* @__PURE__ */ vue.defineComponent({
22897
- name: COMPONENT_NAME$J,
23566
+ name: COMPONENT_NAME$L,
22898
23567
  props: props$s,
22899
23568
  setup(props2, {
22900
23569
  slots
@@ -22921,9 +23590,9 @@ var Vc = (function (exports, vue) {
22921
23590
  };
22922
23591
  }
22923
23592
  });
22924
- const COMPONENT_NAME$I = "vc-select-all";
23593
+ const COMPONENT_NAME$K = "vc-select-all";
22925
23594
  const SelectAll = /* @__PURE__ */ vue.defineComponent({
22926
- name: COMPONENT_NAME$I,
23595
+ name: COMPONENT_NAME$K,
22927
23596
  props: {
22928
23597
  data: {
22929
23598
  type: Array,
@@ -22977,9 +23646,9 @@ var Vc = (function (exports, vue) {
22977
23646
  };
22978
23647
  }
22979
23648
  });
22980
- const COMPONENT_NAME$H = "vc-select";
23649
+ const COMPONENT_NAME$J = "vc-select";
22981
23650
  const Select = /* @__PURE__ */ vue.defineComponent({
22982
- name: COMPONENT_NAME$H,
23651
+ name: COMPONENT_NAME$J,
22983
23652
  props: props$1a,
22984
23653
  emits: ["ready", "close", "visible-change", "clear", "change", "update:modelValue"],
22985
23654
  setup(props2, {
@@ -23260,9 +23929,9 @@ var Vc = (function (exports, vue) {
23260
23929
  };
23261
23930
  }
23262
23931
  });
23263
- const COMPONENT_NAME$G = "vc-pagination";
23932
+ const COMPONENT_NAME$I = "vc-pagination";
23264
23933
  const Pagination = /* @__PURE__ */ vue.defineComponent({
23265
- name: COMPONENT_NAME$G,
23934
+ name: COMPONENT_NAME$I,
23266
23935
  props: props$v,
23267
23936
  emits: ["update:current", "change", "page-size-change"],
23268
23937
  setup(props2, {
@@ -23453,9 +24122,9 @@ var Vc = (function (exports, vue) {
23453
24122
  default: "div"
23454
24123
  }
23455
24124
  };
23456
- const COMPONENT_NAME$F = "vc-picker";
24125
+ const COMPONENT_NAME$H = "vc-picker";
23457
24126
  const Picker$1 = /* @__PURE__ */ vue.defineComponent({
23458
- name: COMPONENT_NAME$F,
24127
+ name: COMPONENT_NAME$H,
23459
24128
  props: props$r,
23460
24129
  setup(props2, {
23461
24130
  slots
@@ -23513,9 +24182,9 @@ var Vc = (function (exports, vue) {
23513
24182
  width: [String, Number],
23514
24183
  portalClass: [String, Object]
23515
24184
  };
23516
- const COMPONENT_NAME$E = "vc-popconfirm";
24185
+ const COMPONENT_NAME$G = "vc-popconfirm";
23517
24186
  const Popconfirm = /* @__PURE__ */ vue.defineComponent({
23518
- name: COMPONENT_NAME$E,
24187
+ name: COMPONENT_NAME$G,
23519
24188
  props: props$q,
23520
24189
  inheritAttrs: false,
23521
24190
  emits: ["update:modelValue", "visible-change", "ready", "close", "cancel", "ok"],
@@ -23675,9 +24344,9 @@ var Vc = (function (exports, vue) {
23675
24344
  })
23676
24345
  }
23677
24346
  };
23678
- const COMPONENT_NAME$D = "vc-popup";
24347
+ const COMPONENT_NAME$F = "vc-popup";
23679
24348
  const MPopup = /* @__PURE__ */ vue.defineComponent({
23680
- name: COMPONENT_NAME$D,
24349
+ name: COMPONENT_NAME$F,
23681
24350
  props: props$p,
23682
24351
  emits: ["update:modelValue", "close", "portal-fulfilled", "visible-change"],
23683
24352
  setup(props2, {
@@ -23786,9 +24455,9 @@ var Vc = (function (exports, vue) {
23786
24455
  default: "div"
23787
24456
  }
23788
24457
  };
23789
- const COMPONENT_NAME$C = "vc-print";
24458
+ const COMPONENT_NAME$E = "vc-print";
23790
24459
  const Print = /* @__PURE__ */ vue.defineComponent({
23791
- name: COMPONENT_NAME$C,
24460
+ name: COMPONENT_NAME$E,
23792
24461
  props: props$o,
23793
24462
  setup(props2, {
23794
24463
  expose,
@@ -23859,7 +24528,7 @@ var Vc = (function (exports, vue) {
23859
24528
  },
23860
24529
  strokeColor: {
23861
24530
  type: String,
23862
- default: "#2d8cf0"
24531
+ default: "#456CF6"
23863
24532
  },
23864
24533
  trackColor: {
23865
24534
  type: String,
@@ -23878,9 +24547,9 @@ var Vc = (function (exports, vue) {
23878
24547
  })
23879
24548
  }
23880
24549
  };
23881
- const COMPONENT_NAME$B = "vc-progress-circle";
24550
+ const COMPONENT_NAME$D = "vc-progress-circle";
23882
24551
  const Circle$1 = /* @__PURE__ */ vue.defineComponent({
23883
- name: COMPONENT_NAME$B,
24552
+ name: COMPONENT_NAME$D,
23884
24553
  props: props$n,
23885
24554
  setup(props2, {
23886
24555
  slots
@@ -23937,9 +24606,9 @@ var Vc = (function (exports, vue) {
23937
24606
  };
23938
24607
  }
23939
24608
  });
23940
- const COMPONENT_NAME$A = "vc-progress-line";
24609
+ const COMPONENT_NAME$C = "vc-progress-line";
23941
24610
  const Line$2 = /* @__PURE__ */ vue.defineComponent({
23942
- name: COMPONENT_NAME$A,
24611
+ name: COMPONENT_NAME$C,
23943
24612
  props: props$n,
23944
24613
  setup(props2) {
23945
24614
  const colorStyle = vue.computed(() => {
@@ -23983,9 +24652,9 @@ var Vc = (function (exports, vue) {
23983
24652
  function _isSlot(s) {
23984
24653
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
23985
24654
  }
23986
- const COMPONENT_NAME$z = "vc-progress";
24655
+ const COMPONENT_NAME$B = "vc-progress";
23987
24656
  const Progress = /* @__PURE__ */ vue.defineComponent({
23988
- name: COMPONENT_NAME$z,
24657
+ name: COMPONENT_NAME$B,
23989
24658
  props: props$n,
23990
24659
  setup(props2, {
23991
24660
  slots
@@ -24141,9 +24810,9 @@ var Vc = (function (exports, vue) {
24141
24810
  computedLabel
24142
24811
  };
24143
24812
  };
24144
- const COMPONENT_NAME$y = "vc-radio";
24813
+ const COMPONENT_NAME$A = "vc-radio";
24145
24814
  const Radio = /* @__PURE__ */ vue.defineComponent({
24146
- name: COMPONENT_NAME$y,
24815
+ name: COMPONENT_NAME$A,
24147
24816
  props: props$m,
24148
24817
  emits: ["update:modelValue", "change"],
24149
24818
  setup(props2, {
@@ -24184,9 +24853,9 @@ var Vc = (function (exports, vue) {
24184
24853
  };
24185
24854
  }
24186
24855
  });
24187
- const COMPONENT_NAME$x = "vc-radio-button";
24856
+ const COMPONENT_NAME$z = "vc-radio-button";
24188
24857
  const RadioButton = /* @__PURE__ */ vue.defineComponent({
24189
- name: COMPONENT_NAME$x,
24858
+ name: COMPONENT_NAME$z,
24190
24859
  props: {
24191
24860
  ...props$m,
24192
24861
  labelStyle: [String, Object],
@@ -24294,9 +24963,9 @@ var Vc = (function (exports, vue) {
24294
24963
  reset
24295
24964
  };
24296
24965
  };
24297
- const COMPONENT_NAME$w = "vc-radio-group";
24966
+ const COMPONENT_NAME$y = "vc-radio-group";
24298
24967
  const RadioGroup = /* @__PURE__ */ vue.defineComponent({
24299
- name: COMPONENT_NAME$w,
24968
+ name: COMPONENT_NAME$y,
24300
24969
  props: props$l,
24301
24970
  emits: ["update:modelValue", "change"],
24302
24971
  setup(props2, {
@@ -24314,9 +24983,9 @@ var Vc = (function (exports, vue) {
24314
24983
  };
24315
24984
  }
24316
24985
  });
24317
- const COMPONENT_NAME$v = "vcm-radio";
24986
+ const COMPONENT_NAME$x = "vcm-radio";
24318
24987
  const MRadio = /* @__PURE__ */ vue.defineComponent({
24319
- name: COMPONENT_NAME$v,
24988
+ name: COMPONENT_NAME$x,
24320
24989
  props: props$m,
24321
24990
  emits: ["update:modelValue", "change"],
24322
24991
  setup(props2, {
@@ -24357,9 +25026,9 @@ var Vc = (function (exports, vue) {
24357
25026
  };
24358
25027
  }
24359
25028
  });
24360
- const COMPONENT_NAME$u = "vcm-radio-group";
25029
+ const COMPONENT_NAME$w = "vcm-radio-group";
24361
25030
  const MRadioGroup = /* @__PURE__ */ vue.defineComponent({
24362
- name: COMPONENT_NAME$u,
25031
+ name: COMPONENT_NAME$w,
24363
25032
  props: props$l,
24364
25033
  emits: ["update:modelValue", "change"],
24365
25034
  setup(props2, {
@@ -24421,9 +25090,9 @@ var Vc = (function (exports, vue) {
24421
25090
  default: () => ({})
24422
25091
  }
24423
25092
  };
24424
- const COMPONENT_NAME$t = "vc-rate";
25093
+ const COMPONENT_NAME$v = "vc-rate";
24425
25094
  const Rate = /* @__PURE__ */ vue.defineComponent({
24426
- name: COMPONENT_NAME$t,
25095
+ name: COMPONENT_NAME$v,
24427
25096
  props: props$k,
24428
25097
  emits: ["update:modelValue", "change"],
24429
25098
  setup(props2, {
@@ -24618,9 +25287,9 @@ var Vc = (function (exports, vue) {
24618
25287
  renderPlaceholder: Function,
24619
25288
  renderRefresh: Function
24620
25289
  };
24621
- const COMPONENT_NAME$s = "vc-recycle-list-scroll-state";
25290
+ const COMPONENT_NAME$u = "vc-recycle-list-scroll-state";
24622
25291
  const ScrollState = /* @__PURE__ */ vue.defineComponent({
24623
- name: COMPONENT_NAME$s,
25292
+ name: COMPONENT_NAME$u,
24624
25293
  setup(_, {
24625
25294
  slots
24626
25295
  }) {
@@ -24744,10 +25413,10 @@ var Vc = (function (exports, vue) {
24744
25413
  );
24745
25414
  return keys;
24746
25415
  };
24747
- const COMPONENT_NAME$r = "vc-recycle-list-container";
25416
+ const COMPONENT_NAME$t = "vc-recycle-list-container";
24748
25417
  const transformKey = prefixStyle("transform").camel;
24749
25418
  const Container$1 = /* @__PURE__ */ vue.defineComponent({
24750
- name: COMPONENT_NAME$r,
25419
+ name: COMPONENT_NAME$t,
24751
25420
  props: props$i,
24752
25421
  emits: ["refresh"],
24753
25422
  setup(props2, {
@@ -24840,9 +25509,9 @@ var Vc = (function (exports, vue) {
24840
25509
  };
24841
25510
  }
24842
25511
  });
24843
- const COMPONENT_NAME$q = "vc-recycle-list";
25512
+ const COMPONENT_NAME$s = "vc-recycle-list";
24844
25513
  const RecycleList = /* @__PURE__ */ vue.defineComponent({
24845
- name: COMPONENT_NAME$q,
25514
+ name: COMPONENT_NAME$s,
24846
25515
  props: props$j,
24847
25516
  emits: ["scroll", "row-resize"],
24848
25517
  setup(props2, {
@@ -25367,9 +26036,9 @@ var Vc = (function (exports, vue) {
25367
26036
  default: "div"
25368
26037
  }
25369
26038
  };
25370
- const COMPONENT_NAME$p = "vc-slider";
26039
+ const COMPONENT_NAME$r = "vc-slider";
25371
26040
  const Slider = /* @__PURE__ */ vue.defineComponent({
25372
- name: COMPONENT_NAME$p,
26041
+ name: COMPONENT_NAME$r,
25373
26042
  props: props$h,
25374
26043
  setup(props2, {
25375
26044
  slots
@@ -25388,9 +26057,9 @@ var Vc = (function (exports, vue) {
25388
26057
  default: "div"
25389
26058
  }
25390
26059
  };
25391
- const COMPONENT_NAME$o = "vc-sort-list";
26060
+ const COMPONENT_NAME$q = "vc-sort-list";
25392
26061
  const SortList = /* @__PURE__ */ vue.defineComponent({
25393
- name: COMPONENT_NAME$o,
26062
+ name: COMPONENT_NAME$q,
25394
26063
  props: props$g,
25395
26064
  setup(props2, {
25396
26065
  slots
@@ -25409,9 +26078,9 @@ var Vc = (function (exports, vue) {
25409
26078
  default: "div"
25410
26079
  }
25411
26080
  };
25412
- const COMPONENT_NAME$n = "vc-steps";
26081
+ const COMPONENT_NAME$p = "vc-steps";
25413
26082
  const Steps = /* @__PURE__ */ vue.defineComponent({
25414
- name: COMPONENT_NAME$n,
26083
+ name: COMPONENT_NAME$p,
25415
26084
  props: props$f,
25416
26085
  setup(props2, {
25417
26086
  slots
@@ -25531,9 +26200,9 @@ var Vc = (function (exports, vue) {
25531
26200
  reset
25532
26201
  };
25533
26202
  };
25534
- const COMPONENT_NAME$m = "vc-switch";
26203
+ const COMPONENT_NAME$o = "vc-switch";
25535
26204
  const Switch = /* @__PURE__ */ vue.defineComponent({
25536
- name: COMPONENT_NAME$m,
26205
+ name: COMPONENT_NAME$o,
25537
26206
  props: props$e,
25538
26207
  // click -> onClick要被拦截,此处不能放置
25539
26208
  emits: ["update:modelValue", "change", "click"],
@@ -25604,9 +26273,9 @@ var Vc = (function (exports, vue) {
25604
26273
  };
25605
26274
  }
25606
26275
  });
25607
- const COMPONENT_NAME$l = "vcm-switch";
26276
+ const COMPONENT_NAME$n = "vcm-switch";
25608
26277
  const MSwitch = /* @__PURE__ */ vue.defineComponent({
25609
- name: COMPONENT_NAME$l,
26278
+ name: COMPONENT_NAME$n,
25610
26279
  props: props$e,
25611
26280
  // click -> onClick要被拦截,此处不能放置
25612
26281
  emits: ["update:modelValue", "change", "click"],
@@ -25742,9 +26411,9 @@ var Vc = (function (exports, vue) {
25742
26411
  };
25743
26412
  const columnsToRowsEffect = (v) => {
25744
26413
  let maxLevel = 1;
25745
- const traverse = (column, parent) => {
25746
- if (parent) {
25747
- column.level = parent.level + 1;
26414
+ const traverse = (column, parent2) => {
26415
+ if (parent2) {
26416
+ column.level = parent2.level + 1;
25748
26417
  if (maxLevel < column.level) {
25749
26418
  maxLevel = column.level;
25750
26419
  }
@@ -25798,8 +26467,8 @@ var Vc = (function (exports, vue) {
25798
26467
  level: baseLevel = 0
25799
26468
  } = opts;
25800
26469
  const isNil = (array) => !(Array.isArray(array) && array.length);
25801
- function _walker(parent, children, level) {
25802
- cb(parent, children, level);
26470
+ function _walker(parent2, children, level) {
26471
+ cb(parent2, children, level);
25803
26472
  children.forEach((item) => {
25804
26473
  if (item[lazyKey]) {
25805
26474
  cb(item, null, level + 1);
@@ -26012,8 +26681,8 @@ var Vc = (function (exports, vue) {
26012
26681
  const res = {};
26013
26682
  walkTreeNode(
26014
26683
  data,
26015
- (parent, children, level) => {
26016
- const parentId = getRowValue(parent, primaryKey);
26684
+ (parent2, children, level) => {
26685
+ const parentId = getRowValue(parent2, primaryKey);
26017
26686
  if (Array.isArray(children)) {
26018
26687
  res[parentId] = {
26019
26688
  children: children.map((row) => getRowValue(row, primaryKey)),
@@ -26153,9 +26822,9 @@ var Vc = (function (exports, vue) {
26153
26822
  this.store.states.treeData[key].expanded = true;
26154
26823
  walkTreeNode(
26155
26824
  data,
26156
- (parent, _, level) => {
26157
- const id = getRowValue(parent, primaryKey);
26158
- Object.defineProperty(parent, "__KEY__", {
26825
+ (parent2, _, level) => {
26826
+ const id = getRowValue(parent2, primaryKey);
26827
+ Object.defineProperty(parent2, "__KEY__", {
26159
26828
  value: `${level}__${id}`,
26160
26829
  writable: false
26161
26830
  });
@@ -26448,13 +27117,13 @@ var Vc = (function (exports, vue) {
26448
27117
  * @param index ~
26449
27118
  * @param parent ~
26450
27119
  */
26451
- insertColumn(column, index, parent) {
27120
+ insertColumn(column, index, parent2) {
26452
27121
  let array = this.states._columns;
26453
- if (parent) {
26454
- array = parent.children;
27122
+ if (parent2) {
27123
+ array = parent2.children;
26455
27124
  if (!array) {
26456
27125
  array = [];
26457
- parent.children = array;
27126
+ parent2.children = array;
26458
27127
  }
26459
27128
  }
26460
27129
  if (typeof index !== "undefined") {
@@ -26471,10 +27140,10 @@ var Vc = (function (exports, vue) {
26471
27140
  this.scheduleLayout();
26472
27141
  }
26473
27142
  }
26474
- removeColumn(column, parent) {
27143
+ removeColumn(column, parent2) {
26475
27144
  let array = this.states._columns;
26476
- if (parent) {
26477
- array = parent.children || [];
27145
+ if (parent2) {
27146
+ array = parent2.children || [];
26478
27147
  }
26479
27148
  if (array) {
26480
27149
  array.splice(array.indexOf(column), 1);
@@ -26707,9 +27376,9 @@ var Vc = (function (exports, vue) {
26707
27376
  });
26708
27377
  return states;
26709
27378
  };
26710
- const COMPONENT_NAME$k = "vc-table-normal-list";
27379
+ const COMPONENT_NAME$m = "vc-table-normal-list";
26711
27380
  const NormalList = /* @__PURE__ */ vue.defineComponent({
26712
- name: COMPONENT_NAME$k,
27381
+ name: COMPONENT_NAME$m,
26713
27382
  props: {
26714
27383
  data: {
26715
27384
  type: Array,
@@ -27703,9 +28372,9 @@ var Vc = (function (exports, vue) {
27703
28372
  default: void 0
27704
28373
  }
27705
28374
  };
27706
- const COMPONENT_NAME$j = "vc-table";
28375
+ const COMPONENT_NAME$l = "vc-table";
27707
28376
  const Table$1 = /* @__PURE__ */ vue.defineComponent({
27708
- name: COMPONENT_NAME$j,
28377
+ name: COMPONENT_NAME$l,
27709
28378
  props: props$d,
27710
28379
  emits: ["select", "select-all", "selection-change", "cell-mouse-enter", "cell-mouse-leave", "cell-click", "cell-dblclick", "row-click", "row-contextmenu", "row-dblclick", "header-click", "header-contextmenu", "current-change", "header-dragend", "expand-change", "sort-change", "update:sort"],
27711
28380
  setup(props2, {
@@ -28442,9 +29111,9 @@ var Vc = (function (exports, vue) {
28442
29111
  }) {
28443
29112
  const instance = vue.getCurrentInstance();
28444
29113
  const table = vue.inject("vc-table");
28445
- const parent = vue.inject("vc-table-column", table);
28446
- const isSubColumn = table !== parent;
28447
- const columnId = vue.ref((parent.tableId || parent.columnId) + getUid("column"));
29114
+ const parent2 = vue.inject("vc-table-column", table);
29115
+ const isSubColumn = table !== parent2;
29116
+ const columnId = vue.ref((parent2.tableId || parent2.columnId) + getUid("column"));
28448
29117
  const realWidth = vue.computed(() => {
28449
29118
  return parseWidth(props2.width);
28450
29119
  });
@@ -28570,13 +29239,13 @@ var Vc = (function (exports, vue) {
28570
29239
  registerWatchers();
28571
29240
  });
28572
29241
  vue.onMounted(() => {
28573
- const children = isSubColumn ? parent.vnode.el.children : parent.hiddenColumns.value.children;
29242
+ const children = isSubColumn ? parent2.vnode.el.children : parent2.hiddenColumns.value.children;
28574
29243
  const columnIndex = [...children].indexOf(instance.vnode.el);
28575
- table.store.insertColumn(columnConfig, columnIndex, isSubColumn && parent.columnConfig);
29244
+ table.store.insertColumn(columnConfig, columnIndex, isSubColumn && parent2.columnConfig);
28576
29245
  });
28577
29246
  vue.onUnmounted(() => {
28578
29247
  if (!instance.parent) return;
28579
- table.store.removeColumn(columnConfig, isSubColumn && parent.columnConfig);
29248
+ table.store.removeColumn(columnConfig, isSubColumn && parent2.columnConfig);
28580
29249
  });
28581
29250
  vue.provide("vc-table-column", {
28582
29251
  columnId,
@@ -28821,9 +29490,9 @@ var Vc = (function (exports, vue) {
28821
29490
  handleChange
28822
29491
  };
28823
29492
  };
28824
- const COMPONENT_NAME$i = "vc-tabs";
29493
+ const COMPONENT_NAME$k = "vc-tabs";
28825
29494
  const Tabs = /* @__PURE__ */ vue.defineComponent({
28826
- name: COMPONENT_NAME$i,
29495
+ name: COMPONENT_NAME$k,
28827
29496
  props: props$c,
28828
29497
  emits: ["update:modelValue", "change", "click"],
28829
29498
  setup(props2, {
@@ -29052,9 +29721,9 @@ var Vc = (function (exports, vue) {
29052
29721
  currentValue
29053
29722
  };
29054
29723
  };
29055
- const COMPONENT_NAME$h = "vc-tabs-pane";
29724
+ const COMPONENT_NAME$j = "vc-tabs-pane";
29056
29725
  const TabsPane = /* @__PURE__ */ vue.defineComponent({
29057
- name: COMPONENT_NAME$h,
29726
+ name: COMPONENT_NAME$j,
29058
29727
  props: props$b,
29059
29728
  setup(_, {
29060
29729
  slots
@@ -29105,9 +29774,9 @@ var Vc = (function (exports, vue) {
29105
29774
  default: false
29106
29775
  }
29107
29776
  };
29108
- const COMPONENT_NAME$g = "vcm-tabs";
29777
+ const COMPONENT_NAME$i = "vcm-tabs";
29109
29778
  const MTabs = /* @__PURE__ */ vue.defineComponent({
29110
- name: COMPONENT_NAME$g,
29779
+ name: COMPONENT_NAME$i,
29111
29780
  props: props$a,
29112
29781
  emits: ["update:modelValue", "change", "click"],
29113
29782
  setup(props2, {
@@ -29335,9 +30004,9 @@ var Vc = (function (exports, vue) {
29335
30004
  };
29336
30005
  }
29337
30006
  });
29338
- const COMPONENT_NAME$f = "vcm-tabs-pane";
30007
+ const COMPONENT_NAME$h = "vcm-tabs-pane";
29339
30008
  const MTabsPane = /* @__PURE__ */ vue.defineComponent({
29340
- name: COMPONENT_NAME$f,
30009
+ name: COMPONENT_NAME$h,
29341
30010
  props: props$b,
29342
30011
  setup(_, {
29343
30012
  slots
@@ -29396,9 +30065,9 @@ var Vc = (function (exports, vue) {
29396
30065
  default: "dark"
29397
30066
  }
29398
30067
  };
29399
- const COMPONENT_NAME$e = "vc-text";
30068
+ const COMPONENT_NAME$g = "vc-text";
29400
30069
  const Text$2 = /* @__PURE__ */ vue.defineComponent({
29401
- name: COMPONENT_NAME$e,
30070
+ name: COMPONENT_NAME$g,
29402
30071
  props: props$9,
29403
30072
  setup(props2, {
29404
30073
  emit
@@ -29757,9 +30426,9 @@ var Vc = (function (exports, vue) {
29757
30426
  type: [Object, Array]
29758
30427
  }
29759
30428
  };
29760
- const COMPONENT_NAME$d = "vc-textarea";
30429
+ const COMPONENT_NAME$f = "vc-textarea";
29761
30430
  const Textarea = /* @__PURE__ */ vue.defineComponent({
29762
- name: COMPONENT_NAME$d,
30431
+ name: COMPONENT_NAME$f,
29763
30432
  props: Object.assign({}, props$8, {
29764
30433
  indicator: {
29765
30434
  type: [Boolean, Object],
@@ -29812,9 +30481,9 @@ var Vc = (function (exports, vue) {
29812
30481
  };
29813
30482
  }
29814
30483
  });
29815
- const COMPONENT_NAME$c = "vcm-textarea";
30484
+ const COMPONENT_NAME$e = "vcm-textarea";
29816
30485
  const MTextarea = /* @__PURE__ */ vue.defineComponent({
29817
- name: COMPONENT_NAME$c,
30486
+ name: COMPONENT_NAME$e,
29818
30487
  props: Object.assign({}, props$8, {
29819
30488
  align: {
29820
30489
  type: String,
@@ -29895,9 +30564,9 @@ var Vc = (function (exports, vue) {
29895
30564
  type: [String, Object]
29896
30565
  }
29897
30566
  };
29898
- const COMPONENT_NAME$b = "vc-theme";
30567
+ const COMPONENT_NAME$d = "vc-theme";
29899
30568
  const Theme$1 = vue.defineComponent({
29900
- name: COMPONENT_NAME$b,
30569
+ name: COMPONENT_NAME$d,
29901
30570
  props: props$7,
29902
30571
  setup(props2, { slots }) {
29903
30572
  const themeId = getUid("vc-theme");
@@ -29979,9 +30648,9 @@ var Vc = (function (exports, vue) {
29979
30648
  };
29980
30649
  }
29981
30650
  });
29982
- const COMPONENT_NAME$a = "vc-theme-view";
30651
+ const COMPONENT_NAME$c = "vc-theme-view";
29983
30652
  const ThemeView = vue.defineComponent({
29984
- name: COMPONENT_NAME$a,
30653
+ name: COMPONENT_NAME$c,
29985
30654
  props: props$7,
29986
30655
  setup(props2, { slots }) {
29987
30656
  return () => {
@@ -29996,9 +30665,9 @@ var Vc = (function (exports, vue) {
29996
30665
  };
29997
30666
  }
29998
30667
  });
29999
- const COMPONENT_NAME$9 = "vc-theme-text";
30668
+ const COMPONENT_NAME$b = "vc-theme-text";
30000
30669
  const ThemeText = vue.defineComponent({
30001
- name: COMPONENT_NAME$9,
30670
+ name: COMPONENT_NAME$b,
30002
30671
  props: props$7,
30003
30672
  setup(props2, { slots }) {
30004
30673
  return () => {
@@ -30013,9 +30682,9 @@ var Vc = (function (exports, vue) {
30013
30682
  };
30014
30683
  }
30015
30684
  });
30016
- const COMPONENT_NAME$8 = "vc-theme-image";
30685
+ const COMPONENT_NAME$a = "vc-theme-image";
30017
30686
  const ThemeImage = vue.defineComponent({
30018
- name: COMPONENT_NAME$8,
30687
+ name: COMPONENT_NAME$a,
30019
30688
  props: props$7,
30020
30689
  setup(props2, { slots }) {
30021
30690
  return () => {
@@ -30063,12 +30732,12 @@ var Vc = (function (exports, vue) {
30063
30732
  default: false
30064
30733
  }
30065
30734
  };
30066
- const COMPONENT_NAME$7 = "vc-time-picker";
30735
+ const COMPONENT_NAME$9 = "vc-time-picker";
30067
30736
  const getPanel = (type) => {
30068
30737
  const isRange = type === "timerange";
30069
30738
  return isRange ? TimeRangePanel : TimePanel;
30070
30739
  };
30071
- const TimePicker = createPicker(COMPONENT_NAME$7, props$6, () => {
30740
+ const TimePicker = createPicker(COMPONENT_NAME$9, props$6, () => {
30072
30741
  const props2 = vue.getCurrentInstance().props;
30073
30742
  const icon = vue.ref("icon");
30074
30743
  const panel = vue.shallowRef({});
@@ -30099,9 +30768,9 @@ var Vc = (function (exports, vue) {
30099
30768
  default: "div"
30100
30769
  }
30101
30770
  };
30102
- const COMPONENT_NAME$6 = "vc-timeline";
30771
+ const COMPONENT_NAME$8 = "vc-timeline";
30103
30772
  const Timeline = /* @__PURE__ */ vue.defineComponent({
30104
- name: COMPONENT_NAME$6,
30773
+ name: COMPONENT_NAME$8,
30105
30774
  props: props$5,
30106
30775
  setup(props2, {
30107
30776
  slots
@@ -30122,9 +30791,9 @@ var Vc = (function (exports, vue) {
30122
30791
  default: "div"
30123
30792
  }
30124
30793
  };
30125
- const COMPONENT_NAME$5 = "vc-touch";
30794
+ const COMPONENT_NAME$7 = "vc-touch";
30126
30795
  const Touch = /* @__PURE__ */ vue.defineComponent({
30127
- name: COMPONENT_NAME$5,
30796
+ name: COMPONENT_NAME$7,
30128
30797
  props: props$4,
30129
30798
  setup(props2, {
30130
30799
  slots
@@ -30185,10 +30854,10 @@ var Vc = (function (exports, vue) {
30185
30854
  node.states.checked = false;
30186
30855
  node.states.indeterminate = false;
30187
30856
  }
30188
- const parent = node.parentNode;
30189
- if (!parent || parent.states.level === 0) return;
30857
+ const parent2 = node.parentNode;
30858
+ if (!parent2 || parent2.states.level === 0) return;
30190
30859
  if (!node.store.checkStrictly) {
30191
- reInitChecked(parent);
30860
+ reInitChecked(parent2);
30192
30861
  }
30193
30862
  };
30194
30863
  const getPropertyFromData = (node, prop) => {
@@ -30281,21 +30950,21 @@ var Vc = (function (exports, vue) {
30281
30950
  this.updateLeafState();
30282
30951
  }
30283
30952
  getNextSiblingNode() {
30284
- const parent = this.parentNode;
30285
- if (parent) {
30286
- const index = parent.childNodes.indexOf(this);
30953
+ const parent2 = this.parentNode;
30954
+ if (parent2) {
30955
+ const index = parent2.childNodes.indexOf(this);
30287
30956
  if (index > -1) {
30288
- return parent.childNodes[index + 1];
30957
+ return parent2.childNodes[index + 1];
30289
30958
  }
30290
30959
  }
30291
30960
  return null;
30292
30961
  }
30293
30962
  getPreviousSiblingNode() {
30294
- const parent = this.parentNode;
30295
- if (parent) {
30296
- const index = parent.childNodes.indexOf(this);
30963
+ const parent2 = this.parentNode;
30964
+ if (parent2) {
30965
+ const index = parent2.childNodes.indexOf(this);
30297
30966
  if (index > -1) {
30298
- return index > 0 ? parent.childNodes[index - 1] : null;
30967
+ return index > 0 ? parent2.childNodes[index - 1] : null;
30299
30968
  }
30300
30969
  }
30301
30970
  return null;
@@ -30317,8 +30986,8 @@ var Vc = (function (exports, vue) {
30317
30986
  }
30318
30987
  }
30319
30988
  contains(target, deep = true) {
30320
- const walk = function(parent) {
30321
- const children = parent.childNodes || [];
30989
+ const walk = function(parent2) {
30990
+ const children = parent2.childNodes || [];
30322
30991
  let result = false;
30323
30992
  for (let i = 0, j = children.length; i < j; i++) {
30324
30993
  const child = children[i];
@@ -30332,9 +31001,9 @@ var Vc = (function (exports, vue) {
30332
31001
  return walk(this);
30333
31002
  }
30334
31003
  remove() {
30335
- const parent = this.parentNode;
30336
- if (parent) {
30337
- parent.removeChild(this);
31004
+ const parent2 = this.parentNode;
31005
+ if (parent2) {
31006
+ parent2.removeChild(this);
30338
31007
  }
30339
31008
  }
30340
31009
  insertChild(states, index, batch) {
@@ -30407,10 +31076,10 @@ var Vc = (function (exports, vue) {
30407
31076
  async expand(expandParent) {
30408
31077
  const done = () => {
30409
31078
  if (expandParent) {
30410
- let parent = this.parentNode;
30411
- while (parent && parent.states.level > 0) {
30412
- parent.states.expanded = true;
30413
- parent = parent.parentNode;
31079
+ let parent2 = this.parentNode;
31080
+ while (parent2 && parent2.states.level > 0) {
31081
+ parent2.states.expanded = true;
31082
+ parent2 = parent2.parentNode;
30414
31083
  }
30415
31084
  }
30416
31085
  this.states.expanded = true;
@@ -30487,10 +31156,10 @@ var Vc = (function (exports, vue) {
30487
31156
  handleDescendants();
30488
31157
  }
30489
31158
  }
30490
- const parent = this.parentNode;
30491
- if (!parent || parent.states.level === 0) return;
31159
+ const parent2 = this.parentNode;
31160
+ if (!parent2 || parent2.states.level === 0) return;
30492
31161
  if (!recursion) {
30493
- reInitChecked(parent);
31162
+ reInitChecked(parent2);
30494
31163
  }
30495
31164
  }
30496
31165
  getChildren(forceInit = false) {
@@ -30628,21 +31297,68 @@ var Vc = (function (exports, vue) {
30628
31297
  parentNode.insertChild({ data });
30629
31298
  }
30630
31299
  }
31300
+ /**
31301
+ * 级联非 strict:仅对「选中集合里的最深节点」做 setChecked(true, deep),
31302
+ * 避免对祖先逐个 deep 勾选把未出现在 checkedValues 里的兄弟子树再次全选。
31303
+ * @param checkedValues ~
31304
+ * @returns ~
31305
+ */
31306
+ _getCascadeCheckedAnchorIds(checkedValues) {
31307
+ const checkedSet = new Set(checkedValues);
31308
+ const nodesMap = this.nodesMap;
31309
+ const anchors = [];
31310
+ for (const id of checkedValues) {
31311
+ const node = nodesMap[id];
31312
+ if (!node) continue;
31313
+ const hasSelectedChildInSet = node.childNodes.some(
31314
+ (child) => checkedSet.has(child.getter.value)
31315
+ );
31316
+ if (!hasSelectedChildInSet) {
31317
+ anchors.push(id);
31318
+ }
31319
+ }
31320
+ anchors.sort((a, b) => {
31321
+ const na = nodesMap[a];
31322
+ const nb = nodesMap[b];
31323
+ if (!na || !nb) return 0;
31324
+ return nb.states.level - na.states.level;
31325
+ });
31326
+ return anchors;
31327
+ }
30631
31328
  _initDefaultCheckedNodes() {
30632
31329
  const checkedValues = this.checkedValues || [];
30633
31330
  const nodesMap = this.nodesMap;
30634
- checkedValues.forEach((id) => {
31331
+ if (this.checkStrictly) {
31332
+ checkedValues.forEach((id) => {
31333
+ const node = nodesMap[id];
31334
+ if (node) {
31335
+ node.setChecked(true, false);
31336
+ }
31337
+ });
31338
+ return;
31339
+ }
31340
+ const anchorIds = this._getCascadeCheckedAnchorIds(checkedValues);
31341
+ anchorIds.forEach((id) => {
30635
31342
  const node = nodesMap[id];
30636
31343
  if (node) {
30637
- node.setChecked(true, !this.checkStrictly);
31344
+ node.setChecked(true, true);
30638
31345
  }
30639
31346
  });
30640
31347
  }
30641
31348
  _initDefaultCheckedNode(node) {
30642
31349
  const checkedValues = this.checkedValues || [];
30643
31350
  const nodeValue = node.getter.value;
30644
- if (checkedValues.indexOf(nodeValue) !== -1) {
30645
- node.setChecked(true, !this.checkStrictly);
31351
+ if (checkedValues.indexOf(nodeValue) === -1) return;
31352
+ if (this.checkStrictly) {
31353
+ node.setChecked(true, false);
31354
+ return;
31355
+ }
31356
+ const checkedSet = new Set(checkedValues);
31357
+ const hasSelectedChildInSet = node.childNodes.some(
31358
+ (child) => checkedSet.has(child.getter.value)
31359
+ );
31360
+ if (!hasSelectedChildInSet) {
31361
+ node.setChecked(true, true);
30646
31362
  }
30647
31363
  }
30648
31364
  setCheckedValues(newVal) {
@@ -30740,10 +31456,10 @@ var Vc = (function (exports, vue) {
30740
31456
  node.setChecked(false, false);
30741
31457
  }
30742
31458
  } else {
30743
- let parent = node.parentNode;
30744
- while (parent && parent.states.level > 0) {
30745
- cache[parent.states.data[key]] = true;
30746
- parent = parent.parentNode;
31459
+ let parent2 = node.parentNode;
31460
+ while (parent2 && parent2.states.level > 0) {
31461
+ cache[parent2.states.data[key]] = true;
31462
+ parent2 = parent2.parentNode;
30747
31463
  }
30748
31464
  if (node.states.isLeaf || this.checkStrictly) {
30749
31465
  node.setChecked(true, false);
@@ -30865,9 +31581,9 @@ var Vc = (function (exports, vue) {
30865
31581
  default: true
30866
31582
  }
30867
31583
  };
30868
- const COMPONENT_NAME$4 = "vc-tree-node";
31584
+ const COMPONENT_NAME$6 = "vc-tree-node";
30869
31585
  const TreeNodeContent = /* @__PURE__ */ vue.defineComponent({
30870
- name: COMPONENT_NAME$4,
31586
+ name: COMPONENT_NAME$6,
30871
31587
  props: props$3,
30872
31588
  emits: ["node-expand"],
30873
31589
  setup(props2, {
@@ -31360,9 +32076,9 @@ var Vc = (function (exports, vue) {
31360
32076
  default: () => KEY_VALUE
31361
32077
  }
31362
32078
  };
31363
- const COMPONENT_NAME$3 = "vc-tree";
32079
+ const COMPONENT_NAME$5 = "vc-tree";
31364
32080
  const Tree2 = /* @__PURE__ */ vue.defineComponent({
31365
- name: COMPONENT_NAME$3,
32081
+ name: COMPONENT_NAME$5,
31366
32082
  props: props$2,
31367
32083
  emits: ["update:modelValue", "change", "check-change", "current-change", "node-click", "node-contextmenu", "node-collapse", "node-expand", "check", "node-drag-start", "node-drag-end", "node-drop", "node-drag-leave", "node-drag-enter", "node-drag-over"],
31368
32084
  setup(props2, {
@@ -31421,10 +32137,10 @@ var Vc = (function (exports, vue) {
31421
32137
  const node = store.getNode(data);
31422
32138
  if (!node) return [];
31423
32139
  const path = [node.states.data];
31424
- let parent = node.parentNode;
31425
- while (parent && parent !== root) {
31426
- path.push(parent.states.data);
31427
- parent = parent.parentNode;
32140
+ let parent2 = node.parentNode;
32141
+ while (parent2 && parent2 !== root) {
32142
+ path.push(parent2.states.data);
32143
+ parent2 = parent2.parentNode;
31428
32144
  }
31429
32145
  return path.reverse();
31430
32146
  };
@@ -31556,6 +32272,217 @@ var Vc = (function (exports, vue) {
31556
32272
  };
31557
32273
  }
31558
32274
  });
32275
+ const COMPONENT_NAME$4 = "vc-tree-select-content";
32276
+ const TreeSelectContent = /* @__PURE__ */ vue.defineComponent({
32277
+ name: COMPONENT_NAME$4,
32278
+ props: {
32279
+ value: {
32280
+ type: Array,
32281
+ required: true
32282
+ },
32283
+ data: {
32284
+ type: Array,
32285
+ default: () => []
32286
+ },
32287
+ checkStrictly: {
32288
+ type: Boolean,
32289
+ default: false
32290
+ },
32291
+ renderNodeLabel: Function
32292
+ },
32293
+ emits: ["change"],
32294
+ setup(props2, {
32295
+ emit
32296
+ }) {
32297
+ return () => {
32298
+ return vue.createVNode(Scroller, {
32299
+ "class": "vc-tree-select__options",
32300
+ "max-height": "200px"
32301
+ }, {
32302
+ default: () => [vue.createVNode(Tree2, {
32303
+ "model-value": props2.value,
32304
+ "expanded-values": props2.value,
32305
+ "data": props2.data,
32306
+ "checkStrictly": props2.checkStrictly,
32307
+ "allowDispatch": false,
32308
+ "showCheckbox": true,
32309
+ "renderNodeLabel": props2.renderNodeLabel,
32310
+ "onChange": (_, data) => emit("change", _, data)
32311
+ }, null)]
32312
+ });
32313
+ };
32314
+ }
32315
+ });
32316
+ const COMPONENT_NAME$3 = "vc-tree-select-content-cascader";
32317
+ const TreeSelectContentCascader = /* @__PURE__ */ vue.defineComponent({
32318
+ name: COMPONENT_NAME$3,
32319
+ props: {
32320
+ value: {
32321
+ type: Array,
32322
+ required: true
32323
+ },
32324
+ data: {
32325
+ type: Array,
32326
+ default: () => []
32327
+ },
32328
+ checkStrictly: {
32329
+ type: Boolean,
32330
+ default: false
32331
+ },
32332
+ renderNodeLabel: Function,
32333
+ numerable: {
32334
+ type: Boolean,
32335
+ default: false
32336
+ },
32337
+ separator: {
32338
+ type: String,
32339
+ default: ","
32340
+ },
32341
+ max: {
32342
+ type: Number,
32343
+ default: 1
32344
+ },
32345
+ nullValue: {
32346
+ type: [Number, String, Object],
32347
+ default: void 0
32348
+ }
32349
+ },
32350
+ emits: ["change"],
32351
+ setup(props2, {
32352
+ emit
32353
+ }) {
32354
+ const treeRef = vue.ref(null);
32355
+ const currentValue = vue.ref([]);
32356
+ const rebuildData = vue.computed(() => {
32357
+ if (!props2.data.length) return [];
32358
+ let temp = props2.data;
32359
+ const data = [];
32360
+ currentValue.value.forEach((cur) => {
32361
+ const col = temp;
32362
+ data.push(col);
32363
+ const next = (temp.find((i) => i.value == cur) || {}).children || [];
32364
+ temp = next;
32365
+ });
32366
+ data.push(temp);
32367
+ return data;
32368
+ });
32369
+ const panelTick = vue.ref(0);
32370
+ const columns = vue.computed(() => Array.from({
32371
+ length: currentValue.value.length + 1
32372
+ }).map((_, index) => index));
32373
+ const handleHover = (value, columnIndex) => {
32374
+ const len = currentValue.value.length - columnIndex;
32375
+ currentValue.value.splice(columnIndex, len, value);
32376
+ };
32377
+ const sync = async () => {
32378
+ await vue.nextTick();
32379
+ const tree = treeRef.value;
32380
+ if (!tree) return;
32381
+ const data = {
32382
+ checkedNodes: tree.getCheckedNodes(),
32383
+ checkedValues: tree.getCheckedValues(),
32384
+ halfCheckedNodes: tree.getHalfCheckedNodes(),
32385
+ halfCheckedValues: tree.getHalfCheckedValues()
32386
+ };
32387
+ panelTick.value++;
32388
+ emit("change", null, data);
32389
+ };
32390
+ const getNodeState = (item) => {
32391
+ const tree = treeRef.value;
32392
+ if (!tree) {
32393
+ return {
32394
+ checked: false,
32395
+ indeterminate: false
32396
+ };
32397
+ }
32398
+ const node = tree.getNode(item);
32399
+ if (!node) {
32400
+ return {
32401
+ checked: false,
32402
+ indeterminate: false
32403
+ };
32404
+ }
32405
+ return {
32406
+ checked: !!node.states.checked,
32407
+ indeterminate: !!node.states.indeterminate
32408
+ };
32409
+ };
32410
+ const hasChildren = (item) => {
32411
+ return !!(item.children && item.children.length > 0);
32412
+ };
32413
+ const handleCheckboxChange = async (v, item) => {
32414
+ const tree = treeRef.value;
32415
+ if (!tree) return;
32416
+ tree.setChecked(item, v, !props2.checkStrictly);
32417
+ sync();
32418
+ };
32419
+ const handleLabelClick = (v, item) => {
32420
+ const tree = treeRef.value;
32421
+ if (!tree) return;
32422
+ tree.setChecked(item, v, !props2.checkStrictly);
32423
+ sync();
32424
+ };
32425
+ return () => {
32426
+ return vue.createVNode("div", {
32427
+ "class": "vc-tree-select__cascader"
32428
+ }, [vue.createVNode(Tree2, {
32429
+ "ref": treeRef,
32430
+ "class": "vc-tree-select__cascader-tree-hidden",
32431
+ "model-value": props2.value,
32432
+ "expanded-values": props2.value,
32433
+ "data": props2.data,
32434
+ "checkStrictly": props2.checkStrictly,
32435
+ "allowDispatch": false,
32436
+ "showCheckbox": true,
32437
+ "renderNodeLabel": props2.renderNodeLabel,
32438
+ "numerable": props2.numerable,
32439
+ "separator": props2.separator,
32440
+ "max": props2.max,
32441
+ "nullValue": props2.nullValue
32442
+ }, null), vue.createVNode("div", {
32443
+ "class": "vc-tree-select__cascader-columns"
32444
+ }, [columns.value.map((columnIndex) => {
32445
+ const col = rebuildData.value[columnIndex];
32446
+ if (!col || !col.length) return null;
32447
+ return vue.createVNode("div", {
32448
+ "class": "vc-tree-select__cascader-column",
32449
+ "key": columnIndex
32450
+ }, [vue.createVNode("div", {
32451
+ "class": "vc-tree-select__cascader-column-wrapper"
32452
+ }, [col.map((item) => {
32453
+ const state = getNodeState(item);
32454
+ const isSelect = currentValue.value[columnIndex] === item.value;
32455
+ const child = hasChildren(item);
32456
+ return vue.createVNode("div", {
32457
+ "key": item.value,
32458
+ "class": ["vc-tree-select__cascader-item", {
32459
+ "is-select": isSelect
32460
+ }],
32461
+ "onMouseenter": () => handleHover(item.value, columnIndex),
32462
+ "onClick": () => handleLabelClick(!state.checked, item)
32463
+ }, [vue.createVNode("span", {
32464
+ "class": "vc-tree-select__cascader-checkbox",
32465
+ "onClick": (e) => e.stopPropagation()
32466
+ }, [vue.createVNode(Checkbox, {
32467
+ "modelValue": state.checked,
32468
+ "indeterminate": state.indeterminate,
32469
+ "disabled": !!item.disabled,
32470
+ "onChange": (v) => handleCheckboxChange(v, item)
32471
+ }, null)]), vue.createVNode("span", {
32472
+ "class": "vc-tree-select__cascader-label"
32473
+ }, [props2.renderNodeLabel && treeRef.value?.getNode?.(item) ? vue.createVNode(Customer, {
32474
+ "render": props2.renderNodeLabel,
32475
+ "store": treeRef.value.getNode(item),
32476
+ "row": item
32477
+ }, null) : vue.createVNode("span", null, [item.label])]), child ? vue.createVNode(Icon, {
32478
+ "type": "right",
32479
+ "class": "vc-tree-select__cascader-icon"
32480
+ }, null) : null]);
32481
+ })])]);
32482
+ })])]);
32483
+ };
32484
+ }
32485
+ });
31559
32486
  const treeKeys = [
31560
32487
  "checkStrictly",
31561
32488
  "data",
@@ -31564,7 +32491,18 @@ var Vc = (function (exports, vue) {
31564
32491
  ];
31565
32492
  const props$1 = {
31566
32493
  ...props$1a,
31567
- ...pick(props$2, treeKeys)
32494
+ ...pick(props$2, treeKeys),
32495
+ autoWidth: {
32496
+ type: Boolean,
32497
+ default: void 0
32498
+ },
32499
+ /**
32500
+ * 级联列模式:与 Cascader 相同的 hover 展开下一级,勾选逻辑与树形模式一致
32501
+ */
32502
+ cascader: {
32503
+ type: Boolean,
32504
+ default: false
32505
+ }
31568
32506
  };
31569
32507
  const COMPONENT_NAME$2 = "vc-tree-select";
31570
32508
  const TreeSelect = /* @__PURE__ */ vue.defineComponent({
@@ -31587,12 +32525,37 @@ var Vc = (function (exports, vue) {
31587
32525
  const searchValue = vue.ref("");
31588
32526
  const searchRegex = vue.ref(new RegExp(""));
31589
32527
  const currentValue = vue.ref([]);
32528
+ const currentValueGroups = vue.computed(() => {
32529
+ if (props2.checkStrictly) return;
32530
+ if (!props2.data?.length || !Array.isArray(currentValue.value) || !currentValue.value.length) {
32531
+ return [];
32532
+ }
32533
+ const pathMap = /* @__PURE__ */ new Map();
32534
+ const traverse = (data, path = []) => {
32535
+ data.forEach((item) => {
32536
+ const v = item.value;
32537
+ if (v == null) return;
32538
+ const fullPath = [...path, v];
32539
+ pathMap.set(v, fullPath);
32540
+ if (item.children?.length) traverse(item.children, fullPath);
32541
+ });
32542
+ };
32543
+ traverse(props2.data);
32544
+ const allPaths = currentValue.value.map((v) => pathMap.get(v)).filter(Boolean);
32545
+ return allPaths.filter((path) => !allPaths.some((other) => other !== path && other.length > path.length && path.every((v, i) => v === other[i])));
32546
+ });
31590
32547
  const source = vue.computed(() => {
31591
32548
  return flattenData$1(props2.data, {
31592
32549
  parent: true,
31593
32550
  cascader: true
31594
32551
  });
31595
32552
  });
32553
+ const labelMap = vue.computed(() => {
32554
+ return source.value.reduce((pre, cur) => {
32555
+ pre[cur.value] = cur.label || "";
32556
+ return pre;
32557
+ }, {});
32558
+ });
31596
32559
  const icon = vue.computed(() => {
31597
32560
  return isActive.value ? "up" : "down";
31598
32561
  });
@@ -31609,17 +32572,34 @@ var Vc = (function (exports, vue) {
31609
32572
  "is-disabled": props2.disabled
31610
32573
  };
31611
32574
  });
31612
- const currentLabel = vue.computed(() => {
32575
+ const displayTags = vue.computed(() => {
31613
32576
  if (!props2.data.length) {
31614
32577
  return [];
31615
32578
  }
31616
- return currentValue.value.map(getLabel.bind(null, source.value));
32579
+ if (props2.checkStrictly) {
32580
+ return currentValue.value.map((v) => ({
32581
+ value: v,
32582
+ label: labelMap.value[v] || ""
32583
+ }));
32584
+ }
32585
+ return (currentValueGroups.value || []).map((path) => {
32586
+ const value = path[path.length - 1];
32587
+ const label = path.map((v) => labelMap.value[v] || "").filter(Boolean).join(" / ");
32588
+ return {
32589
+ path,
32590
+ value,
32591
+ label
32592
+ };
32593
+ });
31617
32594
  });
31618
32595
  const collapseTagCount = vue.computed(() => {
31619
32596
  if (!props2.maxTags) return 0;
31620
- const v = currentValue.value.length - props2.maxTags;
32597
+ const v = displayTags.value.length - props2.maxTags;
31621
32598
  return v < 0 ? 0 : v;
31622
32599
  });
32600
+ const autoWidth = vue.computed(() => {
32601
+ return typeof props2.autoWidth === "boolean" ? props2.autoWidth : !!props2.cascader;
32602
+ });
31623
32603
  const sync = () => {
31624
32604
  const v = toModelValue(currentValue.value, {
31625
32605
  modelValue: props2.modelValue,
@@ -31628,8 +32608,9 @@ var Vc = (function (exports, vue) {
31628
32608
  separator: props2.separator,
31629
32609
  nullValue: props2.nullValue
31630
32610
  });
31631
- emit("update:modelValue", v, currentLabel.value);
31632
- emit("change", v, currentLabel.value);
32611
+ const labels = displayTags.value.map((item) => item.label);
32612
+ emit("update:modelValue", v, labels);
32613
+ emit("change", v, labels);
31633
32614
  formItem?.change?.(currentValue.value);
31634
32615
  };
31635
32616
  const _loadData = debounce(function() {
@@ -31648,8 +32629,15 @@ var Vc = (function (exports, vue) {
31648
32629
  const close = () => {
31649
32630
  isActive.value = false;
31650
32631
  };
31651
- const handleClose = (index) => {
31652
- currentValue.value.splice(index, 1);
32632
+ const handleClose = (item) => {
32633
+ if (props2.checkStrictly) {
32634
+ const index = currentValue.value.findIndex((v) => v === item.value);
32635
+ if (index === -1) return;
32636
+ currentValue.value = currentValue.value.filter((_, i) => i !== index);
32637
+ } else if (item.path) {
32638
+ const remaining = (currentValueGroups.value || []).filter((p) => !(p.length === item.path.length && p.every((v, i) => v === item.path[i])));
32639
+ currentValue.value = [...new Set(remaining.flat())];
32640
+ }
31653
32641
  sync();
31654
32642
  };
31655
32643
  const handleClear = (e) => {
@@ -31686,6 +32674,7 @@ var Vc = (function (exports, vue) {
31686
32674
  multiple,
31687
32675
  isActive,
31688
32676
  current: currentValue,
32677
+ currentValueGroups,
31689
32678
  // for portal
31690
32679
  toggle(v) {
31691
32680
  v = typeof v === "boolean" ? v : !isActive.value;
@@ -31700,7 +32689,7 @@ var Vc = (function (exports, vue) {
31700
32689
  "trigger": props2.trigger,
31701
32690
  "tag": props2.tag,
31702
32691
  "placement": props2.placement,
31703
- "auto-width": props2.autoWidth,
32692
+ "autoWidth": autoWidth.value,
31704
32693
  "disabled": props2.disabled,
31705
32694
  "portalClass": [["is-padding-none", props2.portalClass]],
31706
32695
  "class": [classes.value, its.value.class, "vc-tree-select"],
@@ -31717,22 +32706,22 @@ var Vc = (function (exports, vue) {
31717
32706
  return vue.createVNode(Input$1, {
31718
32707
  "id": props2.id,
31719
32708
  "disabled": props2.disabled,
31720
- "modelValue": currentLabel.value[0] || props2.extra,
32709
+ "modelValue": displayTags.value[0]?.label || props2.extra,
31721
32710
  "allow-dispatch": false,
31722
32711
  "class": "vc-tree-select__input",
31723
32712
  "readonly": true,
31724
32713
  "placeholder": its.value.attrs?.placeholder || "请选择"
31725
32714
  }, {
31726
- content: multiple.value && currentValue.value && currentValue.value.length > 0 ? () => {
32715
+ content: multiple.value && displayTags.value.length > 0 ? () => {
31727
32716
  return vue.createVNode("div", {
31728
32717
  "class": [classes.value, "vc-tree-select__tags"]
31729
- }, [currentValue.value.slice(0, props2.maxTags).map((item, index) => {
32718
+ }, [displayTags.value.slice(0, props2.maxTags).map((item) => {
31730
32719
  return vue.createVNode(Tag, {
31731
- "key": item,
32720
+ "key": item.path ? item.path.join("-") : item.value,
31732
32721
  "closable": !props2.disabled,
31733
- "onClose": () => handleClose(index)
32722
+ "onClose": () => handleClose(item)
31734
32723
  }, {
31735
- default: () => [currentLabel.value[index] || ""]
32724
+ default: () => [item.label]
31736
32725
  });
31737
32726
  }), collapseTagCount.value ? vue.createVNode(Tag, null, {
31738
32727
  default: () => [`+${collapseTagCount.value}...`]
@@ -31765,16 +32754,23 @@ var Vc = (function (exports, vue) {
31765
32754
  }, [vue.createVNode(Spin, {
31766
32755
  "size": 16
31767
32756
  }, null)]), vue.createVNode(Scroller, {
31768
- "class": "vc-tree-select__options",
32757
+ "class": ["vc-tree-select__options", props2.cascader && "is-cascader"],
31769
32758
  "max-height": "200px"
31770
32759
  }, {
31771
- default: () => [vue.createVNode(Tree2, {
31772
- "model-value": currentValue.value,
31773
- "expanded-values": currentValue.value,
32760
+ default: () => [props2.cascader ? vue.createVNode(TreeSelectContentCascader, {
32761
+ "value": currentValue.value,
32762
+ "data": props2.data,
32763
+ "checkStrictly": props2.checkStrictly,
32764
+ "renderNodeLabel": props2.renderNodeLabel,
32765
+ "numerable": props2.numerable,
32766
+ "separator": props2.separator,
32767
+ "max": props2.max,
32768
+ "nullValue": props2.nullValue,
32769
+ "onChange": handleChange
32770
+ }, null) : vue.createVNode(TreeSelectContent, {
32771
+ "value": currentValue.value,
31774
32772
  "data": props2.data,
31775
32773
  "checkStrictly": props2.checkStrictly,
31776
- "allowDispatch": false,
31777
- "showCheckbox": true,
31778
32774
  "renderNodeLabel": props2.renderNodeLabel,
31779
32775
  "onChange": handleChange
31780
32776
  }, null)]
@@ -32343,8 +33339,8 @@ var Vc = (function (exports, vue) {
32343
33339
  MCard,
32344
33340
  Carousel,
32345
33341
  MCarousel,
32346
- // CarouselItem,
32347
- // MCarouselItem,
33342
+ CarouselItem,
33343
+ MCarouselItem,
32348
33344
  Cascader,
32349
33345
  MCascader,
32350
33346
  // MCascaderView,
@@ -138696,6 +139692,7 @@ ${r}
138696
139692
  exports.Calendar = Calendar$1;
138697
139693
  exports.Card = Card;
138698
139694
  exports.Carousel = Carousel;
139695
+ exports.CarouselItem = CarouselItem;
138699
139696
  exports.Cascader = Cascader;
138700
139697
  exports.Chart = Chart;
138701
139698
  exports.Checkbox = Checkbox;
@@ -138742,6 +139739,7 @@ ${r}
138742
139739
  exports.MCalendar = MCalendar;
138743
139740
  exports.MCard = MCard;
138744
139741
  exports.MCarousel = MCarousel;
139742
+ exports.MCarouselItem = MCarouselItem;
138745
139743
  exports.MCascader = MCascader;
138746
139744
  exports.MChart = MChart;
138747
139745
  exports.MCheckbox = MCheckbox;