@dazhicheng/ui 1.6.65 → 1.6.67
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/assets/svg/download.svg.js +1 -1
- package/dist/components/tt-area/TtArea.vue.js +1 -1
- package/dist/components/tt-button/index.d.ts +28 -28
- package/dist/components/tt-button/index.vue.d.ts +16 -16
- package/dist/components/tt-custom-export-modal/src/assets/search.svg.js +5 -5
- package/dist/components/tt-custom-export-modal/src/assets/star.svg.js +3 -3
- package/dist/components/tt-custom-export-modal/src/assets/trash.svg.js +7 -7
- package/dist/components/tt-custom-export-modal/src/components/FieldGridSection.vue.js +1 -1
- package/dist/components/tt-drawer/index.d.ts +109 -109
- package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +60 -60
- package/dist/components/tt-drawer/src/components/DrawerHeader.vue.js +2 -2
- package/dist/components/tt-empty/index.d.ts +4 -4
- package/dist/components/tt-form/src/components/ExpandableArrow.vue2.js +1 -1
- package/dist/components/tt-form/src/components/FormElInput.vue.d.ts +10 -10
- package/dist/components/tt-icon/index.vue.js +2 -2
- package/dist/components/tt-image/index.d.ts +29 -29
- package/dist/components/tt-image/src/components/ImageViewer.d.ts +20 -20
- package/dist/components/tt-image/tt-image.d.ts +29 -29
- package/dist/components/tt-input-textarea/index.vue.d.ts +40 -40
- package/dist/components/tt-loading/src/loading.vue.js +2 -2
- package/dist/components/tt-modal/index.d.ts +150 -150
- package/dist/components/tt-modal/src/RenderModal.vue.d.ts +42 -42
- package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +17 -17
- package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.d.ts +5 -5
- package/dist/components/tt-panel-select/src/index.vue.d.ts +5 -5
- package/dist/components/tt-upload/index.d.ts +60 -60
- package/dist/components/tt-upload/src/TtUpload.vue.d.ts +37 -37
- package/dist/components/tt-upload/src/TtUpload.vue.js +87 -87
- package/dist/components/tt-upload/src/typing.d.ts +17 -17
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as fe, mergeModels as
|
|
1
|
+
import { defineComponent as fe, mergeModels as R, useModel as me, useSlots as we, ref as $, computed as m, createBlock as ve, openBlock as _e, createVNode as r, mergeProps as ye, createTextVNode as w } from "vue";
|
|
2
2
|
import ge from "../../../assets/svg/exportSvg.svg.js";
|
|
3
|
-
import
|
|
3
|
+
import B from "../../../assets/svg/fileSvg.svg.js";
|
|
4
4
|
import { TtButton as k } from "../../tt-button/index.js";
|
|
5
5
|
import { TtIcon as b } from "../../tt-icon/index.js";
|
|
6
6
|
import "../../tt-modal/index.js";
|
|
@@ -19,43 +19,43 @@ import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/aes.j
|
|
|
19
19
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/enc-utf8.js";
|
|
20
20
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/mode-ecb.js";
|
|
21
21
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/pad-pkcs7.js";
|
|
22
|
-
import { omit as Te, isFunction as
|
|
22
|
+
import { omit as Te, isFunction as M } from "lodash-es";
|
|
23
23
|
import "vue-router";
|
|
24
|
-
import { TtText as
|
|
24
|
+
import { TtText as z } from "../../tt-text/index.js";
|
|
25
25
|
/* empty css */
|
|
26
|
-
import { ttUploadProps as
|
|
26
|
+
import { ttUploadProps as Ce } from "./typing.js";
|
|
27
27
|
import { GlobalConfig as T } from "../../../hooks/useSetup.js";
|
|
28
|
-
import { getFileUrlOss as
|
|
28
|
+
import { getFileUrlOss as Se } from "../../../api/oss.js";
|
|
29
29
|
import { useModalRender as xe } from "../../tt-modal/src/hooks/useModalRender.js";
|
|
30
|
-
const
|
|
30
|
+
const no = /* @__PURE__ */ fe({
|
|
31
31
|
name: "TtUpload",
|
|
32
32
|
__name: "TtUpload",
|
|
33
|
-
props: /* @__PURE__ */
|
|
33
|
+
props: /* @__PURE__ */ R(Ce, {
|
|
34
34
|
modelValue: {
|
|
35
35
|
default: () => []
|
|
36
36
|
},
|
|
37
37
|
modelModifiers: {}
|
|
38
38
|
}),
|
|
39
|
-
emits: /* @__PURE__ */
|
|
40
|
-
setup(
|
|
41
|
-
expose:
|
|
42
|
-
emit:
|
|
39
|
+
emits: /* @__PURE__ */ R(["afterUpload", "preview", "download", "delete", "templateDownload", "ok", "close", "error"], ["update:modelValue"]),
|
|
40
|
+
setup(C, {
|
|
41
|
+
expose: I,
|
|
42
|
+
emit: P
|
|
43
43
|
}) {
|
|
44
|
-
const
|
|
45
|
-
function
|
|
44
|
+
const V = ["modal", "modelValue", "ossType", "uploadOssApi", "uploadTip", "maxSize", "showFileList", "showUploadArea", "showTemplateDownload", "templateText", "showPreview", "showDownload", "showDelete", "gridThreshold", "gridColumns", "showCount", "uploadOssViewApi", "beforeUpload", "onError"], N = /* @__PURE__ */ new Set(["jpg", "jpeg", "png", "gif", "webp", "bmp", "svg"]);
|
|
45
|
+
function D(e) {
|
|
46
46
|
var t;
|
|
47
47
|
const o = ((t = e.split(".").pop()) == null ? void 0 : t.toLowerCase()) || "";
|
|
48
|
-
return
|
|
48
|
+
return N.has(o);
|
|
49
49
|
}
|
|
50
50
|
function K(e, o, t) {
|
|
51
|
-
var
|
|
51
|
+
var a;
|
|
52
52
|
if (!(t != null && t.trim())) return !0;
|
|
53
|
-
const l = e.includes(".") ? ((
|
|
53
|
+
const l = e.includes(".") ? ((a = e.split(".").pop()) == null ? void 0 : a.toLowerCase()) ?? "" : "";
|
|
54
54
|
return t.split(",").map((c) => c.trim()).filter(Boolean).some((c) => c.startsWith(".") ? l === c.slice(1).toLowerCase() : c.endsWith("/*") ? o.startsWith(c.slice(0, -1)) : o === c);
|
|
55
55
|
}
|
|
56
|
-
const
|
|
56
|
+
const n = C, p = P, u = me(C, "modelValue"), d = we(), {
|
|
57
57
|
prefixCls: i
|
|
58
|
-
} = he("upload"),
|
|
58
|
+
} = he("upload"), S = $(), h = $(!1), x = $([]), [j, v] = xe({
|
|
59
59
|
onOk() {
|
|
60
60
|
p("ok", u.value);
|
|
61
61
|
},
|
|
@@ -66,38 +66,38 @@ const ao = /* @__PURE__ */ fe({
|
|
|
66
66
|
function W() {
|
|
67
67
|
return [...u.value];
|
|
68
68
|
}
|
|
69
|
-
|
|
69
|
+
I({
|
|
70
70
|
openModal: () => {
|
|
71
|
-
|
|
71
|
+
n.showUploadArea && (u.value = []), v.openModal();
|
|
72
72
|
},
|
|
73
73
|
setModalProps: v.setModalProps,
|
|
74
74
|
closeModal: v.closeModal,
|
|
75
75
|
getFileList: W
|
|
76
76
|
});
|
|
77
|
-
const U = m(() => u.value.length >
|
|
77
|
+
const U = m(() => u.value.length > n.gridThreshold), _ = m(() => n.limit ?? 0), y = m(() => n.uploadOssApi ?? T.uploadOssApi), G = m(() => n.uploadOssViewApi ?? T.uploadOssViewApi ?? Se);
|
|
78
78
|
async function q(e, o) {
|
|
79
|
-
const l = (
|
|
80
|
-
|
|
79
|
+
const l = (n.ossDir || o.dir || "notice").replace(/\/+$/, ""), s = l ? `${l}/${Date.now()}_${e.name}` : `${Date.now()}_${e.name}`, a = new FormData();
|
|
80
|
+
a.append("key", s), a.append("policy", o.policy), a.append("x-oss-signature-version", o.version), a.append("x-oss-signature", o.signature), a.append("x-oss-credential", o.x_oss_credential), a.append("x-oss-date", o.x_oss_date), a.append("x-oss-security-token", o.security_token), o.callback && a.append("callback", o.callback), a.append("success_action_status", "200"), a.append("file", e);
|
|
81
81
|
const c = await fetch(o.host, {
|
|
82
82
|
method: "POST",
|
|
83
|
-
body:
|
|
83
|
+
body: a
|
|
84
84
|
});
|
|
85
85
|
if (!c.ok && c.status !== 203 && c.status !== 200)
|
|
86
86
|
throw new Error(`OSS 上传失败: ${c.status}`);
|
|
87
87
|
return s;
|
|
88
88
|
}
|
|
89
89
|
async function H(e, o) {
|
|
90
|
-
const l = (
|
|
91
|
-
|
|
90
|
+
const l = (n.ossDir || o.dir || "notice").replace(/\/+$/, ""), s = l ? `${l}/${Date.now()}_${encodeURIComponent(e.name)}` : `${Date.now()}_${encodeURIComponent(e.name)}`, a = new FormData();
|
|
91
|
+
a.append("key", s), a.append("policy", o.policy), a.append("AccessKeyId", o.accessKeyId), a.append("signature", o.signature), o.security_token && a.append("x-obs-security-token", o.security_token), o.callbackUrl && a.append("callbackUrl", o.callbackUrl), o.callbackBody && a.append("callbackBody", o.callbackBody), o.callbackBodyType && a.append("callbackBodyType", o.callbackBodyType), a.append("success_action_status", "200"), a.append("file", e);
|
|
92
92
|
const c = await fetch(o.host, {
|
|
93
93
|
method: "POST",
|
|
94
|
-
body:
|
|
94
|
+
body: a
|
|
95
95
|
});
|
|
96
96
|
if (!c.ok && c.status !== 204 && c.status !== 200)
|
|
97
97
|
throw new Error(`OBS 上传失败: ${c.status}`);
|
|
98
98
|
return s;
|
|
99
99
|
}
|
|
100
|
-
const X = m(() =>
|
|
100
|
+
const X = m(() => n.ossType ?? T.ossType ?? "huawei");
|
|
101
101
|
async function Y(e, o) {
|
|
102
102
|
return X.value === "aliyun" ? q(e, o) : H(e, o);
|
|
103
103
|
}
|
|
@@ -131,14 +131,14 @@ const ao = /* @__PURE__ */ fe({
|
|
|
131
131
|
var t;
|
|
132
132
|
const o = y.value;
|
|
133
133
|
try {
|
|
134
|
-
const l = await o(e.file), s = await Y(e.file, l),
|
|
134
|
+
const l = await o(e.file), s = await Y(e.file, l), a = n.ossDir || l.dir, c = {
|
|
135
135
|
fileName: e.file.name,
|
|
136
136
|
fileSize: e.file.size ?? 0,
|
|
137
137
|
fileSuffix: ((t = e.file.name.split(".").pop()) == null ? void 0 : t.toLowerCase()) || "",
|
|
138
138
|
file: e.file,
|
|
139
139
|
uid: e.file.uid,
|
|
140
140
|
ossKey: s,
|
|
141
|
-
ossUploadBaseDir:
|
|
141
|
+
ossUploadBaseDir: a
|
|
142
142
|
};
|
|
143
143
|
return u.value = [...u.value, c], f.success("上传成功"), p("afterUpload", c, s), e.onSuccess(c), c;
|
|
144
144
|
} catch (l) {
|
|
@@ -147,10 +147,10 @@ const ao = /* @__PURE__ */ fe({
|
|
|
147
147
|
}
|
|
148
148
|
function Z(e, o, t) {
|
|
149
149
|
var l;
|
|
150
|
-
o.raw && (O(o.raw), p("error", e, o.raw)), (l =
|
|
150
|
+
o.raw && (O(o.raw), p("error", e, o.raw)), (l = n.onError) == null || l.call(n, e, o, t);
|
|
151
151
|
}
|
|
152
152
|
const ee = m(() => ({
|
|
153
|
-
...Te(
|
|
153
|
+
...Te(n, V),
|
|
154
154
|
showFileList: !1,
|
|
155
155
|
beforeUpload: oe,
|
|
156
156
|
onExceed: te,
|
|
@@ -160,10 +160,10 @@ const ao = /* @__PURE__ */ fe({
|
|
|
160
160
|
httpRequest: y.value ? Q : J
|
|
161
161
|
}));
|
|
162
162
|
function oe(e) {
|
|
163
|
-
if (!K(e.name, e.type,
|
|
164
|
-
return f.warning(`文件格式不支持,仅支持:${
|
|
163
|
+
if (!K(e.name, e.type, n.accept))
|
|
164
|
+
return f.warning(`文件格式不支持,仅支持:${n.accept}`), !1;
|
|
165
165
|
const o = u.value.map((t) => ke(t.fileSize) || be(t.fileSize) ? +t.fileSize : 0).reduce((t, l) => t + l, 0);
|
|
166
|
-
return
|
|
166
|
+
return n.maxSize && (e.size + o) / 1024 / 1024 > n.maxSize ? (f.warning(`文件大小不能超过 ${n.maxSize}MB`), !1) : _.value > 0 && u.value.length >= _.value ? (f.warning("已超过上传数量"), !1) : M(n.beforeUpload) ? n.beforeUpload(e) : !0;
|
|
167
167
|
}
|
|
168
168
|
function te() {
|
|
169
169
|
f.warning("已超过上传数量");
|
|
@@ -177,7 +177,7 @@ const ao = /* @__PURE__ */ fe({
|
|
|
177
177
|
if (!o)
|
|
178
178
|
throw new Error("No OssKey");
|
|
179
179
|
const t = u.value.filter((s) => g(s) !== o);
|
|
180
|
-
t.length !== u.value.length && (u.value = t), e.file && ((l =
|
|
180
|
+
t.length !== u.value.length && (u.value = t), e.file && ((l = S.value) == null || l.handleRemove(e.file)), p("delete", e);
|
|
181
181
|
}
|
|
182
182
|
async function E(e) {
|
|
183
183
|
var t;
|
|
@@ -186,150 +186,150 @@ const ao = /* @__PURE__ */ fe({
|
|
|
186
186
|
try {
|
|
187
187
|
const s = (t = (await o({
|
|
188
188
|
filePath: e.ossKey
|
|
189
|
-
})).find((
|
|
189
|
+
})).find((a) => a.fileName === e.ossKey)) == null ? void 0 : t.fileUrl;
|
|
190
190
|
return e.url = s, s;
|
|
191
191
|
} catch (l) {
|
|
192
192
|
f.warning((l == null ? void 0 : l.message) ?? "获取文件地址失败");
|
|
193
193
|
return;
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
|
-
async function
|
|
197
|
-
const l = await (await fetch(e)).blob(), s = URL.createObjectURL(l),
|
|
198
|
-
|
|
196
|
+
async function ne(e, o) {
|
|
197
|
+
const l = await (await fetch(e)).blob(), s = URL.createObjectURL(l), a = document.createElement("a");
|
|
198
|
+
a.href = s, a.download = o, a.click(), URL.revokeObjectURL(s);
|
|
199
199
|
}
|
|
200
|
-
async function
|
|
200
|
+
async function ae(e) {
|
|
201
201
|
p("preview", e);
|
|
202
202
|
let o = await E(e);
|
|
203
|
-
y.value || (o = URL.createObjectURL(e.file)), o && (
|
|
203
|
+
y.value || (o = URL.createObjectURL(e.file)), o && (D(e.fileName) ? (x.value = [o], h.value = !0) : window.open(o, "_blank"));
|
|
204
204
|
}
|
|
205
|
-
async function
|
|
205
|
+
async function re(e) {
|
|
206
206
|
let o = !1;
|
|
207
|
-
if (o =
|
|
207
|
+
if (o = M(n.beforeDownload) ? !!await n.beforeDownload(e) : n.beforeDownload, !o) {
|
|
208
208
|
p("download", e);
|
|
209
209
|
return;
|
|
210
210
|
}
|
|
211
211
|
let t;
|
|
212
|
-
y.value ? t = await E(e) : t = URL.createObjectURL(e.file), t &&
|
|
212
|
+
y.value ? t = await E(e) : t = URL.createObjectURL(e.file), t && ne(t, e.fileName);
|
|
213
213
|
}
|
|
214
|
-
const ie = () =>
|
|
214
|
+
const ie = () => n.showUploadArea ? r("div", {
|
|
215
215
|
class: `${i}-area`
|
|
216
|
-
}, [
|
|
217
|
-
ref:
|
|
216
|
+
}, [r($e, ye({
|
|
217
|
+
ref: S
|
|
218
218
|
}, ee.value), {
|
|
219
219
|
default: () => {
|
|
220
220
|
var e, o;
|
|
221
|
-
return [((e = d.uploadContent) == null ? void 0 : e.call(d)) ||
|
|
221
|
+
return [((e = d.uploadContent) == null ? void 0 : e.call(d)) || r("div", {
|
|
222
222
|
class: `${i}-dragger`
|
|
223
|
-
}, [
|
|
223
|
+
}, [r(b, {
|
|
224
224
|
icon: ge,
|
|
225
225
|
size: 32,
|
|
226
226
|
isCustomSvg: !0
|
|
227
|
-
}, null),
|
|
227
|
+
}, null), r("div", {
|
|
228
228
|
class: `${i}-dragger__text`
|
|
229
|
-
}, [w("上传附件")]),
|
|
229
|
+
}, [w("上传附件")]), r("div", {
|
|
230
230
|
class: `${i}-dragger__tip`
|
|
231
|
-
}, [((o = d.uploadTip) == null ? void 0 : o.call(d)) ||
|
|
231
|
+
}, [((o = d.uploadTip) == null ? void 0 : o.call(d)) || n.uploadTip]), n.showTemplateDownload && r("div", {
|
|
232
232
|
class: `${i}-dragger__template`,
|
|
233
233
|
onClick: (t) => {
|
|
234
234
|
t.stopPropagation(), p("templateDownload");
|
|
235
235
|
}
|
|
236
|
-
}, [
|
|
236
|
+
}, [n.templateText])])];
|
|
237
237
|
}
|
|
238
238
|
})]) : null, A = (e, o) => d.fileActions ? d.fileActions({
|
|
239
239
|
file: e,
|
|
240
240
|
index: o
|
|
241
|
-
}) :
|
|
241
|
+
}) : r("div", {
|
|
242
242
|
class: `${i}-file__actions`
|
|
243
|
-
}, [
|
|
243
|
+
}, [n.showPreview && r(k, {
|
|
244
244
|
type: "primary",
|
|
245
245
|
link: !0,
|
|
246
|
-
onClick: () =>
|
|
246
|
+
onClick: () => ae(e)
|
|
247
247
|
}, {
|
|
248
248
|
default: () => [w("查看")]
|
|
249
|
-
}),
|
|
249
|
+
}), n.showDownload && r(k, {
|
|
250
250
|
type: "primary",
|
|
251
251
|
link: !0,
|
|
252
|
-
onClick: () =>
|
|
252
|
+
onClick: () => re(e)
|
|
253
253
|
}, {
|
|
254
254
|
default: () => [w("下载")]
|
|
255
|
-
}),
|
|
255
|
+
}), n.showDelete && !n.disabled && r(k, {
|
|
256
256
|
type: "danger",
|
|
257
257
|
link: !0,
|
|
258
258
|
onClick: () => le(e)
|
|
259
259
|
}, {
|
|
260
260
|
default: () => [w("删除")]
|
|
261
|
-
})]), se = (e, o) =>
|
|
261
|
+
})]), se = (e, o) => r("div", {
|
|
262
262
|
class: `${i}-file__card`,
|
|
263
263
|
key: g(e)
|
|
264
|
-
}, [
|
|
264
|
+
}, [r("div", {
|
|
265
265
|
class: `${i}-file__card-header`
|
|
266
|
-
}, [
|
|
266
|
+
}, [r("div", {
|
|
267
267
|
class: `${i}-file__card-icon`
|
|
268
|
-
}, [
|
|
269
|
-
icon:
|
|
268
|
+
}, [r(b, {
|
|
269
|
+
icon: B,
|
|
270
270
|
size: 28,
|
|
271
271
|
isCustomSvg: !0
|
|
272
|
-
}, null)]),
|
|
272
|
+
}, null)]), r("div", {
|
|
273
273
|
class: `${i}-file__card-info`
|
|
274
|
-
}, [
|
|
274
|
+
}, [r(z, {
|
|
275
275
|
class: `${i}-file__card-name`
|
|
276
276
|
}, {
|
|
277
277
|
default: () => [e.fileName]
|
|
278
|
-
})])]),
|
|
278
|
+
})])]), r("div", {
|
|
279
279
|
class: `${i}-file__card-footer`
|
|
280
|
-
}, [A(e, o)])]), ce = (e, o) =>
|
|
280
|
+
}, [A(e, o)])]), ce = (e, o) => r("div", {
|
|
281
281
|
class: `${i}-file__row`,
|
|
282
282
|
key: g(e)
|
|
283
|
-
}, [
|
|
283
|
+
}, [r("div", {
|
|
284
284
|
class: `${i}-file__row-icon`
|
|
285
|
-
}, [
|
|
286
|
-
icon:
|
|
285
|
+
}, [r(b, {
|
|
286
|
+
icon: B,
|
|
287
287
|
size: 28,
|
|
288
288
|
isCustomSvg: !0
|
|
289
|
-
}, null)]),
|
|
289
|
+
}, null)]), r("div", {
|
|
290
290
|
class: `${i}-file__row-info`
|
|
291
|
-
}, [
|
|
291
|
+
}, [r(z, {
|
|
292
292
|
class: `${i}-file__row-name`
|
|
293
293
|
}, {
|
|
294
294
|
default: () => [e.fileName]
|
|
295
|
-
})]),
|
|
295
|
+
})]), r("div", {
|
|
296
296
|
class: `${i}-file__row-actions`
|
|
297
297
|
}, [A(e, o)])]), ue = (e, o) => d.fileItem ? d.fileItem({
|
|
298
298
|
file: e,
|
|
299
299
|
index: o
|
|
300
300
|
}) : U.value ? se(e, o) : ce(e, o), de = () => {
|
|
301
|
-
if (!
|
|
301
|
+
if (!n.showFileList || u.value.length === 0) return null;
|
|
302
302
|
const e = u.value.map((l, s) => ue(l, s)), o = U.value ? `${i}-filelist__grid` : `${i}-filelist__list`, t = U.value ? {
|
|
303
|
-
gridTemplateColumns: `repeat(${
|
|
303
|
+
gridTemplateColumns: `repeat(${n.gridColumns}, 1fr)`
|
|
304
304
|
} : void 0;
|
|
305
|
-
return
|
|
305
|
+
return r("div", {
|
|
306
306
|
class: `${i}-filelist`
|
|
307
|
-
}, [
|
|
307
|
+
}, [r("div", {
|
|
308
308
|
class: o,
|
|
309
309
|
style: t
|
|
310
|
-
}, [e]),
|
|
310
|
+
}, [e]), n.showCount && _.value > 0 && r("div", {
|
|
311
311
|
class: `${i}-filelist__count`
|
|
312
|
-
}, [
|
|
312
|
+
}, [r("span", {
|
|
313
313
|
class: `${i}-filelist__count-current-number`
|
|
314
|
-
}, [u.value.length]),
|
|
314
|
+
}, [u.value.length]), r("span", null, [w(" / ")]), r("span", {
|
|
315
315
|
class: `${i}-filelist__count-total-number`
|
|
316
316
|
}, [_.value])])]);
|
|
317
317
|
}, F = () => {
|
|
318
318
|
var e;
|
|
319
|
-
return
|
|
319
|
+
return r("div", {
|
|
320
320
|
class: i
|
|
321
|
-
}, [ie(), de(), (e = d.footer) == null ? void 0 : e.call(d), h.value &&
|
|
321
|
+
}, [ie(), de(), (e = d.footer) == null ? void 0 : e.call(d), h.value && r(Ue, {
|
|
322
322
|
urlList: x.value,
|
|
323
323
|
hideOnClickModal: !0,
|
|
324
324
|
teleported: !0,
|
|
325
325
|
onClose: () => h.value = !1
|
|
326
326
|
}, null)]);
|
|
327
|
-
}, pe = () =>
|
|
327
|
+
}, pe = () => n.modal ? r(j, null, {
|
|
328
328
|
default: () => F()
|
|
329
329
|
}) : F();
|
|
330
330
|
return (e, o) => (_e(), ve(pe));
|
|
331
331
|
}
|
|
332
332
|
});
|
|
333
333
|
export {
|
|
334
|
-
|
|
334
|
+
no as default
|
|
335
335
|
};
|
|
@@ -81,7 +81,7 @@ export declare const ttUploadProps: {
|
|
|
81
81
|
readonly default: ".pdf,.xlsx,.xls,.doc,.docx,.jpg,.jpeg,.png";
|
|
82
82
|
};
|
|
83
83
|
/** 上传前的钩子;在内置类型/大小/数量校验通过后调用,返回 false 可阻止上传 */
|
|
84
|
-
readonly beforeUpload: import('element-plus/es/utils/
|
|
84
|
+
readonly beforeUpload: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<void | undefined | null | boolean | File | Blob>) | (() => (rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<void | undefined | null | boolean | File | Blob>) | {
|
|
85
85
|
(): (rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<void | undefined | null | boolean | File | Blob>;
|
|
86
86
|
new (): any;
|
|
87
87
|
readonly prototype: any;
|
|
@@ -205,7 +205,7 @@ export declare const ttUploadProps: {
|
|
|
205
205
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
206
206
|
__epPropKey: true;
|
|
207
207
|
};
|
|
208
|
-
readonly onRemove: import('element-plus/es/utils/
|
|
208
|
+
readonly onRemove: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | (() => (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | {
|
|
209
209
|
(): (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void;
|
|
210
210
|
new (): any;
|
|
211
211
|
readonly prototype: any;
|
|
@@ -214,7 +214,7 @@ export declare const ttUploadProps: {
|
|
|
214
214
|
new (): any;
|
|
215
215
|
readonly prototype: any;
|
|
216
216
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
217
|
-
readonly onChange: import('element-plus/es/utils/
|
|
217
|
+
readonly onChange: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | (() => (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | {
|
|
218
218
|
(): (uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void;
|
|
219
219
|
new (): any;
|
|
220
220
|
readonly prototype: any;
|
|
@@ -223,7 +223,7 @@ export declare const ttUploadProps: {
|
|
|
223
223
|
new (): any;
|
|
224
224
|
readonly prototype: any;
|
|
225
225
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
226
|
-
readonly onPreview: import('element-plus/es/utils/
|
|
226
|
+
readonly onPreview: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (uploadFile: import('element-plus').UploadFile) => void) | (() => (uploadFile: import('element-plus').UploadFile) => void) | {
|
|
227
227
|
(): (uploadFile: import('element-plus').UploadFile) => void;
|
|
228
228
|
new (): any;
|
|
229
229
|
readonly prototype: any;
|
|
@@ -232,7 +232,7 @@ export declare const ttUploadProps: {
|
|
|
232
232
|
new (): any;
|
|
233
233
|
readonly prototype: any;
|
|
234
234
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
235
|
-
readonly onSuccess: import('element-plus/es/utils/
|
|
235
|
+
readonly onSuccess: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (response: any, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | (() => (response: any, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | {
|
|
236
236
|
(): (response: any, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void;
|
|
237
237
|
new (): any;
|
|
238
238
|
readonly prototype: any;
|
|
@@ -241,7 +241,7 @@ export declare const ttUploadProps: {
|
|
|
241
241
|
new (): any;
|
|
242
242
|
readonly prototype: any;
|
|
243
243
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
244
|
-
readonly onProgress: import('element-plus/es/utils/
|
|
244
|
+
readonly onProgress: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (evt: import('element-plus').UploadProgressEvent, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | (() => (evt: import('element-plus').UploadProgressEvent, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | {
|
|
245
245
|
(): (evt: import('element-plus').UploadProgressEvent, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void;
|
|
246
246
|
new (): any;
|
|
247
247
|
readonly prototype: any;
|
|
@@ -250,7 +250,7 @@ export declare const ttUploadProps: {
|
|
|
250
250
|
new (): any;
|
|
251
251
|
readonly prototype: any;
|
|
252
252
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
253
|
-
readonly onError: import('element-plus/es/utils/
|
|
253
|
+
readonly onError: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (error: Error, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | (() => (error: Error, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void) | {
|
|
254
254
|
(): (error: Error, uploadFile: import('element-plus').UploadFile, uploadFiles: import('element-plus').UploadFiles) => void;
|
|
255
255
|
new (): any;
|
|
256
256
|
readonly prototype: any;
|
|
@@ -259,7 +259,7 @@ export declare const ttUploadProps: {
|
|
|
259
259
|
new (): any;
|
|
260
260
|
readonly prototype: any;
|
|
261
261
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
262
|
-
readonly onExceed: import('element-plus/es/utils/
|
|
262
|
+
readonly onExceed: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => (files: File[], uploadFiles: import('element-plus').UploadUserFile[]) => void) | (() => (files: File[], uploadFiles: import('element-plus').UploadUserFile[]) => void) | {
|
|
263
263
|
(): (files: File[], uploadFiles: import('element-plus').UploadUserFile[]) => void;
|
|
264
264
|
new (): any;
|
|
265
265
|
readonly prototype: any;
|
|
@@ -269,25 +269,25 @@ export declare const ttUploadProps: {
|
|
|
269
269
|
readonly prototype: any;
|
|
270
270
|
}) | null)[], unknown, unknown, () => void, boolean>;
|
|
271
271
|
readonly crossorigin: {
|
|
272
|
-
readonly type: PropType<import('element-plus/es/utils/
|
|
272
|
+
readonly type: PropType<import('element-plus/es/utils/vue/props/types.mjs').EpPropMergeType<(new (...args: any[]) => "" | "anonymous" | "use-credentials") | (() => "" | "anonymous" | "use-credentials") | (((new (...args: any[]) => "" | "anonymous" | "use-credentials") | (() => "" | "anonymous" | "use-credentials")) | null)[], unknown, unknown>>;
|
|
273
273
|
readonly required: false;
|
|
274
274
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
275
275
|
__epPropKey: true;
|
|
276
276
|
};
|
|
277
277
|
readonly headers: {
|
|
278
|
-
readonly type: PropType<import('element-plus/es/utils/
|
|
278
|
+
readonly type: PropType<import('element-plus/es/utils/vue/props/types.mjs').EpPropMergeType<(new (...args: any[]) => Record<string, any> | Headers) | (() => Record<string, any> | Headers) | (((new (...args: any[]) => Record<string, any> | Headers) | (() => Record<string, any> | Headers)) | null)[], unknown, unknown>>;
|
|
279
279
|
readonly required: false;
|
|
280
280
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
281
281
|
__epPropKey: true;
|
|
282
282
|
};
|
|
283
|
-
readonly method: import('element-plus/es/utils/
|
|
284
|
-
readonly data: import('element-plus/es/utils/
|
|
285
|
-
readonly name: import('element-plus/es/utils/
|
|
283
|
+
readonly method: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<StringConstructor, unknown, unknown, "post", boolean>;
|
|
284
|
+
readonly data: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>> | Promise<import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>>> | ((rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus').UploadData>)) | (() => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>>> | ((rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus').UploadData>)) | (((new (...args: any[]) => import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>> | Promise<import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>>> | ((rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus').UploadData>)) | (() => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus/es/utils/typescript.mjs').Mutable<Record<string, any>>> | ((rawFile: UploadRawFile) => import('element-plus/es/utils/typescript.mjs').Awaitable<import('element-plus').UploadData>))) | null)[], unknown, unknown, () => import('element-plus/es/utils/typescript.mjs').Mutable<{}>, boolean>;
|
|
285
|
+
readonly name: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<StringConstructor, unknown, unknown, "file", boolean>;
|
|
286
286
|
readonly withCredentials: BooleanConstructor;
|
|
287
|
-
readonly fileList: import('element-plus/es/utils/
|
|
288
|
-
readonly autoUpload: import('element-plus/es/utils/
|
|
289
|
-
readonly listType: import('element-plus/es/utils/
|
|
290
|
-
readonly httpRequest: import('element-plus/es/utils/
|
|
287
|
+
readonly fileList: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => import('element-plus').UploadUserFile[]) | (() => import('element-plus').UploadUserFile[]) | (((new (...args: any[]) => import('element-plus').UploadUserFile[]) | (() => import('element-plus').UploadUserFile[])) | null)[], unknown, unknown, () => [], boolean>;
|
|
288
|
+
readonly autoUpload: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<BooleanConstructor, unknown, unknown, true, boolean>;
|
|
289
|
+
readonly listType: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<StringConstructor, "text" | "picture" | "picture-card", unknown, "text", boolean>;
|
|
290
|
+
readonly httpRequest: import('element-plus/es/utils/vue/props/types.mjs').EpPropFinalized<(new (...args: any[]) => import('element-plus').UploadRequestHandler) | (() => import('element-plus').UploadRequestHandler) | {
|
|
291
291
|
(): import('element-plus').UploadRequestHandler;
|
|
292
292
|
new (): any;
|
|
293
293
|
readonly prototype: any;
|