@deot/vc-components 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.
- package/dist/index.cjs +1358 -339
- package/dist/index.d.ts +386 -101
- package/dist/index.iife.js +1420 -401
- package/dist/index.js +1360 -343
- package/dist/index.style.css +2 -2
- package/dist/index.umd.cjs +1420 -401
- package/package.json +1 -1
package/dist/index.iife.js
CHANGED
|
@@ -74,7 +74,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
74
74
|
}
|
|
75
75
|
const VcInstance = new Instance();
|
|
76
76
|
|
|
77
|
-
const props$
|
|
77
|
+
const props$1v = {
|
|
78
78
|
tag: {
|
|
79
79
|
type: String,
|
|
80
80
|
default: "div"
|
|
@@ -83,10 +83,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
83
83
|
|
|
84
84
|
/** @jsxImportSource vue */
|
|
85
85
|
|
|
86
|
-
const COMPONENT_NAME$
|
|
86
|
+
const COMPONENT_NAME$2g = 'vc-action-sheet';
|
|
87
87
|
const ActionSheet = /* @__PURE__ */ vue.defineComponent({
|
|
88
|
-
name: COMPONENT_NAME$
|
|
89
|
-
props: props$
|
|
88
|
+
name: COMPONENT_NAME$2g,
|
|
89
|
+
props: props$1v,
|
|
90
90
|
setup(props, {
|
|
91
91
|
slots
|
|
92
92
|
}) {
|
|
@@ -100,7 +100,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
100
100
|
|
|
101
101
|
const MActionSheet = ActionSheet;
|
|
102
102
|
|
|
103
|
-
const props$
|
|
103
|
+
const props$1u = {
|
|
104
104
|
modelValue: {
|
|
105
105
|
type: Boolean,
|
|
106
106
|
default: false
|
|
@@ -378,11 +378,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
378
378
|
|
|
379
379
|
/** @jsxImportSource vue */
|
|
380
380
|
|
|
381
|
-
const COMPONENT_NAME$
|
|
381
|
+
const COMPONENT_NAME$2f = 'vc-affix';
|
|
382
382
|
const Affix = /* @__PURE__ */ vue.defineComponent({
|
|
383
|
-
name: COMPONENT_NAME$
|
|
383
|
+
name: COMPONENT_NAME$2f,
|
|
384
384
|
emits: ['update:modelValue'],
|
|
385
|
-
props: props$
|
|
385
|
+
props: props$1u,
|
|
386
386
|
setup(props, {
|
|
387
387
|
slots,
|
|
388
388
|
expose,
|
|
@@ -548,7 +548,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
548
548
|
|
|
549
549
|
const MAffix = Affix;
|
|
550
550
|
|
|
551
|
-
const props$
|
|
551
|
+
const props$1t = {
|
|
552
552
|
modelValue: {
|
|
553
553
|
type: Boolean,
|
|
554
554
|
default: true
|
|
@@ -575,7 +575,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
575
575
|
}
|
|
576
576
|
};
|
|
577
577
|
|
|
578
|
-
const props$
|
|
578
|
+
const props$1s = {
|
|
579
579
|
type: String,
|
|
580
580
|
inherit: {
|
|
581
581
|
type: Boolean,
|
|
@@ -712,10 +712,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
712
712
|
|
|
713
713
|
/** @jsxImportSource vue */
|
|
714
714
|
|
|
715
|
-
const COMPONENT_NAME$
|
|
715
|
+
const COMPONENT_NAME$2e = 'vc-icon';
|
|
716
716
|
const Icon = /* @__PURE__ */ vue.defineComponent({
|
|
717
|
-
name: COMPONENT_NAME$
|
|
718
|
-
props: props$
|
|
717
|
+
name: COMPONENT_NAME$2e,
|
|
718
|
+
props: props$1s,
|
|
719
719
|
setup(props) {
|
|
720
720
|
const viewBox = vue.ref('0 0 1024 1024');
|
|
721
721
|
const path = vue.ref([]);
|
|
@@ -748,7 +748,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
748
748
|
}
|
|
749
749
|
});
|
|
750
750
|
|
|
751
|
-
const props$
|
|
751
|
+
const props$1r = {
|
|
752
752
|
/**
|
|
753
753
|
* 进入/离开持续时间
|
|
754
754
|
* {enter: 300, leave: 300}
|
|
@@ -913,10 +913,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
913
913
|
};
|
|
914
914
|
};
|
|
915
915
|
|
|
916
|
-
const COMPONENT_NAME$
|
|
916
|
+
const COMPONENT_NAME$2d = "vc-transition";
|
|
917
917
|
const Transition = vue.defineComponent({
|
|
918
|
-
name: COMPONENT_NAME$
|
|
919
|
-
props: props$
|
|
918
|
+
name: COMPONENT_NAME$2d,
|
|
919
|
+
props: props$1r,
|
|
920
920
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
921
921
|
inheritAttrs: false,
|
|
922
922
|
setup(props, { slots, attrs }) {
|
|
@@ -936,10 +936,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
936
936
|
}
|
|
937
937
|
});
|
|
938
938
|
|
|
939
|
-
const COMPONENT_NAME$
|
|
939
|
+
const COMPONENT_NAME$2c = "vc-transition-collapse";
|
|
940
940
|
const TransitionCollapse = vue.defineComponent({
|
|
941
|
-
name: COMPONENT_NAME$
|
|
942
|
-
props: props$
|
|
941
|
+
name: COMPONENT_NAME$2c,
|
|
942
|
+
props: props$1r,
|
|
943
943
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
944
944
|
inheritAttrs: false,
|
|
945
945
|
setup(props, { slots, attrs: _attrs }) {
|
|
@@ -1053,11 +1053,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
1053
1053
|
}
|
|
1054
1054
|
});
|
|
1055
1055
|
|
|
1056
|
-
const COMPONENT_NAME$
|
|
1056
|
+
const COMPONENT_NAME$2b = "vc-transition-fade";
|
|
1057
1057
|
const TransitionFade = vue.defineComponent({
|
|
1058
|
-
name: COMPONENT_NAME$
|
|
1058
|
+
name: COMPONENT_NAME$2b,
|
|
1059
1059
|
props: {
|
|
1060
|
-
...props$
|
|
1060
|
+
...props$1r,
|
|
1061
1061
|
// inheritAttrs必须是false
|
|
1062
1062
|
style: {
|
|
1063
1063
|
type: Object,
|
|
@@ -1090,11 +1090,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
1090
1090
|
}
|
|
1091
1091
|
});
|
|
1092
1092
|
|
|
1093
|
-
const COMPONENT_NAME$
|
|
1093
|
+
const COMPONENT_NAME$2a = "vc-transition-scale";
|
|
1094
1094
|
const TransitionScale = vue.defineComponent({
|
|
1095
|
-
name: COMPONENT_NAME$
|
|
1095
|
+
name: COMPONENT_NAME$2a,
|
|
1096
1096
|
props: {
|
|
1097
|
-
...props$
|
|
1097
|
+
...props$1r,
|
|
1098
1098
|
mode: {
|
|
1099
1099
|
type: String,
|
|
1100
1100
|
default: "both",
|
|
@@ -1132,11 +1132,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
1132
1132
|
}
|
|
1133
1133
|
});
|
|
1134
1134
|
|
|
1135
|
-
const COMPONENT_NAME$
|
|
1135
|
+
const COMPONENT_NAME$29 = "vc-transition-slide";
|
|
1136
1136
|
const TransitionSlide = vue.defineComponent({
|
|
1137
|
-
name: COMPONENT_NAME$
|
|
1137
|
+
name: COMPONENT_NAME$29,
|
|
1138
1138
|
props: {
|
|
1139
|
-
...props$
|
|
1139
|
+
...props$1r,
|
|
1140
1140
|
mode: {
|
|
1141
1141
|
type: String,
|
|
1142
1142
|
default: "left",
|
|
@@ -1174,11 +1174,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
1174
1174
|
}
|
|
1175
1175
|
});
|
|
1176
1176
|
|
|
1177
|
-
const COMPONENT_NAME$
|
|
1177
|
+
const COMPONENT_NAME$28 = "vc-transition-zoom";
|
|
1178
1178
|
const TransitionZoom = vue.defineComponent({
|
|
1179
|
-
name: COMPONENT_NAME$
|
|
1179
|
+
name: COMPONENT_NAME$28,
|
|
1180
1180
|
props: {
|
|
1181
|
-
...props$
|
|
1181
|
+
...props$1r,
|
|
1182
1182
|
mode: {
|
|
1183
1183
|
type: String,
|
|
1184
1184
|
default: "x",
|
|
@@ -1218,7 +1218,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
1218
1218
|
|
|
1219
1219
|
/** @jsxImportSource vue */
|
|
1220
1220
|
|
|
1221
|
-
const COMPONENT_NAME$
|
|
1221
|
+
const COMPONENT_NAME$27 = 'vc-alert';
|
|
1222
1222
|
|
|
1223
1223
|
// [color, borderColor, backgroundColor], -> CSS
|
|
1224
1224
|
const THEME_MAP = {
|
|
@@ -1228,8 +1228,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
1228
1228
|
warning: ['#ffbf00', '#ffe58f', '#fffbe6']
|
|
1229
1229
|
};
|
|
1230
1230
|
const Alert = /* @__PURE__ */ vue.defineComponent({
|
|
1231
|
-
name: COMPONENT_NAME$
|
|
1232
|
-
props: props$
|
|
1231
|
+
name: COMPONENT_NAME$27,
|
|
1232
|
+
props: props$1t,
|
|
1233
1233
|
setup(props, {
|
|
1234
1234
|
slots,
|
|
1235
1235
|
emit
|
|
@@ -1444,7 +1444,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
1444
1444
|
return flatten$1(value, JSON.parse);
|
|
1445
1445
|
};
|
|
1446
1446
|
|
|
1447
|
-
const props$
|
|
1447
|
+
const props$1q = {
|
|
1448
1448
|
// canvas配置参数
|
|
1449
1449
|
options: Object,
|
|
1450
1450
|
width: {
|
|
@@ -1460,10 +1460,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
1460
1460
|
/** @jsxImportSource vue */
|
|
1461
1461
|
|
|
1462
1462
|
const isTouch = typeof document !== 'undefined' && 'ontouchend' in document;
|
|
1463
|
-
const COMPONENT_NAME$
|
|
1463
|
+
const COMPONENT_NAME$26 = 'vc-artboard';
|
|
1464
1464
|
const Artboard = /* @__PURE__ */ vue.defineComponent({
|
|
1465
|
-
name: COMPONENT_NAME$
|
|
1466
|
-
props: props$
|
|
1465
|
+
name: COMPONENT_NAME$26,
|
|
1466
|
+
props: props$1q,
|
|
1467
1467
|
setup(props, {
|
|
1468
1468
|
emit,
|
|
1469
1469
|
expose
|
|
@@ -1666,7 +1666,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
1666
1666
|
|
|
1667
1667
|
const MArtboard = Artboard;
|
|
1668
1668
|
|
|
1669
|
-
const props$
|
|
1669
|
+
const props$1p = {
|
|
1670
1670
|
size: {
|
|
1671
1671
|
type: Number,
|
|
1672
1672
|
default: 28
|
|
@@ -1690,10 +1690,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
1690
1690
|
|
|
1691
1691
|
/** @jsxImportSource vue */
|
|
1692
1692
|
|
|
1693
|
-
const COMPONENT_NAME$
|
|
1693
|
+
const COMPONENT_NAME$25 = 'vc-spin';
|
|
1694
1694
|
const Spin = /* @__PURE__ */ vue.defineComponent({
|
|
1695
|
-
name: COMPONENT_NAME$
|
|
1696
|
-
props: props$
|
|
1695
|
+
name: COMPONENT_NAME$25,
|
|
1696
|
+
props: props$1p,
|
|
1697
1697
|
setup(props, {
|
|
1698
1698
|
slots
|
|
1699
1699
|
}) {
|
|
@@ -6765,7 +6765,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
6765
6765
|
});
|
|
6766
6766
|
}
|
|
6767
6767
|
|
|
6768
|
-
const props$
|
|
6768
|
+
const props$1o = {
|
|
6769
6769
|
wait: {
|
|
6770
6770
|
type: Number,
|
|
6771
6771
|
default: 250
|
|
@@ -6781,10 +6781,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
6781
6781
|
exclude: RegExp
|
|
6782
6782
|
};
|
|
6783
6783
|
|
|
6784
|
-
const COMPONENT_NAME$
|
|
6784
|
+
const COMPONENT_NAME$24 = "vc-debounce";
|
|
6785
6785
|
const Debounce = vue.defineComponent({
|
|
6786
|
-
name: COMPONENT_NAME$
|
|
6787
|
-
props: props$
|
|
6786
|
+
name: COMPONENT_NAME$24,
|
|
6787
|
+
props: props$1o,
|
|
6788
6788
|
/**
|
|
6789
6789
|
* 不声明emits使得事件被透传放入attrs中, 这样可以让所有的事件透传
|
|
6790
6790
|
* 如事件onClick
|
|
@@ -6824,7 +6824,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
6824
6824
|
}
|
|
6825
6825
|
});
|
|
6826
6826
|
|
|
6827
|
-
const props$
|
|
6827
|
+
const props$1n = {
|
|
6828
6828
|
tag: {
|
|
6829
6829
|
type: String,
|
|
6830
6830
|
default: "button"
|
|
@@ -6856,11 +6856,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
6856
6856
|
|
|
6857
6857
|
/** @jsxImportSource vue */
|
|
6858
6858
|
|
|
6859
|
-
const COMPONENT_NAME$
|
|
6859
|
+
const COMPONENT_NAME$23 = 'vc-button';
|
|
6860
6860
|
const Button = /* @__PURE__ */ vue.defineComponent({
|
|
6861
|
-
name: COMPONENT_NAME$
|
|
6861
|
+
name: COMPONENT_NAME$23,
|
|
6862
6862
|
emits: ['click'],
|
|
6863
|
-
props: props$
|
|
6863
|
+
props: props$1n,
|
|
6864
6864
|
setup(props, {
|
|
6865
6865
|
slots
|
|
6866
6866
|
}) {
|
|
@@ -6921,7 +6921,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
6921
6921
|
}
|
|
6922
6922
|
});
|
|
6923
6923
|
|
|
6924
|
-
const props$
|
|
6924
|
+
const props$1m = {
|
|
6925
6925
|
vertical: {
|
|
6926
6926
|
type: Boolean,
|
|
6927
6927
|
default: false
|
|
@@ -6942,10 +6942,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
6942
6942
|
|
|
6943
6943
|
/** @jsxImportSource vue */
|
|
6944
6944
|
|
|
6945
|
-
const COMPONENT_NAME$
|
|
6945
|
+
const COMPONENT_NAME$22 = 'vc-button-group';
|
|
6946
6946
|
const ButtonGroup = /* @__PURE__ */ vue.defineComponent({
|
|
6947
|
-
name: COMPONENT_NAME$
|
|
6948
|
-
props: props$
|
|
6947
|
+
name: COMPONENT_NAME$22,
|
|
6948
|
+
props: props$1m,
|
|
6949
6949
|
setup(props, {
|
|
6950
6950
|
slots
|
|
6951
6951
|
}) {
|
|
@@ -6969,7 +6969,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
6969
6969
|
const MButton = Button;
|
|
6970
6970
|
const MButtonGroup = ButtonGroup;
|
|
6971
6971
|
|
|
6972
|
-
const props$
|
|
6972
|
+
const props$1l = {
|
|
6973
6973
|
tag: {
|
|
6974
6974
|
type: String,
|
|
6975
6975
|
default: "div"
|
|
@@ -6978,10 +6978,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
6978
6978
|
|
|
6979
6979
|
/** @jsxImportSource vue */
|
|
6980
6980
|
|
|
6981
|
-
const COMPONENT_NAME$
|
|
6981
|
+
const COMPONENT_NAME$21 = 'vc-calendar';
|
|
6982
6982
|
const Calendar$1 = /* @__PURE__ */ vue.defineComponent({
|
|
6983
|
-
name: COMPONENT_NAME$
|
|
6984
|
-
props: props$
|
|
6983
|
+
name: COMPONENT_NAME$21,
|
|
6984
|
+
props: props$1l,
|
|
6985
6985
|
setup(props, {
|
|
6986
6986
|
slots
|
|
6987
6987
|
}) {
|
|
@@ -6995,7 +6995,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
6995
6995
|
|
|
6996
6996
|
const MCalendar = Calendar$1;
|
|
6997
6997
|
|
|
6998
|
-
const props$
|
|
6998
|
+
const props$1k = {
|
|
6999
6999
|
border: {
|
|
7000
7000
|
type: Boolean,
|
|
7001
7001
|
default: true
|
|
@@ -7018,10 +7018,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
7018
7018
|
|
|
7019
7019
|
/** @jsxImportSource vue */
|
|
7020
7020
|
|
|
7021
|
-
const COMPONENT_NAME$
|
|
7021
|
+
const COMPONENT_NAME$20 = 'vc-card';
|
|
7022
7022
|
const Card = /* @__PURE__ */ vue.defineComponent({
|
|
7023
|
-
name: COMPONENT_NAME$
|
|
7024
|
-
props: props$
|
|
7023
|
+
name: COMPONENT_NAME$20,
|
|
7024
|
+
props: props$1k,
|
|
7025
7025
|
setup(props, {
|
|
7026
7026
|
slots
|
|
7027
7027
|
}) {
|
|
@@ -7047,31 +7047,776 @@ var VcComponents = (function (exports, vue) {
|
|
|
7047
7047
|
|
|
7048
7048
|
const MCard = Card;
|
|
7049
7049
|
|
|
7050
|
-
|
|
7051
|
-
|
|
7050
|
+
class Resize {
|
|
7051
|
+
el;
|
|
7052
|
+
static of(el) {
|
|
7053
|
+
return new Resize(el);
|
|
7054
|
+
}
|
|
7055
|
+
/**
|
|
7056
|
+
* Resize.of(el, fn);
|
|
7057
|
+
* @param el ~
|
|
7058
|
+
* @param fn ~
|
|
7059
|
+
* @returns off
|
|
7060
|
+
*/
|
|
7061
|
+
static on(el, fn) {
|
|
7062
|
+
return new Resize(el).on(fn);
|
|
7063
|
+
}
|
|
7064
|
+
/**
|
|
7065
|
+
* 要实现Resize.off(el),el必须侵入式修改挂上__rz__
|
|
7066
|
+
* @param el ~
|
|
7067
|
+
* @param fn ~
|
|
7068
|
+
* @returns ~
|
|
7069
|
+
*/
|
|
7070
|
+
static off(el, fn) {
|
|
7071
|
+
return new Resize(el).off(fn);
|
|
7072
|
+
}
|
|
7073
|
+
listeners = [];
|
|
7074
|
+
ro = null;
|
|
7075
|
+
constructor(el) {
|
|
7076
|
+
this.el = el;
|
|
7077
|
+
let rz = el.__rz__;
|
|
7078
|
+
if (rz && rz instanceof Resize) {
|
|
7079
|
+
this.listeners = rz.listeners;
|
|
7080
|
+
this.ro = rz.ro;
|
|
7081
|
+
}
|
|
7082
|
+
}
|
|
7083
|
+
handleResize = (entries) => {
|
|
7084
|
+
/* istanbul ignore else -- @preserve */
|
|
7085
|
+
if (entries.some((i) => i.target === this.el)) {
|
|
7086
|
+
this.listeners?.forEach((fn) => fn());
|
|
7087
|
+
}
|
|
7088
|
+
};
|
|
7089
|
+
on(fn) {
|
|
7090
|
+
if (typeof ResizeObserver === "undefined")
|
|
7091
|
+
return () => {
|
|
7092
|
+
};
|
|
7093
|
+
if (!this.listeners.length) {
|
|
7094
|
+
this.ro = this.ro || new ResizeObserver(this.handleResize);
|
|
7095
|
+
this.ro.observe(this.el);
|
|
7096
|
+
this.el.__rz__ = this;
|
|
7097
|
+
}
|
|
7098
|
+
this.listeners.push(fn);
|
|
7099
|
+
return () => this.off(fn);
|
|
7100
|
+
}
|
|
7101
|
+
off(fn) {
|
|
7102
|
+
if (fn) {
|
|
7103
|
+
this.listeners.splice(this.listeners.indexOf(fn), 1);
|
|
7104
|
+
} else {
|
|
7105
|
+
this.listeners = [];
|
|
7106
|
+
}
|
|
7107
|
+
if (!this.listeners.length && this.ro) {
|
|
7108
|
+
this.ro.disconnect();
|
|
7109
|
+
}
|
|
7110
|
+
}
|
|
7111
|
+
}
|
|
7112
|
+
|
|
7113
|
+
const useCarousel = (wrapper, content, expose) => {
|
|
7114
|
+
const instance = vue.getCurrentInstance();
|
|
7115
|
+
const props = instance.props;
|
|
7116
|
+
const { emit } = instance;
|
|
7117
|
+
const items = vue.ref([]);
|
|
7118
|
+
const activeIndex = vue.ref(-1);
|
|
7119
|
+
const timer = vue.ref(null);
|
|
7120
|
+
const offset = vue.ref(0);
|
|
7121
|
+
const carouselId = vue.ref(getUid("carousel"));
|
|
7122
|
+
const start = vue.ref();
|
|
7123
|
+
const startX = vue.ref();
|
|
7124
|
+
const startY = vue.ref();
|
|
7125
|
+
const allowTransition = vue.ref(false);
|
|
7126
|
+
const direction = vue.computed(() => {
|
|
7127
|
+
return props.vertical ? "vertical" : "horizontal";
|
|
7128
|
+
});
|
|
7129
|
+
const hasLabel = vue.computed(() => {
|
|
7130
|
+
return items.value.some((item) => item.props.label.toString().length > 0);
|
|
7131
|
+
});
|
|
7132
|
+
const dotsClasses = vue.computed(() => {
|
|
7133
|
+
const classes = ["is-" + direction.value];
|
|
7134
|
+
if (hasLabel.value) {
|
|
7135
|
+
classes.push("is-labels");
|
|
7136
|
+
}
|
|
7137
|
+
if (props.dots === "outside" || props.card) {
|
|
7138
|
+
classes.push("is-outside");
|
|
7139
|
+
}
|
|
7140
|
+
return classes;
|
|
7141
|
+
});
|
|
7142
|
+
const resetItems = (oldIndex) => {
|
|
7143
|
+
items.value.forEach((item, index) => {
|
|
7144
|
+
item.exposed?.reset?.(index, activeIndex.value, oldIndex);
|
|
7145
|
+
});
|
|
7146
|
+
};
|
|
7147
|
+
const playSlides = () => {
|
|
7148
|
+
allowTransition.value = true;
|
|
7149
|
+
if (activeIndex.value < items.value.length - 1) {
|
|
7150
|
+
activeIndex.value++;
|
|
7151
|
+
} else if (props.loop) {
|
|
7152
|
+
activeIndex.value = 0;
|
|
7153
|
+
}
|
|
7154
|
+
};
|
|
7155
|
+
const pauseTimer = () => {
|
|
7156
|
+
if (timer.value) {
|
|
7157
|
+
clearInterval(timer.value);
|
|
7158
|
+
timer.value = null;
|
|
7159
|
+
}
|
|
7160
|
+
};
|
|
7161
|
+
const startTimer = () => {
|
|
7162
|
+
if (props.t <= 0 || !props.autoplay || timer.value) return;
|
|
7163
|
+
timer.value = setInterval(playSlides, props.t);
|
|
7164
|
+
};
|
|
7165
|
+
const setActiveItem = (index) => {
|
|
7166
|
+
if (typeof index === "string") {
|
|
7167
|
+
const filteredItems = items.value.filter((item) => item.props.name === index);
|
|
7168
|
+
if (filteredItems.length > 0) {
|
|
7169
|
+
index = items.value.indexOf(filteredItems[0]);
|
|
7170
|
+
}
|
|
7171
|
+
}
|
|
7172
|
+
index = Number(index);
|
|
7173
|
+
if (isNaN(index) || index !== Math.floor(index)) {
|
|
7174
|
+
throw new VcError("carousel", "索引必须是整数");
|
|
7175
|
+
}
|
|
7176
|
+
const length = items.value.length;
|
|
7177
|
+
const oldIndex = activeIndex.value;
|
|
7178
|
+
if (index < 0) {
|
|
7179
|
+
activeIndex.value = props.loop ? length - 1 : 0;
|
|
7180
|
+
} else if (index >= length) {
|
|
7181
|
+
activeIndex.value = props.loop ? 0 : length - 1;
|
|
7182
|
+
} else {
|
|
7183
|
+
activeIndex.value = index;
|
|
7184
|
+
}
|
|
7185
|
+
if (oldIndex === activeIndex.value) {
|
|
7186
|
+
resetItems(oldIndex);
|
|
7187
|
+
}
|
|
7188
|
+
};
|
|
7189
|
+
const prev = () => {
|
|
7190
|
+
setActiveItem(activeIndex.value - 1);
|
|
7191
|
+
};
|
|
7192
|
+
const next = () => {
|
|
7193
|
+
setActiveItem(activeIndex.value + 1);
|
|
7194
|
+
};
|
|
7195
|
+
const handleDotClick = (index) => {
|
|
7196
|
+
activeIndex.value = index;
|
|
7197
|
+
};
|
|
7198
|
+
const handleStart = (e) => {
|
|
7199
|
+
allowTransition.value = true;
|
|
7200
|
+
if (!props.draggable) return;
|
|
7201
|
+
pauseTimer();
|
|
7202
|
+
start.value = true;
|
|
7203
|
+
startX.value = e.screenX;
|
|
7204
|
+
startY.value = e.screenY;
|
|
7205
|
+
};
|
|
7206
|
+
const handleMove = (e) => {
|
|
7207
|
+
if (!start.value || !props.draggable) return;
|
|
7208
|
+
offset.value = !props.vertical ? e.screenX - startX.value : e.screenY - startY.value;
|
|
7209
|
+
resetItems();
|
|
7210
|
+
};
|
|
7211
|
+
const handleEnd = () => {
|
|
7212
|
+
if (!props.draggable) return;
|
|
7213
|
+
start.value = false;
|
|
7214
|
+
startTimer();
|
|
7215
|
+
const $offset = Math.abs(offset.value);
|
|
7216
|
+
const $direction = offset.value > 0;
|
|
7217
|
+
offset.value = 0;
|
|
7218
|
+
if ($offset > 5) {
|
|
7219
|
+
$direction && prev();
|
|
7220
|
+
!$direction && next();
|
|
7221
|
+
} else {
|
|
7222
|
+
resetItems();
|
|
7223
|
+
}
|
|
7224
|
+
};
|
|
7225
|
+
vue.watch(
|
|
7226
|
+
() => items.value,
|
|
7227
|
+
(v) => {
|
|
7228
|
+
if (v.length > 0) setActiveItem(props.initialIndex);
|
|
7229
|
+
}
|
|
7230
|
+
);
|
|
7231
|
+
vue.watch(
|
|
7232
|
+
() => activeIndex.value,
|
|
7233
|
+
(v, oldV) => {
|
|
7234
|
+
resetItems(oldV);
|
|
7235
|
+
emit("change", v, oldV);
|
|
7236
|
+
}
|
|
7237
|
+
);
|
|
7238
|
+
vue.watch(
|
|
7239
|
+
() => props.autoplay,
|
|
7240
|
+
(v) => {
|
|
7241
|
+
v ? startTimer() : pauseTimer();
|
|
7242
|
+
}
|
|
7243
|
+
);
|
|
7244
|
+
vue.watch(
|
|
7245
|
+
() => props.loop,
|
|
7246
|
+
() => {
|
|
7247
|
+
setActiveItem(activeIndex.value);
|
|
7248
|
+
}
|
|
7249
|
+
);
|
|
7250
|
+
vue.watch(
|
|
7251
|
+
() => props.t,
|
|
7252
|
+
() => {
|
|
7253
|
+
pauseTimer();
|
|
7254
|
+
startTimer();
|
|
7255
|
+
}
|
|
7256
|
+
);
|
|
7257
|
+
vue.onMounted(() => {
|
|
7258
|
+
vue.nextTick(() => {
|
|
7259
|
+
if (wrapper.value) Resize.on(wrapper.value, resetItems);
|
|
7260
|
+
if (props.initialIndex < items.value.length && props.initialIndex >= 0) {
|
|
7261
|
+
activeIndex.value = props.initialIndex;
|
|
7262
|
+
}
|
|
7263
|
+
startTimer();
|
|
7264
|
+
});
|
|
7265
|
+
});
|
|
7266
|
+
vue.onBeforeUnmount(() => {
|
|
7267
|
+
if (wrapper.value) Resize.off(wrapper.value, resetItems);
|
|
7268
|
+
pauseTimer();
|
|
7269
|
+
startTimer();
|
|
7270
|
+
});
|
|
7271
|
+
const add = (item) => {
|
|
7272
|
+
if (!item) return;
|
|
7273
|
+
vue.nextTick(() => {
|
|
7274
|
+
if (content.value) {
|
|
7275
|
+
const index = Array.from(content.value.children).filter((i) => /vcm?-carousel-item/.test(i.className)).indexOf(item.vnode.el);
|
|
7276
|
+
items.value.splice(index, 0, item);
|
|
7277
|
+
return;
|
|
7278
|
+
}
|
|
7279
|
+
items.value.push(item);
|
|
7280
|
+
});
|
|
7281
|
+
};
|
|
7282
|
+
const remove = (item) => {
|
|
7283
|
+
if (!item) return;
|
|
7284
|
+
items.value.splice(items.value.indexOf(item), 1);
|
|
7285
|
+
};
|
|
7286
|
+
vue.provide("vc-carousel", {
|
|
7287
|
+
props,
|
|
7288
|
+
items,
|
|
7289
|
+
offset,
|
|
7290
|
+
allowTransition,
|
|
7291
|
+
setActiveItem,
|
|
7292
|
+
wrapper,
|
|
7293
|
+
content,
|
|
7294
|
+
add,
|
|
7295
|
+
remove
|
|
7296
|
+
});
|
|
7297
|
+
expose({
|
|
7298
|
+
setActiveItem,
|
|
7299
|
+
prev,
|
|
7300
|
+
next
|
|
7301
|
+
});
|
|
7302
|
+
return {
|
|
7303
|
+
carouselId,
|
|
7304
|
+
allowTransition,
|
|
7305
|
+
items,
|
|
7306
|
+
activeIndex,
|
|
7307
|
+
offset,
|
|
7308
|
+
direction,
|
|
7309
|
+
hasLabel,
|
|
7310
|
+
dotsClasses,
|
|
7311
|
+
start,
|
|
7312
|
+
startX,
|
|
7313
|
+
startY,
|
|
7314
|
+
handleStart,
|
|
7315
|
+
handleMove,
|
|
7316
|
+
handleEnd,
|
|
7317
|
+
handleDotClick,
|
|
7318
|
+
prev,
|
|
7319
|
+
next,
|
|
7320
|
+
setActiveItem,
|
|
7321
|
+
pauseTimer,
|
|
7322
|
+
startTimer
|
|
7323
|
+
};
|
|
7324
|
+
};
|
|
7325
|
+
|
|
7326
|
+
const props$1j = {
|
|
7327
|
+
t: {
|
|
7328
|
+
type: Number,
|
|
7329
|
+
default: 3e3
|
|
7330
|
+
},
|
|
7331
|
+
card: Boolean,
|
|
7332
|
+
gutter: {
|
|
7333
|
+
type: Number,
|
|
7334
|
+
default: 0
|
|
7335
|
+
},
|
|
7336
|
+
height: [String, Number],
|
|
7337
|
+
initialIndex: {
|
|
7338
|
+
type: Number,
|
|
7339
|
+
default: 0
|
|
7340
|
+
},
|
|
7341
|
+
trigger: {
|
|
7052
7342
|
type: String,
|
|
7053
|
-
default: "
|
|
7343
|
+
default: "hover"
|
|
7344
|
+
},
|
|
7345
|
+
autoplay: {
|
|
7346
|
+
type: Boolean,
|
|
7347
|
+
default: true
|
|
7348
|
+
},
|
|
7349
|
+
dots: {
|
|
7350
|
+
type: [String, Boolean],
|
|
7351
|
+
default: "bottom"
|
|
7352
|
+
// bottom/outside | false
|
|
7353
|
+
},
|
|
7354
|
+
arrow: {
|
|
7355
|
+
type: [String, Boolean],
|
|
7356
|
+
default: "hover"
|
|
7357
|
+
// hover/always | false
|
|
7358
|
+
},
|
|
7359
|
+
loop: {
|
|
7360
|
+
type: Boolean,
|
|
7361
|
+
default: true
|
|
7362
|
+
},
|
|
7363
|
+
vertical: {
|
|
7364
|
+
type: Boolean,
|
|
7365
|
+
default: false
|
|
7366
|
+
},
|
|
7367
|
+
draggable: {
|
|
7368
|
+
type: Boolean,
|
|
7369
|
+
default: true
|
|
7054
7370
|
}
|
|
7055
7371
|
};
|
|
7056
7372
|
|
|
7057
7373
|
/** @jsxImportSource vue */
|
|
7058
7374
|
|
|
7059
|
-
const COMPONENT_NAME$
|
|
7375
|
+
const COMPONENT_NAME$1$ = 'vc-carousel';
|
|
7060
7376
|
const Carousel = /* @__PURE__ */ vue.defineComponent({
|
|
7061
|
-
name: COMPONENT_NAME$
|
|
7377
|
+
name: COMPONENT_NAME$1$,
|
|
7378
|
+
props: props$1j,
|
|
7379
|
+
setup(props, {
|
|
7380
|
+
slots,
|
|
7381
|
+
expose
|
|
7382
|
+
}) {
|
|
7383
|
+
const isHover = vue.ref(false);
|
|
7384
|
+
const wrapper = vue.ref(null);
|
|
7385
|
+
const content = vue.ref(null);
|
|
7386
|
+
const arrowDisplay = vue.computed(() => {
|
|
7387
|
+
return props.arrow && !props.vertical;
|
|
7388
|
+
});
|
|
7389
|
+
const carousel = useCarousel(wrapper, content, expose);
|
|
7390
|
+
const itemInStage = (item, index, items) => {
|
|
7391
|
+
const length = items.length;
|
|
7392
|
+
const isInStage = item.exposed.isInStage.value;
|
|
7393
|
+
if (index === length - 1 && isInStage && items[0].exposed.isActive.value || isInStage && items[index + 1] && items[index + 1].exposed.isActive.value) {
|
|
7394
|
+
return 'left';
|
|
7395
|
+
} else if (index === 0 && isInStage && items[length - 1].exposed.isActive.value || isInStage && items[index - 1] && items[index - 1].exposed.isActive.value) {
|
|
7396
|
+
return 'right';
|
|
7397
|
+
}
|
|
7398
|
+
return false;
|
|
7399
|
+
};
|
|
7400
|
+
const handleButtonEnter = arrow => {
|
|
7401
|
+
if (props.vertical) return;
|
|
7402
|
+
carousel.items.value.forEach((item, index, items) => {
|
|
7403
|
+
if (arrow === itemInStage(item, index, items)) {
|
|
7404
|
+
item.exposed.isHover.value = true;
|
|
7405
|
+
}
|
|
7406
|
+
});
|
|
7407
|
+
};
|
|
7408
|
+
const handleButtonLeave = () => {
|
|
7409
|
+
if (props.vertical) return;
|
|
7410
|
+
carousel.items.value.forEach(item => {
|
|
7411
|
+
item.exposed.isHover.value = false;
|
|
7412
|
+
});
|
|
7413
|
+
};
|
|
7414
|
+
const handleDotHover = index => {
|
|
7415
|
+
if (props.trigger === 'hover' && index !== carousel.activeIndex.value) {
|
|
7416
|
+
carousel.activeIndex.value = index;
|
|
7417
|
+
}
|
|
7418
|
+
};
|
|
7419
|
+
const handleMouseEnter = () => {
|
|
7420
|
+
isHover.value = true;
|
|
7421
|
+
carousel.pauseTimer();
|
|
7422
|
+
};
|
|
7423
|
+
const handleMouseLeave = () => {
|
|
7424
|
+
isHover.value = false;
|
|
7425
|
+
carousel.startTimer();
|
|
7426
|
+
};
|
|
7427
|
+
const throttledArrowClick = throttle$1(carousel.setActiveItem);
|
|
7428
|
+
const throttledDotHover = throttle$1(handleDotHover);
|
|
7429
|
+
return () => {
|
|
7430
|
+
return vue.createVNode("div", {
|
|
7431
|
+
"ref": wrapper,
|
|
7432
|
+
"class": ['vc-carousel', `is-${carousel.direction.value}`],
|
|
7433
|
+
"onMousedown": vue.withModifiers(carousel.handleStart, ['stop', 'prevent']),
|
|
7434
|
+
"onMousemove": vue.withModifiers(carousel.handleMove, ['stop', 'prevent']),
|
|
7435
|
+
"onMouseup": vue.withModifiers(carousel.handleEnd, ['stop', 'prevent']),
|
|
7436
|
+
"onMouseenter": vue.withModifiers(handleMouseEnter, ['stop']),
|
|
7437
|
+
"onMouseleave": vue.withModifiers(handleMouseLeave, ['stop'])
|
|
7438
|
+
}, [vue.createVNode("div", {
|
|
7439
|
+
"ref": content,
|
|
7440
|
+
"class": "vc-carousel__wrapper",
|
|
7441
|
+
"style": {
|
|
7442
|
+
height: props.height ? `${props.height}px` : 'auto'
|
|
7443
|
+
}
|
|
7444
|
+
}, [arrowDisplay.value && vue.createVNode(TransitionSlide, {
|
|
7445
|
+
"mode": "left-part"
|
|
7446
|
+
}, {
|
|
7447
|
+
default: () => [vue.withDirectives(vue.createVNode("button", {
|
|
7448
|
+
"type": "button",
|
|
7449
|
+
"class": "vc-carousel__arrow is-left-arrow",
|
|
7450
|
+
"onMouseenter": () => handleButtonEnter('left'),
|
|
7451
|
+
"onMouseleave": handleButtonLeave,
|
|
7452
|
+
"onClick": vue.withModifiers(() => throttledArrowClick(carousel.activeIndex.value - 1), ['stop'])
|
|
7453
|
+
}, [vue.createVNode(Icon, {
|
|
7454
|
+
"type": "left"
|
|
7455
|
+
}, null)]), [[vue.vShow, (props.arrow === 'always' || isHover.value) && (props.loop || carousel.activeIndex.value > 0)]])]
|
|
7456
|
+
}), arrowDisplay.value && vue.createVNode(TransitionSlide, {
|
|
7457
|
+
"mode": "right-part"
|
|
7458
|
+
}, {
|
|
7459
|
+
default: () => [vue.withDirectives(vue.createVNode("button", {
|
|
7460
|
+
"type": "button",
|
|
7461
|
+
"class": "vc-carousel__arrow is-right-arrow",
|
|
7462
|
+
"onMouseenter": () => handleButtonEnter('right'),
|
|
7463
|
+
"onMouseleave": handleButtonLeave,
|
|
7464
|
+
"onClick": vue.withModifiers(() => throttledArrowClick(carousel.activeIndex.value + 1), ['stop'])
|
|
7465
|
+
}, [vue.createVNode(Icon, {
|
|
7466
|
+
"type": "right"
|
|
7467
|
+
}, null)]), [[vue.vShow, (props.arrow === 'always' || isHover.value) && (props.loop || carousel.activeIndex.value < carousel.items.value.length - 1)]])]
|
|
7468
|
+
}), slots.default?.()]), props.dots && vue.createVNode("ul", {
|
|
7469
|
+
"class": ['vc-carousel__dots', ...carousel.dotsClasses.value]
|
|
7470
|
+
}, [carousel.items.value.map((item, index) => vue.createVNode("li", {
|
|
7471
|
+
"key": index,
|
|
7472
|
+
"class": ['vc-carousel__dot', `is-${carousel.direction.value}`, {
|
|
7473
|
+
'is-active': index === carousel.activeIndex.value
|
|
7474
|
+
}],
|
|
7475
|
+
"onMouseenter": () => throttledDotHover(index),
|
|
7476
|
+
"onClick": () => carousel.handleDotClick(index)
|
|
7477
|
+
}, [vue.createVNode("button", {
|
|
7478
|
+
"class": "vc-carousel__button"
|
|
7479
|
+
}, [carousel.hasLabel.value && vue.createVNode("span", null, [item.props.label])])]))])]);
|
|
7480
|
+
};
|
|
7481
|
+
}
|
|
7482
|
+
});
|
|
7483
|
+
|
|
7484
|
+
const props$1i = {
|
|
7485
|
+
name: String,
|
|
7486
|
+
label: {
|
|
7487
|
+
type: [String, Number],
|
|
7488
|
+
default: ""
|
|
7489
|
+
},
|
|
7490
|
+
// card大小
|
|
7491
|
+
width: {
|
|
7492
|
+
type: [Number, String],
|
|
7493
|
+
default: "70%"
|
|
7494
|
+
},
|
|
7495
|
+
// card之间间距, 或者滑动时候的间距
|
|
7496
|
+
gutter: {
|
|
7497
|
+
type: Number,
|
|
7498
|
+
default: 0
|
|
7499
|
+
},
|
|
7500
|
+
scale: {
|
|
7501
|
+
type: Number,
|
|
7502
|
+
default: 0.83
|
|
7503
|
+
}
|
|
7504
|
+
};
|
|
7505
|
+
|
|
7506
|
+
const TRANSFORM = prefixStyle("transform").camel;
|
|
7507
|
+
const useCarouselItem = (expose) => {
|
|
7508
|
+
const instance = vue.getCurrentInstance();
|
|
7509
|
+
const carousel = vue.inject("vc-carousel", {});
|
|
7510
|
+
const props = instance.props;
|
|
7511
|
+
const translate = vue.ref(0);
|
|
7512
|
+
const currentScale = vue.ref(1);
|
|
7513
|
+
const isHover = vue.ref(false);
|
|
7514
|
+
const isActive = vue.ref(false);
|
|
7515
|
+
const isReady = vue.ref(false);
|
|
7516
|
+
const isInStage = vue.ref(false);
|
|
7517
|
+
const isAnimating = vue.ref(false);
|
|
7518
|
+
const isVertical = vue.computed(() => {
|
|
7519
|
+
return carousel.props.vertical;
|
|
7520
|
+
});
|
|
7521
|
+
const isCard = vue.computed(() => {
|
|
7522
|
+
return carousel.props.card;
|
|
7523
|
+
});
|
|
7524
|
+
const isMove = vue.computed(() => {
|
|
7525
|
+
return carousel.offset.value !== 0;
|
|
7526
|
+
});
|
|
7527
|
+
const itemGutter = vue.computed(() => {
|
|
7528
|
+
return props.gutter || carousel.props.gutter || 0;
|
|
7529
|
+
});
|
|
7530
|
+
const itemStyle = vue.computed(() => {
|
|
7531
|
+
const translateType = isVertical.value ? "translateY" : "translateX";
|
|
7532
|
+
if (carousel.props.card) {
|
|
7533
|
+
return {
|
|
7534
|
+
[TRANSFORM]: `${translateType}(${translate.value}px) scale(${currentScale.value})`,
|
|
7535
|
+
width: props.width
|
|
7536
|
+
};
|
|
7537
|
+
} else {
|
|
7538
|
+
return {
|
|
7539
|
+
[TRANSFORM]: `${translateType}(${translate.value}px) scale(${currentScale.value})`,
|
|
7540
|
+
width: itemGutter.value ? props.width : "100%"
|
|
7541
|
+
};
|
|
7542
|
+
}
|
|
7543
|
+
});
|
|
7544
|
+
vue.onBeforeMount(() => {
|
|
7545
|
+
carousel.add?.(instance);
|
|
7546
|
+
if (!isCard.value && itemGutter.value && carousel.props.loop) {
|
|
7547
|
+
throw new VcError("carousel", "slide模式下loop不能为true");
|
|
7548
|
+
}
|
|
7549
|
+
});
|
|
7550
|
+
vue.onBeforeUnmount(() => {
|
|
7551
|
+
carousel.remove?.(instance);
|
|
7552
|
+
});
|
|
7553
|
+
const processIndex = (index, activeIndex, length) => {
|
|
7554
|
+
if (activeIndex === 0 && index === length - 1) {
|
|
7555
|
+
return -1;
|
|
7556
|
+
} else if (activeIndex === length - 1 && index === 0) {
|
|
7557
|
+
return length;
|
|
7558
|
+
} else if (index < activeIndex - 1 && activeIndex - index >= length / 2) {
|
|
7559
|
+
return length + 1;
|
|
7560
|
+
} else if (index > activeIndex + 1 && index - activeIndex >= length / 2) {
|
|
7561
|
+
return -2;
|
|
7562
|
+
}
|
|
7563
|
+
return index;
|
|
7564
|
+
};
|
|
7565
|
+
const calcCardTranslate = (index, activeIndex) => {
|
|
7566
|
+
let value;
|
|
7567
|
+
const widthNumber = +props.width / 100;
|
|
7568
|
+
const parentW = carousel.wrapper.value.offsetWidth;
|
|
7569
|
+
if (isInStage.value) {
|
|
7570
|
+
if (index === activeIndex) {
|
|
7571
|
+
value = parentW * (1 - widthNumber) / 2;
|
|
7572
|
+
} else if (index > activeIndex) {
|
|
7573
|
+
value = parentW * (1 + widthNumber * props.scale) / 2 + itemGutter.value;
|
|
7574
|
+
} else {
|
|
7575
|
+
value = -(parentW * ((widthNumber * props.scale - 1) / 2 + widthNumber)) - itemGutter.value;
|
|
7576
|
+
}
|
|
7577
|
+
} else if (index < activeIndex) {
|
|
7578
|
+
value = parentW * (1 - widthNumber) / 2;
|
|
7579
|
+
} else {
|
|
7580
|
+
value = parentW * (1 - widthNumber) / 2;
|
|
7581
|
+
}
|
|
7582
|
+
return value;
|
|
7583
|
+
};
|
|
7584
|
+
const calcSlideOffset = (index, activeIndex, wrapperWidth) => {
|
|
7585
|
+
const { length } = carousel.items.value;
|
|
7586
|
+
const offset = wrapperWidth - (instance.vnode?.el?.offsetWidth || 0);
|
|
7587
|
+
const gutter = itemGutter.value;
|
|
7588
|
+
if (!gutter || isVertical.value) return 0;
|
|
7589
|
+
let slideOffset = 0;
|
|
7590
|
+
if (length === 1) {
|
|
7591
|
+
return offset / 2;
|
|
7592
|
+
}
|
|
7593
|
+
if (activeIndex == 0) {
|
|
7594
|
+
if (index - activeIndex === 0) {
|
|
7595
|
+
slideOffset = gutter;
|
|
7596
|
+
} else if (index - activeIndex === 1) {
|
|
7597
|
+
slideOffset = -offset + gutter * 2;
|
|
7598
|
+
}
|
|
7599
|
+
}
|
|
7600
|
+
if (activeIndex !== 0 && activeIndex != length - 1) {
|
|
7601
|
+
if (index - activeIndex === 0) {
|
|
7602
|
+
slideOffset = offset / 2;
|
|
7603
|
+
} else if (index - activeIndex === 1) {
|
|
7604
|
+
slideOffset = -offset / 2 + gutter;
|
|
7605
|
+
} else if (index - activeIndex === -1) {
|
|
7606
|
+
slideOffset = offset * 3 / 2 - gutter;
|
|
7607
|
+
}
|
|
7608
|
+
}
|
|
7609
|
+
if (activeIndex == length - 1) {
|
|
7610
|
+
if (index - activeIndex === 0) {
|
|
7611
|
+
slideOffset = offset - gutter;
|
|
7612
|
+
} else if (index - activeIndex === -1) {
|
|
7613
|
+
slideOffset = offset * 2 - gutter * 2;
|
|
7614
|
+
}
|
|
7615
|
+
}
|
|
7616
|
+
return slideOffset;
|
|
7617
|
+
};
|
|
7618
|
+
const calcTranslate = (index, activeIndex) => {
|
|
7619
|
+
const distance = carousel.vnode.el[isVertical.value ? "offsetHeight" : "offsetWidth"];
|
|
7620
|
+
const slideOffset = calcSlideOffset(index, activeIndex, distance);
|
|
7621
|
+
return distance * (index - activeIndex) + carousel.offset.value + slideOffset;
|
|
7622
|
+
};
|
|
7623
|
+
const reset = (index, activeIndex, oldIndex) => {
|
|
7624
|
+
const { length } = carousel.items.value;
|
|
7625
|
+
if (carousel.allowTransition.value && !isCard.value && oldIndex !== void 0) {
|
|
7626
|
+
isAnimating.value = index === activeIndex || index === oldIndex;
|
|
7627
|
+
if (!isVertical.value && !isAnimating.value && itemGutter.value && (index - activeIndex === 1 || index - activeIndex === -1)) {
|
|
7628
|
+
isAnimating.value = true;
|
|
7629
|
+
}
|
|
7630
|
+
}
|
|
7631
|
+
if (index !== activeIndex && length > 2 && carousel.props.loop) {
|
|
7632
|
+
index = processIndex(index, activeIndex, length);
|
|
7633
|
+
}
|
|
7634
|
+
if (isCard.value) {
|
|
7635
|
+
if (isVertical.value) {
|
|
7636
|
+
throw new VcError("carousel", "卡片模式不支持垂直方向");
|
|
7637
|
+
}
|
|
7638
|
+
isInStage.value = Math.round(Math.abs(index - activeIndex)) <= 1;
|
|
7639
|
+
isActive.value = index === activeIndex;
|
|
7640
|
+
translate.value = calcCardTranslate(index, activeIndex);
|
|
7641
|
+
currentScale.value = isActive.value ? 1 : props.scale;
|
|
7642
|
+
} else {
|
|
7643
|
+
isActive.value = index === activeIndex;
|
|
7644
|
+
translate.value = calcTranslate(index, activeIndex);
|
|
7645
|
+
}
|
|
7646
|
+
isReady.value = true;
|
|
7647
|
+
};
|
|
7648
|
+
const handleItemClick = () => {
|
|
7649
|
+
if (parent && isCard.value) {
|
|
7650
|
+
const index = carousel.items.value.indexOf(instance);
|
|
7651
|
+
carousel.setActiveItem(index);
|
|
7652
|
+
}
|
|
7653
|
+
};
|
|
7654
|
+
expose({
|
|
7655
|
+
reset,
|
|
7656
|
+
isInStage,
|
|
7657
|
+
isHover,
|
|
7658
|
+
isActive
|
|
7659
|
+
});
|
|
7660
|
+
return {
|
|
7661
|
+
translate,
|
|
7662
|
+
currentScale,
|
|
7663
|
+
isHover,
|
|
7664
|
+
isActive,
|
|
7665
|
+
isReady,
|
|
7666
|
+
isInStage,
|
|
7667
|
+
isAnimating,
|
|
7668
|
+
isVertical,
|
|
7669
|
+
isCard,
|
|
7670
|
+
isMove,
|
|
7671
|
+
itemGutter,
|
|
7672
|
+
itemStyle,
|
|
7673
|
+
reset,
|
|
7674
|
+
handleItemClick
|
|
7675
|
+
};
|
|
7676
|
+
};
|
|
7677
|
+
|
|
7678
|
+
/** @jsxImportSource vue */
|
|
7679
|
+
|
|
7680
|
+
const COMPONENT_NAME$1_ = 'vc-carousel-item';
|
|
7681
|
+
const CarouselItem = /* @__PURE__ */ vue.defineComponent({
|
|
7682
|
+
name: COMPONENT_NAME$1_,
|
|
7062
7683
|
props: props$1i,
|
|
7684
|
+
setup(_, {
|
|
7685
|
+
slots,
|
|
7686
|
+
expose
|
|
7687
|
+
}) {
|
|
7688
|
+
const it = useCarouselItem(expose);
|
|
7689
|
+
return () => {
|
|
7690
|
+
return vue.withDirectives(vue.createVNode("div", {
|
|
7691
|
+
"class": ['vc-carousel-item', {
|
|
7692
|
+
'is-active': it.isActive.value,
|
|
7693
|
+
'is-card': it.isCard.value,
|
|
7694
|
+
'is-in-stage': it.isInStage.value,
|
|
7695
|
+
'is-hover': it.isHover.value,
|
|
7696
|
+
'is-animating': it.isAnimating.value && !it.isMove.value
|
|
7697
|
+
}],
|
|
7698
|
+
"style": it.itemStyle.value,
|
|
7699
|
+
"onClick": it.handleItemClick
|
|
7700
|
+
}, [it.isCard.value && vue.withDirectives(vue.createVNode("div", {
|
|
7701
|
+
"class": "vc-carousel-item__mask"
|
|
7702
|
+
}, null), [[vue.vShow, !it.isActive.value]]), slots.default?.()]), [[vue.vShow, it.isReady.value]]);
|
|
7703
|
+
};
|
|
7704
|
+
}
|
|
7705
|
+
});
|
|
7706
|
+
|
|
7707
|
+
/** @jsxImportSource vue */
|
|
7708
|
+
|
|
7709
|
+
const COMPONENT_NAME$1Z = 'vcm-carousel';
|
|
7710
|
+
const MCarousel = /* @__PURE__ */ vue.defineComponent({
|
|
7711
|
+
name: COMPONENT_NAME$1Z,
|
|
7712
|
+
props: {
|
|
7713
|
+
...props$1j,
|
|
7714
|
+
dots: {
|
|
7715
|
+
type: [String, Boolean],
|
|
7716
|
+
default: false
|
|
7717
|
+
},
|
|
7718
|
+
indicator: {
|
|
7719
|
+
type: Boolean,
|
|
7720
|
+
default: true
|
|
7721
|
+
}
|
|
7722
|
+
},
|
|
7063
7723
|
setup(props, {
|
|
7064
|
-
slots
|
|
7724
|
+
slots,
|
|
7725
|
+
expose
|
|
7065
7726
|
}) {
|
|
7727
|
+
const wrapper = vue.ref(null);
|
|
7728
|
+
const content = vue.ref(null);
|
|
7729
|
+
const carousel = useCarousel(wrapper, content, expose);
|
|
7730
|
+
let scrollStatus = 0;
|
|
7731
|
+
const handleTouchStart = e => {
|
|
7732
|
+
carousel.handleStart(e.touches[0]);
|
|
7733
|
+
scrollStatus = 0;
|
|
7734
|
+
};
|
|
7735
|
+
const handleTouchMove = e => {
|
|
7736
|
+
const absX = Math.abs(e.touches[0].screenX - carousel.startX.value);
|
|
7737
|
+
const absY = Math.abs(e.touches[0].screenY - carousel.startY.value);
|
|
7738
|
+
if (!props.vertical && absX > absY && scrollStatus !== 1) {
|
|
7739
|
+
e.preventDefault();
|
|
7740
|
+
carousel.handleMove(e.touches[0]);
|
|
7741
|
+
scrollStatus = 2;
|
|
7742
|
+
return;
|
|
7743
|
+
}
|
|
7744
|
+
if (props.vertical && absY > absX) {
|
|
7745
|
+
e.preventDefault();
|
|
7746
|
+
carousel.handleMove(e.touches[0]);
|
|
7747
|
+
return;
|
|
7748
|
+
}
|
|
7749
|
+
if (scrollStatus === 0) {
|
|
7750
|
+
scrollStatus = 1;
|
|
7751
|
+
}
|
|
7752
|
+
};
|
|
7753
|
+
|
|
7754
|
+
// e.changedTouches[0]
|
|
7755
|
+
const handleTouchEnd = () => {
|
|
7756
|
+
carousel.handleEnd();
|
|
7757
|
+
scrollStatus = 0;
|
|
7758
|
+
};
|
|
7066
7759
|
return () => {
|
|
7067
7760
|
return vue.createVNode("div", {
|
|
7068
|
-
"
|
|
7069
|
-
|
|
7761
|
+
"ref": wrapper,
|
|
7762
|
+
"class": ['vcm-carousel', `is-${carousel.direction.value}`],
|
|
7763
|
+
"onTouchstart": vue.withModifiers(handleTouchStart, ['stop']),
|
|
7764
|
+
"onTouchmove": vue.withModifiers(handleTouchMove, ['stop']),
|
|
7765
|
+
"onTouchend": vue.withModifiers(handleTouchEnd, ['stop'])
|
|
7766
|
+
}, [vue.createVNode("div", {
|
|
7767
|
+
"ref": content,
|
|
7768
|
+
"style": {
|
|
7769
|
+
height: props.height ? `${props.height}px` : 'auto'
|
|
7770
|
+
},
|
|
7771
|
+
"class": "vcm-carousel__wrapper"
|
|
7772
|
+
}, [slots.default?.()]), props.dots && vue.createVNode("ul", {
|
|
7773
|
+
"class": ['vcm-carousel__dots', ...carousel.dotsClasses.value]
|
|
7774
|
+
}, [carousel.items.value.map((_, index) => vue.createVNode("li", {
|
|
7775
|
+
"key": index,
|
|
7776
|
+
"class": ['vcm-carousel__dot', 'is-' + carousel.direction.value, {
|
|
7777
|
+
'is-active': index === carousel.activeIndex.value
|
|
7778
|
+
}],
|
|
7779
|
+
"onClick": e => {
|
|
7780
|
+
e.stopPropagation();
|
|
7781
|
+
carousel.handleDotClick(index);
|
|
7782
|
+
}
|
|
7783
|
+
}, [vue.createVNode("button", {
|
|
7784
|
+
"class": "vcm-carousel__button"
|
|
7785
|
+
}, [carousel.hasLabel.value && vue.createVNode("span", null, [carousel.items.value[index].props.label])])]))]), !props.card && props.indicator && vue.createVNode("div", {
|
|
7786
|
+
"class": "vcm-carousel__indicator"
|
|
7787
|
+
}, [vue.createVNode("span", null, [carousel.activeIndex.value + 1]), vue.createVNode("span", null, [vue.createTextVNode(" / ")]), vue.createVNode("span", null, [carousel.items.value.length])])]);
|
|
7070
7788
|
};
|
|
7071
7789
|
}
|
|
7072
7790
|
});
|
|
7073
7791
|
|
|
7074
|
-
|
|
7792
|
+
/** @jsxImportSource vue */
|
|
7793
|
+
|
|
7794
|
+
const COMPONENT_NAME$1Y = 'vcm-carousel-item';
|
|
7795
|
+
const MCarouselItem = /* @__PURE__ */ vue.defineComponent({
|
|
7796
|
+
name: COMPONENT_NAME$1Y,
|
|
7797
|
+
props: props$1i,
|
|
7798
|
+
setup(_, {
|
|
7799
|
+
slots,
|
|
7800
|
+
expose
|
|
7801
|
+
}) {
|
|
7802
|
+
const it = useCarouselItem(expose);
|
|
7803
|
+
return () => {
|
|
7804
|
+
return vue.withDirectives(vue.createVNode("div", {
|
|
7805
|
+
"style": it.itemStyle.value,
|
|
7806
|
+
"class": {
|
|
7807
|
+
'vcm-carousel-item': true,
|
|
7808
|
+
'is-active': it.isActive.value,
|
|
7809
|
+
'is-card': it.isCard.value,
|
|
7810
|
+
'is-animating': it.isAnimating.value && !it.isMove.value,
|
|
7811
|
+
'is-in-stage': it.isInStage.value
|
|
7812
|
+
},
|
|
7813
|
+
"onClick": it.handleItemClick
|
|
7814
|
+
}, [it.isCard.value && !it.isActive.value && vue.createVNode("div", {
|
|
7815
|
+
"class": "vcm-carousel-item__mask"
|
|
7816
|
+
}, null), slots.default?.()]), [[vue.vShow, it.isReady.value]]);
|
|
7817
|
+
};
|
|
7818
|
+
}
|
|
7819
|
+
});
|
|
7075
7820
|
|
|
7076
7821
|
const useAttrs = (options) => {
|
|
7077
7822
|
const attrs = vue.useAttrs();
|
|
@@ -7415,9 +8160,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7415
8160
|
|
|
7416
8161
|
/** @jsxImportSource vue */
|
|
7417
8162
|
|
|
7418
|
-
const COMPONENT_NAME$
|
|
8163
|
+
const COMPONENT_NAME$1X = 'vc-input';
|
|
7419
8164
|
const Input$1 = /* @__PURE__ */ vue.defineComponent({
|
|
7420
|
-
name: COMPONENT_NAME$
|
|
8165
|
+
name: COMPONENT_NAME$1X,
|
|
7421
8166
|
inheritAttrs: false,
|
|
7422
8167
|
props: {
|
|
7423
8168
|
...props$1h,
|
|
@@ -7752,9 +8497,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7752
8497
|
|
|
7753
8498
|
/** @jsxImportSource vue */
|
|
7754
8499
|
|
|
7755
|
-
const COMPONENT_NAME$
|
|
8500
|
+
const COMPONENT_NAME$1W = 'vc-input-number';
|
|
7756
8501
|
const InputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
7757
|
-
name: COMPONENT_NAME$
|
|
8502
|
+
name: COMPONENT_NAME$1W,
|
|
7758
8503
|
props: props$1g,
|
|
7759
8504
|
inheritAttrs: false,
|
|
7760
8505
|
setup(props, {
|
|
@@ -7818,9 +8563,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7818
8563
|
|
|
7819
8564
|
/** @jsxImportSource vue */
|
|
7820
8565
|
|
|
7821
|
-
const COMPONENT_NAME$
|
|
8566
|
+
const COMPONENT_NAME$1V = 'vc-input-search';
|
|
7822
8567
|
const InputSearch = /* @__PURE__ */ vue.defineComponent({
|
|
7823
|
-
name: COMPONENT_NAME$
|
|
8568
|
+
name: COMPONENT_NAME$1V,
|
|
7824
8569
|
props: props$1f,
|
|
7825
8570
|
inheritAttrs: false,
|
|
7826
8571
|
setup(props, {
|
|
@@ -7953,69 +8698,6 @@ var VcComponents = (function (exports, vue) {
|
|
|
7953
8698
|
...pick(props$1e, wrapperKeys)
|
|
7954
8699
|
};
|
|
7955
8700
|
|
|
7956
|
-
class Resize {
|
|
7957
|
-
el;
|
|
7958
|
-
static of(el) {
|
|
7959
|
-
return new Resize(el);
|
|
7960
|
-
}
|
|
7961
|
-
/**
|
|
7962
|
-
* Resize.of(el, fn);
|
|
7963
|
-
* @param el ~
|
|
7964
|
-
* @param fn ~
|
|
7965
|
-
* @returns off
|
|
7966
|
-
*/
|
|
7967
|
-
static on(el, fn) {
|
|
7968
|
-
return new Resize(el).on(fn);
|
|
7969
|
-
}
|
|
7970
|
-
/**
|
|
7971
|
-
* 要实现Resize.off(el),el必须侵入式修改挂上__rz__
|
|
7972
|
-
* @param el ~
|
|
7973
|
-
* @param fn ~
|
|
7974
|
-
* @returns ~
|
|
7975
|
-
*/
|
|
7976
|
-
static off(el, fn) {
|
|
7977
|
-
return new Resize(el).off(fn);
|
|
7978
|
-
}
|
|
7979
|
-
listeners = [];
|
|
7980
|
-
ro = null;
|
|
7981
|
-
constructor(el) {
|
|
7982
|
-
this.el = el;
|
|
7983
|
-
let rz = el.__rz__;
|
|
7984
|
-
if (rz && rz instanceof Resize) {
|
|
7985
|
-
this.listeners = rz.listeners;
|
|
7986
|
-
this.ro = rz.ro;
|
|
7987
|
-
}
|
|
7988
|
-
}
|
|
7989
|
-
handleResize = (entries) => {
|
|
7990
|
-
/* istanbul ignore else -- @preserve */
|
|
7991
|
-
if (entries.some((i) => i.target === this.el)) {
|
|
7992
|
-
this.listeners?.forEach((fn) => fn());
|
|
7993
|
-
}
|
|
7994
|
-
};
|
|
7995
|
-
on(fn) {
|
|
7996
|
-
if (typeof ResizeObserver === "undefined")
|
|
7997
|
-
return () => {
|
|
7998
|
-
};
|
|
7999
|
-
if (!this.listeners.length) {
|
|
8000
|
-
this.ro = this.ro || new ResizeObserver(this.handleResize);
|
|
8001
|
-
this.ro.observe(this.el);
|
|
8002
|
-
this.el.__rz__ = this;
|
|
8003
|
-
}
|
|
8004
|
-
this.listeners.push(fn);
|
|
8005
|
-
return () => this.off(fn);
|
|
8006
|
-
}
|
|
8007
|
-
off(fn) {
|
|
8008
|
-
if (fn) {
|
|
8009
|
-
this.listeners.splice(this.listeners.indexOf(fn), 1);
|
|
8010
|
-
} else {
|
|
8011
|
-
this.listeners = [];
|
|
8012
|
-
}
|
|
8013
|
-
if (!this.listeners.length && this.ro) {
|
|
8014
|
-
this.ro.disconnect();
|
|
8015
|
-
}
|
|
8016
|
-
}
|
|
8017
|
-
}
|
|
8018
|
-
|
|
8019
8701
|
const EXTRA_DISTANCE = 4;
|
|
8020
8702
|
const HALF_ARROW = 12.73 / 2;
|
|
8021
8703
|
const usePos = () => {
|
|
@@ -8276,9 +8958,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8276
8958
|
}
|
|
8277
8959
|
};
|
|
8278
8960
|
|
|
8279
|
-
const COMPONENT_NAME$
|
|
8961
|
+
const COMPONENT_NAME$1U = "vc-customer";
|
|
8280
8962
|
const Customer = vue.defineComponent({
|
|
8281
|
-
name: COMPONENT_NAME$
|
|
8963
|
+
name: COMPONENT_NAME$1U,
|
|
8282
8964
|
props: props$1c,
|
|
8283
8965
|
setup(props, context) {
|
|
8284
8966
|
return () => vue.h(() => {
|
|
@@ -8413,7 +9095,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
8413
9095
|
}
|
|
8414
9096
|
}
|
|
8415
9097
|
|
|
8416
|
-
const COMPONENT_NAME$
|
|
9098
|
+
const COMPONENT_NAME$1T = "vc-portal";
|
|
8417
9099
|
class Portal {
|
|
8418
9100
|
/**
|
|
8419
9101
|
* 清理Portals类型组件
|
|
@@ -8463,7 +9145,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
8463
9145
|
this.wrapper = wrapper;
|
|
8464
9146
|
this.globalOptions = {
|
|
8465
9147
|
...options,
|
|
8466
|
-
name: options?.name || wrapper.name || getUid(COMPONENT_NAME$
|
|
9148
|
+
name: options?.name || wrapper.name || getUid(COMPONENT_NAME$1T)
|
|
8467
9149
|
};
|
|
8468
9150
|
}
|
|
8469
9151
|
popup(propsData, options) {
|
|
@@ -8561,7 +9243,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
8561
9243
|
...rest
|
|
8562
9244
|
} = options;
|
|
8563
9245
|
let useAllNodes = fragment;
|
|
8564
|
-
const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$
|
|
9246
|
+
const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$1T)}` : name$;
|
|
8565
9247
|
const container = document.createElement(tag);
|
|
8566
9248
|
const root = typeof el === "object" ? el : document.querySelector(el || "body");
|
|
8567
9249
|
!alive && Portal.leafs.get(name)?.destroy();
|
|
@@ -8595,7 +9277,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
8595
9277
|
} else {
|
|
8596
9278
|
const wrapper = this.wrapper;
|
|
8597
9279
|
const app = vue.createApp({
|
|
8598
|
-
name: COMPONENT_NAME$
|
|
9280
|
+
name: COMPONENT_NAME$1T,
|
|
8599
9281
|
parent,
|
|
8600
9282
|
setup() {
|
|
8601
9283
|
if (alive) {
|
|
@@ -8706,13 +9388,13 @@ var VcComponents = (function (exports, vue) {
|
|
|
8706
9388
|
}
|
|
8707
9389
|
};
|
|
8708
9390
|
|
|
8709
|
-
const COMPONENT_NAME$
|
|
9391
|
+
const COMPONENT_NAME$1S = 'vc-portal-view';
|
|
8710
9392
|
|
|
8711
9393
|
/**
|
|
8712
9394
|
* 写法不同,但与vue@2.x 保持一致
|
|
8713
9395
|
*/
|
|
8714
9396
|
const PortalView = /* @__PURE__ */ vue.defineComponent({
|
|
8715
|
-
name: COMPONENT_NAME$
|
|
9397
|
+
name: COMPONENT_NAME$1S,
|
|
8716
9398
|
props: props$1b,
|
|
8717
9399
|
setup(props, {
|
|
8718
9400
|
slots
|
|
@@ -8732,9 +9414,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8732
9414
|
|
|
8733
9415
|
/** @jsxImportSource vue */
|
|
8734
9416
|
|
|
8735
|
-
const COMPONENT_NAME$
|
|
9417
|
+
const COMPONENT_NAME$1R = 'vc-popover-wrapper';
|
|
8736
9418
|
const PopoverWrapper = /* @__PURE__ */ vue.defineComponent({
|
|
8737
|
-
name: COMPONENT_NAME$
|
|
9419
|
+
name: COMPONENT_NAME$1R,
|
|
8738
9420
|
props: props$1e,
|
|
8739
9421
|
emits: ['portal-fulfilled', 'close'],
|
|
8740
9422
|
setup(props, {
|
|
@@ -8992,9 +9674,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8992
9674
|
|
|
8993
9675
|
/** @jsxImportSource vue */
|
|
8994
9676
|
|
|
8995
|
-
const COMPONENT_NAME$
|
|
9677
|
+
const COMPONENT_NAME$1Q = 'vc-popover';
|
|
8996
9678
|
const Popover$1 = /* @__PURE__ */ vue.defineComponent({
|
|
8997
|
-
name: COMPONENT_NAME$
|
|
9679
|
+
name: COMPONENT_NAME$1Q,
|
|
8998
9680
|
props: props$1d,
|
|
8999
9681
|
emits: ['update:modelValue', 'visible-change', 'ready', 'close'],
|
|
9000
9682
|
setup(props, {
|
|
@@ -9138,9 +9820,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9138
9820
|
|
|
9139
9821
|
/** @jsxImportSource vue */
|
|
9140
9822
|
|
|
9141
|
-
const COMPONENT_NAME$
|
|
9823
|
+
const COMPONENT_NAME$1P = 'vc-cascader-column';
|
|
9142
9824
|
const CascaderColumn = /* @__PURE__ */ vue.defineComponent({
|
|
9143
|
-
name: COMPONENT_NAME$
|
|
9825
|
+
name: COMPONENT_NAME$1P,
|
|
9144
9826
|
emits: ['click', 'change'],
|
|
9145
9827
|
props: {
|
|
9146
9828
|
data: {
|
|
@@ -9348,9 +10030,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9348
10030
|
|
|
9349
10031
|
/** @jsxImportSource vue */
|
|
9350
10032
|
|
|
9351
|
-
const COMPONENT_NAME$
|
|
10033
|
+
const COMPONENT_NAME$1O = 'vc-cascader';
|
|
9352
10034
|
const Cascader = /* @__PURE__ */ vue.defineComponent({
|
|
9353
|
-
name: COMPONENT_NAME$
|
|
10035
|
+
name: COMPONENT_NAME$1O,
|
|
9354
10036
|
inheritAttrs: false,
|
|
9355
10037
|
props: props$19,
|
|
9356
10038
|
emits: ['update:modelValue', 'visible-change', 'ready', 'change', 'close'],
|
|
@@ -9702,9 +10384,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9702
10384
|
|
|
9703
10385
|
/** @jsxImportSource vue */
|
|
9704
10386
|
|
|
9705
|
-
const COMPONENT_NAME$
|
|
10387
|
+
const COMPONENT_NAME$1N = 'vc-chart';
|
|
9706
10388
|
const Chart = /* @__PURE__ */ vue.defineComponent({
|
|
9707
|
-
name: COMPONENT_NAME$
|
|
10389
|
+
name: COMPONENT_NAME$1N,
|
|
9708
10390
|
props: props$18,
|
|
9709
10391
|
emits: [...EVENTS$1, 'ready'],
|
|
9710
10392
|
setup(props, {
|
|
@@ -9943,9 +10625,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9943
10625
|
|
|
9944
10626
|
/** @jsxImportSource vue */
|
|
9945
10627
|
|
|
9946
|
-
const COMPONENT_NAME$
|
|
10628
|
+
const COMPONENT_NAME$1M = 'vc-checkbox';
|
|
9947
10629
|
const Checkbox = /* @__PURE__ */ vue.defineComponent({
|
|
9948
|
-
name: COMPONENT_NAME$
|
|
10630
|
+
name: COMPONENT_NAME$1M,
|
|
9949
10631
|
props: props$17,
|
|
9950
10632
|
emits: ['update:modelValue', 'change'],
|
|
9951
10633
|
setup(props, {
|
|
@@ -10032,9 +10714,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10032
10714
|
|
|
10033
10715
|
/** @jsxImportSource vue */
|
|
10034
10716
|
|
|
10035
|
-
const COMPONENT_NAME$
|
|
10717
|
+
const COMPONENT_NAME$1L = 'vc-checkbox-group';
|
|
10036
10718
|
const CheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
10037
|
-
name: COMPONENT_NAME$
|
|
10719
|
+
name: COMPONENT_NAME$1L,
|
|
10038
10720
|
props: props$16,
|
|
10039
10721
|
emits: ['update:modelValue', 'change'],
|
|
10040
10722
|
setup(props, {
|
|
@@ -10052,9 +10734,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10052
10734
|
|
|
10053
10735
|
/** @jsxImportSource vue */
|
|
10054
10736
|
|
|
10055
|
-
const COMPONENT_NAME$
|
|
10737
|
+
const COMPONENT_NAME$1K = 'vcm-checkbox';
|
|
10056
10738
|
const MCheckbox = /* @__PURE__ */ vue.defineComponent({
|
|
10057
|
-
name: COMPONENT_NAME$
|
|
10739
|
+
name: COMPONENT_NAME$1K,
|
|
10058
10740
|
props: props$17,
|
|
10059
10741
|
emits: ['update:modelValue', 'change'],
|
|
10060
10742
|
setup(props, {
|
|
@@ -10094,9 +10776,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10094
10776
|
|
|
10095
10777
|
/** @jsxImportSource vue */
|
|
10096
10778
|
|
|
10097
|
-
const COMPONENT_NAME$
|
|
10779
|
+
const COMPONENT_NAME$1J = 'vcm-checkbox-group';
|
|
10098
10780
|
const MCheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
10099
|
-
name: COMPONENT_NAME$
|
|
10781
|
+
name: COMPONENT_NAME$1J,
|
|
10100
10782
|
props: props$16,
|
|
10101
10783
|
emits: ['update:modelValue', 'change'],
|
|
10102
10784
|
setup(props, {
|
|
@@ -10150,9 +10832,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10150
10832
|
|
|
10151
10833
|
/** @jsxImportSource vue */
|
|
10152
10834
|
|
|
10153
|
-
const COMPONENT_NAME$
|
|
10835
|
+
const COMPONENT_NAME$1I = 'vc-message';
|
|
10154
10836
|
const MessageView = /* @__PURE__ */ vue.defineComponent({
|
|
10155
|
-
name: COMPONENT_NAME$
|
|
10837
|
+
name: COMPONENT_NAME$1I,
|
|
10156
10838
|
emits: ['before-close', 'close', 'portal-fulfilled'],
|
|
10157
10839
|
props: props$15,
|
|
10158
10840
|
setup(props, {
|
|
@@ -10401,9 +11083,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10401
11083
|
return () => vue.h(props.tag, { onClick: handleClick, class: "vc-clipboard" }, slots?.default?.());
|
|
10402
11084
|
};
|
|
10403
11085
|
|
|
10404
|
-
const COMPONENT_NAME$
|
|
11086
|
+
const COMPONENT_NAME$1H = "vc-clipboard";
|
|
10405
11087
|
const Clipboard$2 = vue.defineComponent({
|
|
10406
|
-
name: COMPONENT_NAME$
|
|
11088
|
+
name: COMPONENT_NAME$1H,
|
|
10407
11089
|
props: props$14,
|
|
10408
11090
|
setup() {
|
|
10409
11091
|
return useClipboard((content) => Message.success({ content }));
|
|
@@ -10443,9 +11125,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10443
11125
|
|
|
10444
11126
|
/** @jsxImportSource vue */
|
|
10445
11127
|
|
|
10446
|
-
const COMPONENT_NAME$
|
|
11128
|
+
const COMPONENT_NAME$1G = 'vcm-toast';
|
|
10447
11129
|
const MToastView = /* @__PURE__ */ vue.defineComponent({
|
|
10448
|
-
name: COMPONENT_NAME$
|
|
11130
|
+
name: COMPONENT_NAME$1G,
|
|
10449
11131
|
emits: ['close', 'portal-fulfilled'],
|
|
10450
11132
|
props: props$13,
|
|
10451
11133
|
setup(props, {
|
|
@@ -10547,9 +11229,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10547
11229
|
const error$3 = create$6({ mode: "error" });
|
|
10548
11230
|
const MToast = Object.assign(MToastView, { destroy: destroy$4, info: info$2, success: success$2, loading, warning: warning$2, error: error$3 });
|
|
10549
11231
|
|
|
10550
|
-
const COMPONENT_NAME$
|
|
11232
|
+
const COMPONENT_NAME$1F = "vcm-clipboard";
|
|
10551
11233
|
const MClipboard$1 = vue.defineComponent({
|
|
10552
|
-
name: COMPONENT_NAME$
|
|
11234
|
+
name: COMPONENT_NAME$1F,
|
|
10553
11235
|
props: props$14,
|
|
10554
11236
|
setup() {
|
|
10555
11237
|
return useClipboard((content) => MToast.info({ content }));
|
|
@@ -10581,9 +11263,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10581
11263
|
}
|
|
10582
11264
|
};
|
|
10583
11265
|
|
|
10584
|
-
const COMPONENT_NAME$
|
|
11266
|
+
const COMPONENT_NAME$1E = "vc-collapse";
|
|
10585
11267
|
const Collapse = vue.defineComponent({
|
|
10586
|
-
name: COMPONENT_NAME$
|
|
11268
|
+
name: COMPONENT_NAME$1E,
|
|
10587
11269
|
props: props$12,
|
|
10588
11270
|
emits: ["update:moodelValue", "change"],
|
|
10589
11271
|
setup(props, { slots, emit }) {
|
|
@@ -10700,9 +11382,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10700
11382
|
function _isSlot$3(s) {
|
|
10701
11383
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
10702
11384
|
}
|
|
10703
|
-
const COMPONENT_NAME$
|
|
11385
|
+
const COMPONENT_NAME$1D = 'vc-expand';
|
|
10704
11386
|
const Expand$1 = /* @__PURE__ */ vue.defineComponent({
|
|
10705
|
-
name: COMPONENT_NAME$
|
|
11387
|
+
name: COMPONENT_NAME$1D,
|
|
10706
11388
|
props: props$10,
|
|
10707
11389
|
setup(props, {
|
|
10708
11390
|
slots
|
|
@@ -10732,9 +11414,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10732
11414
|
|
|
10733
11415
|
/** @jsxImportSource vue */
|
|
10734
11416
|
|
|
10735
|
-
const COMPONENT_NAME$
|
|
11417
|
+
const COMPONENT_NAME$1C = 'vc-collapse-item';
|
|
10736
11418
|
const CollapseItem = /* @__PURE__ */ vue.defineComponent({
|
|
10737
|
-
name: COMPONENT_NAME$
|
|
11419
|
+
name: COMPONENT_NAME$1C,
|
|
10738
11420
|
props: props$11,
|
|
10739
11421
|
setup(props, {
|
|
10740
11422
|
slots,
|
|
@@ -10809,9 +11491,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10809
11491
|
|
|
10810
11492
|
/** @jsxImportSource vue */
|
|
10811
11493
|
|
|
10812
|
-
const COMPONENT_NAME$
|
|
11494
|
+
const COMPONENT_NAME$1B = 'vc-color-picker';
|
|
10813
11495
|
const ColorPicker$1 = /* @__PURE__ */ vue.defineComponent({
|
|
10814
|
-
name: COMPONENT_NAME$
|
|
11496
|
+
name: COMPONENT_NAME$1B,
|
|
10815
11497
|
props: props$$,
|
|
10816
11498
|
setup(props, {
|
|
10817
11499
|
slots
|
|
@@ -10874,9 +11556,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10874
11556
|
function _isSlot$2(s) {
|
|
10875
11557
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
10876
11558
|
}
|
|
10877
|
-
const COMPONENT_NAME$
|
|
11559
|
+
const COMPONENT_NAME$1A = 'vc-countdown';
|
|
10878
11560
|
const Countdown = /* @__PURE__ */ vue.defineComponent({
|
|
10879
|
-
name: COMPONENT_NAME$
|
|
11561
|
+
name: COMPONENT_NAME$1A,
|
|
10880
11562
|
props: props$_,
|
|
10881
11563
|
emits: ['change', 'complete', 'error'],
|
|
10882
11564
|
setup(props, {
|
|
@@ -11149,9 +11831,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11149
11831
|
function _isSlot$1(s) {
|
|
11150
11832
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
11151
11833
|
}
|
|
11152
|
-
const COMPONENT_NAME$
|
|
11834
|
+
const COMPONENT_NAME$1z = 'vc-counter';
|
|
11153
11835
|
const Counter = /* @__PURE__ */ vue.defineComponent({
|
|
11154
|
-
name: COMPONENT_NAME$
|
|
11836
|
+
name: COMPONENT_NAME$1z,
|
|
11155
11837
|
props: props$Z,
|
|
11156
11838
|
emits: ['begin', 'complete', 'change'],
|
|
11157
11839
|
setup(props, {
|
|
@@ -12414,9 +13096,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12414
13096
|
}
|
|
12415
13097
|
return view;
|
|
12416
13098
|
};
|
|
12417
|
-
const COMPONENT_NAME$
|
|
13099
|
+
const COMPONENT_NAME$1y = 'vc-date-confirm';
|
|
12418
13100
|
const Confirm = /* @__PURE__ */ vue.defineComponent({
|
|
12419
|
-
name: COMPONENT_NAME$
|
|
13101
|
+
name: COMPONENT_NAME$1y,
|
|
12420
13102
|
props: {
|
|
12421
13103
|
showTime: {
|
|
12422
13104
|
type: Boolean,
|
|
@@ -12480,9 +13162,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12480
13162
|
|
|
12481
13163
|
/** @jsxImportSource vue */
|
|
12482
13164
|
|
|
12483
|
-
const COMPONENT_NAME$
|
|
13165
|
+
const COMPONENT_NAME$1x = 'vc-date-header';
|
|
12484
13166
|
const DateHeader = /* @__PURE__ */ vue.defineComponent({
|
|
12485
|
-
name: COMPONENT_NAME$
|
|
13167
|
+
name: COMPONENT_NAME$1x,
|
|
12486
13168
|
props: {
|
|
12487
13169
|
panelDate: Date,
|
|
12488
13170
|
showNext: {
|
|
@@ -12566,9 +13248,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12566
13248
|
|
|
12567
13249
|
/** @jsxImportSource vue */
|
|
12568
13250
|
|
|
12569
|
-
const COMPONENT_NAME$
|
|
13251
|
+
const COMPONENT_NAME$1w = 'vc-date-table';
|
|
12570
13252
|
const DateTable = /* @__PURE__ */ vue.defineComponent({
|
|
12571
|
-
name: COMPONENT_NAME$
|
|
13253
|
+
name: COMPONENT_NAME$1w,
|
|
12572
13254
|
props: {
|
|
12573
13255
|
value: Array,
|
|
12574
13256
|
firstDayOfWeek: {
|
|
@@ -12777,9 +13459,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12777
13459
|
|
|
12778
13460
|
/** @jsxImportSource vue */
|
|
12779
13461
|
|
|
12780
|
-
const COMPONENT_NAME$
|
|
13462
|
+
const COMPONENT_NAME$1v = 'vc-month-table';
|
|
12781
13463
|
const MonthTable = /* @__PURE__ */ vue.defineComponent({
|
|
12782
|
-
name: COMPONENT_NAME$
|
|
13464
|
+
name: COMPONENT_NAME$1v,
|
|
12783
13465
|
props: {
|
|
12784
13466
|
value: Array,
|
|
12785
13467
|
panelDate: Date,
|
|
@@ -12911,7 +13593,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
12911
13593
|
|
|
12912
13594
|
/** @jsxImportSource vue */
|
|
12913
13595
|
|
|
12914
|
-
const COMPONENT_NAME$
|
|
13596
|
+
const COMPONENT_NAME$1u = 'vc-quarter-table';
|
|
12915
13597
|
|
|
12916
13598
|
/**
|
|
12917
13599
|
* 获取季度对应的月份范围
|
|
@@ -12945,7 +13627,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
12945
13627
|
}
|
|
12946
13628
|
};
|
|
12947
13629
|
const QuarterTable = /* @__PURE__ */ vue.defineComponent({
|
|
12948
|
-
name: COMPONENT_NAME$
|
|
13630
|
+
name: COMPONENT_NAME$1u,
|
|
12949
13631
|
props: {
|
|
12950
13632
|
value: Array,
|
|
12951
13633
|
panelDate: Date,
|
|
@@ -13068,9 +13750,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13068
13750
|
|
|
13069
13751
|
/** @jsxImportSource vue */
|
|
13070
13752
|
|
|
13071
|
-
const COMPONENT_NAME$
|
|
13753
|
+
const COMPONENT_NAME$1t = 'vc-shortcuts-select';
|
|
13072
13754
|
const ShortcutsSelect = /* @__PURE__ */ vue.defineComponent({
|
|
13073
|
-
name: COMPONENT_NAME$
|
|
13755
|
+
name: COMPONENT_NAME$1t,
|
|
13074
13756
|
props: {
|
|
13075
13757
|
panelDate: Date,
|
|
13076
13758
|
config: Array,
|
|
@@ -13110,9 +13792,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13110
13792
|
|
|
13111
13793
|
/** @jsxImportSource vue */
|
|
13112
13794
|
|
|
13113
|
-
const COMPONENT_NAME$
|
|
13795
|
+
const COMPONENT_NAME$1s = 'vc-time-select';
|
|
13114
13796
|
const TimeSelect = /* @__PURE__ */ vue.defineComponent({
|
|
13115
|
-
name: COMPONENT_NAME$
|
|
13797
|
+
name: COMPONENT_NAME$1s,
|
|
13116
13798
|
props: {
|
|
13117
13799
|
hours: {
|
|
13118
13800
|
type: [Number, String],
|
|
@@ -13392,9 +14074,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13392
14074
|
|
|
13393
14075
|
/** @jsxImportSource vue */
|
|
13394
14076
|
|
|
13395
|
-
const COMPONENT_NAME$
|
|
14077
|
+
const COMPONENT_NAME$1r = 'vc-year-table';
|
|
13396
14078
|
const YearTable = /* @__PURE__ */ vue.defineComponent({
|
|
13397
|
-
name: COMPONENT_NAME$
|
|
14079
|
+
name: COMPONENT_NAME$1r,
|
|
13398
14080
|
props: {
|
|
13399
14081
|
value: Array,
|
|
13400
14082
|
panelDate: Date,
|
|
@@ -13517,9 +14199,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13517
14199
|
}
|
|
13518
14200
|
return true;
|
|
13519
14201
|
};
|
|
13520
|
-
const COMPONENT_NAME$
|
|
14202
|
+
const COMPONENT_NAME$1q = 'vc-date-range-panel';
|
|
13521
14203
|
const DateRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
13522
|
-
name: COMPONENT_NAME$
|
|
14204
|
+
name: COMPONENT_NAME$1q,
|
|
13523
14205
|
props: {
|
|
13524
14206
|
...props$W,
|
|
13525
14207
|
confirm: {
|
|
@@ -13898,9 +14580,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13898
14580
|
|
|
13899
14581
|
/** @jsxImportSource vue */
|
|
13900
14582
|
|
|
13901
|
-
const COMPONENT_NAME$
|
|
14583
|
+
const COMPONENT_NAME$1p = 'vc-date-panel';
|
|
13902
14584
|
const DatePanel = /* @__PURE__ */ vue.defineComponent({
|
|
13903
|
-
name: COMPONENT_NAME$
|
|
14585
|
+
name: COMPONENT_NAME$1p,
|
|
13904
14586
|
props: {
|
|
13905
14587
|
...props$W,
|
|
13906
14588
|
type: String,
|
|
@@ -14108,9 +14790,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14108
14790
|
const endYear = value[1].getFullYear();
|
|
14109
14791
|
return startYear === endYear;
|
|
14110
14792
|
};
|
|
14111
|
-
const COMPONENT_NAME$
|
|
14793
|
+
const COMPONENT_NAME$1o = 'vc-monthrange-panel';
|
|
14112
14794
|
const MonthRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
14113
|
-
name: COMPONENT_NAME$
|
|
14795
|
+
name: COMPONENT_NAME$1o,
|
|
14114
14796
|
props: {
|
|
14115
14797
|
...props$W,
|
|
14116
14798
|
confirm: {
|
|
@@ -14285,9 +14967,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14285
14967
|
const endYear = value[1].getFullYear();
|
|
14286
14968
|
return startYear === endYear;
|
|
14287
14969
|
};
|
|
14288
|
-
const COMPONENT_NAME$
|
|
14970
|
+
const COMPONENT_NAME$1n = 'vc-quarterrange-panel';
|
|
14289
14971
|
const QuarterRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
14290
|
-
name: COMPONENT_NAME$
|
|
14972
|
+
name: COMPONENT_NAME$1n,
|
|
14291
14973
|
props: {
|
|
14292
14974
|
...props$W,
|
|
14293
14975
|
confirm: {
|
|
@@ -14526,9 +15208,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14526
15208
|
seconds
|
|
14527
15209
|
};
|
|
14528
15210
|
};
|
|
14529
|
-
const COMPONENT_NAME$
|
|
15211
|
+
const COMPONENT_NAME$1m = 'vc-timerange-panel';
|
|
14530
15212
|
const TimeRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
14531
|
-
name: COMPONENT_NAME$
|
|
15213
|
+
name: COMPONENT_NAME$1m,
|
|
14532
15214
|
props: props$V,
|
|
14533
15215
|
emits: ['pick', 'clear', 'ok'],
|
|
14534
15216
|
setup(props, {
|
|
@@ -14629,9 +15311,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14629
15311
|
|
|
14630
15312
|
/** @jsxImportSource vue */
|
|
14631
15313
|
|
|
14632
|
-
const COMPONENT_NAME$
|
|
15314
|
+
const COMPONENT_NAME$1l = 'vc-time-panel';
|
|
14633
15315
|
const TimePanel = /* @__PURE__ */ vue.defineComponent({
|
|
14634
|
-
name: COMPONENT_NAME$
|
|
15316
|
+
name: COMPONENT_NAME$1l,
|
|
14635
15317
|
props: props$V,
|
|
14636
15318
|
emits: ['pick', 'clear', 'ok'],
|
|
14637
15319
|
setup(props, {
|
|
@@ -14687,7 +15369,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14687
15369
|
|
|
14688
15370
|
/** @jsxImportSource vue */
|
|
14689
15371
|
|
|
14690
|
-
const COMPONENT_NAME$
|
|
15372
|
+
const COMPONENT_NAME$1k = 'vc-date-picker';
|
|
14691
15373
|
const getPanel$1 = type => {
|
|
14692
15374
|
if (['daterange', 'datetimerange'].includes(type)) {
|
|
14693
15375
|
return DateRangePanel;
|
|
@@ -14698,7 +15380,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14698
15380
|
}
|
|
14699
15381
|
return DatePanel;
|
|
14700
15382
|
};
|
|
14701
|
-
const DatePicker = createPicker(COMPONENT_NAME$
|
|
15383
|
+
const DatePicker = createPicker(COMPONENT_NAME$1k, props$Y, () => {
|
|
14702
15384
|
const props = vue.getCurrentInstance().props;
|
|
14703
15385
|
const icon = vue.ref('date');
|
|
14704
15386
|
const panel = vue.shallowRef({});
|
|
@@ -14739,9 +15421,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14739
15421
|
|
|
14740
15422
|
/** @jsxImportSource vue */
|
|
14741
15423
|
|
|
14742
|
-
const COMPONENT_NAME$
|
|
15424
|
+
const COMPONENT_NAME$1j = 'vc-divider';
|
|
14743
15425
|
const Divider = /* @__PURE__ */ vue.defineComponent({
|
|
14744
|
-
name: COMPONENT_NAME$
|
|
15426
|
+
name: COMPONENT_NAME$1j,
|
|
14745
15427
|
props: props$U,
|
|
14746
15428
|
setup(props, {
|
|
14747
15429
|
slots
|
|
@@ -14877,7 +15559,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14877
15559
|
|
|
14878
15560
|
/** @jsxImportSource vue */
|
|
14879
15561
|
|
|
14880
|
-
const COMPONENT_NAME$
|
|
15562
|
+
const COMPONENT_NAME$1i = 'vc-scroller-track';
|
|
14881
15563
|
const BAR_MAP = {
|
|
14882
15564
|
vertical: {
|
|
14883
15565
|
scroll: 'scrollTop',
|
|
@@ -14897,7 +15579,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14897
15579
|
}
|
|
14898
15580
|
};
|
|
14899
15581
|
const Track$1 = /* @__PURE__ */ vue.defineComponent({
|
|
14900
|
-
name: COMPONENT_NAME$
|
|
15582
|
+
name: COMPONENT_NAME$1i,
|
|
14901
15583
|
props: props$T,
|
|
14902
15584
|
emits: ['change'],
|
|
14903
15585
|
inheritAttrs: false,
|
|
@@ -15087,9 +15769,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
15087
15769
|
|
|
15088
15770
|
/** @jsxImportSource vue */
|
|
15089
15771
|
|
|
15090
|
-
const COMPONENT_NAME$
|
|
15772
|
+
const COMPONENT_NAME$1h = 'vc-scroller-bar';
|
|
15091
15773
|
const Bar = /* @__PURE__ */ vue.defineComponent({
|
|
15092
|
-
name: COMPONENT_NAME$
|
|
15774
|
+
name: COMPONENT_NAME$1h,
|
|
15093
15775
|
props: props$S,
|
|
15094
15776
|
emits: ['change'],
|
|
15095
15777
|
setup(props, {
|
|
@@ -15324,7 +16006,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
15324
16006
|
|
|
15325
16007
|
/** @jsxImportSource vue */
|
|
15326
16008
|
|
|
15327
|
-
const COMPONENT_NAME$
|
|
16009
|
+
const COMPONENT_NAME$1g = 'vc-scroller';
|
|
15328
16010
|
|
|
15329
16011
|
/**
|
|
15330
16012
|
* 作为备选方案,目前推荐使用ScrollerWheel
|
|
@@ -15335,7 +16017,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
15335
16017
|
* 2. 增加了一层嵌套
|
|
15336
16018
|
*/
|
|
15337
16019
|
const Scroller = /* @__PURE__ */ vue.defineComponent({
|
|
15338
|
-
name: COMPONENT_NAME$
|
|
16020
|
+
name: COMPONENT_NAME$1g,
|
|
15339
16021
|
props: props$R,
|
|
15340
16022
|
emits: ['scroll'],
|
|
15341
16023
|
setup(props, {
|
|
@@ -16282,7 +16964,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
16282
16964
|
|
|
16283
16965
|
/** @jsxImportSource vue */
|
|
16284
16966
|
|
|
16285
|
-
const COMPONENT_NAME$
|
|
16967
|
+
const COMPONENT_NAME$1f = 'vc-scroller-wheel';
|
|
16286
16968
|
|
|
16287
16969
|
/**
|
|
16288
16970
|
* 为减少一层嵌套,为去除滚动bar的抖动,使用wheel模拟
|
|
@@ -16304,7 +16986,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
16304
16986
|
* 设置scrollTop不会reflow和repaint,不需要考虑transfrom来改变content(transform也只在draw完成)
|
|
16305
16987
|
*/
|
|
16306
16988
|
const ScrollerWheel = /* @__PURE__ */ vue.defineComponent({
|
|
16307
|
-
name: COMPONENT_NAME$
|
|
16989
|
+
name: COMPONENT_NAME$1f,
|
|
16308
16990
|
props: Object.assign({}, props$R, {
|
|
16309
16991
|
stopPropagation: {
|
|
16310
16992
|
type: Boolean,
|
|
@@ -16493,9 +17175,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
16493
17175
|
|
|
16494
17176
|
/** @jsxImportSource vue */
|
|
16495
17177
|
|
|
16496
|
-
const COMPONENT_NAME$
|
|
17178
|
+
const COMPONENT_NAME$1e = 'vc-drawer';
|
|
16497
17179
|
const DrawerView = /* @__PURE__ */ vue.defineComponent({
|
|
16498
|
-
name: COMPONENT_NAME$
|
|
17180
|
+
name: COMPONENT_NAME$1e,
|
|
16499
17181
|
props: props$Q,
|
|
16500
17182
|
emits: ['close', 'update:modelValue', 'visible-change'],
|
|
16501
17183
|
setup(props, {
|
|
@@ -16684,9 +17366,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
16684
17366
|
|
|
16685
17367
|
/** @jsxImportSource vue */
|
|
16686
17368
|
|
|
16687
|
-
const COMPONENT_NAME$
|
|
17369
|
+
const COMPONENT_NAME$1d = 'vc-dropdown';
|
|
16688
17370
|
const Dropdown = /* @__PURE__ */ vue.defineComponent({
|
|
16689
|
-
name: COMPONENT_NAME$
|
|
17371
|
+
name: COMPONENT_NAME$1d,
|
|
16690
17372
|
props: props$P,
|
|
16691
17373
|
inheritAttrs: false,
|
|
16692
17374
|
emits: ['update:modelValue', 'ready', 'close', 'visible-change', 'click'],
|
|
@@ -16756,9 +17438,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
16756
17438
|
|
|
16757
17439
|
/** @jsxImportSource vue */
|
|
16758
17440
|
|
|
16759
|
-
const COMPONENT_NAME$
|
|
17441
|
+
const COMPONENT_NAME$1c = 'vc-dropdown-menu';
|
|
16760
17442
|
const DropdownMenu = /* @__PURE__ */ vue.defineComponent({
|
|
16761
|
-
name: COMPONENT_NAME$
|
|
17443
|
+
name: COMPONENT_NAME$1c,
|
|
16762
17444
|
setup(_, {
|
|
16763
17445
|
slots
|
|
16764
17446
|
}) {
|
|
@@ -16772,9 +17454,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
16772
17454
|
|
|
16773
17455
|
/** @jsxImportSource vue */
|
|
16774
17456
|
|
|
16775
|
-
const COMPONENT_NAME$
|
|
17457
|
+
const COMPONENT_NAME$1b = 'vc-dropdown-item';
|
|
16776
17458
|
const DropdownItem = /* @__PURE__ */ vue.defineComponent({
|
|
16777
|
-
name: COMPONENT_NAME$
|
|
17459
|
+
name: COMPONENT_NAME$1b,
|
|
16778
17460
|
emits: ['click'],
|
|
16779
17461
|
props: {
|
|
16780
17462
|
value: {
|
|
@@ -17018,9 +17700,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
17018
17700
|
|
|
17019
17701
|
/** @jsxImportSource vue */
|
|
17020
17702
|
|
|
17021
|
-
const COMPONENT_NAME$
|
|
17703
|
+
const COMPONENT_NAME$1a = 'vc-editor-toolbar';
|
|
17022
17704
|
const EditorToolbar = /* @__PURE__ */ vue.defineComponent({
|
|
17023
|
-
name: COMPONENT_NAME$
|
|
17705
|
+
name: COMPONENT_NAME$1a,
|
|
17024
17706
|
props: {
|
|
17025
17707
|
options: [Array, Object],
|
|
17026
17708
|
elementId: String
|
|
@@ -17228,9 +17910,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
17228
17910
|
|
|
17229
17911
|
/** @jsxImportSource vue */
|
|
17230
17912
|
|
|
17231
|
-
const COMPONENT_NAME$
|
|
17913
|
+
const COMPONENT_NAME$19 = 'vc-image-preview';
|
|
17232
17914
|
const ImagePreview$1 = /* @__PURE__ */ vue.defineComponent({
|
|
17233
|
-
name: COMPONENT_NAME$
|
|
17915
|
+
name: COMPONENT_NAME$19,
|
|
17234
17916
|
props: props$O,
|
|
17235
17917
|
setup(props, {
|
|
17236
17918
|
slots
|
|
@@ -19383,9 +20065,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
19383
20065
|
}
|
|
19384
20066
|
};
|
|
19385
20067
|
|
|
19386
|
-
const COMPONENT_NAME$
|
|
20068
|
+
const COMPONENT_NAME$18 = "vc-upload";
|
|
19387
20069
|
const Upload$1 = vue.defineComponent({
|
|
19388
|
-
name: COMPONENT_NAME$
|
|
20070
|
+
name: COMPONENT_NAME$18,
|
|
19389
20071
|
props: props$N,
|
|
19390
20072
|
emits: [
|
|
19391
20073
|
"message",
|
|
@@ -19919,9 +20601,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
19919
20601
|
|
|
19920
20602
|
/** @jsxImportSource vue */
|
|
19921
20603
|
|
|
19922
|
-
const COMPONENT_NAME$
|
|
20604
|
+
const COMPONENT_NAME$17 = 'vc-editor';
|
|
19923
20605
|
const Editor$1 = /* @__PURE__ */ vue.defineComponent({
|
|
19924
|
-
name: COMPONENT_NAME$
|
|
20606
|
+
name: COMPONENT_NAME$17,
|
|
19925
20607
|
props: props$M,
|
|
19926
20608
|
defaults: defaults$1,
|
|
19927
20609
|
emits: ['ready', 'blur', 'focus', 'input', 'update:modelValue', 'change'],
|
|
@@ -20110,7 +20792,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
20110
20792
|
|
|
20111
20793
|
/** @jsxImportSource vue */
|
|
20112
20794
|
|
|
20113
|
-
const COMPONENT_NAME$
|
|
20795
|
+
const COMPONENT_NAME$16 = 'vc-editor-view';
|
|
20114
20796
|
const setImages = v => {
|
|
20115
20797
|
if (!v) return;
|
|
20116
20798
|
const IMG_REGX = /<img.*?(?:>|\/>)/gi;
|
|
@@ -20128,7 +20810,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
20128
20810
|
return;
|
|
20129
20811
|
};
|
|
20130
20812
|
const EditorView = /* @__PURE__ */ vue.defineComponent({
|
|
20131
|
-
name: COMPONENT_NAME$
|
|
20813
|
+
name: COMPONENT_NAME$16,
|
|
20132
20814
|
props: {
|
|
20133
20815
|
value: {
|
|
20134
20816
|
type: String,
|
|
@@ -20343,9 +21025,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
20343
21025
|
});
|
|
20344
21026
|
};
|
|
20345
21027
|
|
|
20346
|
-
const COMPONENT_NAME$
|
|
21028
|
+
const COMPONENT_NAME$15 = "vc-form";
|
|
20347
21029
|
const Form = vue.defineComponent({
|
|
20348
|
-
name: COMPONENT_NAME$
|
|
21030
|
+
name: COMPONENT_NAME$15,
|
|
20349
21031
|
props: props$L,
|
|
20350
21032
|
setup(props, { slots, expose }) {
|
|
20351
21033
|
useForm(expose);
|
|
@@ -20825,9 +21507,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
20825
21507
|
|
|
20826
21508
|
/** @jsxImportSource vue */
|
|
20827
21509
|
|
|
20828
|
-
const COMPONENT_NAME$
|
|
21510
|
+
const COMPONENT_NAME$14 = 'vc-form-item';
|
|
20829
21511
|
const FormItem = /* @__PURE__ */ vue.defineComponent({
|
|
20830
|
-
name: COMPONENT_NAME$
|
|
21512
|
+
name: COMPONENT_NAME$14,
|
|
20831
21513
|
props: props$K,
|
|
20832
21514
|
setup(props, {
|
|
20833
21515
|
slots,
|
|
@@ -20895,9 +21577,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
20895
21577
|
}
|
|
20896
21578
|
};
|
|
20897
21579
|
|
|
20898
|
-
const COMPONENT_NAME$
|
|
21580
|
+
const COMPONENT_NAME$13 = "vcm-form";
|
|
20899
21581
|
const MForm = vue.defineComponent({
|
|
20900
|
-
name: COMPONENT_NAME$
|
|
21582
|
+
name: COMPONENT_NAME$13,
|
|
20901
21583
|
props: props$J,
|
|
20902
21584
|
setup(props, { slots, expose }) {
|
|
20903
21585
|
useForm(expose, {
|
|
@@ -20928,9 +21610,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
20928
21610
|
|
|
20929
21611
|
/** @jsxImportSource vue */
|
|
20930
21612
|
|
|
20931
|
-
const COMPONENT_NAME$
|
|
21613
|
+
const COMPONENT_NAME$12 = 'vcm-form-item';
|
|
20932
21614
|
const MFormItem = /* @__PURE__ */ vue.defineComponent({
|
|
20933
|
-
name: COMPONENT_NAME$
|
|
21615
|
+
name: COMPONENT_NAME$12,
|
|
20934
21616
|
props: props$I,
|
|
20935
21617
|
setup(props, {
|
|
20936
21618
|
slots,
|
|
@@ -20985,9 +21667,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
20985
21667
|
}
|
|
20986
21668
|
});
|
|
20987
21669
|
|
|
20988
|
-
const COMPONENT_NAME
|
|
21670
|
+
const COMPONENT_NAME$11 = "vc-fragment";
|
|
20989
21671
|
const Fragment = vue.defineComponent({
|
|
20990
|
-
name: COMPONENT_NAME
|
|
21672
|
+
name: COMPONENT_NAME$11,
|
|
20991
21673
|
setup(_, { slots }) {
|
|
20992
21674
|
return () => vue.h(vue.Fragment, slots.default?.());
|
|
20993
21675
|
}
|
|
@@ -21026,9 +21708,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21026
21708
|
|
|
21027
21709
|
/** @jsxImportSource vue */
|
|
21028
21710
|
|
|
21029
|
-
const COMPONENT_NAME$
|
|
21711
|
+
const COMPONENT_NAME$10 = 'vc-snapshot';
|
|
21030
21712
|
const Snapshot = /* @__PURE__ */ vue.defineComponent({
|
|
21031
|
-
name: COMPONENT_NAME$
|
|
21713
|
+
name: COMPONENT_NAME$10,
|
|
21032
21714
|
props: props$H,
|
|
21033
21715
|
emits: ['ready'],
|
|
21034
21716
|
setup(props, {
|
|
@@ -21561,7 +22243,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
21561
22243
|
|
|
21562
22244
|
/** @jsxImportSource vue */
|
|
21563
22245
|
|
|
21564
|
-
const COMPONENT_NAME
|
|
22246
|
+
const COMPONENT_NAME$$ = 'vc-image';
|
|
21565
22247
|
let isSupportObjectFit = false;
|
|
21566
22248
|
window.addEventListener('DOMContentLoaded', () => {
|
|
21567
22249
|
isSupportObjectFit = !IS_SERVER$1 && document.documentElement.style.objectFit !== undefined;
|
|
@@ -21574,7 +22256,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
21574
22256
|
SCALE_DOWN: 'scale-down'
|
|
21575
22257
|
};
|
|
21576
22258
|
const Image$2 = /* @__PURE__ */ vue.defineComponent({
|
|
21577
|
-
name: COMPONENT_NAME
|
|
22259
|
+
name: COMPONENT_NAME$$,
|
|
21578
22260
|
inheritAttrs: false,
|
|
21579
22261
|
props: props$G,
|
|
21580
22262
|
setup(props, {
|
|
@@ -21791,9 +22473,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21791
22473
|
|
|
21792
22474
|
/** @jsxImportSource vue */
|
|
21793
22475
|
|
|
21794
|
-
const COMPONENT_NAME$
|
|
22476
|
+
const COMPONENT_NAME$_ = 'vc-image-crop';
|
|
21795
22477
|
const ImageCrop = /* @__PURE__ */ vue.defineComponent({
|
|
21796
|
-
name: COMPONENT_NAME$
|
|
22478
|
+
name: COMPONENT_NAME$_,
|
|
21797
22479
|
props: props$F,
|
|
21798
22480
|
setup(props, {
|
|
21799
22481
|
slots
|
|
@@ -21819,9 +22501,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21819
22501
|
|
|
21820
22502
|
/** @jsxImportSource vue */
|
|
21821
22503
|
|
|
21822
|
-
const COMPONENT_NAME$
|
|
22504
|
+
const COMPONENT_NAME$Z = 'vc-image-processing';
|
|
21823
22505
|
const ImageProcessing = /* @__PURE__ */ vue.defineComponent({
|
|
21824
|
-
name: COMPONENT_NAME$
|
|
22506
|
+
name: COMPONENT_NAME$Z,
|
|
21825
22507
|
props: props$E,
|
|
21826
22508
|
setup(props, {
|
|
21827
22509
|
slots
|
|
@@ -21838,9 +22520,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21838
22520
|
|
|
21839
22521
|
/** @jsxImportSource vue */
|
|
21840
22522
|
|
|
21841
|
-
const COMPONENT_NAME$
|
|
22523
|
+
const COMPONENT_NAME$Y = 'vcm-input';
|
|
21842
22524
|
const MInput = /* @__PURE__ */ vue.defineComponent({
|
|
21843
|
-
name: COMPONENT_NAME$
|
|
22525
|
+
name: COMPONENT_NAME$Y,
|
|
21844
22526
|
inheritAttrs: false,
|
|
21845
22527
|
props: {
|
|
21846
22528
|
...props$1h,
|
|
@@ -21929,9 +22611,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21929
22611
|
|
|
21930
22612
|
/** @jsxImportSource vue */
|
|
21931
22613
|
|
|
21932
|
-
const COMPONENT_NAME$
|
|
22614
|
+
const COMPONENT_NAME$X = 'vcm-input-number';
|
|
21933
22615
|
const MInputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
21934
|
-
name: COMPONENT_NAME$
|
|
22616
|
+
name: COMPONENT_NAME$X,
|
|
21935
22617
|
props: props$1g,
|
|
21936
22618
|
inheritAttrs: false,
|
|
21937
22619
|
setup(props, {
|
|
@@ -21980,9 +22662,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
21980
22662
|
|
|
21981
22663
|
/** @jsxImportSource vue */
|
|
21982
22664
|
|
|
21983
|
-
const COMPONENT_NAME$
|
|
22665
|
+
const COMPONENT_NAME$W = 'vcm-input-search';
|
|
21984
22666
|
const MInputSearch = /* @__PURE__ */ vue.defineComponent({
|
|
21985
|
-
name: COMPONENT_NAME$
|
|
22667
|
+
name: COMPONENT_NAME$W,
|
|
21986
22668
|
props: {
|
|
21987
22669
|
...props$1f,
|
|
21988
22670
|
cancelText: {
|
|
@@ -22059,9 +22741,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
22059
22741
|
}
|
|
22060
22742
|
};
|
|
22061
22743
|
|
|
22062
|
-
const COMPONENT_NAME$
|
|
22744
|
+
const COMPONENT_NAME$V = "vcm-list";
|
|
22063
22745
|
const MList = vue.defineComponent({
|
|
22064
|
-
name: COMPONENT_NAME$
|
|
22746
|
+
name: COMPONENT_NAME$V,
|
|
22065
22747
|
props: props$D,
|
|
22066
22748
|
setup(props, { slots }) {
|
|
22067
22749
|
vue.provide("vc-list", { props });
|
|
@@ -22116,10 +22798,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
22116
22798
|
|
|
22117
22799
|
/** @jsxImportSource vue */
|
|
22118
22800
|
|
|
22119
|
-
const COMPONENT_NAME$
|
|
22801
|
+
const COMPONENT_NAME$U = 'vcm-list-item';
|
|
22120
22802
|
const HTTP_REGEX = /[a-zA-z]+:\/\/[^\s]*/;
|
|
22121
22803
|
const MListItem = /* @__PURE__ */ vue.defineComponent({
|
|
22122
|
-
name: COMPONENT_NAME$
|
|
22804
|
+
name: COMPONENT_NAME$U,
|
|
22123
22805
|
props: props$C,
|
|
22124
22806
|
emits: ['click'],
|
|
22125
22807
|
setup(props, {
|
|
@@ -22213,11 +22895,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
22213
22895
|
|
|
22214
22896
|
/** @jsxImportSource vue */
|
|
22215
22897
|
|
|
22216
|
-
const COMPONENT_NAME$
|
|
22898
|
+
const COMPONENT_NAME$T = 'vc-marquee';
|
|
22217
22899
|
const ANIMATION = prefixStyle('animation').camel;
|
|
22218
22900
|
const TRANSFORM_KEBAB = prefixStyle('transform').kebab;
|
|
22219
22901
|
const Marquee = /* @__PURE__ */ vue.defineComponent({
|
|
22220
|
-
name: COMPONENT_NAME$
|
|
22902
|
+
name: COMPONENT_NAME$T,
|
|
22221
22903
|
props: props$B,
|
|
22222
22904
|
setup(props, {
|
|
22223
22905
|
slots
|
|
@@ -22285,9 +22967,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
22285
22967
|
}
|
|
22286
22968
|
};
|
|
22287
22969
|
|
|
22288
|
-
const COMPONENT_NAME$
|
|
22970
|
+
const COMPONENT_NAME$S = "vc-resizer";
|
|
22289
22971
|
const Resizer = vue.defineComponent({
|
|
22290
|
-
name: COMPONENT_NAME$
|
|
22972
|
+
name: COMPONENT_NAME$S,
|
|
22291
22973
|
props: props$A,
|
|
22292
22974
|
emits: ["resize"],
|
|
22293
22975
|
setup(props, { emit, slots, expose }) {
|
|
@@ -22457,10 +23139,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
22457
23139
|
|
|
22458
23140
|
/** @jsxImportSource vue */
|
|
22459
23141
|
|
|
22460
|
-
const COMPONENT_NAME$
|
|
23142
|
+
const COMPONENT_NAME$R = 'vc-modal';
|
|
22461
23143
|
let zIndexNumber = 1002;
|
|
22462
23144
|
const ModalView = /* @__PURE__ */ vue.defineComponent({
|
|
22463
|
-
name: COMPONENT_NAME$
|
|
23145
|
+
name: COMPONENT_NAME$R,
|
|
22464
23146
|
emits: ['update:modelValue', 'close', 'portal-fulfilled', 'visible-change', 'ok', 'cancel'],
|
|
22465
23147
|
props: props$z,
|
|
22466
23148
|
setup(props, {
|
|
@@ -22899,9 +23581,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
22899
23581
|
|
|
22900
23582
|
/** @jsxImportSource vue */
|
|
22901
23583
|
|
|
22902
|
-
const COMPONENT_NAME$
|
|
23584
|
+
const COMPONENT_NAME$Q = 'vc-modal';
|
|
22903
23585
|
const MModalView = /* @__PURE__ */ vue.defineComponent({
|
|
22904
|
-
name: COMPONENT_NAME$
|
|
23586
|
+
name: COMPONENT_NAME$Q,
|
|
22905
23587
|
emits: ['update:modelValue', 'portal-fulfilled', 'close', 'ok', 'cancel'],
|
|
22906
23588
|
props: props$y,
|
|
22907
23589
|
setup(props, {
|
|
@@ -23113,9 +23795,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23113
23795
|
|
|
23114
23796
|
/** @jsxImportSource vue */
|
|
23115
23797
|
|
|
23116
|
-
const COMPONENT_NAME$
|
|
23798
|
+
const COMPONENT_NAME$P = 'vc-notice';
|
|
23117
23799
|
const NoticeView = /* @__PURE__ */ vue.defineComponent({
|
|
23118
|
-
name: COMPONENT_NAME$
|
|
23800
|
+
name: COMPONENT_NAME$P,
|
|
23119
23801
|
props: props$x,
|
|
23120
23802
|
emits: ['portal-fulfilled', 'close', 'before-close'],
|
|
23121
23803
|
setup(props, {
|
|
@@ -23288,9 +23970,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23288
23970
|
|
|
23289
23971
|
/** @jsxImportSource vue */
|
|
23290
23972
|
|
|
23291
|
-
const COMPONENT_NAME$
|
|
23973
|
+
const COMPONENT_NAME$O = 'vc-option';
|
|
23292
23974
|
const Option$1 = /* @__PURE__ */ vue.defineComponent({
|
|
23293
|
-
name: COMPONENT_NAME$
|
|
23975
|
+
name: COMPONENT_NAME$O,
|
|
23294
23976
|
props: props$w,
|
|
23295
23977
|
setup(props, {
|
|
23296
23978
|
slots
|
|
@@ -23374,9 +24056,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23374
24056
|
|
|
23375
24057
|
/** @jsxImportSource vue */
|
|
23376
24058
|
|
|
23377
|
-
const COMPONENT_NAME$
|
|
24059
|
+
const COMPONENT_NAME$N = 'vc-tag';
|
|
23378
24060
|
const Tag = /* @__PURE__ */ vue.defineComponent({
|
|
23379
|
-
name: COMPONENT_NAME$
|
|
24061
|
+
name: COMPONENT_NAME$N,
|
|
23380
24062
|
props: props$u,
|
|
23381
24063
|
emits: ['close', 'change'],
|
|
23382
24064
|
setup(props, {
|
|
@@ -23447,9 +24129,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23447
24129
|
|
|
23448
24130
|
/** @jsxImportSource vue */
|
|
23449
24131
|
|
|
23450
|
-
const COMPONENT_NAME$
|
|
24132
|
+
const COMPONENT_NAME$M = 'vc-select-option';
|
|
23451
24133
|
const Option = /* @__PURE__ */ vue.defineComponent({
|
|
23452
|
-
name: COMPONENT_NAME$
|
|
24134
|
+
name: COMPONENT_NAME$M,
|
|
23453
24135
|
props: props$t,
|
|
23454
24136
|
setup(props, {
|
|
23455
24137
|
slots,
|
|
@@ -23544,9 +24226,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23544
24226
|
|
|
23545
24227
|
/** @jsxImportSource vue */
|
|
23546
24228
|
|
|
23547
|
-
const COMPONENT_NAME$
|
|
24229
|
+
const COMPONENT_NAME$L = 'vc-select-option-group';
|
|
23548
24230
|
const OptionGroup = /* @__PURE__ */ vue.defineComponent({
|
|
23549
|
-
name: COMPONENT_NAME$
|
|
24231
|
+
name: COMPONENT_NAME$L,
|
|
23550
24232
|
props: props$s,
|
|
23551
24233
|
setup(props, {
|
|
23552
24234
|
slots
|
|
@@ -23576,9 +24258,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23576
24258
|
|
|
23577
24259
|
/** @jsxImportSource vue */
|
|
23578
24260
|
|
|
23579
|
-
const COMPONENT_NAME$
|
|
24261
|
+
const COMPONENT_NAME$K = 'vc-select-all';
|
|
23580
24262
|
const SelectAll = /* @__PURE__ */ vue.defineComponent({
|
|
23581
|
-
name: COMPONENT_NAME$
|
|
24263
|
+
name: COMPONENT_NAME$K,
|
|
23582
24264
|
props: {
|
|
23583
24265
|
data: {
|
|
23584
24266
|
type: Array,
|
|
@@ -23648,9 +24330,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23648
24330
|
|
|
23649
24331
|
/** @jsxImportSource vue */
|
|
23650
24332
|
|
|
23651
|
-
const COMPONENT_NAME$
|
|
24333
|
+
const COMPONENT_NAME$J = 'vc-select';
|
|
23652
24334
|
const Select = /* @__PURE__ */ vue.defineComponent({
|
|
23653
|
-
name: COMPONENT_NAME$
|
|
24335
|
+
name: COMPONENT_NAME$J,
|
|
23654
24336
|
props: props$1a,
|
|
23655
24337
|
emits: ['ready', 'close', 'visible-change', 'clear', 'change', 'update:modelValue'],
|
|
23656
24338
|
setup(props, {
|
|
@@ -23944,9 +24626,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
23944
24626
|
|
|
23945
24627
|
/** @jsxImportSource vue */
|
|
23946
24628
|
|
|
23947
|
-
const COMPONENT_NAME$
|
|
24629
|
+
const COMPONENT_NAME$I = 'vc-pagination';
|
|
23948
24630
|
const Pagination = /* @__PURE__ */ vue.defineComponent({
|
|
23949
|
-
name: COMPONENT_NAME$
|
|
24631
|
+
name: COMPONENT_NAME$I,
|
|
23950
24632
|
props: props$v,
|
|
23951
24633
|
emits: ['update:current', 'change', 'page-size-change'],
|
|
23952
24634
|
setup(props, {
|
|
@@ -24144,9 +24826,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24144
24826
|
|
|
24145
24827
|
/** @jsxImportSource vue */
|
|
24146
24828
|
|
|
24147
|
-
const COMPONENT_NAME$
|
|
24829
|
+
const COMPONENT_NAME$H = 'vc-picker';
|
|
24148
24830
|
const Picker$1 = /* @__PURE__ */ vue.defineComponent({
|
|
24149
|
-
name: COMPONENT_NAME$
|
|
24831
|
+
name: COMPONENT_NAME$H,
|
|
24150
24832
|
props: props$r,
|
|
24151
24833
|
setup(props, {
|
|
24152
24834
|
slots
|
|
@@ -24209,9 +24891,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24209
24891
|
|
|
24210
24892
|
/** @jsxImportSource vue */
|
|
24211
24893
|
|
|
24212
|
-
const COMPONENT_NAME$
|
|
24894
|
+
const COMPONENT_NAME$G = 'vc-popconfirm';
|
|
24213
24895
|
const Popconfirm = /* @__PURE__ */ vue.defineComponent({
|
|
24214
|
-
name: COMPONENT_NAME$
|
|
24896
|
+
name: COMPONENT_NAME$G,
|
|
24215
24897
|
props: props$q,
|
|
24216
24898
|
inheritAttrs: false,
|
|
24217
24899
|
emits: ['update:modelValue', 'visible-change', 'ready', 'close', 'cancel', 'ok'],
|
|
@@ -24379,9 +25061,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24379
25061
|
|
|
24380
25062
|
/** @jsxImportSource vue */
|
|
24381
25063
|
|
|
24382
|
-
const COMPONENT_NAME$
|
|
25064
|
+
const COMPONENT_NAME$F = 'vc-popup';
|
|
24383
25065
|
const MPopup = /* @__PURE__ */ vue.defineComponent({
|
|
24384
|
-
name: COMPONENT_NAME$
|
|
25066
|
+
name: COMPONENT_NAME$F,
|
|
24385
25067
|
props: props$p,
|
|
24386
25068
|
emits: ['update:modelValue', 'close', 'portal-fulfilled', 'visible-change'],
|
|
24387
25069
|
setup(props, {
|
|
@@ -24508,9 +25190,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24508
25190
|
|
|
24509
25191
|
/** @jsxImportSource vue */
|
|
24510
25192
|
|
|
24511
|
-
const COMPONENT_NAME$
|
|
25193
|
+
const COMPONENT_NAME$E = 'vc-print';
|
|
24512
25194
|
const Print = /* @__PURE__ */ vue.defineComponent({
|
|
24513
|
-
name: COMPONENT_NAME$
|
|
25195
|
+
name: COMPONENT_NAME$E,
|
|
24514
25196
|
props: props$o,
|
|
24515
25197
|
setup(props, {
|
|
24516
25198
|
expose,
|
|
@@ -24590,7 +25272,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
24590
25272
|
},
|
|
24591
25273
|
strokeColor: {
|
|
24592
25274
|
type: String,
|
|
24593
|
-
default: "#
|
|
25275
|
+
default: "#456CF6"
|
|
24594
25276
|
},
|
|
24595
25277
|
trackColor: {
|
|
24596
25278
|
type: String,
|
|
@@ -24612,9 +25294,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24612
25294
|
|
|
24613
25295
|
/** @jsxImportSource vue */
|
|
24614
25296
|
|
|
24615
|
-
const COMPONENT_NAME$
|
|
25297
|
+
const COMPONENT_NAME$D = 'vc-progress-circle';
|
|
24616
25298
|
const Circle$1 = /* @__PURE__ */ vue.defineComponent({
|
|
24617
|
-
name: COMPONENT_NAME$
|
|
25299
|
+
name: COMPONENT_NAME$D,
|
|
24618
25300
|
props: props$n,
|
|
24619
25301
|
setup(props, {
|
|
24620
25302
|
slots
|
|
@@ -24674,9 +25356,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24674
25356
|
|
|
24675
25357
|
/** @jsxImportSource vue */
|
|
24676
25358
|
|
|
24677
|
-
const COMPONENT_NAME$
|
|
25359
|
+
const COMPONENT_NAME$C = 'vc-progress-line';
|
|
24678
25360
|
const Line$2 = /* @__PURE__ */ vue.defineComponent({
|
|
24679
|
-
name: COMPONENT_NAME$
|
|
25361
|
+
name: COMPONENT_NAME$C,
|
|
24680
25362
|
props: props$n,
|
|
24681
25363
|
setup(props) {
|
|
24682
25364
|
const colorStyle = vue.computed(() => {
|
|
@@ -24723,9 +25405,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24723
25405
|
function _isSlot(s) {
|
|
24724
25406
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
24725
25407
|
}
|
|
24726
|
-
const COMPONENT_NAME$
|
|
25408
|
+
const COMPONENT_NAME$B = 'vc-progress';
|
|
24727
25409
|
const Progress = /* @__PURE__ */ vue.defineComponent({
|
|
24728
|
-
name: COMPONENT_NAME$
|
|
25410
|
+
name: COMPONENT_NAME$B,
|
|
24729
25411
|
props: props$n,
|
|
24730
25412
|
setup(props, {
|
|
24731
25413
|
slots
|
|
@@ -24887,9 +25569,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24887
25569
|
|
|
24888
25570
|
/** @jsxImportSource vue */
|
|
24889
25571
|
|
|
24890
|
-
const COMPONENT_NAME$
|
|
25572
|
+
const COMPONENT_NAME$A = 'vc-radio';
|
|
24891
25573
|
const Radio = /* @__PURE__ */ vue.defineComponent({
|
|
24892
|
-
name: COMPONENT_NAME$
|
|
25574
|
+
name: COMPONENT_NAME$A,
|
|
24893
25575
|
props: props$m,
|
|
24894
25576
|
emits: ['update:modelValue', 'change'],
|
|
24895
25577
|
setup(props, {
|
|
@@ -24933,9 +25615,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
24933
25615
|
|
|
24934
25616
|
/** @jsxImportSource vue */
|
|
24935
25617
|
|
|
24936
|
-
const COMPONENT_NAME$
|
|
25618
|
+
const COMPONENT_NAME$z = 'vc-radio-button';
|
|
24937
25619
|
const RadioButton = /* @__PURE__ */ vue.defineComponent({
|
|
24938
|
-
name: COMPONENT_NAME$
|
|
25620
|
+
name: COMPONENT_NAME$z,
|
|
24939
25621
|
props: {
|
|
24940
25622
|
...props$m,
|
|
24941
25623
|
labelStyle: [String, Object],
|
|
@@ -25048,9 +25730,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25048
25730
|
|
|
25049
25731
|
/** @jsxImportSource vue */
|
|
25050
25732
|
|
|
25051
|
-
const COMPONENT_NAME$
|
|
25733
|
+
const COMPONENT_NAME$y = 'vc-radio-group';
|
|
25052
25734
|
const RadioGroup = /* @__PURE__ */ vue.defineComponent({
|
|
25053
|
-
name: COMPONENT_NAME$
|
|
25735
|
+
name: COMPONENT_NAME$y,
|
|
25054
25736
|
props: props$l,
|
|
25055
25737
|
emits: ['update:modelValue', 'change'],
|
|
25056
25738
|
setup(props, {
|
|
@@ -25071,9 +25753,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25071
25753
|
|
|
25072
25754
|
/** @jsxImportSource vue */
|
|
25073
25755
|
|
|
25074
|
-
const COMPONENT_NAME$
|
|
25756
|
+
const COMPONENT_NAME$x = 'vcm-radio';
|
|
25075
25757
|
const MRadio = /* @__PURE__ */ vue.defineComponent({
|
|
25076
|
-
name: COMPONENT_NAME$
|
|
25758
|
+
name: COMPONENT_NAME$x,
|
|
25077
25759
|
props: props$m,
|
|
25078
25760
|
emits: ['update:modelValue', 'change'],
|
|
25079
25761
|
setup(props, {
|
|
@@ -25117,9 +25799,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25117
25799
|
|
|
25118
25800
|
/** @jsxImportSource vue */
|
|
25119
25801
|
|
|
25120
|
-
const COMPONENT_NAME$
|
|
25802
|
+
const COMPONENT_NAME$w = 'vcm-radio-group';
|
|
25121
25803
|
const MRadioGroup = /* @__PURE__ */ vue.defineComponent({
|
|
25122
|
-
name: COMPONENT_NAME$
|
|
25804
|
+
name: COMPONENT_NAME$w,
|
|
25123
25805
|
props: props$l,
|
|
25124
25806
|
emits: ['update:modelValue', 'change'],
|
|
25125
25807
|
setup(props, {
|
|
@@ -25186,9 +25868,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25186
25868
|
|
|
25187
25869
|
/** @jsxImportSource vue */
|
|
25188
25870
|
|
|
25189
|
-
const COMPONENT_NAME$
|
|
25871
|
+
const COMPONENT_NAME$v = 'vc-rate';
|
|
25190
25872
|
const Rate = /* @__PURE__ */ vue.defineComponent({
|
|
25191
|
-
name: COMPONENT_NAME$
|
|
25873
|
+
name: COMPONENT_NAME$v,
|
|
25192
25874
|
props: props$k,
|
|
25193
25875
|
emits: ['update:modelValue', 'change'],
|
|
25194
25876
|
setup(props, {
|
|
@@ -25504,9 +26186,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25504
26186
|
|
|
25505
26187
|
/** @jsxImportSource vue */
|
|
25506
26188
|
|
|
25507
|
-
const COMPONENT_NAME$
|
|
26189
|
+
const COMPONENT_NAME$u = 'vc-recycle-list-scroll-state';
|
|
25508
26190
|
const ScrollState = /* @__PURE__ */ vue.defineComponent({
|
|
25509
|
-
name: COMPONENT_NAME$
|
|
26191
|
+
name: COMPONENT_NAME$u,
|
|
25510
26192
|
setup(_, {
|
|
25511
26193
|
slots
|
|
25512
26194
|
}) {
|
|
@@ -25636,12 +26318,12 @@ var VcComponents = (function (exports, vue) {
|
|
|
25636
26318
|
|
|
25637
26319
|
/** @jsxImportSource vue */
|
|
25638
26320
|
|
|
25639
|
-
const COMPONENT_NAME$
|
|
26321
|
+
const COMPONENT_NAME$t = 'vc-recycle-list-container';
|
|
25640
26322
|
|
|
25641
26323
|
// TODO: 抽离
|
|
25642
26324
|
const transformKey = prefixStyle('transform').camel;
|
|
25643
26325
|
const Container$1 = /* @__PURE__ */ vue.defineComponent({
|
|
25644
|
-
name: COMPONENT_NAME$
|
|
26326
|
+
name: COMPONENT_NAME$t,
|
|
25645
26327
|
props: props$i,
|
|
25646
26328
|
emits: ['refresh'],
|
|
25647
26329
|
setup(props, {
|
|
@@ -25739,9 +26421,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
25739
26421
|
|
|
25740
26422
|
/** @jsxImportSource vue */
|
|
25741
26423
|
|
|
25742
|
-
const COMPONENT_NAME$
|
|
26424
|
+
const COMPONENT_NAME$s = 'vc-recycle-list';
|
|
25743
26425
|
const RecycleList = /* @__PURE__ */ vue.defineComponent({
|
|
25744
|
-
name: COMPONENT_NAME$
|
|
26426
|
+
name: COMPONENT_NAME$s,
|
|
25745
26427
|
props: props$j,
|
|
25746
26428
|
emits: ['scroll', 'row-resize'],
|
|
25747
26429
|
setup(props, {
|
|
@@ -26315,9 +26997,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
26315
26997
|
|
|
26316
26998
|
/** @jsxImportSource vue */
|
|
26317
26999
|
|
|
26318
|
-
const COMPONENT_NAME$
|
|
27000
|
+
const COMPONENT_NAME$r = 'vc-slider';
|
|
26319
27001
|
const Slider = /* @__PURE__ */ vue.defineComponent({
|
|
26320
|
-
name: COMPONENT_NAME$
|
|
27002
|
+
name: COMPONENT_NAME$r,
|
|
26321
27003
|
props: props$h,
|
|
26322
27004
|
setup(props, {
|
|
26323
27005
|
slots
|
|
@@ -26341,9 +27023,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
26341
27023
|
|
|
26342
27024
|
/** @jsxImportSource vue */
|
|
26343
27025
|
|
|
26344
|
-
const COMPONENT_NAME$
|
|
27026
|
+
const COMPONENT_NAME$q = 'vc-sort-list';
|
|
26345
27027
|
const SortList = /* @__PURE__ */ vue.defineComponent({
|
|
26346
|
-
name: COMPONENT_NAME$
|
|
27028
|
+
name: COMPONENT_NAME$q,
|
|
26347
27029
|
props: props$g,
|
|
26348
27030
|
setup(props, {
|
|
26349
27031
|
slots
|
|
@@ -26367,9 +27049,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
26367
27049
|
|
|
26368
27050
|
/** @jsxImportSource vue */
|
|
26369
27051
|
|
|
26370
|
-
const COMPONENT_NAME$
|
|
27052
|
+
const COMPONENT_NAME$p = 'vc-steps';
|
|
26371
27053
|
const Steps = /* @__PURE__ */ vue.defineComponent({
|
|
26372
|
-
name: COMPONENT_NAME$
|
|
27054
|
+
name: COMPONENT_NAME$p,
|
|
26373
27055
|
props: props$f,
|
|
26374
27056
|
setup(props, {
|
|
26375
27057
|
slots
|
|
@@ -26495,9 +27177,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
26495
27177
|
|
|
26496
27178
|
/** @jsxImportSource vue */
|
|
26497
27179
|
|
|
26498
|
-
const COMPONENT_NAME$
|
|
27180
|
+
const COMPONENT_NAME$o = 'vc-switch';
|
|
26499
27181
|
const Switch = /* @__PURE__ */ vue.defineComponent({
|
|
26500
|
-
name: COMPONENT_NAME$
|
|
27182
|
+
name: COMPONENT_NAME$o,
|
|
26501
27183
|
props: props$e,
|
|
26502
27184
|
// click -> onClick要被拦截,此处不能放置
|
|
26503
27185
|
emits: ['update:modelValue', 'change', 'click'],
|
|
@@ -26571,9 +27253,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
26571
27253
|
|
|
26572
27254
|
/** @jsxImportSource vue */
|
|
26573
27255
|
|
|
26574
|
-
const COMPONENT_NAME$
|
|
27256
|
+
const COMPONENT_NAME$n = 'vcm-switch';
|
|
26575
27257
|
const MSwitch = /* @__PURE__ */ vue.defineComponent({
|
|
26576
|
-
name: COMPONENT_NAME$
|
|
27258
|
+
name: COMPONENT_NAME$n,
|
|
26577
27259
|
props: props$e,
|
|
26578
27260
|
// click -> onClick要被拦截,此处不能放置
|
|
26579
27261
|
emits: ['update:modelValue', 'change', 'click'],
|
|
@@ -27686,9 +28368,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
27686
28368
|
|
|
27687
28369
|
/** @jsxImportSource vue */
|
|
27688
28370
|
|
|
27689
|
-
const COMPONENT_NAME$
|
|
28371
|
+
const COMPONENT_NAME$m = 'vc-table-normal-list';
|
|
27690
28372
|
const NormalList = /* @__PURE__ */ vue.defineComponent({
|
|
27691
|
-
name: COMPONENT_NAME$
|
|
28373
|
+
name: COMPONENT_NAME$m,
|
|
27692
28374
|
props: {
|
|
27693
28375
|
data: {
|
|
27694
28376
|
type: Array,
|
|
@@ -28689,9 +29371,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
28689
29371
|
|
|
28690
29372
|
/** @jsxImportSource vue */
|
|
28691
29373
|
|
|
28692
|
-
const COMPONENT_NAME$
|
|
29374
|
+
const COMPONENT_NAME$l = 'vc-table';
|
|
28693
29375
|
const Table$1 = /* @__PURE__ */ vue.defineComponent({
|
|
28694
|
-
name: COMPONENT_NAME$
|
|
29376
|
+
name: COMPONENT_NAME$l,
|
|
28695
29377
|
props: props$d,
|
|
28696
29378
|
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'],
|
|
28697
29379
|
setup(props, {
|
|
@@ -29894,9 +30576,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
29894
30576
|
|
|
29895
30577
|
/** @jsxImportSource vue */
|
|
29896
30578
|
|
|
29897
|
-
const COMPONENT_NAME$
|
|
30579
|
+
const COMPONENT_NAME$k = 'vc-tabs';
|
|
29898
30580
|
const Tabs = /* @__PURE__ */ vue.defineComponent({
|
|
29899
|
-
name: COMPONENT_NAME$
|
|
30581
|
+
name: COMPONENT_NAME$k,
|
|
29900
30582
|
props: props$c,
|
|
29901
30583
|
emits: ['update:modelValue', 'change', 'click'],
|
|
29902
30584
|
setup(props, {
|
|
@@ -30149,9 +30831,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30149
30831
|
|
|
30150
30832
|
/** @jsxImportSource vue */
|
|
30151
30833
|
|
|
30152
|
-
const COMPONENT_NAME$
|
|
30834
|
+
const COMPONENT_NAME$j = 'vc-tabs-pane';
|
|
30153
30835
|
const TabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
30154
|
-
name: COMPONENT_NAME$
|
|
30836
|
+
name: COMPONENT_NAME$j,
|
|
30155
30837
|
props: props$b,
|
|
30156
30838
|
setup(_, {
|
|
30157
30839
|
slots
|
|
@@ -30206,9 +30888,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30206
30888
|
|
|
30207
30889
|
/** @jsxImportSource vue */
|
|
30208
30890
|
|
|
30209
|
-
const COMPONENT_NAME$
|
|
30891
|
+
const COMPONENT_NAME$i = 'vcm-tabs';
|
|
30210
30892
|
const MTabs = /* @__PURE__ */ vue.defineComponent({
|
|
30211
|
-
name: COMPONENT_NAME$
|
|
30893
|
+
name: COMPONENT_NAME$i,
|
|
30212
30894
|
props: props$a,
|
|
30213
30895
|
emits: ['update:modelValue', 'change', 'click'],
|
|
30214
30896
|
setup(props, {
|
|
@@ -30473,9 +31155,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30473
31155
|
|
|
30474
31156
|
/** @jsxImportSource vue */
|
|
30475
31157
|
|
|
30476
|
-
const COMPONENT_NAME$
|
|
31158
|
+
const COMPONENT_NAME$h = 'vcm-tabs-pane';
|
|
30477
31159
|
const MTabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
30478
|
-
name: COMPONENT_NAME$
|
|
31160
|
+
name: COMPONENT_NAME$h,
|
|
30479
31161
|
props: props$b,
|
|
30480
31162
|
setup(_, {
|
|
30481
31163
|
slots
|
|
@@ -30539,9 +31221,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30539
31221
|
|
|
30540
31222
|
/** @jsxImportSource vue */
|
|
30541
31223
|
|
|
30542
|
-
const COMPONENT_NAME$
|
|
31224
|
+
const COMPONENT_NAME$g = 'vc-text';
|
|
30543
31225
|
const Text$2 = /* @__PURE__ */ vue.defineComponent({
|
|
30544
|
-
name: COMPONENT_NAME$
|
|
31226
|
+
name: COMPONENT_NAME$g,
|
|
30545
31227
|
props: props$9,
|
|
30546
31228
|
setup(props, {
|
|
30547
31229
|
emit
|
|
@@ -30908,9 +31590,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30908
31590
|
|
|
30909
31591
|
/** @jsxImportSource vue */
|
|
30910
31592
|
|
|
30911
|
-
const COMPONENT_NAME$
|
|
31593
|
+
const COMPONENT_NAME$f = 'vc-textarea';
|
|
30912
31594
|
const Textarea = /* @__PURE__ */ vue.defineComponent({
|
|
30913
|
-
name: COMPONENT_NAME$
|
|
31595
|
+
name: COMPONENT_NAME$f,
|
|
30914
31596
|
props: Object.assign({}, props$8, {
|
|
30915
31597
|
indicator: {
|
|
30916
31598
|
type: [Boolean, Object],
|
|
@@ -30966,9 +31648,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
30966
31648
|
|
|
30967
31649
|
/** @jsxImportSource vue */
|
|
30968
31650
|
|
|
30969
|
-
const COMPONENT_NAME$
|
|
31651
|
+
const COMPONENT_NAME$e = 'vcm-textarea';
|
|
30970
31652
|
const MTextarea = /* @__PURE__ */ vue.defineComponent({
|
|
30971
|
-
name: COMPONENT_NAME$
|
|
31653
|
+
name: COMPONENT_NAME$e,
|
|
30972
31654
|
props: Object.assign({}, props$8, {
|
|
30973
31655
|
align: {
|
|
30974
31656
|
type: String,
|
|
@@ -31051,9 +31733,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31051
31733
|
}
|
|
31052
31734
|
};
|
|
31053
31735
|
|
|
31054
|
-
const COMPONENT_NAME$
|
|
31736
|
+
const COMPONENT_NAME$d = "vc-theme";
|
|
31055
31737
|
const Theme$1 = vue.defineComponent({
|
|
31056
|
-
name: COMPONENT_NAME$
|
|
31738
|
+
name: COMPONENT_NAME$d,
|
|
31057
31739
|
props: props$7,
|
|
31058
31740
|
setup(props, { slots }) {
|
|
31059
31741
|
const themeId = getUid("vc-theme");
|
|
@@ -31136,9 +31818,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31136
31818
|
}
|
|
31137
31819
|
});
|
|
31138
31820
|
|
|
31139
|
-
const COMPONENT_NAME$
|
|
31821
|
+
const COMPONENT_NAME$c = "vc-theme-view";
|
|
31140
31822
|
const ThemeView = vue.defineComponent({
|
|
31141
|
-
name: COMPONENT_NAME$
|
|
31823
|
+
name: COMPONENT_NAME$c,
|
|
31142
31824
|
props: props$7,
|
|
31143
31825
|
setup(props, { slots }) {
|
|
31144
31826
|
return () => {
|
|
@@ -31154,9 +31836,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31154
31836
|
}
|
|
31155
31837
|
});
|
|
31156
31838
|
|
|
31157
|
-
const COMPONENT_NAME$
|
|
31839
|
+
const COMPONENT_NAME$b = "vc-theme-text";
|
|
31158
31840
|
const ThemeText = vue.defineComponent({
|
|
31159
|
-
name: COMPONENT_NAME$
|
|
31841
|
+
name: COMPONENT_NAME$b,
|
|
31160
31842
|
props: props$7,
|
|
31161
31843
|
setup(props, { slots }) {
|
|
31162
31844
|
return () => {
|
|
@@ -31172,9 +31854,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31172
31854
|
}
|
|
31173
31855
|
});
|
|
31174
31856
|
|
|
31175
|
-
const COMPONENT_NAME$
|
|
31857
|
+
const COMPONENT_NAME$a = "vc-theme-image";
|
|
31176
31858
|
const ThemeImage = vue.defineComponent({
|
|
31177
|
-
name: COMPONENT_NAME$
|
|
31859
|
+
name: COMPONENT_NAME$a,
|
|
31178
31860
|
props: props$7,
|
|
31179
31861
|
setup(props, { slots }) {
|
|
31180
31862
|
return () => {
|
|
@@ -31226,12 +31908,12 @@ var VcComponents = (function (exports, vue) {
|
|
|
31226
31908
|
|
|
31227
31909
|
/** @jsxImportSource vue */
|
|
31228
31910
|
|
|
31229
|
-
const COMPONENT_NAME$
|
|
31911
|
+
const COMPONENT_NAME$9 = 'vc-time-picker';
|
|
31230
31912
|
const getPanel = type => {
|
|
31231
31913
|
const isRange = type === 'timerange';
|
|
31232
31914
|
return isRange ? TimeRangePanel : TimePanel;
|
|
31233
31915
|
};
|
|
31234
|
-
const TimePicker = createPicker(COMPONENT_NAME$
|
|
31916
|
+
const TimePicker = createPicker(COMPONENT_NAME$9, props$6, () => {
|
|
31235
31917
|
const props = vue.getCurrentInstance().props;
|
|
31236
31918
|
const icon = vue.ref('icon');
|
|
31237
31919
|
const panel = vue.shallowRef({});
|
|
@@ -31267,9 +31949,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31267
31949
|
|
|
31268
31950
|
/** @jsxImportSource vue */
|
|
31269
31951
|
|
|
31270
|
-
const COMPONENT_NAME$
|
|
31952
|
+
const COMPONENT_NAME$8 = 'vc-timeline';
|
|
31271
31953
|
const Timeline = /* @__PURE__ */ vue.defineComponent({
|
|
31272
|
-
name: COMPONENT_NAME$
|
|
31954
|
+
name: COMPONENT_NAME$8,
|
|
31273
31955
|
props: props$5,
|
|
31274
31956
|
setup(props, {
|
|
31275
31957
|
slots
|
|
@@ -31296,9 +31978,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
31296
31978
|
|
|
31297
31979
|
/** @jsxImportSource vue */
|
|
31298
31980
|
|
|
31299
|
-
const COMPONENT_NAME$
|
|
31981
|
+
const COMPONENT_NAME$7 = 'vc-touch';
|
|
31300
31982
|
const Touch = /* @__PURE__ */ vue.defineComponent({
|
|
31301
|
-
name: COMPONENT_NAME$
|
|
31983
|
+
name: COMPONENT_NAME$7,
|
|
31302
31984
|
props: props$4,
|
|
31303
31985
|
setup(props, {
|
|
31304
31986
|
slots
|
|
@@ -31806,21 +32488,68 @@ var VcComponents = (function (exports, vue) {
|
|
|
31806
32488
|
parentNode.insertChild({ data });
|
|
31807
32489
|
}
|
|
31808
32490
|
}
|
|
32491
|
+
/**
|
|
32492
|
+
* 级联非 strict:仅对「选中集合里的最深节点」做 setChecked(true, deep),
|
|
32493
|
+
* 避免对祖先逐个 deep 勾选把未出现在 checkedValues 里的兄弟子树再次全选。
|
|
32494
|
+
* @param checkedValues ~
|
|
32495
|
+
* @returns ~
|
|
32496
|
+
*/
|
|
32497
|
+
_getCascadeCheckedAnchorIds(checkedValues) {
|
|
32498
|
+
const checkedSet = new Set(checkedValues);
|
|
32499
|
+
const nodesMap = this.nodesMap;
|
|
32500
|
+
const anchors = [];
|
|
32501
|
+
for (const id of checkedValues) {
|
|
32502
|
+
const node = nodesMap[id];
|
|
32503
|
+
if (!node) continue;
|
|
32504
|
+
const hasSelectedChildInSet = node.childNodes.some(
|
|
32505
|
+
(child) => checkedSet.has(child.getter.value)
|
|
32506
|
+
);
|
|
32507
|
+
if (!hasSelectedChildInSet) {
|
|
32508
|
+
anchors.push(id);
|
|
32509
|
+
}
|
|
32510
|
+
}
|
|
32511
|
+
anchors.sort((a, b) => {
|
|
32512
|
+
const na = nodesMap[a];
|
|
32513
|
+
const nb = nodesMap[b];
|
|
32514
|
+
if (!na || !nb) return 0;
|
|
32515
|
+
return nb.states.level - na.states.level;
|
|
32516
|
+
});
|
|
32517
|
+
return anchors;
|
|
32518
|
+
}
|
|
31809
32519
|
_initDefaultCheckedNodes() {
|
|
31810
32520
|
const checkedValues = this.checkedValues || [];
|
|
31811
32521
|
const nodesMap = this.nodesMap;
|
|
31812
|
-
|
|
32522
|
+
if (this.checkStrictly) {
|
|
32523
|
+
checkedValues.forEach((id) => {
|
|
32524
|
+
const node = nodesMap[id];
|
|
32525
|
+
if (node) {
|
|
32526
|
+
node.setChecked(true, false);
|
|
32527
|
+
}
|
|
32528
|
+
});
|
|
32529
|
+
return;
|
|
32530
|
+
}
|
|
32531
|
+
const anchorIds = this._getCascadeCheckedAnchorIds(checkedValues);
|
|
32532
|
+
anchorIds.forEach((id) => {
|
|
31813
32533
|
const node = nodesMap[id];
|
|
31814
32534
|
if (node) {
|
|
31815
|
-
node.setChecked(true,
|
|
32535
|
+
node.setChecked(true, true);
|
|
31816
32536
|
}
|
|
31817
32537
|
});
|
|
31818
32538
|
}
|
|
31819
32539
|
_initDefaultCheckedNode(node) {
|
|
31820
32540
|
const checkedValues = this.checkedValues || [];
|
|
31821
32541
|
const nodeValue = node.getter.value;
|
|
31822
|
-
if (checkedValues.indexOf(nodeValue)
|
|
31823
|
-
|
|
32542
|
+
if (checkedValues.indexOf(nodeValue) === -1) return;
|
|
32543
|
+
if (this.checkStrictly) {
|
|
32544
|
+
node.setChecked(true, false);
|
|
32545
|
+
return;
|
|
32546
|
+
}
|
|
32547
|
+
const checkedSet = new Set(checkedValues);
|
|
32548
|
+
const hasSelectedChildInSet = node.childNodes.some(
|
|
32549
|
+
(child) => checkedSet.has(child.getter.value)
|
|
32550
|
+
);
|
|
32551
|
+
if (!hasSelectedChildInSet) {
|
|
32552
|
+
node.setChecked(true, true);
|
|
31824
32553
|
}
|
|
31825
32554
|
}
|
|
31826
32555
|
setCheckedValues(newVal) {
|
|
@@ -32048,9 +32777,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
32048
32777
|
|
|
32049
32778
|
/** @jsxImportSource vue */
|
|
32050
32779
|
|
|
32051
|
-
const COMPONENT_NAME$
|
|
32780
|
+
const COMPONENT_NAME$6 = 'vc-tree-node';
|
|
32052
32781
|
const TreeNodeContent = /* @__PURE__ */ vue.defineComponent({
|
|
32053
|
-
name: COMPONENT_NAME$
|
|
32782
|
+
name: COMPONENT_NAME$6,
|
|
32054
32783
|
props: props$3,
|
|
32055
32784
|
emits: ['node-expand'],
|
|
32056
32785
|
setup(props, {
|
|
@@ -32549,9 +33278,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
32549
33278
|
|
|
32550
33279
|
/** @jsxImportSource vue */
|
|
32551
33280
|
|
|
32552
|
-
const COMPONENT_NAME$
|
|
33281
|
+
const COMPONENT_NAME$5 = 'vc-tree';
|
|
32553
33282
|
const Tree$1 = /* @__PURE__ */ vue.defineComponent({
|
|
32554
|
-
name: COMPONENT_NAME$
|
|
33283
|
+
name: COMPONENT_NAME$5,
|
|
32555
33284
|
props: props$2,
|
|
32556
33285
|
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'],
|
|
32557
33286
|
setup(props, {
|
|
@@ -32746,6 +33475,225 @@ var VcComponents = (function (exports, vue) {
|
|
|
32746
33475
|
}
|
|
32747
33476
|
});
|
|
32748
33477
|
|
|
33478
|
+
/** @jsxImportSource vue */
|
|
33479
|
+
|
|
33480
|
+
const COMPONENT_NAME$4 = 'vc-tree-select-content';
|
|
33481
|
+
const TreeSelectContent = /* @__PURE__ */ vue.defineComponent({
|
|
33482
|
+
name: COMPONENT_NAME$4,
|
|
33483
|
+
props: {
|
|
33484
|
+
value: {
|
|
33485
|
+
type: Array,
|
|
33486
|
+
required: true
|
|
33487
|
+
},
|
|
33488
|
+
data: {
|
|
33489
|
+
type: Array,
|
|
33490
|
+
default: () => []
|
|
33491
|
+
},
|
|
33492
|
+
checkStrictly: {
|
|
33493
|
+
type: Boolean,
|
|
33494
|
+
default: false
|
|
33495
|
+
},
|
|
33496
|
+
renderNodeLabel: Function
|
|
33497
|
+
},
|
|
33498
|
+
emits: ['change'],
|
|
33499
|
+
setup(props, {
|
|
33500
|
+
emit
|
|
33501
|
+
}) {
|
|
33502
|
+
return () => {
|
|
33503
|
+
return vue.createVNode(Scroller, {
|
|
33504
|
+
"class": "vc-tree-select__options",
|
|
33505
|
+
"max-height": "200px"
|
|
33506
|
+
}, {
|
|
33507
|
+
default: () => [vue.createVNode(Tree$1, {
|
|
33508
|
+
"model-value": props.value,
|
|
33509
|
+
"expanded-values": props.value,
|
|
33510
|
+
"data": props.data,
|
|
33511
|
+
"checkStrictly": props.checkStrictly,
|
|
33512
|
+
"allowDispatch": false,
|
|
33513
|
+
"showCheckbox": true,
|
|
33514
|
+
"renderNodeLabel": props.renderNodeLabel,
|
|
33515
|
+
"onChange": (_, data) => emit('change', _, data)
|
|
33516
|
+
}, null)]
|
|
33517
|
+
});
|
|
33518
|
+
};
|
|
33519
|
+
}
|
|
33520
|
+
});
|
|
33521
|
+
|
|
33522
|
+
/** @jsxImportSource vue */
|
|
33523
|
+
|
|
33524
|
+
const COMPONENT_NAME$3 = 'vc-tree-select-content-cascader';
|
|
33525
|
+
const TreeSelectContentCascader = /* @__PURE__ */ vue.defineComponent({
|
|
33526
|
+
name: COMPONENT_NAME$3,
|
|
33527
|
+
props: {
|
|
33528
|
+
value: {
|
|
33529
|
+
type: Array,
|
|
33530
|
+
required: true
|
|
33531
|
+
},
|
|
33532
|
+
data: {
|
|
33533
|
+
type: Array,
|
|
33534
|
+
default: () => []
|
|
33535
|
+
},
|
|
33536
|
+
checkStrictly: {
|
|
33537
|
+
type: Boolean,
|
|
33538
|
+
default: false
|
|
33539
|
+
},
|
|
33540
|
+
renderNodeLabel: Function,
|
|
33541
|
+
numerable: {
|
|
33542
|
+
type: Boolean,
|
|
33543
|
+
default: false
|
|
33544
|
+
},
|
|
33545
|
+
separator: {
|
|
33546
|
+
type: String,
|
|
33547
|
+
default: ','
|
|
33548
|
+
},
|
|
33549
|
+
max: {
|
|
33550
|
+
type: Number,
|
|
33551
|
+
default: 1
|
|
33552
|
+
},
|
|
33553
|
+
nullValue: {
|
|
33554
|
+
type: [Number, String, Object],
|
|
33555
|
+
default: void 0
|
|
33556
|
+
}
|
|
33557
|
+
},
|
|
33558
|
+
emits: ['change'],
|
|
33559
|
+
setup(props, {
|
|
33560
|
+
emit
|
|
33561
|
+
}) {
|
|
33562
|
+
const treeRef = vue.ref(null);
|
|
33563
|
+
/** hover 展开路径,与 Cascader 一致 */
|
|
33564
|
+
const currentValue = vue.ref([]);
|
|
33565
|
+
const rebuildData = vue.computed(() => {
|
|
33566
|
+
if (!props.data.length) return [];
|
|
33567
|
+
let temp = props.data;
|
|
33568
|
+
const data = [];
|
|
33569
|
+
currentValue.value.forEach(cur => {
|
|
33570
|
+
const col = temp;
|
|
33571
|
+
data.push(col);
|
|
33572
|
+
const next = (temp.find(i => i.value == cur) || {}).children || [];
|
|
33573
|
+
temp = next;
|
|
33574
|
+
});
|
|
33575
|
+
data.push(temp);
|
|
33576
|
+
return data;
|
|
33577
|
+
});
|
|
33578
|
+
/** 驱动列区在 TreeStore 更新后重绘 */
|
|
33579
|
+
const panelTick = vue.ref(0);
|
|
33580
|
+
const columns = vue.computed(() => Array.from({
|
|
33581
|
+
length: currentValue.value.length + 1
|
|
33582
|
+
}).map((_, index) => index));
|
|
33583
|
+
const handleHover = (value, columnIndex) => {
|
|
33584
|
+
const len = currentValue.value.length - columnIndex;
|
|
33585
|
+
currentValue.value.splice(columnIndex, len, value);
|
|
33586
|
+
};
|
|
33587
|
+
const sync = async () => {
|
|
33588
|
+
await vue.nextTick();
|
|
33589
|
+
const tree = treeRef.value;
|
|
33590
|
+
if (!tree) return;
|
|
33591
|
+
const data = {
|
|
33592
|
+
checkedNodes: tree.getCheckedNodes(),
|
|
33593
|
+
checkedValues: tree.getCheckedValues(),
|
|
33594
|
+
halfCheckedNodes: tree.getHalfCheckedNodes(),
|
|
33595
|
+
halfCheckedValues: tree.getHalfCheckedValues()
|
|
33596
|
+
};
|
|
33597
|
+
panelTick.value++;
|
|
33598
|
+
emit('change', null, data);
|
|
33599
|
+
};
|
|
33600
|
+
const getNodeState = item => {
|
|
33601
|
+
const tree = treeRef.value;
|
|
33602
|
+
if (!tree) {
|
|
33603
|
+
return {
|
|
33604
|
+
checked: false,
|
|
33605
|
+
indeterminate: false
|
|
33606
|
+
};
|
|
33607
|
+
}
|
|
33608
|
+
const node = tree.getNode(item);
|
|
33609
|
+
if (!node) {
|
|
33610
|
+
return {
|
|
33611
|
+
checked: false,
|
|
33612
|
+
indeterminate: false
|
|
33613
|
+
};
|
|
33614
|
+
}
|
|
33615
|
+
return {
|
|
33616
|
+
checked: !!node.states.checked,
|
|
33617
|
+
indeterminate: !!node.states.indeterminate
|
|
33618
|
+
};
|
|
33619
|
+
};
|
|
33620
|
+
const hasChildren = item => {
|
|
33621
|
+
return !!(item.children && item.children.length > 0);
|
|
33622
|
+
};
|
|
33623
|
+
const handleCheckboxChange = async (v, item) => {
|
|
33624
|
+
const tree = treeRef.value;
|
|
33625
|
+
if (!tree) return;
|
|
33626
|
+
tree.setChecked(item, v, !props.checkStrictly);
|
|
33627
|
+
sync();
|
|
33628
|
+
};
|
|
33629
|
+
const handleLabelClick = (v, item) => {
|
|
33630
|
+
const tree = treeRef.value;
|
|
33631
|
+
if (!tree) return;
|
|
33632
|
+
tree.setChecked(item, v, !props.checkStrictly);
|
|
33633
|
+
sync();
|
|
33634
|
+
};
|
|
33635
|
+
return () => {
|
|
33636
|
+
return vue.createVNode("div", {
|
|
33637
|
+
"class": "vc-tree-select__cascader"
|
|
33638
|
+
}, [vue.createVNode(Tree$1, {
|
|
33639
|
+
"ref": treeRef,
|
|
33640
|
+
"class": "vc-tree-select__cascader-tree-hidden",
|
|
33641
|
+
"model-value": props.value,
|
|
33642
|
+
"expanded-values": props.value,
|
|
33643
|
+
"data": props.data,
|
|
33644
|
+
"checkStrictly": props.checkStrictly,
|
|
33645
|
+
"allowDispatch": false,
|
|
33646
|
+
"showCheckbox": true,
|
|
33647
|
+
"renderNodeLabel": props.renderNodeLabel,
|
|
33648
|
+
"numerable": props.numerable,
|
|
33649
|
+
"separator": props.separator,
|
|
33650
|
+
"max": props.max,
|
|
33651
|
+
"nullValue": props.nullValue
|
|
33652
|
+
}, null), vue.createVNode("div", {
|
|
33653
|
+
"class": "vc-tree-select__cascader-columns"
|
|
33654
|
+
}, [columns.value.map(columnIndex => {
|
|
33655
|
+
const col = rebuildData.value[columnIndex];
|
|
33656
|
+
if (!col || !col.length) return null;
|
|
33657
|
+
return vue.createVNode("div", {
|
|
33658
|
+
"class": "vc-tree-select__cascader-column",
|
|
33659
|
+
"key": columnIndex
|
|
33660
|
+
}, [vue.createVNode("div", {
|
|
33661
|
+
"class": "vc-tree-select__cascader-column-wrapper"
|
|
33662
|
+
}, [col.map(item => {
|
|
33663
|
+
const state = getNodeState(item);
|
|
33664
|
+
const isSelect = currentValue.value[columnIndex] === item.value;
|
|
33665
|
+
const child = hasChildren(item);
|
|
33666
|
+
return vue.createVNode("div", {
|
|
33667
|
+
"key": item.value,
|
|
33668
|
+
"class": ['vc-tree-select__cascader-item', {
|
|
33669
|
+
'is-select': isSelect
|
|
33670
|
+
}],
|
|
33671
|
+
"onMouseenter": () => handleHover(item.value, columnIndex),
|
|
33672
|
+
"onClick": () => handleLabelClick(!state.checked, item)
|
|
33673
|
+
}, [vue.createVNode("span", {
|
|
33674
|
+
"class": "vc-tree-select__cascader-checkbox",
|
|
33675
|
+
"onClick": e => e.stopPropagation()
|
|
33676
|
+
}, [vue.createVNode(Checkbox, {
|
|
33677
|
+
"modelValue": state.checked,
|
|
33678
|
+
"indeterminate": state.indeterminate,
|
|
33679
|
+
"disabled": !!item.disabled,
|
|
33680
|
+
"onChange": v => handleCheckboxChange(v, item)
|
|
33681
|
+
}, null)]), vue.createVNode("span", {
|
|
33682
|
+
"class": "vc-tree-select__cascader-label"
|
|
33683
|
+
}, [props.renderNodeLabel && treeRef.value?.getNode?.(item) ? vue.createVNode(Customer, {
|
|
33684
|
+
"render": props.renderNodeLabel,
|
|
33685
|
+
"store": treeRef.value.getNode(item),
|
|
33686
|
+
"row": item
|
|
33687
|
+
}, null) : vue.createVNode("span", null, [item.label])]), child ? vue.createVNode(Icon, {
|
|
33688
|
+
"type": "right",
|
|
33689
|
+
"class": "vc-tree-select__cascader-icon"
|
|
33690
|
+
}, null) : null]);
|
|
33691
|
+
})])]);
|
|
33692
|
+
})])]);
|
|
33693
|
+
};
|
|
33694
|
+
}
|
|
33695
|
+
});
|
|
33696
|
+
|
|
32749
33697
|
const treeKeys = [
|
|
32750
33698
|
"checkStrictly",
|
|
32751
33699
|
"data",
|
|
@@ -32754,7 +33702,18 @@ var VcComponents = (function (exports, vue) {
|
|
|
32754
33702
|
];
|
|
32755
33703
|
const props$1 = {
|
|
32756
33704
|
...props$1a,
|
|
32757
|
-
...pick(props$2, treeKeys)
|
|
33705
|
+
...pick(props$2, treeKeys),
|
|
33706
|
+
autoWidth: {
|
|
33707
|
+
type: Boolean,
|
|
33708
|
+
default: void 0
|
|
33709
|
+
},
|
|
33710
|
+
/**
|
|
33711
|
+
* 级联列模式:与 Cascader 相同的 hover 展开下一级,勾选逻辑与树形模式一致
|
|
33712
|
+
*/
|
|
33713
|
+
cascader: {
|
|
33714
|
+
type: Boolean,
|
|
33715
|
+
default: false
|
|
33716
|
+
}
|
|
32758
33717
|
};
|
|
32759
33718
|
|
|
32760
33719
|
/** @jsxImportSource vue */
|
|
@@ -32780,12 +33739,37 @@ var VcComponents = (function (exports, vue) {
|
|
|
32780
33739
|
const searchValue = vue.ref('');
|
|
32781
33740
|
const searchRegex = vue.ref(new RegExp(''));
|
|
32782
33741
|
const currentValue = vue.ref([]);
|
|
33742
|
+
const currentValueGroups = vue.computed(() => {
|
|
33743
|
+
if (props.checkStrictly) return;
|
|
33744
|
+
if (!props.data?.length || !Array.isArray(currentValue.value) || !currentValue.value.length) {
|
|
33745
|
+
return [];
|
|
33746
|
+
}
|
|
33747
|
+
const pathMap = new Map();
|
|
33748
|
+
const traverse = (data, path = []) => {
|
|
33749
|
+
data.forEach(item => {
|
|
33750
|
+
const v = item.value;
|
|
33751
|
+
if (v == null) return;
|
|
33752
|
+
const fullPath = [...path, v];
|
|
33753
|
+
pathMap.set(v, fullPath);
|
|
33754
|
+
if (item.children?.length) traverse(item.children, fullPath);
|
|
33755
|
+
});
|
|
33756
|
+
};
|
|
33757
|
+
traverse(props.data);
|
|
33758
|
+
const allPaths = currentValue.value.map(v => pathMap.get(v)).filter(Boolean);
|
|
33759
|
+
return allPaths.filter(path => !allPaths.some(other => other !== path && other.length > path.length && path.every((v, i) => v === other[i])));
|
|
33760
|
+
});
|
|
32783
33761
|
const source = vue.computed(() => {
|
|
32784
33762
|
return flattenData$1(props.data, {
|
|
32785
33763
|
parent: true,
|
|
32786
33764
|
cascader: true
|
|
32787
33765
|
});
|
|
32788
33766
|
});
|
|
33767
|
+
const labelMap = vue.computed(() => {
|
|
33768
|
+
return source.value.reduce((pre, cur) => {
|
|
33769
|
+
pre[cur.value] = cur.label || '';
|
|
33770
|
+
return pre;
|
|
33771
|
+
}, {});
|
|
33772
|
+
});
|
|
32789
33773
|
const icon = vue.computed(() => {
|
|
32790
33774
|
return isActive.value ? 'up' : 'down';
|
|
32791
33775
|
});
|
|
@@ -32802,17 +33786,34 @@ var VcComponents = (function (exports, vue) {
|
|
|
32802
33786
|
'is-disabled': props.disabled
|
|
32803
33787
|
};
|
|
32804
33788
|
});
|
|
32805
|
-
const
|
|
33789
|
+
const displayTags = vue.computed(() => {
|
|
32806
33790
|
if (!props.data.length) {
|
|
32807
33791
|
return [];
|
|
32808
33792
|
}
|
|
32809
|
-
|
|
33793
|
+
if (props.checkStrictly) {
|
|
33794
|
+
return currentValue.value.map(v => ({
|
|
33795
|
+
value: v,
|
|
33796
|
+
label: labelMap.value[v] || ''
|
|
33797
|
+
}));
|
|
33798
|
+
}
|
|
33799
|
+
return (currentValueGroups.value || []).map(path => {
|
|
33800
|
+
const value = path[path.length - 1];
|
|
33801
|
+
const label = path.map(v => labelMap.value[v] || '').filter(Boolean).join(' / ');
|
|
33802
|
+
return {
|
|
33803
|
+
path,
|
|
33804
|
+
value,
|
|
33805
|
+
label
|
|
33806
|
+
};
|
|
33807
|
+
});
|
|
32810
33808
|
});
|
|
32811
33809
|
const collapseTagCount = vue.computed(() => {
|
|
32812
33810
|
if (!props.maxTags) return 0;
|
|
32813
|
-
const v =
|
|
33811
|
+
const v = displayTags.value.length - props.maxTags;
|
|
32814
33812
|
return v < 0 ? 0 : v;
|
|
32815
33813
|
});
|
|
33814
|
+
const autoWidth = vue.computed(() => {
|
|
33815
|
+
return typeof props.autoWidth === 'boolean' ? props.autoWidth : !!props.cascader;
|
|
33816
|
+
});
|
|
32816
33817
|
|
|
32817
33818
|
/**
|
|
32818
33819
|
* v-model 同步, 外部的数据改变时不会触发
|
|
@@ -32825,8 +33826,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
32825
33826
|
separator: props.separator,
|
|
32826
33827
|
nullValue: props.nullValue
|
|
32827
33828
|
});
|
|
32828
|
-
|
|
32829
|
-
emit('
|
|
33829
|
+
const labels = displayTags.value.map(item => item.label);
|
|
33830
|
+
emit('update:modelValue', v, labels);
|
|
33831
|
+
emit('change', v, labels);
|
|
32830
33832
|
|
|
32831
33833
|
// form表单
|
|
32832
33834
|
formItem?.change?.(currentValue.value);
|
|
@@ -32851,8 +33853,15 @@ var VcComponents = (function (exports, vue) {
|
|
|
32851
33853
|
const close = () => {
|
|
32852
33854
|
isActive.value = false;
|
|
32853
33855
|
};
|
|
32854
|
-
const handleClose =
|
|
32855
|
-
|
|
33856
|
+
const handleClose = item => {
|
|
33857
|
+
if (props.checkStrictly) {
|
|
33858
|
+
const index = currentValue.value.findIndex(v => v === item.value);
|
|
33859
|
+
if (index === -1) return;
|
|
33860
|
+
currentValue.value = currentValue.value.filter((_, i) => i !== index);
|
|
33861
|
+
} else if (item.path) {
|
|
33862
|
+
const remaining = (currentValueGroups.value || []).filter(p => !(p.length === item.path.length && p.every((v, i) => v === item.path[i])));
|
|
33863
|
+
currentValue.value = [...new Set(remaining.flat())];
|
|
33864
|
+
}
|
|
32856
33865
|
sync();
|
|
32857
33866
|
};
|
|
32858
33867
|
const handleClear = e => {
|
|
@@ -32889,6 +33898,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
32889
33898
|
multiple,
|
|
32890
33899
|
isActive,
|
|
32891
33900
|
current: currentValue,
|
|
33901
|
+
currentValueGroups,
|
|
32892
33902
|
// for portal
|
|
32893
33903
|
toggle(v) {
|
|
32894
33904
|
v = typeof v === 'boolean' ? v : !isActive.value;
|
|
@@ -32903,7 +33913,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
32903
33913
|
"trigger": props.trigger,
|
|
32904
33914
|
"tag": props.tag,
|
|
32905
33915
|
"placement": props.placement,
|
|
32906
|
-
"
|
|
33916
|
+
"autoWidth": autoWidth.value,
|
|
32907
33917
|
"disabled": props.disabled,
|
|
32908
33918
|
"portalClass": [['is-padding-none', props.portalClass]],
|
|
32909
33919
|
"class": [classes.value, its.value.class, 'vc-tree-select'],
|
|
@@ -32920,22 +33930,22 @@ var VcComponents = (function (exports, vue) {
|
|
|
32920
33930
|
return vue.createVNode(Input$1, {
|
|
32921
33931
|
"id": props.id,
|
|
32922
33932
|
"disabled": props.disabled,
|
|
32923
|
-
"modelValue":
|
|
33933
|
+
"modelValue": displayTags.value[0]?.label || props.extra,
|
|
32924
33934
|
"allow-dispatch": false,
|
|
32925
33935
|
"class": "vc-tree-select__input",
|
|
32926
33936
|
"readonly": true,
|
|
32927
33937
|
"placeholder": its.value.attrs?.placeholder || '请选择'
|
|
32928
33938
|
}, {
|
|
32929
|
-
content: multiple.value &&
|
|
33939
|
+
content: multiple.value && displayTags.value.length > 0 ? () => {
|
|
32930
33940
|
return vue.createVNode("div", {
|
|
32931
33941
|
"class": [classes.value, 'vc-tree-select__tags']
|
|
32932
|
-
}, [
|
|
33942
|
+
}, [displayTags.value.slice(0, props.maxTags).map(item => {
|
|
32933
33943
|
return vue.createVNode(Tag, {
|
|
32934
|
-
"key": item,
|
|
33944
|
+
"key": item.path ? item.path.join('-') : item.value,
|
|
32935
33945
|
"closable": !props.disabled,
|
|
32936
|
-
"onClose": () => handleClose(
|
|
33946
|
+
"onClose": () => handleClose(item)
|
|
32937
33947
|
}, {
|
|
32938
|
-
default: () => [
|
|
33948
|
+
default: () => [item.label]
|
|
32939
33949
|
});
|
|
32940
33950
|
}), collapseTagCount.value ? vue.createVNode(Tag, null, {
|
|
32941
33951
|
default: () => [`+${collapseTagCount.value}...`]
|
|
@@ -32968,16 +33978,23 @@ var VcComponents = (function (exports, vue) {
|
|
|
32968
33978
|
}, [vue.createVNode(Spin, {
|
|
32969
33979
|
"size": 16
|
|
32970
33980
|
}, null)]), vue.createVNode(Scroller, {
|
|
32971
|
-
"class":
|
|
33981
|
+
"class": ['vc-tree-select__options', props.cascader && 'is-cascader'],
|
|
32972
33982
|
"max-height": "200px"
|
|
32973
33983
|
}, {
|
|
32974
|
-
default: () => [vue.createVNode(
|
|
32975
|
-
"
|
|
32976
|
-
"
|
|
33984
|
+
default: () => [props.cascader ? vue.createVNode(TreeSelectContentCascader, {
|
|
33985
|
+
"value": currentValue.value,
|
|
33986
|
+
"data": props.data,
|
|
33987
|
+
"checkStrictly": props.checkStrictly,
|
|
33988
|
+
"renderNodeLabel": props.renderNodeLabel,
|
|
33989
|
+
"numerable": props.numerable,
|
|
33990
|
+
"separator": props.separator,
|
|
33991
|
+
"max": props.max,
|
|
33992
|
+
"nullValue": props.nullValue,
|
|
33993
|
+
"onChange": handleChange
|
|
33994
|
+
}, null) : vue.createVNode(TreeSelectContent, {
|
|
33995
|
+
"value": currentValue.value,
|
|
32977
33996
|
"data": props.data,
|
|
32978
33997
|
"checkStrictly": props.checkStrictly,
|
|
32979
|
-
"allowDispatch": false,
|
|
32980
|
-
"showCheckbox": true,
|
|
32981
33998
|
"renderNodeLabel": props.renderNodeLabel,
|
|
32982
33999
|
"onChange": handleChange
|
|
32983
34000
|
}, null)]
|
|
@@ -139705,6 +140722,7 @@ ${r}
|
|
|
139705
140722
|
exports.Calendar = Calendar$1;
|
|
139706
140723
|
exports.Card = Card;
|
|
139707
140724
|
exports.Carousel = Carousel;
|
|
140725
|
+
exports.CarouselItem = CarouselItem;
|
|
139708
140726
|
exports.Cascader = Cascader;
|
|
139709
140727
|
exports.Chart = Chart;
|
|
139710
140728
|
exports.Checkbox = Checkbox;
|
|
@@ -139750,6 +140768,7 @@ ${r}
|
|
|
139750
140768
|
exports.MCalendar = MCalendar;
|
|
139751
140769
|
exports.MCard = MCard;
|
|
139752
140770
|
exports.MCarousel = MCarousel;
|
|
140771
|
+
exports.MCarouselItem = MCarouselItem;
|
|
139753
140772
|
exports.MCascader = MCascader;
|
|
139754
140773
|
exports.MChart = MChart;
|
|
139755
140774
|
exports.MCheckbox = MCheckbox;
|