@deot/vc-components 1.0.15 → 1.0.17
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 +824 -480
- package/dist/index.d.ts +230 -22
- package/dist/index.iife.js +822 -478
- package/dist/index.js +825 -481
- package/dist/index.style.css +1 -1
- package/dist/index.umd.cjs +822 -478
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -54,6 +54,17 @@ const VARIABLES = {};
|
|
|
54
54
|
const defaults$1 = {
|
|
55
55
|
Theme: {
|
|
56
56
|
variables: VARIABLES
|
|
57
|
+
},
|
|
58
|
+
Portal: {
|
|
59
|
+
install: void 0
|
|
60
|
+
},
|
|
61
|
+
Upload: {
|
|
62
|
+
onRequest: void 0,
|
|
63
|
+
onResponse: void 0,
|
|
64
|
+
onMessage: void 0
|
|
65
|
+
},
|
|
66
|
+
TableColumn: {
|
|
67
|
+
line: void 0
|
|
57
68
|
}
|
|
58
69
|
};
|
|
59
70
|
|
|
@@ -91,9 +102,9 @@ const props$1q = {
|
|
|
91
102
|
|
|
92
103
|
/** @jsxImportSource vue */
|
|
93
104
|
|
|
94
|
-
const COMPONENT_NAME$
|
|
105
|
+
const COMPONENT_NAME$1$ = 'vc-action-sheet';
|
|
95
106
|
const ActionSheet = /* @__PURE__ */ vue.defineComponent({
|
|
96
|
-
name: COMPONENT_NAME$
|
|
107
|
+
name: COMPONENT_NAME$1$,
|
|
97
108
|
props: props$1q,
|
|
98
109
|
setup(props, {
|
|
99
110
|
slots
|
|
@@ -280,9 +291,9 @@ const IconManager = new Manager();
|
|
|
280
291
|
|
|
281
292
|
/** @jsxImportSource vue */
|
|
282
293
|
|
|
283
|
-
const COMPONENT_NAME$
|
|
294
|
+
const COMPONENT_NAME$1_ = 'vc-icon';
|
|
284
295
|
const Icon = /* @__PURE__ */ vue.defineComponent({
|
|
285
|
-
name: COMPONENT_NAME$
|
|
296
|
+
name: COMPONENT_NAME$1_,
|
|
286
297
|
props: props$1o,
|
|
287
298
|
setup(props) {
|
|
288
299
|
const viewBox = vue.ref('0 0 1024 1024');
|
|
@@ -481,9 +492,9 @@ const useTransition = () => {
|
|
|
481
492
|
};
|
|
482
493
|
};
|
|
483
494
|
|
|
484
|
-
const COMPONENT_NAME$
|
|
495
|
+
const COMPONENT_NAME$1Z = "vc-transition";
|
|
485
496
|
const Transition = vue.defineComponent({
|
|
486
|
-
name: COMPONENT_NAME$
|
|
497
|
+
name: COMPONENT_NAME$1Z,
|
|
487
498
|
props: props$1n,
|
|
488
499
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
489
500
|
inheritAttrs: false,
|
|
@@ -504,9 +515,9 @@ const Transition = vue.defineComponent({
|
|
|
504
515
|
}
|
|
505
516
|
});
|
|
506
517
|
|
|
507
|
-
const COMPONENT_NAME$
|
|
518
|
+
const COMPONENT_NAME$1Y = "vc-transition-collapse";
|
|
508
519
|
const TransitionCollapse = vue.defineComponent({
|
|
509
|
-
name: COMPONENT_NAME$
|
|
520
|
+
name: COMPONENT_NAME$1Y,
|
|
510
521
|
props: props$1n,
|
|
511
522
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
512
523
|
inheritAttrs: false,
|
|
@@ -625,9 +636,9 @@ const TransitionCollapse = vue.defineComponent({
|
|
|
625
636
|
}
|
|
626
637
|
});
|
|
627
638
|
|
|
628
|
-
const COMPONENT_NAME$
|
|
639
|
+
const COMPONENT_NAME$1X = "vc-transition-fade";
|
|
629
640
|
const TransitionFade = vue.defineComponent({
|
|
630
|
-
name: COMPONENT_NAME$
|
|
641
|
+
name: COMPONENT_NAME$1X,
|
|
631
642
|
props: {
|
|
632
643
|
...props$1n,
|
|
633
644
|
// inheritAttrs必须是false
|
|
@@ -662,9 +673,9 @@ const TransitionFade = vue.defineComponent({
|
|
|
662
673
|
}
|
|
663
674
|
});
|
|
664
675
|
|
|
665
|
-
const COMPONENT_NAME$
|
|
676
|
+
const COMPONENT_NAME$1W = "vc-transition-scale";
|
|
666
677
|
const TransitionScale = vue.defineComponent({
|
|
667
|
-
name: COMPONENT_NAME$
|
|
678
|
+
name: COMPONENT_NAME$1W,
|
|
668
679
|
props: {
|
|
669
680
|
...props$1n,
|
|
670
681
|
mode: {
|
|
@@ -704,9 +715,9 @@ const TransitionScale = vue.defineComponent({
|
|
|
704
715
|
}
|
|
705
716
|
});
|
|
706
717
|
|
|
707
|
-
const COMPONENT_NAME$
|
|
718
|
+
const COMPONENT_NAME$1V = "vc-transition-slide";
|
|
708
719
|
const TransitionSlide = vue.defineComponent({
|
|
709
|
-
name: COMPONENT_NAME$
|
|
720
|
+
name: COMPONENT_NAME$1V,
|
|
710
721
|
props: {
|
|
711
722
|
...props$1n,
|
|
712
723
|
mode: {
|
|
@@ -746,9 +757,9 @@ const TransitionSlide = vue.defineComponent({
|
|
|
746
757
|
}
|
|
747
758
|
});
|
|
748
759
|
|
|
749
|
-
const COMPONENT_NAME$
|
|
760
|
+
const COMPONENT_NAME$1U = "vc-transition-zoom";
|
|
750
761
|
const TransitionZoom = vue.defineComponent({
|
|
751
|
-
name: COMPONENT_NAME$
|
|
762
|
+
name: COMPONENT_NAME$1U,
|
|
752
763
|
props: {
|
|
753
764
|
...props$1n,
|
|
754
765
|
mode: {
|
|
@@ -790,7 +801,7 @@ const TransitionZoom = vue.defineComponent({
|
|
|
790
801
|
|
|
791
802
|
/** @jsxImportSource vue */
|
|
792
803
|
|
|
793
|
-
const COMPONENT_NAME$
|
|
804
|
+
const COMPONENT_NAME$1T = 'vc-alert';
|
|
794
805
|
|
|
795
806
|
// [color, borderColor, backgroundColor], -> CSS
|
|
796
807
|
const THEME_MAP = {
|
|
@@ -800,7 +811,7 @@ const THEME_MAP = {
|
|
|
800
811
|
warning: ['#ffbf00', '#ffe58f', '#fffbe6']
|
|
801
812
|
};
|
|
802
813
|
const Alert = /* @__PURE__ */ vue.defineComponent({
|
|
803
|
-
name: COMPONENT_NAME$
|
|
814
|
+
name: COMPONENT_NAME$1T,
|
|
804
815
|
props: props$1p,
|
|
805
816
|
setup(props, {
|
|
806
817
|
slots,
|
|
@@ -899,9 +910,9 @@ const props$1m = {
|
|
|
899
910
|
|
|
900
911
|
/** @jsxImportSource vue */
|
|
901
912
|
|
|
902
|
-
const COMPONENT_NAME$
|
|
913
|
+
const COMPONENT_NAME$1S = 'vc-artboard';
|
|
903
914
|
const Artboard = /* @__PURE__ */ vue.defineComponent({
|
|
904
|
-
name: COMPONENT_NAME$
|
|
915
|
+
name: COMPONENT_NAME$1S,
|
|
905
916
|
props: props$1m,
|
|
906
917
|
setup(props, {
|
|
907
918
|
slots
|
|
@@ -940,9 +951,9 @@ const props$1l = {
|
|
|
940
951
|
|
|
941
952
|
/** @jsxImportSource vue */
|
|
942
953
|
|
|
943
|
-
const COMPONENT_NAME$
|
|
954
|
+
const COMPONENT_NAME$1R = 'vc-spin';
|
|
944
955
|
const Spin = /* @__PURE__ */ vue.defineComponent({
|
|
945
|
-
name: COMPONENT_NAME$
|
|
956
|
+
name: COMPONENT_NAME$1R,
|
|
946
957
|
props: props$1l,
|
|
947
958
|
setup(props, {
|
|
948
959
|
slots
|
|
@@ -993,9 +1004,9 @@ const props$1k = {
|
|
|
993
1004
|
exclude: RegExp
|
|
994
1005
|
};
|
|
995
1006
|
|
|
996
|
-
const COMPONENT_NAME$
|
|
1007
|
+
const COMPONENT_NAME$1Q = "vc-debounce";
|
|
997
1008
|
const Debounce = vue.defineComponent({
|
|
998
|
-
name: COMPONENT_NAME$
|
|
1009
|
+
name: COMPONENT_NAME$1Q,
|
|
999
1010
|
props: props$1k,
|
|
1000
1011
|
/**
|
|
1001
1012
|
* 不声明emits使得事件被透传放入attrs中, 这样可以让所有的事件透传
|
|
@@ -1067,9 +1078,9 @@ const props$1j = {
|
|
|
1067
1078
|
|
|
1068
1079
|
/** @jsxImportSource vue */
|
|
1069
1080
|
|
|
1070
|
-
const COMPONENT_NAME$
|
|
1081
|
+
const COMPONENT_NAME$1P = 'vc-button';
|
|
1071
1082
|
const Button = /* @__PURE__ */ vue.defineComponent({
|
|
1072
|
-
name: COMPONENT_NAME$
|
|
1083
|
+
name: COMPONENT_NAME$1P,
|
|
1073
1084
|
emits: ['click'],
|
|
1074
1085
|
props: props$1j,
|
|
1075
1086
|
setup(props, {
|
|
@@ -1149,9 +1160,9 @@ const props$1i = {
|
|
|
1149
1160
|
|
|
1150
1161
|
/** @jsxImportSource vue */
|
|
1151
1162
|
|
|
1152
|
-
const COMPONENT_NAME$
|
|
1163
|
+
const COMPONENT_NAME$1O = 'vc-button-group';
|
|
1153
1164
|
const ButtonGroup = /* @__PURE__ */ vue.defineComponent({
|
|
1154
|
-
name: COMPONENT_NAME$
|
|
1165
|
+
name: COMPONENT_NAME$1O,
|
|
1155
1166
|
props: props$1i,
|
|
1156
1167
|
setup(props, {
|
|
1157
1168
|
slots
|
|
@@ -1185,9 +1196,9 @@ const props$1h = {
|
|
|
1185
1196
|
|
|
1186
1197
|
/** @jsxImportSource vue */
|
|
1187
1198
|
|
|
1188
|
-
const COMPONENT_NAME$
|
|
1199
|
+
const COMPONENT_NAME$1N = 'vc-calendar';
|
|
1189
1200
|
const Calendar = /* @__PURE__ */ vue.defineComponent({
|
|
1190
|
-
name: COMPONENT_NAME$
|
|
1201
|
+
name: COMPONENT_NAME$1N,
|
|
1191
1202
|
props: props$1h,
|
|
1192
1203
|
setup(props, {
|
|
1193
1204
|
slots
|
|
@@ -1225,9 +1236,9 @@ const props$1g = {
|
|
|
1225
1236
|
|
|
1226
1237
|
/** @jsxImportSource vue */
|
|
1227
1238
|
|
|
1228
|
-
const COMPONENT_NAME$
|
|
1239
|
+
const COMPONENT_NAME$1M = 'vc-card';
|
|
1229
1240
|
const Card = /* @__PURE__ */ vue.defineComponent({
|
|
1230
|
-
name: COMPONENT_NAME$
|
|
1241
|
+
name: COMPONENT_NAME$1M,
|
|
1231
1242
|
props: props$1g,
|
|
1232
1243
|
setup(props, {
|
|
1233
1244
|
slots
|
|
@@ -1263,9 +1274,9 @@ const props$1f = {
|
|
|
1263
1274
|
|
|
1264
1275
|
/** @jsxImportSource vue */
|
|
1265
1276
|
|
|
1266
|
-
const COMPONENT_NAME$
|
|
1277
|
+
const COMPONENT_NAME$1L = 'vc-carousel';
|
|
1267
1278
|
const Carousel = /* @__PURE__ */ vue.defineComponent({
|
|
1268
|
-
name: COMPONENT_NAME$
|
|
1279
|
+
name: COMPONENT_NAME$1L,
|
|
1269
1280
|
props: props$1f,
|
|
1270
1281
|
setup(props, {
|
|
1271
1282
|
slots
|
|
@@ -1289,9 +1300,9 @@ const props$1e = {
|
|
|
1289
1300
|
|
|
1290
1301
|
/** @jsxImportSource vue */
|
|
1291
1302
|
|
|
1292
|
-
const COMPONENT_NAME$
|
|
1303
|
+
const COMPONENT_NAME$1K = 'vc-cascader';
|
|
1293
1304
|
const Cascader = /* @__PURE__ */ vue.defineComponent({
|
|
1294
|
-
name: COMPONENT_NAME$
|
|
1305
|
+
name: COMPONENT_NAME$1K,
|
|
1295
1306
|
props: props$1e,
|
|
1296
1307
|
setup(props, {
|
|
1297
1308
|
slots
|
|
@@ -1360,9 +1371,9 @@ const props$1d = {
|
|
|
1360
1371
|
|
|
1361
1372
|
/** @jsxImportSource vue */
|
|
1362
1373
|
|
|
1363
|
-
const COMPONENT_NAME$
|
|
1374
|
+
const COMPONENT_NAME$1J = 'vc-chart';
|
|
1364
1375
|
const Chart = /* @__PURE__ */ vue.defineComponent({
|
|
1365
|
-
name: COMPONENT_NAME$
|
|
1376
|
+
name: COMPONENT_NAME$1J,
|
|
1366
1377
|
props: props$1d,
|
|
1367
1378
|
emits: [...EVENTS, 'ready'],
|
|
1368
1379
|
setup(props, {
|
|
@@ -1593,9 +1604,9 @@ const useCheckbox = () => {
|
|
|
1593
1604
|
|
|
1594
1605
|
/** @jsxImportSource vue */
|
|
1595
1606
|
|
|
1596
|
-
const COMPONENT_NAME$
|
|
1607
|
+
const COMPONENT_NAME$1I = 'vc-checkbox';
|
|
1597
1608
|
const Checkbox = /* @__PURE__ */ vue.defineComponent({
|
|
1598
|
-
name: COMPONENT_NAME$
|
|
1609
|
+
name: COMPONENT_NAME$1I,
|
|
1599
1610
|
props: props$1c,
|
|
1600
1611
|
emits: ['update:modelValue', 'change'],
|
|
1601
1612
|
setup(props, {
|
|
@@ -1682,9 +1693,9 @@ const useCheckboxGroup = () => {
|
|
|
1682
1693
|
|
|
1683
1694
|
/** @jsxImportSource vue */
|
|
1684
1695
|
|
|
1685
|
-
const COMPONENT_NAME$
|
|
1696
|
+
const COMPONENT_NAME$1H = 'vc-checkbox-group';
|
|
1686
1697
|
const CheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
1687
|
-
name: COMPONENT_NAME$
|
|
1698
|
+
name: COMPONENT_NAME$1H,
|
|
1688
1699
|
props: props$1b,
|
|
1689
1700
|
emits: ['update:modelValue', 'change'],
|
|
1690
1701
|
setup(props, {
|
|
@@ -1702,9 +1713,9 @@ const CheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
|
1702
1713
|
|
|
1703
1714
|
/** @jsxImportSource vue */
|
|
1704
1715
|
|
|
1705
|
-
const COMPONENT_NAME$
|
|
1716
|
+
const COMPONENT_NAME$1G = 'vcm-checkbox';
|
|
1706
1717
|
const MCheckbox = /* @__PURE__ */ vue.defineComponent({
|
|
1707
|
-
name: COMPONENT_NAME$
|
|
1718
|
+
name: COMPONENT_NAME$1G,
|
|
1708
1719
|
props: props$1c,
|
|
1709
1720
|
emits: ['update:modelValue', 'change'],
|
|
1710
1721
|
setup(props, {
|
|
@@ -1744,9 +1755,9 @@ const MCheckbox = /* @__PURE__ */ vue.defineComponent({
|
|
|
1744
1755
|
|
|
1745
1756
|
/** @jsxImportSource vue */
|
|
1746
1757
|
|
|
1747
|
-
const COMPONENT_NAME$
|
|
1758
|
+
const COMPONENT_NAME$1F = 'vcm-checkbox-group';
|
|
1748
1759
|
const MCheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
1749
|
-
name: COMPONENT_NAME$
|
|
1760
|
+
name: COMPONENT_NAME$1F,
|
|
1750
1761
|
props: props$1b,
|
|
1751
1762
|
emits: ['update:modelValue', 'change'],
|
|
1752
1763
|
setup(props, {
|
|
@@ -1805,9 +1816,9 @@ const props$19 = {
|
|
|
1805
1816
|
}
|
|
1806
1817
|
};
|
|
1807
1818
|
|
|
1808
|
-
const COMPONENT_NAME$
|
|
1819
|
+
const COMPONENT_NAME$1E = "vc-customer";
|
|
1809
1820
|
const Customer = vue.defineComponent({
|
|
1810
|
-
name: COMPONENT_NAME$
|
|
1821
|
+
name: COMPONENT_NAME$1E,
|
|
1811
1822
|
props: props$19,
|
|
1812
1823
|
setup(props, context) {
|
|
1813
1824
|
return () => vue.h(() => {
|
|
@@ -1818,9 +1829,9 @@ const Customer = vue.defineComponent({
|
|
|
1818
1829
|
|
|
1819
1830
|
/** @jsxImportSource vue */
|
|
1820
1831
|
|
|
1821
|
-
const COMPONENT_NAME$
|
|
1832
|
+
const COMPONENT_NAME$1D = 'vc-message';
|
|
1822
1833
|
const MessageView = /* @__PURE__ */ vue.defineComponent({
|
|
1823
|
-
name: COMPONENT_NAME$
|
|
1834
|
+
name: COMPONENT_NAME$1D,
|
|
1824
1835
|
emits: ['before-close', 'close', 'portal-fulfilled'],
|
|
1825
1836
|
props: props$1a,
|
|
1826
1837
|
setup(props, {
|
|
@@ -1967,7 +1978,7 @@ class PortalLeaf {
|
|
|
1967
1978
|
}
|
|
1968
1979
|
}
|
|
1969
1980
|
|
|
1970
|
-
const COMPONENT_NAME$
|
|
1981
|
+
const COMPONENT_NAME$1C = "vc-portal";
|
|
1971
1982
|
class Portal {
|
|
1972
1983
|
/**
|
|
1973
1984
|
* 清理Portals类型组件
|
|
@@ -2019,7 +2030,7 @@ class Portal {
|
|
|
2019
2030
|
this.wrapper = wrapper;
|
|
2020
2031
|
this.globalOptions = {
|
|
2021
2032
|
...options,
|
|
2022
|
-
name: options?.name || wrapper.name || Utils__namespace.getUid(COMPONENT_NAME$
|
|
2033
|
+
name: options?.name || wrapper.name || Utils__namespace.getUid(COMPONENT_NAME$1C)
|
|
2023
2034
|
};
|
|
2024
2035
|
}
|
|
2025
2036
|
popup(propsData, options) {
|
|
@@ -2118,7 +2129,7 @@ class Portal {
|
|
|
2118
2129
|
...rest
|
|
2119
2130
|
} = options;
|
|
2120
2131
|
let useAllNodes = fragment;
|
|
2121
|
-
const name = multiple ? `${name$}__${Utils__namespace.getUid(COMPONENT_NAME$
|
|
2132
|
+
const name = multiple ? `${name$}__${Utils__namespace.getUid(COMPONENT_NAME$1C)}` : name$;
|
|
2122
2133
|
const container = document.createElement(tag);
|
|
2123
2134
|
const root = typeof el === "object" ? el : document.querySelector(el || "body");
|
|
2124
2135
|
!alive && Portal.leafs.get(name)?.destroy();
|
|
@@ -2152,7 +2163,7 @@ class Portal {
|
|
|
2152
2163
|
} else {
|
|
2153
2164
|
const wrapper = this.wrapper;
|
|
2154
2165
|
const app = vue.createApp({
|
|
2155
|
-
name: COMPONENT_NAME$
|
|
2166
|
+
name: COMPONENT_NAME$1C,
|
|
2156
2167
|
parent,
|
|
2157
2168
|
setup() {
|
|
2158
2169
|
if (alive) {
|
|
@@ -2264,13 +2275,13 @@ const props$18 = {
|
|
|
2264
2275
|
}
|
|
2265
2276
|
};
|
|
2266
2277
|
|
|
2267
|
-
const COMPONENT_NAME$
|
|
2278
|
+
const COMPONENT_NAME$1B = 'vc-portal-view';
|
|
2268
2279
|
|
|
2269
2280
|
/**
|
|
2270
2281
|
* 写法不同,但与vue@2.x 保持一致
|
|
2271
2282
|
*/
|
|
2272
2283
|
const PortalView = /* @__PURE__ */ vue.defineComponent({
|
|
2273
|
-
name: COMPONENT_NAME$
|
|
2284
|
+
name: COMPONENT_NAME$1B,
|
|
2274
2285
|
props: props$18,
|
|
2275
2286
|
setup(props, {
|
|
2276
2287
|
slots
|
|
@@ -2441,9 +2452,9 @@ const useClipboard = (done) => {
|
|
|
2441
2452
|
return () => vue.h(props.tag, { onClick: handleClick, class: "vc-clipboard" }, slots?.default?.());
|
|
2442
2453
|
};
|
|
2443
2454
|
|
|
2444
|
-
const COMPONENT_NAME$
|
|
2455
|
+
const COMPONENT_NAME$1A = "vc-clipboard";
|
|
2445
2456
|
const Clipboard$1 = vue.defineComponent({
|
|
2446
|
-
name: COMPONENT_NAME$
|
|
2457
|
+
name: COMPONENT_NAME$1A,
|
|
2447
2458
|
props: props$17,
|
|
2448
2459
|
setup() {
|
|
2449
2460
|
return useClipboard((content) => Message.success({ content }));
|
|
@@ -2483,9 +2494,9 @@ const MTransitionZoom = TransitionZoom;
|
|
|
2483
2494
|
|
|
2484
2495
|
/** @jsxImportSource vue */
|
|
2485
2496
|
|
|
2486
|
-
const COMPONENT_NAME$
|
|
2497
|
+
const COMPONENT_NAME$1z = 'vcm-toast';
|
|
2487
2498
|
const MToastView = /* @__PURE__ */ vue.defineComponent({
|
|
2488
|
-
name: COMPONENT_NAME$
|
|
2499
|
+
name: COMPONENT_NAME$1z,
|
|
2489
2500
|
emits: ['close', 'portal-fulfilled'],
|
|
2490
2501
|
props: props$16,
|
|
2491
2502
|
setup(props, {
|
|
@@ -2587,9 +2598,9 @@ const warning$2 = create$3({ mode: "warning" });
|
|
|
2587
2598
|
const error$2 = create$3({ mode: "error" });
|
|
2588
2599
|
const MToast = Object.assign(MToastView, { destroy: destroy$4, info: info$2, success: success$2, loading, warning: warning$2, error: error$2 });
|
|
2589
2600
|
|
|
2590
|
-
const COMPONENT_NAME$
|
|
2601
|
+
const COMPONENT_NAME$1y = "vcm-clipboard";
|
|
2591
2602
|
const MClipboard$1 = vue.defineComponent({
|
|
2592
|
-
name: COMPONENT_NAME$
|
|
2603
|
+
name: COMPONENT_NAME$1y,
|
|
2593
2604
|
props: props$17,
|
|
2594
2605
|
setup() {
|
|
2595
2606
|
return useClipboard((content) => MToast.info({ content }));
|
|
@@ -2621,9 +2632,9 @@ const props$15 = {
|
|
|
2621
2632
|
}
|
|
2622
2633
|
};
|
|
2623
2634
|
|
|
2624
|
-
const COMPONENT_NAME$
|
|
2635
|
+
const COMPONENT_NAME$1x = "vc-collapse";
|
|
2625
2636
|
const Collapse = vue.defineComponent({
|
|
2626
|
-
name: COMPONENT_NAME$
|
|
2637
|
+
name: COMPONENT_NAME$1x,
|
|
2627
2638
|
props: props$15,
|
|
2628
2639
|
emits: ["update:moodelValue", "change"],
|
|
2629
2640
|
setup(props, { slots, emit }) {
|
|
@@ -2740,9 +2751,9 @@ const props$13 = {
|
|
|
2740
2751
|
function _isSlot$3(s) {
|
|
2741
2752
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
2742
2753
|
}
|
|
2743
|
-
const COMPONENT_NAME$
|
|
2754
|
+
const COMPONENT_NAME$1w = 'vc-expand';
|
|
2744
2755
|
const Expand$1 = /* @__PURE__ */ vue.defineComponent({
|
|
2745
|
-
name: COMPONENT_NAME$
|
|
2756
|
+
name: COMPONENT_NAME$1w,
|
|
2746
2757
|
props: props$13,
|
|
2747
2758
|
setup(props, {
|
|
2748
2759
|
slots
|
|
@@ -2772,9 +2783,9 @@ const Expand$1 = /* @__PURE__ */ vue.defineComponent({
|
|
|
2772
2783
|
|
|
2773
2784
|
/** @jsxImportSource vue */
|
|
2774
2785
|
|
|
2775
|
-
const COMPONENT_NAME$
|
|
2786
|
+
const COMPONENT_NAME$1v = 'vc-collapse-item';
|
|
2776
2787
|
const CollapseItem = /* @__PURE__ */ vue.defineComponent({
|
|
2777
|
-
name: COMPONENT_NAME$
|
|
2788
|
+
name: COMPONENT_NAME$1v,
|
|
2778
2789
|
props: props$14,
|
|
2779
2790
|
setup(props, {
|
|
2780
2791
|
slots,
|
|
@@ -2849,9 +2860,9 @@ const props$12 = {
|
|
|
2849
2860
|
|
|
2850
2861
|
/** @jsxImportSource vue */
|
|
2851
2862
|
|
|
2852
|
-
const COMPONENT_NAME$
|
|
2863
|
+
const COMPONENT_NAME$1u = 'vc-color-picker';
|
|
2853
2864
|
const ColorPicker = /* @__PURE__ */ vue.defineComponent({
|
|
2854
|
-
name: COMPONENT_NAME$
|
|
2865
|
+
name: COMPONENT_NAME$1u,
|
|
2855
2866
|
props: props$12,
|
|
2856
2867
|
setup(props, {
|
|
2857
2868
|
slots
|
|
@@ -2875,9 +2886,9 @@ const props$11 = {
|
|
|
2875
2886
|
|
|
2876
2887
|
/** @jsxImportSource vue */
|
|
2877
2888
|
|
|
2878
|
-
const COMPONENT_NAME$
|
|
2889
|
+
const COMPONENT_NAME$1t = 'vc-countdown';
|
|
2879
2890
|
const Countdown = /* @__PURE__ */ vue.defineComponent({
|
|
2880
|
-
name: COMPONENT_NAME$
|
|
2891
|
+
name: COMPONENT_NAME$1t,
|
|
2881
2892
|
props: props$11,
|
|
2882
2893
|
setup(props, {
|
|
2883
2894
|
slots
|
|
@@ -3030,7 +3041,7 @@ const props$_ = {
|
|
|
3030
3041
|
hover: Boolean,
|
|
3031
3042
|
always: Boolean,
|
|
3032
3043
|
portalClass: [Object, String, Array],
|
|
3033
|
-
portalStyle: Object
|
|
3044
|
+
portalStyle: [Object, String]
|
|
3034
3045
|
};
|
|
3035
3046
|
|
|
3036
3047
|
const wrapperKeys = [
|
|
@@ -3068,7 +3079,7 @@ const props$Z = {
|
|
|
3068
3079
|
...lodashEs.pick(props$_, wrapperKeys)
|
|
3069
3080
|
};
|
|
3070
3081
|
|
|
3071
|
-
const inputKeys$
|
|
3082
|
+
const inputKeys$2 = [
|
|
3072
3083
|
"id",
|
|
3073
3084
|
"disabled"
|
|
3074
3085
|
];
|
|
@@ -3078,7 +3089,7 @@ const popoverKeys$1 = [
|
|
|
3078
3089
|
];
|
|
3079
3090
|
const props$Y = {
|
|
3080
3091
|
...lodashEs.pick(props$Z, popoverKeys$1),
|
|
3081
|
-
...lodashEs.pick(props$$, inputKeys$
|
|
3092
|
+
...lodashEs.pick(props$$, inputKeys$2),
|
|
3082
3093
|
type: String,
|
|
3083
3094
|
placeholder: String,
|
|
3084
3095
|
clearable: {
|
|
@@ -3326,9 +3337,9 @@ const useNativeEmitter = (input, expose) => {
|
|
|
3326
3337
|
|
|
3327
3338
|
/** @jsxImportSource vue */
|
|
3328
3339
|
|
|
3329
|
-
const COMPONENT_NAME$
|
|
3340
|
+
const COMPONENT_NAME$1s = 'vc-input';
|
|
3330
3341
|
const Input = /* @__PURE__ */ vue.defineComponent({
|
|
3331
|
-
name: COMPONENT_NAME$
|
|
3342
|
+
name: COMPONENT_NAME$1s,
|
|
3332
3343
|
inheritAttrs: false,
|
|
3333
3344
|
props: {
|
|
3334
3345
|
...props$$,
|
|
@@ -3662,9 +3673,9 @@ const useInputNumber = () => {
|
|
|
3662
3673
|
|
|
3663
3674
|
/** @jsxImportSource vue */
|
|
3664
3675
|
|
|
3665
|
-
const COMPONENT_NAME$
|
|
3676
|
+
const COMPONENT_NAME$1r = 'vc-input-number';
|
|
3666
3677
|
const InputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
3667
|
-
name: COMPONENT_NAME$
|
|
3678
|
+
name: COMPONENT_NAME$1r,
|
|
3668
3679
|
props: props$X,
|
|
3669
3680
|
inheritAttrs: false,
|
|
3670
3681
|
setup(props, {
|
|
@@ -3728,9 +3739,9 @@ const props$W = {
|
|
|
3728
3739
|
|
|
3729
3740
|
/** @jsxImportSource vue */
|
|
3730
3741
|
|
|
3731
|
-
const COMPONENT_NAME$
|
|
3742
|
+
const COMPONENT_NAME$1q = 'vc-input-search';
|
|
3732
3743
|
const InputSearch = /* @__PURE__ */ vue.defineComponent({
|
|
3733
|
-
name: COMPONENT_NAME$
|
|
3744
|
+
name: COMPONENT_NAME$1q,
|
|
3734
3745
|
props: props$W,
|
|
3735
3746
|
inheritAttrs: false,
|
|
3736
3747
|
setup(props, {
|
|
@@ -4021,9 +4032,9 @@ const usePos = () => {
|
|
|
4021
4032
|
function _isSlot$2(s) {
|
|
4022
4033
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
4023
4034
|
}
|
|
4024
|
-
const COMPONENT_NAME$
|
|
4035
|
+
const COMPONENT_NAME$1p = 'vc-popover-wrapper';
|
|
4025
4036
|
const PopoverWrapper = /* @__PURE__ */ vue.defineComponent({
|
|
4026
|
-
name: COMPONENT_NAME$
|
|
4037
|
+
name: COMPONENT_NAME$1p,
|
|
4027
4038
|
props: props$_,
|
|
4028
4039
|
emits: ['portal-fulfilled', 'close'],
|
|
4029
4040
|
setup(props, {
|
|
@@ -4275,9 +4286,9 @@ const PopoverPortal = new Portal(PopoverWrapper);
|
|
|
4275
4286
|
|
|
4276
4287
|
/** @jsxImportSource vue */
|
|
4277
4288
|
|
|
4278
|
-
const COMPONENT_NAME$
|
|
4289
|
+
const COMPONENT_NAME$1o = 'vc-popover';
|
|
4279
4290
|
const Popover$1 = /* @__PURE__ */ vue.defineComponent({
|
|
4280
|
-
name: COMPONENT_NAME$
|
|
4291
|
+
name: COMPONENT_NAME$1o,
|
|
4281
4292
|
props: props$Z,
|
|
4282
4293
|
emits: ['update:modelValue', 'visible-change', 'ready', 'close'],
|
|
4283
4294
|
setup(props, {
|
|
@@ -5378,9 +5389,9 @@ const getTimeType = type => {
|
|
|
5378
5389
|
}
|
|
5379
5390
|
return view;
|
|
5380
5391
|
};
|
|
5381
|
-
const COMPONENT_NAME$
|
|
5392
|
+
const COMPONENT_NAME$1n = 'vc-date-confirm';
|
|
5382
5393
|
const Confirm = /* @__PURE__ */ vue.defineComponent({
|
|
5383
|
-
name: COMPONENT_NAME$
|
|
5394
|
+
name: COMPONENT_NAME$1n,
|
|
5384
5395
|
props: {
|
|
5385
5396
|
showTime: {
|
|
5386
5397
|
type: Boolean,
|
|
@@ -5444,9 +5455,9 @@ const Confirm = /* @__PURE__ */ vue.defineComponent({
|
|
|
5444
5455
|
|
|
5445
5456
|
/** @jsxImportSource vue */
|
|
5446
5457
|
|
|
5447
|
-
const COMPONENT_NAME$
|
|
5458
|
+
const COMPONENT_NAME$1m = 'vc-date-header';
|
|
5448
5459
|
const DateHeader = /* @__PURE__ */ vue.defineComponent({
|
|
5449
|
-
name: COMPONENT_NAME$
|
|
5460
|
+
name: COMPONENT_NAME$1m,
|
|
5450
5461
|
props: {
|
|
5451
5462
|
panelDate: Date,
|
|
5452
5463
|
showNext: {
|
|
@@ -5530,9 +5541,9 @@ const DateHeader = /* @__PURE__ */ vue.defineComponent({
|
|
|
5530
5541
|
|
|
5531
5542
|
/** @jsxImportSource vue */
|
|
5532
5543
|
|
|
5533
|
-
const COMPONENT_NAME$
|
|
5544
|
+
const COMPONENT_NAME$1l = 'vc-date-table';
|
|
5534
5545
|
const DateTable = /* @__PURE__ */ vue.defineComponent({
|
|
5535
|
-
name: COMPONENT_NAME$
|
|
5546
|
+
name: COMPONENT_NAME$1l,
|
|
5536
5547
|
props: {
|
|
5537
5548
|
value: Array,
|
|
5538
5549
|
firstDayOfWeek: {
|
|
@@ -5741,9 +5752,9 @@ const DateTable = /* @__PURE__ */ vue.defineComponent({
|
|
|
5741
5752
|
|
|
5742
5753
|
/** @jsxImportSource vue */
|
|
5743
5754
|
|
|
5744
|
-
const COMPONENT_NAME$
|
|
5755
|
+
const COMPONENT_NAME$1k = 'vc-month-table';
|
|
5745
5756
|
const MonthTable = /* @__PURE__ */ vue.defineComponent({
|
|
5746
|
-
name: COMPONENT_NAME$
|
|
5757
|
+
name: COMPONENT_NAME$1k,
|
|
5747
5758
|
props: {
|
|
5748
5759
|
value: Array,
|
|
5749
5760
|
panelDate: Date,
|
|
@@ -5875,7 +5886,7 @@ const MonthTable = /* @__PURE__ */ vue.defineComponent({
|
|
|
5875
5886
|
|
|
5876
5887
|
/** @jsxImportSource vue */
|
|
5877
5888
|
|
|
5878
|
-
const COMPONENT_NAME$
|
|
5889
|
+
const COMPONENT_NAME$1j = 'vc-quarter-table';
|
|
5879
5890
|
|
|
5880
5891
|
/**
|
|
5881
5892
|
* 获取季度对应的月份范围
|
|
@@ -5909,7 +5920,7 @@ const getQuarterRangeByMonth = value => {
|
|
|
5909
5920
|
}
|
|
5910
5921
|
};
|
|
5911
5922
|
const QuarterTable = /* @__PURE__ */ vue.defineComponent({
|
|
5912
|
-
name: COMPONENT_NAME$
|
|
5923
|
+
name: COMPONENT_NAME$1j,
|
|
5913
5924
|
props: {
|
|
5914
5925
|
value: Array,
|
|
5915
5926
|
panelDate: Date,
|
|
@@ -6032,9 +6043,9 @@ const QuarterTable = /* @__PURE__ */ vue.defineComponent({
|
|
|
6032
6043
|
|
|
6033
6044
|
/** @jsxImportSource vue */
|
|
6034
6045
|
|
|
6035
|
-
const COMPONENT_NAME$
|
|
6046
|
+
const COMPONENT_NAME$1i = 'vc-shortcuts-select';
|
|
6036
6047
|
const ShortcutsSelect = /* @__PURE__ */ vue.defineComponent({
|
|
6037
|
-
name: COMPONENT_NAME$
|
|
6048
|
+
name: COMPONENT_NAME$1i,
|
|
6038
6049
|
props: {
|
|
6039
6050
|
panelDate: Date,
|
|
6040
6051
|
config: Array,
|
|
@@ -6074,9 +6085,9 @@ const ShortcutsSelect = /* @__PURE__ */ vue.defineComponent({
|
|
|
6074
6085
|
|
|
6075
6086
|
/** @jsxImportSource vue */
|
|
6076
6087
|
|
|
6077
|
-
const COMPONENT_NAME$
|
|
6088
|
+
const COMPONENT_NAME$1h = 'vc-time-select';
|
|
6078
6089
|
const TimeSelect = /* @__PURE__ */ vue.defineComponent({
|
|
6079
|
-
name: COMPONENT_NAME$
|
|
6090
|
+
name: COMPONENT_NAME$1h,
|
|
6080
6091
|
props: {
|
|
6081
6092
|
hours: {
|
|
6082
6093
|
type: [Number, String],
|
|
@@ -6355,9 +6366,9 @@ const TimeSelect = /* @__PURE__ */ vue.defineComponent({
|
|
|
6355
6366
|
|
|
6356
6367
|
/** @jsxImportSource vue */
|
|
6357
6368
|
|
|
6358
|
-
const COMPONENT_NAME$
|
|
6369
|
+
const COMPONENT_NAME$1g = 'vc-year-table';
|
|
6359
6370
|
const YearTable = /* @__PURE__ */ vue.defineComponent({
|
|
6360
|
-
name: COMPONENT_NAME$
|
|
6371
|
+
name: COMPONENT_NAME$1g,
|
|
6361
6372
|
props: {
|
|
6362
6373
|
value: Array,
|
|
6363
6374
|
panelDate: Date,
|
|
@@ -6480,9 +6491,9 @@ const getDateIsInRange = (value, type, leftPanelDate, rightPanelDate) => {
|
|
|
6480
6491
|
}
|
|
6481
6492
|
return true;
|
|
6482
6493
|
};
|
|
6483
|
-
const COMPONENT_NAME$
|
|
6494
|
+
const COMPONENT_NAME$1f = 'vc-date-range-panel';
|
|
6484
6495
|
const DateRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
6485
|
-
name: COMPONENT_NAME$
|
|
6496
|
+
name: COMPONENT_NAME$1f,
|
|
6486
6497
|
props: {
|
|
6487
6498
|
...props$V,
|
|
6488
6499
|
confirm: {
|
|
@@ -6861,9 +6872,9 @@ const DateRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
|
6861
6872
|
|
|
6862
6873
|
/** @jsxImportSource vue */
|
|
6863
6874
|
|
|
6864
|
-
const COMPONENT_NAME$
|
|
6875
|
+
const COMPONENT_NAME$1e = 'vc-date-panel';
|
|
6865
6876
|
const DatePanel = /* @__PURE__ */ vue.defineComponent({
|
|
6866
|
-
name: COMPONENT_NAME$
|
|
6877
|
+
name: COMPONENT_NAME$1e,
|
|
6867
6878
|
props: {
|
|
6868
6879
|
...props$V,
|
|
6869
6880
|
type: String,
|
|
@@ -7071,9 +7082,9 @@ const isEqualYear$1 = value => {
|
|
|
7071
7082
|
const endYear = value[1].getFullYear();
|
|
7072
7083
|
return startYear === endYear;
|
|
7073
7084
|
};
|
|
7074
|
-
const COMPONENT_NAME$
|
|
7085
|
+
const COMPONENT_NAME$1d = 'vc-monthrange-panel';
|
|
7075
7086
|
const MonthRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
7076
|
-
name: COMPONENT_NAME$
|
|
7087
|
+
name: COMPONENT_NAME$1d,
|
|
7077
7088
|
props: {
|
|
7078
7089
|
...props$V,
|
|
7079
7090
|
confirm: {
|
|
@@ -7248,9 +7259,9 @@ const isEqualYear = value => {
|
|
|
7248
7259
|
const endYear = value[1].getFullYear();
|
|
7249
7260
|
return startYear === endYear;
|
|
7250
7261
|
};
|
|
7251
|
-
const COMPONENT_NAME$
|
|
7262
|
+
const COMPONENT_NAME$1c = 'vc-quarterrange-panel';
|
|
7252
7263
|
const QuarterRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
7253
|
-
name: COMPONENT_NAME$
|
|
7264
|
+
name: COMPONENT_NAME$1c,
|
|
7254
7265
|
props: {
|
|
7255
7266
|
...props$V,
|
|
7256
7267
|
confirm: {
|
|
@@ -7489,9 +7500,9 @@ const getComparedDate = (leftDate, rightDate) => {
|
|
|
7489
7500
|
seconds
|
|
7490
7501
|
};
|
|
7491
7502
|
};
|
|
7492
|
-
const COMPONENT_NAME$
|
|
7503
|
+
const COMPONENT_NAME$1b = 'vc-timerange-panel';
|
|
7493
7504
|
const TimeRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
7494
|
-
name: COMPONENT_NAME$
|
|
7505
|
+
name: COMPONENT_NAME$1b,
|
|
7495
7506
|
props: props$U,
|
|
7496
7507
|
emits: ['pick', 'clear', 'ok'],
|
|
7497
7508
|
setup(props, {
|
|
@@ -7590,9 +7601,9 @@ const TimeRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
|
7590
7601
|
|
|
7591
7602
|
/** @jsxImportSource vue */
|
|
7592
7603
|
|
|
7593
|
-
const COMPONENT_NAME$
|
|
7604
|
+
const COMPONENT_NAME$1a = 'vc-time-panel';
|
|
7594
7605
|
const TimePanel = /* @__PURE__ */ vue.defineComponent({
|
|
7595
|
-
name: COMPONENT_NAME$
|
|
7606
|
+
name: COMPONENT_NAME$1a,
|
|
7596
7607
|
props: props$U,
|
|
7597
7608
|
emits: ['pick', 'clear', 'ok'],
|
|
7598
7609
|
setup(props, {
|
|
@@ -7647,7 +7658,7 @@ const TimePanel = /* @__PURE__ */ vue.defineComponent({
|
|
|
7647
7658
|
|
|
7648
7659
|
/** @jsxImportSource vue */
|
|
7649
7660
|
|
|
7650
|
-
const COMPONENT_NAME$
|
|
7661
|
+
const COMPONENT_NAME$19 = 'vc-date-picker';
|
|
7651
7662
|
const getPanel$1 = type => {
|
|
7652
7663
|
if (['daterange', 'datetimerange'].includes(type)) {
|
|
7653
7664
|
return DateRangePanel;
|
|
@@ -7658,7 +7669,7 @@ const getPanel$1 = type => {
|
|
|
7658
7669
|
}
|
|
7659
7670
|
return DatePanel;
|
|
7660
7671
|
};
|
|
7661
|
-
const DatePicker = createPicker(COMPONENT_NAME$
|
|
7672
|
+
const DatePicker = createPicker(COMPONENT_NAME$19, props$10, () => {
|
|
7662
7673
|
const props = vue.getCurrentInstance().props;
|
|
7663
7674
|
const icon = vue.ref('date');
|
|
7664
7675
|
const panel = vue.shallowRef({});
|
|
@@ -7691,9 +7702,9 @@ const props$T = {
|
|
|
7691
7702
|
|
|
7692
7703
|
/** @jsxImportSource vue */
|
|
7693
7704
|
|
|
7694
|
-
const COMPONENT_NAME$
|
|
7705
|
+
const COMPONENT_NAME$18 = 'vc-divider';
|
|
7695
7706
|
const Divider = /* @__PURE__ */ vue.defineComponent({
|
|
7696
|
-
name: COMPONENT_NAME$
|
|
7707
|
+
name: COMPONENT_NAME$18,
|
|
7697
7708
|
props: props$T,
|
|
7698
7709
|
setup(props, {
|
|
7699
7710
|
slots
|
|
@@ -7848,7 +7859,7 @@ const props$Q = {
|
|
|
7848
7859
|
|
|
7849
7860
|
/** @jsxImportSource vue */
|
|
7850
7861
|
|
|
7851
|
-
const COMPONENT_NAME$
|
|
7862
|
+
const COMPONENT_NAME$17 = 'vc-scroller-track';
|
|
7852
7863
|
const BAR_MAP = {
|
|
7853
7864
|
vertical: {
|
|
7854
7865
|
scroll: 'scrollTop',
|
|
@@ -7868,7 +7879,7 @@ const BAR_MAP = {
|
|
|
7868
7879
|
}
|
|
7869
7880
|
};
|
|
7870
7881
|
const Track = /* @__PURE__ */ vue.defineComponent({
|
|
7871
|
-
name: COMPONENT_NAME$
|
|
7882
|
+
name: COMPONENT_NAME$17,
|
|
7872
7883
|
props: props$S,
|
|
7873
7884
|
emits: ['change'],
|
|
7874
7885
|
inheritAttrs: false,
|
|
@@ -8058,9 +8069,9 @@ const Track = /* @__PURE__ */ vue.defineComponent({
|
|
|
8058
8069
|
|
|
8059
8070
|
/** @jsxImportSource vue */
|
|
8060
8071
|
|
|
8061
|
-
const COMPONENT_NAME$
|
|
8072
|
+
const COMPONENT_NAME$16 = 'vc-scroller-bar';
|
|
8062
8073
|
const Bar = /* @__PURE__ */ vue.defineComponent({
|
|
8063
|
-
name: COMPONENT_NAME$
|
|
8074
|
+
name: COMPONENT_NAME$16,
|
|
8064
8075
|
props: props$R,
|
|
8065
8076
|
emits: ['change'],
|
|
8066
8077
|
setup(props, {
|
|
@@ -8275,7 +8286,7 @@ const useScroller = (expose) => {
|
|
|
8275
8286
|
|
|
8276
8287
|
/** @jsxImportSource vue */
|
|
8277
8288
|
|
|
8278
|
-
const COMPONENT_NAME$
|
|
8289
|
+
const COMPONENT_NAME$15 = 'vc-scroller';
|
|
8279
8290
|
|
|
8280
8291
|
/**
|
|
8281
8292
|
* 作为备选方案,目前推荐使用ScrollerWheel
|
|
@@ -8286,7 +8297,7 @@ const COMPONENT_NAME$14 = 'vc-scroller';
|
|
|
8286
8297
|
* 2. 增加了一层嵌套
|
|
8287
8298
|
*/
|
|
8288
8299
|
const Scroller = /* @__PURE__ */ vue.defineComponent({
|
|
8289
|
-
name: COMPONENT_NAME$
|
|
8300
|
+
name: COMPONENT_NAME$15,
|
|
8290
8301
|
props: props$Q,
|
|
8291
8302
|
emits: ['scroll'],
|
|
8292
8303
|
setup(props, {
|
|
@@ -8347,7 +8358,7 @@ const Scroller = /* @__PURE__ */ vue.defineComponent({
|
|
|
8347
8358
|
|
|
8348
8359
|
/** @jsxImportSource vue */
|
|
8349
8360
|
|
|
8350
|
-
const COMPONENT_NAME$
|
|
8361
|
+
const COMPONENT_NAME$14 = 'vc-scroller-wheel';
|
|
8351
8362
|
|
|
8352
8363
|
/**
|
|
8353
8364
|
* 为减少一层嵌套,为去除滚动bar的抖动,使用wheel模拟
|
|
@@ -8369,7 +8380,7 @@ const COMPONENT_NAME$13 = 'vc-scroller-wheel';
|
|
|
8369
8380
|
* 设置scrollTop不会reflow和repaint,不需要考虑transfrom来改变content(transform也只在draw完成)
|
|
8370
8381
|
*/
|
|
8371
8382
|
const ScrollerWheel = /* @__PURE__ */ vue.defineComponent({
|
|
8372
|
-
name: COMPONENT_NAME$
|
|
8383
|
+
name: COMPONENT_NAME$14,
|
|
8373
8384
|
props: Object.assign(props$Q, {
|
|
8374
8385
|
stopPropagation: {
|
|
8375
8386
|
type: Boolean,
|
|
@@ -8548,9 +8559,9 @@ const props$P = {
|
|
|
8548
8559
|
|
|
8549
8560
|
/** @jsxImportSource vue */
|
|
8550
8561
|
|
|
8551
|
-
const COMPONENT_NAME$
|
|
8562
|
+
const COMPONENT_NAME$13 = 'vc-drawer';
|
|
8552
8563
|
const DrawerView = /* @__PURE__ */ vue.defineComponent({
|
|
8553
|
-
name: COMPONENT_NAME$
|
|
8564
|
+
name: COMPONENT_NAME$13,
|
|
8554
8565
|
props: props$P,
|
|
8555
8566
|
emits: ['close', 'update:modelValue', 'visible-change'],
|
|
8556
8567
|
setup(props, {
|
|
@@ -8723,9 +8734,9 @@ const props$O = {
|
|
|
8723
8734
|
|
|
8724
8735
|
/** @jsxImportSource vue */
|
|
8725
8736
|
|
|
8726
|
-
const COMPONENT_NAME$
|
|
8737
|
+
const COMPONENT_NAME$12 = 'vc-dropdown';
|
|
8727
8738
|
const Dropdown = /* @__PURE__ */ vue.defineComponent({
|
|
8728
|
-
name: COMPONENT_NAME$
|
|
8739
|
+
name: COMPONENT_NAME$12,
|
|
8729
8740
|
props: props$O,
|
|
8730
8741
|
setup(props, {
|
|
8731
8742
|
slots
|
|
@@ -8749,9 +8760,9 @@ const props$N = {
|
|
|
8749
8760
|
|
|
8750
8761
|
/** @jsxImportSource vue */
|
|
8751
8762
|
|
|
8752
|
-
const COMPONENT_NAME$
|
|
8763
|
+
const COMPONENT_NAME$11 = 'vc-editor';
|
|
8753
8764
|
const Editor = /* @__PURE__ */ vue.defineComponent({
|
|
8754
|
-
name: COMPONENT_NAME$
|
|
8765
|
+
name: COMPONENT_NAME$11,
|
|
8755
8766
|
props: props$N,
|
|
8756
8767
|
setup(props, {
|
|
8757
8768
|
slots
|
|
@@ -8895,9 +8906,9 @@ const useForm = (expose, options = {}) => {
|
|
|
8895
8906
|
});
|
|
8896
8907
|
};
|
|
8897
8908
|
|
|
8898
|
-
const COMPONENT_NAME
|
|
8909
|
+
const COMPONENT_NAME$10 = "vc-form";
|
|
8899
8910
|
const Form = vue.defineComponent({
|
|
8900
|
-
name: COMPONENT_NAME
|
|
8911
|
+
name: COMPONENT_NAME$10,
|
|
8901
8912
|
props: props$M,
|
|
8902
8913
|
setup(props, { slots, expose }) {
|
|
8903
8914
|
useForm(expose);
|
|
@@ -9217,9 +9228,9 @@ const useFormItem = (expose) => {
|
|
|
9217
9228
|
|
|
9218
9229
|
/** @jsxImportSource vue */
|
|
9219
9230
|
|
|
9220
|
-
const COMPONENT_NAME
|
|
9231
|
+
const COMPONENT_NAME$$ = 'vc-form-item';
|
|
9221
9232
|
const FormItem = /* @__PURE__ */ vue.defineComponent({
|
|
9222
|
-
name: COMPONENT_NAME
|
|
9233
|
+
name: COMPONENT_NAME$$,
|
|
9223
9234
|
props: props$L,
|
|
9224
9235
|
setup(props, {
|
|
9225
9236
|
slots,
|
|
@@ -9284,9 +9295,9 @@ const props$K = {
|
|
|
9284
9295
|
}
|
|
9285
9296
|
};
|
|
9286
9297
|
|
|
9287
|
-
const COMPONENT_NAME$
|
|
9298
|
+
const COMPONENT_NAME$_ = "vcm-form";
|
|
9288
9299
|
const MForm = vue.defineComponent({
|
|
9289
|
-
name: COMPONENT_NAME$
|
|
9300
|
+
name: COMPONENT_NAME$_,
|
|
9290
9301
|
props: props$K,
|
|
9291
9302
|
setup(props, { slots, expose }) {
|
|
9292
9303
|
useForm(expose, {
|
|
@@ -9317,9 +9328,9 @@ const props$J = {
|
|
|
9317
9328
|
|
|
9318
9329
|
/** @jsxImportSource vue */
|
|
9319
9330
|
|
|
9320
|
-
const COMPONENT_NAME$
|
|
9331
|
+
const COMPONENT_NAME$Z = 'vcm-form-item';
|
|
9321
9332
|
const MFormItem = /* @__PURE__ */ vue.defineComponent({
|
|
9322
|
-
name: COMPONENT_NAME$
|
|
9333
|
+
name: COMPONENT_NAME$Z,
|
|
9323
9334
|
props: props$J,
|
|
9324
9335
|
setup(props, {
|
|
9325
9336
|
slots,
|
|
@@ -9373,9 +9384,9 @@ const MFormItem = /* @__PURE__ */ vue.defineComponent({
|
|
|
9373
9384
|
}
|
|
9374
9385
|
});
|
|
9375
9386
|
|
|
9376
|
-
const COMPONENT_NAME$
|
|
9387
|
+
const COMPONENT_NAME$Y = "vc-fragment";
|
|
9377
9388
|
const Fragment = vue.defineComponent({
|
|
9378
|
-
name: COMPONENT_NAME$
|
|
9389
|
+
name: COMPONENT_NAME$Y,
|
|
9379
9390
|
setup(_, { slots }) {
|
|
9380
9391
|
return () => vue.h(vue.Fragment, slots.default?.());
|
|
9381
9392
|
}
|
|
@@ -9392,9 +9403,9 @@ const props$I = {
|
|
|
9392
9403
|
|
|
9393
9404
|
/** @jsxImportSource vue */
|
|
9394
9405
|
|
|
9395
|
-
const COMPONENT_NAME$
|
|
9406
|
+
const COMPONENT_NAME$X = 'vc-html-to-image';
|
|
9396
9407
|
const HTMLToImage = /* @__PURE__ */ vue.defineComponent({
|
|
9397
|
-
name: COMPONENT_NAME$
|
|
9408
|
+
name: COMPONENT_NAME$X,
|
|
9398
9409
|
props: props$I,
|
|
9399
9410
|
setup(props, {
|
|
9400
9411
|
slots
|
|
@@ -9470,7 +9481,7 @@ const IMGStore$1 = new IMGStore();
|
|
|
9470
9481
|
|
|
9471
9482
|
/** @jsxImportSource vue */
|
|
9472
9483
|
|
|
9473
|
-
const COMPONENT_NAME$
|
|
9484
|
+
const COMPONENT_NAME$W = 'vc-image';
|
|
9474
9485
|
let isSupportObjectFit = false;
|
|
9475
9486
|
window.addEventListener('DOMContentLoaded', () => {
|
|
9476
9487
|
isSupportObjectFit = !vcShared.IS_SERVER && document.documentElement.style.objectFit !== undefined;
|
|
@@ -9483,7 +9494,7 @@ const ObjectFit = {
|
|
|
9483
9494
|
SCALE_DOWN: 'scale-down'
|
|
9484
9495
|
};
|
|
9485
9496
|
const Image = /* @__PURE__ */ vue.defineComponent({
|
|
9486
|
-
name: COMPONENT_NAME$
|
|
9497
|
+
name: COMPONENT_NAME$W,
|
|
9487
9498
|
inheritAttrs: false,
|
|
9488
9499
|
props: props$H,
|
|
9489
9500
|
setup(props, {
|
|
@@ -9688,9 +9699,9 @@ const props$G = {
|
|
|
9688
9699
|
|
|
9689
9700
|
/** @jsxImportSource vue */
|
|
9690
9701
|
|
|
9691
|
-
const COMPONENT_NAME$
|
|
9702
|
+
const COMPONENT_NAME$V = 'vc-image-crop';
|
|
9692
9703
|
const ImageCrop = /* @__PURE__ */ vue.defineComponent({
|
|
9693
|
-
name: COMPONENT_NAME$
|
|
9704
|
+
name: COMPONENT_NAME$V,
|
|
9694
9705
|
props: props$G,
|
|
9695
9706
|
setup(props, {
|
|
9696
9707
|
slots
|
|
@@ -9714,9 +9725,9 @@ const props$F = {
|
|
|
9714
9725
|
|
|
9715
9726
|
/** @jsxImportSource vue */
|
|
9716
9727
|
|
|
9717
|
-
const COMPONENT_NAME$
|
|
9728
|
+
const COMPONENT_NAME$U = 'vc-image-preview';
|
|
9718
9729
|
const ImagePreview = /* @__PURE__ */ vue.defineComponent({
|
|
9719
|
-
name: COMPONENT_NAME$
|
|
9730
|
+
name: COMPONENT_NAME$U,
|
|
9720
9731
|
props: props$F,
|
|
9721
9732
|
setup(props, {
|
|
9722
9733
|
slots
|
|
@@ -9740,9 +9751,9 @@ const props$E = {
|
|
|
9740
9751
|
|
|
9741
9752
|
/** @jsxImportSource vue */
|
|
9742
9753
|
|
|
9743
|
-
const COMPONENT_NAME$
|
|
9754
|
+
const COMPONENT_NAME$T = 'vc-image-processing';
|
|
9744
9755
|
const ImageProcessing = /* @__PURE__ */ vue.defineComponent({
|
|
9745
|
-
name: COMPONENT_NAME$
|
|
9756
|
+
name: COMPONENT_NAME$T,
|
|
9746
9757
|
props: props$E,
|
|
9747
9758
|
setup(props, {
|
|
9748
9759
|
slots
|
|
@@ -9759,9 +9770,9 @@ const MImageProcessing = ImageProcessing;
|
|
|
9759
9770
|
|
|
9760
9771
|
/** @jsxImportSource vue */
|
|
9761
9772
|
|
|
9762
|
-
const COMPONENT_NAME$
|
|
9773
|
+
const COMPONENT_NAME$S = 'vcm-input';
|
|
9763
9774
|
const MInput = /* @__PURE__ */ vue.defineComponent({
|
|
9764
|
-
name: COMPONENT_NAME$
|
|
9775
|
+
name: COMPONENT_NAME$S,
|
|
9765
9776
|
inheritAttrs: false,
|
|
9766
9777
|
props: {
|
|
9767
9778
|
...props$$,
|
|
@@ -9850,9 +9861,9 @@ const MInput = /* @__PURE__ */ vue.defineComponent({
|
|
|
9850
9861
|
|
|
9851
9862
|
/** @jsxImportSource vue */
|
|
9852
9863
|
|
|
9853
|
-
const COMPONENT_NAME$
|
|
9864
|
+
const COMPONENT_NAME$R = 'vcm-input-number';
|
|
9854
9865
|
const MInputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
9855
|
-
name: COMPONENT_NAME$
|
|
9866
|
+
name: COMPONENT_NAME$R,
|
|
9856
9867
|
props: props$X,
|
|
9857
9868
|
inheritAttrs: false,
|
|
9858
9869
|
setup(props, {
|
|
@@ -9901,9 +9912,9 @@ const MInputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
|
9901
9912
|
|
|
9902
9913
|
/** @jsxImportSource vue */
|
|
9903
9914
|
|
|
9904
|
-
const COMPONENT_NAME$
|
|
9915
|
+
const COMPONENT_NAME$Q = 'vcm-input-search';
|
|
9905
9916
|
const MInputSearch = /* @__PURE__ */ vue.defineComponent({
|
|
9906
|
-
name: COMPONENT_NAME$
|
|
9917
|
+
name: COMPONENT_NAME$Q,
|
|
9907
9918
|
props: {
|
|
9908
9919
|
...props$W,
|
|
9909
9920
|
cancelText: {
|
|
@@ -9980,9 +9991,9 @@ const props$D = {
|
|
|
9980
9991
|
}
|
|
9981
9992
|
};
|
|
9982
9993
|
|
|
9983
|
-
const COMPONENT_NAME$
|
|
9994
|
+
const COMPONENT_NAME$P = "vcm-list";
|
|
9984
9995
|
const MList = vue.defineComponent({
|
|
9985
|
-
name: COMPONENT_NAME$
|
|
9996
|
+
name: COMPONENT_NAME$P,
|
|
9986
9997
|
props: props$D,
|
|
9987
9998
|
setup(props, { slots }) {
|
|
9988
9999
|
vue.provide("vc-list", { props });
|
|
@@ -10037,10 +10048,10 @@ const props$C = {
|
|
|
10037
10048
|
|
|
10038
10049
|
/** @jsxImportSource vue */
|
|
10039
10050
|
|
|
10040
|
-
const COMPONENT_NAME$
|
|
10051
|
+
const COMPONENT_NAME$O = 'vcm-list-item';
|
|
10041
10052
|
const HTTP_REGEX = /[a-zA-z]+:\/\/[^\s]*/;
|
|
10042
10053
|
const MListItem = /* @__PURE__ */ vue.defineComponent({
|
|
10043
|
-
name: COMPONENT_NAME$
|
|
10054
|
+
name: COMPONENT_NAME$O,
|
|
10044
10055
|
props: props$C,
|
|
10045
10056
|
emits: ['click'],
|
|
10046
10057
|
setup(props, {
|
|
@@ -10134,11 +10145,11 @@ const props$B = {
|
|
|
10134
10145
|
|
|
10135
10146
|
/** @jsxImportSource vue */
|
|
10136
10147
|
|
|
10137
|
-
const COMPONENT_NAME$
|
|
10148
|
+
const COMPONENT_NAME$N = 'vc-marquee';
|
|
10138
10149
|
const ANIMATION = $.prefixStyle('animation').camel;
|
|
10139
10150
|
const TRANSFORM_KEBAB = $.prefixStyle('transform').kebab;
|
|
10140
10151
|
const Marquee = /* @__PURE__ */ vue.defineComponent({
|
|
10141
|
-
name: COMPONENT_NAME$
|
|
10152
|
+
name: COMPONENT_NAME$N,
|
|
10142
10153
|
props: props$B,
|
|
10143
10154
|
setup(props, {
|
|
10144
10155
|
slots
|
|
@@ -10206,9 +10217,9 @@ const props$A = {
|
|
|
10206
10217
|
}
|
|
10207
10218
|
};
|
|
10208
10219
|
|
|
10209
|
-
const COMPONENT_NAME$
|
|
10220
|
+
const COMPONENT_NAME$M = "vc-resizer";
|
|
10210
10221
|
const Resizer = vue.defineComponent({
|
|
10211
|
-
name: COMPONENT_NAME$
|
|
10222
|
+
name: COMPONENT_NAME$M,
|
|
10212
10223
|
props: props$A,
|
|
10213
10224
|
emit: ["resize", "change"],
|
|
10214
10225
|
setup(props, { emit, slots, expose }) {
|
|
@@ -10355,10 +10366,10 @@ const props$z = {
|
|
|
10355
10366
|
|
|
10356
10367
|
/** @jsxImportSource vue */
|
|
10357
10368
|
|
|
10358
|
-
const COMPONENT_NAME$
|
|
10369
|
+
const COMPONENT_NAME$L = 'vc-modal';
|
|
10359
10370
|
let zIndexNumber = 1002;
|
|
10360
10371
|
const ModalView = /* @__PURE__ */ vue.defineComponent({
|
|
10361
|
-
name: COMPONENT_NAME$
|
|
10372
|
+
name: COMPONENT_NAME$L,
|
|
10362
10373
|
emits: ['update:modelValue', 'close', 'portal-fulfilled', 'visible-change', 'ok', 'cancel'],
|
|
10363
10374
|
props: props$z,
|
|
10364
10375
|
setup(props, {
|
|
@@ -10785,9 +10796,9 @@ const props$y = {
|
|
|
10785
10796
|
|
|
10786
10797
|
/** @jsxImportSource vue */
|
|
10787
10798
|
|
|
10788
|
-
const COMPONENT_NAME$
|
|
10799
|
+
const COMPONENT_NAME$K = 'vc-modal';
|
|
10789
10800
|
const MModalView = /* @__PURE__ */ vue.defineComponent({
|
|
10790
|
-
name: COMPONENT_NAME$
|
|
10801
|
+
name: COMPONENT_NAME$K,
|
|
10791
10802
|
emits: ['update:modelValue', 'portal-fulfilled', 'close', 'ok', 'cancel'],
|
|
10792
10803
|
props: props$y,
|
|
10793
10804
|
setup(props, {
|
|
@@ -10999,9 +11010,9 @@ const props$x = {
|
|
|
10999
11010
|
|
|
11000
11011
|
/** @jsxImportSource vue */
|
|
11001
11012
|
|
|
11002
|
-
const COMPONENT_NAME$
|
|
11013
|
+
const COMPONENT_NAME$J = 'vc-notice';
|
|
11003
11014
|
const NoticeView = /* @__PURE__ */ vue.defineComponent({
|
|
11004
|
-
name: COMPONENT_NAME$
|
|
11015
|
+
name: COMPONENT_NAME$J,
|
|
11005
11016
|
props: props$x,
|
|
11006
11017
|
emits: ['portal-fulfilled', 'close', 'before-close'],
|
|
11007
11018
|
setup(props, {
|
|
@@ -11174,9 +11185,9 @@ const props$w = {
|
|
|
11174
11185
|
|
|
11175
11186
|
/** @jsxImportSource vue */
|
|
11176
11187
|
|
|
11177
|
-
const COMPONENT_NAME$
|
|
11188
|
+
const COMPONENT_NAME$I = 'vc-option';
|
|
11178
11189
|
const Option$1 = /* @__PURE__ */ vue.defineComponent({
|
|
11179
|
-
name: COMPONENT_NAME$
|
|
11190
|
+
name: COMPONENT_NAME$I,
|
|
11180
11191
|
props: props$w,
|
|
11181
11192
|
setup(props, {
|
|
11182
11193
|
slots
|
|
@@ -11289,9 +11300,9 @@ const props$u = {
|
|
|
11289
11300
|
|
|
11290
11301
|
/** @jsxImportSource vue */
|
|
11291
11302
|
|
|
11292
|
-
const COMPONENT_NAME$
|
|
11303
|
+
const COMPONENT_NAME$H = 'vc-tag';
|
|
11293
11304
|
const Tag = /* @__PURE__ */ vue.defineComponent({
|
|
11294
|
-
name: COMPONENT_NAME$
|
|
11305
|
+
name: COMPONENT_NAME$H,
|
|
11295
11306
|
props: props$u,
|
|
11296
11307
|
emits: ['close', 'change'],
|
|
11297
11308
|
setup(props, {
|
|
@@ -11360,9 +11371,9 @@ const props$t = {
|
|
|
11360
11371
|
|
|
11361
11372
|
/** @jsxImportSource vue */
|
|
11362
11373
|
|
|
11363
|
-
const COMPONENT_NAME$
|
|
11374
|
+
const COMPONENT_NAME$G = 'vc-select-option';
|
|
11364
11375
|
const Option = /* @__PURE__ */ vue.defineComponent({
|
|
11365
|
-
name: COMPONENT_NAME$
|
|
11376
|
+
name: COMPONENT_NAME$G,
|
|
11366
11377
|
props: props$t,
|
|
11367
11378
|
setup(props, {
|
|
11368
11379
|
slots
|
|
@@ -11435,9 +11446,9 @@ const props$s = {
|
|
|
11435
11446
|
|
|
11436
11447
|
/** @jsxImportSource vue */
|
|
11437
11448
|
|
|
11438
|
-
const COMPONENT_NAME$
|
|
11449
|
+
const COMPONENT_NAME$F = 'vc-select-option-group';
|
|
11439
11450
|
const OptionGroup = /* @__PURE__ */ vue.defineComponent({
|
|
11440
|
-
name: COMPONENT_NAME$
|
|
11451
|
+
name: COMPONENT_NAME$F,
|
|
11441
11452
|
props: props$s,
|
|
11442
11453
|
setup(props, {
|
|
11443
11454
|
slots
|
|
@@ -11456,7 +11467,7 @@ const OptionGroup = /* @__PURE__ */ vue.defineComponent({
|
|
|
11456
11467
|
}
|
|
11457
11468
|
});
|
|
11458
11469
|
|
|
11459
|
-
const inputKeys = [
|
|
11470
|
+
const inputKeys$1 = [
|
|
11460
11471
|
"id",
|
|
11461
11472
|
"disabled",
|
|
11462
11473
|
"modelValue",
|
|
@@ -11468,7 +11479,7 @@ const popoverKeys = [
|
|
|
11468
11479
|
];
|
|
11469
11480
|
const props$r = {
|
|
11470
11481
|
...lodashEs.pick(props$Z, popoverKeys),
|
|
11471
|
-
...lodashEs.pick(props$$, inputKeys),
|
|
11482
|
+
...lodashEs.pick(props$$, inputKeys$1),
|
|
11472
11483
|
data: {
|
|
11473
11484
|
type: Array,
|
|
11474
11485
|
default: () => []
|
|
@@ -11535,9 +11546,9 @@ const props$r = {
|
|
|
11535
11546
|
function _isSlot$1(s) {
|
|
11536
11547
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
11537
11548
|
}
|
|
11538
|
-
const COMPONENT_NAME$
|
|
11549
|
+
const COMPONENT_NAME$E = 'vc-select';
|
|
11539
11550
|
const Select = /* @__PURE__ */ vue.defineComponent({
|
|
11540
|
-
name: COMPONENT_NAME$
|
|
11551
|
+
name: COMPONENT_NAME$E,
|
|
11541
11552
|
props: props$r,
|
|
11542
11553
|
emits: ['ready', 'close', 'visible-change', 'clear', 'change', 'update:modelValue'],
|
|
11543
11554
|
setup(props, {
|
|
@@ -11781,9 +11792,9 @@ const Select = /* @__PURE__ */ vue.defineComponent({
|
|
|
11781
11792
|
|
|
11782
11793
|
/** @jsxImportSource vue */
|
|
11783
11794
|
|
|
11784
|
-
const COMPONENT_NAME$
|
|
11795
|
+
const COMPONENT_NAME$D = 'vc-pagination';
|
|
11785
11796
|
const Pagination = /* @__PURE__ */ vue.defineComponent({
|
|
11786
|
-
name: COMPONENT_NAME$
|
|
11797
|
+
name: COMPONENT_NAME$D,
|
|
11787
11798
|
props: props$v,
|
|
11788
11799
|
emits: ['update:current', 'change', 'page-size-change'],
|
|
11789
11800
|
setup(props, {
|
|
@@ -11981,9 +11992,9 @@ const props$q = {
|
|
|
11981
11992
|
|
|
11982
11993
|
/** @jsxImportSource vue */
|
|
11983
11994
|
|
|
11984
|
-
const COMPONENT_NAME$
|
|
11995
|
+
const COMPONENT_NAME$C = 'vc-picker';
|
|
11985
11996
|
const Picker = /* @__PURE__ */ vue.defineComponent({
|
|
11986
|
-
name: COMPONENT_NAME$
|
|
11997
|
+
name: COMPONENT_NAME$C,
|
|
11987
11998
|
props: props$q,
|
|
11988
11999
|
setup(props, {
|
|
11989
12000
|
slots
|
|
@@ -12007,9 +12018,9 @@ const props$p = {
|
|
|
12007
12018
|
|
|
12008
12019
|
/** @jsxImportSource vue */
|
|
12009
12020
|
|
|
12010
|
-
const COMPONENT_NAME$
|
|
12021
|
+
const COMPONENT_NAME$B = 'vc-popconfirm';
|
|
12011
12022
|
const Popconfirm = /* @__PURE__ */ vue.defineComponent({
|
|
12012
|
-
name: COMPONENT_NAME$
|
|
12023
|
+
name: COMPONENT_NAME$B,
|
|
12013
12024
|
props: props$p,
|
|
12014
12025
|
setup(props, {
|
|
12015
12026
|
slots
|
|
@@ -12035,9 +12046,9 @@ const props$o = {
|
|
|
12035
12046
|
|
|
12036
12047
|
/** @jsxImportSource vue */
|
|
12037
12048
|
|
|
12038
|
-
const COMPONENT_NAME$
|
|
12049
|
+
const COMPONENT_NAME$A = 'vc-popup';
|
|
12039
12050
|
const Popup = /* @__PURE__ */ vue.defineComponent({
|
|
12040
|
-
name: COMPONENT_NAME$
|
|
12051
|
+
name: COMPONENT_NAME$A,
|
|
12041
12052
|
props: props$o,
|
|
12042
12053
|
setup(props, {
|
|
12043
12054
|
slots
|
|
@@ -12064,9 +12075,9 @@ const props$n = {
|
|
|
12064
12075
|
|
|
12065
12076
|
/** @jsxImportSource vue */
|
|
12066
12077
|
|
|
12067
|
-
const COMPONENT_NAME$
|
|
12078
|
+
const COMPONENT_NAME$z = 'vc-print';
|
|
12068
12079
|
const Print = /* @__PURE__ */ vue.defineComponent({
|
|
12069
|
-
name: COMPONENT_NAME$
|
|
12080
|
+
name: COMPONENT_NAME$z,
|
|
12070
12081
|
props: props$n,
|
|
12071
12082
|
setup(props, {
|
|
12072
12083
|
expose,
|
|
@@ -12168,9 +12179,9 @@ const props$m = {
|
|
|
12168
12179
|
|
|
12169
12180
|
/** @jsxImportSource vue */
|
|
12170
12181
|
|
|
12171
|
-
const COMPONENT_NAME$
|
|
12182
|
+
const COMPONENT_NAME$y = 'vc-progress-circle';
|
|
12172
12183
|
const Circle = /* @__PURE__ */ vue.defineComponent({
|
|
12173
|
-
name: COMPONENT_NAME$
|
|
12184
|
+
name: COMPONENT_NAME$y,
|
|
12174
12185
|
props: props$m,
|
|
12175
12186
|
setup(props, {
|
|
12176
12187
|
slots
|
|
@@ -12230,9 +12241,9 @@ const Circle = /* @__PURE__ */ vue.defineComponent({
|
|
|
12230
12241
|
|
|
12231
12242
|
/** @jsxImportSource vue */
|
|
12232
12243
|
|
|
12233
|
-
const COMPONENT_NAME$
|
|
12244
|
+
const COMPONENT_NAME$x = 'vc-progress-line';
|
|
12234
12245
|
const Line = /* @__PURE__ */ vue.defineComponent({
|
|
12235
|
-
name: COMPONENT_NAME$
|
|
12246
|
+
name: COMPONENT_NAME$x,
|
|
12236
12247
|
props: props$m,
|
|
12237
12248
|
setup(props) {
|
|
12238
12249
|
const colorStyle = vue.computed(() => {
|
|
@@ -12279,9 +12290,9 @@ const Line = /* @__PURE__ */ vue.defineComponent({
|
|
|
12279
12290
|
function _isSlot(s) {
|
|
12280
12291
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
12281
12292
|
}
|
|
12282
|
-
const COMPONENT_NAME$
|
|
12293
|
+
const COMPONENT_NAME$w = 'vc-progress';
|
|
12283
12294
|
const Progress = /* @__PURE__ */ vue.defineComponent({
|
|
12284
|
-
name: COMPONENT_NAME$
|
|
12295
|
+
name: COMPONENT_NAME$w,
|
|
12285
12296
|
props: props$m,
|
|
12286
12297
|
setup(props, {
|
|
12287
12298
|
slots
|
|
@@ -12433,9 +12444,9 @@ const useRadio = () => {
|
|
|
12433
12444
|
|
|
12434
12445
|
/** @jsxImportSource vue */
|
|
12435
12446
|
|
|
12436
|
-
const COMPONENT_NAME$
|
|
12447
|
+
const COMPONENT_NAME$v = 'vc-radio';
|
|
12437
12448
|
const Radio = /* @__PURE__ */ vue.defineComponent({
|
|
12438
|
-
name: COMPONENT_NAME$
|
|
12449
|
+
name: COMPONENT_NAME$v,
|
|
12439
12450
|
props: props$l,
|
|
12440
12451
|
emits: ['update:modelValue', 'change'],
|
|
12441
12452
|
setup(props, {
|
|
@@ -12546,9 +12557,9 @@ const useRadioGroup = () => {
|
|
|
12546
12557
|
|
|
12547
12558
|
/** @jsxImportSource vue */
|
|
12548
12559
|
|
|
12549
|
-
const COMPONENT_NAME$
|
|
12560
|
+
const COMPONENT_NAME$u = 'vc-radio-group';
|
|
12550
12561
|
const RadioGroup = /* @__PURE__ */ vue.defineComponent({
|
|
12551
|
-
name: COMPONENT_NAME$
|
|
12562
|
+
name: COMPONENT_NAME$u,
|
|
12552
12563
|
props: props$k,
|
|
12553
12564
|
emits: ['update:modelValue', 'change'],
|
|
12554
12565
|
setup(props, {
|
|
@@ -12570,9 +12581,9 @@ const RadioGroup = /* @__PURE__ */ vue.defineComponent({
|
|
|
12570
12581
|
|
|
12571
12582
|
/** @jsxImportSource vue */
|
|
12572
12583
|
|
|
12573
|
-
const COMPONENT_NAME$
|
|
12584
|
+
const COMPONENT_NAME$t = 'vcm-radio';
|
|
12574
12585
|
const MRadio = /* @__PURE__ */ vue.defineComponent({
|
|
12575
|
-
name: COMPONENT_NAME$
|
|
12586
|
+
name: COMPONENT_NAME$t,
|
|
12576
12587
|
props: props$l,
|
|
12577
12588
|
emits: ['update:modelValue', 'change'],
|
|
12578
12589
|
setup(props, {
|
|
@@ -12613,9 +12624,9 @@ const MRadio = /* @__PURE__ */ vue.defineComponent({
|
|
|
12613
12624
|
|
|
12614
12625
|
/** @jsxImportSource vue */
|
|
12615
12626
|
|
|
12616
|
-
const COMPONENT_NAME$
|
|
12627
|
+
const COMPONENT_NAME$s = 'vcm-radio-group';
|
|
12617
12628
|
const MRadioGroup = /* @__PURE__ */ vue.defineComponent({
|
|
12618
|
-
name: COMPONENT_NAME$
|
|
12629
|
+
name: COMPONENT_NAME$s,
|
|
12619
12630
|
props: props$k,
|
|
12620
12631
|
emits: ['update:modelValue', 'change'],
|
|
12621
12632
|
setup(props, {
|
|
@@ -12644,9 +12655,9 @@ const props$j = {
|
|
|
12644
12655
|
|
|
12645
12656
|
/** @jsxImportSource vue */
|
|
12646
12657
|
|
|
12647
|
-
const COMPONENT_NAME$
|
|
12658
|
+
const COMPONENT_NAME$r = 'vc-rate';
|
|
12648
12659
|
const Rate = /* @__PURE__ */ vue.defineComponent({
|
|
12649
|
-
name: COMPONENT_NAME$
|
|
12660
|
+
name: COMPONENT_NAME$r,
|
|
12650
12661
|
props: props$j,
|
|
12651
12662
|
setup(props, {
|
|
12652
12663
|
slots
|
|
@@ -12714,9 +12725,9 @@ const props$i = {
|
|
|
12714
12725
|
|
|
12715
12726
|
/** @jsxImportSource vue */
|
|
12716
12727
|
|
|
12717
|
-
const COMPONENT_NAME$
|
|
12728
|
+
const COMPONENT_NAME$q = 'vc-recycle-list-scroll-state';
|
|
12718
12729
|
const ScrollState = /* @__PURE__ */ vue.defineComponent({
|
|
12719
|
-
name: COMPONENT_NAME$
|
|
12730
|
+
name: COMPONENT_NAME$q,
|
|
12720
12731
|
setup(_, {
|
|
12721
12732
|
slots
|
|
12722
12733
|
}) {
|
|
@@ -12846,12 +12857,12 @@ const useDirectionKeys = () => {
|
|
|
12846
12857
|
|
|
12847
12858
|
/** @jsxImportSource vue */
|
|
12848
12859
|
|
|
12849
|
-
const COMPONENT_NAME$
|
|
12860
|
+
const COMPONENT_NAME$p = 'vc-recycle-list-container';
|
|
12850
12861
|
|
|
12851
12862
|
// TODO: 抽离
|
|
12852
12863
|
const transformKey = $__namespace.prefixStyle('transform').camel;
|
|
12853
12864
|
const Container = /* @__PURE__ */ vue.defineComponent({
|
|
12854
|
-
name: COMPONENT_NAME$
|
|
12865
|
+
name: COMPONENT_NAME$p,
|
|
12855
12866
|
props: props$h,
|
|
12856
12867
|
emits: ['refresh'],
|
|
12857
12868
|
setup(props, {
|
|
@@ -12949,9 +12960,9 @@ const Container = /* @__PURE__ */ vue.defineComponent({
|
|
|
12949
12960
|
|
|
12950
12961
|
/** @jsxImportSource vue */
|
|
12951
12962
|
|
|
12952
|
-
const COMPONENT_NAME$
|
|
12963
|
+
const COMPONENT_NAME$o = 'vc-recycle-list';
|
|
12953
12964
|
const RecycleList = /* @__PURE__ */ vue.defineComponent({
|
|
12954
|
-
name: COMPONENT_NAME$
|
|
12965
|
+
name: COMPONENT_NAME$o,
|
|
12955
12966
|
props: props$i,
|
|
12956
12967
|
emits: ['scroll', 'row-resize'],
|
|
12957
12968
|
setup(props, {
|
|
@@ -13098,21 +13109,12 @@ const RecycleList = /* @__PURE__ */ vue.defineComponent({
|
|
|
13098
13109
|
const current = props.inverted ? rebuildData.value[rebuildDataIndexMap.value[index]] : rebuildData.value[index];
|
|
13099
13110
|
if (!current) return; // 受到`removeUnusedPlaceholders`影响,无效的会被回收
|
|
13100
13111
|
|
|
13101
|
-
const oldSize = current.size;
|
|
13102
13112
|
const dom = preloads.value[index] || curloads.value[props.inverted ? index : index - firstItemIndex.value];
|
|
13103
13113
|
if (dom) {
|
|
13104
13114
|
current.size = dom[K.offsetSize] || placeholderSize.value;
|
|
13105
13115
|
} else if (current) {
|
|
13106
13116
|
current.size = placeholderSize.value;
|
|
13107
13117
|
}
|
|
13108
|
-
|
|
13109
|
-
// 这样的考虑欠佳,待优化
|
|
13110
|
-
if (oldSize !== current.size) {
|
|
13111
|
-
emit('row-resize', {
|
|
13112
|
-
index: current.id,
|
|
13113
|
-
size: current.size
|
|
13114
|
-
});
|
|
13115
|
-
}
|
|
13116
13118
|
};
|
|
13117
13119
|
const refreshItemPosition = () => {
|
|
13118
13120
|
const sizes = Array.from({
|
|
@@ -13342,6 +13344,13 @@ const RecycleList = /* @__PURE__ */ vue.defineComponent({
|
|
|
13342
13344
|
leading: false,
|
|
13343
13345
|
trailing: true
|
|
13344
13346
|
});
|
|
13347
|
+
const handleRowChange = (e, row) => {
|
|
13348
|
+
emit('row-resize', {
|
|
13349
|
+
index: row.id,
|
|
13350
|
+
height: e.height,
|
|
13351
|
+
width: e.width
|
|
13352
|
+
});
|
|
13353
|
+
};
|
|
13345
13354
|
|
|
13346
13355
|
// 设置初始数据
|
|
13347
13356
|
const setDataSource = async (v, oldV) => {
|
|
@@ -13472,7 +13481,8 @@ const RecycleList = /* @__PURE__ */ vue.defineComponent({
|
|
|
13472
13481
|
"data-column": item.column,
|
|
13473
13482
|
"data-size": item.size,
|
|
13474
13483
|
"data-position": item.position,
|
|
13475
|
-
"onResize": handleResize
|
|
13484
|
+
"onResize": handleResize,
|
|
13485
|
+
"onChange": e => handleRowChange(e, item)
|
|
13476
13486
|
}, {
|
|
13477
13487
|
default: () => [slots.default?.({
|
|
13478
13488
|
row: item.data || {},
|
|
@@ -13523,9 +13533,9 @@ const props$g = {
|
|
|
13523
13533
|
|
|
13524
13534
|
/** @jsxImportSource vue */
|
|
13525
13535
|
|
|
13526
|
-
const COMPONENT_NAME$
|
|
13536
|
+
const COMPONENT_NAME$n = 'vc-slider';
|
|
13527
13537
|
const Slider = /* @__PURE__ */ vue.defineComponent({
|
|
13528
|
-
name: COMPONENT_NAME$
|
|
13538
|
+
name: COMPONENT_NAME$n,
|
|
13529
13539
|
props: props$g,
|
|
13530
13540
|
setup(props, {
|
|
13531
13541
|
slots
|
|
@@ -13549,9 +13559,9 @@ const props$f = {
|
|
|
13549
13559
|
|
|
13550
13560
|
/** @jsxImportSource vue */
|
|
13551
13561
|
|
|
13552
|
-
const COMPONENT_NAME$
|
|
13562
|
+
const COMPONENT_NAME$m = 'vc-sort-list';
|
|
13553
13563
|
const SortList = /* @__PURE__ */ vue.defineComponent({
|
|
13554
|
-
name: COMPONENT_NAME$
|
|
13564
|
+
name: COMPONENT_NAME$m,
|
|
13555
13565
|
props: props$f,
|
|
13556
13566
|
setup(props, {
|
|
13557
13567
|
slots
|
|
@@ -13575,9 +13585,9 @@ const props$e = {
|
|
|
13575
13585
|
|
|
13576
13586
|
/** @jsxImportSource vue */
|
|
13577
13587
|
|
|
13578
|
-
const COMPONENT_NAME$
|
|
13588
|
+
const COMPONENT_NAME$l = 'vc-steps';
|
|
13579
13589
|
const Steps = /* @__PURE__ */ vue.defineComponent({
|
|
13580
|
-
name: COMPONENT_NAME$
|
|
13590
|
+
name: COMPONENT_NAME$l,
|
|
13581
13591
|
props: props$e,
|
|
13582
13592
|
setup(props, {
|
|
13583
13593
|
slots
|
|
@@ -13690,9 +13700,9 @@ const useSwitch = (expose) => {
|
|
|
13690
13700
|
|
|
13691
13701
|
/** @jsxImportSource vue */
|
|
13692
13702
|
|
|
13693
|
-
const COMPONENT_NAME$
|
|
13703
|
+
const COMPONENT_NAME$k = 'vc-switch';
|
|
13694
13704
|
const Switch = /* @__PURE__ */ vue.defineComponent({
|
|
13695
|
-
name: COMPONENT_NAME$
|
|
13705
|
+
name: COMPONENT_NAME$k,
|
|
13696
13706
|
props: props$d,
|
|
13697
13707
|
// click -> onClick要被拦截,此处不能放置
|
|
13698
13708
|
emits: ['update:modelValue', 'change', 'click'],
|
|
@@ -13729,9 +13739,9 @@ const Switch = /* @__PURE__ */ vue.defineComponent({
|
|
|
13729
13739
|
|
|
13730
13740
|
/** @jsxImportSource vue */
|
|
13731
13741
|
|
|
13732
|
-
const COMPONENT_NAME$
|
|
13742
|
+
const COMPONENT_NAME$j = 'vcm-switch';
|
|
13733
13743
|
const MSwitch = /* @__PURE__ */ vue.defineComponent({
|
|
13734
|
-
name: COMPONENT_NAME$
|
|
13744
|
+
name: COMPONENT_NAME$j,
|
|
13735
13745
|
props: props$d,
|
|
13736
13746
|
// click -> onClick要被拦截,此处不能放置
|
|
13737
13747
|
emits: ['update:modelValue', 'change', 'click'],
|
|
@@ -14503,6 +14513,7 @@ class Store extends BaseWatcher {
|
|
|
14503
14513
|
});
|
|
14504
14514
|
}
|
|
14505
14515
|
setData(data) {
|
|
14516
|
+
const { primaryKey } = this.table.props;
|
|
14506
14517
|
const dataInstanceChanged = this.states._data !== data;
|
|
14507
14518
|
this.states._data = data;
|
|
14508
14519
|
this.states.data = data;
|
|
@@ -14514,19 +14525,22 @@ class Store extends BaseWatcher {
|
|
|
14514
14525
|
});
|
|
14515
14526
|
this.states.list = data.reduce((pre, row, index) => {
|
|
14516
14527
|
const cache = caches.get(row) || { heightMap: {} };
|
|
14517
|
-
|
|
14518
|
-
|
|
14519
|
-
|
|
14520
|
-
|
|
14521
|
-
|
|
14522
|
-
|
|
14523
|
-
|
|
14524
|
-
|
|
14525
|
-
|
|
14526
|
-
right: cache.heightMap.right || ""
|
|
14527
|
-
}
|
|
14528
|
+
const rows = [
|
|
14529
|
+
{
|
|
14530
|
+
index,
|
|
14531
|
+
data: row,
|
|
14532
|
+
height: cache.height || "",
|
|
14533
|
+
heightMap: {
|
|
14534
|
+
left: cache.heightMap.left || "",
|
|
14535
|
+
main: cache.heightMap.main || "",
|
|
14536
|
+
right: cache.heightMap.right || ""
|
|
14528
14537
|
}
|
|
14529
|
-
|
|
14538
|
+
}
|
|
14539
|
+
];
|
|
14540
|
+
const id = primaryKey ? rows.map((rowData) => getRowValue(rowData.data, primaryKey)).join(",") : index;
|
|
14541
|
+
pre.push({
|
|
14542
|
+
id: typeof id === "undefined" ? index : id,
|
|
14543
|
+
rows,
|
|
14530
14544
|
expand: false
|
|
14531
14545
|
});
|
|
14532
14546
|
return pre;
|
|
@@ -14840,9 +14854,9 @@ const useStates = (mapper, $store) => {
|
|
|
14840
14854
|
|
|
14841
14855
|
/** @jsxImportSource vue */
|
|
14842
14856
|
|
|
14843
|
-
const COMPONENT_NAME$
|
|
14857
|
+
const COMPONENT_NAME$i = 'vc-table-normal-list';
|
|
14844
14858
|
const NormalList = /* @__PURE__ */ vue.defineComponent({
|
|
14845
|
-
name: COMPONENT_NAME$
|
|
14859
|
+
name: COMPONENT_NAME$i,
|
|
14846
14860
|
props: {
|
|
14847
14861
|
data: {
|
|
14848
14862
|
type: Array,
|
|
@@ -14857,17 +14871,19 @@ const NormalList = /* @__PURE__ */ vue.defineComponent({
|
|
|
14857
14871
|
const handleResize = (e, index) => {
|
|
14858
14872
|
emit('row-resize', {
|
|
14859
14873
|
index,
|
|
14860
|
-
|
|
14874
|
+
height: e.height,
|
|
14875
|
+
width: e.width
|
|
14861
14876
|
});
|
|
14862
14877
|
};
|
|
14863
14878
|
return () => {
|
|
14864
|
-
return props.data.map((
|
|
14879
|
+
return props.data.map((mergeData, index) => {
|
|
14865
14880
|
return vue.createVNode(Resizer, {
|
|
14881
|
+
"key": mergeData.id,
|
|
14866
14882
|
"fill": false,
|
|
14867
14883
|
"onChange": e => handleResize(e, index)
|
|
14868
14884
|
}, {
|
|
14869
14885
|
default: () => [slots.default?.({
|
|
14870
|
-
row,
|
|
14886
|
+
row: mergeData,
|
|
14871
14887
|
index
|
|
14872
14888
|
})]
|
|
14873
14889
|
});
|
|
@@ -15016,32 +15032,6 @@ const TableBody = /* @__PURE__ */ vue.defineComponent({
|
|
|
15016
15032
|
table.hoverState.value = hoverState;
|
|
15017
15033
|
table.emit('cell-mouse-enter', hoverState.row, hoverState.column, hoverState.cell, e);
|
|
15018
15034
|
}
|
|
15019
|
-
|
|
15020
|
-
// 判断是否text-overflow, 如果是就显示tooltip
|
|
15021
|
-
const cellChild = e.target.querySelector('.vc-table__cell');
|
|
15022
|
-
if (!($.hasClass(cellChild, 'vc-popover') && cellChild.childNodes.length)) {
|
|
15023
|
-
return;
|
|
15024
|
-
}
|
|
15025
|
-
// 使用范围宽度而不是滚动宽度来确定文本是否溢出,以解决潜在的FireFox bug
|
|
15026
|
-
// https://bugzilla.mozilla.org/show_bug.cgi?id=1074543#c3
|
|
15027
|
-
const range = document.createRange();
|
|
15028
|
-
range.setStart(cellChild, 0);
|
|
15029
|
-
range.setEnd(cellChild, cellChild.childNodes.length);
|
|
15030
|
-
const rangeWidth = range.getBoundingClientRect().width;
|
|
15031
|
-
const padding = (parseInt(cellChild.style.paddingLeft, 10) || 0) + (parseInt(cellChild.style.paddingRight, 10) || 0);
|
|
15032
|
-
if (rangeWidth + padding > cellChild.offsetWidth || cellChild.scrollWidth > cellChild.offsetWidth) {
|
|
15033
|
-
Popover.open({
|
|
15034
|
-
el: document.body,
|
|
15035
|
-
name: 'vc-table-popover',
|
|
15036
|
-
// 确保不重复创建
|
|
15037
|
-
triggerEl: cell,
|
|
15038
|
-
hover: true,
|
|
15039
|
-
theme: 'dark',
|
|
15040
|
-
placement: 'top',
|
|
15041
|
-
content: cell.innerText || cell.textContent,
|
|
15042
|
-
alone: true
|
|
15043
|
-
});
|
|
15044
|
-
}
|
|
15045
15035
|
};
|
|
15046
15036
|
const handleCellMouseLeave = e => {
|
|
15047
15037
|
const cell = getCell(e);
|
|
@@ -15129,13 +15119,14 @@ const TableBody = /* @__PURE__ */ vue.defineComponent({
|
|
|
15129
15119
|
})]);
|
|
15130
15120
|
})]);
|
|
15131
15121
|
};
|
|
15132
|
-
const renderMergeRow =
|
|
15122
|
+
const renderMergeRow = mergeData => {
|
|
15133
15123
|
const {
|
|
15134
|
-
rows
|
|
15124
|
+
rows,
|
|
15125
|
+
id
|
|
15135
15126
|
} = mergeData;
|
|
15136
15127
|
return vue.createVNode("div", {
|
|
15137
15128
|
"class": "vc-table__merge-row",
|
|
15138
|
-
"key":
|
|
15129
|
+
"key": id
|
|
15139
15130
|
}, [rows.map(row => {
|
|
15140
15131
|
return renderRow(row, row.index);
|
|
15141
15132
|
})]);
|
|
@@ -15143,7 +15134,7 @@ const TableBody = /* @__PURE__ */ vue.defineComponent({
|
|
|
15143
15134
|
const handleMergeRowResize = v => {
|
|
15144
15135
|
if (table.props.rowHeight) return;
|
|
15145
15136
|
states.list[v.index].rows.forEach(row => {
|
|
15146
|
-
row.heightMap[props.fixed || 'main'] = v.
|
|
15137
|
+
row.heightMap[props.fixed || 'main'] = v.height;
|
|
15147
15138
|
const heights = [row.heightMap.main];
|
|
15148
15139
|
if (states.leftFixedCount) {
|
|
15149
15140
|
heights.push(row.heightMap.left);
|
|
@@ -15195,17 +15186,15 @@ const TableBody = /* @__PURE__ */ vue.defineComponent({
|
|
|
15195
15186
|
"style": props.heightStyle
|
|
15196
15187
|
}, {
|
|
15197
15188
|
default: ({
|
|
15198
|
-
row
|
|
15199
|
-
|
|
15200
|
-
}) => renderMergeRow(row, index)
|
|
15189
|
+
row
|
|
15190
|
+
}) => renderMergeRow(row)
|
|
15201
15191
|
}) : vue.createVNode(NormalList, {
|
|
15202
15192
|
"data": states.list,
|
|
15203
15193
|
"onRowResize": handleMergeRowResize
|
|
15204
15194
|
}, {
|
|
15205
15195
|
default: ({
|
|
15206
|
-
row
|
|
15207
|
-
|
|
15208
|
-
}) => renderMergeRow(row, index)
|
|
15196
|
+
row
|
|
15197
|
+
}) => renderMergeRow(row)
|
|
15209
15198
|
})]);
|
|
15210
15199
|
};
|
|
15211
15200
|
}
|
|
@@ -15699,9 +15688,9 @@ const props$c = {
|
|
|
15699
15688
|
|
|
15700
15689
|
/** @jsxImportSource vue */
|
|
15701
15690
|
|
|
15702
|
-
const COMPONENT_NAME$
|
|
15691
|
+
const COMPONENT_NAME$h = 'vc-table';
|
|
15703
15692
|
const Table = /* @__PURE__ */ vue.defineComponent({
|
|
15704
|
-
name: COMPONENT_NAME$
|
|
15693
|
+
name: COMPONENT_NAME$h,
|
|
15705
15694
|
props: props$c,
|
|
15706
15695
|
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'],
|
|
15707
15696
|
setup(props, {
|
|
@@ -16231,8 +16220,198 @@ const Table = /* @__PURE__ */ vue.defineComponent({
|
|
|
16231
16220
|
}
|
|
16232
16221
|
});
|
|
16233
16222
|
|
|
16234
|
-
const
|
|
16235
|
-
|
|
16223
|
+
const props$b = {
|
|
16224
|
+
tag: {
|
|
16225
|
+
type: String,
|
|
16226
|
+
default: "div"
|
|
16227
|
+
},
|
|
16228
|
+
value: {
|
|
16229
|
+
type: String,
|
|
16230
|
+
default: ""
|
|
16231
|
+
},
|
|
16232
|
+
line: {
|
|
16233
|
+
type: Number,
|
|
16234
|
+
default: 0
|
|
16235
|
+
},
|
|
16236
|
+
// TODO: 是否改为tail-indent来表示尾部缩进
|
|
16237
|
+
indent: {
|
|
16238
|
+
type: Number,
|
|
16239
|
+
default: 0
|
|
16240
|
+
},
|
|
16241
|
+
resize: {
|
|
16242
|
+
type: [Boolean, Number],
|
|
16243
|
+
default: 100
|
|
16244
|
+
},
|
|
16245
|
+
suffix: {
|
|
16246
|
+
type: String,
|
|
16247
|
+
default: "..."
|
|
16248
|
+
},
|
|
16249
|
+
placement: {
|
|
16250
|
+
type: String,
|
|
16251
|
+
default: "top"
|
|
16252
|
+
},
|
|
16253
|
+
portalClassName: [Object, String, Array],
|
|
16254
|
+
portalStyle: [Object, String, Array],
|
|
16255
|
+
renderRow: {
|
|
16256
|
+
type: Function,
|
|
16257
|
+
// 函数式可以用于高亮显示
|
|
16258
|
+
default: (props$) => {
|
|
16259
|
+
const { value } = props$;
|
|
16260
|
+
return vue.h("span", {}, value);
|
|
16261
|
+
}
|
|
16262
|
+
}
|
|
16263
|
+
};
|
|
16264
|
+
|
|
16265
|
+
const HIDDEN_TEXT_STYLE = `
|
|
16266
|
+
position: absolute!important;
|
|
16267
|
+
word-break: break-all!important;
|
|
16268
|
+
overflow: auto!important;
|
|
16269
|
+
opacity: 0!important;
|
|
16270
|
+
z-index: -1000!important;
|
|
16271
|
+
top: 0!important;
|
|
16272
|
+
right: 0!important;
|
|
16273
|
+
`;
|
|
16274
|
+
const SIZING_STYLE$1 = [
|
|
16275
|
+
"letter-spacing",
|
|
16276
|
+
"line-height",
|
|
16277
|
+
"padding-top",
|
|
16278
|
+
"padding-bottom",
|
|
16279
|
+
"font-family",
|
|
16280
|
+
"font-weight",
|
|
16281
|
+
"font-size",
|
|
16282
|
+
"text-rendering",
|
|
16283
|
+
"text-transform",
|
|
16284
|
+
"width",
|
|
16285
|
+
// 'text-indent', // 需要额外计算
|
|
16286
|
+
"padding-left",
|
|
16287
|
+
"padding-right",
|
|
16288
|
+
"border-width",
|
|
16289
|
+
"box-sizing"
|
|
16290
|
+
];
|
|
16291
|
+
let hiddenEl$1;
|
|
16292
|
+
const getFitIndex = (options = {}) => {
|
|
16293
|
+
const { el, line, value, suffix, indent } = options;
|
|
16294
|
+
let lineHeight = parseInt($.getStyle(el, "line-height"), 10);
|
|
16295
|
+
if (!hiddenEl$1) {
|
|
16296
|
+
hiddenEl$1 = document.createElement("div");
|
|
16297
|
+
document.body.appendChild(hiddenEl$1);
|
|
16298
|
+
}
|
|
16299
|
+
el.getAttribute("wrap") ? hiddenEl$1.setAttribute("wrap", el.getAttribute("wrap")) : hiddenEl$1.removeAttribute("wrap");
|
|
16300
|
+
const {
|
|
16301
|
+
paddingSize,
|
|
16302
|
+
borderSize,
|
|
16303
|
+
boxSizing,
|
|
16304
|
+
sizingStyle
|
|
16305
|
+
} = vcShared.Utils.getComputedStyle(el, SIZING_STYLE$1);
|
|
16306
|
+
const textIndent = `text-indent: ${parseInt($.getStyle(el, "text-indent"), 10) + indent}px;`;
|
|
16307
|
+
hiddenEl$1.setAttribute("style", `${sizingStyle};${textIndent};${HIDDEN_TEXT_STYLE}`);
|
|
16308
|
+
let sideHeight = paddingSize || 0;
|
|
16309
|
+
boxSizing === "border-box" && (sideHeight += borderSize);
|
|
16310
|
+
if (Number.isNaN(lineHeight)) {
|
|
16311
|
+
hiddenEl$1.innerText = ".";
|
|
16312
|
+
lineHeight = hiddenEl$1.clientHeight - sideHeight;
|
|
16313
|
+
}
|
|
16314
|
+
let endIndex = 0;
|
|
16315
|
+
hiddenEl$1.innerText = suffix;
|
|
16316
|
+
value.split("").forEach((item, i) => {
|
|
16317
|
+
let old = hiddenEl$1.innerText;
|
|
16318
|
+
old = old.substring(0, old.length - suffix.length);
|
|
16319
|
+
hiddenEl$1.innerText = old + item + suffix;
|
|
16320
|
+
if (hiddenEl$1.clientHeight - sideHeight > lineHeight * line && endIndex === 0) {
|
|
16321
|
+
endIndex = i;
|
|
16322
|
+
}
|
|
16323
|
+
});
|
|
16324
|
+
return endIndex;
|
|
16325
|
+
};
|
|
16326
|
+
|
|
16327
|
+
/** @jsxImportSource vue */
|
|
16328
|
+
|
|
16329
|
+
const COMPONENT_NAME$g = 'vc-text';
|
|
16330
|
+
const Text = /* @__PURE__ */ vue.defineComponent({
|
|
16331
|
+
name: COMPONENT_NAME$g,
|
|
16332
|
+
props: props$b,
|
|
16333
|
+
setup(props, {
|
|
16334
|
+
emit
|
|
16335
|
+
}) {
|
|
16336
|
+
const instance = vue.getCurrentInstance();
|
|
16337
|
+
const isActive = vue.ref(false);
|
|
16338
|
+
const endIndex = vue.ref(0);
|
|
16339
|
+
const styles = vue.computed(() => {
|
|
16340
|
+
return {
|
|
16341
|
+
cursor: endIndex.value === 0 ? 'unset' : 'pointer'
|
|
16342
|
+
};
|
|
16343
|
+
});
|
|
16344
|
+
const calcPosition = () => {
|
|
16345
|
+
const {
|
|
16346
|
+
suffix,
|
|
16347
|
+
line,
|
|
16348
|
+
value,
|
|
16349
|
+
indent
|
|
16350
|
+
} = props;
|
|
16351
|
+
if (line === 0) {
|
|
16352
|
+
endIndex.value = 0;
|
|
16353
|
+
isActive.value = true;
|
|
16354
|
+
} else {
|
|
16355
|
+
endIndex.value = getFitIndex({
|
|
16356
|
+
el: instance.vnode.el,
|
|
16357
|
+
line,
|
|
16358
|
+
value,
|
|
16359
|
+
suffix,
|
|
16360
|
+
indent
|
|
16361
|
+
});
|
|
16362
|
+
isActive.value = true;
|
|
16363
|
+
}
|
|
16364
|
+
emit('clip', endIndex.value);
|
|
16365
|
+
};
|
|
16366
|
+
const handleResize = props.resize === true || props.resize === 0 ? calcPosition : lodashEs.debounce(calcPosition, props.resize || 0);
|
|
16367
|
+
const handleMouseOver = e => {
|
|
16368
|
+
if (endIndex.value > 0) {
|
|
16369
|
+
Popover.open({
|
|
16370
|
+
el: document.body,
|
|
16371
|
+
name: 'vc-text-popover',
|
|
16372
|
+
// 确保不重复创建
|
|
16373
|
+
triggerEl: e.target,
|
|
16374
|
+
hover: true,
|
|
16375
|
+
theme: 'dark',
|
|
16376
|
+
placement: props.placement,
|
|
16377
|
+
portalClassName: props.portalClassName,
|
|
16378
|
+
portalStyle: props.portalStyle || `width: ${e.target.clientWidth}px`,
|
|
16379
|
+
content: props.value
|
|
16380
|
+
});
|
|
16381
|
+
}
|
|
16382
|
+
};
|
|
16383
|
+
const handleMouseOut = () => {
|
|
16384
|
+
// Do.
|
|
16385
|
+
};
|
|
16386
|
+
['value', 'indent', 'line'].forEach(key => {
|
|
16387
|
+
vue.watch(() => props[key], calcPosition);
|
|
16388
|
+
});
|
|
16389
|
+
vue.onMounted(() => {
|
|
16390
|
+
props.resize !== false && helperResize.Resize.on(instance.vnode.el, handleResize); // 首次会执行一次
|
|
16391
|
+
});
|
|
16392
|
+
vue.onBeforeUnmount(() => {
|
|
16393
|
+
props.resize !== false && helperResize.Resize.off(instance.vnode.el, handleResize);
|
|
16394
|
+
});
|
|
16395
|
+
const Content = props.tag;
|
|
16396
|
+
return () => {
|
|
16397
|
+
return vue.createVNode(Content, {
|
|
16398
|
+
"class": "vc-text",
|
|
16399
|
+
"style": styles.value,
|
|
16400
|
+
"onMouseover": handleMouseOver,
|
|
16401
|
+
"onMouseout": handleMouseOut
|
|
16402
|
+
}, {
|
|
16403
|
+
default: () => [isActive.value ? vue.createVNode(Customer, {
|
|
16404
|
+
"value": endIndex.value > 0 ? `${props.value.slice(0, endIndex.value)}${props.suffix}` : props.value,
|
|
16405
|
+
"index": endIndex.value,
|
|
16406
|
+
"render": props.renderRow
|
|
16407
|
+
}, null) : null]
|
|
16408
|
+
});
|
|
16409
|
+
};
|
|
16410
|
+
}
|
|
16411
|
+
});
|
|
16412
|
+
|
|
16413
|
+
const cellStarts = {
|
|
16414
|
+
default: {
|
|
16236
16415
|
order: ''
|
|
16237
16416
|
},
|
|
16238
16417
|
selection: {
|
|
@@ -16340,26 +16519,29 @@ const cellForced = {
|
|
|
16340
16519
|
};
|
|
16341
16520
|
|
|
16342
16521
|
// Cell默认渲染value 或 formatter
|
|
16343
|
-
const defaultRenderCell = ({
|
|
16344
|
-
|
|
16345
|
-
column = {},
|
|
16346
|
-
rowIndex
|
|
16347
|
-
}) => {
|
|
16522
|
+
const defaultRenderCell = (rowData = {}) => {
|
|
16523
|
+
const column = rowData.column;
|
|
16348
16524
|
const {
|
|
16349
16525
|
prop,
|
|
16350
16526
|
formatter
|
|
16351
16527
|
} = column;
|
|
16352
16528
|
let value;
|
|
16353
16529
|
if (prop) {
|
|
16354
|
-
value = Utils.getPropByPath(row, prop).v;
|
|
16530
|
+
value = Utils.getPropByPath(rowData.row, prop).v;
|
|
16355
16531
|
}
|
|
16356
16532
|
if (formatter) {
|
|
16357
|
-
return column.formatter(
|
|
16358
|
-
|
|
16359
|
-
|
|
16360
|
-
|
|
16361
|
-
|
|
16362
|
-
|
|
16533
|
+
return column.formatter(rowData);
|
|
16534
|
+
}
|
|
16535
|
+
const line = column.line || VcInstance.options.TableColumn?.line;
|
|
16536
|
+
if (line) {
|
|
16537
|
+
const style = {
|
|
16538
|
+
width: (column.realWidth || column.width) - 20 + 'px'
|
|
16539
|
+
};
|
|
16540
|
+
return vue.createVNode(Text, {
|
|
16541
|
+
"style": style,
|
|
16542
|
+
"line": line,
|
|
16543
|
+
"value": value
|
|
16544
|
+
}, null);
|
|
16363
16545
|
}
|
|
16364
16546
|
return value;
|
|
16365
16547
|
};
|
|
@@ -16412,6 +16594,11 @@ const TableColumn = /* @__PURE__ */ vue.defineComponent({
|
|
|
16412
16594
|
type: String,
|
|
16413
16595
|
default: 'default'
|
|
16414
16596
|
},
|
|
16597
|
+
// 默认只展示一行
|
|
16598
|
+
line: {
|
|
16599
|
+
type: Number,
|
|
16600
|
+
default: 0
|
|
16601
|
+
},
|
|
16415
16602
|
label: String,
|
|
16416
16603
|
customClass: String,
|
|
16417
16604
|
labelClass: String,
|
|
@@ -16426,7 +16613,6 @@ const TableColumn = /* @__PURE__ */ vue.defineComponent({
|
|
|
16426
16613
|
columnKey: String,
|
|
16427
16614
|
align: String,
|
|
16428
16615
|
headerAlign: String,
|
|
16429
|
-
showPopover: Boolean,
|
|
16430
16616
|
fixed: [Boolean, String],
|
|
16431
16617
|
formatter: Function,
|
|
16432
16618
|
selectable: Function,
|
|
@@ -16574,12 +16760,6 @@ const TableColumn = /* @__PURE__ */ vue.defineComponent({
|
|
|
16574
16760
|
"class": "vc-table-un-expand__indent"
|
|
16575
16761
|
}, null);
|
|
16576
16762
|
}
|
|
16577
|
-
if (data.column.showPopover) {
|
|
16578
|
-
$props.class += ' vc-popover';
|
|
16579
|
-
$props.style = {
|
|
16580
|
-
width: (data.column.realWidth || data.column.width) - 1 + 'px'
|
|
16581
|
-
};
|
|
16582
|
-
}
|
|
16583
16763
|
const {
|
|
16584
16764
|
placeholder
|
|
16585
16765
|
} = table.props;
|
|
@@ -16679,7 +16859,7 @@ const TableColumn = /* @__PURE__ */ vue.defineComponent({
|
|
|
16679
16859
|
const MTable = Table;
|
|
16680
16860
|
const MTableColumn = TableColumn;
|
|
16681
16861
|
|
|
16682
|
-
const props$
|
|
16862
|
+
const props$a = {
|
|
16683
16863
|
type: {
|
|
16684
16864
|
type: String,
|
|
16685
16865
|
validator: (v) => /^(line|card)$/.test(v),
|
|
@@ -16837,7 +17017,7 @@ const useTabs = (options = {}) => {
|
|
|
16837
17017
|
const COMPONENT_NAME$f = 'vc-tabs';
|
|
16838
17018
|
const Tabs = /* @__PURE__ */ vue.defineComponent({
|
|
16839
17019
|
name: COMPONENT_NAME$f,
|
|
16840
|
-
props: props$
|
|
17020
|
+
props: props$a,
|
|
16841
17021
|
emits: ['update:modelValue', 'change', 'click'],
|
|
16842
17022
|
setup(props, {
|
|
16843
17023
|
slots
|
|
@@ -17002,7 +17182,7 @@ const Tabs = /* @__PURE__ */ vue.defineComponent({
|
|
|
17002
17182
|
}
|
|
17003
17183
|
});
|
|
17004
17184
|
|
|
17005
|
-
const props$
|
|
17185
|
+
const props$9 = {
|
|
17006
17186
|
value: {
|
|
17007
17187
|
type: [String, Number]
|
|
17008
17188
|
},
|
|
@@ -17087,7 +17267,7 @@ const useTabsPane = () => {
|
|
|
17087
17267
|
const COMPONENT_NAME$e = 'vc-tabs-pane';
|
|
17088
17268
|
const TabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
17089
17269
|
name: COMPONENT_NAME$e,
|
|
17090
|
-
props: props$
|
|
17270
|
+
props: props$9,
|
|
17091
17271
|
setup(_, {
|
|
17092
17272
|
slots
|
|
17093
17273
|
}) {
|
|
@@ -17102,8 +17282,8 @@ const TabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
|
17102
17282
|
}
|
|
17103
17283
|
});
|
|
17104
17284
|
|
|
17105
|
-
const props$
|
|
17106
|
-
...props$
|
|
17285
|
+
const props$8 = {
|
|
17286
|
+
...props$a,
|
|
17107
17287
|
theme: {
|
|
17108
17288
|
type: String,
|
|
17109
17289
|
default: "light",
|
|
@@ -17144,7 +17324,7 @@ const props$9 = {
|
|
|
17144
17324
|
const COMPONENT_NAME$d = 'vcm-tabs';
|
|
17145
17325
|
const MTabs = /* @__PURE__ */ vue.defineComponent({
|
|
17146
17326
|
name: COMPONENT_NAME$d,
|
|
17147
|
-
props: props$
|
|
17327
|
+
props: props$8,
|
|
17148
17328
|
emits: ['update:modelValue', 'change', 'click'],
|
|
17149
17329
|
setup(props, {
|
|
17150
17330
|
slots
|
|
@@ -17411,7 +17591,7 @@ const MTabs = /* @__PURE__ */ vue.defineComponent({
|
|
|
17411
17591
|
const COMPONENT_NAME$c = 'vcm-tabs-pane';
|
|
17412
17592
|
const MTabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
17413
17593
|
name: COMPONENT_NAME$c,
|
|
17414
|
-
props: props$
|
|
17594
|
+
props: props$9,
|
|
17415
17595
|
setup(_, {
|
|
17416
17596
|
slots
|
|
17417
17597
|
}) {
|
|
@@ -17428,56 +17608,18 @@ const MTabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
|
17428
17608
|
|
|
17429
17609
|
const MTag = Tag;
|
|
17430
17610
|
|
|
17431
|
-
const
|
|
17432
|
-
tag: {
|
|
17433
|
-
type: String,
|
|
17434
|
-
default: "div"
|
|
17435
|
-
},
|
|
17436
|
-
value: {
|
|
17437
|
-
type: String,
|
|
17438
|
-
default: ""
|
|
17439
|
-
},
|
|
17440
|
-
line: {
|
|
17441
|
-
type: Number,
|
|
17442
|
-
default: 0
|
|
17443
|
-
},
|
|
17444
|
-
// TODO: 是否改为tail-indent来表示尾部缩进
|
|
17445
|
-
indent: {
|
|
17446
|
-
type: Number,
|
|
17447
|
-
default: 0
|
|
17448
|
-
},
|
|
17449
|
-
resize: {
|
|
17450
|
-
type: [Boolean, Number],
|
|
17451
|
-
default: 100
|
|
17452
|
-
},
|
|
17453
|
-
suffix: {
|
|
17454
|
-
type: String,
|
|
17455
|
-
default: "..."
|
|
17456
|
-
},
|
|
17457
|
-
placement: {
|
|
17458
|
-
type: String,
|
|
17459
|
-
default: "top"
|
|
17460
|
-
},
|
|
17461
|
-
portalClassName: [Object, String, Array],
|
|
17462
|
-
portalStyle: [Object, String, Array],
|
|
17463
|
-
renderRow: {
|
|
17464
|
-
type: Function,
|
|
17465
|
-
// 函数式可以用于高亮显示
|
|
17466
|
-
default: (props$) => {
|
|
17467
|
-
const { value } = props$;
|
|
17468
|
-
return vue.h("span", {}, value);
|
|
17469
|
-
}
|
|
17470
|
-
}
|
|
17471
|
-
};
|
|
17611
|
+
const MText = Text;
|
|
17472
17612
|
|
|
17473
|
-
const
|
|
17474
|
-
|
|
17475
|
-
|
|
17476
|
-
|
|
17477
|
-
|
|
17478
|
-
|
|
17479
|
-
|
|
17480
|
-
|
|
17613
|
+
const HIDDEN_TEXTAREA_STYLE = `
|
|
17614
|
+
min-height:0 !important;
|
|
17615
|
+
max-height:none !important;
|
|
17616
|
+
height:0 !important;
|
|
17617
|
+
visibility:hidden !important;
|
|
17618
|
+
overflow:hidden !important;
|
|
17619
|
+
position:absolute !important;
|
|
17620
|
+
z-index:-1000 !important;
|
|
17621
|
+
top:0 !important;
|
|
17622
|
+
right:0 !important
|
|
17481
17623
|
`;
|
|
17482
17624
|
const SIZING_STYLE = [
|
|
17483
17625
|
"letter-spacing",
|
|
@@ -17490,18 +17632,18 @@ const SIZING_STYLE = [
|
|
|
17490
17632
|
"text-rendering",
|
|
17491
17633
|
"text-transform",
|
|
17492
17634
|
"width",
|
|
17493
|
-
|
|
17635
|
+
"text-indent",
|
|
17494
17636
|
"padding-left",
|
|
17495
17637
|
"padding-right",
|
|
17496
17638
|
"border-width",
|
|
17497
17639
|
"box-sizing"
|
|
17498
17640
|
];
|
|
17499
17641
|
let hiddenEl;
|
|
17500
|
-
const
|
|
17501
|
-
|
|
17502
|
-
|
|
17642
|
+
const getComputedHeight = (options = {}) => {
|
|
17643
|
+
if (vcShared.IS_SERVER) return {};
|
|
17644
|
+
const { el, minRows = null, maxRows = null } = options;
|
|
17503
17645
|
if (!hiddenEl) {
|
|
17504
|
-
hiddenEl = document.createElement("
|
|
17646
|
+
hiddenEl = document.createElement("textarea");
|
|
17505
17647
|
document.body.appendChild(hiddenEl);
|
|
17506
17648
|
}
|
|
17507
17649
|
el.getAttribute("wrap") ? hiddenEl.setAttribute("wrap", el.getAttribute("wrap")) : hiddenEl.removeAttribute("wrap");
|
|
@@ -17511,141 +17653,343 @@ const getFitIndex = (options = {}) => {
|
|
|
17511
17653
|
boxSizing,
|
|
17512
17654
|
sizingStyle
|
|
17513
17655
|
} = vcShared.Utils.getComputedStyle(el, SIZING_STYLE);
|
|
17514
|
-
|
|
17515
|
-
hiddenEl.
|
|
17516
|
-
let
|
|
17517
|
-
|
|
17518
|
-
|
|
17519
|
-
|
|
17520
|
-
|
|
17656
|
+
hiddenEl.setAttribute("style", `${sizingStyle};${HIDDEN_TEXTAREA_STYLE}`);
|
|
17657
|
+
hiddenEl.value = el.value || el.placeholder || "";
|
|
17658
|
+
let minHeight = Number.MIN_SAFE_INTEGER;
|
|
17659
|
+
let maxHeight = Number.MAX_SAFE_INTEGER;
|
|
17660
|
+
let height = hiddenEl.scrollHeight;
|
|
17661
|
+
let overflowY;
|
|
17662
|
+
if (boxSizing === "border-box") {
|
|
17663
|
+
height += borderSize;
|
|
17664
|
+
} else if (boxSizing === "content-box") {
|
|
17665
|
+
height -= paddingSize;
|
|
17666
|
+
}
|
|
17667
|
+
if (minRows !== null || maxRows !== null) {
|
|
17668
|
+
hiddenEl.value = " ";
|
|
17669
|
+
const singleRowHeight = hiddenEl.scrollHeight - paddingSize;
|
|
17670
|
+
if (minRows !== null) {
|
|
17671
|
+
minHeight = singleRowHeight * minRows;
|
|
17672
|
+
if (boxSizing === "border-box") {
|
|
17673
|
+
minHeight = minHeight + paddingSize + borderSize;
|
|
17674
|
+
}
|
|
17675
|
+
height = Math.max(minHeight, height);
|
|
17676
|
+
}
|
|
17677
|
+
if (maxRows !== null) {
|
|
17678
|
+
maxHeight = singleRowHeight * maxRows;
|
|
17679
|
+
if (boxSizing === "border-box") {
|
|
17680
|
+
maxHeight = maxHeight + paddingSize + borderSize;
|
|
17681
|
+
}
|
|
17682
|
+
overflowY = height > maxHeight ? "" : "hidden";
|
|
17683
|
+
height = Math.min(maxHeight, height);
|
|
17684
|
+
}
|
|
17521
17685
|
}
|
|
17522
|
-
|
|
17523
|
-
|
|
17524
|
-
|
|
17525
|
-
|
|
17526
|
-
|
|
17527
|
-
|
|
17528
|
-
|
|
17529
|
-
|
|
17686
|
+
if (!maxRows) {
|
|
17687
|
+
overflowY = "hidden";
|
|
17688
|
+
}
|
|
17689
|
+
return {
|
|
17690
|
+
height: `${height}px`,
|
|
17691
|
+
minHeight: `${minHeight}px`,
|
|
17692
|
+
maxHeight: `${maxHeight}px`,
|
|
17693
|
+
overflowY
|
|
17694
|
+
};
|
|
17695
|
+
};
|
|
17696
|
+
|
|
17697
|
+
const useTextarea = (textarea, expose) => {
|
|
17698
|
+
const attrs = vue.useAttrs();
|
|
17699
|
+
const instance = vue.getCurrentInstance();
|
|
17700
|
+
const props = instance.props;
|
|
17701
|
+
const { emit } = instance;
|
|
17702
|
+
const formItem = vue.inject("vc-form-item", {});
|
|
17703
|
+
const currentValue = vue.ref(null);
|
|
17704
|
+
const isOnComposition = vue.ref(false);
|
|
17705
|
+
const isFocus = vue.ref(false);
|
|
17706
|
+
const calcTextareaStyle = vue.ref({});
|
|
17707
|
+
const contentStyle = vue.ref({});
|
|
17708
|
+
const currentMaxlength = vue.computed(() => {
|
|
17709
|
+
const value = currentValue.value;
|
|
17710
|
+
const { maxlength, bytes } = props;
|
|
17711
|
+
return Array.isArray(value) || !maxlength || !bytes ? maxlength : getFitMaxLength(value, maxlength);
|
|
17712
|
+
});
|
|
17713
|
+
const sync = (v, e, force) => {
|
|
17714
|
+
if (!force && v === currentValue.value) return;
|
|
17715
|
+
if (!props.controllable) {
|
|
17716
|
+
currentValue.value = v;
|
|
17717
|
+
}
|
|
17718
|
+
emit("update:modelValue", v, e);
|
|
17719
|
+
emit("input", v, e);
|
|
17720
|
+
emit("change", v, e);
|
|
17721
|
+
props.allowDispatch && formItem?.change?.(v);
|
|
17722
|
+
};
|
|
17723
|
+
const forceUpdate = () => {
|
|
17724
|
+
instance.proxy?.$forceUpdate?.();
|
|
17725
|
+
};
|
|
17726
|
+
const refresh = () => {
|
|
17727
|
+
if (!props.autosize) return;
|
|
17728
|
+
const { minRows, maxRows } = props.autosize;
|
|
17729
|
+
vue.nextTick(() => {
|
|
17730
|
+
calcTextareaStyle.value = getComputedHeight({
|
|
17731
|
+
el: textarea.value,
|
|
17732
|
+
minRows,
|
|
17733
|
+
maxRows
|
|
17734
|
+
});
|
|
17735
|
+
});
|
|
17736
|
+
};
|
|
17737
|
+
const handleKeydown = (e) => {
|
|
17738
|
+
emit("keydown", e);
|
|
17739
|
+
};
|
|
17740
|
+
const handleKeypress = (e) => {
|
|
17741
|
+
emit("keypress", e);
|
|
17742
|
+
};
|
|
17743
|
+
const handleKeyup = (e) => {
|
|
17744
|
+
if (e.keyCode == 13) {
|
|
17745
|
+
emit("enter", e);
|
|
17746
|
+
}
|
|
17747
|
+
emit("keyup", e);
|
|
17748
|
+
};
|
|
17749
|
+
const handleFocus = (e) => {
|
|
17750
|
+
isFocus.value = true;
|
|
17751
|
+
emit("focus", e);
|
|
17752
|
+
};
|
|
17753
|
+
const handleBlur = (e) => {
|
|
17754
|
+
isFocus.value = false;
|
|
17755
|
+
emit("blur", e);
|
|
17756
|
+
props.allowDispatch && formItem?.blur?.(currentValue.value);
|
|
17757
|
+
};
|
|
17758
|
+
const handleChange = (e) => {
|
|
17759
|
+
emit("change", e);
|
|
17760
|
+
};
|
|
17761
|
+
const handleInput = (e) => {
|
|
17762
|
+
if (isOnComposition.value) return;
|
|
17763
|
+
let value = textarea.value.value;
|
|
17764
|
+
if (typeof props.maxlength !== "undefined" && props.bytes && e.inputType !== "deleteContentBackward") {
|
|
17765
|
+
const fitValue = getFitValue(value, props.maxlength);
|
|
17766
|
+
if (value !== fitValue) {
|
|
17767
|
+
value = fitValue;
|
|
17768
|
+
}
|
|
17769
|
+
}
|
|
17770
|
+
sync(value, e, e.inputType === "insertFromPaste");
|
|
17771
|
+
forceUpdate();
|
|
17772
|
+
};
|
|
17773
|
+
const handleComposition = (e) => {
|
|
17774
|
+
if (e.type === "compositionstart") {
|
|
17775
|
+
isOnComposition.value = true;
|
|
17776
|
+
}
|
|
17777
|
+
if (e.type === "compositionend") {
|
|
17778
|
+
isOnComposition.value = false;
|
|
17779
|
+
handleInput(e);
|
|
17530
17780
|
}
|
|
17781
|
+
};
|
|
17782
|
+
const handleResize = (e) => {
|
|
17783
|
+
contentStyle.value = {
|
|
17784
|
+
height: `${textarea.value ? textarea.value.offsetHeight : 0}px`
|
|
17785
|
+
};
|
|
17786
|
+
emit("resize", e);
|
|
17787
|
+
};
|
|
17788
|
+
const handlePaste = (e) => {
|
|
17789
|
+
emit("paste", e, e.clipboardData.getData("text"));
|
|
17790
|
+
};
|
|
17791
|
+
const classes = vue.computed(() => {
|
|
17792
|
+
return {
|
|
17793
|
+
"is-focus": isFocus.value,
|
|
17794
|
+
"is-disabled": props.disabled
|
|
17795
|
+
};
|
|
17531
17796
|
});
|
|
17532
|
-
|
|
17797
|
+
const listeners = vue.computed(() => {
|
|
17798
|
+
return {
|
|
17799
|
+
onKeyup: handleKeyup,
|
|
17800
|
+
onKeypress: handleKeypress,
|
|
17801
|
+
onKeydown: handleKeydown,
|
|
17802
|
+
onFocus: handleFocus,
|
|
17803
|
+
onBlur: handleBlur,
|
|
17804
|
+
onCompositionstart: handleComposition,
|
|
17805
|
+
onCompositionupdate: handleComposition,
|
|
17806
|
+
onCompositionend: handleComposition,
|
|
17807
|
+
onInput: handleInput,
|
|
17808
|
+
onChange: handleChange,
|
|
17809
|
+
onPaste: handlePaste
|
|
17810
|
+
};
|
|
17811
|
+
});
|
|
17812
|
+
const binds = vue.computed(() => {
|
|
17813
|
+
return {
|
|
17814
|
+
id: props.id,
|
|
17815
|
+
autocomplete: attrs.autocomplete,
|
|
17816
|
+
spellcheck: attrs.spellcheck,
|
|
17817
|
+
placeholder: attrs.placeholder,
|
|
17818
|
+
readonly: attrs.readonly,
|
|
17819
|
+
name: attrs.name,
|
|
17820
|
+
autofocus: attrs.autofocus,
|
|
17821
|
+
disabled: props.disabled,
|
|
17822
|
+
maxlength: props.maxlength,
|
|
17823
|
+
rows: props.rows,
|
|
17824
|
+
wrap: props.wrap
|
|
17825
|
+
};
|
|
17826
|
+
});
|
|
17827
|
+
vue.watch(
|
|
17828
|
+
() => props.modelValue,
|
|
17829
|
+
(v) => {
|
|
17830
|
+
if (props.controllable || v !== currentValue.value) {
|
|
17831
|
+
currentValue.value = v;
|
|
17832
|
+
refresh();
|
|
17833
|
+
}
|
|
17834
|
+
},
|
|
17835
|
+
{ immediate: true }
|
|
17836
|
+
);
|
|
17837
|
+
vue.onMounted(() => {
|
|
17838
|
+
helperResize.Resize.on(textarea.value, handleResize);
|
|
17839
|
+
refresh();
|
|
17840
|
+
});
|
|
17841
|
+
vue.onBeforeUnmount(() => {
|
|
17842
|
+
helperResize.Resize.off(textarea.value, handleResize);
|
|
17843
|
+
});
|
|
17844
|
+
const exposed = useNativeEmitter(textarea);
|
|
17845
|
+
expose?.({
|
|
17846
|
+
...exposed,
|
|
17847
|
+
refresh
|
|
17848
|
+
});
|
|
17849
|
+
return {
|
|
17850
|
+
currentValue,
|
|
17851
|
+
isOnComposition,
|
|
17852
|
+
isFocus,
|
|
17853
|
+
calcTextareaStyle,
|
|
17854
|
+
contentStyle,
|
|
17855
|
+
classes,
|
|
17856
|
+
listeners,
|
|
17857
|
+
binds,
|
|
17858
|
+
currentMaxlength
|
|
17859
|
+
};
|
|
17860
|
+
};
|
|
17861
|
+
|
|
17862
|
+
const inputKeys = [
|
|
17863
|
+
"id",
|
|
17864
|
+
"disabled",
|
|
17865
|
+
"maxlength",
|
|
17866
|
+
"allowDispatch",
|
|
17867
|
+
"modelValue",
|
|
17868
|
+
"bytes",
|
|
17869
|
+
"controllable"
|
|
17870
|
+
];
|
|
17871
|
+
const props$7 = {
|
|
17872
|
+
...lodashEs.pick(props$$, inputKeys),
|
|
17873
|
+
wrap: {
|
|
17874
|
+
type: String,
|
|
17875
|
+
validator: (v) => /(soft|hard)/.test(v),
|
|
17876
|
+
default: "soft"
|
|
17877
|
+
},
|
|
17878
|
+
rows: {
|
|
17879
|
+
type: Number,
|
|
17880
|
+
default: 2
|
|
17881
|
+
},
|
|
17882
|
+
autosize: {
|
|
17883
|
+
type: [Boolean, Object],
|
|
17884
|
+
default: false
|
|
17885
|
+
},
|
|
17886
|
+
textareaStyle: {
|
|
17887
|
+
type: [Object, Array]
|
|
17888
|
+
}
|
|
17533
17889
|
};
|
|
17534
17890
|
|
|
17535
17891
|
/** @jsxImportSource vue */
|
|
17536
17892
|
|
|
17537
|
-
const COMPONENT_NAME$b = 'vc-
|
|
17538
|
-
const
|
|
17893
|
+
const COMPONENT_NAME$b = 'vc-textarea';
|
|
17894
|
+
const Textarea = /* @__PURE__ */ vue.defineComponent({
|
|
17539
17895
|
name: COMPONENT_NAME$b,
|
|
17540
|
-
props: props$
|
|
17896
|
+
props: Object.assign(props$7, {
|
|
17897
|
+
indicator: {
|
|
17898
|
+
type: [Boolean, Object],
|
|
17899
|
+
default: false
|
|
17900
|
+
},
|
|
17901
|
+
indicateClass: String
|
|
17902
|
+
}),
|
|
17903
|
+
emits: ['update:modelValue', 'input', 'change', 'focus', 'blur', 'clear', 'paste', 'keydown', 'keypress', 'keyup', 'enter', 'cancel', 'resize'],
|
|
17541
17904
|
setup(props, {
|
|
17542
|
-
|
|
17905
|
+
expose
|
|
17543
17906
|
}) {
|
|
17544
|
-
const
|
|
17545
|
-
const
|
|
17546
|
-
|
|
17547
|
-
|
|
17548
|
-
|
|
17549
|
-
|
|
17550
|
-
|
|
17551
|
-
|
|
17552
|
-
|
|
17553
|
-
|
|
17554
|
-
|
|
17555
|
-
|
|
17556
|
-
|
|
17557
|
-
|
|
17558
|
-
}
|
|
17559
|
-
if (line === 0) {
|
|
17560
|
-
endIndex.value = 0;
|
|
17561
|
-
isActive.value = true;
|
|
17562
|
-
} else {
|
|
17563
|
-
endIndex.value = getFitIndex({
|
|
17564
|
-
el: instance.vnode.el,
|
|
17565
|
-
line,
|
|
17566
|
-
value,
|
|
17567
|
-
suffix,
|
|
17568
|
-
indent
|
|
17569
|
-
});
|
|
17570
|
-
isActive.value = true;
|
|
17571
|
-
}
|
|
17572
|
-
emit('clip', endIndex.value);
|
|
17573
|
-
};
|
|
17574
|
-
const handleResize = props.resize === true || props.resize === 0 ? calcPosition : lodashEs.debounce(calcPosition, props.resize || 0);
|
|
17575
|
-
const handleMouseOver = e => {
|
|
17576
|
-
if (endIndex.value > 0) {
|
|
17577
|
-
Popover.open({
|
|
17578
|
-
el: document.body,
|
|
17579
|
-
name: 'vc-text-popover',
|
|
17580
|
-
// 确保不重复创建
|
|
17581
|
-
triggerEl: e.target,
|
|
17582
|
-
hover: true,
|
|
17583
|
-
theme: 'dark',
|
|
17584
|
-
placement: props.placement,
|
|
17585
|
-
portalClassName: props.portalClassName,
|
|
17586
|
-
portalStyle: props.portalStyle || `width: ${e.target.clientWidth}px`,
|
|
17587
|
-
content: props.value
|
|
17588
|
-
});
|
|
17589
|
-
}
|
|
17590
|
-
};
|
|
17591
|
-
const handleMouseOut = () => {
|
|
17592
|
-
// Do.
|
|
17593
|
-
};
|
|
17594
|
-
['value', 'indent', 'line'].forEach(key => {
|
|
17595
|
-
vue.watch(() => props[key], calcPosition);
|
|
17596
|
-
});
|
|
17597
|
-
vue.onMounted(() => {
|
|
17598
|
-
props.resize !== false && helperResize.Resize.on(instance.vnode.el, handleResize); // 首次会执行一次
|
|
17907
|
+
const textarea = vue.ref();
|
|
17908
|
+
const {
|
|
17909
|
+
currentValue,
|
|
17910
|
+
classes,
|
|
17911
|
+
contentStyle,
|
|
17912
|
+
listeners,
|
|
17913
|
+
binds,
|
|
17914
|
+
calcTextareaStyle,
|
|
17915
|
+
currentMaxlength
|
|
17916
|
+
} = useTextarea(textarea, expose);
|
|
17917
|
+
const indicatorNum = vue.computed(() => {
|
|
17918
|
+
const currentLength = (String(props.modelValue) || '').length;
|
|
17919
|
+
const extraLength = props.bytes ? getBytesSize(props.modelValue) || 0 : 0;
|
|
17920
|
+
const length = props.indicator && props.indicator.inverted ? props.maxlength + extraLength - currentLength : currentLength - extraLength;
|
|
17921
|
+
return `${length}/${props.maxlength}`;
|
|
17599
17922
|
});
|
|
17600
|
-
vue.
|
|
17601
|
-
props.
|
|
17923
|
+
const indicateInline = vue.computed(() => {
|
|
17924
|
+
return props.indicator && props.indicator.inline;
|
|
17602
17925
|
});
|
|
17603
|
-
const Content = props.tag;
|
|
17604
17926
|
return () => {
|
|
17605
|
-
return vue.createVNode(
|
|
17606
|
-
"class":
|
|
17607
|
-
|
|
17608
|
-
"
|
|
17609
|
-
|
|
17610
|
-
|
|
17611
|
-
|
|
17612
|
-
|
|
17613
|
-
|
|
17614
|
-
|
|
17615
|
-
|
|
17616
|
-
|
|
17927
|
+
return vue.createVNode("div", {
|
|
17928
|
+
"class": [classes.value, 'vc-textarea']
|
|
17929
|
+
}, [vue.createVNode("div", {
|
|
17930
|
+
"class": "vc-textarea__wrapper"
|
|
17931
|
+
}, [vue.createVNode("div", {
|
|
17932
|
+
"style": contentStyle.value,
|
|
17933
|
+
"class": ['vc-textarea__content']
|
|
17934
|
+
}, [vue.createVNode("textarea", vue.mergeProps({
|
|
17935
|
+
"ref": textarea
|
|
17936
|
+
}, binds.value, listeners.value, {
|
|
17937
|
+
"value": currentValue.value,
|
|
17938
|
+
"maxlength": currentMaxlength.value,
|
|
17939
|
+
"style": [props.textareaStyle, calcTextareaStyle.value]
|
|
17940
|
+
}), null)]), props.indicator && vue.createVNode("div", {
|
|
17941
|
+
"class": [props.indicateClass, {
|
|
17942
|
+
'is-inline': indicateInline.value
|
|
17943
|
+
}, 'vc-textarea__indicator']
|
|
17944
|
+
}, [indicatorNum.value])])]);
|
|
17617
17945
|
};
|
|
17618
17946
|
}
|
|
17619
17947
|
});
|
|
17620
17948
|
|
|
17621
|
-
const MText = Text;
|
|
17622
|
-
|
|
17623
|
-
const props$7 = {
|
|
17624
|
-
tag: {
|
|
17625
|
-
type: String,
|
|
17626
|
-
default: "div"
|
|
17627
|
-
}
|
|
17628
|
-
};
|
|
17629
|
-
|
|
17630
17949
|
/** @jsxImportSource vue */
|
|
17631
17950
|
|
|
17632
|
-
const COMPONENT_NAME$a = '
|
|
17633
|
-
const
|
|
17951
|
+
const COMPONENT_NAME$a = 'vcm-textarea';
|
|
17952
|
+
const MTextarea = /* @__PURE__ */ vue.defineComponent({
|
|
17634
17953
|
name: COMPONENT_NAME$a,
|
|
17635
|
-
props: props$7,
|
|
17954
|
+
props: Object.assign(props$7, {
|
|
17955
|
+
align: {
|
|
17956
|
+
type: String,
|
|
17957
|
+
default: 'left'
|
|
17958
|
+
}
|
|
17959
|
+
}),
|
|
17960
|
+
emits: ['update:modelValue', 'input', 'change', 'focus', 'blur', 'clear', 'paste', 'keydown', 'keypress', 'keyup', 'enter', 'cancel', 'resize'],
|
|
17636
17961
|
setup(props, {
|
|
17637
|
-
|
|
17962
|
+
expose
|
|
17638
17963
|
}) {
|
|
17964
|
+
const textarea = vue.ref();
|
|
17965
|
+
const {
|
|
17966
|
+
currentValue,
|
|
17967
|
+
classes,
|
|
17968
|
+
contentStyle,
|
|
17969
|
+
listeners,
|
|
17970
|
+
binds,
|
|
17971
|
+
calcTextareaStyle,
|
|
17972
|
+
currentMaxlength
|
|
17973
|
+
} = useTextarea(textarea, expose);
|
|
17639
17974
|
return () => {
|
|
17640
17975
|
return vue.createVNode("div", {
|
|
17641
|
-
"class":
|
|
17642
|
-
}, [
|
|
17976
|
+
"class": [classes.value, 'vcm-textarea']
|
|
17977
|
+
}, [vue.createVNode("div", {
|
|
17978
|
+
"class": "vcm-textarea__wrapper"
|
|
17979
|
+
}, [vue.createVNode("div", {
|
|
17980
|
+
"style": contentStyle.value,
|
|
17981
|
+
"class": ['vcm-textarea__content']
|
|
17982
|
+
}, [vue.createVNode("textarea", vue.mergeProps({
|
|
17983
|
+
"ref": textarea
|
|
17984
|
+
}, binds.value, listeners.value, {
|
|
17985
|
+
"value": currentValue.value,
|
|
17986
|
+
"maxlength": currentMaxlength.value,
|
|
17987
|
+
"style": [props.textareaStyle, calcTextareaStyle.value]
|
|
17988
|
+
}), null)])])]);
|
|
17643
17989
|
};
|
|
17644
17990
|
}
|
|
17645
17991
|
});
|
|
17646
17992
|
|
|
17647
|
-
const MTextarea = Textarea;
|
|
17648
|
-
|
|
17649
17993
|
const props$6 = {
|
|
17650
17994
|
tag: {
|
|
17651
17995
|
type: String,
|