@deot/vc-components 1.0.27 → 1.0.29
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 +835 -432
- package/dist/index.d.ts +460 -22
- package/dist/index.iife.js +825 -422
- package/dist/index.js +833 -434
- package/dist/index.style.css +1 -1
- package/dist/index.umd.cjs +825 -422
- package/package.json +1 -1
package/dist/index.iife.js
CHANGED
|
@@ -64,9 +64,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
64
64
|
|
|
65
65
|
/** @jsxImportSource vue */
|
|
66
66
|
|
|
67
|
-
const COMPONENT_NAME$
|
|
67
|
+
const COMPONENT_NAME$22 = 'vc-action-sheet';
|
|
68
68
|
const ActionSheet = /* @__PURE__ */ vue.defineComponent({
|
|
69
|
-
name: COMPONENT_NAME$
|
|
69
|
+
name: COMPONENT_NAME$22,
|
|
70
70
|
props: props$1q,
|
|
71
71
|
setup(props, {
|
|
72
72
|
slots
|
|
@@ -253,9 +253,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
253
253
|
|
|
254
254
|
/** @jsxImportSource vue */
|
|
255
255
|
|
|
256
|
-
const COMPONENT_NAME$
|
|
256
|
+
const COMPONENT_NAME$21 = 'vc-icon';
|
|
257
257
|
const Icon = /* @__PURE__ */ vue.defineComponent({
|
|
258
|
-
name: COMPONENT_NAME$
|
|
258
|
+
name: COMPONENT_NAME$21,
|
|
259
259
|
props: props$1o,
|
|
260
260
|
setup(props) {
|
|
261
261
|
const viewBox = vue.ref('0 0 1024 1024');
|
|
@@ -454,9 +454,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
454
454
|
};
|
|
455
455
|
};
|
|
456
456
|
|
|
457
|
-
const COMPONENT_NAME$
|
|
457
|
+
const COMPONENT_NAME$20 = "vc-transition";
|
|
458
458
|
const Transition = vue.defineComponent({
|
|
459
|
-
name: COMPONENT_NAME$
|
|
459
|
+
name: COMPONENT_NAME$20,
|
|
460
460
|
props: props$1n,
|
|
461
461
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
462
462
|
inheritAttrs: false,
|
|
@@ -477,9 +477,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
477
477
|
}
|
|
478
478
|
});
|
|
479
479
|
|
|
480
|
-
const COMPONENT_NAME$
|
|
480
|
+
const COMPONENT_NAME$1$ = "vc-transition-collapse";
|
|
481
481
|
const TransitionCollapse = vue.defineComponent({
|
|
482
|
-
name: COMPONENT_NAME$
|
|
482
|
+
name: COMPONENT_NAME$1$,
|
|
483
483
|
props: props$1n,
|
|
484
484
|
// 当不声明emits的情况下,事件存在于attrs中
|
|
485
485
|
inheritAttrs: false,
|
|
@@ -598,9 +598,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
598
598
|
}
|
|
599
599
|
});
|
|
600
600
|
|
|
601
|
-
const COMPONENT_NAME$
|
|
601
|
+
const COMPONENT_NAME$1_ = "vc-transition-fade";
|
|
602
602
|
const TransitionFade = vue.defineComponent({
|
|
603
|
-
name: COMPONENT_NAME$
|
|
603
|
+
name: COMPONENT_NAME$1_,
|
|
604
604
|
props: {
|
|
605
605
|
...props$1n,
|
|
606
606
|
// inheritAttrs必须是false
|
|
@@ -635,9 +635,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
635
635
|
}
|
|
636
636
|
});
|
|
637
637
|
|
|
638
|
-
const COMPONENT_NAME$
|
|
638
|
+
const COMPONENT_NAME$1Z = "vc-transition-scale";
|
|
639
639
|
const TransitionScale = vue.defineComponent({
|
|
640
|
-
name: COMPONENT_NAME$
|
|
640
|
+
name: COMPONENT_NAME$1Z,
|
|
641
641
|
props: {
|
|
642
642
|
...props$1n,
|
|
643
643
|
mode: {
|
|
@@ -677,9 +677,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
677
677
|
}
|
|
678
678
|
});
|
|
679
679
|
|
|
680
|
-
const COMPONENT_NAME$
|
|
680
|
+
const COMPONENT_NAME$1Y = "vc-transition-slide";
|
|
681
681
|
const TransitionSlide = vue.defineComponent({
|
|
682
|
-
name: COMPONENT_NAME$
|
|
682
|
+
name: COMPONENT_NAME$1Y,
|
|
683
683
|
props: {
|
|
684
684
|
...props$1n,
|
|
685
685
|
mode: {
|
|
@@ -719,9 +719,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
719
719
|
}
|
|
720
720
|
});
|
|
721
721
|
|
|
722
|
-
const COMPONENT_NAME$
|
|
722
|
+
const COMPONENT_NAME$1X = "vc-transition-zoom";
|
|
723
723
|
const TransitionZoom = vue.defineComponent({
|
|
724
|
-
name: COMPONENT_NAME$
|
|
724
|
+
name: COMPONENT_NAME$1X,
|
|
725
725
|
props: {
|
|
726
726
|
...props$1n,
|
|
727
727
|
mode: {
|
|
@@ -763,7 +763,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
763
763
|
|
|
764
764
|
/** @jsxImportSource vue */
|
|
765
765
|
|
|
766
|
-
const COMPONENT_NAME$
|
|
766
|
+
const COMPONENT_NAME$1W = 'vc-alert';
|
|
767
767
|
|
|
768
768
|
// [color, borderColor, backgroundColor], -> CSS
|
|
769
769
|
const THEME_MAP = {
|
|
@@ -773,7 +773,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
773
773
|
warning: ['#ffbf00', '#ffe58f', '#fffbe6']
|
|
774
774
|
};
|
|
775
775
|
const Alert = /* @__PURE__ */ vue.defineComponent({
|
|
776
|
-
name: COMPONENT_NAME$
|
|
776
|
+
name: COMPONENT_NAME$1W,
|
|
777
777
|
props: props$1p,
|
|
778
778
|
setup(props, {
|
|
779
779
|
slots,
|
|
@@ -872,9 +872,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
872
872
|
|
|
873
873
|
/** @jsxImportSource vue */
|
|
874
874
|
|
|
875
|
-
const COMPONENT_NAME$
|
|
875
|
+
const COMPONENT_NAME$1V = 'vc-artboard';
|
|
876
876
|
const Artboard = /* @__PURE__ */ vue.defineComponent({
|
|
877
|
-
name: COMPONENT_NAME$
|
|
877
|
+
name: COMPONENT_NAME$1V,
|
|
878
878
|
props: props$1m,
|
|
879
879
|
setup(props, {
|
|
880
880
|
slots
|
|
@@ -913,9 +913,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
913
913
|
|
|
914
914
|
/** @jsxImportSource vue */
|
|
915
915
|
|
|
916
|
-
const COMPONENT_NAME$
|
|
916
|
+
const COMPONENT_NAME$1U = 'vc-spin';
|
|
917
917
|
const Spin = /* @__PURE__ */ vue.defineComponent({
|
|
918
|
-
name: COMPONENT_NAME$
|
|
918
|
+
name: COMPONENT_NAME$1U,
|
|
919
919
|
props: props$1l,
|
|
920
920
|
setup(props, {
|
|
921
921
|
slots
|
|
@@ -5771,9 +5771,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
5771
5771
|
exclude: RegExp
|
|
5772
5772
|
};
|
|
5773
5773
|
|
|
5774
|
-
const COMPONENT_NAME$
|
|
5774
|
+
const COMPONENT_NAME$1T = "vc-debounce";
|
|
5775
5775
|
const Debounce = vue.defineComponent({
|
|
5776
|
-
name: COMPONENT_NAME$
|
|
5776
|
+
name: COMPONENT_NAME$1T,
|
|
5777
5777
|
props: props$1k,
|
|
5778
5778
|
/**
|
|
5779
5779
|
* 不声明emits使得事件被透传放入attrs中, 这样可以让所有的事件透传
|
|
@@ -5845,9 +5845,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
5845
5845
|
|
|
5846
5846
|
/** @jsxImportSource vue */
|
|
5847
5847
|
|
|
5848
|
-
const COMPONENT_NAME$
|
|
5848
|
+
const COMPONENT_NAME$1S = 'vc-button';
|
|
5849
5849
|
const Button = /* @__PURE__ */ vue.defineComponent({
|
|
5850
|
-
name: COMPONENT_NAME$
|
|
5850
|
+
name: COMPONENT_NAME$1S,
|
|
5851
5851
|
emits: ['click'],
|
|
5852
5852
|
props: props$1j,
|
|
5853
5853
|
setup(props, {
|
|
@@ -5929,9 +5929,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
5929
5929
|
|
|
5930
5930
|
/** @jsxImportSource vue */
|
|
5931
5931
|
|
|
5932
|
-
const COMPONENT_NAME$
|
|
5932
|
+
const COMPONENT_NAME$1R = 'vc-button-group';
|
|
5933
5933
|
const ButtonGroup = /* @__PURE__ */ vue.defineComponent({
|
|
5934
|
-
name: COMPONENT_NAME$
|
|
5934
|
+
name: COMPONENT_NAME$1R,
|
|
5935
5935
|
props: props$1i,
|
|
5936
5936
|
setup(props, {
|
|
5937
5937
|
slots
|
|
@@ -5965,9 +5965,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
5965
5965
|
|
|
5966
5966
|
/** @jsxImportSource vue */
|
|
5967
5967
|
|
|
5968
|
-
const COMPONENT_NAME$
|
|
5968
|
+
const COMPONENT_NAME$1Q = 'vc-calendar';
|
|
5969
5969
|
const Calendar$1 = /* @__PURE__ */ vue.defineComponent({
|
|
5970
|
-
name: COMPONENT_NAME$
|
|
5970
|
+
name: COMPONENT_NAME$1Q,
|
|
5971
5971
|
props: props$1h,
|
|
5972
5972
|
setup(props, {
|
|
5973
5973
|
slots
|
|
@@ -6005,9 +6005,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6005
6005
|
|
|
6006
6006
|
/** @jsxImportSource vue */
|
|
6007
6007
|
|
|
6008
|
-
const COMPONENT_NAME$
|
|
6008
|
+
const COMPONENT_NAME$1P = 'vc-card';
|
|
6009
6009
|
const Card = /* @__PURE__ */ vue.defineComponent({
|
|
6010
|
-
name: COMPONENT_NAME$
|
|
6010
|
+
name: COMPONENT_NAME$1P,
|
|
6011
6011
|
props: props$1g,
|
|
6012
6012
|
setup(props, {
|
|
6013
6013
|
slots
|
|
@@ -6043,9 +6043,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6043
6043
|
|
|
6044
6044
|
/** @jsxImportSource vue */
|
|
6045
6045
|
|
|
6046
|
-
const COMPONENT_NAME$
|
|
6046
|
+
const COMPONENT_NAME$1O = 'vc-carousel';
|
|
6047
6047
|
const Carousel = /* @__PURE__ */ vue.defineComponent({
|
|
6048
|
-
name: COMPONENT_NAME$
|
|
6048
|
+
name: COMPONENT_NAME$1O,
|
|
6049
6049
|
props: props$1f,
|
|
6050
6050
|
setup(props, {
|
|
6051
6051
|
slots
|
|
@@ -6069,9 +6069,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6069
6069
|
|
|
6070
6070
|
/** @jsxImportSource vue */
|
|
6071
6071
|
|
|
6072
|
-
const COMPONENT_NAME$
|
|
6072
|
+
const COMPONENT_NAME$1N = 'vc-cascader';
|
|
6073
6073
|
const Cascader = /* @__PURE__ */ vue.defineComponent({
|
|
6074
|
-
name: COMPONENT_NAME$
|
|
6074
|
+
name: COMPONENT_NAME$1N,
|
|
6075
6075
|
props: props$1e,
|
|
6076
6076
|
setup(props, {
|
|
6077
6077
|
slots
|
|
@@ -6203,9 +6203,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6203
6203
|
|
|
6204
6204
|
/** @jsxImportSource vue */
|
|
6205
6205
|
|
|
6206
|
-
const COMPONENT_NAME$
|
|
6206
|
+
const COMPONENT_NAME$1M = 'vc-chart';
|
|
6207
6207
|
const Chart = /* @__PURE__ */ vue.defineComponent({
|
|
6208
|
-
name: COMPONENT_NAME$
|
|
6208
|
+
name: COMPONENT_NAME$1M,
|
|
6209
6209
|
props: props$1d,
|
|
6210
6210
|
emits: [...EVENTS, 'ready'],
|
|
6211
6211
|
setup(props, {
|
|
@@ -6437,9 +6437,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6437
6437
|
|
|
6438
6438
|
/** @jsxImportSource vue */
|
|
6439
6439
|
|
|
6440
|
-
const COMPONENT_NAME$
|
|
6440
|
+
const COMPONENT_NAME$1L = 'vc-checkbox';
|
|
6441
6441
|
const Checkbox = /* @__PURE__ */ vue.defineComponent({
|
|
6442
|
-
name: COMPONENT_NAME$
|
|
6442
|
+
name: COMPONENT_NAME$1L,
|
|
6443
6443
|
props: props$1c,
|
|
6444
6444
|
emits: ['update:modelValue', 'change'],
|
|
6445
6445
|
setup(props, {
|
|
@@ -6526,9 +6526,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6526
6526
|
|
|
6527
6527
|
/** @jsxImportSource vue */
|
|
6528
6528
|
|
|
6529
|
-
const COMPONENT_NAME$
|
|
6529
|
+
const COMPONENT_NAME$1K = 'vc-checkbox-group';
|
|
6530
6530
|
const CheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
6531
|
-
name: COMPONENT_NAME$
|
|
6531
|
+
name: COMPONENT_NAME$1K,
|
|
6532
6532
|
props: props$1b,
|
|
6533
6533
|
emits: ['update:modelValue', 'change'],
|
|
6534
6534
|
setup(props, {
|
|
@@ -6546,9 +6546,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6546
6546
|
|
|
6547
6547
|
/** @jsxImportSource vue */
|
|
6548
6548
|
|
|
6549
|
-
const COMPONENT_NAME$
|
|
6549
|
+
const COMPONENT_NAME$1J = 'vcm-checkbox';
|
|
6550
6550
|
const MCheckbox = /* @__PURE__ */ vue.defineComponent({
|
|
6551
|
-
name: COMPONENT_NAME$
|
|
6551
|
+
name: COMPONENT_NAME$1J,
|
|
6552
6552
|
props: props$1c,
|
|
6553
6553
|
emits: ['update:modelValue', 'change'],
|
|
6554
6554
|
setup(props, {
|
|
@@ -6588,9 +6588,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6588
6588
|
|
|
6589
6589
|
/** @jsxImportSource vue */
|
|
6590
6590
|
|
|
6591
|
-
const COMPONENT_NAME$
|
|
6591
|
+
const COMPONENT_NAME$1I = 'vcm-checkbox-group';
|
|
6592
6592
|
const MCheckboxGroup = /* @__PURE__ */ vue.defineComponent({
|
|
6593
|
-
name: COMPONENT_NAME$
|
|
6593
|
+
name: COMPONENT_NAME$1I,
|
|
6594
6594
|
props: props$1b,
|
|
6595
6595
|
emits: ['update:modelValue', 'change'],
|
|
6596
6596
|
setup(props, {
|
|
@@ -6649,9 +6649,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6649
6649
|
}
|
|
6650
6650
|
};
|
|
6651
6651
|
|
|
6652
|
-
const COMPONENT_NAME$
|
|
6652
|
+
const COMPONENT_NAME$1H = "vc-customer";
|
|
6653
6653
|
const Customer = vue.defineComponent({
|
|
6654
|
-
name: COMPONENT_NAME$
|
|
6654
|
+
name: COMPONENT_NAME$1H,
|
|
6655
6655
|
props: props$19,
|
|
6656
6656
|
setup(props, context) {
|
|
6657
6657
|
return () => vue.h(() => {
|
|
@@ -6662,9 +6662,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
6662
6662
|
|
|
6663
6663
|
/** @jsxImportSource vue */
|
|
6664
6664
|
|
|
6665
|
-
const COMPONENT_NAME$
|
|
6665
|
+
const COMPONENT_NAME$1G = 'vc-message';
|
|
6666
6666
|
const MessageView = /* @__PURE__ */ vue.defineComponent({
|
|
6667
|
-
name: COMPONENT_NAME$
|
|
6667
|
+
name: COMPONENT_NAME$1G,
|
|
6668
6668
|
emits: ['before-close', 'close', 'portal-fulfilled'],
|
|
6669
6669
|
props: props$1a,
|
|
6670
6670
|
setup(props, {
|
|
@@ -7224,7 +7224,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
7224
7224
|
}
|
|
7225
7225
|
}
|
|
7226
7226
|
|
|
7227
|
-
const COMPONENT_NAME$
|
|
7227
|
+
const COMPONENT_NAME$1F = "vc-portal";
|
|
7228
7228
|
class Portal {
|
|
7229
7229
|
/**
|
|
7230
7230
|
* 清理Portals类型组件
|
|
@@ -7276,7 +7276,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
7276
7276
|
this.wrapper = wrapper;
|
|
7277
7277
|
this.globalOptions = {
|
|
7278
7278
|
...options,
|
|
7279
|
-
name: options?.name || wrapper.name || getUid(COMPONENT_NAME$
|
|
7279
|
+
name: options?.name || wrapper.name || getUid(COMPONENT_NAME$1F)
|
|
7280
7280
|
};
|
|
7281
7281
|
}
|
|
7282
7282
|
popup(propsData, options) {
|
|
@@ -7375,7 +7375,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
7375
7375
|
...rest
|
|
7376
7376
|
} = options;
|
|
7377
7377
|
let useAllNodes = fragment;
|
|
7378
|
-
const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$
|
|
7378
|
+
const name = multiple ? `${name$}__${getUid(COMPONENT_NAME$1F)}` : name$;
|
|
7379
7379
|
const container = document.createElement(tag);
|
|
7380
7380
|
const root = typeof el === "object" ? el : document.querySelector(el || "body");
|
|
7381
7381
|
!alive && Portal.leafs.get(name)?.destroy();
|
|
@@ -7409,7 +7409,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
7409
7409
|
} else {
|
|
7410
7410
|
const wrapper = this.wrapper;
|
|
7411
7411
|
const app = vue.createApp({
|
|
7412
|
-
name: COMPONENT_NAME$
|
|
7412
|
+
name: COMPONENT_NAME$1F,
|
|
7413
7413
|
parent,
|
|
7414
7414
|
setup() {
|
|
7415
7415
|
if (alive) {
|
|
@@ -7521,13 +7521,13 @@ var VcComponents = (function (exports, vue) {
|
|
|
7521
7521
|
}
|
|
7522
7522
|
};
|
|
7523
7523
|
|
|
7524
|
-
const COMPONENT_NAME$
|
|
7524
|
+
const COMPONENT_NAME$1E = 'vc-portal-view';
|
|
7525
7525
|
|
|
7526
7526
|
/**
|
|
7527
7527
|
* 写法不同,但与vue@2.x 保持一致
|
|
7528
7528
|
*/
|
|
7529
7529
|
const PortalView = /* @__PURE__ */ vue.defineComponent({
|
|
7530
|
-
name: COMPONENT_NAME$
|
|
7530
|
+
name: COMPONENT_NAME$1E,
|
|
7531
7531
|
props: props$18,
|
|
7532
7532
|
setup(props, {
|
|
7533
7533
|
slots
|
|
@@ -7698,9 +7698,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7698
7698
|
return () => vue.h(props.tag, { onClick: handleClick, class: "vc-clipboard" }, slots?.default?.());
|
|
7699
7699
|
};
|
|
7700
7700
|
|
|
7701
|
-
const COMPONENT_NAME$
|
|
7701
|
+
const COMPONENT_NAME$1D = "vc-clipboard";
|
|
7702
7702
|
const Clipboard$1 = vue.defineComponent({
|
|
7703
|
-
name: COMPONENT_NAME$
|
|
7703
|
+
name: COMPONENT_NAME$1D,
|
|
7704
7704
|
props: props$17,
|
|
7705
7705
|
setup() {
|
|
7706
7706
|
return useClipboard((content) => Message.success({ content }));
|
|
@@ -7740,9 +7740,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7740
7740
|
|
|
7741
7741
|
/** @jsxImportSource vue */
|
|
7742
7742
|
|
|
7743
|
-
const COMPONENT_NAME$
|
|
7743
|
+
const COMPONENT_NAME$1C = 'vcm-toast';
|
|
7744
7744
|
const MToastView = /* @__PURE__ */ vue.defineComponent({
|
|
7745
|
-
name: COMPONENT_NAME$
|
|
7745
|
+
name: COMPONENT_NAME$1C,
|
|
7746
7746
|
emits: ['close', 'portal-fulfilled'],
|
|
7747
7747
|
props: props$16,
|
|
7748
7748
|
setup(props, {
|
|
@@ -7844,9 +7844,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7844
7844
|
const error$2 = create$6({ mode: "error" });
|
|
7845
7845
|
const MToast = Object.assign(MToastView, { destroy: destroy$4, info: info$2, success: success$2, loading, warning: warning$2, error: error$2 });
|
|
7846
7846
|
|
|
7847
|
-
const COMPONENT_NAME$
|
|
7847
|
+
const COMPONENT_NAME$1B = "vcm-clipboard";
|
|
7848
7848
|
const MClipboard$1 = vue.defineComponent({
|
|
7849
|
-
name: COMPONENT_NAME$
|
|
7849
|
+
name: COMPONENT_NAME$1B,
|
|
7850
7850
|
props: props$17,
|
|
7851
7851
|
setup() {
|
|
7852
7852
|
return useClipboard((content) => MToast.info({ content }));
|
|
@@ -7878,9 +7878,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
7878
7878
|
}
|
|
7879
7879
|
};
|
|
7880
7880
|
|
|
7881
|
-
const COMPONENT_NAME$
|
|
7881
|
+
const COMPONENT_NAME$1A = "vc-collapse";
|
|
7882
7882
|
const Collapse = vue.defineComponent({
|
|
7883
|
-
name: COMPONENT_NAME$
|
|
7883
|
+
name: COMPONENT_NAME$1A,
|
|
7884
7884
|
props: props$15,
|
|
7885
7885
|
emits: ["update:moodelValue", "change"],
|
|
7886
7886
|
setup(props, { slots, emit }) {
|
|
@@ -7994,12 +7994,12 @@ var VcComponents = (function (exports, vue) {
|
|
|
7994
7994
|
|
|
7995
7995
|
/** @jsxImportSource vue */
|
|
7996
7996
|
|
|
7997
|
-
function _isSlot$
|
|
7997
|
+
function _isSlot$2(s) {
|
|
7998
7998
|
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
7999
7999
|
}
|
|
8000
|
-
const COMPONENT_NAME$
|
|
8000
|
+
const COMPONENT_NAME$1z = 'vc-expand';
|
|
8001
8001
|
const Expand$1 = /* @__PURE__ */ vue.defineComponent({
|
|
8002
|
-
name: COMPONENT_NAME$
|
|
8002
|
+
name: COMPONENT_NAME$1z,
|
|
8003
8003
|
props: props$13,
|
|
8004
8004
|
setup(props, {
|
|
8005
8005
|
slots
|
|
@@ -8018,7 +8018,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
8018
8018
|
enter: 200,
|
|
8019
8019
|
leave: 200
|
|
8020
8020
|
}
|
|
8021
|
-
}, _isSlot$
|
|
8021
|
+
}, _isSlot$2(_slot = vue.withDirectives(vue.createVNode(Content, null, {
|
|
8022
8022
|
default: () => [(props.alive || !props.alive && isActive.value) && slots.default?.()]
|
|
8023
8023
|
}), [[vue.vShow, isActive.value]])) ? _slot : {
|
|
8024
8024
|
default: () => [_slot]
|
|
@@ -8029,9 +8029,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8029
8029
|
|
|
8030
8030
|
/** @jsxImportSource vue */
|
|
8031
8031
|
|
|
8032
|
-
const COMPONENT_NAME$
|
|
8032
|
+
const COMPONENT_NAME$1y = 'vc-collapse-item';
|
|
8033
8033
|
const CollapseItem = /* @__PURE__ */ vue.defineComponent({
|
|
8034
|
-
name: COMPONENT_NAME$
|
|
8034
|
+
name: COMPONENT_NAME$1y,
|
|
8035
8035
|
props: props$14,
|
|
8036
8036
|
setup(props, {
|
|
8037
8037
|
slots,
|
|
@@ -8106,9 +8106,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8106
8106
|
|
|
8107
8107
|
/** @jsxImportSource vue */
|
|
8108
8108
|
|
|
8109
|
-
const COMPONENT_NAME$
|
|
8109
|
+
const COMPONENT_NAME$1x = 'vc-color-picker';
|
|
8110
8110
|
const ColorPicker = /* @__PURE__ */ vue.defineComponent({
|
|
8111
|
-
name: COMPONENT_NAME$
|
|
8111
|
+
name: COMPONENT_NAME$1x,
|
|
8112
8112
|
props: props$12,
|
|
8113
8113
|
setup(props, {
|
|
8114
8114
|
slots
|
|
@@ -8132,9 +8132,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8132
8132
|
|
|
8133
8133
|
/** @jsxImportSource vue */
|
|
8134
8134
|
|
|
8135
|
-
const COMPONENT_NAME$
|
|
8135
|
+
const COMPONENT_NAME$1w = 'vc-countdown';
|
|
8136
8136
|
const Countdown = /* @__PURE__ */ vue.defineComponent({
|
|
8137
|
-
name: COMPONENT_NAME$
|
|
8137
|
+
name: COMPONENT_NAME$1w,
|
|
8138
8138
|
props: props$11,
|
|
8139
8139
|
setup(props, {
|
|
8140
8140
|
slots
|
|
@@ -8648,9 +8648,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8648
8648
|
|
|
8649
8649
|
/** @jsxImportSource vue */
|
|
8650
8650
|
|
|
8651
|
-
const COMPONENT_NAME$
|
|
8651
|
+
const COMPONENT_NAME$1v = 'vc-input';
|
|
8652
8652
|
const Input = /* @__PURE__ */ vue.defineComponent({
|
|
8653
|
-
name: COMPONENT_NAME$
|
|
8653
|
+
name: COMPONENT_NAME$1v,
|
|
8654
8654
|
inheritAttrs: false,
|
|
8655
8655
|
props: {
|
|
8656
8656
|
...props$$,
|
|
@@ -8663,7 +8663,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
8663
8663
|
emits: ['update:modelValue', 'input', 'change', 'focus', 'blur', 'clear', 'paste', 'keydown', 'keypress', 'keyup', 'enter', 'tip'],
|
|
8664
8664
|
setup(props, {
|
|
8665
8665
|
slots,
|
|
8666
|
-
expose
|
|
8666
|
+
expose,
|
|
8667
|
+
attrs
|
|
8667
8668
|
}) {
|
|
8668
8669
|
const input = vue.ref();
|
|
8669
8670
|
useNativeEmitter(input, expose);
|
|
@@ -8730,9 +8731,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8730
8731
|
}, classes.value]
|
|
8731
8732
|
}, [slots.prepend?.() || props.prepend && vue.createVNode(Icon, {
|
|
8732
8733
|
"type": props.prepend
|
|
8733
|
-
}, null)]), vue.createVNode("div", {
|
|
8734
|
+
}, null)]), vue.createVNode("div", vue.mergeProps({
|
|
8734
8735
|
"class": ['vc-input__content', classes.value]
|
|
8735
|
-
}, [slots.content
|
|
8736
|
+
}, slots.content ? it.value.listeners : {}), [slots.content ? slots.content() : renderInput(false)]), !props.disabled && props.clearable && vue.createVNode(TransitionFade, null, {
|
|
8736
8737
|
default: () => [vue.createVNode(Icon, {
|
|
8737
8738
|
"class": "vc-input__icon-clear",
|
|
8738
8739
|
"type": "clear",
|
|
@@ -8984,9 +8985,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
8984
8985
|
|
|
8985
8986
|
/** @jsxImportSource vue */
|
|
8986
8987
|
|
|
8987
|
-
const COMPONENT_NAME$
|
|
8988
|
+
const COMPONENT_NAME$1u = 'vc-input-number';
|
|
8988
8989
|
const InputNumber = /* @__PURE__ */ vue.defineComponent({
|
|
8989
|
-
name: COMPONENT_NAME$
|
|
8990
|
+
name: COMPONENT_NAME$1u,
|
|
8990
8991
|
props: props$X,
|
|
8991
8992
|
inheritAttrs: false,
|
|
8992
8993
|
setup(props, {
|
|
@@ -9050,9 +9051,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9050
9051
|
|
|
9051
9052
|
/** @jsxImportSource vue */
|
|
9052
9053
|
|
|
9053
|
-
const COMPONENT_NAME$
|
|
9054
|
+
const COMPONENT_NAME$1t = 'vc-input-search';
|
|
9054
9055
|
const InputSearch = /* @__PURE__ */ vue.defineComponent({
|
|
9055
|
-
name: COMPONENT_NAME$
|
|
9056
|
+
name: COMPONENT_NAME$1t,
|
|
9056
9057
|
props: props$W,
|
|
9057
9058
|
inheritAttrs: false,
|
|
9058
9059
|
setup(props, {
|
|
@@ -9340,12 +9341,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
9340
9341
|
|
|
9341
9342
|
/** @jsxImportSource vue */
|
|
9342
9343
|
|
|
9343
|
-
|
|
9344
|
-
return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
|
|
9345
|
-
}
|
|
9346
|
-
const COMPONENT_NAME$1q = 'vc-popover-wrapper';
|
|
9344
|
+
const COMPONENT_NAME$1s = 'vc-popover-wrapper';
|
|
9347
9345
|
const PopoverWrapper = /* @__PURE__ */ vue.defineComponent({
|
|
9348
|
-
name: COMPONENT_NAME$
|
|
9346
|
+
name: COMPONENT_NAME$1s,
|
|
9349
9347
|
props: props$_,
|
|
9350
9348
|
emits: ['portal-fulfilled', 'close'],
|
|
9351
9349
|
setup(props, {
|
|
@@ -9407,7 +9405,12 @@ var VcComponents = (function (exports, vue) {
|
|
|
9407
9405
|
return container;
|
|
9408
9406
|
}
|
|
9409
9407
|
};
|
|
9410
|
-
|
|
9408
|
+
|
|
9409
|
+
/**
|
|
9410
|
+
* 添加debounce解决连续setPopupStyle的情况
|
|
9411
|
+
* 待排查
|
|
9412
|
+
*/
|
|
9413
|
+
const setPopupStyle = debounce$1(() => {
|
|
9411
9414
|
if (!vnode.el) return;
|
|
9412
9415
|
const triggerEl = getHackContainer();
|
|
9413
9416
|
const {
|
|
@@ -9437,13 +9440,15 @@ var VcComponents = (function (exports, vue) {
|
|
|
9437
9440
|
fitPos.value = result;
|
|
9438
9441
|
wrapperStyle.value = $wrapperStyle;
|
|
9439
9442
|
arrowStyle.value = $arrowStyle;
|
|
9440
|
-
|
|
9441
9443
|
// 自适应高度
|
|
9442
9444
|
if (props.autoWidth) return;
|
|
9443
9445
|
wrapperW.value = {
|
|
9444
9446
|
width: `${triggerEl.getBoundingClientRect().width}px`
|
|
9445
9447
|
};
|
|
9446
|
-
}
|
|
9448
|
+
}, 50, {
|
|
9449
|
+
leading: true,
|
|
9450
|
+
trailing: false
|
|
9451
|
+
});
|
|
9447
9452
|
let timer;
|
|
9448
9453
|
let isPressMouse = false;
|
|
9449
9454
|
const handleTriggerChange = e => {
|
|
@@ -9498,7 +9503,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
9498
9503
|
switch (direction[0]) {
|
|
9499
9504
|
case 'top':
|
|
9500
9505
|
case 'bottom':
|
|
9501
|
-
if (left + vnode.el.offsetWidth
|
|
9506
|
+
if (left + vnode.el.offsetWidth > window.innerWidth) {
|
|
9502
9507
|
wrapperStyle.value = {
|
|
9503
9508
|
...wrapperStyle.value,
|
|
9504
9509
|
left: `${window.innerWidth - vnode.el.offsetWidth}px`
|
|
@@ -9558,7 +9563,6 @@ var VcComponents = (function (exports, vue) {
|
|
|
9558
9563
|
}
|
|
9559
9564
|
});
|
|
9560
9565
|
return () => {
|
|
9561
|
-
let _slot;
|
|
9562
9566
|
return vue.createVNode(TransitionScale, {
|
|
9563
9567
|
"mode": props.animation || 'part',
|
|
9564
9568
|
"duration": {
|
|
@@ -9566,38 +9570,40 @@ var VcComponents = (function (exports, vue) {
|
|
|
9566
9570
|
leave: 150
|
|
9567
9571
|
},
|
|
9568
9572
|
"onAfterLeave": handleRemove
|
|
9569
|
-
},
|
|
9570
|
-
|
|
9571
|
-
|
|
9572
|
-
|
|
9573
|
-
|
|
9574
|
-
|
|
9575
|
-
|
|
9576
|
-
|
|
9577
|
-
|
|
9578
|
-
|
|
9579
|
-
|
|
9580
|
-
|
|
9581
|
-
|
|
9582
|
-
"
|
|
9583
|
-
|
|
9584
|
-
|
|
9585
|
-
|
|
9586
|
-
|
|
9587
|
-
"
|
|
9588
|
-
|
|
9589
|
-
|
|
9573
|
+
}, {
|
|
9574
|
+
default: () => [vue.withDirectives(vue.createVNode("div", {
|
|
9575
|
+
"style": [wrapperStyle.value, wrapperW.value, props.portalStyle],
|
|
9576
|
+
"class": [wrapperClasses.value, props.portalClass, 'vc-popover-wrapper'],
|
|
9577
|
+
"onMousedown": () => !props.hover && handleMouseDown(),
|
|
9578
|
+
"onMouseenter": e => props.hover && handleChange(e, {
|
|
9579
|
+
visible: true
|
|
9580
|
+
}),
|
|
9581
|
+
"onMouseleave": e => props.hover && handleChange(e, {
|
|
9582
|
+
visible: false
|
|
9583
|
+
})
|
|
9584
|
+
}, [vue.createVNode("div", {
|
|
9585
|
+
"class": [themeClasses.value, 'vc-popover-wrapper__container']
|
|
9586
|
+
}, [props.arrow && vue.createVNode("div", {
|
|
9587
|
+
"style": arrowStyle.value,
|
|
9588
|
+
"class": [themeClasses.value, posClasses.value, 'vc-popover-wrapper__arrow']
|
|
9589
|
+
}, null), slots.content ? slots.content() : typeof props.content === 'function' ? vue.createVNode(Customer, {
|
|
9590
|
+
"render": props.content
|
|
9591
|
+
}, null) : vue.createVNode("div", {
|
|
9592
|
+
"innerHTML": props.content
|
|
9593
|
+
}, null)])]), [[vue.vShow, isActive.value]])]
|
|
9590
9594
|
});
|
|
9591
9595
|
};
|
|
9592
9596
|
}
|
|
9593
9597
|
});
|
|
9594
|
-
const PopoverPortal = new Portal(PopoverWrapper
|
|
9598
|
+
const PopoverPortal = new Portal(PopoverWrapper, {
|
|
9599
|
+
leaveDelay: 0
|
|
9600
|
+
});
|
|
9595
9601
|
|
|
9596
9602
|
/** @jsxImportSource vue */
|
|
9597
9603
|
|
|
9598
|
-
const COMPONENT_NAME$
|
|
9604
|
+
const COMPONENT_NAME$1r = 'vc-popover';
|
|
9599
9605
|
const Popover$1 = /* @__PURE__ */ vue.defineComponent({
|
|
9600
|
-
name: COMPONENT_NAME$
|
|
9606
|
+
name: COMPONENT_NAME$1r,
|
|
9601
9607
|
props: props$Z,
|
|
9602
9608
|
emits: ['update:modelValue', 'visible-change', 'ready', 'close'],
|
|
9603
9609
|
setup(props, {
|
|
@@ -10698,9 +10704,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10698
10704
|
}
|
|
10699
10705
|
return view;
|
|
10700
10706
|
};
|
|
10701
|
-
const COMPONENT_NAME$
|
|
10707
|
+
const COMPONENT_NAME$1q = 'vc-date-confirm';
|
|
10702
10708
|
const Confirm = /* @__PURE__ */ vue.defineComponent({
|
|
10703
|
-
name: COMPONENT_NAME$
|
|
10709
|
+
name: COMPONENT_NAME$1q,
|
|
10704
10710
|
props: {
|
|
10705
10711
|
showTime: {
|
|
10706
10712
|
type: Boolean,
|
|
@@ -10764,9 +10770,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10764
10770
|
|
|
10765
10771
|
/** @jsxImportSource vue */
|
|
10766
10772
|
|
|
10767
|
-
const COMPONENT_NAME$
|
|
10773
|
+
const COMPONENT_NAME$1p = 'vc-date-header';
|
|
10768
10774
|
const DateHeader = /* @__PURE__ */ vue.defineComponent({
|
|
10769
|
-
name: COMPONENT_NAME$
|
|
10775
|
+
name: COMPONENT_NAME$1p,
|
|
10770
10776
|
props: {
|
|
10771
10777
|
panelDate: Date,
|
|
10772
10778
|
showNext: {
|
|
@@ -10850,9 +10856,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
10850
10856
|
|
|
10851
10857
|
/** @jsxImportSource vue */
|
|
10852
10858
|
|
|
10853
|
-
const COMPONENT_NAME$
|
|
10859
|
+
const COMPONENT_NAME$1o = 'vc-date-table';
|
|
10854
10860
|
const DateTable = /* @__PURE__ */ vue.defineComponent({
|
|
10855
|
-
name: COMPONENT_NAME$
|
|
10861
|
+
name: COMPONENT_NAME$1o,
|
|
10856
10862
|
props: {
|
|
10857
10863
|
value: Array,
|
|
10858
10864
|
firstDayOfWeek: {
|
|
@@ -11061,9 +11067,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11061
11067
|
|
|
11062
11068
|
/** @jsxImportSource vue */
|
|
11063
11069
|
|
|
11064
|
-
const COMPONENT_NAME$
|
|
11070
|
+
const COMPONENT_NAME$1n = 'vc-month-table';
|
|
11065
11071
|
const MonthTable = /* @__PURE__ */ vue.defineComponent({
|
|
11066
|
-
name: COMPONENT_NAME$
|
|
11072
|
+
name: COMPONENT_NAME$1n,
|
|
11067
11073
|
props: {
|
|
11068
11074
|
value: Array,
|
|
11069
11075
|
panelDate: Date,
|
|
@@ -11195,7 +11201,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
11195
11201
|
|
|
11196
11202
|
/** @jsxImportSource vue */
|
|
11197
11203
|
|
|
11198
|
-
const COMPONENT_NAME$
|
|
11204
|
+
const COMPONENT_NAME$1m = 'vc-quarter-table';
|
|
11199
11205
|
|
|
11200
11206
|
/**
|
|
11201
11207
|
* 获取季度对应的月份范围
|
|
@@ -11229,7 +11235,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
11229
11235
|
}
|
|
11230
11236
|
};
|
|
11231
11237
|
const QuarterTable = /* @__PURE__ */ vue.defineComponent({
|
|
11232
|
-
name: COMPONENT_NAME$
|
|
11238
|
+
name: COMPONENT_NAME$1m,
|
|
11233
11239
|
props: {
|
|
11234
11240
|
value: Array,
|
|
11235
11241
|
panelDate: Date,
|
|
@@ -11352,9 +11358,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11352
11358
|
|
|
11353
11359
|
/** @jsxImportSource vue */
|
|
11354
11360
|
|
|
11355
|
-
const COMPONENT_NAME$
|
|
11361
|
+
const COMPONENT_NAME$1l = 'vc-shortcuts-select';
|
|
11356
11362
|
const ShortcutsSelect = /* @__PURE__ */ vue.defineComponent({
|
|
11357
|
-
name: COMPONENT_NAME$
|
|
11363
|
+
name: COMPONENT_NAME$1l,
|
|
11358
11364
|
props: {
|
|
11359
11365
|
panelDate: Date,
|
|
11360
11366
|
config: Array,
|
|
@@ -11394,9 +11400,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11394
11400
|
|
|
11395
11401
|
/** @jsxImportSource vue */
|
|
11396
11402
|
|
|
11397
|
-
const COMPONENT_NAME$
|
|
11403
|
+
const COMPONENT_NAME$1k = 'vc-time-select';
|
|
11398
11404
|
const TimeSelect = /* @__PURE__ */ vue.defineComponent({
|
|
11399
|
-
name: COMPONENT_NAME$
|
|
11405
|
+
name: COMPONENT_NAME$1k,
|
|
11400
11406
|
props: {
|
|
11401
11407
|
hours: {
|
|
11402
11408
|
type: [Number, String],
|
|
@@ -11675,9 +11681,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11675
11681
|
|
|
11676
11682
|
/** @jsxImportSource vue */
|
|
11677
11683
|
|
|
11678
|
-
const COMPONENT_NAME$
|
|
11684
|
+
const COMPONENT_NAME$1j = 'vc-year-table';
|
|
11679
11685
|
const YearTable = /* @__PURE__ */ vue.defineComponent({
|
|
11680
|
-
name: COMPONENT_NAME$
|
|
11686
|
+
name: COMPONENT_NAME$1j,
|
|
11681
11687
|
props: {
|
|
11682
11688
|
value: Array,
|
|
11683
11689
|
panelDate: Date,
|
|
@@ -11800,9 +11806,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
11800
11806
|
}
|
|
11801
11807
|
return true;
|
|
11802
11808
|
};
|
|
11803
|
-
const COMPONENT_NAME$
|
|
11809
|
+
const COMPONENT_NAME$1i = 'vc-date-range-panel';
|
|
11804
11810
|
const DateRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
11805
|
-
name: COMPONENT_NAME$
|
|
11811
|
+
name: COMPONENT_NAME$1i,
|
|
11806
11812
|
props: {
|
|
11807
11813
|
...props$V,
|
|
11808
11814
|
confirm: {
|
|
@@ -12181,9 +12187,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12181
12187
|
|
|
12182
12188
|
/** @jsxImportSource vue */
|
|
12183
12189
|
|
|
12184
|
-
const COMPONENT_NAME$
|
|
12190
|
+
const COMPONENT_NAME$1h = 'vc-date-panel';
|
|
12185
12191
|
const DatePanel = /* @__PURE__ */ vue.defineComponent({
|
|
12186
|
-
name: COMPONENT_NAME$
|
|
12192
|
+
name: COMPONENT_NAME$1h,
|
|
12187
12193
|
props: {
|
|
12188
12194
|
...props$V,
|
|
12189
12195
|
type: String,
|
|
@@ -12391,9 +12397,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12391
12397
|
const endYear = value[1].getFullYear();
|
|
12392
12398
|
return startYear === endYear;
|
|
12393
12399
|
};
|
|
12394
|
-
const COMPONENT_NAME$
|
|
12400
|
+
const COMPONENT_NAME$1g = 'vc-monthrange-panel';
|
|
12395
12401
|
const MonthRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
12396
|
-
name: COMPONENT_NAME$
|
|
12402
|
+
name: COMPONENT_NAME$1g,
|
|
12397
12403
|
props: {
|
|
12398
12404
|
...props$V,
|
|
12399
12405
|
confirm: {
|
|
@@ -12568,9 +12574,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12568
12574
|
const endYear = value[1].getFullYear();
|
|
12569
12575
|
return startYear === endYear;
|
|
12570
12576
|
};
|
|
12571
|
-
const COMPONENT_NAME$
|
|
12577
|
+
const COMPONENT_NAME$1f = 'vc-quarterrange-panel';
|
|
12572
12578
|
const QuarterRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
12573
|
-
name: COMPONENT_NAME$
|
|
12579
|
+
name: COMPONENT_NAME$1f,
|
|
12574
12580
|
props: {
|
|
12575
12581
|
...props$V,
|
|
12576
12582
|
confirm: {
|
|
@@ -12809,9 +12815,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12809
12815
|
seconds
|
|
12810
12816
|
};
|
|
12811
12817
|
};
|
|
12812
|
-
const COMPONENT_NAME$
|
|
12818
|
+
const COMPONENT_NAME$1e = 'vc-timerange-panel';
|
|
12813
12819
|
const TimeRangePanel = /* @__PURE__ */ vue.defineComponent({
|
|
12814
|
-
name: COMPONENT_NAME$
|
|
12820
|
+
name: COMPONENT_NAME$1e,
|
|
12815
12821
|
props: props$U,
|
|
12816
12822
|
emits: ['pick', 'clear', 'ok'],
|
|
12817
12823
|
setup(props, {
|
|
@@ -12910,9 +12916,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
12910
12916
|
|
|
12911
12917
|
/** @jsxImportSource vue */
|
|
12912
12918
|
|
|
12913
|
-
const COMPONENT_NAME$
|
|
12919
|
+
const COMPONENT_NAME$1d = 'vc-time-panel';
|
|
12914
12920
|
const TimePanel = /* @__PURE__ */ vue.defineComponent({
|
|
12915
|
-
name: COMPONENT_NAME$
|
|
12921
|
+
name: COMPONENT_NAME$1d,
|
|
12916
12922
|
props: props$U,
|
|
12917
12923
|
emits: ['pick', 'clear', 'ok'],
|
|
12918
12924
|
setup(props, {
|
|
@@ -12967,7 +12973,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
12967
12973
|
|
|
12968
12974
|
/** @jsxImportSource vue */
|
|
12969
12975
|
|
|
12970
|
-
const COMPONENT_NAME$
|
|
12976
|
+
const COMPONENT_NAME$1c = 'vc-date-picker';
|
|
12971
12977
|
const getPanel$1 = type => {
|
|
12972
12978
|
if (['daterange', 'datetimerange'].includes(type)) {
|
|
12973
12979
|
return DateRangePanel;
|
|
@@ -12978,7 +12984,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
12978
12984
|
}
|
|
12979
12985
|
return DatePanel;
|
|
12980
12986
|
};
|
|
12981
|
-
const DatePicker = createPicker(COMPONENT_NAME$
|
|
12987
|
+
const DatePicker = createPicker(COMPONENT_NAME$1c, props$10, () => {
|
|
12982
12988
|
const props = vue.getCurrentInstance().props;
|
|
12983
12989
|
const icon = vue.ref('date');
|
|
12984
12990
|
const panel = vue.shallowRef({});
|
|
@@ -13011,9 +13017,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13011
13017
|
|
|
13012
13018
|
/** @jsxImportSource vue */
|
|
13013
13019
|
|
|
13014
|
-
const COMPONENT_NAME$
|
|
13020
|
+
const COMPONENT_NAME$1b = 'vc-divider';
|
|
13015
13021
|
const Divider = /* @__PURE__ */ vue.defineComponent({
|
|
13016
|
-
name: COMPONENT_NAME$
|
|
13022
|
+
name: COMPONENT_NAME$1b,
|
|
13017
13023
|
props: props$T,
|
|
13018
13024
|
setup(props, {
|
|
13019
13025
|
slots
|
|
@@ -13168,7 +13174,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
13168
13174
|
|
|
13169
13175
|
/** @jsxImportSource vue */
|
|
13170
13176
|
|
|
13171
|
-
const COMPONENT_NAME$
|
|
13177
|
+
const COMPONENT_NAME$1a = 'vc-scroller-track';
|
|
13172
13178
|
const BAR_MAP = {
|
|
13173
13179
|
vertical: {
|
|
13174
13180
|
scroll: 'scrollTop',
|
|
@@ -13188,7 +13194,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
13188
13194
|
}
|
|
13189
13195
|
};
|
|
13190
13196
|
const Track$1 = /* @__PURE__ */ vue.defineComponent({
|
|
13191
|
-
name: COMPONENT_NAME$
|
|
13197
|
+
name: COMPONENT_NAME$1a,
|
|
13192
13198
|
props: props$S,
|
|
13193
13199
|
emits: ['change'],
|
|
13194
13200
|
inheritAttrs: false,
|
|
@@ -13378,9 +13384,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
13378
13384
|
|
|
13379
13385
|
/** @jsxImportSource vue */
|
|
13380
13386
|
|
|
13381
|
-
const COMPONENT_NAME$
|
|
13387
|
+
const COMPONENT_NAME$19 = 'vc-scroller-bar';
|
|
13382
13388
|
const Bar = /* @__PURE__ */ vue.defineComponent({
|
|
13383
|
-
name: COMPONENT_NAME$
|
|
13389
|
+
name: COMPONENT_NAME$19,
|
|
13384
13390
|
props: props$R,
|
|
13385
13391
|
emits: ['change'],
|
|
13386
13392
|
setup(props, {
|
|
@@ -13595,7 +13601,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
13595
13601
|
|
|
13596
13602
|
/** @jsxImportSource vue */
|
|
13597
13603
|
|
|
13598
|
-
const COMPONENT_NAME$
|
|
13604
|
+
const COMPONENT_NAME$18 = 'vc-scroller';
|
|
13599
13605
|
|
|
13600
13606
|
/**
|
|
13601
13607
|
* 作为备选方案,目前推荐使用ScrollerWheel
|
|
@@ -13606,7 +13612,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
13606
13612
|
* 2. 增加了一层嵌套
|
|
13607
13613
|
*/
|
|
13608
13614
|
const Scroller = /* @__PURE__ */ vue.defineComponent({
|
|
13609
|
-
name: COMPONENT_NAME$
|
|
13615
|
+
name: COMPONENT_NAME$18,
|
|
13610
13616
|
props: props$Q,
|
|
13611
13617
|
emits: ['scroll'],
|
|
13612
13618
|
setup(props, {
|
|
@@ -14556,7 +14562,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14556
14562
|
|
|
14557
14563
|
/** @jsxImportSource vue */
|
|
14558
14564
|
|
|
14559
|
-
const COMPONENT_NAME$
|
|
14565
|
+
const COMPONENT_NAME$17 = 'vc-scroller-wheel';
|
|
14560
14566
|
|
|
14561
14567
|
/**
|
|
14562
14568
|
* 为减少一层嵌套,为去除滚动bar的抖动,使用wheel模拟
|
|
@@ -14578,7 +14584,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
14578
14584
|
* 设置scrollTop不会reflow和repaint,不需要考虑transfrom来改变content(transform也只在draw完成)
|
|
14579
14585
|
*/
|
|
14580
14586
|
const ScrollerWheel = /* @__PURE__ */ vue.defineComponent({
|
|
14581
|
-
name: COMPONENT_NAME$
|
|
14587
|
+
name: COMPONENT_NAME$17,
|
|
14582
14588
|
props: Object.assign(props$Q, {
|
|
14583
14589
|
stopPropagation: {
|
|
14584
14590
|
type: Boolean,
|
|
@@ -14767,9 +14773,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
14767
14773
|
|
|
14768
14774
|
/** @jsxImportSource vue */
|
|
14769
14775
|
|
|
14770
|
-
const COMPONENT_NAME$
|
|
14776
|
+
const COMPONENT_NAME$16 = 'vc-drawer';
|
|
14771
14777
|
const DrawerView = /* @__PURE__ */ vue.defineComponent({
|
|
14772
|
-
name: COMPONENT_NAME$
|
|
14778
|
+
name: COMPONENT_NAME$16,
|
|
14773
14779
|
props: props$P,
|
|
14774
14780
|
emits: ['close', 'update:modelValue', 'visible-change'],
|
|
14775
14781
|
setup(props, {
|
|
@@ -14937,30 +14943,178 @@ var VcComponents = (function (exports, vue) {
|
|
|
14937
14943
|
const MDrawerView = DrawerView;
|
|
14938
14944
|
|
|
14939
14945
|
const props$O = {
|
|
14940
|
-
|
|
14946
|
+
modelValue: {
|
|
14947
|
+
type: Boolean,
|
|
14948
|
+
default: false
|
|
14949
|
+
},
|
|
14950
|
+
portalClass: [String, Object],
|
|
14951
|
+
placement: {
|
|
14941
14952
|
type: String,
|
|
14942
|
-
default: "
|
|
14953
|
+
default: "bottom"
|
|
14954
|
+
},
|
|
14955
|
+
trigger: {
|
|
14956
|
+
type: String,
|
|
14957
|
+
default: "hover"
|
|
14958
|
+
},
|
|
14959
|
+
arrow: {
|
|
14960
|
+
type: Boolean,
|
|
14961
|
+
default: false
|
|
14943
14962
|
}
|
|
14944
14963
|
};
|
|
14945
14964
|
|
|
14946
14965
|
/** @jsxImportSource vue */
|
|
14947
14966
|
|
|
14948
|
-
const COMPONENT_NAME$
|
|
14967
|
+
const COMPONENT_NAME$15 = 'vc-dropdown';
|
|
14949
14968
|
const Dropdown = /* @__PURE__ */ vue.defineComponent({
|
|
14950
|
-
name: COMPONENT_NAME$
|
|
14969
|
+
name: COMPONENT_NAME$15,
|
|
14951
14970
|
props: props$O,
|
|
14971
|
+
inheritAttrs: false,
|
|
14972
|
+
emits: ['update:modelValue', 'ready', 'close', 'visible-change', 'click'],
|
|
14952
14973
|
setup(props, {
|
|
14974
|
+
slots,
|
|
14975
|
+
emit,
|
|
14976
|
+
expose
|
|
14977
|
+
}) {
|
|
14978
|
+
const its = useAttrs({
|
|
14979
|
+
merge: false
|
|
14980
|
+
});
|
|
14981
|
+
const isActive = vue.ref(false);
|
|
14982
|
+
const dropdownId = vue.ref(getUid('dropdown'));
|
|
14983
|
+
const inherit = vue.computed(() => {
|
|
14984
|
+
return {
|
|
14985
|
+
style: its.value.style,
|
|
14986
|
+
class: its.value.class
|
|
14987
|
+
};
|
|
14988
|
+
});
|
|
14989
|
+
const attrs = vue.computed(() => {
|
|
14990
|
+
return its.value.attrs;
|
|
14991
|
+
});
|
|
14992
|
+
vue.watch(() => props.modelValue, v => {
|
|
14993
|
+
isActive.value = v;
|
|
14994
|
+
}, {
|
|
14995
|
+
immediate: true
|
|
14996
|
+
});
|
|
14997
|
+
|
|
14998
|
+
/**
|
|
14999
|
+
* v-model 同步, 外部的数据改变时不会触发
|
|
15000
|
+
*/
|
|
15001
|
+
const sync = () => {
|
|
15002
|
+
emit('update:modelValue', isActive.value);
|
|
15003
|
+
emit('visible-change', isActive.value);
|
|
15004
|
+
};
|
|
15005
|
+
const handleChange = v => {
|
|
15006
|
+
isActive.value = v;
|
|
15007
|
+
sync();
|
|
15008
|
+
};
|
|
15009
|
+
const close = () => {
|
|
15010
|
+
isActive.value = false;
|
|
15011
|
+
sync();
|
|
15012
|
+
};
|
|
15013
|
+
expose({
|
|
15014
|
+
close,
|
|
15015
|
+
dropdownId
|
|
15016
|
+
});
|
|
15017
|
+
return () => {
|
|
15018
|
+
return vue.createVNode(Popover, vue.mergeProps(attrs.value, {
|
|
15019
|
+
"modelValue": isActive.value,
|
|
15020
|
+
"placement": props.placement,
|
|
15021
|
+
"trigger": props.trigger,
|
|
15022
|
+
"arrow": props.arrow,
|
|
15023
|
+
"portalClass": ['is-padding-none', 'vc-dropdown-wrapper', props.portalClass],
|
|
15024
|
+
"class": ['vc-dropdown', inherit.value.class],
|
|
15025
|
+
"style": inherit.value.style,
|
|
15026
|
+
"onReady": () => emit('ready'),
|
|
15027
|
+
"onClose": () => emit('close'),
|
|
15028
|
+
"onVisibleChange": handleChange
|
|
15029
|
+
}), {
|
|
15030
|
+
default: () => slots?.default?.(),
|
|
15031
|
+
content: () => slots?.content?.()
|
|
15032
|
+
});
|
|
15033
|
+
};
|
|
15034
|
+
}
|
|
15035
|
+
});
|
|
15036
|
+
|
|
15037
|
+
/** @jsxImportSource vue */
|
|
15038
|
+
|
|
15039
|
+
const COMPONENT_NAME$14 = 'vc-dropdown-menu';
|
|
15040
|
+
const DropdownMenu = /* @__PURE__ */ vue.defineComponent({
|
|
15041
|
+
name: COMPONENT_NAME$14,
|
|
15042
|
+
setup(_, {
|
|
14953
15043
|
slots
|
|
14954
15044
|
}) {
|
|
14955
15045
|
return () => {
|
|
14956
|
-
return vue.createVNode("
|
|
14957
|
-
"class": "vc-dropdown"
|
|
15046
|
+
return vue.createVNode("ul", {
|
|
15047
|
+
"class": "vc-dropdown-menu"
|
|
14958
15048
|
}, [slots?.default?.()]);
|
|
14959
15049
|
};
|
|
14960
15050
|
}
|
|
14961
15051
|
});
|
|
14962
15052
|
|
|
15053
|
+
/** @jsxImportSource vue */
|
|
15054
|
+
|
|
15055
|
+
const COMPONENT_NAME$13 = 'vc-dropdown-item';
|
|
15056
|
+
const DropdownItem = /* @__PURE__ */ vue.defineComponent({
|
|
15057
|
+
name: COMPONENT_NAME$13,
|
|
15058
|
+
props: {
|
|
15059
|
+
value: {
|
|
15060
|
+
type: [String, Number],
|
|
15061
|
+
value: undefined
|
|
15062
|
+
},
|
|
15063
|
+
label: {
|
|
15064
|
+
type: [String, Number],
|
|
15065
|
+
value: undefined
|
|
15066
|
+
},
|
|
15067
|
+
disabled: {
|
|
15068
|
+
type: Boolean,
|
|
15069
|
+
default: false
|
|
15070
|
+
},
|
|
15071
|
+
selected: {
|
|
15072
|
+
type: Boolean,
|
|
15073
|
+
default: false
|
|
15074
|
+
},
|
|
15075
|
+
divided: {
|
|
15076
|
+
type: Boolean,
|
|
15077
|
+
default: false
|
|
15078
|
+
},
|
|
15079
|
+
closable: {
|
|
15080
|
+
type: Boolean,
|
|
15081
|
+
default: true
|
|
15082
|
+
}
|
|
15083
|
+
},
|
|
15084
|
+
setup(props, {
|
|
15085
|
+
slots,
|
|
15086
|
+
emit
|
|
15087
|
+
}) {
|
|
15088
|
+
const owner = getInstance$1('dropdown', 'dropdownId');
|
|
15089
|
+
const currentValue = vue.computed(() => {
|
|
15090
|
+
const v = typeof props.value === 'undefined' || props.value === '' ? props.label : props.value;
|
|
15091
|
+
return v;
|
|
15092
|
+
});
|
|
15093
|
+
const classes = vue.computed(() => {
|
|
15094
|
+
return {
|
|
15095
|
+
'is-selected': props.selected,
|
|
15096
|
+
'is-divided': props.divided,
|
|
15097
|
+
'is-disabled': props.disabled
|
|
15098
|
+
};
|
|
15099
|
+
});
|
|
15100
|
+
const handleClick = e => {
|
|
15101
|
+
if (props.disabled) return;
|
|
15102
|
+
emit('click', currentValue.value, e);
|
|
15103
|
+
owner.emit('click', currentValue.value, e);
|
|
15104
|
+
props.closable && owner.exposed?.close();
|
|
15105
|
+
};
|
|
15106
|
+
return () => {
|
|
15107
|
+
return vue.createVNode("li", {
|
|
15108
|
+
"class": [classes.value, 'vc-dropdown-item'],
|
|
15109
|
+
"onClick": handleClick
|
|
15110
|
+
}, [slots.default ? slots.default?.() : props.label]);
|
|
15111
|
+
};
|
|
15112
|
+
}
|
|
15113
|
+
});
|
|
15114
|
+
|
|
14963
15115
|
const MDropdown = Dropdown;
|
|
15116
|
+
const MDropdownMenu = DropdownMenu;
|
|
15117
|
+
const MDropdownItem = DropdownItem;
|
|
14964
15118
|
|
|
14965
15119
|
const props$N = {
|
|
14966
15120
|
tag: {
|
|
@@ -15378,6 +15532,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
15378
15532
|
"is-validating": validateState.value === "validating",
|
|
15379
15533
|
"is-inline": form.props.inline,
|
|
15380
15534
|
"is-nest": isNest.value,
|
|
15535
|
+
"is-alone": !props.showMessage,
|
|
15536
|
+
// 用于单独去除form-item的默认margin_bottom
|
|
15381
15537
|
[`is-${labelPosition.value}`]: true
|
|
15382
15538
|
};
|
|
15383
15539
|
});
|
|
@@ -19156,6 +19312,9 @@ var VcComponents = (function (exports, vue) {
|
|
|
19156
19312
|
type: Boolean,
|
|
19157
19313
|
default: false
|
|
19158
19314
|
},
|
|
19315
|
+
// draggable为true时有效
|
|
19316
|
+
x: Number,
|
|
19317
|
+
y: Number,
|
|
19159
19318
|
okText: {
|
|
19160
19319
|
type: [String, Boolean],
|
|
19161
19320
|
default: "确定"
|
|
@@ -19213,8 +19372,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
19213
19372
|
const header = vue.shallowRef();
|
|
19214
19373
|
const scroller = vue.shallowRef();
|
|
19215
19374
|
const resizer = vue.shallowRef();
|
|
19216
|
-
const x = vue.ref(
|
|
19217
|
-
const y = vue.ref(
|
|
19375
|
+
const x = vue.ref(props.x);
|
|
19376
|
+
const y = vue.ref(props.y);
|
|
19218
19377
|
const isActive = vue.ref(false);
|
|
19219
19378
|
|
|
19220
19379
|
// 注: 服务端渲染为0, 在客服端激活前,展示端存在问题【高度不定】
|
|
@@ -19256,8 +19415,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
19256
19415
|
});
|
|
19257
19416
|
const draggableStyle = vue.computed(() => {
|
|
19258
19417
|
if (IS_SERVER$2 || !props.draggable) return {};
|
|
19259
|
-
const left = x.value
|
|
19260
|
-
const top = y.value
|
|
19418
|
+
const left = typeof x.value === 'undefined' ? window.innerWidth / 2 - defaultSize.value.width / 2 : x.value;
|
|
19419
|
+
const top = typeof y.value === 'undefined' ? window.innerHeight / 2 - defaultSize.value.height / 2 : y.value;
|
|
19261
19420
|
return {
|
|
19262
19421
|
left: `${left}px`,
|
|
19263
19422
|
top: `${top}px`
|
|
@@ -20854,10 +21013,49 @@ var VcComponents = (function (exports, vue) {
|
|
|
20854
21013
|
const MPicker = Picker;
|
|
20855
21014
|
|
|
20856
21015
|
const props$p = {
|
|
20857
|
-
|
|
21016
|
+
title: {
|
|
21017
|
+
type: [String, Function],
|
|
21018
|
+
default: ""
|
|
21019
|
+
},
|
|
21020
|
+
content: {
|
|
21021
|
+
type: [String, Function],
|
|
21022
|
+
default: ""
|
|
21023
|
+
},
|
|
21024
|
+
modelValue: {
|
|
21025
|
+
type: Boolean,
|
|
21026
|
+
default: false
|
|
21027
|
+
},
|
|
21028
|
+
placement: {
|
|
20858
21029
|
type: String,
|
|
20859
|
-
default: "
|
|
20860
|
-
}
|
|
21030
|
+
default: "top"
|
|
21031
|
+
},
|
|
21032
|
+
trigger: {
|
|
21033
|
+
type: String,
|
|
21034
|
+
default: "click"
|
|
21035
|
+
},
|
|
21036
|
+
okText: {
|
|
21037
|
+
type: String,
|
|
21038
|
+
default: "确定"
|
|
21039
|
+
},
|
|
21040
|
+
cancelText: {
|
|
21041
|
+
type: String,
|
|
21042
|
+
default: "取消"
|
|
21043
|
+
},
|
|
21044
|
+
okType: {
|
|
21045
|
+
type: String,
|
|
21046
|
+
default: "primary"
|
|
21047
|
+
},
|
|
21048
|
+
cancelType: {
|
|
21049
|
+
type: String,
|
|
21050
|
+
default: "default"
|
|
21051
|
+
},
|
|
21052
|
+
type: {
|
|
21053
|
+
type: String,
|
|
21054
|
+
default: "warning",
|
|
21055
|
+
validator: (v) => /(warning|info|success|error)/.test(v)
|
|
21056
|
+
},
|
|
21057
|
+
width: [String, Number],
|
|
21058
|
+
portalClass: [String, Object]
|
|
20861
21059
|
};
|
|
20862
21060
|
|
|
20863
21061
|
/** @jsxImportSource vue */
|
|
@@ -20866,13 +21064,125 @@ var VcComponents = (function (exports, vue) {
|
|
|
20866
21064
|
const Popconfirm = /* @__PURE__ */ vue.defineComponent({
|
|
20867
21065
|
name: COMPONENT_NAME$C,
|
|
20868
21066
|
props: props$p,
|
|
21067
|
+
inheritAttrs: false,
|
|
21068
|
+
emits: ['update:modelValue', 'visible-change', 'ready', 'close', 'cancel', 'ok'],
|
|
20869
21069
|
setup(props, {
|
|
20870
|
-
slots
|
|
21070
|
+
slots,
|
|
21071
|
+
emit
|
|
20871
21072
|
}) {
|
|
21073
|
+
const instance = vue.getCurrentInstance();
|
|
21074
|
+
const its = useAttrs({
|
|
21075
|
+
merge: false
|
|
21076
|
+
});
|
|
21077
|
+
const isActive = vue.ref(false);
|
|
21078
|
+
const contentStyle = vue.computed(() => {
|
|
21079
|
+
return props.content || !!slots.content ? {
|
|
21080
|
+
marginBottom: '15px'
|
|
21081
|
+
} : {};
|
|
21082
|
+
});
|
|
21083
|
+
const inherit = vue.computed(() => {
|
|
21084
|
+
return {
|
|
21085
|
+
style: its.value.style,
|
|
21086
|
+
class: its.value.class
|
|
21087
|
+
};
|
|
21088
|
+
});
|
|
21089
|
+
const attrs = vue.computed(() => {
|
|
21090
|
+
return its.value.attrs;
|
|
21091
|
+
});
|
|
21092
|
+
vue.watch(() => props.modelValue, v => {
|
|
21093
|
+
isActive.value = v;
|
|
21094
|
+
}, {
|
|
21095
|
+
immediate: true
|
|
21096
|
+
});
|
|
21097
|
+
|
|
21098
|
+
/**
|
|
21099
|
+
* v-model 同步, 外部的数据改变时不会触发
|
|
21100
|
+
*/
|
|
21101
|
+
const sync = () => {
|
|
21102
|
+
emit('update:modelValue', isActive.value);
|
|
21103
|
+
emit('visible-change', isActive.value);
|
|
21104
|
+
};
|
|
21105
|
+
const handleBefore = (e, hook) => {
|
|
21106
|
+
e.stopPropagation();
|
|
21107
|
+
e.preventDefault();
|
|
21108
|
+
if (!isActive.value) return;
|
|
21109
|
+
const fn = hook && hook(e);
|
|
21110
|
+
if (fn && fn.then) {
|
|
21111
|
+
return fn.then(res => {
|
|
21112
|
+
isActive.value = false;
|
|
21113
|
+
sync();
|
|
21114
|
+
return res;
|
|
21115
|
+
});
|
|
21116
|
+
} else if (!fn || fn === true) {
|
|
21117
|
+
isActive.value = false;
|
|
21118
|
+
sync();
|
|
21119
|
+
}
|
|
21120
|
+
};
|
|
21121
|
+
const handleOk = (...rest) => {
|
|
21122
|
+
const ok = instance.vnode.props?.onOk || (() => {});
|
|
21123
|
+
return ok(...rest);
|
|
21124
|
+
};
|
|
21125
|
+
const handleCancel = (...rest) => {
|
|
21126
|
+
const cancel = instance.vnode.props?.onCancel || (() => {});
|
|
21127
|
+
return cancel(...rest);
|
|
21128
|
+
};
|
|
21129
|
+
const handleChange = v => {
|
|
21130
|
+
isActive.value = v;
|
|
21131
|
+
sync();
|
|
21132
|
+
};
|
|
20872
21133
|
return () => {
|
|
20873
|
-
return vue.createVNode(
|
|
20874
|
-
"
|
|
20875
|
-
|
|
21134
|
+
return vue.createVNode(Popover, vue.mergeProps(attrs.value, {
|
|
21135
|
+
"modelValue": isActive.value,
|
|
21136
|
+
"placement": props.placement,
|
|
21137
|
+
"trigger": props.trigger,
|
|
21138
|
+
"portalClass": ['is-padding-none', 'vc-popconfirm-wrapper', props.portalClass],
|
|
21139
|
+
"class": ['vc-popconfirm', inherit.value.class],
|
|
21140
|
+
"style": inherit.value.style,
|
|
21141
|
+
"onReady": () => emit('ready'),
|
|
21142
|
+
"onClose": () => emit('close'),
|
|
21143
|
+
"onVisibleChange": handleChange
|
|
21144
|
+
}), {
|
|
21145
|
+
default: () => slots?.default?.(),
|
|
21146
|
+
content: () => {
|
|
21147
|
+
return vue.createVNode("div", {
|
|
21148
|
+
"style": [{
|
|
21149
|
+
width: `${props.width}px`
|
|
21150
|
+
}],
|
|
21151
|
+
"class": "vc-popconfirm__wrapper"
|
|
21152
|
+
}, [vue.createVNode("div", {
|
|
21153
|
+
"class": "vc-popconfirm__title"
|
|
21154
|
+
}, [slots.icon ? slots.icon() : vue.createVNode(Icon, {
|
|
21155
|
+
"type": props.type,
|
|
21156
|
+
"class": [`is-${props.type}`, 'vc-popconfirm__icon']
|
|
21157
|
+
}, null), vue.createVNode("div", null, [slots.title ? slots.title() : typeof props.title === 'string' ? vue.createVNode("div", {
|
|
21158
|
+
"innerHTML": props.title
|
|
21159
|
+
}, null) : typeof props.title === 'function' ? vue.createVNode(Customer, {
|
|
21160
|
+
"render": props.title
|
|
21161
|
+
}, null) : null])]), vue.createVNode("div", {
|
|
21162
|
+
"style": contentStyle.value,
|
|
21163
|
+
"class": "vc-popconfirm__content"
|
|
21164
|
+
}, [slots.content ? slots.content() : typeof props.content === 'string' ? vue.createVNode("div", {
|
|
21165
|
+
"innerHTML": props.content
|
|
21166
|
+
}, null) : typeof props.content === 'function' ? vue.createVNode(Customer, {
|
|
21167
|
+
"render": props.content
|
|
21168
|
+
}, null) : null]), vue.createVNode("div", {
|
|
21169
|
+
"class": "vc-popconfirm__footer"
|
|
21170
|
+
}, [vue.createVNode(Button, {
|
|
21171
|
+
"type": props.cancelType,
|
|
21172
|
+
"style": "margin-right: 8px;",
|
|
21173
|
+
"size": "small",
|
|
21174
|
+
"onClick": e => handleBefore(e, handleCancel)
|
|
21175
|
+
}, {
|
|
21176
|
+
default: () => [props.cancelText]
|
|
21177
|
+
}), vue.createVNode(Button, {
|
|
21178
|
+
"type": props.okType,
|
|
21179
|
+
"size": "small",
|
|
21180
|
+
"onClick": e => handleBefore(e, handleOk)
|
|
21181
|
+
}, {
|
|
21182
|
+
default: () => [props.okText]
|
|
21183
|
+
})])]);
|
|
21184
|
+
}
|
|
21185
|
+
});
|
|
20876
21186
|
};
|
|
20877
21187
|
}
|
|
20878
21188
|
});
|
|
@@ -22593,6 +22903,18 @@ var VcComponents = (function (exports, vue) {
|
|
|
22593
22903
|
uncheckedText: {
|
|
22594
22904
|
type: String,
|
|
22595
22905
|
default: ""
|
|
22906
|
+
},
|
|
22907
|
+
width: {
|
|
22908
|
+
type: Number,
|
|
22909
|
+
default: 36
|
|
22910
|
+
},
|
|
22911
|
+
height: {
|
|
22912
|
+
type: Number,
|
|
22913
|
+
default: 20
|
|
22914
|
+
},
|
|
22915
|
+
borderWidth: {
|
|
22916
|
+
type: Number,
|
|
22917
|
+
default: 1
|
|
22596
22918
|
}
|
|
22597
22919
|
};
|
|
22598
22920
|
|
|
@@ -22675,28 +22997,65 @@ var VcComponents = (function (exports, vue) {
|
|
|
22675
22997
|
expose
|
|
22676
22998
|
}) {
|
|
22677
22999
|
const {
|
|
23000
|
+
checked,
|
|
22678
23001
|
classes,
|
|
22679
23002
|
currentValue,
|
|
22680
23003
|
isLoading,
|
|
22681
23004
|
handleToggle
|
|
22682
23005
|
} = useSwitch(expose);
|
|
23006
|
+
const size = vue.computed(() => {
|
|
23007
|
+
return props.height - props.borderWidth * 4;
|
|
23008
|
+
});
|
|
23009
|
+
const lefts = vue.computed(() => {
|
|
23010
|
+
return {
|
|
23011
|
+
inner: checked.value ? props.width - props.borderWidth * 3 - size.value : props.borderWidth,
|
|
23012
|
+
loading: checked.value ? props.height - props.borderWidth * 2 : props.borderWidth * 2
|
|
23013
|
+
};
|
|
23014
|
+
});
|
|
23015
|
+
const contentOffset = vue.computed(() => {
|
|
23016
|
+
return Math.max(props.height / 2, size.value) + props.borderWidth * 2;
|
|
23017
|
+
});
|
|
22683
23018
|
return () => {
|
|
22684
|
-
return vue.createVNode("
|
|
22685
|
-
"
|
|
23019
|
+
return vue.createVNode("div", {
|
|
23020
|
+
"style": {
|
|
23021
|
+
width: `${props.width}px`
|
|
23022
|
+
},
|
|
23023
|
+
"class": [classes.value, 'vc-switch']
|
|
23024
|
+
}, [vue.createVNode("span", {
|
|
23025
|
+
"style": {
|
|
23026
|
+
height: `${props.height}px`,
|
|
23027
|
+
borderWidth: `${props.borderWidth}px`
|
|
23028
|
+
},
|
|
23029
|
+
"class": "vc-switch__wrapper",
|
|
22686
23030
|
"onClick": handleToggle
|
|
22687
23031
|
}, [vue.createVNode("input", {
|
|
22688
23032
|
"name": props.name,
|
|
22689
23033
|
"value": currentValue.value,
|
|
22690
23034
|
"type": "hidden"
|
|
22691
23035
|
}, null), vue.createVNode("span", {
|
|
22692
|
-
"class": "vc-switch__content"
|
|
23036
|
+
"class": "vc-switch__content",
|
|
23037
|
+
"style": {
|
|
23038
|
+
left: `${checked.value ? props.height / 4 : contentOffset.value}px`,
|
|
23039
|
+
right: `${checked.value ? contentOffset.value : props.height / 4}px`,
|
|
23040
|
+
top: 0,
|
|
23041
|
+
bottom: 0
|
|
23042
|
+
}
|
|
22693
23043
|
}, [currentValue.value === props.checkedValue ? slots.checked ? slots.checked() : props.checkedText : null, currentValue.value === props.uncheckedValue ? slots.unchecked ? slots.unchecked() : props.uncheckedText : null]), vue.createVNode("span", {
|
|
22694
|
-
"class": "vc-switch__inner"
|
|
23044
|
+
"class": "vc-switch__inner",
|
|
23045
|
+
"style": {
|
|
23046
|
+
width: `${size.value}px`,
|
|
23047
|
+
height: `${size.value}px`,
|
|
23048
|
+
left: `${lefts.value.inner}px`,
|
|
23049
|
+
top: `${props.borderWidth}px`
|
|
23050
|
+
}
|
|
22695
23051
|
}, null), isLoading.value && vue.createVNode(Spin, {
|
|
22696
23052
|
"size": 14,
|
|
22697
23053
|
"foreground": "#fff",
|
|
22698
|
-
"class": "vc-switch__loading"
|
|
22699
|
-
|
|
23054
|
+
"class": "vc-switch__loading",
|
|
23055
|
+
"style": {
|
|
23056
|
+
left: `${lefts.value.loading}px`
|
|
23057
|
+
}
|
|
23058
|
+
}, null)])]);
|
|
22700
23059
|
};
|
|
22701
23060
|
}
|
|
22702
23061
|
});
|
|
@@ -41066,6 +41425,79 @@ var VcComponents = (function (exports, vue) {
|
|
|
41066
41425
|
}
|
|
41067
41426
|
});
|
|
41068
41427
|
|
|
41428
|
+
const HIDDEN_TEXT_STYLE = `
|
|
41429
|
+
position: absolute!important;
|
|
41430
|
+
word-break: break-all!important;
|
|
41431
|
+
overflow: auto!important;
|
|
41432
|
+
opacity: 1!important;
|
|
41433
|
+
z-index: -1000!important;
|
|
41434
|
+
top: 0!important;
|
|
41435
|
+
right: 100px!important;
|
|
41436
|
+
`;
|
|
41437
|
+
const SIZING_STYLE$1 = [
|
|
41438
|
+
"letter-spacing",
|
|
41439
|
+
"line-height",
|
|
41440
|
+
"padding-top",
|
|
41441
|
+
"padding-bottom",
|
|
41442
|
+
"font-family",
|
|
41443
|
+
"font-weight",
|
|
41444
|
+
"font-size",
|
|
41445
|
+
"text-rendering",
|
|
41446
|
+
"text-transform",
|
|
41447
|
+
"width",
|
|
41448
|
+
// 'text-indent', // 需要额外计算
|
|
41449
|
+
"padding-left",
|
|
41450
|
+
"padding-right",
|
|
41451
|
+
"border-width",
|
|
41452
|
+
"box-sizing"
|
|
41453
|
+
];
|
|
41454
|
+
let hiddenEl$1;
|
|
41455
|
+
const getFitIndex = (options = {}) => {
|
|
41456
|
+
const { el, line, value, suffix, indent = 0 } = options;
|
|
41457
|
+
let lineHeight = parseInt(getStyle$1(el, "line-height"), 10);
|
|
41458
|
+
if (!hiddenEl$1) {
|
|
41459
|
+
hiddenEl$1 = document.createElement("div");
|
|
41460
|
+
document.body.appendChild(hiddenEl$1);
|
|
41461
|
+
}
|
|
41462
|
+
el.getAttribute("wrap") ? hiddenEl$1.setAttribute("wrap", el.getAttribute("wrap")) : hiddenEl$1.removeAttribute("wrap");
|
|
41463
|
+
const {
|
|
41464
|
+
paddingSize,
|
|
41465
|
+
borderSize,
|
|
41466
|
+
boxSizing,
|
|
41467
|
+
sizingStyle
|
|
41468
|
+
} = utils.getComputedStyle(el, SIZING_STYLE$1);
|
|
41469
|
+
const textIndent = `text-indent: ${parseInt(getStyle$1(el, "text-indent"), 10) + indent}px;`;
|
|
41470
|
+
hiddenEl$1.setAttribute("style", `${sizingStyle};${textIndent};${HIDDEN_TEXT_STYLE}`);
|
|
41471
|
+
let sideHeight = paddingSize || 0;
|
|
41472
|
+
boxSizing === "border-box" && (sideHeight += borderSize);
|
|
41473
|
+
if (Number.isNaN(lineHeight)) {
|
|
41474
|
+
hiddenEl$1.innerText = ".";
|
|
41475
|
+
lineHeight = hiddenEl$1.clientHeight - sideHeight;
|
|
41476
|
+
}
|
|
41477
|
+
let endIndex = -1;
|
|
41478
|
+
const strs = (typeof value === "number" ? `${value}` : value || "").split("");
|
|
41479
|
+
let innerText = "";
|
|
41480
|
+
for (let i = 0; i < strs.length; i++) {
|
|
41481
|
+
innerText += strs[i];
|
|
41482
|
+
hiddenEl$1.innerText = innerText;
|
|
41483
|
+
if (endIndex === -1 && hiddenEl$1.clientHeight - sideHeight > lineHeight * line) {
|
|
41484
|
+
endIndex = i;
|
|
41485
|
+
break;
|
|
41486
|
+
}
|
|
41487
|
+
}
|
|
41488
|
+
if (endIndex >= 0 && endIndex <= strs.length - 1) {
|
|
41489
|
+
for (let i = endIndex - 1; i >= 0; i--) {
|
|
41490
|
+
innerText = innerText.substring(0, i);
|
|
41491
|
+
hiddenEl$1.innerText = innerText + suffix;
|
|
41492
|
+
if (hiddenEl$1.clientHeight - sideHeight <= lineHeight * line) {
|
|
41493
|
+
endIndex = i;
|
|
41494
|
+
break;
|
|
41495
|
+
}
|
|
41496
|
+
}
|
|
41497
|
+
}
|
|
41498
|
+
return endIndex;
|
|
41499
|
+
};
|
|
41500
|
+
|
|
41069
41501
|
const TableBody = /* @__PURE__ */ vue.defineComponent({
|
|
41070
41502
|
name: 'vc-table-body',
|
|
41071
41503
|
props: {
|
|
@@ -41174,10 +41606,13 @@ var VcComponents = (function (exports, vue) {
|
|
|
41174
41606
|
column
|
|
41175
41607
|
});
|
|
41176
41608
|
}
|
|
41177
|
-
return
|
|
41609
|
+
return {
|
|
41610
|
+
...cellStyle,
|
|
41611
|
+
...column.style
|
|
41612
|
+
};
|
|
41178
41613
|
};
|
|
41179
41614
|
const getCellClass = (rowIndex, columnIndex, row, column) => {
|
|
41180
|
-
const classes = [column.realAlign, column.
|
|
41615
|
+
const classes = [column.realAlign, column.class];
|
|
41181
41616
|
if (isColumnHidden(columnIndex)) {
|
|
41182
41617
|
classes.push('is-hidden');
|
|
41183
41618
|
}
|
|
@@ -41194,24 +41629,44 @@ var VcComponents = (function (exports, vue) {
|
|
|
41194
41629
|
}
|
|
41195
41630
|
return classes.join(' ');
|
|
41196
41631
|
};
|
|
41197
|
-
|
|
41632
|
+
let poper;
|
|
41633
|
+
const handleCellMouseEnter = (e, row, column) => {
|
|
41198
41634
|
const cell = getCell(e);
|
|
41635
|
+
const hoverState = {
|
|
41636
|
+
cell,
|
|
41637
|
+
column,
|
|
41638
|
+
row
|
|
41639
|
+
};
|
|
41199
41640
|
if (cell) {
|
|
41200
|
-
const column = getColumnByCell(states.columns, cell);
|
|
41201
|
-
const hoverState = {
|
|
41202
|
-
cell,
|
|
41203
|
-
column,
|
|
41204
|
-
row
|
|
41205
|
-
};
|
|
41206
41641
|
table.hoverState.value = hoverState;
|
|
41207
41642
|
table.emit('cell-mouse-enter', hoverState.row, hoverState.column, hoverState.cell, e);
|
|
41208
41643
|
}
|
|
41644
|
+
// 判断是否text-overflow, 如果是就显示tooltip
|
|
41645
|
+
const el = e.target.querySelector('.vc-table__text-line');
|
|
41646
|
+
if (!el) return;
|
|
41647
|
+
const value = `${row[column.prop]}`;
|
|
41648
|
+
const endIndex = getFitIndex({
|
|
41649
|
+
el,
|
|
41650
|
+
value,
|
|
41651
|
+
line: column.line,
|
|
41652
|
+
suffix: '...'
|
|
41653
|
+
});
|
|
41654
|
+
if (endIndex > 0 && endIndex < value.length - 1) {
|
|
41655
|
+
poper && poper.destroy();
|
|
41656
|
+
poper = Popover.open({
|
|
41657
|
+
el: document.body,
|
|
41658
|
+
triggerEl: el,
|
|
41659
|
+
hover: true,
|
|
41660
|
+
alone: true,
|
|
41661
|
+
autoWidth: true,
|
|
41662
|
+
content: value
|
|
41663
|
+
});
|
|
41664
|
+
}
|
|
41209
41665
|
};
|
|
41210
|
-
const handleCellMouseLeave = e => {
|
|
41666
|
+
const handleCellMouseLeave = (e, row, column) => {
|
|
41211
41667
|
const cell = getCell(e);
|
|
41212
41668
|
if (!cell) return;
|
|
41213
|
-
|
|
41214
|
-
table.emit('cell-mouse-leave', oldHoverState.row, oldHoverState.column, oldHoverState.cell, e);
|
|
41669
|
+
table.emit('cell-mouse-leave', row, column, cell, e);
|
|
41215
41670
|
};
|
|
41216
41671
|
const handleMouseEnter = debounce$1(index => {
|
|
41217
41672
|
table.store.setHoverRow(index);
|
|
@@ -41282,8 +41737,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
41282
41737
|
"key": column.id,
|
|
41283
41738
|
"style": [getCellStyle(rowIndex, columnIndex, row, column), sizeStyle],
|
|
41284
41739
|
"class": [getCellClass(rowIndex, columnIndex, row, column), 'vc-table__td'],
|
|
41285
|
-
"onMouseenter": e => handleCellMouseEnter(e, row),
|
|
41286
|
-
"onMouseleave": e => handleCellMouseLeave(e)
|
|
41740
|
+
"onMouseenter": e => handleCellMouseEnter(e, row, column),
|
|
41741
|
+
"onMouseleave": e => handleCellMouseLeave(e, row, column)
|
|
41287
41742
|
}, [renderCell({
|
|
41288
41743
|
row,
|
|
41289
41744
|
column,
|
|
@@ -41339,7 +41794,11 @@ var VcComponents = (function (exports, vue) {
|
|
|
41339
41794
|
allowRender.value = true;
|
|
41340
41795
|
}
|
|
41341
41796
|
});
|
|
41342
|
-
vue.onBeforeUnmount(() =>
|
|
41797
|
+
vue.onBeforeUnmount(() => {
|
|
41798
|
+
poper && poper.destroy();
|
|
41799
|
+
timer && clearTimeout(timer);
|
|
41800
|
+
allowRender.value = false;
|
|
41801
|
+
});
|
|
41343
41802
|
return () => {
|
|
41344
41803
|
if (!allowRender.value) return;
|
|
41345
41804
|
return vue.createVNode("div", {
|
|
@@ -41466,10 +41925,13 @@ var VcComponents = (function (exports, vue) {
|
|
|
41466
41925
|
column
|
|
41467
41926
|
});
|
|
41468
41927
|
}
|
|
41469
|
-
return
|
|
41928
|
+
return {
|
|
41929
|
+
...headerCellStyle,
|
|
41930
|
+
...column.style
|
|
41931
|
+
};
|
|
41470
41932
|
};
|
|
41471
41933
|
const getHeaderCellClass = (rowIndex, columnIndex, row, column) => {
|
|
41472
|
-
const classes = [column.id, column.order, column.realHeaderAlign, column.
|
|
41934
|
+
const classes = [column.id, column.order, column.realHeaderAlign, column.class, column.labelClass];
|
|
41473
41935
|
if (rowIndex === 0 && columnsHidden.value[columnIndex]) {
|
|
41474
41936
|
classes.push('is-hidden');
|
|
41475
41937
|
}
|
|
@@ -42404,196 +42866,6 @@ var VcComponents = (function (exports, vue) {
|
|
|
42404
42866
|
}
|
|
42405
42867
|
});
|
|
42406
42868
|
|
|
42407
|
-
const props$b = {
|
|
42408
|
-
tag: {
|
|
42409
|
-
type: String,
|
|
42410
|
-
default: "div"
|
|
42411
|
-
},
|
|
42412
|
-
value: {
|
|
42413
|
-
type: String,
|
|
42414
|
-
default: ""
|
|
42415
|
-
},
|
|
42416
|
-
line: {
|
|
42417
|
-
type: Number,
|
|
42418
|
-
default: 0
|
|
42419
|
-
},
|
|
42420
|
-
// TODO: 是否改为tail-indent来表示尾部缩进
|
|
42421
|
-
indent: {
|
|
42422
|
-
type: Number,
|
|
42423
|
-
default: 0
|
|
42424
|
-
},
|
|
42425
|
-
resize: {
|
|
42426
|
-
type: [Boolean, Number],
|
|
42427
|
-
default: 100
|
|
42428
|
-
},
|
|
42429
|
-
suffix: {
|
|
42430
|
-
type: String,
|
|
42431
|
-
default: "..."
|
|
42432
|
-
},
|
|
42433
|
-
placement: {
|
|
42434
|
-
type: String,
|
|
42435
|
-
default: "top"
|
|
42436
|
-
},
|
|
42437
|
-
portalClass: [Object, String, Array],
|
|
42438
|
-
portalStyle: [Object, String, Array],
|
|
42439
|
-
renderRow: {
|
|
42440
|
-
type: Function,
|
|
42441
|
-
default: (props$) => {
|
|
42442
|
-
return props$.value;
|
|
42443
|
-
}
|
|
42444
|
-
}
|
|
42445
|
-
};
|
|
42446
|
-
|
|
42447
|
-
const HIDDEN_TEXT_STYLE = `
|
|
42448
|
-
position: absolute!important;
|
|
42449
|
-
word-break: break-all!important;
|
|
42450
|
-
overflow: auto!important;
|
|
42451
|
-
opacity: 0!important;
|
|
42452
|
-
z-index: -1000!important;
|
|
42453
|
-
top: 0!important;
|
|
42454
|
-
right: 0!important;
|
|
42455
|
-
`;
|
|
42456
|
-
const SIZING_STYLE$1 = [
|
|
42457
|
-
"letter-spacing",
|
|
42458
|
-
"line-height",
|
|
42459
|
-
"padding-top",
|
|
42460
|
-
"padding-bottom",
|
|
42461
|
-
"font-family",
|
|
42462
|
-
"font-weight",
|
|
42463
|
-
"font-size",
|
|
42464
|
-
"text-rendering",
|
|
42465
|
-
"text-transform",
|
|
42466
|
-
"width",
|
|
42467
|
-
// 'text-indent', // 需要额外计算
|
|
42468
|
-
"padding-left",
|
|
42469
|
-
"padding-right",
|
|
42470
|
-
"border-width",
|
|
42471
|
-
"box-sizing"
|
|
42472
|
-
];
|
|
42473
|
-
let hiddenEl$1;
|
|
42474
|
-
const getFitIndex = (options = {}) => {
|
|
42475
|
-
const { el, line, value, suffix, indent } = options;
|
|
42476
|
-
let lineHeight = parseInt(getStyle$1(el, "line-height"), 10);
|
|
42477
|
-
if (!hiddenEl$1) {
|
|
42478
|
-
hiddenEl$1 = document.createElement("div");
|
|
42479
|
-
document.body.appendChild(hiddenEl$1);
|
|
42480
|
-
}
|
|
42481
|
-
el.getAttribute("wrap") ? hiddenEl$1.setAttribute("wrap", el.getAttribute("wrap")) : hiddenEl$1.removeAttribute("wrap");
|
|
42482
|
-
const {
|
|
42483
|
-
paddingSize,
|
|
42484
|
-
borderSize,
|
|
42485
|
-
boxSizing,
|
|
42486
|
-
sizingStyle
|
|
42487
|
-
} = utils.getComputedStyle(el, SIZING_STYLE$1);
|
|
42488
|
-
const textIndent = `text-indent: ${parseInt(getStyle$1(el, "text-indent"), 10) + indent}px;`;
|
|
42489
|
-
hiddenEl$1.setAttribute("style", `${sizingStyle};${textIndent};${HIDDEN_TEXT_STYLE}`);
|
|
42490
|
-
let sideHeight = paddingSize || 0;
|
|
42491
|
-
boxSizing === "border-box" && (sideHeight += borderSize);
|
|
42492
|
-
if (Number.isNaN(lineHeight)) {
|
|
42493
|
-
hiddenEl$1.innerText = ".";
|
|
42494
|
-
lineHeight = hiddenEl$1.clientHeight - sideHeight;
|
|
42495
|
-
}
|
|
42496
|
-
let endIndex = 0;
|
|
42497
|
-
hiddenEl$1.innerText = suffix;
|
|
42498
|
-
(value || "").split("").forEach((item, i) => {
|
|
42499
|
-
let old = hiddenEl$1.innerText;
|
|
42500
|
-
old = old.substring(0, old.length - suffix.length);
|
|
42501
|
-
hiddenEl$1.innerText = old + item + suffix;
|
|
42502
|
-
if (hiddenEl$1.clientHeight - sideHeight > lineHeight * line && endIndex === 0) {
|
|
42503
|
-
endIndex = i;
|
|
42504
|
-
}
|
|
42505
|
-
});
|
|
42506
|
-
return endIndex;
|
|
42507
|
-
};
|
|
42508
|
-
|
|
42509
|
-
/** @jsxImportSource vue */
|
|
42510
|
-
|
|
42511
|
-
const COMPONENT_NAME$h = 'vc-text';
|
|
42512
|
-
const Text = /* @__PURE__ */ vue.defineComponent({
|
|
42513
|
-
name: COMPONENT_NAME$h,
|
|
42514
|
-
props: props$b,
|
|
42515
|
-
setup(props, {
|
|
42516
|
-
emit
|
|
42517
|
-
}) {
|
|
42518
|
-
const instance = vue.getCurrentInstance();
|
|
42519
|
-
const isActive = vue.ref(false);
|
|
42520
|
-
const endIndex = vue.ref(0);
|
|
42521
|
-
const styles = vue.computed(() => {
|
|
42522
|
-
return {
|
|
42523
|
-
cursor: endIndex.value === 0 ? 'unset' : 'pointer'
|
|
42524
|
-
};
|
|
42525
|
-
});
|
|
42526
|
-
const calcPosition = () => {
|
|
42527
|
-
const {
|
|
42528
|
-
suffix,
|
|
42529
|
-
line,
|
|
42530
|
-
value,
|
|
42531
|
-
indent
|
|
42532
|
-
} = props;
|
|
42533
|
-
if (line === 0) {
|
|
42534
|
-
endIndex.value = 0;
|
|
42535
|
-
isActive.value = true;
|
|
42536
|
-
} else {
|
|
42537
|
-
endIndex.value = getFitIndex({
|
|
42538
|
-
el: instance.vnode.el,
|
|
42539
|
-
line,
|
|
42540
|
-
value,
|
|
42541
|
-
suffix,
|
|
42542
|
-
indent
|
|
42543
|
-
});
|
|
42544
|
-
isActive.value = true;
|
|
42545
|
-
}
|
|
42546
|
-
emit('clip', endIndex.value);
|
|
42547
|
-
};
|
|
42548
|
-
const handleResize = props.resize === true || props.resize === 0 ? calcPosition : debounce$1(calcPosition, props.resize || 0);
|
|
42549
|
-
let poper;
|
|
42550
|
-
const handleMouseOver = e => {
|
|
42551
|
-
if (endIndex.value > 0) {
|
|
42552
|
-
poper = Popover.open({
|
|
42553
|
-
el: document.body,
|
|
42554
|
-
name: 'vc-text-popover',
|
|
42555
|
-
// 确保不重复创建
|
|
42556
|
-
triggerEl: e.target,
|
|
42557
|
-
hover: true,
|
|
42558
|
-
theme: 'dark',
|
|
42559
|
-
placement: props.placement,
|
|
42560
|
-
portalClass: props.portalClass,
|
|
42561
|
-
portalStyle: [props.portalStyle || `width: ${e.target.clientWidth}px`, 'word-break: break-all'],
|
|
42562
|
-
content: props.value
|
|
42563
|
-
});
|
|
42564
|
-
}
|
|
42565
|
-
};
|
|
42566
|
-
const handleMouseOut = () => {
|
|
42567
|
-
// Do.
|
|
42568
|
-
};
|
|
42569
|
-
['value', 'indent', 'line'].forEach(key => {
|
|
42570
|
-
vue.watch(() => props[key], calcPosition);
|
|
42571
|
-
});
|
|
42572
|
-
vue.onMounted(() => {
|
|
42573
|
-
props.resize !== false && Resize.on(instance.vnode.el, handleResize); // 首次会执行一次
|
|
42574
|
-
});
|
|
42575
|
-
vue.onBeforeUnmount(() => {
|
|
42576
|
-
props.resize !== false && Resize.off(instance.vnode.el, handleResize);
|
|
42577
|
-
poper?.destroy?.();
|
|
42578
|
-
});
|
|
42579
|
-
const Content = props.tag;
|
|
42580
|
-
return () => {
|
|
42581
|
-
return vue.createVNode(Content, {
|
|
42582
|
-
"class": "vc-text",
|
|
42583
|
-
"style": styles.value,
|
|
42584
|
-
"onMouseover": handleMouseOver,
|
|
42585
|
-
"onMouseout": handleMouseOut
|
|
42586
|
-
}, {
|
|
42587
|
-
default: () => [isActive.value ? vue.createVNode(Customer, {
|
|
42588
|
-
"value": endIndex.value > 0 ? `${props.value.slice(0, endIndex.value)}${props.suffix}` : props.value,
|
|
42589
|
-
"index": endIndex.value,
|
|
42590
|
-
"render": props.renderRow
|
|
42591
|
-
}, null) : null]
|
|
42592
|
-
});
|
|
42593
|
-
};
|
|
42594
|
-
}
|
|
42595
|
-
});
|
|
42596
|
-
|
|
42597
42869
|
const cellStarts = {
|
|
42598
42870
|
default: {
|
|
42599
42871
|
order: ''
|
|
@@ -42601,8 +42873,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
42601
42873
|
selection: {
|
|
42602
42874
|
width: 60,
|
|
42603
42875
|
minWidth: 60,
|
|
42604
|
-
order: ''
|
|
42605
|
-
className: 'vc-table-column--selection'
|
|
42876
|
+
order: ''
|
|
42606
42877
|
},
|
|
42607
42878
|
expand: {
|
|
42608
42879
|
width: 60,
|
|
@@ -42648,7 +42919,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
42648
42919
|
}, null), [[vue.vShow, store.states.expandSelectable || level === 0]]);
|
|
42649
42920
|
},
|
|
42650
42921
|
sortable: false,
|
|
42651
|
-
resizable: false
|
|
42922
|
+
resizable: false,
|
|
42923
|
+
class: 'vc-table__selection-column'
|
|
42652
42924
|
},
|
|
42653
42925
|
index: {
|
|
42654
42926
|
renderHeader(h, {
|
|
@@ -42698,7 +42970,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
42698
42970
|
},
|
|
42699
42971
|
sortable: false,
|
|
42700
42972
|
resizable: false,
|
|
42701
|
-
|
|
42973
|
+
class: 'vc-table__expand-column'
|
|
42702
42974
|
}
|
|
42703
42975
|
};
|
|
42704
42976
|
|
|
@@ -42718,17 +42990,13 @@ var VcComponents = (function (exports, vue) {
|
|
|
42718
42990
|
}
|
|
42719
42991
|
const line = column.line || VcInstance.options.TableColumn?.line;
|
|
42720
42992
|
if (line && value) {
|
|
42721
|
-
const base = rowData.isHead || rowData.isTail ? 36 : 24; // 目前gap是12
|
|
42722
42993
|
const style = {
|
|
42723
|
-
|
|
42724
|
-
// TODO: 含有border还要-1
|
|
42725
|
-
width: (column.realWidth || column.width) - base + 'px'
|
|
42994
|
+
'-webkit-line-clamp': line
|
|
42726
42995
|
};
|
|
42727
|
-
return vue.createVNode(
|
|
42728
|
-
"
|
|
42729
|
-
"
|
|
42730
|
-
|
|
42731
|
-
}, null);
|
|
42996
|
+
return vue.createVNode("div", {
|
|
42997
|
+
"class": "vc-table__text-line",
|
|
42998
|
+
"style": style
|
|
42999
|
+
}, [value]);
|
|
42732
43000
|
}
|
|
42733
43001
|
return value;
|
|
42734
43002
|
};
|
|
@@ -42776,6 +43044,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
42776
43044
|
|
|
42777
43045
|
const TableColumn = /* @__PURE__ */ vue.defineComponent({
|
|
42778
43046
|
name: 'vc-table-column',
|
|
43047
|
+
inheritAttrs: false,
|
|
42779
43048
|
props: {
|
|
42780
43049
|
type: {
|
|
42781
43050
|
type: String,
|
|
@@ -42787,7 +43056,6 @@ var VcComponents = (function (exports, vue) {
|
|
|
42787
43056
|
default: 0
|
|
42788
43057
|
},
|
|
42789
43058
|
label: String,
|
|
42790
|
-
customClass: String,
|
|
42791
43059
|
labelClass: String,
|
|
42792
43060
|
prop: String,
|
|
42793
43061
|
width: Number,
|
|
@@ -42824,7 +43092,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
42824
43092
|
tooltip: [String, Function]
|
|
42825
43093
|
},
|
|
42826
43094
|
setup(props, {
|
|
42827
|
-
slots
|
|
43095
|
+
slots,
|
|
43096
|
+
attrs
|
|
42828
43097
|
}) {
|
|
42829
43098
|
const instance = vue.getCurrentInstance();
|
|
42830
43099
|
const table = vue.inject('vc-table');
|
|
@@ -42874,7 +43143,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
42874
43143
|
Object.keys(source).forEach(prop => {
|
|
42875
43144
|
const value = source[prop];
|
|
42876
43145
|
if (value !== undefined) {
|
|
42877
|
-
column[prop] = prop === '
|
|
43146
|
+
column[prop] = prop === 'class' ? `${column[prop] ? `${column[prop]} ` : ''}${value}` : value;
|
|
42878
43147
|
}
|
|
42879
43148
|
});
|
|
42880
43149
|
return column;
|
|
@@ -42944,7 +43213,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
42944
43213
|
// 存在树形数组,且当前行无箭头图标且处于当前展开列,表格对齐
|
|
42945
43214
|
if (!isEmpty$1(table.store.states.treeData) && !prefix && data.isExpandColumn) {
|
|
42946
43215
|
prefix = vue.createVNode("span", {
|
|
42947
|
-
"class": "vc-
|
|
43216
|
+
"class": "vc-table__unexpand__indent"
|
|
42948
43217
|
}, null);
|
|
42949
43218
|
}
|
|
42950
43219
|
const {
|
|
@@ -42960,6 +43229,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
42960
43229
|
const defaults = {
|
|
42961
43230
|
colspan: 1,
|
|
42962
43231
|
rowspan: 1,
|
|
43232
|
+
class: attrs.class,
|
|
43233
|
+
style: attrs.style,
|
|
42963
43234
|
...cellStarts[props.type],
|
|
42964
43235
|
id: columnId.value,
|
|
42965
43236
|
realAlign,
|
|
@@ -43046,7 +43317,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
43046
43317
|
const MTable = Table;
|
|
43047
43318
|
const MTableColumn = TableColumn;
|
|
43048
43319
|
|
|
43049
|
-
const props$
|
|
43320
|
+
const props$b = {
|
|
43050
43321
|
type: {
|
|
43051
43322
|
type: String,
|
|
43052
43323
|
validator: (v) => /^(line|card)$/.test(v),
|
|
@@ -43205,10 +43476,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
43205
43476
|
|
|
43206
43477
|
/** @jsxImportSource vue */
|
|
43207
43478
|
|
|
43208
|
-
const COMPONENT_NAME$
|
|
43479
|
+
const COMPONENT_NAME$h = 'vc-tabs';
|
|
43209
43480
|
const Tabs = /* @__PURE__ */ vue.defineComponent({
|
|
43210
|
-
name: COMPONENT_NAME$
|
|
43211
|
-
props: props$
|
|
43481
|
+
name: COMPONENT_NAME$h,
|
|
43482
|
+
props: props$b,
|
|
43212
43483
|
emits: ['update:modelValue', 'change', 'click'],
|
|
43213
43484
|
setup(props, {
|
|
43214
43485
|
slots
|
|
@@ -43373,7 +43644,7 @@ var VcComponents = (function (exports, vue) {
|
|
|
43373
43644
|
}
|
|
43374
43645
|
});
|
|
43375
43646
|
|
|
43376
|
-
const props$
|
|
43647
|
+
const props$a = {
|
|
43377
43648
|
value: {
|
|
43378
43649
|
type: [String, Number]
|
|
43379
43650
|
},
|
|
@@ -43455,10 +43726,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
43455
43726
|
|
|
43456
43727
|
/** @jsxImportSource vue */
|
|
43457
43728
|
|
|
43458
|
-
const COMPONENT_NAME$
|
|
43729
|
+
const COMPONENT_NAME$g = 'vc-tabs-pane';
|
|
43459
43730
|
const TabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
43460
|
-
name: COMPONENT_NAME$
|
|
43461
|
-
props: props$
|
|
43731
|
+
name: COMPONENT_NAME$g,
|
|
43732
|
+
props: props$a,
|
|
43462
43733
|
setup(_, {
|
|
43463
43734
|
slots
|
|
43464
43735
|
}) {
|
|
@@ -43473,8 +43744,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
43473
43744
|
}
|
|
43474
43745
|
});
|
|
43475
43746
|
|
|
43476
|
-
const props$
|
|
43477
|
-
...props$
|
|
43747
|
+
const props$9 = {
|
|
43748
|
+
...props$b,
|
|
43478
43749
|
theme: {
|
|
43479
43750
|
type: String,
|
|
43480
43751
|
default: "light",
|
|
@@ -43512,10 +43783,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
43512
43783
|
|
|
43513
43784
|
/** @jsxImportSource vue */
|
|
43514
43785
|
|
|
43515
|
-
const COMPONENT_NAME$
|
|
43786
|
+
const COMPONENT_NAME$f = 'vcm-tabs';
|
|
43516
43787
|
const MTabs = /* @__PURE__ */ vue.defineComponent({
|
|
43517
|
-
name: COMPONENT_NAME$
|
|
43518
|
-
props: props$
|
|
43788
|
+
name: COMPONENT_NAME$f,
|
|
43789
|
+
props: props$9,
|
|
43519
43790
|
emits: ['update:modelValue', 'change', 'click'],
|
|
43520
43791
|
setup(props, {
|
|
43521
43792
|
slots
|
|
@@ -43779,10 +44050,10 @@ var VcComponents = (function (exports, vue) {
|
|
|
43779
44050
|
|
|
43780
44051
|
/** @jsxImportSource vue */
|
|
43781
44052
|
|
|
43782
|
-
const COMPONENT_NAME$
|
|
44053
|
+
const COMPONENT_NAME$e = 'vcm-tabs-pane';
|
|
43783
44054
|
const MTabsPane = /* @__PURE__ */ vue.defineComponent({
|
|
43784
|
-
name: COMPONENT_NAME$
|
|
43785
|
-
props: props$
|
|
44055
|
+
name: COMPONENT_NAME$e,
|
|
44056
|
+
props: props$a,
|
|
43786
44057
|
setup(_, {
|
|
43787
44058
|
slots
|
|
43788
44059
|
}) {
|
|
@@ -43799,6 +44070,134 @@ var VcComponents = (function (exports, vue) {
|
|
|
43799
44070
|
|
|
43800
44071
|
const MTag = Tag;
|
|
43801
44072
|
|
|
44073
|
+
const props$8 = {
|
|
44074
|
+
tag: {
|
|
44075
|
+
type: String,
|
|
44076
|
+
default: "div"
|
|
44077
|
+
},
|
|
44078
|
+
value: {
|
|
44079
|
+
type: String,
|
|
44080
|
+
default: ""
|
|
44081
|
+
},
|
|
44082
|
+
line: {
|
|
44083
|
+
type: Number,
|
|
44084
|
+
default: 0
|
|
44085
|
+
},
|
|
44086
|
+
// TODO: 是否改为tail-indent来表示尾部缩进
|
|
44087
|
+
indent: {
|
|
44088
|
+
type: Number,
|
|
44089
|
+
default: 0
|
|
44090
|
+
},
|
|
44091
|
+
resize: {
|
|
44092
|
+
type: [Boolean, Number],
|
|
44093
|
+
default: 100
|
|
44094
|
+
},
|
|
44095
|
+
suffix: {
|
|
44096
|
+
type: String,
|
|
44097
|
+
default: "..."
|
|
44098
|
+
},
|
|
44099
|
+
placement: {
|
|
44100
|
+
type: String,
|
|
44101
|
+
default: "top"
|
|
44102
|
+
},
|
|
44103
|
+
portalClass: [Object, String, Array],
|
|
44104
|
+
portalStyle: [Object, String, Array],
|
|
44105
|
+
renderRow: {
|
|
44106
|
+
type: Function,
|
|
44107
|
+
default: (props$) => {
|
|
44108
|
+
return props$.value;
|
|
44109
|
+
}
|
|
44110
|
+
}
|
|
44111
|
+
};
|
|
44112
|
+
|
|
44113
|
+
/** @jsxImportSource vue */
|
|
44114
|
+
|
|
44115
|
+
const COMPONENT_NAME$d = 'vc-text';
|
|
44116
|
+
const Text = /* @__PURE__ */ vue.defineComponent({
|
|
44117
|
+
name: COMPONENT_NAME$d,
|
|
44118
|
+
props: props$8,
|
|
44119
|
+
setup(props, {
|
|
44120
|
+
emit
|
|
44121
|
+
}) {
|
|
44122
|
+
const instance = vue.getCurrentInstance();
|
|
44123
|
+
const isActive = vue.ref(false);
|
|
44124
|
+
const endIndex = vue.ref(-1);
|
|
44125
|
+
const styles = vue.computed(() => {
|
|
44126
|
+
return {
|
|
44127
|
+
cursor: endIndex.value <= 0 ? 'unset' : 'pointer'
|
|
44128
|
+
};
|
|
44129
|
+
});
|
|
44130
|
+
const calcPosition = () => {
|
|
44131
|
+
const {
|
|
44132
|
+
suffix,
|
|
44133
|
+
line,
|
|
44134
|
+
value,
|
|
44135
|
+
indent
|
|
44136
|
+
} = props;
|
|
44137
|
+
if (line === 0) {
|
|
44138
|
+
endIndex.value = -1;
|
|
44139
|
+
isActive.value = true;
|
|
44140
|
+
} else {
|
|
44141
|
+
endIndex.value = getFitIndex({
|
|
44142
|
+
el: instance.vnode.el,
|
|
44143
|
+
line,
|
|
44144
|
+
value,
|
|
44145
|
+
suffix,
|
|
44146
|
+
indent
|
|
44147
|
+
});
|
|
44148
|
+
isActive.value = true;
|
|
44149
|
+
}
|
|
44150
|
+
emit('clip', endIndex.value);
|
|
44151
|
+
};
|
|
44152
|
+
const handleResize = props.resize === true || props.resize === 0 ? calcPosition : debounce$1(calcPosition, props.resize || 0);
|
|
44153
|
+
let poper;
|
|
44154
|
+
const handleMouseOver = e => {
|
|
44155
|
+
if (endIndex.value > 0) {
|
|
44156
|
+
poper = Popover.open({
|
|
44157
|
+
el: document.body,
|
|
44158
|
+
name: 'vc-text-popover',
|
|
44159
|
+
// 确保不重复创建
|
|
44160
|
+
triggerEl: e.target,
|
|
44161
|
+
hover: true,
|
|
44162
|
+
theme: 'dark',
|
|
44163
|
+
placement: props.placement,
|
|
44164
|
+
portalClass: props.portalClass,
|
|
44165
|
+
portalStyle: [props.portalStyle || `width: ${e.target.clientWidth}px`, 'word-break: break-all'],
|
|
44166
|
+
content: props.value
|
|
44167
|
+
});
|
|
44168
|
+
}
|
|
44169
|
+
};
|
|
44170
|
+
const handleMouseOut = () => {
|
|
44171
|
+
// Do.
|
|
44172
|
+
};
|
|
44173
|
+
['value', 'indent', 'line'].forEach(key => {
|
|
44174
|
+
vue.watch(() => props[key], calcPosition);
|
|
44175
|
+
});
|
|
44176
|
+
vue.onMounted(() => {
|
|
44177
|
+
props.resize !== false && Resize.on(instance.vnode.el, handleResize); // 首次会执行一次
|
|
44178
|
+
});
|
|
44179
|
+
vue.onBeforeUnmount(() => {
|
|
44180
|
+
props.resize !== false && Resize.off(instance.vnode.el, handleResize);
|
|
44181
|
+
poper?.destroy?.();
|
|
44182
|
+
});
|
|
44183
|
+
const Content = props.tag;
|
|
44184
|
+
return () => {
|
|
44185
|
+
return vue.createVNode(Content, {
|
|
44186
|
+
"class": "vc-text",
|
|
44187
|
+
"style": styles.value,
|
|
44188
|
+
"onMouseover": handleMouseOver,
|
|
44189
|
+
"onMouseout": handleMouseOut
|
|
44190
|
+
}, {
|
|
44191
|
+
default: () => [isActive.value ? vue.createVNode(Customer, {
|
|
44192
|
+
"value": endIndex.value > 0 ? `${props.value.slice(0, endIndex.value)}${props.suffix}` : props.value,
|
|
44193
|
+
"index": endIndex.value,
|
|
44194
|
+
"render": props.renderRow
|
|
44195
|
+
}, null) : null]
|
|
44196
|
+
});
|
|
44197
|
+
};
|
|
44198
|
+
}
|
|
44199
|
+
});
|
|
44200
|
+
|
|
43802
44201
|
const MText = Text;
|
|
43803
44202
|
|
|
43804
44203
|
const HIDDEN_TEXTAREA_STYLE = `
|
|
@@ -132675,6 +133074,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
132675
133074
|
exports.Drawer = Drawer;
|
|
132676
133075
|
exports.DrawerView = DrawerView;
|
|
132677
133076
|
exports.Dropdown = Dropdown;
|
|
133077
|
+
exports.DropdownItem = DropdownItem;
|
|
133078
|
+
exports.DropdownMenu = DropdownMenu;
|
|
132678
133079
|
exports.Editor = Editor;
|
|
132679
133080
|
exports.Expand = Expand$1;
|
|
132680
133081
|
exports.Form = Form;
|
|
@@ -132716,6 +133117,8 @@ var VcComponents = (function (exports, vue) {
|
|
|
132716
133117
|
exports.MDrawer = MDrawer;
|
|
132717
133118
|
exports.MDrawerView = MDrawerView;
|
|
132718
133119
|
exports.MDropdown = MDropdown;
|
|
133120
|
+
exports.MDropdownItem = MDropdownItem;
|
|
133121
|
+
exports.MDropdownMenu = MDropdownMenu;
|
|
132719
133122
|
exports.MEditor = MEditor;
|
|
132720
133123
|
exports.MExpand = MExpand;
|
|
132721
133124
|
exports.MForm = MForm;
|