lew-ui 2.4.20 → 2.5.2
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/components/button/src/LewButton.vue.d.ts +1 -1
- package/dist/components/color-picker/src/LewColorPicker.vue.d.ts +17 -2
- package/dist/components/color-picker/src/props.d.ts +5 -0
- package/dist/components/desc/src/LewDesc.vue.d.ts +5 -5
- package/dist/components/desc/src/props.d.ts +9 -2
- package/dist/components/drawer/src/LewDrawer.vue.d.ts +2 -2
- package/dist/components/modal/src/LewModal.vue.d.ts +2 -2
- package/dist/components/popok/src/LewPopok.vue.d.ts +2 -2
- package/dist/components/text-trim/src/LewTextTrim.vue.d.ts +2 -2
- package/dist/components/text-trim/src/props.d.ts +1 -1
- package/dist/index.mjs +580 -382
- package/dist/index.umd.js +3 -3
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -3595,17 +3595,17 @@ const imageProps = {
|
|
|
3595
3595
|
}
|
|
3596
3596
|
}
|
|
3597
3597
|
};
|
|
3598
|
-
const _hoisted_1$
|
|
3598
|
+
const _hoisted_1$K = {
|
|
3599
3599
|
key: 0,
|
|
3600
3600
|
class: "skeletons"
|
|
3601
3601
|
};
|
|
3602
|
-
const _hoisted_2$
|
|
3602
|
+
const _hoisted_2$s = {
|
|
3603
3603
|
key: 1,
|
|
3604
3604
|
class: "lew-image-fail-icon",
|
|
3605
3605
|
src: _imports_0,
|
|
3606
3606
|
alt: "图片加载失败"
|
|
3607
3607
|
};
|
|
3608
|
-
const _hoisted_3$
|
|
3608
|
+
const _hoisted_3$l = {
|
|
3609
3609
|
key: 2,
|
|
3610
3610
|
class: "lew-image-box"
|
|
3611
3611
|
};
|
|
@@ -3655,14 +3655,14 @@ const _sfc_main$11 = /* @__PURE__ */ defineComponent({
|
|
|
3655
3655
|
style: normalizeStyle(unref(imageStyleObject))
|
|
3656
3656
|
}, {
|
|
3657
3657
|
default: withCtx(() => [
|
|
3658
|
-
unref(_loading) || _ctx.loading || !_ctx.src ? (openBlock(), createElementBlock("div", _hoisted_1$
|
|
3659
|
-
_ctx.$slots.error ? renderSlot(_ctx.$slots, "error", { key: 0 }, void 0, true) : withDirectives((openBlock(), createElementBlock("img", _hoisted_2$
|
|
3658
|
+
unref(_loading) || _ctx.loading || !_ctx.src ? (openBlock(), createElementBlock("div", _hoisted_1$K)) : unref(_error) ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
3659
|
+
_ctx.$slots.error ? renderSlot(_ctx.$slots, "error", { key: 0 }, void 0, true) : withDirectives((openBlock(), createElementBlock("img", _hoisted_2$s, null, 512)), [
|
|
3660
3660
|
[_directive_tooltip, {
|
|
3661
3661
|
content: "图片加载失败",
|
|
3662
3662
|
trigger: "mouseenter"
|
|
3663
3663
|
}]
|
|
3664
3664
|
])
|
|
3665
|
-
], 64)) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
3665
|
+
], 64)) : (openBlock(), createElementBlock("div", _hoisted_3$l, [
|
|
3666
3666
|
createElementVNode("img", {
|
|
3667
3667
|
class: "lew-image",
|
|
3668
3668
|
src: _ctx.src,
|
|
@@ -3806,27 +3806,22 @@ const avatarProps = {
|
|
|
3806
3806
|
}
|
|
3807
3807
|
}
|
|
3808
3808
|
};
|
|
3809
|
-
const _hoisted_1$
|
|
3809
|
+
const _hoisted_1$J = {
|
|
3810
3810
|
key: 0,
|
|
3811
3811
|
class: "skeletons"
|
|
3812
3812
|
};
|
|
3813
|
-
const _hoisted_2$
|
|
3813
|
+
const _hoisted_2$r = ["src", "alt"];
|
|
3814
3814
|
const errorSrc = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHgAAAB4CAYAAAA5ZDbSAAAAAXNSR0IArs4c6QAABopJREFUeAHtnd9rG0cQx+ckxVFbt7VBgSS07o84BCJaAoW8NFDogyH/R176mj+kbyUv+T8KfggU0pdAi/tDTapIiWPHsZzY8S/JliWfrjtnH1JUWb7dO61nVrNg9Gtmd/b78dzezZ5lD/raw0cLRb/l31FvzwUAMwDBZJ+JvCSlgFf3AJZUSPPZiez9WzdvlHrDU58dtVKpNLG+2fwRPPghCIJM9L488lHA87wOBHCvMJ2/WywWWxh5CDiEu9X8WYH9ns90JNKTFFCgHxSm8rcRcpipmLkC9yS5+L2PLMOjsQrdC9fctv+nHJb5gRwWMR6us+eyX+fwhCoAWXOHicXxM0xYZIuH6DmOE5CYYykwlzm6FIplLEbMFEC2KoPlOpcZN41wg8nwLFrDQ0yZKSCAmQHTDVcA6yrGzF4AMwOmG64A1lWMmb0AZgZMN1wBrKsYM3sBzAyYbrgCWFcxZvYCmBkw3XAFsK5izOwFMDNguuEKYF3FmNkLYGbAdMMVwLqKMbMXwMyA6YYrgHUVY2YvgJkB0w1XAOsqxsxeADMDphuuANZVjJm9AGYGTDdcAayrGDP7nO14v/v2G9tDkhrvl19/sxqPZLBVue0PJoDta251RAFsVW77gwlg+5pbHVEAW5Xb/mAC2L7mVkcUwFbltj+Y9etg0yk29vZhtbYOm1s70DwIvyEI8ucnYHrqI7h0sQAfvP+eaddO+5EH3Ol0oPr8JbyqvfkfiL39JuDPyupruHzxAlz54hPIZOSg1CsUaTUQ7l//VAbC7Z0EPsdfALRFH2ldBUgDxszd2t7tRnvKM7RFH2ldBcgCxjV30GG5G/rgZ+iDvtKOFCALGE+oTFsSX9MxqfqRBYxny6Ytia/pmFT9yAKOLoVMhEviazIeZR+ygCmLxik2soCxiGHakviajknVjyxgrFCZtiS+pmNS9SMLGMuPpi2Jr+mYVP3IAsbaMpYfdRv6SF26qxpZwBgi1panPv6wG+0pz9AWfaR1FSANGDcOvro+GyuTMXPRNo3NBiyUvNnY7KrE+Bn53SQEdvXKDFy+dMHKduFuvQFPny3BuVwOptURIaceOTc20eO6OvvlpyPVut0+hNKTZ6C+Dh9a7TZUF1fg2uxnIx1z1J2TPkSPevK9/SPUx+XncHB8MwF+Vltb19rN6u2PynMBfEzixfJqeLdIP5h/Ky/A9/nuMQtgRXRjcxsQ8KDWbB6oz14N+ojFe2MPGAE+UYfmYW15ZQ1263vDTMh+NtaA8fYePKk6PPRPBVSuLIYnX6caEjMYa8BPq0tQb8TLzHpjHzCTubWxBbyqzpBrrze0eOFavK/u4uTUWALGSlNZnd2a3kGJ6ylmr27rdAIoKz+8pOLS2AGOKk2YgX/8XYaDVltL66NiRtUYEt65WVvTy3ytAFM2ZgW4t9KEOuzsNuD3hcewvVOPJQtmHp4x9xYzYjn2GVUXX2r/YvV1Ye0lG8CDKk2oEpYUMZPj3GKL17pvE9zMF1HxfR8qBof4yN/mIxvAJ1WaUCyEj2vqsHV5WDHDRPD1t1ssdpxYAI4L56R1OU4xwwRypbqsrqEPTVyt+ZAHrAunf13WKWboqh7tOOn62bQnDdgUTu+6rFPMMBGe+o4TacBJ4ETrsm4xwwQy5R0nsoBNKk0mcNLwobzjRBKwaaUpDVimfVDdcSIHOGmlyRRQGn4Ud5xIAU6r0pQGLJM+KO44kQKcVqXJBE5aPtR2nMgAjlvMSAvEqPqhtuNEArBuMWNUcNLql9KO05kDNi1mpAVjVP1Q2XE6c8BJihmjgpNGv1R2nM78LxuuXf0c8EfaaBQ48wwezbSk10gBARwp4eijAHYUbDQtARwp4eijAHYUbDQt62fRtv9vUDTRcX2UDHacvAAWwI4r4Pj0JIMFsOMKOD49yWAB7LgCjk9PMlgAO66A49OTDBbAjivg+PQkgwWw4wo4Pj3JYAHsuAKOT08yWAA7roDj05MMFsCOK+D49CSDBbDjCjg+PclgAey4Ao5PT2WwF++rWh0Xws3pefWMB7Dk5uRkVsgW1+B5kcJZBeYz2Ynsfc/z+P7nJ2fZJJsYMkW2mVs3b5QggHvJuhNvcgoopsg2vEwqTOfvKuIPyAUpARkpgCyRKTqHgIvFYqswlb/tgfeTHK6NNCXhhOyQIbJEphiUOtF6tz18tFD0W/4d9e6c+ucxM+oL8yfftZBXtBTw6sdXQvO45oZLbk+A/wFCn6eLV03nkQAAAABJRU5ErkJggg==";
|
|
3815
3815
|
const _sfc_main$10 = /* @__PURE__ */ defineComponent({
|
|
3816
3816
|
__name: "LewAvatar",
|
|
3817
3817
|
props: avatarProps,
|
|
3818
3818
|
setup(__props2) {
|
|
3819
3819
|
const props2 = __props2;
|
|
3820
|
-
const
|
|
3821
|
-
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
}
|
|
3825
|
-
});
|
|
3826
|
-
const avatarClassName = computed(() => {
|
|
3827
|
-
return object2class("lew-avatar", {
|
|
3828
|
-
round: props2.shape === "circle"
|
|
3829
|
-
});
|
|
3820
|
+
const avatarBoxStyleObject = computed(() => {
|
|
3821
|
+
const { shape } = props2;
|
|
3822
|
+
return {
|
|
3823
|
+
borderRadius: shape === "circle" ? "50%" : "0px"
|
|
3824
|
+
};
|
|
3830
3825
|
});
|
|
3831
3826
|
const avatarStyleObject = computed(() => {
|
|
3832
3827
|
return {
|
|
@@ -3840,6 +3835,53 @@ const _sfc_main$10 = /* @__PURE__ */ defineComponent({
|
|
|
3840
3835
|
objectPosition: props2.objectPosition
|
|
3841
3836
|
};
|
|
3842
3837
|
});
|
|
3838
|
+
const STATUS_PLACEMENT_CONFIG = {
|
|
3839
|
+
"top-left": {
|
|
3840
|
+
top: "-0.25rem",
|
|
3841
|
+
left: "-0.25rem",
|
|
3842
|
+
bottom: "auto",
|
|
3843
|
+
right: "auto"
|
|
3844
|
+
},
|
|
3845
|
+
"top-right": {
|
|
3846
|
+
top: "-0.25rem",
|
|
3847
|
+
left: "auto",
|
|
3848
|
+
bottom: "auto",
|
|
3849
|
+
right: "-0.25rem"
|
|
3850
|
+
},
|
|
3851
|
+
"bottom-left": {
|
|
3852
|
+
top: "auto",
|
|
3853
|
+
left: "-0.25rem",
|
|
3854
|
+
bottom: "-0.25rem",
|
|
3855
|
+
right: "auto"
|
|
3856
|
+
},
|
|
3857
|
+
"bottom-right": {
|
|
3858
|
+
top: "auto",
|
|
3859
|
+
left: "auto",
|
|
3860
|
+
bottom: "-0.25rem",
|
|
3861
|
+
right: "-0.25rem"
|
|
3862
|
+
}
|
|
3863
|
+
};
|
|
3864
|
+
const STATUS_COLOR_CONFIG = {
|
|
3865
|
+
online: "var(--lew-color-success)",
|
|
3866
|
+
busy: "var(--lew-color-error)",
|
|
3867
|
+
offline: "var(--lew-color-normal-dark)",
|
|
3868
|
+
processing: "var(--lew-color-info)",
|
|
3869
|
+
away: "var(--lew-color-warning)"
|
|
3870
|
+
};
|
|
3871
|
+
const dotStyleObject = computed(() => {
|
|
3872
|
+
const { status, statusPlacement } = props2;
|
|
3873
|
+
return {
|
|
3874
|
+
...STATUS_PLACEMENT_CONFIG[statusPlacement] || {},
|
|
3875
|
+
backgroundColor: status ? STATUS_COLOR_CONFIG[status] : "",
|
|
3876
|
+
position: "absolute",
|
|
3877
|
+
content: "",
|
|
3878
|
+
width: "0.6rem",
|
|
3879
|
+
height: "0.6rem",
|
|
3880
|
+
borderRadius: "50%",
|
|
3881
|
+
zIndex: 9,
|
|
3882
|
+
border: "var(--lew-form-border-width) var(--lew-color-white) solid"
|
|
3883
|
+
};
|
|
3884
|
+
});
|
|
3843
3885
|
let _loading = ref();
|
|
3844
3886
|
let _error = ref();
|
|
3845
3887
|
const init = () => {
|
|
@@ -3866,9 +3908,10 @@ const _sfc_main$10 = /* @__PURE__ */ defineComponent({
|
|
|
3866
3908
|
style: normalizeStyle(unref(avatarStyleObject))
|
|
3867
3909
|
}, [
|
|
3868
3910
|
createElementVNode("div", {
|
|
3869
|
-
class:
|
|
3911
|
+
class: "lew-avatar-box",
|
|
3912
|
+
style: normalizeStyle(unref(avatarBoxStyleObject))
|
|
3870
3913
|
}, [
|
|
3871
|
-
unref(_loading) || _ctx.loading || !_ctx.src ? (openBlock(), createElementBlock("div", _hoisted_1$
|
|
3914
|
+
unref(_loading) || _ctx.loading || !_ctx.src ? (openBlock(), createElementBlock("div", _hoisted_1$J)) : unref(_error) ? (openBlock(), createElementBlock("img", {
|
|
3872
3915
|
key: 1,
|
|
3873
3916
|
src: errorSrc,
|
|
3874
3917
|
alt: "",
|
|
@@ -3880,17 +3923,17 @@ const _sfc_main$10 = /* @__PURE__ */ defineComponent({
|
|
|
3880
3923
|
alt: _ctx.alt,
|
|
3881
3924
|
lazy: "",
|
|
3882
3925
|
style: normalizeStyle(unref(imageStyleObject))
|
|
3883
|
-
}, null, 12, _hoisted_2$
|
|
3884
|
-
],
|
|
3885
|
-
_ctx.status ? (openBlock(), createElementBlock("
|
|
3926
|
+
}, null, 12, _hoisted_2$r)) : createCommentVNode("", true)
|
|
3927
|
+
], 4),
|
|
3928
|
+
_ctx.status ? (openBlock(), createElementBlock("i", {
|
|
3886
3929
|
key: 0,
|
|
3887
|
-
|
|
3888
|
-
}, null,
|
|
3930
|
+
style: normalizeStyle(unref(dotStyleObject))
|
|
3931
|
+
}, null, 4)) : createCommentVNode("", true)
|
|
3889
3932
|
], 4);
|
|
3890
3933
|
};
|
|
3891
3934
|
}
|
|
3892
3935
|
});
|
|
3893
|
-
const LewAvatar = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["__scopeId", "data-v-
|
|
3936
|
+
const LewAvatar = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["__scopeId", "data-v-3990fb5c"]]);
|
|
3894
3937
|
const validColors = [
|
|
3895
3938
|
"blue",
|
|
3896
3939
|
"gray",
|
|
@@ -4012,12 +4055,12 @@ const buttonProps = {
|
|
|
4012
4055
|
description: "点击按钮时触发的异步请求函数"
|
|
4013
4056
|
}
|
|
4014
4057
|
};
|
|
4015
|
-
const _hoisted_1$
|
|
4016
|
-
const _hoisted_2$
|
|
4058
|
+
const _hoisted_1$I = ["disabled"];
|
|
4059
|
+
const _hoisted_2$q = {
|
|
4017
4060
|
key: 0,
|
|
4018
4061
|
class: "lew-button-content"
|
|
4019
4062
|
};
|
|
4020
|
-
const _hoisted_3$
|
|
4063
|
+
const _hoisted_3$k = { class: "lew-button-text" };
|
|
4021
4064
|
const _sfc_main$$ = /* @__PURE__ */ defineComponent({
|
|
4022
4065
|
__name: "LewButton",
|
|
4023
4066
|
props: buttonProps,
|
|
@@ -4078,30 +4121,33 @@ const _sfc_main$$ = /* @__PURE__ */ defineComponent({
|
|
|
4078
4121
|
const { round: round2, type, color, dashed } = props2;
|
|
4079
4122
|
const styleObj = {};
|
|
4080
4123
|
const _color = getColorType(color) || "primary";
|
|
4081
|
-
|
|
4082
|
-
|
|
4083
|
-
|
|
4084
|
-
|
|
4085
|
-
|
|
4086
|
-
|
|
4087
|
-
|
|
4088
|
-
|
|
4089
|
-
|
|
4090
|
-
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
|
|
4094
|
-
|
|
4095
|
-
|
|
4096
|
-
|
|
4097
|
-
|
|
4098
|
-
|
|
4099
|
-
|
|
4100
|
-
|
|
4101
|
-
|
|
4102
|
-
|
|
4103
|
-
|
|
4104
|
-
|
|
4124
|
+
const baseStyle = {
|
|
4125
|
+
fill: {
|
|
4126
|
+
backgroundColor: `var(--lew-color-${_color})`,
|
|
4127
|
+
color: "var(--lew-color-white)"
|
|
4128
|
+
},
|
|
4129
|
+
light: {
|
|
4130
|
+
backgroundColor: `var(--lew-color-${_color}-light)`,
|
|
4131
|
+
color: `var(--lew-color-${_color}-dark)`
|
|
4132
|
+
},
|
|
4133
|
+
ghost: {
|
|
4134
|
+
backgroundColor: "transparent",
|
|
4135
|
+
border: `var(--lew-form-border-width) ${dashed ? "dashed" : "solid"} var(--lew-color-${_color}-dark)`,
|
|
4136
|
+
color: `var(--lew-color-${_color}-dark)`,
|
|
4137
|
+
boxShadow: "none"
|
|
4138
|
+
},
|
|
4139
|
+
text: {
|
|
4140
|
+
backgroundColor: "transparent",
|
|
4141
|
+
color: `var(--lew-color-${_color}-dark)`,
|
|
4142
|
+
boxShadow: "none"
|
|
4143
|
+
}
|
|
4144
|
+
};
|
|
4145
|
+
Object.assign(
|
|
4146
|
+
styleObj,
|
|
4147
|
+
baseStyle[type] || {
|
|
4148
|
+
backgroundColor: `var(--lew-color-${_color})`
|
|
4149
|
+
}
|
|
4150
|
+
);
|
|
4105
4151
|
styleObj.borderRadius = round2 ? "50px" : "none";
|
|
4106
4152
|
return styleObj;
|
|
4107
4153
|
});
|
|
@@ -4126,18 +4172,18 @@ const _sfc_main$$ = /* @__PURE__ */ defineComponent({
|
|
|
4126
4172
|
type: "loader"
|
|
4127
4173
|
}, null, 8, ["size"])
|
|
4128
4174
|
], 2),
|
|
4129
|
-
_ctx.$slots.default || _ctx.text ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
4130
|
-
createElementVNode("span", _hoisted_3$
|
|
4175
|
+
_ctx.$slots.default || _ctx.text ? (openBlock(), createElementBlock("div", _hoisted_2$q, [
|
|
4176
|
+
createElementVNode("span", _hoisted_3$k, [
|
|
4131
4177
|
_ctx.$slots.default ? renderSlot(_ctx.$slots, "default", { key: 0 }, void 0, true) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
4132
4178
|
createTextVNode(toDisplayString(_ctx.text), 1)
|
|
4133
4179
|
], 64))
|
|
4134
4180
|
])
|
|
4135
4181
|
])) : createCommentVNode("", true)
|
|
4136
|
-
], 14, _hoisted_1$
|
|
4182
|
+
], 14, _hoisted_1$I);
|
|
4137
4183
|
};
|
|
4138
4184
|
}
|
|
4139
4185
|
});
|
|
4140
|
-
const LewButton = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["__scopeId", "data-v-
|
|
4186
|
+
const LewButton = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["__scopeId", "data-v-45a88edc"]]);
|
|
4141
4187
|
const tagProps = {
|
|
4142
4188
|
text: {
|
|
4143
4189
|
type: String,
|
|
@@ -4203,9 +4249,10 @@ const tagProps = {
|
|
|
4203
4249
|
description: "是否禁用标签"
|
|
4204
4250
|
}
|
|
4205
4251
|
};
|
|
4206
|
-
const _hoisted_1$
|
|
4207
|
-
|
|
4208
|
-
|
|
4252
|
+
const _hoisted_1$H = {
|
|
4253
|
+
key: 1,
|
|
4254
|
+
class: "lew-tag-right"
|
|
4255
|
+
};
|
|
4209
4256
|
const _sfc_main$_ = /* @__PURE__ */ defineComponent({
|
|
4210
4257
|
__name: "LewTag",
|
|
4211
4258
|
props: tagProps,
|
|
@@ -4213,64 +4260,93 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent({
|
|
|
4213
4260
|
setup(__props2, { emit: __emit2 }) {
|
|
4214
4261
|
const props2 = __props2;
|
|
4215
4262
|
const emit2 = __emit2;
|
|
4263
|
+
const SIZE_CONFIG = {
|
|
4264
|
+
small: {
|
|
4265
|
+
height: "20px",
|
|
4266
|
+
minWidth: "20px",
|
|
4267
|
+
fontSize: "11px",
|
|
4268
|
+
borderRadius: "5px",
|
|
4269
|
+
padding: "0px 2px",
|
|
4270
|
+
closeIconSize: 12,
|
|
4271
|
+
closeMargin: "-2px 4px -2px -2px",
|
|
4272
|
+
contentPadding: "0px 3px",
|
|
4273
|
+
leftMargin: "4px"
|
|
4274
|
+
},
|
|
4275
|
+
medium: {
|
|
4276
|
+
height: "24px",
|
|
4277
|
+
minWidth: "24px",
|
|
4278
|
+
fontSize: "13px",
|
|
4279
|
+
borderRadius: "6px",
|
|
4280
|
+
padding: "0px 2px",
|
|
4281
|
+
closeIconSize: 14,
|
|
4282
|
+
closeMargin: "-3px 2px -3px -3px",
|
|
4283
|
+
contentPadding: "0px 4px",
|
|
4284
|
+
leftMargin: "4px"
|
|
4285
|
+
},
|
|
4286
|
+
large: {
|
|
4287
|
+
height: "28px",
|
|
4288
|
+
minWidth: "28px",
|
|
4289
|
+
fontSize: "15px",
|
|
4290
|
+
borderRadius: "8px",
|
|
4291
|
+
padding: "0px 6px",
|
|
4292
|
+
closeIconSize: 16,
|
|
4293
|
+
closeMargin: "-4px 0 -4px -4px",
|
|
4294
|
+
contentPadding: "0px 5px",
|
|
4295
|
+
leftMargin: "4px"
|
|
4296
|
+
}
|
|
4297
|
+
};
|
|
4298
|
+
const TYPE_STYLES = {
|
|
4299
|
+
fill: (color) => ({
|
|
4300
|
+
backgroundColor: `var(--lew-color-${color})`,
|
|
4301
|
+
color: "var(--lew-color-white)"
|
|
4302
|
+
}),
|
|
4303
|
+
light: (color) => ({
|
|
4304
|
+
backgroundColor: `var(--lew-color-${color}-light)`,
|
|
4305
|
+
color: `var(--lew-color-${color}-dark)`
|
|
4306
|
+
}),
|
|
4307
|
+
ghost: (color) => ({
|
|
4308
|
+
backgroundColor: "transparent",
|
|
4309
|
+
border: `1px solid var(--lew-color-${color}-dark)`,
|
|
4310
|
+
color: `var(--lew-color-${color}-dark)`,
|
|
4311
|
+
boxShadow: "none"
|
|
4312
|
+
}),
|
|
4313
|
+
default: (color) => ({
|
|
4314
|
+
backgroundColor: `var(--lew-color-${color})`,
|
|
4315
|
+
color: "var(--lew-color-white)"
|
|
4316
|
+
})
|
|
4317
|
+
};
|
|
4216
4318
|
const close = () => {
|
|
4217
|
-
if (props2.disabled)
|
|
4218
|
-
return;
|
|
4219
|
-
}
|
|
4319
|
+
if (props2.disabled) return;
|
|
4220
4320
|
emit2("close");
|
|
4221
4321
|
};
|
|
4222
|
-
const
|
|
4223
|
-
|
|
4224
|
-
case "small":
|
|
4225
|
-
return 12;
|
|
4226
|
-
case "medium":
|
|
4227
|
-
return 14;
|
|
4228
|
-
case "large":
|
|
4229
|
-
return 16;
|
|
4230
|
-
default:
|
|
4231
|
-
return 14;
|
|
4232
|
-
}
|
|
4233
|
-
});
|
|
4234
|
-
const tagClassName = computed(() => {
|
|
4235
|
-
const { size, disabled, color, type } = props2;
|
|
4236
|
-
return object2class("lew-tag", { size, color, disabled, type });
|
|
4237
|
-
});
|
|
4238
|
-
const getStyle = computed(() => {
|
|
4239
|
-
const { round: round2, type, color } = props2;
|
|
4240
|
-
const styleObj = {};
|
|
4322
|
+
const tagStyle = computed(() => {
|
|
4323
|
+
const { round: round2, type, color, size, disabled } = props2;
|
|
4241
4324
|
const _color = getColorType(color) || "primary";
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
|
|
4247
|
-
|
|
4248
|
-
|
|
4249
|
-
|
|
4250
|
-
break;
|
|
4251
|
-
case "ghost":
|
|
4252
|
-
styleObj.backgroundColor = "transparent";
|
|
4253
|
-
styleObj.border = `1px solid var(--lew-color-${_color}-dark)`;
|
|
4254
|
-
styleObj.color = `var(--lew-color-${_color}-dark)`;
|
|
4255
|
-
styleObj.boxShadow = "none";
|
|
4256
|
-
break;
|
|
4257
|
-
default:
|
|
4258
|
-
styleObj.color = "var(--lew-color-white)";
|
|
4259
|
-
styleObj.backgroundColor = `var(--lew-color-${_color})`;
|
|
4260
|
-
break;
|
|
4261
|
-
}
|
|
4262
|
-
styleObj.borderRadius = round2 ? "20px" : "none";
|
|
4263
|
-
return styleObj;
|
|
4325
|
+
const sizeConfig = SIZE_CONFIG[size] || SIZE_CONFIG.medium;
|
|
4326
|
+
return {
|
|
4327
|
+
...(TYPE_STYLES[type] || TYPE_STYLES.default)(_color),
|
|
4328
|
+
...sizeConfig,
|
|
4329
|
+
borderRadius: round2 ? "20px" : sizeConfig.borderRadius,
|
|
4330
|
+
opacity: disabled ? "var(--lew-disabled-opacity)" : void 0,
|
|
4331
|
+
pointerEvents: disabled ? "none" : "auto"
|
|
4332
|
+
};
|
|
4264
4333
|
});
|
|
4265
4334
|
return (_ctx, _cache) => {
|
|
4266
4335
|
return openBlock(), createElementBlock("div", {
|
|
4267
|
-
class:
|
|
4268
|
-
style: normalizeStyle(unref(
|
|
4336
|
+
class: "lew-tag",
|
|
4337
|
+
style: normalizeStyle(unref(tagStyle))
|
|
4269
4338
|
}, [
|
|
4270
|
-
|
|
4339
|
+
_ctx.$slots.left ? (openBlock(), createElementBlock("div", {
|
|
4340
|
+
key: 0,
|
|
4341
|
+
class: "lew-tag-left",
|
|
4342
|
+
style: normalizeStyle({ marginLeft: unref(tagStyle).leftMargin })
|
|
4343
|
+
}, [
|
|
4271
4344
|
renderSlot(_ctx.$slots, "left")
|
|
4272
|
-
]),
|
|
4273
|
-
createElementVNode("div",
|
|
4345
|
+
], 4)) : createCommentVNode("", true),
|
|
4346
|
+
createElementVNode("div", {
|
|
4347
|
+
class: "lew-tag-value",
|
|
4348
|
+
style: normalizeStyle({ padding: unref(tagStyle).contentPadding })
|
|
4349
|
+
}, [
|
|
4274
4350
|
_ctx.text ? (openBlock(), createBlock(unref(LewTextTrim), {
|
|
4275
4351
|
key: 0,
|
|
4276
4352
|
text: _ctx.text
|
|
@@ -4280,21 +4356,22 @@ const _sfc_main$_ = /* @__PURE__ */ defineComponent({
|
|
|
4280
4356
|
]),
|
|
4281
4357
|
_: 3
|
|
4282
4358
|
}))
|
|
4283
|
-
]),
|
|
4284
|
-
|
|
4359
|
+
], 4),
|
|
4360
|
+
_ctx.$slots.right ? (openBlock(), createElementBlock("div", _hoisted_1$H, [
|
|
4285
4361
|
renderSlot(_ctx.$slots, "right")
|
|
4286
|
-
]),
|
|
4362
|
+
])) : createCommentVNode("", true),
|
|
4287
4363
|
_ctx.closable ? (openBlock(), createElementBlock("div", {
|
|
4288
|
-
key:
|
|
4364
|
+
key: 2,
|
|
4289
4365
|
class: "lew-tag-close",
|
|
4366
|
+
style: normalizeStyle({ margin: unref(tagStyle).closeMargin }),
|
|
4290
4367
|
onClick: withModifiers(close, ["stop"])
|
|
4291
4368
|
}, [
|
|
4292
4369
|
createVNode(Icon, {
|
|
4293
|
-
size: unref(
|
|
4370
|
+
size: unref(tagStyle).closeIconSize,
|
|
4294
4371
|
type: "close"
|
|
4295
4372
|
}, null, 8, ["size"])
|
|
4296
|
-
])) : createCommentVNode("", true)
|
|
4297
|
-
],
|
|
4373
|
+
], 4)) : createCommentVNode("", true)
|
|
4374
|
+
], 4);
|
|
4298
4375
|
};
|
|
4299
4376
|
}
|
|
4300
4377
|
});
|
|
@@ -4326,7 +4403,7 @@ const badgeProps = {
|
|
|
4326
4403
|
}
|
|
4327
4404
|
}
|
|
4328
4405
|
};
|
|
4329
|
-
const _hoisted_1$
|
|
4406
|
+
const _hoisted_1$G = { class: "lew-badge" };
|
|
4330
4407
|
const _sfc_main$Z = /* @__PURE__ */ defineComponent({
|
|
4331
4408
|
__name: "LewBadge",
|
|
4332
4409
|
props: badgeProps,
|
|
@@ -4340,7 +4417,7 @@ const _sfc_main$Z = /* @__PURE__ */ defineComponent({
|
|
|
4340
4417
|
return styleObj;
|
|
4341
4418
|
});
|
|
4342
4419
|
return (_ctx, _cache) => {
|
|
4343
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
4420
|
+
return openBlock(), createElementBlock("div", _hoisted_1$G, [
|
|
4344
4421
|
_ctx.value ? (openBlock(), createElementBlock("div", {
|
|
4345
4422
|
key: 0,
|
|
4346
4423
|
class: "lew-badge-value",
|
|
@@ -7138,7 +7215,7 @@ const textTrimProps = {
|
|
|
7138
7215
|
},
|
|
7139
7216
|
delay: {
|
|
7140
7217
|
type: Array,
|
|
7141
|
-
default:
|
|
7218
|
+
default: [120, 120],
|
|
7142
7219
|
description: "显示和隐藏提示框的延迟时间 [显示延迟, 隐藏延迟](单位:毫秒)",
|
|
7143
7220
|
validator(value) {
|
|
7144
7221
|
if (!Array.isArray(value) || value.length !== 2 || !value.every((item) => typeof item === "number" && item >= 0)) {
|
|
@@ -7726,14 +7803,14 @@ const stepsProps = {
|
|
|
7726
7803
|
}
|
|
7727
7804
|
}
|
|
7728
7805
|
};
|
|
7729
|
-
const _hoisted_1$
|
|
7806
|
+
const _hoisted_1$F = { class: "lew-steps lew-scrollbar" };
|
|
7730
7807
|
const _hoisted_2$p = { class: "lew-steps-item-index" };
|
|
7731
7808
|
const _hoisted_3$j = {
|
|
7732
7809
|
key: 4,
|
|
7733
7810
|
class: "index"
|
|
7734
7811
|
};
|
|
7735
7812
|
const _hoisted_4$e = { class: "lew-steps-item-info" };
|
|
7736
|
-
const _hoisted_5$
|
|
7813
|
+
const _hoisted_5$8 = { class: "lew-steps-item-title" };
|
|
7737
7814
|
const _hoisted_6$6 = { class: "lew-steps-item-description" };
|
|
7738
7815
|
const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
7739
7816
|
__name: "LewSteps",
|
|
@@ -7745,7 +7822,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
7745
7822
|
setup(__props2) {
|
|
7746
7823
|
const stepsValue = useModel(__props2, "modelValue");
|
|
7747
7824
|
return (_ctx, _cache) => {
|
|
7748
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
7825
|
+
return openBlock(), createElementBlock("div", _hoisted_1$F, [
|
|
7749
7826
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.options, (item, index2) => {
|
|
7750
7827
|
return openBlock(), createElementBlock("div", {
|
|
7751
7828
|
key: index2,
|
|
@@ -7783,7 +7860,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
7783
7860
|
})) : (openBlock(), createElementBlock("span", _hoisted_3$j, toDisplayString(index2 + 1), 1))
|
|
7784
7861
|
]),
|
|
7785
7862
|
createElementVNode("div", _hoisted_4$e, [
|
|
7786
|
-
createElementVNode("div", _hoisted_5$
|
|
7863
|
+
createElementVNode("div", _hoisted_5$8, [
|
|
7787
7864
|
createVNode(unref(LewTextTrim), {
|
|
7788
7865
|
placement: "bottom",
|
|
7789
7866
|
text: item.title
|
|
@@ -7833,7 +7910,7 @@ const menuProps = {
|
|
|
7833
7910
|
}
|
|
7834
7911
|
}
|
|
7835
7912
|
};
|
|
7836
|
-
const _hoisted_1$
|
|
7913
|
+
const _hoisted_1$E = { class: "lew-menu" };
|
|
7837
7914
|
const _hoisted_2$o = { class: "lew-menu-item" };
|
|
7838
7915
|
const _hoisted_3$i = ["onClick"];
|
|
7839
7916
|
const _sfc_main$R = /* @__PURE__ */ defineComponent({
|
|
@@ -7851,7 +7928,7 @@ const _sfc_main$R = /* @__PURE__ */ defineComponent({
|
|
|
7851
7928
|
emit2("change", item);
|
|
7852
7929
|
};
|
|
7853
7930
|
return (_ctx, _cache) => {
|
|
7854
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
7931
|
+
return openBlock(), createElementBlock("div", _hoisted_1$E, [
|
|
7855
7932
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.options, (item) => {
|
|
7856
7933
|
return openBlock(), createElementBlock(Fragment, {
|
|
7857
7934
|
key: item.label
|
|
@@ -7910,7 +7987,7 @@ const _sfc_main$R = /* @__PURE__ */ defineComponent({
|
|
|
7910
7987
|
};
|
|
7911
7988
|
}
|
|
7912
7989
|
});
|
|
7913
|
-
const LewMenu = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["__scopeId", "data-v-
|
|
7990
|
+
const LewMenu = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["__scopeId", "data-v-93729b05"]]);
|
|
7914
7991
|
const menuTreeModel = {
|
|
7915
7992
|
modelValue: {
|
|
7916
7993
|
type: String,
|
|
@@ -8001,7 +8078,7 @@ const menuTreeItemProps = {
|
|
|
8001
8078
|
description: "是否为叶子节点。"
|
|
8002
8079
|
}
|
|
8003
8080
|
};
|
|
8004
|
-
const _hoisted_1$
|
|
8081
|
+
const _hoisted_1$D = { class: "lew-menu-tree-item" };
|
|
8005
8082
|
const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
8006
8083
|
__name: "LewMenuTreeItem",
|
|
8007
8084
|
props: menuTreeItemProps,
|
|
@@ -8032,7 +8109,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
8032
8109
|
return (_ctx, _cache) => {
|
|
8033
8110
|
var _a;
|
|
8034
8111
|
const _component_lew_text_trim = resolveComponent("lew-text-trim");
|
|
8035
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
8112
|
+
return openBlock(), createElementBlock("div", _hoisted_1$D, [
|
|
8036
8113
|
createVNode(unref(LewFlex), {
|
|
8037
8114
|
x: "start",
|
|
8038
8115
|
y: "center",
|
|
@@ -8046,7 +8123,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
8046
8123
|
"lew-menu-tree-item-label-collapsed": unref(collapsed)
|
|
8047
8124
|
}]),
|
|
8048
8125
|
style: normalizeStyle({
|
|
8049
|
-
paddingLeft: unref(collapsed) ? "0px" : _ctx.renderIcon() ? "
|
|
8126
|
+
paddingLeft: unref(collapsed) ? "0px" : _ctx.renderIcon() ? "36px" : "15px"
|
|
8050
8127
|
}),
|
|
8051
8128
|
onClick: withModifiers(change2, ["stop"])
|
|
8052
8129
|
}, {
|
|
@@ -8095,7 +8172,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
8095
8172
|
};
|
|
8096
8173
|
}
|
|
8097
8174
|
});
|
|
8098
|
-
const LewMenuTreeItem = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["__scopeId", "data-v-
|
|
8175
|
+
const LewMenuTreeItem = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["__scopeId", "data-v-b1217566"]]);
|
|
8099
8176
|
const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
8100
8177
|
__name: "LewMenuTree",
|
|
8101
8178
|
props: /* @__PURE__ */ mergeModels(menuTreeProps, {
|
|
@@ -8135,7 +8212,7 @@ const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
|
8135
8212
|
modelValueKeyPath: getModelValueKeyPath
|
|
8136
8213
|
});
|
|
8137
8214
|
const menuTreeStyle = computed(() => ({
|
|
8138
|
-
width: collapsed.value ? any2px(
|
|
8215
|
+
width: collapsed.value ? any2px(44) : any2px(props2.width)
|
|
8139
8216
|
}));
|
|
8140
8217
|
const hoverMenu = resolveDirective("hover-menu");
|
|
8141
8218
|
const transformTree = (tree) => {
|
|
@@ -8218,7 +8295,7 @@ const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
|
8218
8295
|
};
|
|
8219
8296
|
}
|
|
8220
8297
|
});
|
|
8221
|
-
const LewMenuTree = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["__scopeId", "data-v-
|
|
8298
|
+
const LewMenuTree = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["__scopeId", "data-v-9c3463ba"]]);
|
|
8222
8299
|
const dropdownProps = {
|
|
8223
8300
|
trigger: {
|
|
8224
8301
|
type: String,
|
|
@@ -8367,7 +8444,7 @@ const breadcrumbProps = {
|
|
|
8367
8444
|
}
|
|
8368
8445
|
}
|
|
8369
8446
|
};
|
|
8370
|
-
const _hoisted_1$
|
|
8447
|
+
const _hoisted_1$C = { class: "lew-breadcrumb" };
|
|
8371
8448
|
const _hoisted_2$n = ["onClick"];
|
|
8372
8449
|
const _hoisted_3$h = {
|
|
8373
8450
|
key: 0,
|
|
@@ -8383,7 +8460,7 @@ const _hoisted_4$d = {
|
|
|
8383
8460
|
"stroke-linecap": "butt",
|
|
8384
8461
|
"stroke-linejoin": "miter"
|
|
8385
8462
|
};
|
|
8386
|
-
const _hoisted_5$
|
|
8463
|
+
const _hoisted_5$7 = {
|
|
8387
8464
|
key: 1,
|
|
8388
8465
|
viewBox: "0 0 48 48",
|
|
8389
8466
|
fill: "none",
|
|
@@ -8400,7 +8477,7 @@ const _sfc_main$N = /* @__PURE__ */ defineComponent({
|
|
|
8400
8477
|
setup(__props2, { emit: __emit2 }) {
|
|
8401
8478
|
const emit2 = __emit2;
|
|
8402
8479
|
return (_ctx, _cache) => {
|
|
8403
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
8480
|
+
return openBlock(), createElementBlock("div", _hoisted_1$C, [
|
|
8404
8481
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.options, (item, index2) => {
|
|
8405
8482
|
return openBlock(), createElementBlock("div", {
|
|
8406
8483
|
key: index2,
|
|
@@ -8414,7 +8491,7 @@ const _sfc_main$N = /* @__PURE__ */ defineComponent({
|
|
|
8414
8491
|
_ctx.iconType === "sprit" ? (openBlock(), createElementBlock("svg", _hoisted_4$d, _cache[0] || (_cache[0] = [
|
|
8415
8492
|
createElementVNode("path", { d: "M29.506 6.502 18.493 41.498" }, null, -1)
|
|
8416
8493
|
]))) : createCommentVNode("", true),
|
|
8417
|
-
_ctx.iconType === "shoulder" ? (openBlock(), createElementBlock("svg", _hoisted_5$
|
|
8494
|
+
_ctx.iconType === "shoulder" ? (openBlock(), createElementBlock("svg", _hoisted_5$7, _cache[1] || (_cache[1] = [
|
|
8418
8495
|
createElementVNode("path", { d: "m16 39.513 15.556-15.557L16 8.4" }, null, -1)
|
|
8419
8496
|
]))) : createCommentVNode("", true)
|
|
8420
8497
|
])) : createCommentVNode("", true)
|
|
@@ -8425,7 +8502,7 @@ const _sfc_main$N = /* @__PURE__ */ defineComponent({
|
|
|
8425
8502
|
}
|
|
8426
8503
|
});
|
|
8427
8504
|
const LewBreadcrumb = /* @__PURE__ */ _export_sfc(_sfc_main$N, [["__scopeId", "data-v-8735f131"]]);
|
|
8428
|
-
const _hoisted_1$
|
|
8505
|
+
const _hoisted_1$B = ["width", "height"];
|
|
8429
8506
|
const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
8430
8507
|
__name: "RequiredIcon",
|
|
8431
8508
|
props: {
|
|
@@ -8451,7 +8528,7 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
|
8451
8528
|
fill: "#DF3F52",
|
|
8452
8529
|
"p-id": "10883"
|
|
8453
8530
|
}, null, -1)
|
|
8454
|
-
]), 8, _hoisted_1$
|
|
8531
|
+
]), 8, _hoisted_1$B);
|
|
8455
8532
|
};
|
|
8456
8533
|
}
|
|
8457
8534
|
});
|
|
@@ -11051,7 +11128,7 @@ class ArraySchema extends Schema {
|
|
|
11051
11128
|
}
|
|
11052
11129
|
}
|
|
11053
11130
|
create$2.prototype = ArraySchema.prototype;
|
|
11054
|
-
const _hoisted_1$
|
|
11131
|
+
const _hoisted_1$A = {
|
|
11055
11132
|
key: 0,
|
|
11056
11133
|
class: "lew-label-box"
|
|
11057
11134
|
};
|
|
@@ -11084,7 +11161,8 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
11084
11161
|
upload: LewUpload,
|
|
11085
11162
|
"input-number": LewInputNumber,
|
|
11086
11163
|
slider: LewSlider,
|
|
11087
|
-
"slider-range": LewSliderRange
|
|
11164
|
+
"slider-range": LewSliderRange,
|
|
11165
|
+
"color-picker": LewColorPicker
|
|
11088
11166
|
};
|
|
11089
11167
|
const app = (_a = getCurrentInstance()) == null ? void 0 : _a.appContext.app;
|
|
11090
11168
|
if (app && !app.directive("tooltip")) {
|
|
@@ -11176,23 +11254,31 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
11176
11254
|
if (!required) return ((_a2 = _rule == null ? void 0 : _rule.spec) == null ? void 0 : _a2.optional) === false;
|
|
11177
11255
|
return required;
|
|
11178
11256
|
});
|
|
11257
|
+
const getFormItemMainStyle = computed(() => {
|
|
11258
|
+
if (!formItemRef.value) return {};
|
|
11259
|
+
const { direction, labelWidth, between } = props;
|
|
11260
|
+
const { offsetWidth } = formItemRef.value;
|
|
11261
|
+
return {
|
|
11262
|
+
width: direction === "x" ? `calc(${offsetWidth}px - ${any2px(labelWidth)} - 10px)` : "100%",
|
|
11263
|
+
justifyContent: direction === "x" && between ? "flex-end" : "flex-start"
|
|
11264
|
+
};
|
|
11265
|
+
});
|
|
11179
11266
|
__expose({ validate, setError, curRule });
|
|
11180
11267
|
return (_ctx, _cache) => {
|
|
11181
|
-
var _a2;
|
|
11182
11268
|
const _directive_tooltip = resolveDirective("tooltip");
|
|
11183
11269
|
return openBlock(), createElementBlock("div", {
|
|
11184
11270
|
class: normalizeClass(["lew-form-item", unref(getFormItemClassNames)]),
|
|
11185
11271
|
ref_key: "formItemRef",
|
|
11186
11272
|
ref: formItemRef,
|
|
11187
11273
|
style: normalizeStyle({
|
|
11188
|
-
"grid-area": _ctx.gridArea
|
|
11274
|
+
"grid-area": _ctx.gridArea
|
|
11189
11275
|
})
|
|
11190
11276
|
}, [
|
|
11191
11277
|
createElementVNode("div", {
|
|
11192
11278
|
style: normalizeStyle(_ctx.direction === "x" ? `width:${unref(any2px)(_ctx.labelWidth)}` : ""),
|
|
11193
11279
|
class: "lew-label-box-wrapper"
|
|
11194
11280
|
}, [
|
|
11195
|
-
_ctx.as ? (openBlock(), createElementBlock("div", _hoisted_1$
|
|
11281
|
+
_ctx.as ? (openBlock(), createElementBlock("div", _hoisted_1$A, [
|
|
11196
11282
|
unref(curRequired) && _ctx.label ? (openBlock(), createBlock(_sfc_main$M, {
|
|
11197
11283
|
key: 0,
|
|
11198
11284
|
size: unref(requiredIconSizeMap)[_ctx.size]
|
|
@@ -11213,10 +11299,7 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
11213
11299
|
], 4),
|
|
11214
11300
|
createElementVNode("div", {
|
|
11215
11301
|
class: normalizeClass(["lew-form-item-main", { "lew-form-item-error": unref(errMsg) }]),
|
|
11216
|
-
style: normalizeStyle(
|
|
11217
|
-
width: _ctx.direction === "x" ? `calc(${(_a2 = unref(formItemRef)) == null ? void 0 : _a2.offsetWidth}px - ${unref(any2px)(_ctx.labelWidth)} - 10px)` : "100%",
|
|
11218
|
-
justifyContent: _ctx.direction === "x" && _ctx.between ? "flex-end" : "flex-start"
|
|
11219
|
-
})
|
|
11302
|
+
style: normalizeStyle(unref(getFormItemMainStyle))
|
|
11220
11303
|
}, [
|
|
11221
11304
|
(openBlock(), createBlock(resolveDynamicComponent(asMap[_ctx.as]), mergeProps({
|
|
11222
11305
|
modelValue: modelValue.value,
|
|
@@ -11238,7 +11321,7 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
11238
11321
|
};
|
|
11239
11322
|
}
|
|
11240
11323
|
});
|
|
11241
|
-
const LewFormItem = /* @__PURE__ */ _export_sfc(_sfc_main$K, [["__scopeId", "data-v-
|
|
11324
|
+
const LewFormItem = /* @__PURE__ */ _export_sfc(_sfc_main$K, [["__scopeId", "data-v-b9bef2d5"]]);
|
|
11242
11325
|
const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
11243
11326
|
__name: "LewForm",
|
|
11244
11327
|
props: formProps,
|
|
@@ -11544,7 +11627,7 @@ const inputProps = {
|
|
|
11544
11627
|
description: "是否允许通过回车键确认输入"
|
|
11545
11628
|
}
|
|
11546
11629
|
};
|
|
11547
|
-
const _hoisted_1$
|
|
11630
|
+
const _hoisted_1$z = {
|
|
11548
11631
|
key: 0,
|
|
11549
11632
|
class: "lew-input-prefixes"
|
|
11550
11633
|
};
|
|
@@ -11557,7 +11640,7 @@ const _hoisted_4$c = {
|
|
|
11557
11640
|
key: 2,
|
|
11558
11641
|
class: "lew-input-prefixes-select"
|
|
11559
11642
|
};
|
|
11560
|
-
const _hoisted_5$
|
|
11643
|
+
const _hoisted_5$6 = ["disabled", "placeholder", "type", "readonly", "maxlength"];
|
|
11561
11644
|
const _hoisted_6$5 = {
|
|
11562
11645
|
key: 0,
|
|
11563
11646
|
class: "lew-input-auto-width"
|
|
@@ -11725,7 +11808,7 @@ const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
|
11725
11808
|
return openBlock(), createElementBlock("div", {
|
|
11726
11809
|
class: normalizeClass(["lew-input-view", unref(getInputClassNames)])
|
|
11727
11810
|
}, [
|
|
11728
|
-
_ctx.prefixes ? withDirectives((openBlock(), createElementBlock("div", _hoisted_1$
|
|
11811
|
+
_ctx.prefixes ? withDirectives((openBlock(), createElementBlock("div", _hoisted_1$z, [
|
|
11729
11812
|
_ctx.prefixes === "text" ? (openBlock(), createElementBlock("div", _hoisted_2$m, toDisplayString(prefixesValue.value), 1)) : createCommentVNode("", true),
|
|
11730
11813
|
_ctx.prefixes === "icon" ? (openBlock(), createElementBlock("div", _hoisted_3$g, [
|
|
11731
11814
|
createVNode(Icon, {
|
|
@@ -11804,7 +11887,7 @@ const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
|
11804
11887
|
onChange: _cache[4] || (_cache[4] = ($event) => emit2("change", modelValue2.value)),
|
|
11805
11888
|
onBlur: blur,
|
|
11806
11889
|
onFocus: focus
|
|
11807
|
-
}, null, 44, _hoisted_5$
|
|
11890
|
+
}, null, 44, _hoisted_5$6), [
|
|
11808
11891
|
[vModelDynamic, modelValue2.value]
|
|
11809
11892
|
]),
|
|
11810
11893
|
_ctx.autoWidth ? (openBlock(), createElementBlock("label", _hoisted_6$5, toDisplayString(modelValue2.value), 1)) : createCommentVNode("", true),
|
|
@@ -11905,7 +11988,7 @@ const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
|
11905
11988
|
};
|
|
11906
11989
|
}
|
|
11907
11990
|
});
|
|
11908
|
-
const LewInput = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["__scopeId", "data-v-
|
|
11991
|
+
const LewInput = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["__scopeId", "data-v-59da6657"]]);
|
|
11909
11992
|
const inputNumberModel = {
|
|
11910
11993
|
modelValue: {
|
|
11911
11994
|
type: Number,
|
|
@@ -12014,7 +12097,7 @@ const inputNumberProps = {
|
|
|
12014
12097
|
description: "聚焦时是否选中内容"
|
|
12015
12098
|
}
|
|
12016
12099
|
};
|
|
12017
|
-
const _hoisted_1$
|
|
12100
|
+
const _hoisted_1$y = ["placeholder", "min", "max", "step"];
|
|
12018
12101
|
const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
12019
12102
|
__name: "LewInputNumber",
|
|
12020
12103
|
props: /* @__PURE__ */ mergeModels(inputNumberProps, {
|
|
@@ -12070,7 +12153,13 @@ const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
|
12070
12153
|
return {
|
|
12071
12154
|
textAlign: align,
|
|
12072
12155
|
padding: `var(--lew-form-input-padding-${size})`,
|
|
12073
|
-
fontSize: `var(--lew-form-font-size-${size})
|
|
12156
|
+
fontSize: `var(--lew-form-font-size-${size})`
|
|
12157
|
+
};
|
|
12158
|
+
});
|
|
12159
|
+
const getInputNumberViewStyle = computed(() => {
|
|
12160
|
+
const { width, size } = props2;
|
|
12161
|
+
return {
|
|
12162
|
+
width: any2px(width),
|
|
12074
12163
|
height: `var(--lew-form-item-height-${size})`,
|
|
12075
12164
|
lineHeight: `var(--lew-form-input-line-height-${size})`
|
|
12076
12165
|
};
|
|
@@ -12135,7 +12224,7 @@ const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
|
12135
12224
|
onMouseenter: checkValidationMessage,
|
|
12136
12225
|
onMouseleave: _cache[4] || (_cache[4] = ($event) => validationMessage.value = ""),
|
|
12137
12226
|
class: normalizeClass(["lew-input-number-view", unref(getInputClassNames)]),
|
|
12138
|
-
style: normalizeStyle(
|
|
12227
|
+
style: normalizeStyle(unref(getInputNumberViewStyle))
|
|
12139
12228
|
}, [
|
|
12140
12229
|
withDirectives(createElementVNode("input", {
|
|
12141
12230
|
title: "",
|
|
@@ -12153,7 +12242,7 @@ const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
|
12153
12242
|
onChange: changeFn,
|
|
12154
12243
|
onBlur: blur,
|
|
12155
12244
|
onFocus: focus
|
|
12156
|
-
}, null, 44, _hoisted_1$
|
|
12245
|
+
}, null, 44, _hoisted_1$y), [
|
|
12157
12246
|
[_directive_tooltip, {
|
|
12158
12247
|
content: unref(validationMessage),
|
|
12159
12248
|
triggerFrom: "input-number"
|
|
@@ -12193,7 +12282,7 @@ const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
|
12193
12282
|
};
|
|
12194
12283
|
}
|
|
12195
12284
|
});
|
|
12196
|
-
const LewInputNumber = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["__scopeId", "data-v-
|
|
12285
|
+
const LewInputNumber = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["__scopeId", "data-v-ff264ee4"]]);
|
|
12197
12286
|
const textareaModel = {
|
|
12198
12287
|
modelValue: {
|
|
12199
12288
|
type: String,
|
|
@@ -12307,7 +12396,7 @@ const textareaProps = {
|
|
|
12307
12396
|
description: "是否启用回车键确认(启用后,Shift+Enter可换行)"
|
|
12308
12397
|
}
|
|
12309
12398
|
};
|
|
12310
|
-
const _hoisted_1$
|
|
12399
|
+
const _hoisted_1$x = ["placeholder", "maxlength", "disabled", "readonly"];
|
|
12311
12400
|
const _hoisted_2$l = {
|
|
12312
12401
|
key: 0,
|
|
12313
12402
|
class: "lew-textarea-count"
|
|
@@ -12458,7 +12547,7 @@ const _sfc_main$G = /* @__PURE__ */ defineComponent({
|
|
|
12458
12547
|
onBlur: blur,
|
|
12459
12548
|
onInput: _cache[1] || (_cache[1] = ($event) => emit2("input", modelValue2.value)),
|
|
12460
12549
|
onChange: _cache[2] || (_cache[2] = ($event) => emit2("change", modelValue2.value))
|
|
12461
|
-
}, null, 40, _hoisted_1$
|
|
12550
|
+
}, null, 40, _hoisted_1$x), [
|
|
12462
12551
|
[vModelText, modelValue2.value]
|
|
12463
12552
|
]),
|
|
12464
12553
|
modelValue2.value && _ctx.showCount ? (openBlock(), createElementBlock("div", _hoisted_2$l, toDisplayString(modelValue2.value.length) + toDisplayString(_ctx.maxLength ? " / " + _ctx.maxLength : ""), 1)) : createCommentVNode("", true),
|
|
@@ -12483,7 +12572,7 @@ const _sfc_main$G = /* @__PURE__ */ defineComponent({
|
|
|
12483
12572
|
};
|
|
12484
12573
|
}
|
|
12485
12574
|
});
|
|
12486
|
-
const LewTextarea = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["__scopeId", "data-v-
|
|
12575
|
+
const LewTextarea = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["__scopeId", "data-v-4b92a5fb"]]);
|
|
12487
12576
|
const inputTagModel = {
|
|
12488
12577
|
modelValue: {
|
|
12489
12578
|
type: Array,
|
|
@@ -12621,7 +12710,7 @@ const _sfc_main$F = /* @__PURE__ */ defineComponent({
|
|
|
12621
12710
|
onClick: openInput
|
|
12622
12711
|
}, [
|
|
12623
12712
|
createElementVNode("div", {
|
|
12624
|
-
style: normalizeStyle({ padding: (modelValue2.value || []).length > 0 ? "
|
|
12713
|
+
style: normalizeStyle({ padding: (modelValue2.value || []).length > 0 ? "4px" : "" }),
|
|
12625
12714
|
class: "lew-input-tag-box"
|
|
12626
12715
|
}, [
|
|
12627
12716
|
createVNode(TransitionGroup, { name: "tag-list" }, {
|
|
@@ -12678,7 +12767,7 @@ const _sfc_main$F = /* @__PURE__ */ defineComponent({
|
|
|
12678
12767
|
};
|
|
12679
12768
|
}
|
|
12680
12769
|
});
|
|
12681
|
-
const LewInputTag = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["__scopeId", "data-v-
|
|
12770
|
+
const LewInputTag = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["__scopeId", "data-v-a8a450e2"]]);
|
|
12682
12771
|
const checkboxModel = {
|
|
12683
12772
|
modelValue: {
|
|
12684
12773
|
type: Boolean,
|
|
@@ -12818,7 +12907,7 @@ const checkboxGroupProps = {
|
|
|
12818
12907
|
description: "是否显示复选框的图标(仅在块状模式下生效)"
|
|
12819
12908
|
}
|
|
12820
12909
|
};
|
|
12821
|
-
const _hoisted_1$
|
|
12910
|
+
const _hoisted_1$w = {
|
|
12822
12911
|
key: 0,
|
|
12823
12912
|
class: "lew-checkbox-icon-box"
|
|
12824
12913
|
};
|
|
@@ -12878,7 +12967,7 @@ const _sfc_main$E = /* @__PURE__ */ defineComponent({
|
|
|
12878
12967
|
return openBlock(), createElementBlock("label", {
|
|
12879
12968
|
class: normalizeClass(["lew-checkbox", unref(getCheckboxClassName)])
|
|
12880
12969
|
}, [
|
|
12881
|
-
_ctx.iconable || !_ctx.iconable && !_ctx.block ? (openBlock(), createElementBlock("div", _hoisted_1$
|
|
12970
|
+
_ctx.iconable || !_ctx.iconable && !_ctx.block ? (openBlock(), createElementBlock("div", _hoisted_1$w, [
|
|
12882
12971
|
withDirectives(createElementVNode("i", _hoisted_2$k, null, 512), [
|
|
12883
12972
|
[vShow, _ctx.certain]
|
|
12884
12973
|
]),
|
|
@@ -13109,7 +13198,7 @@ const radioGroupProps = {
|
|
|
13109
13198
|
}
|
|
13110
13199
|
}
|
|
13111
13200
|
};
|
|
13112
|
-
const _hoisted_1$
|
|
13201
|
+
const _hoisted_1$v = {
|
|
13113
13202
|
key: 0,
|
|
13114
13203
|
class: "lew-icon-radio-box"
|
|
13115
13204
|
};
|
|
@@ -13158,7 +13247,7 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
13158
13247
|
return openBlock(), createElementBlock("label", {
|
|
13159
13248
|
class: normalizeClass(["lew-radio", unref(getRadioClassName)])
|
|
13160
13249
|
}, [
|
|
13161
|
-
_ctx.iconable || !_ctx.iconable && !_ctx.block ? (openBlock(), createElementBlock("div", _hoisted_1$
|
|
13250
|
+
_ctx.iconable || !_ctx.iconable && !_ctx.block ? (openBlock(), createElementBlock("div", _hoisted_1$v, [
|
|
13162
13251
|
createVNode(Icon, {
|
|
13163
13252
|
"stroke-width": 4,
|
|
13164
13253
|
class: "lew-icon-radio",
|
|
@@ -13334,7 +13423,7 @@ const tabsProps = {
|
|
|
13334
13423
|
description: "是否将所有标签页设置为只读状态"
|
|
13335
13424
|
}
|
|
13336
13425
|
};
|
|
13337
|
-
const _hoisted_1$
|
|
13426
|
+
const _hoisted_1$u = ["onClick"];
|
|
13338
13427
|
const _sfc_main$A = /* @__PURE__ */ defineComponent({
|
|
13339
13428
|
__name: "LewTabs",
|
|
13340
13429
|
props: /* @__PURE__ */ mergeModels(tabsProps, {
|
|
@@ -13504,14 +13593,14 @@ const _sfc_main$A = /* @__PURE__ */ defineComponent({
|
|
|
13504
13593
|
class: normalizeClass(["lew-tabs-item", { "lew-tabs-item-active": tabsValue.value === item.value }]),
|
|
13505
13594
|
style: normalizeStyle(unref(getItemStyle)),
|
|
13506
13595
|
onClick: ($event) => selectItem(item.value)
|
|
13507
|
-
}, toDisplayString(item.label), 15, _hoisted_1$
|
|
13596
|
+
}, toDisplayString(item.label), 15, _hoisted_1$u);
|
|
13508
13597
|
}), 128))
|
|
13509
13598
|
], 38)
|
|
13510
13599
|
], 6);
|
|
13511
13600
|
};
|
|
13512
13601
|
}
|
|
13513
13602
|
});
|
|
13514
|
-
const LewTabs = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["__scopeId", "data-v-
|
|
13603
|
+
const LewTabs = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["__scopeId", "data-v-b86d4bc4"]]);
|
|
13515
13604
|
function tryOnScopeDispose(fn2) {
|
|
13516
13605
|
if (getCurrentScope()) {
|
|
13517
13606
|
onScopeDispose(fn2);
|
|
@@ -14104,7 +14193,7 @@ const selectProps = {
|
|
|
14104
14193
|
description: "是否在选中项旁显示勾选图标"
|
|
14105
14194
|
}
|
|
14106
14195
|
};
|
|
14107
|
-
const _hoisted_1$
|
|
14196
|
+
const _hoisted_1$t = ["readonly", "placeholder"];
|
|
14108
14197
|
const _hoisted_2$i = { class: "lew-select-options-box" };
|
|
14109
14198
|
const _hoisted_3$d = {
|
|
14110
14199
|
key: 1,
|
|
@@ -14217,24 +14306,22 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
|
14217
14306
|
};
|
|
14218
14307
|
findKeyword();
|
|
14219
14308
|
const getSelectClassName = computed(() => {
|
|
14220
|
-
let { clearable, size } = props2;
|
|
14309
|
+
let { clearable, size, disabled, readonly: readonly2, searchable } = props2;
|
|
14221
14310
|
clearable = clearable ? !!selectValue.value : false;
|
|
14222
|
-
|
|
14311
|
+
const focus = state.visible;
|
|
14312
|
+
return object2class("lew-select", {
|
|
14313
|
+
clearable,
|
|
14314
|
+
size,
|
|
14315
|
+
disabled,
|
|
14316
|
+
readonly: readonly2,
|
|
14317
|
+
searchable,
|
|
14318
|
+
focus
|
|
14319
|
+
});
|
|
14223
14320
|
});
|
|
14224
14321
|
const getBodyClassName = computed(() => {
|
|
14225
14322
|
const { size, disabled } = props2;
|
|
14226
14323
|
return object2class("lew-select-body", { size, disabled });
|
|
14227
14324
|
});
|
|
14228
|
-
const getSelectViewClassName = computed(() => {
|
|
14229
|
-
const { disabled, readonly: readonly2, searchable } = props2;
|
|
14230
|
-
const focus = state.visible;
|
|
14231
|
-
return object2class("lew-select-view", {
|
|
14232
|
-
focus,
|
|
14233
|
-
searchable,
|
|
14234
|
-
disabled,
|
|
14235
|
-
readonly: readonly2
|
|
14236
|
-
});
|
|
14237
|
-
});
|
|
14238
14325
|
const getSelectItemClassName = (e) => {
|
|
14239
14326
|
const { disabled } = e;
|
|
14240
14327
|
const active = getChecked.value(e.value);
|
|
@@ -14288,7 +14375,7 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
|
14288
14375
|
ref_key: "lewPopoverRef",
|
|
14289
14376
|
ref: lewPopoverRef,
|
|
14290
14377
|
popoverBodyClassName: "lew-select-popover-body",
|
|
14291
|
-
class:
|
|
14378
|
+
class: "lew-select-view",
|
|
14292
14379
|
trigger: _ctx.trigger,
|
|
14293
14380
|
disabled: _ctx.disabled,
|
|
14294
14381
|
placement: "bottom-start",
|
|
@@ -14333,7 +14420,7 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
|
14333
14420
|
placeholder: unref(state).keywordBackup || _ctx.placeholder,
|
|
14334
14421
|
onInput: _cache[1] || (_cache[1] = //@ts-ignore
|
|
14335
14422
|
(...args) => unref(searchDebounce) && unref(searchDebounce)(...args))
|
|
14336
|
-
}, null, 44, _hoisted_1$
|
|
14423
|
+
}, null, 44, _hoisted_1$t), [
|
|
14337
14424
|
[vModelText, unref(state).keyword]
|
|
14338
14425
|
])
|
|
14339
14426
|
], 2)
|
|
@@ -14403,11 +14490,11 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
|
14403
14490
|
], 6)
|
|
14404
14491
|
]),
|
|
14405
14492
|
_: 3
|
|
14406
|
-
}, 8, ["
|
|
14493
|
+
}, 8, ["trigger", "disabled", "loading"]);
|
|
14407
14494
|
};
|
|
14408
14495
|
}
|
|
14409
14496
|
});
|
|
14410
|
-
const LewSelect = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["__scopeId", "data-v-
|
|
14497
|
+
const LewSelect = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["__scopeId", "data-v-1944f494"]]);
|
|
14411
14498
|
const selectMultipleModel = {
|
|
14412
14499
|
modelValue: {
|
|
14413
14500
|
type: Array,
|
|
@@ -14522,17 +14609,16 @@ const selectMultipleProps = {
|
|
|
14522
14609
|
description: "选择框默认值"
|
|
14523
14610
|
}
|
|
14524
14611
|
};
|
|
14525
|
-
const _hoisted_1$
|
|
14526
|
-
const _hoisted_2$h = {
|
|
14612
|
+
const _hoisted_1$s = {
|
|
14527
14613
|
key: 0,
|
|
14528
14614
|
class: "lew-search-input"
|
|
14529
14615
|
};
|
|
14530
|
-
const
|
|
14531
|
-
const
|
|
14616
|
+
const _hoisted_2$h = { class: "lew-select-options-box" };
|
|
14617
|
+
const _hoisted_3$c = {
|
|
14532
14618
|
key: 1,
|
|
14533
14619
|
class: "lew-result-count"
|
|
14534
14620
|
};
|
|
14535
|
-
const
|
|
14621
|
+
const _hoisted_4$9 = ["onClick"];
|
|
14536
14622
|
const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
14537
14623
|
__name: "LewSelectMultiple",
|
|
14538
14624
|
props: /* @__PURE__ */ mergeModels(selectMultipleProps, {
|
|
@@ -14658,19 +14744,21 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14658
14744
|
}
|
|
14659
14745
|
return (props2 == null ? void 0 : props2.defaultValue) || selectValue.value || [];
|
|
14660
14746
|
});
|
|
14661
|
-
const getSelectClassName = computed(() => {
|
|
14662
|
-
let { clearable, size } = props2;
|
|
14663
|
-
clearable = clearable ? !!selectValue.value : false;
|
|
14664
|
-
return object2class("lew-select", { clearable, size });
|
|
14665
|
-
});
|
|
14666
14747
|
const getBodyClassName = computed(() => {
|
|
14667
14748
|
const { size, disabled } = props2;
|
|
14668
14749
|
return object2class("lew-select-body", { size, disabled });
|
|
14669
14750
|
});
|
|
14670
|
-
const
|
|
14671
|
-
|
|
14751
|
+
const getSelectClassName = computed(() => {
|
|
14752
|
+
let { clearable, size, disabled, readonly: readonly2 } = props2;
|
|
14753
|
+
clearable = clearable ? !!selectValue.value : false;
|
|
14672
14754
|
const focus = state.visible;
|
|
14673
|
-
return object2class("lew-select
|
|
14755
|
+
return object2class("lew-select", {
|
|
14756
|
+
clearable,
|
|
14757
|
+
size,
|
|
14758
|
+
disabled,
|
|
14759
|
+
readonly: readonly2,
|
|
14760
|
+
focus
|
|
14761
|
+
});
|
|
14674
14762
|
});
|
|
14675
14763
|
const getSelectItemClassName = (e) => {
|
|
14676
14764
|
const { disabled } = e;
|
|
@@ -14713,7 +14801,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14713
14801
|
ref_key: "lewPopoverRef",
|
|
14714
14802
|
ref: lewPopoverRef,
|
|
14715
14803
|
popoverBodyClassName: "lew-select-multiple-popover-body",
|
|
14716
|
-
class:
|
|
14804
|
+
class: "lew-select-view",
|
|
14717
14805
|
trigger: _ctx.trigger,
|
|
14718
14806
|
disabled: _ctx.disabled,
|
|
14719
14807
|
placement: "bottom-start",
|
|
@@ -14753,10 +14841,10 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14753
14841
|
unref(getLabels) && unref(getLabels).length > 0 ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
14754
14842
|
_ctx.valueLayout === "tag" ? (openBlock(), createBlock(unref(LewFlex), {
|
|
14755
14843
|
key: 0,
|
|
14756
|
-
style: {
|
|
14844
|
+
style: { padding: "4px" },
|
|
14757
14845
|
x: "start",
|
|
14758
14846
|
y: "center",
|
|
14759
|
-
gap:
|
|
14847
|
+
gap: 4,
|
|
14760
14848
|
wrap: "",
|
|
14761
14849
|
class: "lew-value"
|
|
14762
14850
|
}, {
|
|
@@ -14793,7 +14881,12 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14793
14881
|
style: { "width": "100%" }
|
|
14794
14882
|
}, {
|
|
14795
14883
|
trigger: withCtx(() => [
|
|
14796
|
-
createElementVNode("div",
|
|
14884
|
+
createElementVNode("div", {
|
|
14885
|
+
style: normalizeStyle({
|
|
14886
|
+
opacity: unref(state).visible ? 0.6 : 1
|
|
14887
|
+
}),
|
|
14888
|
+
class: "lew-select-multiple-text-value"
|
|
14889
|
+
}, toDisplayString(unref(getLabels).join(_ctx.valueTextSplit)), 5)
|
|
14797
14890
|
]),
|
|
14798
14891
|
"popover-body": withCtx(() => [
|
|
14799
14892
|
createVNode(unref(LewFlex), {
|
|
@@ -14801,7 +14894,9 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14801
14894
|
y: "center",
|
|
14802
14895
|
gap: 5,
|
|
14803
14896
|
wrap: "",
|
|
14804
|
-
style: normalizeStyle(
|
|
14897
|
+
style: normalizeStyle({
|
|
14898
|
+
maxWidth: `${unref(state).selectWidth + 12}px`
|
|
14899
|
+
}),
|
|
14805
14900
|
class: "lew-select-multiple-tag-value"
|
|
14806
14901
|
}, {
|
|
14807
14902
|
default: withCtx(() => [
|
|
@@ -14826,7 +14921,12 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14826
14921
|
_: 1
|
|
14827
14922
|
}, 512))
|
|
14828
14923
|
], 64)) : createCommentVNode("", true),
|
|
14829
|
-
withDirectives(createElementVNode("div", {
|
|
14924
|
+
withDirectives(createElementVNode("div", {
|
|
14925
|
+
style: normalizeStyle({
|
|
14926
|
+
opacity: unref(state).visible ? 0.6 : 1
|
|
14927
|
+
}),
|
|
14928
|
+
class: "lew-placeholder"
|
|
14929
|
+
}, toDisplayString(_ctx.placeholder), 5), [
|
|
14830
14930
|
[vShow, unref(getLabels) && unref(getLabels).length === 0]
|
|
14831
14931
|
])
|
|
14832
14932
|
], 2)
|
|
@@ -14837,7 +14937,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14837
14937
|
style: normalizeStyle(`width:${unref(state).selectWidth}px`)
|
|
14838
14938
|
}, [
|
|
14839
14939
|
renderSlot(_ctx.$slots, "header", {}, void 0, true),
|
|
14840
|
-
_ctx.searchable ? (openBlock(), createElementBlock("div",
|
|
14940
|
+
_ctx.searchable ? (openBlock(), createElementBlock("div", _hoisted_1$s, [
|
|
14841
14941
|
withDirectives(createElementVNode("input", {
|
|
14842
14942
|
ref_key: "searchInputRef",
|
|
14843
14943
|
ref: searchInputRef,
|
|
@@ -14849,7 +14949,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14849
14949
|
[vModelText, unref(state).keyword]
|
|
14850
14950
|
])
|
|
14851
14951
|
])) : createCommentVNode("", true),
|
|
14852
|
-
createElementVNode("div",
|
|
14952
|
+
createElementVNode("div", _hoisted_2$h, [
|
|
14853
14953
|
unref(state).options && unref(state).options.length === 0 ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
14854
14954
|
_ctx.$slots.empty ? renderSlot(_ctx.$slots, "empty", { key: 0 }, void 0, true) : (openBlock(), createBlock(unref(LewFlex), {
|
|
14855
14955
|
key: 1,
|
|
@@ -14862,7 +14962,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14862
14962
|
_: 1
|
|
14863
14963
|
}))
|
|
14864
14964
|
], 64)) : createCommentVNode("", true),
|
|
14865
|
-
_ctx.searchable && unref(state).options && unref(state).options.length > 0 ? (openBlock(), createElementBlock("div",
|
|
14965
|
+
_ctx.searchable && unref(state).options && unref(state).options.length > 0 ? (openBlock(), createElementBlock("div", _hoisted_3$c, " 共 " + toDisplayString(unref(numFormat)(unref(state).options && unref(state).options.length)) + " 条结果 ", 1)) : createCommentVNode("", true),
|
|
14866
14966
|
unref(state).options.length > 0 ? (openBlock(), createBlock(unref(UseVirtualList), {
|
|
14867
14967
|
key: unref(getVirtualHeight),
|
|
14868
14968
|
class: "lew-select-options-list lew-scrollbar",
|
|
@@ -14899,7 +14999,7 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14899
14999
|
class: "lew-select-label"
|
|
14900
15000
|
}, null, 8, ["text"])
|
|
14901
15001
|
], 2))
|
|
14902
|
-
], 12,
|
|
15002
|
+
], 12, _hoisted_4$9)
|
|
14903
15003
|
]),
|
|
14904
15004
|
_: 3
|
|
14905
15005
|
}, 8, ["list", "options", "height"])) : createCommentVNode("", true)
|
|
@@ -14908,11 +15008,11 @@ const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
|
14908
15008
|
], 6)
|
|
14909
15009
|
]),
|
|
14910
15010
|
_: 3
|
|
14911
|
-
}, 8, ["
|
|
15011
|
+
}, 8, ["trigger", "disabled", "loading"]);
|
|
14912
15012
|
};
|
|
14913
15013
|
}
|
|
14914
15014
|
});
|
|
14915
|
-
const LewSelectMultiple = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["__scopeId", "data-v-
|
|
15015
|
+
const LewSelectMultiple = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["__scopeId", "data-v-7a311724"]]);
|
|
14916
15016
|
const getHeadDate = ["一", "二", "三", "四", "五", "六", "日"];
|
|
14917
15017
|
const getMonthDate = (year, month) => {
|
|
14918
15018
|
const ret = [];
|
|
@@ -15300,7 +15400,7 @@ var dayjs_min = { exports: {} };
|
|
|
15300
15400
|
})(dayjs_min);
|
|
15301
15401
|
var dayjs_minExports = dayjs_min.exports;
|
|
15302
15402
|
const dayjs = /* @__PURE__ */ getDefaultExportFromCjs(dayjs_minExports);
|
|
15303
|
-
const _hoisted_1$
|
|
15403
|
+
const _hoisted_1$r = { class: "lew-date" };
|
|
15304
15404
|
const _hoisted_2$g = { class: "lew-date-control-left" };
|
|
15305
15405
|
const _hoisted_3$b = { class: "cur-date" };
|
|
15306
15406
|
const _hoisted_4$8 = { style: { "width": "22px", "text-align": "center" } };
|
|
@@ -15388,7 +15488,7 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
|
|
|
15388
15488
|
return object2class("lew-date-item", { e, selected });
|
|
15389
15489
|
});
|
|
15390
15490
|
return (_ctx, _cache) => {
|
|
15391
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
15491
|
+
return openBlock(), createElementBlock("div", _hoisted_1$r, [
|
|
15392
15492
|
createVNode(unref(LewFlex), {
|
|
15393
15493
|
x: "start",
|
|
15394
15494
|
mode: "between",
|
|
@@ -15482,7 +15582,7 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
|
|
|
15482
15582
|
}
|
|
15483
15583
|
});
|
|
15484
15584
|
const LewDate = /* @__PURE__ */ _export_sfc(_sfc_main$x, [["__scopeId", "data-v-5964f565"]]);
|
|
15485
|
-
const _hoisted_1$
|
|
15585
|
+
const _hoisted_1$q = { class: "lew-date-picker-view" };
|
|
15486
15586
|
const _hoisted_2$f = ["onClick"];
|
|
15487
15587
|
const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
15488
15588
|
__name: "LewDatePicker",
|
|
@@ -15530,11 +15630,20 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
15530
15630
|
};
|
|
15531
15631
|
return size[props2.size];
|
|
15532
15632
|
});
|
|
15533
|
-
const
|
|
15633
|
+
const lewDatePickerClassNames = computed(() => {
|
|
15534
15634
|
const focus = visible.value;
|
|
15535
15635
|
const { size, readonly: readonly2, disabled } = props2;
|
|
15536
15636
|
return object2class("lew-date-picker", { focus, size, readonly: readonly2, disabled });
|
|
15537
15637
|
});
|
|
15638
|
+
const getDatePickerInputStyle = computed(() => {
|
|
15639
|
+
const { size } = props2;
|
|
15640
|
+
return {
|
|
15641
|
+
height: `var(--lew-form-item-height-${size})`,
|
|
15642
|
+
lineHeight: `var(--lew-form-input-line-height-${size})`,
|
|
15643
|
+
padding: `var(--lew-form-input-padding-${size})`,
|
|
15644
|
+
fontSize: `var(--lew-form-font-size-${size})`
|
|
15645
|
+
};
|
|
15646
|
+
});
|
|
15538
15647
|
const clearHandle = () => {
|
|
15539
15648
|
modelValue2.value = void 0;
|
|
15540
15649
|
change2(modelValue2.value);
|
|
@@ -15562,16 +15671,28 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
15562
15671
|
onHide: hideHandle
|
|
15563
15672
|
}, {
|
|
15564
15673
|
trigger: withCtx(() => [
|
|
15565
|
-
createElementVNode("div",
|
|
15566
|
-
|
|
15567
|
-
|
|
15568
|
-
|
|
15569
|
-
|
|
15570
|
-
|
|
15571
|
-
|
|
15572
|
-
|
|
15573
|
-
|
|
15574
|
-
|
|
15674
|
+
createElementVNode("div", _hoisted_1$q, [
|
|
15675
|
+
createElementVNode("div", {
|
|
15676
|
+
class: normalizeClass(["lew-date-picker", unref(lewDatePickerClassNames)]),
|
|
15677
|
+
style: normalizeStyle(unref(getDatePickerInputStyle))
|
|
15678
|
+
}, [
|
|
15679
|
+
createVNode(_component_lew_flex, {
|
|
15680
|
+
x: "start",
|
|
15681
|
+
y: "center",
|
|
15682
|
+
style: normalizeStyle({
|
|
15683
|
+
opacity: unref(visible) ? 0.6 : 1
|
|
15684
|
+
})
|
|
15685
|
+
}, {
|
|
15686
|
+
default: withCtx(() => [
|
|
15687
|
+
withDirectives(createElementVNode("div", { class: "lew-date-picker-placeholder" }, toDisplayString(_ctx.placeholder), 513), [
|
|
15688
|
+
[vShow, !modelValue2.value]
|
|
15689
|
+
]),
|
|
15690
|
+
withDirectives(createElementVNode("div", { class: "lew-date-picker-dateValue" }, toDisplayString(modelValue2.value), 513), [
|
|
15691
|
+
[vShow, modelValue2.value]
|
|
15692
|
+
])
|
|
15693
|
+
]),
|
|
15694
|
+
_: 1
|
|
15695
|
+
}, 8, ["style"]),
|
|
15575
15696
|
createVNode(Icon, {
|
|
15576
15697
|
class: normalizeClass(["lew-date-picker-icon-calendar", {
|
|
15577
15698
|
"lew-date-picker-icon-calendar-hide": modelValue2.value && _ctx.clearable
|
|
@@ -15593,8 +15714,8 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
15593
15714
|
]),
|
|
15594
15715
|
_: 1
|
|
15595
15716
|
})
|
|
15596
|
-
])
|
|
15597
|
-
]
|
|
15717
|
+
], 6)
|
|
15718
|
+
])
|
|
15598
15719
|
]),
|
|
15599
15720
|
"popover-body": withCtx(() => [
|
|
15600
15721
|
createVNode(_component_lew_flex, { gap: "0" }, {
|
|
@@ -15647,7 +15768,7 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
15647
15768
|
};
|
|
15648
15769
|
}
|
|
15649
15770
|
});
|
|
15650
|
-
const LewDatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$w, [["__scopeId", "data-v-
|
|
15771
|
+
const LewDatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$w, [["__scopeId", "data-v-b8f08a4e"]]);
|
|
15651
15772
|
const dateRangePickerModel = {
|
|
15652
15773
|
modelValue: {
|
|
15653
15774
|
type: Object,
|
|
@@ -15756,7 +15877,7 @@ const dateRangeProps = {
|
|
|
15756
15877
|
description: "日期格式化字符串"
|
|
15757
15878
|
}
|
|
15758
15879
|
};
|
|
15759
|
-
const _hoisted_1$
|
|
15880
|
+
const _hoisted_1$p = { class: "lew-date-range" };
|
|
15760
15881
|
const _hoisted_2$e = { class: "lew-date" };
|
|
15761
15882
|
const _hoisted_3$a = { class: "lew-date-control-left" };
|
|
15762
15883
|
const _hoisted_4$7 = { class: "cur-date" };
|
|
@@ -16033,7 +16154,7 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
16033
16154
|
init();
|
|
16034
16155
|
__expose2({ init });
|
|
16035
16156
|
return (_ctx, _cache) => {
|
|
16036
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
16157
|
+
return openBlock(), createElementBlock("div", _hoisted_1$p, [
|
|
16037
16158
|
createElementVNode("div", _hoisted_2$e, [
|
|
16038
16159
|
createVNode(unref(LewFlex), {
|
|
16039
16160
|
x: "start",
|
|
@@ -16229,7 +16350,7 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
16229
16350
|
}
|
|
16230
16351
|
});
|
|
16231
16352
|
const LewDateRange = /* @__PURE__ */ _export_sfc(_sfc_main$v, [["__scopeId", "data-v-ac11df30"]]);
|
|
16232
|
-
const _hoisted_1$
|
|
16353
|
+
const _hoisted_1$o = { class: "lew-date-range-picker-view" };
|
|
16233
16354
|
const _hoisted_2$d = {
|
|
16234
16355
|
key: 0,
|
|
16235
16356
|
class: "lew-date-range-picker-placeholder"
|
|
@@ -16308,11 +16429,21 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
16308
16429
|
disabled
|
|
16309
16430
|
});
|
|
16310
16431
|
});
|
|
16432
|
+
const getDateRangePickerInputStyle = computed(() => {
|
|
16433
|
+
const { size } = props2;
|
|
16434
|
+
return {
|
|
16435
|
+
height: `var(--lew-form-item-height-${size})`,
|
|
16436
|
+
lineHeight: `var(--lew-form-input-line-height-${size})`,
|
|
16437
|
+
padding: `var(--lew-form-input-padding-${size})`,
|
|
16438
|
+
fontSize: `var(--lew-form-font-size-${size})`
|
|
16439
|
+
};
|
|
16440
|
+
});
|
|
16311
16441
|
const checkClear = computed(() => {
|
|
16312
16442
|
return (modelValue2.value && modelValue2.value[startKey] || modelValue2.value && modelValue2.value[endKey]) && props2.clearable;
|
|
16313
16443
|
});
|
|
16314
16444
|
__expose2({ show, hide: hide2 });
|
|
16315
16445
|
return (_ctx, _cache) => {
|
|
16446
|
+
const _component_lew_flex = resolveComponent("lew-flex");
|
|
16316
16447
|
return openBlock(), createBlock(unref(_sfc_main$5), {
|
|
16317
16448
|
ref_key: "lewPopoverRef",
|
|
16318
16449
|
ref: lewPopoverRef,
|
|
@@ -16324,25 +16455,37 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
16324
16455
|
onHide: hideHandle
|
|
16325
16456
|
}, {
|
|
16326
16457
|
trigger: withCtx(() => [
|
|
16327
|
-
createElementVNode("div",
|
|
16328
|
-
|
|
16329
|
-
|
|
16330
|
-
|
|
16331
|
-
|
|
16332
|
-
|
|
16333
|
-
|
|
16334
|
-
|
|
16335
|
-
|
|
16458
|
+
createElementVNode("div", _hoisted_1$o, [
|
|
16459
|
+
createElementVNode("div", {
|
|
16460
|
+
class: normalizeClass(["lew-date-range-picker", unref(lewDateRangeClassNames)]),
|
|
16461
|
+
style: normalizeStyle(unref(getDateRangePickerInputStyle))
|
|
16462
|
+
}, [
|
|
16463
|
+
createVNode(_component_lew_flex, {
|
|
16464
|
+
x: "start",
|
|
16465
|
+
y: "center",
|
|
16466
|
+
style: normalizeStyle({
|
|
16467
|
+
opacity: unref(visible) ? 0.6 : 1
|
|
16336
16468
|
})
|
|
16337
|
-
|
|
16338
|
-
|
|
16339
|
-
|
|
16340
|
-
|
|
16341
|
-
|
|
16342
|
-
|
|
16343
|
-
|
|
16344
|
-
|
|
16345
|
-
|
|
16469
|
+
}, {
|
|
16470
|
+
default: withCtx(() => [
|
|
16471
|
+
!modelValue2.value || !modelValue2.value[unref(startKey)] ? (openBlock(), createElementBlock("div", _hoisted_2$d, toDisplayString(_ctx.placeholderStart), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$9, toDisplayString(modelValue2.value[unref(startKey)]), 1)),
|
|
16472
|
+
createElementVNode("div", _hoisted_4$6, [
|
|
16473
|
+
createVNode(Icon, {
|
|
16474
|
+
size: 14,
|
|
16475
|
+
type: "minus"
|
|
16476
|
+
})
|
|
16477
|
+
]),
|
|
16478
|
+
!modelValue2.value || !modelValue2.value[unref(endKey)] ? (openBlock(), createElementBlock("div", _hoisted_5$3, toDisplayString(_ctx.placeholderEnd), 1)) : (openBlock(), createElementBlock("div", _hoisted_6$2, toDisplayString(modelValue2.value[unref(endKey)]), 1)),
|
|
16479
|
+
createVNode(Icon, {
|
|
16480
|
+
class: normalizeClass(["lew-date-range-picker-icon-calendar", {
|
|
16481
|
+
"lew-date-range-picker-icon-calendar-hide": unref(checkClear)
|
|
16482
|
+
}]),
|
|
16483
|
+
size: unref(getIconSize),
|
|
16484
|
+
type: "calendar"
|
|
16485
|
+
}, null, 8, ["size", "class"])
|
|
16486
|
+
]),
|
|
16487
|
+
_: 1
|
|
16488
|
+
}, 8, ["style"]),
|
|
16346
16489
|
createVNode(Transition, { name: "lew-form-icon-ani" }, {
|
|
16347
16490
|
default: withCtx(() => [
|
|
16348
16491
|
_ctx.clearable && unref(checkClear) && !_ctx.readonly ? (openBlock(), createBlock(Icon, {
|
|
@@ -16357,8 +16500,8 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
16357
16500
|
]),
|
|
16358
16501
|
_: 1
|
|
16359
16502
|
})
|
|
16360
|
-
])
|
|
16361
|
-
]
|
|
16503
|
+
], 6)
|
|
16504
|
+
])
|
|
16362
16505
|
]),
|
|
16363
16506
|
"popover-body": withCtx(() => [
|
|
16364
16507
|
createVNode(unref(LewDateRange), mergeProps({
|
|
@@ -16375,7 +16518,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
16375
16518
|
};
|
|
16376
16519
|
}
|
|
16377
16520
|
});
|
|
16378
|
-
const LewDateRangePicker = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__scopeId", "data-v-
|
|
16521
|
+
const LewDateRangePicker = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__scopeId", "data-v-61368d37"]]);
|
|
16379
16522
|
const cascaderModel = {
|
|
16380
16523
|
modelValue: {
|
|
16381
16524
|
type: [String, Number],
|
|
@@ -16463,7 +16606,7 @@ const cascaderProps = {
|
|
|
16463
16606
|
description: "是否只读"
|
|
16464
16607
|
}
|
|
16465
16608
|
};
|
|
16466
|
-
const _hoisted_1$
|
|
16609
|
+
const _hoisted_1$n = { key: 1 };
|
|
16467
16610
|
const _hoisted_2$c = {
|
|
16468
16611
|
class: "lew-cascader-item-padding",
|
|
16469
16612
|
style: { height: "38px" }
|
|
@@ -16686,22 +16829,35 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16686
16829
|
emit2("change");
|
|
16687
16830
|
};
|
|
16688
16831
|
const getValueStyle = computed(() => {
|
|
16689
|
-
|
|
16832
|
+
const { size } = props2;
|
|
16833
|
+
const widthMap = {
|
|
16834
|
+
small: "calc(100% - 24px)",
|
|
16835
|
+
medium: "calc(100% - 24px)",
|
|
16836
|
+
large: "calc(100% - 24px)"
|
|
16837
|
+
};
|
|
16838
|
+
return {
|
|
16839
|
+
width: widthMap[size],
|
|
16840
|
+
padding: `var(--lew-form-input-padding-${size})`,
|
|
16841
|
+
fontSize: `var(--lew-form-font-size-${size})`,
|
|
16842
|
+
lineHeight: `calc(var(--lew-form-item-height-${size}) - (var(--lew-form-border-width) * 2))`,
|
|
16843
|
+
opacity: state.visible ? 0.4 : 1
|
|
16844
|
+
};
|
|
16690
16845
|
});
|
|
16691
16846
|
const getCascaderClassName = computed(() => {
|
|
16692
|
-
let { clearable,
|
|
16847
|
+
let { clearable, disabled, readonly: readonly2 } = props2;
|
|
16693
16848
|
clearable = clearable ? !!cascaderValue.value : false;
|
|
16694
|
-
|
|
16849
|
+
const focus = state.visible;
|
|
16850
|
+
return object2class("lew-cascader", {
|
|
16851
|
+
clearable,
|
|
16852
|
+
disabled,
|
|
16853
|
+
readonly: readonly2,
|
|
16854
|
+
focus
|
|
16855
|
+
});
|
|
16695
16856
|
});
|
|
16696
16857
|
const getBodyClassName = computed(() => {
|
|
16697
16858
|
const { size, disabled } = props2;
|
|
16698
16859
|
return object2class("lew-cascader-body", { size, disabled });
|
|
16699
16860
|
});
|
|
16700
|
-
const getCascaderViewClassName = computed(() => {
|
|
16701
|
-
const { disabled, readonly: readonly2 } = props2;
|
|
16702
|
-
const focus = state.visible;
|
|
16703
|
-
return object2class("lew-cascader-view", { focus, disabled, readonly: readonly2 });
|
|
16704
|
-
});
|
|
16705
16861
|
const getIconSize = computed(() => {
|
|
16706
16862
|
const size = {
|
|
16707
16863
|
small: 14,
|
|
@@ -16731,6 +16887,12 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16731
16887
|
}
|
|
16732
16888
|
return _hasChildOptions * 200;
|
|
16733
16889
|
});
|
|
16890
|
+
const getCascaderStyle = computed(() => {
|
|
16891
|
+
const { size } = props2;
|
|
16892
|
+
return {
|
|
16893
|
+
height: `var(--lew-form-item-height-${size})`
|
|
16894
|
+
};
|
|
16895
|
+
});
|
|
16734
16896
|
const getLabel = computed(() => {
|
|
16735
16897
|
const item = findObjectByValue(
|
|
16736
16898
|
state.optionsTree,
|
|
@@ -16752,11 +16914,10 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16752
16914
|
return openBlock(), createBlock(unref(_sfc_main$5), {
|
|
16753
16915
|
ref_key: "lewPopoverRef",
|
|
16754
16916
|
ref: lewPopoverRef,
|
|
16755
|
-
class:
|
|
16917
|
+
class: "lew-cascader-view",
|
|
16756
16918
|
trigger: _ctx.trigger,
|
|
16757
16919
|
disabled: _ctx.disabled,
|
|
16758
16920
|
placement: "bottom-start",
|
|
16759
|
-
style: { "width": "100%" },
|
|
16760
16921
|
offset: [-1, 10],
|
|
16761
16922
|
loading: unref(state).loading,
|
|
16762
16923
|
onShow: showHandle,
|
|
@@ -16766,7 +16927,8 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16766
16927
|
createElementVNode("div", {
|
|
16767
16928
|
ref_key: "lewCascaderRef",
|
|
16768
16929
|
ref: lewCascaderRef,
|
|
16769
|
-
class: normalizeClass(["lew-cascader", unref(getCascaderClassName)])
|
|
16930
|
+
class: normalizeClass(["lew-cascader", unref(getCascaderClassName)]),
|
|
16931
|
+
style: normalizeStyle(unref(getCascaderStyle))
|
|
16770
16932
|
}, [
|
|
16771
16933
|
createVNode(Transition, { name: "lew-form-icon-ani" }, {
|
|
16772
16934
|
default: withCtx(() => [
|
|
@@ -16794,20 +16956,23 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16794
16956
|
_: 1
|
|
16795
16957
|
}),
|
|
16796
16958
|
withDirectives(createElementVNode("div", {
|
|
16797
|
-
|
|
16798
|
-
|
|
16959
|
+
class: "lew-cascader-value",
|
|
16960
|
+
style: normalizeStyle(unref(getValueStyle))
|
|
16799
16961
|
}, [
|
|
16800
16962
|
_ctx.showAllLevels ? (openBlock(), createBlock(unref(LewTextTrim), {
|
|
16801
16963
|
key: 0,
|
|
16802
16964
|
text: unref(getLabel).join(" / ")
|
|
16803
|
-
}, null, 8, ["text"])) : unref(getLabel) ? (openBlock(), createElementBlock("span", _hoisted_1$
|
|
16965
|
+
}, null, 8, ["text"])) : unref(getLabel) ? (openBlock(), createElementBlock("span", _hoisted_1$n, toDisplayString(unref(getLabel)[unref(getLabel).length - 1]), 1)) : createCommentVNode("", true)
|
|
16804
16966
|
], 4), [
|
|
16805
16967
|
[vShow, unref(getLabel) && unref(getLabel).length > 0]
|
|
16806
16968
|
]),
|
|
16807
|
-
withDirectives(createElementVNode("div", {
|
|
16969
|
+
withDirectives(createElementVNode("div", {
|
|
16970
|
+
class: "lew-cascader-placeholder",
|
|
16971
|
+
style: normalizeStyle(unref(getValueStyle))
|
|
16972
|
+
}, toDisplayString(_ctx.placeholder), 5), [
|
|
16808
16973
|
[vShow, !unref(getLabel) || unref(getLabel) && unref(getLabel).length === 0]
|
|
16809
16974
|
])
|
|
16810
|
-
],
|
|
16975
|
+
], 6)
|
|
16811
16976
|
]),
|
|
16812
16977
|
"popover-body": withCtx(() => [
|
|
16813
16978
|
createElementVNode("div", {
|
|
@@ -16920,11 +17085,11 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
16920
17085
|
], 6)
|
|
16921
17086
|
]),
|
|
16922
17087
|
_: 3
|
|
16923
|
-
}, 8, ["
|
|
17088
|
+
}, 8, ["trigger", "disabled", "loading"]);
|
|
16924
17089
|
};
|
|
16925
17090
|
}
|
|
16926
17091
|
});
|
|
16927
|
-
const LewCascader = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["__scopeId", "data-v-
|
|
17092
|
+
const LewCascader = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["__scopeId", "data-v-125f865d"]]);
|
|
16928
17093
|
const treeSelectModel = {
|
|
16929
17094
|
modelValue: {
|
|
16930
17095
|
type: [String, Number],
|
|
@@ -17084,7 +17249,7 @@ const treeSelectProps = {
|
|
|
17084
17249
|
description: "异步加载子节点数据的方法"
|
|
17085
17250
|
}
|
|
17086
17251
|
};
|
|
17087
|
-
const _hoisted_1$
|
|
17252
|
+
const _hoisted_1$m = ["readonly", "placeholder"];
|
|
17088
17253
|
const _hoisted_2$b = { class: "lew-select-options-box" };
|
|
17089
17254
|
const _hoisted_3$7 = {
|
|
17090
17255
|
key: 0,
|
|
@@ -17191,24 +17356,23 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
17191
17356
|
};
|
|
17192
17357
|
findKeyword();
|
|
17193
17358
|
const getSelectClassName = computed(() => {
|
|
17194
|
-
let { clearable, size, align } = props2;
|
|
17359
|
+
let { clearable, size, align, disabled, readonly: readonly2, searchable } = props2;
|
|
17195
17360
|
clearable = clearable ? !!treeSelectValue.value : false;
|
|
17196
|
-
|
|
17361
|
+
const focus = state.visible;
|
|
17362
|
+
return object2class("lew-select", {
|
|
17363
|
+
clearable,
|
|
17364
|
+
size,
|
|
17365
|
+
align,
|
|
17366
|
+
disabled,
|
|
17367
|
+
readonly: readonly2,
|
|
17368
|
+
searchable,
|
|
17369
|
+
focus
|
|
17370
|
+
});
|
|
17197
17371
|
});
|
|
17198
17372
|
const getBodyClassName = computed(() => {
|
|
17199
17373
|
const { size, disabled } = props2;
|
|
17200
17374
|
return object2class("lew-select-body", { size, disabled });
|
|
17201
17375
|
});
|
|
17202
|
-
const getSelectViewClassName = computed(() => {
|
|
17203
|
-
const { disabled, readonly: readonly2, searchable } = props2;
|
|
17204
|
-
const focus = state.visible;
|
|
17205
|
-
return object2class("lew-select-view", {
|
|
17206
|
-
focus,
|
|
17207
|
-
searchable,
|
|
17208
|
-
disabled,
|
|
17209
|
-
readonly: readonly2 || state.initLoading
|
|
17210
|
-
});
|
|
17211
|
-
});
|
|
17212
17376
|
const getIconSize = computed(() => {
|
|
17213
17377
|
const size = {
|
|
17214
17378
|
small: 14,
|
|
@@ -17258,7 +17422,7 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
17258
17422
|
ref_key: "lewPopoverRef",
|
|
17259
17423
|
ref: lewPopoverRef,
|
|
17260
17424
|
popoverBodyClassName: "lew-select-popover-body",
|
|
17261
|
-
class:
|
|
17425
|
+
class: "lew-select-view",
|
|
17262
17426
|
trigger: _ctx.trigger,
|
|
17263
17427
|
disabled: _ctx.disabled,
|
|
17264
17428
|
placement: "bottom-start",
|
|
@@ -17310,7 +17474,7 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
17310
17474
|
placeholder: unref(state).keywordBackup || props2.placeholder,
|
|
17311
17475
|
onInput: _cache[1] || (_cache[1] = //@ts-ignore
|
|
17312
17476
|
(...args) => unref(searchDebounce) && unref(searchDebounce)(...args))
|
|
17313
|
-
}, null, 44, _hoisted_1$
|
|
17477
|
+
}, null, 44, _hoisted_1$m), [
|
|
17314
17478
|
[vModelText, unref(state).keyword]
|
|
17315
17479
|
])
|
|
17316
17480
|
], 2)
|
|
@@ -17365,12 +17529,12 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
17365
17529
|
], 6)
|
|
17366
17530
|
]),
|
|
17367
17531
|
_: 3
|
|
17368
|
-
}, 8, ["
|
|
17532
|
+
}, 8, ["trigger", "disabled", "loading"]);
|
|
17369
17533
|
};
|
|
17370
17534
|
}
|
|
17371
17535
|
});
|
|
17372
|
-
const LewTreeSelect = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__scopeId", "data-v-
|
|
17373
|
-
const _hoisted_1$
|
|
17536
|
+
const LewTreeSelect = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__scopeId", "data-v-8b411b09"]]);
|
|
17537
|
+
const _hoisted_1$l = { class: "lew-form-modal lew-scrollbar" };
|
|
17374
17538
|
const _sfc_main$r = /* @__PURE__ */ defineComponent({
|
|
17375
17539
|
__name: "FormModal",
|
|
17376
17540
|
props: {
|
|
@@ -17441,7 +17605,7 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
|
|
|
17441
17605
|
title: `${unref(editIndex) >= 0 ? "编辑" : "新增"}数据`
|
|
17442
17606
|
}, {
|
|
17443
17607
|
default: withCtx(() => [
|
|
17444
|
-
createElementVNode("div", _hoisted_1$
|
|
17608
|
+
createElementVNode("div", _hoisted_1$l, [
|
|
17445
17609
|
createVNode(unref(LewForm), {
|
|
17446
17610
|
siz: __props2.size,
|
|
17447
17611
|
onMounted: formMounted,
|
|
@@ -17985,7 +18149,7 @@ const switchProps = {
|
|
|
17985
18149
|
description: "是否显示加载状态"
|
|
17986
18150
|
}
|
|
17987
18151
|
};
|
|
17988
|
-
const _hoisted_1$
|
|
18152
|
+
const _hoisted_1$k = ["disabled"];
|
|
17989
18153
|
const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
17990
18154
|
__name: "LewSwitch",
|
|
17991
18155
|
props: /* @__PURE__ */ mergeModels(switchProps, {
|
|
@@ -18034,43 +18198,43 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
18034
18198
|
switch (size) {
|
|
18035
18199
|
case "small":
|
|
18036
18200
|
return {
|
|
18037
|
-
"--lew-switch-width": "
|
|
18038
|
-
"--lew-switch-height": "
|
|
18039
|
-
"--lew-switch-dot-width": "
|
|
18040
|
-
"--lew-switch-dot-height": "
|
|
18041
|
-
"--lew-switch-dot-width-active": "
|
|
18201
|
+
"--lew-switch-width": "42px",
|
|
18202
|
+
"--lew-switch-height": "26px",
|
|
18203
|
+
"--lew-switch-dot-width": "18px",
|
|
18204
|
+
"--lew-switch-dot-height": "18px",
|
|
18205
|
+
"--lew-switch-dot-width-active": "20px",
|
|
18042
18206
|
"--lew-switch-dot-transform": "translate(4px, 4px)",
|
|
18043
|
-
"--lew-switch-dot-transform-active": "translate(
|
|
18207
|
+
"--lew-switch-dot-transform-active": "translate(17px, 4px)"
|
|
18044
18208
|
};
|
|
18045
18209
|
case "medium":
|
|
18046
18210
|
return {
|
|
18047
|
-
"--lew-switch-width": "
|
|
18048
|
-
"--lew-switch-height": "
|
|
18049
|
-
"--lew-switch-dot-width": "
|
|
18050
|
-
"--lew-switch-dot-height": "
|
|
18051
|
-
"--lew-switch-dot-width-active": "
|
|
18211
|
+
"--lew-switch-width": "44px",
|
|
18212
|
+
"--lew-switch-height": "28px",
|
|
18213
|
+
"--lew-switch-dot-width": "20px",
|
|
18214
|
+
"--lew-switch-dot-height": "20px",
|
|
18215
|
+
"--lew-switch-dot-width-active": "22px",
|
|
18052
18216
|
"--lew-switch-dot-transform": "translate(4px, 4px)",
|
|
18053
|
-
"--lew-switch-dot-transform-active": "translate(
|
|
18217
|
+
"--lew-switch-dot-transform-active": "translate(17px, 4px)"
|
|
18054
18218
|
};
|
|
18055
18219
|
case "large":
|
|
18056
18220
|
return {
|
|
18057
|
-
"--lew-switch-width": "
|
|
18058
|
-
"--lew-switch-height": "
|
|
18059
|
-
"--lew-switch-dot-width": "
|
|
18060
|
-
"--lew-switch-dot-height": "
|
|
18061
|
-
"--lew-switch-dot-width-active": "
|
|
18221
|
+
"--lew-switch-width": "46px",
|
|
18222
|
+
"--lew-switch-height": "30px",
|
|
18223
|
+
"--lew-switch-dot-width": "22px",
|
|
18224
|
+
"--lew-switch-dot-height": "22px",
|
|
18225
|
+
"--lew-switch-dot-width-active": "24px",
|
|
18062
18226
|
"--lew-switch-dot-transform": "translate(4px, 4px)",
|
|
18063
|
-
"--lew-switch-dot-transform-active": "translate(
|
|
18227
|
+
"--lew-switch-dot-transform-active": "translate(17px, 4px)"
|
|
18064
18228
|
};
|
|
18065
18229
|
default:
|
|
18066
18230
|
return {
|
|
18067
|
-
"--lew-switch-width": "
|
|
18068
|
-
"--lew-switch-height": "
|
|
18069
|
-
"--lew-switch-dot-width": "
|
|
18070
|
-
"--lew-switch-dot-height": "
|
|
18071
|
-
"--lew-switch-dot-width-active": "
|
|
18231
|
+
"--lew-switch-width": "44px",
|
|
18232
|
+
"--lew-switch-height": "28px",
|
|
18233
|
+
"--lew-switch-dot-width": "20px",
|
|
18234
|
+
"--lew-switch-dot-height": "20px",
|
|
18235
|
+
"--lew-switch-dot-width-active": "24px",
|
|
18072
18236
|
"--lew-switch-dot-transform": "translate(4px, 4px)",
|
|
18073
|
-
"--lew-switch-dot-transform-active": "translate(
|
|
18237
|
+
"--lew-switch-dot-transform-active": "translate(17px, 4px)"
|
|
18074
18238
|
};
|
|
18075
18239
|
}
|
|
18076
18240
|
});
|
|
@@ -18084,7 +18248,7 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
18084
18248
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue2.value = $event),
|
|
18085
18249
|
type: "checkbox",
|
|
18086
18250
|
disabled: _ctx.disabled
|
|
18087
|
-
}, null, 8, _hoisted_1$
|
|
18251
|
+
}, null, 8, _hoisted_1$k), [
|
|
18088
18252
|
[vShow, false],
|
|
18089
18253
|
[vModelCheckbox, modelValue2.value]
|
|
18090
18254
|
]),
|
|
@@ -18093,7 +18257,7 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
18093
18257
|
};
|
|
18094
18258
|
}
|
|
18095
18259
|
});
|
|
18096
|
-
const LewSwitch = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["__scopeId", "data-v-
|
|
18260
|
+
const LewSwitch = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["__scopeId", "data-v-f9d855ca"]]);
|
|
18097
18261
|
const sliderModel = {
|
|
18098
18262
|
modelValue: {
|
|
18099
18263
|
type: [Number, void 0],
|
|
@@ -18183,7 +18347,7 @@ const sliderProps = {
|
|
|
18183
18347
|
description: "格式化 tooltip 内容"
|
|
18184
18348
|
}
|
|
18185
18349
|
};
|
|
18186
|
-
const _hoisted_1$
|
|
18350
|
+
const _hoisted_1$j = { class: "lew-slider-track-line" };
|
|
18187
18351
|
const _hoisted_2$a = ["onClick"];
|
|
18188
18352
|
const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
18189
18353
|
__name: "LewSlider",
|
|
@@ -18394,7 +18558,7 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
|
18394
18558
|
onClick: _cache[1] || (_cache[1] = withModifiers(() => {
|
|
18395
18559
|
}, ["stop"]))
|
|
18396
18560
|
}, null, 4),
|
|
18397
|
-
createElementVNode("div", _hoisted_1$
|
|
18561
|
+
createElementVNode("div", _hoisted_1$j, [
|
|
18398
18562
|
createElementVNode("div", {
|
|
18399
18563
|
class: "lew-slider-track-line-range",
|
|
18400
18564
|
style: normalizeStyle({
|
|
@@ -18547,7 +18711,7 @@ const sliderRangeProps = {
|
|
|
18547
18711
|
description: "格式化 tooltip 内容"
|
|
18548
18712
|
}
|
|
18549
18713
|
};
|
|
18550
|
-
const _hoisted_1$
|
|
18714
|
+
const _hoisted_1$i = { class: "lew-slider-track-line" };
|
|
18551
18715
|
const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
18552
18716
|
__name: "LewSliderRange",
|
|
18553
18717
|
props: /* @__PURE__ */ mergeModels(sliderRangeProps, {
|
|
@@ -18767,7 +18931,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
|
18767
18931
|
onClick: _cache[1] || (_cache[1] = withModifiers(() => {
|
|
18768
18932
|
}, ["stop"]))
|
|
18769
18933
|
}, null, 4),
|
|
18770
|
-
createElementVNode("div", _hoisted_1$
|
|
18934
|
+
createElementVNode("div", _hoisted_1$i, [
|
|
18771
18935
|
createElementVNode("div", {
|
|
18772
18936
|
class: "lew-slider-track-line-range",
|
|
18773
18937
|
style: normalizeStyle({
|
|
@@ -18865,6 +19029,11 @@ const colorPickerProps = {
|
|
|
18865
19029
|
default: "auto",
|
|
18866
19030
|
description: "颜色选择器宽度"
|
|
18867
19031
|
},
|
|
19032
|
+
placeholder: {
|
|
19033
|
+
type: String,
|
|
19034
|
+
default: "请选择",
|
|
19035
|
+
description: "颜色选择器占位文本"
|
|
19036
|
+
},
|
|
18868
19037
|
disabled: {
|
|
18869
19038
|
type: Boolean,
|
|
18870
19039
|
default: false,
|
|
@@ -18876,23 +19045,22 @@ const colorPickerProps = {
|
|
|
18876
19045
|
description: "是否只读"
|
|
18877
19046
|
}
|
|
18878
19047
|
};
|
|
19048
|
+
const _hoisted_1$h = ["placeholder"];
|
|
18879
19049
|
const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
18880
19050
|
__name: "LewColorPicker",
|
|
18881
19051
|
props: /* @__PURE__ */ mergeModels(colorPickerProps, {
|
|
18882
19052
|
"modelValue": {},
|
|
18883
19053
|
"modelModifiers": {}
|
|
18884
19054
|
}),
|
|
18885
|
-
emits: ["update:modelValue"],
|
|
18886
|
-
setup(__props2) {
|
|
19055
|
+
emits: /* @__PURE__ */ mergeModels(["change"], ["update:modelValue"]),
|
|
19056
|
+
setup(__props2, { emit: __emit2 }) {
|
|
18887
19057
|
const props2 = __props2;
|
|
18888
19058
|
const modelValue2 = useModel(__props2, "modelValue");
|
|
19059
|
+
const emit2 = __emit2;
|
|
18889
19060
|
const isFocus = ref(false);
|
|
18890
19061
|
const getPickerClassName = computed(() => {
|
|
18891
|
-
return object2class("lew-color-picker", {});
|
|
18892
|
-
});
|
|
18893
|
-
const getPickerViewClassName = computed(() => {
|
|
18894
19062
|
const { disabled, readonly: readonly2 } = props2;
|
|
18895
|
-
return object2class("lew-color-picker
|
|
19063
|
+
return object2class("lew-color-picker", {
|
|
18896
19064
|
disabled,
|
|
18897
19065
|
readonly: readonly2,
|
|
18898
19066
|
focus: isFocus.value
|
|
@@ -18906,7 +19074,7 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18906
19074
|
large: 130
|
|
18907
19075
|
};
|
|
18908
19076
|
return {
|
|
18909
|
-
width: width === "auto" ? any2px(_width[size]) : any2px(width)
|
|
19077
|
+
width: width === "auto" || !width ? any2px(_width[size]) : any2px(width)
|
|
18910
19078
|
};
|
|
18911
19079
|
});
|
|
18912
19080
|
const getPickerStyle = computed(() => {
|
|
@@ -18921,8 +19089,8 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18921
19089
|
const getPickerInputStyle = computed(() => {
|
|
18922
19090
|
const { size } = props2;
|
|
18923
19091
|
return {
|
|
18924
|
-
width: `calc(var(--lew-form-item-height-${size}) -
|
|
18925
|
-
height: `calc(var(--lew-form-item-height-${size}) -
|
|
19092
|
+
width: `calc(var(--lew-form-item-height-${size}) - 12px)`,
|
|
19093
|
+
height: `calc(var(--lew-form-item-height-${size}) - 12px)`
|
|
18926
19094
|
};
|
|
18927
19095
|
});
|
|
18928
19096
|
const getPickerValueInputStyle = computed(() => {
|
|
@@ -18939,6 +19107,7 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18939
19107
|
const blur = () => {
|
|
18940
19108
|
isFocus.value = false;
|
|
18941
19109
|
modelValue2.value = convertToHex(modelValue2.value);
|
|
19110
|
+
emit2("change", modelValue2.value);
|
|
18942
19111
|
};
|
|
18943
19112
|
const convertToHex = (color) => {
|
|
18944
19113
|
color = color.trim();
|
|
@@ -18958,11 +19127,14 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18958
19127
|
const b = parseInt(rgbMatch[3]).toString(16).padStart(2, "0");
|
|
18959
19128
|
return `#${r}${g}${b}`;
|
|
18960
19129
|
}
|
|
18961
|
-
return "
|
|
19130
|
+
return "";
|
|
19131
|
+
};
|
|
19132
|
+
const change2 = () => {
|
|
19133
|
+
emit2("change", modelValue2.value);
|
|
18962
19134
|
};
|
|
18963
19135
|
return (_ctx, _cache) => {
|
|
18964
19136
|
return openBlock(), createElementBlock("div", {
|
|
18965
|
-
class:
|
|
19137
|
+
class: "lew-color-picker-view",
|
|
18966
19138
|
style: normalizeStyle(unref(getPickerViewStyle))
|
|
18967
19139
|
}, [
|
|
18968
19140
|
createElementVNode("div", {
|
|
@@ -18973,8 +19145,9 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18973
19145
|
class: "lew-color-picker-input",
|
|
18974
19146
|
style: normalizeStyle(unref(getPickerInputStyle)),
|
|
18975
19147
|
type: "color",
|
|
18976
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue2.value = $event)
|
|
18977
|
-
|
|
19148
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue2.value = $event),
|
|
19149
|
+
onChange: change2
|
|
19150
|
+
}, null, 36), [
|
|
18978
19151
|
[vModelText, modelValue2.value]
|
|
18979
19152
|
]),
|
|
18980
19153
|
withDirectives(createElementVNode("input", {
|
|
@@ -18983,18 +19156,19 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
18983
19156
|
style: normalizeStyle(unref(getPickerValueInputStyle)),
|
|
18984
19157
|
class: "lew-color-value-input",
|
|
18985
19158
|
type: "text",
|
|
19159
|
+
placeholder: _ctx.placeholder,
|
|
18986
19160
|
onFocus: focus,
|
|
18987
19161
|
onBlur: blur,
|
|
18988
19162
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => modelValue2.value = $event)
|
|
18989
|
-
}, null,
|
|
19163
|
+
}, null, 44, _hoisted_1$h), [
|
|
18990
19164
|
[vModelText, modelValue2.value]
|
|
18991
19165
|
])
|
|
18992
19166
|
], 6)
|
|
18993
|
-
],
|
|
19167
|
+
], 4);
|
|
18994
19168
|
};
|
|
18995
19169
|
}
|
|
18996
19170
|
});
|
|
18997
|
-
const LewColorPicker = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__scopeId", "data-v-
|
|
19171
|
+
const LewColorPicker = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__scopeId", "data-v-5601dfdf"]]);
|
|
18998
19172
|
const uploadProps = {
|
|
18999
19173
|
accept: {
|
|
19000
19174
|
type: String,
|
|
@@ -21106,7 +21280,7 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
|
21106
21280
|
};
|
|
21107
21281
|
}
|
|
21108
21282
|
});
|
|
21109
|
-
const LewPagination = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["__scopeId", "data-v-
|
|
21283
|
+
const LewPagination = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["__scopeId", "data-v-e37e24d3"]]);
|
|
21110
21284
|
const magicNumberProps = {
|
|
21111
21285
|
value: {
|
|
21112
21286
|
type: Number,
|
|
@@ -21679,7 +21853,7 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
21679
21853
|
};
|
|
21680
21854
|
}
|
|
21681
21855
|
});
|
|
21682
|
-
const LewTree = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-
|
|
21856
|
+
const LewTree = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-86c0e774"]]);
|
|
21683
21857
|
const collapseModel = {
|
|
21684
21858
|
modelValue: {
|
|
21685
21859
|
type: [Array, String],
|
|
@@ -22342,8 +22516,8 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
22342
22516
|
const props2 = __props2;
|
|
22343
22517
|
const descItemRef = ref();
|
|
22344
22518
|
const getDescItemClassNames = computed(() => {
|
|
22345
|
-
const { direction, size } =
|
|
22346
|
-
return object2class("lew-desc-item", { direction, size });
|
|
22519
|
+
const { direction, size, bordered } = props2;
|
|
22520
|
+
return object2class("lew-desc-item", { direction, size, bordered });
|
|
22347
22521
|
});
|
|
22348
22522
|
const showTextAndEmpty = () => {
|
|
22349
22523
|
const text = retrieveNestedFieldValue(props2.dataSource, props2.field);
|
|
@@ -22381,30 +22555,50 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
22381
22555
|
const { bordered, size } = props2;
|
|
22382
22556
|
return bordered ? `${any2px(lewDescSizePaddingMap[size] - 10)} ${any2px(lewDescSizePaddingMap[size])}` : 0;
|
|
22383
22557
|
});
|
|
22384
|
-
|
|
22558
|
+
const getDescItemStyle = computed(() => {
|
|
22559
|
+
const { bordered, gridArea } = props2;
|
|
22560
|
+
return {
|
|
22561
|
+
gap: bordered ? 0 : any2px(getGap.value),
|
|
22562
|
+
"grid-area": gridArea || ""
|
|
22563
|
+
};
|
|
22564
|
+
});
|
|
22565
|
+
const getLabelBoxStyle = computed(() => {
|
|
22566
|
+
const { labelX } = props2;
|
|
22567
|
+
return {
|
|
22568
|
+
"justify-content": labelX === "center" ? labelX : `flex-${labelX}`,
|
|
22569
|
+
padding: getPadding.value
|
|
22570
|
+
};
|
|
22571
|
+
});
|
|
22572
|
+
const getDescItemMainStyle = computed(() => {
|
|
22385
22573
|
var _a2;
|
|
22574
|
+
const { direction, labelWidth, valueX } = props2;
|
|
22575
|
+
return {
|
|
22576
|
+
width: direction === "x" ? `calc(${(_a2 = descItemRef.value) == null ? void 0 : _a2.offsetWidth}px - ${any2px(labelWidth)} - 10px)` : "100%",
|
|
22577
|
+
"justify-content": valueX === "center" ? valueX : `flex-${valueX}`,
|
|
22578
|
+
padding: getPadding.value
|
|
22579
|
+
};
|
|
22580
|
+
});
|
|
22581
|
+
const getLabelBoxWidth = computed(() => {
|
|
22582
|
+
const { direction, labelWidth } = props2;
|
|
22583
|
+
return direction === "x" ? any2px(labelWidth) : "100%";
|
|
22584
|
+
});
|
|
22585
|
+
return (_ctx, _cache) => {
|
|
22386
22586
|
const _directive_tooltip = resolveDirective("tooltip");
|
|
22387
22587
|
return openBlock(), createElementBlock("div", {
|
|
22388
|
-
class: normalizeClass(["lew-desc-item",
|
|
22588
|
+
class: normalizeClass(["lew-desc-item", unref(getDescItemClassNames)]),
|
|
22389
22589
|
ref_key: "descItemRef",
|
|
22390
22590
|
ref: descItemRef,
|
|
22391
|
-
style: normalizeStyle(
|
|
22392
|
-
"grid-area": _ctx.gridArea || "",
|
|
22393
|
-
gap: _ctx.bordered ? 0 : unref(any2px)(unref(getGap))
|
|
22394
|
-
})
|
|
22591
|
+
style: normalizeStyle(unref(getDescItemStyle))
|
|
22395
22592
|
}, [
|
|
22396
22593
|
createElementVNode("div", {
|
|
22397
|
-
style: normalizeStyle(
|
|
22594
|
+
style: normalizeStyle(`width:${unref(getLabelBoxWidth)}`),
|
|
22398
22595
|
class: "lew-label-box-wrapper"
|
|
22399
22596
|
}, [
|
|
22400
22597
|
createElementVNode("div", {
|
|
22401
22598
|
class: "lew-label-box",
|
|
22402
|
-
style: normalizeStyle(
|
|
22403
|
-
"justify-content": _ctx.labelX === "center" ? _ctx.labelX : `flex-${_ctx.labelX}`,
|
|
22404
|
-
padding: unref(getPadding)
|
|
22405
|
-
})
|
|
22599
|
+
style: normalizeStyle(unref(getLabelBoxStyle))
|
|
22406
22600
|
}, [
|
|
22407
|
-
createTextVNode(toDisplayString(_ctx.label), 1),
|
|
22601
|
+
createTextVNode(toDisplayString(_ctx.label) + " ", 1),
|
|
22408
22602
|
_ctx.tips ? withDirectives((openBlock(), createBlock(Icon, {
|
|
22409
22603
|
key: 0,
|
|
22410
22604
|
class: "lew-label-tips-icon",
|
|
@@ -22419,11 +22613,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
22419
22613
|
], 4),
|
|
22420
22614
|
createElementVNode("div", {
|
|
22421
22615
|
class: "lew-desc-item-main",
|
|
22422
|
-
style: normalizeStyle(
|
|
22423
|
-
width: _ctx.direction === "x" ? `calc(${(_a2 = unref(descItemRef)) == null ? void 0 : _a2.offsetWidth}px - ${unref(any2px)(_ctx.labelWidth)} - 10px)` : "100%",
|
|
22424
|
-
justifyContent: _ctx.valueX === "center" ? _ctx.valueX : `flex-${_ctx.valueX}`,
|
|
22425
|
-
padding: unref(getPadding)
|
|
22426
|
-
})
|
|
22616
|
+
style: normalizeStyle(unref(getDescItemMainStyle))
|
|
22427
22617
|
}, [
|
|
22428
22618
|
createVNode(renderItem)
|
|
22429
22619
|
], 4)
|
|
@@ -22431,7 +22621,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
22431
22621
|
};
|
|
22432
22622
|
}
|
|
22433
22623
|
});
|
|
22434
|
-
const LewDescItem = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-
|
|
22624
|
+
const LewDescItem = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-25a1c7c1"]]);
|
|
22435
22625
|
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
22436
22626
|
__name: "LewDesc",
|
|
22437
22627
|
props: descProps,
|
|
@@ -22443,8 +22633,8 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
22443
22633
|
const autoLabelWidth = ref(0);
|
|
22444
22634
|
let componentOptions = cloneDeep(props2.options) || [];
|
|
22445
22635
|
const getDescClassNames = computed(() => {
|
|
22446
|
-
const { columns } =
|
|
22447
|
-
return object2class("lew-desc", { columns });
|
|
22636
|
+
const { columns, bordered } = props2;
|
|
22637
|
+
return object2class("lew-desc", { columns, bordered });
|
|
22448
22638
|
});
|
|
22449
22639
|
onMounted(() => {
|
|
22450
22640
|
var _a;
|
|
@@ -22460,14 +22650,30 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
22460
22650
|
});
|
|
22461
22651
|
}
|
|
22462
22652
|
);
|
|
22653
|
+
const getDescStyle = computed(() => {
|
|
22654
|
+
const { width, gap, bordered } = props2;
|
|
22655
|
+
return {
|
|
22656
|
+
width: any2px(width),
|
|
22657
|
+
minWidth: 320,
|
|
22658
|
+
gap: bordered ? 0 : any2px(gap)
|
|
22659
|
+
};
|
|
22660
|
+
});
|
|
22661
|
+
const getBind = computed(() => (item) => {
|
|
22662
|
+
const { direction, size, labelX, valueX, bordered, labelWidth } = props2;
|
|
22663
|
+
return {
|
|
22664
|
+
direction,
|
|
22665
|
+
size,
|
|
22666
|
+
labelX,
|
|
22667
|
+
valueX,
|
|
22668
|
+
bordered,
|
|
22669
|
+
labelWidth: labelWidth === "auto" ? autoLabelWidth.value || labelWidth : labelWidth,
|
|
22670
|
+
...item
|
|
22671
|
+
};
|
|
22672
|
+
});
|
|
22463
22673
|
return (_ctx, _cache) => {
|
|
22464
22674
|
return openBlock(), createElementBlock("div", {
|
|
22465
|
-
class: normalizeClass(["lew-desc",
|
|
22466
|
-
style: normalizeStyle(
|
|
22467
|
-
width: unref(any2px)(_ctx.width),
|
|
22468
|
-
minWidth: 320,
|
|
22469
|
-
gap: _ctx.bordered ? 0 : unref(any2px)(_ctx.gap)
|
|
22470
|
-
})
|
|
22675
|
+
class: normalizeClass(["lew-desc", unref(getDescClassNames)]),
|
|
22676
|
+
style: normalizeStyle(unref(getDescStyle))
|
|
22471
22677
|
}, [
|
|
22472
22678
|
createVNode(LewGetLabelWidth, {
|
|
22473
22679
|
ref_key: "descLabelRef",
|
|
@@ -22481,21 +22687,13 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
22481
22687
|
field: item.field,
|
|
22482
22688
|
"data-source": _ctx.dataSource,
|
|
22483
22689
|
ref_for: true
|
|
22484
|
-
},
|
|
22485
|
-
direction: _ctx.direction,
|
|
22486
|
-
size: _ctx.size,
|
|
22487
|
-
labelX: _ctx.labelX,
|
|
22488
|
-
valueX: _ctx.valueX,
|
|
22489
|
-
bordered: _ctx.bordered,
|
|
22490
|
-
labelWidth: _ctx.labelWidth === "auto" ? unref(autoLabelWidth) || _ctx.labelWidth : _ctx.labelWidth,
|
|
22491
|
-
...item
|
|
22492
|
-
}), null, 16, ["field", "data-source"]);
|
|
22690
|
+
}, unref(getBind)(item)), null, 16, ["field", "data-source"]);
|
|
22493
22691
|
}), 128))
|
|
22494
22692
|
], 6);
|
|
22495
22693
|
};
|
|
22496
22694
|
}
|
|
22497
22695
|
});
|
|
22498
|
-
const LewDesc = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__scopeId", "data-v-
|
|
22696
|
+
const LewDesc = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__scopeId", "data-v-bb1cd68d"]]);
|
|
22499
22697
|
const alertProps = {
|
|
22500
22698
|
type: {
|
|
22501
22699
|
type: String,
|
|
@@ -23883,7 +24081,7 @@ const LewTooltip = {
|
|
|
23883
24081
|
arrow: ROUND_ARROW,
|
|
23884
24082
|
maxWidth: 250,
|
|
23885
24083
|
duration: [250, 250],
|
|
23886
|
-
delay:
|
|
24084
|
+
delay: _trigger === "mouseenter" ? delay || [120, 120] : void 0
|
|
23887
24085
|
});
|
|
23888
24086
|
(_a = el.instance) == null ? void 0 : _a.popper.children[0].setAttribute("data-lew", "tooltip");
|
|
23889
24087
|
if (!((_b = binding == null ? void 0 : binding.value) == null ? void 0 : _b.content)) {
|
|
@@ -23893,7 +24091,7 @@ const LewTooltip = {
|
|
|
23893
24091
|
updated(el, binding) {
|
|
23894
24092
|
var _a, _b, _c, _d, _e;
|
|
23895
24093
|
const { triggerFrom, content } = binding.value;
|
|
23896
|
-
if (!content && content
|
|
24094
|
+
if (!content && content !== 0) {
|
|
23897
24095
|
(_a = el.instance) == null ? void 0 : _a.disable();
|
|
23898
24096
|
} else {
|
|
23899
24097
|
(_b = el.instance) == null ? void 0 : _b.enable();
|
|
@@ -24174,7 +24372,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
24174
24372
|
interactive: true,
|
|
24175
24373
|
placement: "right-start",
|
|
24176
24374
|
duration: [250, 250],
|
|
24177
|
-
delay: [
|
|
24375
|
+
delay: [120, 120],
|
|
24178
24376
|
arrow: false,
|
|
24179
24377
|
offset: [0, 0],
|
|
24180
24378
|
allowHTML: true,
|
|
@@ -24251,7 +24449,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
24251
24449
|
};
|
|
24252
24450
|
}
|
|
24253
24451
|
});
|
|
24254
|
-
const _LewContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-
|
|
24452
|
+
const _LewContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-189cc6df"]]);
|
|
24255
24453
|
const initLewHoverMenu = () => {
|
|
24256
24454
|
window.LewHoverMenu = {
|
|
24257
24455
|
menu: {},
|