@lingshugroup/web-plus 1.0.7 → 1.0.9
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/README.md +5 -1
- package/lib/index.css +1 -1
- package/lib/index.css.br +0 -0
- package/lib/index.css.gz +0 -0
- package/lib/node_modules/.pnpm/@vueuse_core@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/core/index/index.js +9 -9
- package/lib/node_modules/.pnpm/@vueuse_core@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/core/index/index.js.br +0 -0
- package/lib/node_modules/.pnpm/@vueuse_core@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/core/index/index.js.gz +0 -0
- package/lib/node_modules/.pnpm/@vueuse_shared@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/shared/index/index.js +6 -6
- package/lib/node_modules/.pnpm/@vueuse_shared@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/shared/index/index.js.br +0 -0
- package/lib/node_modules/.pnpm/@vueuse_shared@9.13.0_vue@3.4.38_typescript@5.5.4_/node_modules/@vueuse/shared/index/index.js.gz +0 -0
- package/lib/node_modules/.pnpm/element-plus@2.8.1_vue@3.4.38_typescript@5.5.4_/node_modules/element-plus/es/utils/dom/style/index.js +3 -3
- package/lib/node_modules/.pnpm/element-plus@2.8.1_vue@3.4.38_typescript@5.5.4_/node_modules/element-plus/es/utils/dom/style/index.js.br +0 -0
- package/lib/node_modules/.pnpm/element-plus@2.8.1_vue@3.4.38_typescript@5.5.4_/node_modules/element-plus/es/utils/dom/style/index.js.gz +0 -0
- package/lib/packages/ls-components/components/_directives/auth/index.cjs +1 -1
- package/lib/packages/ls-components/components/_directives/auth/index.js +25 -19
- package/lib/packages/ls-components/components/_directives/auth/index.js.br +0 -0
- package/lib/packages/ls-components/components/_directives/auth/index.js.gz +0 -0
- package/lib/packages/ls-components/components/_hooks/useDelayLoader/index.cjs +1 -0
- package/lib/packages/ls-components/components/_hooks/useDelayLoader/index.js +25 -0
- package/lib/packages/ls-components/components/_hooks/useTableListHook/index.cjs +1 -1
- package/lib/packages/ls-components/components/_hooks/useTableListHook/index.js +90 -49
- package/lib/packages/ls-components/components/_hooks/useTableListHook/index.js.br +0 -0
- package/lib/packages/ls-components/components/_hooks/useTableListHook/index.js.gz +0 -0
- package/lib/packages/ls-components/components/button/Button.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/button/Button.vue/index.js +1 -1
- package/lib/packages/ls-components/components/button/Button.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/button/Button.vue/index2.js +26 -24
- package/lib/packages/ls-components/components/button/Button.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/button/Button.vue/index2.js.gz +0 -0
- package/lib/packages/ls-components/components/dialog/Index.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/dialog/Index.vue/index.js +2 -2
- package/lib/packages/ls-components/components/dialog/Index.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/dialog/Index.vue/index2.js +43 -38
- package/lib/packages/ls-components/components/dialog/Index.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/dialog/Index.vue/index2.js.gz +0 -0
- package/lib/packages/ls-components/components/dialog/types/index.cjs +1 -1
- package/lib/packages/ls-components/components/dialog/types/index.js +8 -4
- package/lib/packages/ls-components/components/list/List.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/list/List.vue/index.js +1 -1
- package/lib/packages/ls-components/components/list/List.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/list/List.vue/index2.js +19 -19
- package/lib/packages/ls-components/components/list/List.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/list/List.vue/index2.js.gz +0 -0
- package/lib/packages/ls-components/components/list/types/index.cjs +1 -1
- package/lib/packages/ls-components/components/list/types/index.js +4 -0
- package/lib/packages/ls-components/components/list/types/index.js.br +0 -0
- package/lib/packages/ls-components/components/list/types/index.js.gz +0 -0
- package/lib/packages/ls-components/components/preview/Index.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/preview/Index.vue/index.js +1 -1
- package/lib/packages/ls-components/components/preview/Index.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/preview/Index.vue/index2.js +58 -55
- package/lib/packages/ls-components/components/preview/Index.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/preview/Index.vue/index2.js.gz +0 -0
- package/lib/packages/ls-components/components/table/Table.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/table/Table.vue/index.js +2 -2
- package/lib/packages/ls-components/components/table/Table.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/table/Table.vue/index2.js +24 -24
- package/lib/packages/ls-components/components/table/Table.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/table/Table.vue/index2.js.gz +0 -0
- package/lib/packages/ls-components/components/upload/Index.vue/index.cjs +1 -1
- package/lib/packages/ls-components/components/upload/Index.vue/index.js +2 -2
- package/lib/packages/ls-components/components/upload/Index.vue/index2.cjs +1 -1
- package/lib/packages/ls-components/components/upload/Index.vue/index2.js +99 -97
- package/lib/packages/ls-components/components/upload/Index.vue/index2.js.br +0 -0
- package/lib/packages/ls-components/components/upload/Index.vue/index2.js.gz +0 -0
- package/package.json +1 -1
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
var
|
|
2
|
-
var r = (w, O) =>
|
|
1
|
+
var xe = Object.defineProperty;
|
|
2
|
+
var r = (w, O) => xe(w, "name", { value: O, configurable: !0 });
|
|
3
3
|
/* empty css */
|
|
4
4
|
/* empty css */
|
|
5
5
|
/* empty css */
|
|
6
|
-
import { defineComponent as
|
|
7
|
-
import { lsUploadProps as
|
|
8
|
-
import { getVariable as
|
|
9
|
-
import { useNamespace as
|
|
6
|
+
import { defineComponent as Le, useSlots as Ue, useAttrs as Te, ref as ee, reactive as te, computed as u, watch as oe, resolveComponent as Ae, openBlock as c, createElementBlock as p, normalizeClass as V, unref as l, createVNode as Y, mergeProps as Ee, createSlots as $e, withCtx as h, Fragment as S, createBlock as b, createElementVNode as B, toDisplayString as D, createTextVNode as E, createCommentVNode as N, renderSlot as q, toRefs as ie, pushScopeId as Me, popScopeId as Re } from "vue";
|
|
7
|
+
import { lsUploadProps as ze, UPLOAD_TYPE_MAP as Ie, fileTypeMap as Ve, UPLOAD_STATUS_MAP as De, IMG_SUFFIX_LIST as Ne } from "../types/index.js";
|
|
8
|
+
import { getVariable as qe } from "../../_utils/config/index.js";
|
|
9
|
+
import { useNamespace as Be } from "../../_hooks/useNamespace/index.js";
|
|
10
10
|
import _ from "../../button/Button.vue/index.js";
|
|
11
11
|
import ne from "../../icon/Index.vue/index.js";
|
|
12
12
|
/* empty css */
|
|
13
13
|
/* empty css */
|
|
14
|
-
import
|
|
14
|
+
import Oe from "../../../../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/merge/index.js";
|
|
15
15
|
import { ElMessage as $ } from "../../../../../node_modules/.pnpm/element-plus@2.8.1_vue@3.4.38_typescript@5.5.4_/node_modules/element-plus/es/components/message/index/index.js";
|
|
16
|
-
import { ElUpload as
|
|
17
|
-
const
|
|
16
|
+
import { ElUpload as We } from "../../../../../node_modules/.pnpm/element-plus@2.8.1_vue@3.4.38_typescript@5.5.4_/node_modules/element-plus/es/components/upload/index/index.js";
|
|
17
|
+
const je = /* @__PURE__ */ r((w) => (Me("data-v-c1121064"), w = w(), Re(), w), "_withScopeId"), Ge = { class: "ls-drag" }, Xe = { class: "drag-txt ls-color-brand6" }, Ye = /* @__PURE__ */ je(() => /* @__PURE__ */ B("div", { class: "drag-txt ls-color-text2" }, "拖拽到此区域", -1)), He = {
|
|
18
18
|
key: 0,
|
|
19
19
|
class: "btn-picture-card"
|
|
20
|
-
},
|
|
20
|
+
}, Je = {
|
|
21
21
|
key: 0,
|
|
22
22
|
class: "ls-tip"
|
|
23
|
-
},
|
|
23
|
+
}, mt = /* @__PURE__ */ Le({
|
|
24
24
|
name: "LSUpload",
|
|
25
25
|
inheritAttrs: !1,
|
|
26
26
|
__name: "Index",
|
|
27
|
-
props:
|
|
27
|
+
props: ze,
|
|
28
28
|
emits: ["uploadErrorFunc", "onChangeFunc", "httpResponseFunc"],
|
|
29
|
-
setup(w, {
|
|
30
|
-
const M =
|
|
29
|
+
setup(w, { expose: O, emit: le }) {
|
|
30
|
+
const M = Ue(), x = Te(), se = Be("upload").b(), m = ee(), f = ee(!1), y = te({
|
|
31
31
|
isCover: !0,
|
|
32
32
|
accept: "",
|
|
33
33
|
disabled: f
|
|
@@ -37,8 +37,8 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
37
37
|
showPreview: !1,
|
|
38
38
|
typePreview: "",
|
|
39
39
|
sourcePreview: "",
|
|
40
|
-
iconColor:
|
|
41
|
-
}), o = w, R =
|
|
40
|
+
iconColor: qe("colorText1")
|
|
41
|
+
}), o = w, R = le, L = u(() => {
|
|
42
42
|
var e, t;
|
|
43
43
|
return (((e = o == null ? void 0 : o.item) == null ? void 0 : e.isToast) || typeof ((t = o == null ? void 0 : o.item) == null ? void 0 : t.isToast)) === "undefined";
|
|
44
44
|
}), F = u(() => {
|
|
@@ -48,22 +48,22 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
48
48
|
}), k = u(() => x.multiple), C = u(() => {
|
|
49
49
|
const e = x["auto-upload"];
|
|
50
50
|
return typeof e > "u" ? !0 : e;
|
|
51
|
-
}),
|
|
51
|
+
}), re = u(() => {
|
|
52
52
|
var e;
|
|
53
53
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.emptyFileMsg) || "";
|
|
54
|
-
}),
|
|
54
|
+
}), ae = u(() => x["list-type"]), P = u(() => ae.value === Ie.picCard), U = u(() => {
|
|
55
55
|
var e;
|
|
56
56
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.limitFile) || [];
|
|
57
|
-
}),
|
|
57
|
+
}), ue = u(() => {
|
|
58
58
|
var e;
|
|
59
59
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.limitFileMsg) || "";
|
|
60
60
|
}), W = u(() => {
|
|
61
61
|
var e;
|
|
62
62
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.limitSize) || 2;
|
|
63
|
-
}),
|
|
63
|
+
}), ce = u(() => {
|
|
64
64
|
var e;
|
|
65
65
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.limitSizeMsg) || "";
|
|
66
|
-
}),
|
|
66
|
+
}), fe = u(() => {
|
|
67
67
|
var e;
|
|
68
68
|
return ((e = o == null ? void 0 : o.item) == null ? void 0 : e.limitNumMsg) || "";
|
|
69
69
|
}), H = u(() => {
|
|
@@ -73,7 +73,7 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
73
73
|
const e = P.value ? "图片" : "文件";
|
|
74
74
|
let t = `选择${e}`;
|
|
75
75
|
return f.value ? t = "正在上传..." : F.value && !k.value ? C.value ? n.initUploadStatus ? t = "点击上传" : t = "重新上传" : n.initUploadStatus ? t = `选择${e}` : t = "重新上传" : C.value && (t = "点击上传"), t;
|
|
76
|
-
}),
|
|
76
|
+
}), de = u(() => {
|
|
77
77
|
let e = "不限制上传格式,";
|
|
78
78
|
return P.value && (e = "文件须为图片格式,"), `${e}文件大小不超过${W.value}M`;
|
|
79
79
|
}), G = u(() => {
|
|
@@ -86,7 +86,7 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
86
86
|
oe(
|
|
87
87
|
[F, G],
|
|
88
88
|
([e, t]) => {
|
|
89
|
-
y.isCover = e, t && t instanceof Function && (y["http-request"] =
|
|
89
|
+
y.isCover = e, t && t instanceof Function && (y["http-request"] = Pe);
|
|
90
90
|
},
|
|
91
91
|
{
|
|
92
92
|
immediate: !0,
|
|
@@ -95,20 +95,20 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
95
95
|
), oe(
|
|
96
96
|
() => U.value,
|
|
97
97
|
(e) => {
|
|
98
|
-
e && e.length > 0 &&
|
|
98
|
+
e && e.length > 0 && me(e);
|
|
99
99
|
},
|
|
100
100
|
{
|
|
101
101
|
immediate: !0,
|
|
102
102
|
deep: !0
|
|
103
103
|
}
|
|
104
104
|
);
|
|
105
|
-
function
|
|
105
|
+
function me(e) {
|
|
106
106
|
y.accept = "", e.forEach((t) => {
|
|
107
|
-
const i =
|
|
107
|
+
const i = Ve[t] || "";
|
|
108
108
|
i && (y.accept && (y.accept += ","), y.accept += i);
|
|
109
109
|
});
|
|
110
110
|
}
|
|
111
|
-
r(
|
|
111
|
+
r(me, "updateFileAccept");
|
|
112
112
|
function A(e) {
|
|
113
113
|
const { formRuleFunc: t, formValidateFunc: i } = ie(o == null ? void 0 : o.item);
|
|
114
114
|
if (t && t.value instanceof Function && i && i.value instanceof Function) {
|
|
@@ -118,16 +118,16 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
118
118
|
R("uploadErrorFunc", e);
|
|
119
119
|
}
|
|
120
120
|
r(A, "validateForm");
|
|
121
|
-
function
|
|
121
|
+
function ve(e, t) {
|
|
122
122
|
if (f.value = !1, o.onExceed)
|
|
123
123
|
return o.onExceed(e, t);
|
|
124
|
-
const i = `当前限制选择 ${x.limit} 个文件,本次选择了 ${e.length} 个文件,共选择了 ${e.length + t.length} 个文件` ||
|
|
124
|
+
const i = `当前限制选择 ${x.limit} 个文件,本次选择了 ${e.length} 个文件,共选择了 ${e.length + t.length} 个文件` || fe.value;
|
|
125
125
|
L.value ? setTimeout(() => {
|
|
126
126
|
$.warning(i);
|
|
127
127
|
}, 200) : A(i);
|
|
128
128
|
}
|
|
129
|
-
r(
|
|
130
|
-
function
|
|
129
|
+
r(ve, "onExceedAction");
|
|
130
|
+
function pe(e) {
|
|
131
131
|
if (o.beforeUpload) {
|
|
132
132
|
const i = o.beforeUpload(e);
|
|
133
133
|
return i && F.value && !k.value && I(), i;
|
|
@@ -135,23 +135,23 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
135
135
|
const t = X(e, !0);
|
|
136
136
|
return t && C.value && F.value && !k.value && I(), t;
|
|
137
137
|
}
|
|
138
|
-
r(
|
|
138
|
+
r(pe, "beforeUploadAction");
|
|
139
139
|
function X(e, t) {
|
|
140
140
|
let i = !0;
|
|
141
|
-
const { size: s, name: a } = e, d = U.value.length > 0 && !J(a),
|
|
141
|
+
const { size: s, name: a } = e, d = U.value.length > 0 && !J(a), v = s / 1024 / 1024 > W.value;
|
|
142
142
|
if (d) {
|
|
143
|
-
const g =
|
|
143
|
+
const g = ue.value || `上传文件 ${e.name} 只能是 ${U.value.filter((_e) => _e).join(",").toLocaleLowerCase()} 格式!`;
|
|
144
144
|
L.value && t ? setTimeout(() => {
|
|
145
145
|
$.error(g);
|
|
146
146
|
}, 200) : A(g), i = !1;
|
|
147
147
|
}
|
|
148
|
-
if (
|
|
149
|
-
const g =
|
|
148
|
+
if (v) {
|
|
149
|
+
const g = ce.value || `上传文件 ${e.name} 大小不能超过 ${W.value}MB!`;
|
|
150
150
|
L.value && t ? setTimeout(() => {
|
|
151
151
|
$.error(g);
|
|
152
152
|
}, 200) : A(g), i = !1;
|
|
153
153
|
}
|
|
154
|
-
if (P.value && !J(a,
|
|
154
|
+
if (P.value && !J(a, Ne)) {
|
|
155
155
|
const g = `上传文件 ${e.name} 不是图片格式的文件!`;
|
|
156
156
|
L.value && t ? setTimeout(() => {
|
|
157
157
|
$.error(g);
|
|
@@ -176,7 +176,7 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
176
176
|
n.uploadFileList.splice(e || 0, t || n.uploadFileList.length - 1);
|
|
177
177
|
}
|
|
178
178
|
r(I, "updateCoverFileList");
|
|
179
|
-
function
|
|
179
|
+
function ge(e, t) {
|
|
180
180
|
n.uploadFileList = t;
|
|
181
181
|
const i = e.raw && X(e.raw, !C.value);
|
|
182
182
|
if (i && F.value && !k.value && I(), o.onChange)
|
|
@@ -184,47 +184,47 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
184
184
|
const { size: s } = e;
|
|
185
185
|
if (s <= 0) {
|
|
186
186
|
K();
|
|
187
|
-
const a =
|
|
187
|
+
const a = re.value || "禁止上传空文件,请检查后重新上传!";
|
|
188
188
|
L.value ? $.error(a) : A(a);
|
|
189
189
|
return;
|
|
190
190
|
}
|
|
191
191
|
e.raw && (!C.value && !i ? K() : (e.blob = URL.createObjectURL(e.raw) || "", R("onChangeFunc", e)));
|
|
192
192
|
}
|
|
193
|
-
r(
|
|
193
|
+
r(ge, "onChangeAction");
|
|
194
194
|
function K() {
|
|
195
195
|
let e = 0;
|
|
196
196
|
n.uploadFileList.length > 1 && (e = n.uploadFileList.length - 1), I(e, 1), R("onChangeFunc", {});
|
|
197
197
|
}
|
|
198
198
|
r(K, "setChangeRes");
|
|
199
|
-
function
|
|
199
|
+
function he(e, t, i) {
|
|
200
200
|
f.value = !1, n.initUploadStatus = !1;
|
|
201
201
|
const { formRuleFunc: s, formValidateFunc: a } = ie(o == null ? void 0 : o.item);
|
|
202
202
|
if (s && s.value instanceof Function && a && a.value instanceof Function && a.value(), o.onSuccess)
|
|
203
203
|
return o.onSuccess(e, t, i);
|
|
204
204
|
}
|
|
205
|
-
r(
|
|
206
|
-
function
|
|
205
|
+
r(he, "onSuccessAction");
|
|
206
|
+
function we(e, t, i) {
|
|
207
207
|
if (f.value = !1, o.onError)
|
|
208
208
|
return o.onError(e, t, i);
|
|
209
209
|
}
|
|
210
|
-
r(
|
|
211
|
-
function
|
|
210
|
+
r(we, "onErrorAction");
|
|
211
|
+
function ye(e, t) {
|
|
212
212
|
if (n.initUploadStatus = !t.length, o.onRemove)
|
|
213
213
|
return o.onRemove(e, t);
|
|
214
214
|
}
|
|
215
|
-
r(
|
|
216
|
-
function
|
|
215
|
+
r(ye, "onRemoveAction");
|
|
216
|
+
function Fe(e) {
|
|
217
217
|
if (o.onPreview)
|
|
218
218
|
return o.onPreview(e);
|
|
219
219
|
const { raw: t, url: i, blob: s, name: a } = e, { type: d } = t || {};
|
|
220
|
-
t ? T.value && T.value.length > 0 ? d != null && d.startsWith("image") ? (n.typePreview = "image", n.sourcePreview = P.value ? [i] : [s], n.showPreview = !0) : T.value.includes("pdf") && d == "application/pdf" ? (n.typePreview = "pdf", n.sourcePreview = s, n.showPreview = !0) : T.value.includes("xlsx") && ["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"].includes(d) ? (n.typePreview = "xlsx", fetch(s).then((
|
|
221
|
-
n.sourcePreview = new File([
|
|
222
|
-
})) : T.value.includes("docx") && d == "application/vnd.openxmlformats-officedocument.wordprocessingml.document" && (n.typePreview = "docx", fetch(s).then((
|
|
223
|
-
n.sourcePreview =
|
|
220
|
+
t ? T.value && T.value.length > 0 ? d != null && d.startsWith("image") ? (n.typePreview = "image", n.sourcePreview = P.value ? [i] : [s], n.showPreview = !0) : T.value.includes("pdf") && d == "application/pdf" ? (n.typePreview = "pdf", n.sourcePreview = s, n.showPreview = !0) : T.value.includes("xlsx") && ["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"].includes(d) ? (n.typePreview = "xlsx", fetch(s).then((v) => v.blob()).then((v) => {
|
|
221
|
+
n.sourcePreview = new File([v], a, { type: d }), n.showPreview = !0;
|
|
222
|
+
})) : T.value.includes("docx") && d == "application/vnd.openxmlformats-officedocument.wordprocessingml.document" && (n.typePreview = "docx", fetch(s).then((v) => v.blob()).then((v) => v.arrayBuffer()).then((v) => {
|
|
223
|
+
n.sourcePreview = v, n.showPreview = !0;
|
|
224
224
|
})) : P.value && d != null && d.startsWith("image") && (n.typePreview = "image", n.sourcePreview = [i], n.showPreview = !0) : P.value && (n.typePreview = "image", n.sourcePreview = [i], n.showPreview = !0);
|
|
225
225
|
}
|
|
226
|
-
r(
|
|
227
|
-
async function
|
|
226
|
+
r(Fe, "onPreviewAction");
|
|
227
|
+
async function Pe(e) {
|
|
228
228
|
const { file: t } = e;
|
|
229
229
|
if (!t)
|
|
230
230
|
return;
|
|
@@ -246,11 +246,11 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
246
246
|
}
|
|
247
247
|
}
|
|
248
248
|
}
|
|
249
|
-
r(
|
|
249
|
+
r(Pe, "httpRequestAction");
|
|
250
250
|
function Q() {
|
|
251
251
|
let e = !1;
|
|
252
252
|
for (let t = 0; t < n.uploadFileList.length; t++)
|
|
253
|
-
if (n.uploadFileList[t].status ===
|
|
253
|
+
if (n.uploadFileList[t].status === De.ready) {
|
|
254
254
|
e = !0;
|
|
255
255
|
break;
|
|
256
256
|
}
|
|
@@ -259,53 +259,55 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
259
259
|
r(Q, "hasReadyFile");
|
|
260
260
|
function Z() {
|
|
261
261
|
var e;
|
|
262
|
-
(e =
|
|
262
|
+
(e = m == null ? void 0 : m.value) == null || e.submit();
|
|
263
263
|
}
|
|
264
264
|
r(Z, "comfirmUpload");
|
|
265
|
-
function
|
|
266
|
-
|
|
265
|
+
function Se(e) {
|
|
266
|
+
m == null || m.value.handleRemove(e);
|
|
267
267
|
}
|
|
268
|
-
r(
|
|
269
|
-
function
|
|
268
|
+
r(Se, "removeFile");
|
|
269
|
+
function be() {
|
|
270
270
|
n.uploadFileList.forEach((e) => {
|
|
271
271
|
var t;
|
|
272
272
|
if (e)
|
|
273
273
|
try {
|
|
274
|
-
(t =
|
|
274
|
+
(t = m == null ? void 0 : m.value) == null || t.abort(e), Se(e);
|
|
275
275
|
} catch {
|
|
276
276
|
}
|
|
277
277
|
});
|
|
278
278
|
}
|
|
279
|
-
r(
|
|
280
|
-
function
|
|
279
|
+
r(be, "cancelUpload");
|
|
280
|
+
function ke() {
|
|
281
281
|
f.value = !0;
|
|
282
282
|
}
|
|
283
|
-
r(
|
|
284
|
-
function
|
|
283
|
+
r(ke, "onProgressAction");
|
|
284
|
+
function Ce() {
|
|
285
285
|
n.showPreview = !1, n.sourcePreview = "";
|
|
286
286
|
}
|
|
287
|
-
return r(
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
287
|
+
return r(Ce, "closePreview"), O({
|
|
288
|
+
uploadRef: m
|
|
289
|
+
}), (e, t) => {
|
|
290
|
+
const i = We, s = Ae("LSPreview");
|
|
291
|
+
return c(), p("div", {
|
|
292
|
+
class: V([l(se), l(z) ? "ls-upload-drag" : "", l(H) ? "ls-profile" : ""])
|
|
291
293
|
}, [
|
|
292
|
-
Y(i,
|
|
294
|
+
Y(i, Ee({
|
|
293
295
|
ref_key: "uploadRef",
|
|
294
|
-
ref:
|
|
295
|
-
}, l(
|
|
296
|
-
"on-exceed":
|
|
297
|
-
"before-upload":
|
|
298
|
-
"on-change":
|
|
299
|
-
"on-success":
|
|
300
|
-
"on-error":
|
|
301
|
-
"on-remove":
|
|
302
|
-
"on-preview":
|
|
303
|
-
"on-progress":
|
|
304
|
-
}),
|
|
296
|
+
ref: m
|
|
297
|
+
}, l(Oe)(l(y), e.$attrs), {
|
|
298
|
+
"on-exceed": ve,
|
|
299
|
+
"before-upload": pe,
|
|
300
|
+
"on-change": ge,
|
|
301
|
+
"on-success": he,
|
|
302
|
+
"on-error": we,
|
|
303
|
+
"on-remove": ye,
|
|
304
|
+
"on-preview": Fe,
|
|
305
|
+
"on-progress": ke
|
|
306
|
+
}), $e({
|
|
305
307
|
trigger: h(() => [
|
|
306
|
-
l(H) ? N("", !0) : (c(),
|
|
307
|
-
l(M).trigger ? q(e.$slots, "trigger", { key: 1 }, void 0, !0) : (c(),
|
|
308
|
-
l(z) ? (c(),
|
|
308
|
+
l(H) ? N("", !0) : (c(), p(S, { key: 0 }, [
|
|
309
|
+
l(M).trigger ? q(e.$slots, "trigger", { key: 1 }, void 0, !0) : (c(), p(S, { key: 0 }, [
|
|
310
|
+
l(z) ? (c(), p(S, { key: 0 }, [
|
|
309
311
|
l(f) ? (c(), b(_, {
|
|
310
312
|
key: 0,
|
|
311
313
|
text: "",
|
|
@@ -317,15 +319,15 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
317
319
|
size: "56",
|
|
318
320
|
color: "#E7E7E7"
|
|
319
321
|
})),
|
|
320
|
-
B("div",
|
|
321
|
-
B("div",
|
|
322
|
-
l(f) ? N("", !0) : (c(),
|
|
322
|
+
B("div", Ge, [
|
|
323
|
+
B("div", Xe, D(l(j)), 1),
|
|
324
|
+
l(f) ? N("", !0) : (c(), p(S, { key: 0 }, [
|
|
323
325
|
E(" / "),
|
|
324
|
-
|
|
326
|
+
Ye
|
|
325
327
|
], 64))
|
|
326
328
|
])
|
|
327
|
-
], 64)) : (c(),
|
|
328
|
-
l(P) ? (c(),
|
|
329
|
+
], 64)) : (c(), p(S, { key: 1 }, [
|
|
330
|
+
l(P) ? (c(), p("div", He, [
|
|
329
331
|
l(f) ? (c(), b(_, {
|
|
330
332
|
key: 0,
|
|
331
333
|
text: "",
|
|
@@ -354,16 +356,16 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
354
356
|
], 64))
|
|
355
357
|
]),
|
|
356
358
|
default: h(() => [
|
|
357
|
-
l(M).default ? q(e.$slots, "default", { key: 1 }, void 0, !0) : (c(),
|
|
358
|
-
l(C) ? N("", !0) : (c(),
|
|
359
|
+
l(M).default ? q(e.$slots, "default", { key: 1 }, void 0, !0) : (c(), p(S, { key: 0 }, [
|
|
360
|
+
l(C) ? N("", !0) : (c(), p("div", {
|
|
359
361
|
key: 0,
|
|
360
362
|
class: V(["upload-btn-handle", [l(z) ? "drag-css" : "nor-css", !l(F) || l(k) ? "multi-css" : ""]])
|
|
361
363
|
}, [
|
|
362
|
-
l(z) ? (c(),
|
|
364
|
+
l(z) ? (c(), p(S, { key: 1 }, [
|
|
363
365
|
!l(F) || l(k) ? (c(), b(_, {
|
|
364
366
|
key: 0,
|
|
365
367
|
type: "primary",
|
|
366
|
-
onClick:
|
|
368
|
+
onClick: be,
|
|
367
369
|
class: "ls-upload-btn-com ls-upload-btn-cancel"
|
|
368
370
|
}, {
|
|
369
371
|
default: h(() => [
|
|
@@ -398,7 +400,7 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
398
400
|
], 64))
|
|
399
401
|
]),
|
|
400
402
|
tip: h(() => [
|
|
401
|
-
l(M).tip ? q(e.$slots, "tip", { key: 1 }, void 0, !0) : (c(),
|
|
403
|
+
l(M).tip ? q(e.$slots, "tip", { key: 1 }, void 0, !0) : (c(), p("div", Je, D(l(de)), 1))
|
|
402
404
|
]),
|
|
403
405
|
_: 2
|
|
404
406
|
}, [
|
|
@@ -413,7 +415,7 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
413
415
|
Y(s, {
|
|
414
416
|
modelValue: l(n).showPreview,
|
|
415
417
|
"onUpdate:modelValue": t[0] || (t[0] = (a) => l(n).showPreview = a),
|
|
416
|
-
"on-close":
|
|
418
|
+
"on-close": Ce,
|
|
417
419
|
type: l(n).typePreview,
|
|
418
420
|
source: l(n).sourcePreview
|
|
419
421
|
}, null, 8, ["modelValue", "type", "source"])
|
|
@@ -422,5 +424,5 @@ const We = /* @__PURE__ */ r((w) => ($e("data-v-12b1af67"), w = w(), Me(), w), "
|
|
|
422
424
|
}
|
|
423
425
|
});
|
|
424
426
|
export {
|
|
425
|
-
|
|
427
|
+
mt as default
|
|
426
428
|
};
|
|
Binary file
|
|
Binary file
|