iking-web-ui-pro 0.2.4 → 0.2.6
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/IKDetailPreviewFiles/ik.index.es.js +586 -571
- package/dist/IKDetailPreviewFiles/ik.index.umd.js +1 -1
- package/dist/IKDetailPreviewFiles/style.css +1 -1
- package/dist/IKExpandCollapse/ik.index.es.js +123 -120
- package/dist/IKExpandCollapse/ik.index.umd.js +1 -1
- package/dist/IKExpandCollapse/style.css +1 -1
- package/dist/IKPreviewFile/ik.index.es.js +491 -476
- package/dist/IKPreviewFile/ik.index.umd.js +1 -1
- package/dist/IKPreviewFile/style.css +1 -1
- package/dist/IKVerticalStepBar/ik.index.es.js +142 -139
- package/dist/IKVerticalStepBar/ik.index.umd.js +3 -3
- package/dist/IKVerticalStepBar/style.css +1 -1
- package/dist/IkApprovalProcessDetail/ik.index.es.js +756 -741
- package/dist/IkApprovalProcessDetail/ik.index.umd.js +1 -1
- package/dist/IkApprovalProcessDetail/style.css +1 -1
- package/dist/IkBaseDialog/ik.index.es.js +125 -122
- package/dist/IkBaseDialog/ik.index.umd.js +1 -1
- package/dist/IkBaseDialog/style.css +1 -1
- package/dist/IkBtnSetting/ik.index.es.js +252 -249
- package/dist/IkBtnSetting/ik.index.umd.js +1 -1
- package/dist/IkBtnSetting/style.css +1 -1
- package/dist/IkCollapseCard/ik.index.es.js +129 -126
- package/dist/IkCollapseCard/ik.index.umd.js +1 -1
- package/dist/IkCollapseCard/style.css +1 -1
- package/dist/IkDescription/ik.index.es.js +530 -515
- package/dist/IkDescription/ik.index.umd.js +1 -1
- package/dist/IkDescription/style.css +1 -1
- package/dist/IkIconPicker/ik.index.es.js +196 -193
- package/dist/IkIconPicker/ik.index.umd.js +1 -1
- package/dist/IkIconPicker/style.css +1 -1
- package/dist/IkMonacoEditor/ik.index.es.js +397 -394
- package/dist/IkMonacoEditor/ik.index.umd.js +3 -3
- package/dist/IkMonacoEditor/style.css +1 -1
- package/dist/IkPageFull/ik.index.es.js +1122 -1119
- package/dist/IkPageFull/ik.index.umd.js +2 -2
- package/dist/IkPageFull/style.css +1 -1
- package/dist/IkPreviewFileDialog/ik.index.es.js +314 -308
- package/dist/IkPreviewFileDialog/ik.index.umd.js +1 -1
- package/dist/IkPreviewFileDialog/style.css +1 -1
- package/dist/IkSchedule/ik.index.es.js +968 -965
- package/dist/IkSchedule/ik.index.umd.js +1 -1
- package/dist/IkSchedule/style.css +1 -1
- package/dist/IkSideText/ik.index.es.js +148 -145
- package/dist/IkSideText/ik.index.umd.js +1 -1
- package/dist/IkSideText/style.css +1 -1
- package/dist/IkSvgIcon/ik.index.es.js +106 -103
- package/dist/IkSvgIcon/ik.index.umd.js +1 -1
- package/dist/IkSvgIcon/style.css +1 -1
- package/dist/IkUploadFile/ik.index.es.js +963 -944
- package/dist/IkUploadFile/ik.index.umd.js +1 -1
- package/dist/IkUploadFile/style.css +1 -1
- package/dist/IkUploadImage/ik.index.es.js +265 -253
- package/dist/IkUploadImage/ik.index.umd.js +1 -1
- package/dist/IkUploadImage/style.css +1 -1
- package/dist/Provider/ik.index.es.js +1611 -0
- package/dist/Provider/ik.index.umd.js +17 -0
- package/dist/index.es.js +38689 -37072
- package/dist/index.umd.js +95 -79
- package/dist/src/components/IKDetailPreviewFiles/index.d.ts +1 -1
- package/dist/src/components/IKDetailPreviewFiles/src/IKDetailPreviewFiles.vue.d.ts +1 -1
- package/dist/src/components/IKPreviewFile/index.d.ts +3 -3
- package/dist/src/components/IKPreviewFile/src/IkPreviewFile.vue.d.ts +1 -1
- package/dist/src/components/IkApprovalProcess/index.d.ts +1 -1
- package/dist/src/components/IkApprovalProcess/src/IKApprovalProcess.vue.d.ts +1 -1
- package/dist/src/components/IkDescription/index.d.ts +3 -3
- package/dist/src/components/IkDescription/src/IkDescription.vue.d.ts +1 -1
- package/dist/src/components/IkPreviewFileDialog/index.d.ts +1 -1
- package/dist/src/components/IkPreviewFileDialog/src/IkPreviewFileDialog.vue.d.ts +1 -1
- package/dist/src/components/IkTinymce/index.d.ts +1 -1
- package/dist/src/components/IkTinymce/src/index.vue.d.ts +1 -1
- package/dist/src/components/IkUploadFile/index.d.ts +3 -3
- package/dist/src/components/IkUploadFile/src/index.vue.d.ts +1 -1
- package/dist/src/components/IkUploadImage/index.d.ts +3 -3
- package/dist/src/components/IkUploadImage/src/index.vue.d.ts +1 -1
- package/dist/src/components/Provider/ProviderConfig.vue.d.ts +66 -0
- package/dist/src/components/Provider/index.d.ts +139 -0
- package/dist/src/components/index.d.ts +1 -0
- package/dist/src/utils/use-provider.d.ts +8 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ikColor as
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as y, inject as X, computed as C, resolveComponent as z, openBlock as r, createElementBlock as f, normalizeClass as _, normalizeStyle as m, createCommentVNode as R, createElementVNode as I, createBlock as k, withCtx as h, createTextVNode as B, toDisplayString as O, createVNode as D, unref as w, mergeModels as H, useModel as W, ref as q, h as Y, mergeProps as G, createSlots as K, renderSlot as S, reactive as J, watch as Q, nextTick as Z, Fragment as ee } from "vue";
|
|
2
|
+
import { ikColor as te, buildUUID as ne } from "iking-utils-pro";
|
|
3
|
+
const E = (n, t) => {
|
|
4
4
|
if (n.install = (o) => {
|
|
5
|
-
for (const
|
|
6
|
-
o.component(
|
|
7
|
-
},
|
|
8
|
-
for (const [o,
|
|
9
|
-
n[o] =
|
|
5
|
+
for (const e of [n, ...Object.values(t ?? {})])
|
|
6
|
+
o.component(e.name, e);
|
|
7
|
+
}, t)
|
|
8
|
+
for (const [o, e] of Object.entries(t))
|
|
9
|
+
n[o] = e;
|
|
10
10
|
return n;
|
|
11
|
-
}, M = (n,
|
|
11
|
+
}, M = (n, t) => t ? t.startsWith("http") ? t : `${n || location.origin}${t}` : "", V = (n, t) => {
|
|
12
12
|
const o = n.__vccOpts || n;
|
|
13
|
-
for (const [
|
|
14
|
-
o[
|
|
13
|
+
for (const [e, l] of t)
|
|
14
|
+
o[e] = l;
|
|
15
15
|
return o;
|
|
16
|
-
},
|
|
17
|
-
var i,
|
|
18
|
-
const o = (i = n == null ? void 0 : n.response) != null && i.data ? L((
|
|
16
|
+
}, oe = (n, t) => {
|
|
17
|
+
var i, s, c, d;
|
|
18
|
+
const o = (i = n == null ? void 0 : n.response) != null && i.data ? L((c = (s = n == null ? void 0 : n.response) == null ? void 0 : s.data) == null ? void 0 : c.suffix) : ((d = n.raw) == null ? void 0 : d.type) || L(n[t.suffix]), e = o == null ? void 0 : o.toLowerCase(), l = {
|
|
19
19
|
sheet: "excel",
|
|
20
20
|
excel: "excel",
|
|
21
21
|
zip: "zip",
|
|
@@ -31,11 +31,11 @@ const q = (n, e) => {
|
|
|
31
31
|
exe: "exe",
|
|
32
32
|
json: "json"
|
|
33
33
|
};
|
|
34
|
-
for (let
|
|
35
|
-
if (typeof
|
|
36
|
-
return
|
|
34
|
+
for (let a in l)
|
|
35
|
+
if (typeof e == "string" && (e.includes(a) || e === a))
|
|
36
|
+
return l[a];
|
|
37
37
|
return "unknown";
|
|
38
|
-
},
|
|
38
|
+
}, ie = {
|
|
39
39
|
".doc": "word",
|
|
40
40
|
".docx": "word",
|
|
41
41
|
".docxf": "word",
|
|
@@ -121,23 +121,23 @@ const q = (n, e) => {
|
|
|
121
121
|
".txt": "txt",
|
|
122
122
|
".pdf": "pdf"
|
|
123
123
|
}, L = (n) => {
|
|
124
|
-
const
|
|
125
|
-
return o &&
|
|
126
|
-
},
|
|
127
|
-
let
|
|
128
|
-
return o.includes(n) && (
|
|
129
|
-
},
|
|
124
|
+
const t = n == null ? void 0 : n.toLocaleLowerCase(), o = t != null && t.startsWith(".") ? t : `.${t}`;
|
|
125
|
+
return o && ie[o] || "unknow";
|
|
126
|
+
}, se = (n) => {
|
|
127
|
+
let t = "", o = ["doc", "docx"], e = ["xls", "xlsx"], l = ["ppt", "pptx"], i = ["pdf"];
|
|
128
|
+
return o.includes(n) && (t = "word"), e.includes(n) && (t = "cell"), l.includes(n) && (t = "slide"), i.includes(n) && (t = "text-pdf"), t;
|
|
129
|
+
}, ae = {
|
|
130
130
|
key: 0,
|
|
131
131
|
class: "ik-svg-icon ik-icon inline-block inline-flex justify-center box-content line-height-[0]"
|
|
132
|
-
},
|
|
132
|
+
}, le = {
|
|
133
133
|
key: 1,
|
|
134
134
|
class: "h-[1em] w-[1em]",
|
|
135
135
|
"aria-hidden": "true"
|
|
136
|
-
},
|
|
136
|
+
}, re = ["xlink:href"], ce = ["src"], ue = {
|
|
137
137
|
key: 1,
|
|
138
138
|
class: "h-[1em] w-[1em]",
|
|
139
139
|
"aria-hidden": "true"
|
|
140
|
-
},
|
|
140
|
+
}, de = ["xlink:href"], pe = ["src"], fe = /* @__PURE__ */ y({
|
|
141
141
|
name: "IkSvgIcon",
|
|
142
142
|
__name: "index",
|
|
143
143
|
props: {
|
|
@@ -164,84 +164,87 @@ const q = (n, e) => {
|
|
|
164
164
|
tableIconType: { default: "icon" }
|
|
165
165
|
},
|
|
166
166
|
setup(n) {
|
|
167
|
-
const
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
}),
|
|
171
|
-
const
|
|
172
|
-
|
|
173
|
-
|
|
167
|
+
const t = n, o = X("iconConfig"), e = C(() => ({
|
|
168
|
+
...(o == null ? void 0 : o.value) || {},
|
|
169
|
+
...t
|
|
170
|
+
})), l = C(() => {
|
|
171
|
+
const { name: s } = e.value;
|
|
172
|
+
return /^http?:\/\//.test(s) ? "img" : /i-[^:]+:[^:]+/.test(s) ? "unocss" : s != null && s.startsWith("iksig") ? "iksig" : s != null && s.includes(":") ? "iconify" : s != null && s.startsWith("iksvg") ? "svg" : "i";
|
|
173
|
+
}), i = C(() => {
|
|
174
|
+
const s = [];
|
|
175
|
+
if (e.value.flip)
|
|
176
|
+
switch (e.value.flip) {
|
|
174
177
|
case "horizontal":
|
|
175
|
-
|
|
178
|
+
s.push("rotateY(180deg)");
|
|
176
179
|
break;
|
|
177
180
|
case "vertical":
|
|
178
|
-
|
|
181
|
+
s.push("rotateX(180deg)");
|
|
179
182
|
break;
|
|
180
183
|
case "both":
|
|
181
|
-
|
|
184
|
+
s.push("rotateX(180deg)"), s.push("rotateY(180deg)");
|
|
182
185
|
break;
|
|
183
186
|
}
|
|
184
|
-
e.rotate &&
|
|
185
|
-
const
|
|
186
|
-
...e.color && { color: e.color },
|
|
187
|
-
...e.size && { fontSize: typeof e.size == "number" ? `${e.size}px` : e.size },
|
|
188
|
-
...
|
|
189
|
-
padding: e.showBg || e.bg ? e.padding : 0,
|
|
190
|
-
...e.color &&
|
|
191
|
-
"--ik-color-icon-dark": e.color,
|
|
192
|
-
"--ik-color-icon-light": e.colorLight ||
|
|
187
|
+
e.value.rotate && s.push(`rotate(${e.value.rotate % 360}deg)`);
|
|
188
|
+
const c = {
|
|
189
|
+
...e.value.color && { color: e.value.color },
|
|
190
|
+
...e.value.size && { fontSize: typeof e.value.size == "number" ? `${e.value.size}px` : e.value.size },
|
|
191
|
+
...s.length && { transform: s.join(" ") },
|
|
192
|
+
padding: e.value.showBg || e.value.bg ? e.value.padding : 0,
|
|
193
|
+
...e.value.color && l.value !== "iksig" ? {
|
|
194
|
+
"--ik-color-icon-dark": e.value.color,
|
|
195
|
+
"--ik-color-icon-light": e.value.colorLight || te.setOpacity(e.value.color, e.value.opacity)
|
|
193
196
|
} : {}
|
|
194
197
|
};
|
|
195
|
-
return e.width && (
|
|
198
|
+
return e.value.width && (c.width = c.height = typeof e.value.width == "number" ? `${e.value.width}px` : e.value.width), c;
|
|
196
199
|
});
|
|
197
|
-
return (
|
|
198
|
-
const
|
|
199
|
-
return
|
|
200
|
-
|
|
200
|
+
return (s, c) => {
|
|
201
|
+
const d = z("el-tooltip"), a = z("el-button");
|
|
202
|
+
return e.value.tableIconType === "icon" ? (r(), f("span", ae, [
|
|
203
|
+
e.value.notip || !e.value.title ? (r(), f(
|
|
201
204
|
"i",
|
|
202
205
|
{
|
|
203
206
|
key: 0,
|
|
204
|
-
class:
|
|
205
|
-
[
|
|
206
|
-
"show-bg":
|
|
207
|
-
default:
|
|
208
|
-
small:
|
|
209
|
-
big:
|
|
210
|
-
warning:
|
|
211
|
-
primary:
|
|
212
|
-
success:
|
|
213
|
-
error:
|
|
214
|
-
active:
|
|
215
|
-
disabled:
|
|
207
|
+
class: _(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition", {
|
|
208
|
+
[s.name]: l.value === "unocss",
|
|
209
|
+
"show-bg": e.value.showBg || e.value.bg,
|
|
210
|
+
default: e.value.size === "default",
|
|
211
|
+
small: e.value.size === "small",
|
|
212
|
+
big: e.value.size === "big",
|
|
213
|
+
warning: e.value.warning || e.value.type === "warning",
|
|
214
|
+
primary: e.value.primary || e.value.type === "primary",
|
|
215
|
+
success: s.success || e.value.type === "success",
|
|
216
|
+
error: e.value.error || e.value.type === "error",
|
|
217
|
+
active: e.value.active,
|
|
218
|
+
disabled: e.value.disabled
|
|
216
219
|
}]),
|
|
217
|
-
style: m(
|
|
220
|
+
style: m(i.value)
|
|
218
221
|
},
|
|
219
222
|
[
|
|
220
|
-
|
|
221
|
-
|
|
223
|
+
R(` <Icon v-if="outputType === 'iconify'" :icon="name" /> `),
|
|
224
|
+
l.value === "iksig" ? (r(), f(
|
|
222
225
|
"i",
|
|
223
226
|
{
|
|
224
227
|
key: 0,
|
|
225
|
-
class:
|
|
226
|
-
style: m(
|
|
228
|
+
class: _(`iksig ${e.value.name}`),
|
|
229
|
+
style: m(i.value)
|
|
227
230
|
},
|
|
228
231
|
null,
|
|
229
232
|
6
|
|
230
233
|
/* CLASS, STYLE */
|
|
231
|
-
)) :
|
|
234
|
+
)) : l.value === "svg" ? (r(), f("svg", le, [
|
|
232
235
|
I("use", {
|
|
233
|
-
"xlink:href": `#${
|
|
234
|
-
}, null, 8,
|
|
235
|
-
])) :
|
|
236
|
+
"xlink:href": `#${e.value.name}`
|
|
237
|
+
}, null, 8, re)
|
|
238
|
+
])) : l.value === "img" ? (r(), f("img", {
|
|
236
239
|
key: 2,
|
|
237
|
-
src:
|
|
240
|
+
src: e.value.name,
|
|
238
241
|
class: "h-[1em] w-[1em]"
|
|
239
|
-
}, null, 8,
|
|
242
|
+
}, null, 8, ce)) : (r(), f(
|
|
240
243
|
"i",
|
|
241
244
|
{
|
|
242
245
|
key: 3,
|
|
243
|
-
class:
|
|
244
|
-
style: m(
|
|
246
|
+
class: _(e.value.name),
|
|
247
|
+
style: m(i.value)
|
|
245
248
|
},
|
|
246
249
|
null,
|
|
247
250
|
6
|
|
@@ -250,54 +253,54 @@ const q = (n, e) => {
|
|
|
250
253
|
],
|
|
251
254
|
6
|
|
252
255
|
/* CLASS, STYLE */
|
|
253
|
-
)) : (
|
|
256
|
+
)) : (r(), k(d, {
|
|
254
257
|
key: 1,
|
|
255
|
-
content:
|
|
258
|
+
content: e.value.title,
|
|
256
259
|
placement: "top"
|
|
257
260
|
}, {
|
|
258
|
-
default:
|
|
261
|
+
default: h(() => [
|
|
259
262
|
I(
|
|
260
263
|
"i",
|
|
261
264
|
{
|
|
262
|
-
class:
|
|
263
|
-
[
|
|
264
|
-
"show-bg":
|
|
265
|
-
default:
|
|
266
|
-
small:
|
|
267
|
-
big:
|
|
268
|
-
warning:
|
|
269
|
-
primary:
|
|
270
|
-
success:
|
|
271
|
-
error:
|
|
272
|
-
active:
|
|
265
|
+
class: _(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition", {
|
|
266
|
+
[s.name]: l.value === "unocss",
|
|
267
|
+
"show-bg": e.value.showBg || e.value.bg,
|
|
268
|
+
default: e.value.size === "default",
|
|
269
|
+
small: e.value.size === "small",
|
|
270
|
+
big: e.value.size === "big",
|
|
271
|
+
warning: e.value.warning || e.value.type === "warning",
|
|
272
|
+
primary: s.primary || e.value.type === "primary",
|
|
273
|
+
success: s.success || e.value.type === "success",
|
|
274
|
+
error: e.value.error || e.value.type === "error",
|
|
275
|
+
active: e.value.active
|
|
273
276
|
}]),
|
|
274
|
-
style: m(
|
|
277
|
+
style: m(i.value)
|
|
275
278
|
},
|
|
276
279
|
[
|
|
277
|
-
|
|
280
|
+
l.value === "iksig" ? (r(), f(
|
|
278
281
|
"i",
|
|
279
282
|
{
|
|
280
283
|
key: 0,
|
|
281
|
-
class:
|
|
282
|
-
style: m(
|
|
284
|
+
class: _(`iksig ${e.value.name}`),
|
|
285
|
+
style: m(i.value)
|
|
283
286
|
},
|
|
284
287
|
null,
|
|
285
288
|
6
|
|
286
289
|
/* CLASS, STYLE */
|
|
287
|
-
)) :
|
|
290
|
+
)) : l.value === "svg" ? (r(), f("svg", ue, [
|
|
288
291
|
I("use", {
|
|
289
|
-
"xlink:href": `#${
|
|
290
|
-
}, null, 8,
|
|
291
|
-
])) :
|
|
292
|
+
"xlink:href": `#${e.value.name}`
|
|
293
|
+
}, null, 8, de)
|
|
294
|
+
])) : l.value === "img" ? (r(), f("img", {
|
|
292
295
|
key: 2,
|
|
293
|
-
src:
|
|
296
|
+
src: e.value.name,
|
|
294
297
|
class: "h-[1em] w-[1em]"
|
|
295
|
-
}, null, 8,
|
|
298
|
+
}, null, 8, pe)) : (r(), f(
|
|
296
299
|
"i",
|
|
297
300
|
{
|
|
298
301
|
key: 3,
|
|
299
|
-
class:
|
|
300
|
-
style: m(
|
|
302
|
+
class: _(e.value.name),
|
|
303
|
+
style: m(i.value)
|
|
301
304
|
},
|
|
302
305
|
null,
|
|
303
306
|
6
|
|
@@ -311,13 +314,13 @@ const q = (n, e) => {
|
|
|
311
314
|
_: 1
|
|
312
315
|
/* STABLE */
|
|
313
316
|
}, 8, ["content"]))
|
|
314
|
-
])) : (
|
|
317
|
+
])) : (r(), k(a, {
|
|
315
318
|
key: 1,
|
|
316
|
-
type: ["warning", "error"].includes(
|
|
319
|
+
type: ["warning", "error"].includes(e.value.type) ? "danger" : ""
|
|
317
320
|
}, {
|
|
318
|
-
default:
|
|
321
|
+
default: h(() => [
|
|
319
322
|
B(
|
|
320
|
-
O(
|
|
323
|
+
O(e.value.title),
|
|
321
324
|
1
|
|
322
325
|
/* TEXT */
|
|
323
326
|
)
|
|
@@ -328,10 +331,10 @@ const q = (n, e) => {
|
|
|
328
331
|
};
|
|
329
332
|
}
|
|
330
333
|
});
|
|
331
|
-
const
|
|
334
|
+
const ve = /* @__PURE__ */ V(fe, [["__scopeId", "data-v-1be337e4"]]), $ = E(ve), ge = {
|
|
332
335
|
key: 0,
|
|
333
336
|
class: "exit-main-page-maximize"
|
|
334
|
-
}, me = /* @__PURE__ */
|
|
337
|
+
}, me = /* @__PURE__ */ y({
|
|
335
338
|
__name: "CloseIcon",
|
|
336
339
|
props: {
|
|
337
340
|
showBg: {
|
|
@@ -344,15 +347,15 @@ const fe = /* @__PURE__ */ V(pe, [["__scopeId", "data-v-7d95dbf5"]]), $ = q(fe),
|
|
|
344
347
|
}
|
|
345
348
|
},
|
|
346
349
|
setup(n) {
|
|
347
|
-
return (
|
|
348
|
-
n.showBg && n.fullscreen ? (
|
|
349
|
-
D(
|
|
350
|
+
return (t, o) => (r(), f("div", null, [
|
|
351
|
+
n.showBg && n.fullscreen ? (r(), f("div", ge, [
|
|
352
|
+
D(w($), {
|
|
350
353
|
name: "iksvg_guanbidanchuang",
|
|
351
354
|
title: "关闭",
|
|
352
355
|
size: 20,
|
|
353
356
|
error: ""
|
|
354
357
|
})
|
|
355
|
-
])) : (
|
|
358
|
+
])) : (r(), k(w($), {
|
|
356
359
|
key: 1,
|
|
357
360
|
error: "",
|
|
358
361
|
name: "iksvg_guanbidanchuang",
|
|
@@ -362,7 +365,7 @@ const fe = /* @__PURE__ */ V(pe, [["__scopeId", "data-v-7d95dbf5"]]), $ = q(fe),
|
|
|
362
365
|
]));
|
|
363
366
|
}
|
|
364
367
|
});
|
|
365
|
-
const
|
|
368
|
+
const he = /* @__PURE__ */ V(me, [["__scopeId", "data-v-79f49df8"]]), ye = { class: "base-header" }, we = /* @__PURE__ */ y({
|
|
366
369
|
__name: "IkBaseDialog",
|
|
367
370
|
props: /* @__PURE__ */ H({
|
|
368
371
|
title: { default: "" },
|
|
@@ -383,64 +386,64 @@ const ve = /* @__PURE__ */ V(me, [["__scopeId", "data-v-79f49df8"]]), he = { cla
|
|
|
383
386
|
}),
|
|
384
387
|
emits: ["update:modelValue"],
|
|
385
388
|
setup(n) {
|
|
386
|
-
const
|
|
387
|
-
|
|
388
|
-
}, i =
|
|
389
|
+
const t = n, o = W(n, "modelValue"), e = q(t.fullscreen), l = () => {
|
|
390
|
+
e.value = !e.value;
|
|
391
|
+
}, i = y({
|
|
389
392
|
setup() {
|
|
390
|
-
return () =>
|
|
391
|
-
showBg:
|
|
392
|
-
fullscreen:
|
|
393
|
+
return () => Y(he, {
|
|
394
|
+
showBg: t.showCloseBg,
|
|
395
|
+
fullscreen: t.fullscreen
|
|
393
396
|
});
|
|
394
397
|
}
|
|
395
398
|
});
|
|
396
|
-
return (
|
|
397
|
-
const
|
|
398
|
-
return
|
|
399
|
+
return (s, c) => {
|
|
400
|
+
const d = z("el-dialog");
|
|
401
|
+
return r(), k(d, G({
|
|
399
402
|
modelValue: o.value,
|
|
400
|
-
"onUpdate:modelValue":
|
|
401
|
-
},
|
|
402
|
-
"close-icon":
|
|
403
|
-
class: `ik-base-dialog ${
|
|
404
|
-
fullscreen:
|
|
403
|
+
"onUpdate:modelValue": c[0] || (c[0] = (a) => o.value = a)
|
|
404
|
+
}, s.$attrs, {
|
|
405
|
+
"close-icon": w(i),
|
|
406
|
+
class: `ik-base-dialog ${s.noHeader ? "no-header" : ""} ${s.noFooter ? "no-footer" : ""}`,
|
|
407
|
+
fullscreen: e.value,
|
|
405
408
|
"modal-class": "baseDialog"
|
|
406
|
-
}),
|
|
407
|
-
icon:
|
|
408
|
-
|
|
409
|
+
}), K({
|
|
410
|
+
icon: h(() => [
|
|
411
|
+
S(s.$slots, "title", {}, () => [
|
|
409
412
|
B(
|
|
410
|
-
O(
|
|
413
|
+
O(s.title),
|
|
411
414
|
1
|
|
412
415
|
/* TEXT */
|
|
413
416
|
)
|
|
414
417
|
])
|
|
415
418
|
]),
|
|
416
|
-
header:
|
|
417
|
-
I("div",
|
|
418
|
-
|
|
419
|
+
header: h(() => [
|
|
420
|
+
I("div", ye, [
|
|
421
|
+
S(s.$slots, "header", {}, () => [
|
|
419
422
|
B(
|
|
420
|
-
O(
|
|
423
|
+
O(s.title),
|
|
421
424
|
1
|
|
422
425
|
/* TEXT */
|
|
423
426
|
)
|
|
424
427
|
])
|
|
425
428
|
]),
|
|
426
|
-
|
|
429
|
+
s.$attrs.showClose ? (r(), k(w($), {
|
|
427
430
|
key: 0,
|
|
428
|
-
onClick:
|
|
429
|
-
name:
|
|
431
|
+
onClick: l,
|
|
432
|
+
name: e.value ? "iksvg_tuichuquanping" : "iksvg_quanping-daohang",
|
|
430
433
|
class: "absolute! top-[18px] right-[50px] icon-dialog-full",
|
|
431
|
-
title:
|
|
432
|
-
}, null, 8, ["name", "title"])) :
|
|
434
|
+
title: e.value ? "退出全屏" : "全屏"
|
|
435
|
+
}, null, 8, ["name", "title"])) : R("v-if", !0)
|
|
433
436
|
]),
|
|
434
|
-
default:
|
|
435
|
-
|
|
437
|
+
default: h(() => [
|
|
438
|
+
S(s.$slots, "default")
|
|
436
439
|
]),
|
|
437
440
|
_: 2
|
|
438
441
|
/* DYNAMIC */
|
|
439
442
|
}, [
|
|
440
|
-
|
|
443
|
+
s.$slots.footer ? {
|
|
441
444
|
name: "footer",
|
|
442
|
-
fn:
|
|
443
|
-
|
|
445
|
+
fn: h(() => [
|
|
446
|
+
S(s.$slots, "footer")
|
|
444
447
|
]),
|
|
445
448
|
key: "0"
|
|
446
449
|
} : void 0
|
|
@@ -448,135 +451,135 @@ const ve = /* @__PURE__ */ V(me, [["__scopeId", "data-v-79f49df8"]]), he = { cla
|
|
|
448
451
|
};
|
|
449
452
|
}
|
|
450
453
|
});
|
|
451
|
-
const
|
|
452
|
-
function
|
|
453
|
-
function
|
|
454
|
-
return i instanceof o ? i : new o(function(
|
|
455
|
-
|
|
454
|
+
const _e = E(we);
|
|
455
|
+
function ke(n, t, o, e) {
|
|
456
|
+
function l(i) {
|
|
457
|
+
return i instanceof o ? i : new o(function(s) {
|
|
458
|
+
s(i);
|
|
456
459
|
});
|
|
457
460
|
}
|
|
458
|
-
return new (o || (o = Promise))(function(i,
|
|
459
|
-
function u
|
|
461
|
+
return new (o || (o = Promise))(function(i, s) {
|
|
462
|
+
function c(u) {
|
|
460
463
|
try {
|
|
461
|
-
|
|
462
|
-
} catch (
|
|
463
|
-
|
|
464
|
+
a(e.next(u));
|
|
465
|
+
} catch (v) {
|
|
466
|
+
s(v);
|
|
464
467
|
}
|
|
465
468
|
}
|
|
466
|
-
function
|
|
469
|
+
function d(u) {
|
|
467
470
|
try {
|
|
468
|
-
|
|
469
|
-
} catch (
|
|
470
|
-
|
|
471
|
+
a(e.throw(u));
|
|
472
|
+
} catch (v) {
|
|
473
|
+
s(v);
|
|
471
474
|
}
|
|
472
475
|
}
|
|
473
|
-
function
|
|
474
|
-
|
|
476
|
+
function a(u) {
|
|
477
|
+
u.done ? i(u.value) : l(u.value).then(c, d);
|
|
475
478
|
}
|
|
476
|
-
|
|
479
|
+
a((e = e.apply(n, t || [])).next());
|
|
477
480
|
});
|
|
478
481
|
}
|
|
479
|
-
function
|
|
482
|
+
function be(n, t) {
|
|
480
483
|
var o = { label: 0, sent: function() {
|
|
481
484
|
if (i[0] & 1)
|
|
482
485
|
throw i[1];
|
|
483
486
|
return i[1];
|
|
484
|
-
}, trys: [], ops: [] },
|
|
485
|
-
return
|
|
487
|
+
}, trys: [], ops: [] }, e, l, i, s;
|
|
488
|
+
return s = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (s[Symbol.iterator] = function() {
|
|
486
489
|
return this;
|
|
487
|
-
}),
|
|
488
|
-
function
|
|
489
|
-
return function(
|
|
490
|
-
return
|
|
490
|
+
}), s;
|
|
491
|
+
function c(a) {
|
|
492
|
+
return function(u) {
|
|
493
|
+
return d([a, u]);
|
|
491
494
|
};
|
|
492
495
|
}
|
|
493
|
-
function
|
|
494
|
-
if (
|
|
496
|
+
function d(a) {
|
|
497
|
+
if (e)
|
|
495
498
|
throw new TypeError("Generator is already executing.");
|
|
496
|
-
for (;
|
|
499
|
+
for (; s && (s = 0, a[0] && (o = 0)), o; )
|
|
497
500
|
try {
|
|
498
|
-
if (
|
|
501
|
+
if (e = 1, l && (i = a[0] & 2 ? l.return : a[0] ? l.throw || ((i = l.return) && i.call(l), 0) : l.next) && !(i = i.call(l, a[1])).done)
|
|
499
502
|
return i;
|
|
500
|
-
switch (
|
|
503
|
+
switch (l = 0, i && (a = [a[0] & 2, i.value]), a[0]) {
|
|
501
504
|
case 0:
|
|
502
505
|
case 1:
|
|
503
|
-
i =
|
|
506
|
+
i = a;
|
|
504
507
|
break;
|
|
505
508
|
case 4:
|
|
506
|
-
return o.label++, { value:
|
|
509
|
+
return o.label++, { value: a[1], done: !1 };
|
|
507
510
|
case 5:
|
|
508
|
-
o.label++,
|
|
511
|
+
o.label++, l = a[1], a = [0];
|
|
509
512
|
continue;
|
|
510
513
|
case 7:
|
|
511
|
-
|
|
514
|
+
a = o.ops.pop(), o.trys.pop();
|
|
512
515
|
continue;
|
|
513
516
|
default:
|
|
514
|
-
if (i = o.trys, !(i = i.length > 0 && i[i.length - 1]) && (
|
|
517
|
+
if (i = o.trys, !(i = i.length > 0 && i[i.length - 1]) && (a[0] === 6 || a[0] === 2)) {
|
|
515
518
|
o = 0;
|
|
516
519
|
continue;
|
|
517
520
|
}
|
|
518
|
-
if (
|
|
519
|
-
o.label =
|
|
521
|
+
if (a[0] === 3 && (!i || a[1] > i[0] && a[1] < i[3])) {
|
|
522
|
+
o.label = a[1];
|
|
520
523
|
break;
|
|
521
524
|
}
|
|
522
|
-
if (
|
|
523
|
-
o.label = i[1], i =
|
|
525
|
+
if (a[0] === 6 && o.label < i[1]) {
|
|
526
|
+
o.label = i[1], i = a;
|
|
524
527
|
break;
|
|
525
528
|
}
|
|
526
529
|
if (i && o.label < i[2]) {
|
|
527
|
-
o.label = i[2], o.ops.push(
|
|
530
|
+
o.label = i[2], o.ops.push(a);
|
|
528
531
|
break;
|
|
529
532
|
}
|
|
530
533
|
i[2] && o.ops.pop(), o.trys.pop();
|
|
531
534
|
continue;
|
|
532
535
|
}
|
|
533
|
-
|
|
534
|
-
} catch (
|
|
535
|
-
|
|
536
|
+
a = t.call(n, o);
|
|
537
|
+
} catch (u) {
|
|
538
|
+
a = [6, u], l = 0;
|
|
536
539
|
} finally {
|
|
537
|
-
|
|
540
|
+
e = i = 0;
|
|
538
541
|
}
|
|
539
|
-
if (
|
|
540
|
-
throw
|
|
541
|
-
return { value:
|
|
542
|
+
if (a[0] & 5)
|
|
543
|
+
throw a[1];
|
|
544
|
+
return { value: a[0] ? a[1] : void 0, done: !0 };
|
|
542
545
|
}
|
|
543
546
|
}
|
|
544
|
-
var
|
|
545
|
-
return
|
|
546
|
-
return
|
|
547
|
-
return [2, new Promise(function(
|
|
547
|
+
var xe = function(n, t) {
|
|
548
|
+
return ke(void 0, void 0, void 0, function() {
|
|
549
|
+
return be(this, function(o) {
|
|
550
|
+
return [2, new Promise(function(e, l) {
|
|
548
551
|
try {
|
|
549
552
|
if (window.DocsAPI)
|
|
550
|
-
return
|
|
551
|
-
var i = document.getElementById(
|
|
553
|
+
return e(null);
|
|
554
|
+
var i = document.getElementById(t);
|
|
552
555
|
if (i)
|
|
553
|
-
var
|
|
554
|
-
var
|
|
555
|
-
if (!
|
|
556
|
-
if (clearInterval(
|
|
557
|
-
return
|
|
558
|
-
var
|
|
559
|
-
i.remove(), document.body.appendChild(
|
|
556
|
+
var s = setInterval(function() {
|
|
557
|
+
var d = i.getAttribute("loading");
|
|
558
|
+
if (!d) {
|
|
559
|
+
if (clearInterval(s), window.DocsAPI)
|
|
560
|
+
return e(null);
|
|
561
|
+
var a = U(t, n, e, l);
|
|
562
|
+
i.remove(), document.body.appendChild(a);
|
|
560
563
|
}
|
|
561
564
|
}, 500);
|
|
562
565
|
else {
|
|
563
|
-
var
|
|
564
|
-
document.body.appendChild(
|
|
566
|
+
var c = U(t, n, e, l);
|
|
567
|
+
document.body.appendChild(c);
|
|
565
568
|
}
|
|
566
|
-
} catch (
|
|
567
|
-
console.error(
|
|
569
|
+
} catch (d) {
|
|
570
|
+
console.error(d);
|
|
568
571
|
}
|
|
569
572
|
})];
|
|
570
573
|
});
|
|
571
574
|
});
|
|
572
|
-
}, U = function(n,
|
|
573
|
-
var
|
|
574
|
-
return
|
|
575
|
-
|
|
576
|
-
},
|
|
577
|
-
|
|
578
|
-
},
|
|
579
|
-
}, T =
|
|
575
|
+
}, U = function(n, t, o, e) {
|
|
576
|
+
var l = document.createElement("script");
|
|
577
|
+
return l.id = n, l.type = "text/javascript", l.src = t, l.async = !0, l.onload = function() {
|
|
578
|
+
l.removeAttribute("loading"), o(null);
|
|
579
|
+
}, l.onerror = function(i) {
|
|
580
|
+
l.removeAttribute("loading"), e(i);
|
|
581
|
+
}, l.setAttribute("loading", ""), l;
|
|
582
|
+
}, T = y({
|
|
580
583
|
name: "DocumentEditor",
|
|
581
584
|
props: {
|
|
582
585
|
id: {
|
|
@@ -628,59 +631,59 @@ var be = function(n, e) {
|
|
|
628
631
|
events_onRequestSelectDocument: Function
|
|
629
632
|
},
|
|
630
633
|
mounted: function() {
|
|
631
|
-
var n = this,
|
|
632
|
-
|
|
633
|
-
var o = "".concat(
|
|
634
|
-
|
|
634
|
+
var n = this, t = this.documentServerUrl;
|
|
635
|
+
t.endsWith("/") || (t += "/");
|
|
636
|
+
var o = "".concat(t, "web-apps/apps/api/documents/api.js");
|
|
637
|
+
xe(o, "onlyoffice-api-script").then(function() {
|
|
635
638
|
return n.onLoad();
|
|
636
639
|
}).catch(function() {
|
|
637
640
|
n.onError(-2);
|
|
638
641
|
});
|
|
639
642
|
},
|
|
640
643
|
unmounted: function() {
|
|
641
|
-
var n,
|
|
642
|
-
!((n = window == null ? void 0 : window.DocEditor) === null || n === void 0) && n.instances[
|
|
644
|
+
var n, t = this.id || "";
|
|
645
|
+
!((n = window == null ? void 0 : window.DocEditor) === null || n === void 0) && n.instances[t] && (window.DocEditor.instances[t].destroyEditor(), window.DocEditor.instances[t] = void 0);
|
|
643
646
|
},
|
|
644
647
|
watch: {
|
|
645
648
|
config: {
|
|
646
|
-
handler: function(n,
|
|
649
|
+
handler: function(n, t) {
|
|
647
650
|
this.onChangeProps();
|
|
648
651
|
},
|
|
649
652
|
deep: !0
|
|
650
653
|
},
|
|
651
|
-
document_fileType: function(n,
|
|
654
|
+
document_fileType: function(n, t) {
|
|
652
655
|
this.onChangeProps();
|
|
653
656
|
},
|
|
654
|
-
document_title: function(n,
|
|
657
|
+
document_title: function(n, t) {
|
|
655
658
|
this.onChangeProps();
|
|
656
659
|
},
|
|
657
|
-
documentType: function(n,
|
|
660
|
+
documentType: function(n, t) {
|
|
658
661
|
this.onChangeProps();
|
|
659
662
|
},
|
|
660
|
-
editorConfig_lang: function(n,
|
|
663
|
+
editorConfig_lang: function(n, t) {
|
|
661
664
|
this.onChangeProps();
|
|
662
665
|
},
|
|
663
|
-
height: function(n,
|
|
666
|
+
height: function(n, t) {
|
|
664
667
|
this.onChangeProps();
|
|
665
668
|
},
|
|
666
|
-
type: function(n,
|
|
669
|
+
type: function(n, t) {
|
|
667
670
|
this.onChangeProps();
|
|
668
671
|
},
|
|
669
|
-
width: function(n,
|
|
672
|
+
width: function(n, t) {
|
|
670
673
|
this.onChangeProps();
|
|
671
674
|
}
|
|
672
675
|
},
|
|
673
676
|
methods: {
|
|
674
677
|
onLoad: function() {
|
|
675
|
-
var n,
|
|
678
|
+
var n, t;
|
|
676
679
|
try {
|
|
677
680
|
var o = this.id || "";
|
|
678
681
|
if (window.DocsAPI || this.onError(-3), !((n = window == null ? void 0 : window.DocEditor) === null || n === void 0) && n.instances[o]) {
|
|
679
682
|
console.log("Skip loading. Instance already exists", o);
|
|
680
683
|
return;
|
|
681
684
|
}
|
|
682
|
-
!((
|
|
683
|
-
var
|
|
685
|
+
!((t = window == null ? void 0 : window.DocEditor) === null || t === void 0) && t.instances || (window.DocEditor = { instances: {} });
|
|
686
|
+
var e = Object.assign({
|
|
684
687
|
document: {
|
|
685
688
|
fileType: this.document_fileType,
|
|
686
689
|
title: this.document_title
|
|
@@ -715,43 +718,43 @@ var be = function(n, e) {
|
|
|
715
718
|
height: this.height,
|
|
716
719
|
type: this.type,
|
|
717
720
|
width: this.width
|
|
718
|
-
}, this.config || {}),
|
|
719
|
-
window.DocEditor.instances[o] =
|
|
721
|
+
}, this.config || {}), l = window.DocsAPI.DocEditor(o, e);
|
|
722
|
+
window.DocEditor.instances[o] = l;
|
|
720
723
|
} catch (i) {
|
|
721
724
|
console.error(i), this.onError(-1);
|
|
722
725
|
}
|
|
723
726
|
},
|
|
724
727
|
onError: function(n) {
|
|
725
|
-
var
|
|
728
|
+
var t;
|
|
726
729
|
switch (n) {
|
|
727
730
|
case -2:
|
|
728
|
-
|
|
731
|
+
t = "Error load DocsAPI from " + this.documentServerUrl;
|
|
729
732
|
break;
|
|
730
733
|
case -3:
|
|
731
|
-
|
|
734
|
+
t = "DocsAPI is not defined";
|
|
732
735
|
break;
|
|
733
736
|
default:
|
|
734
|
-
|
|
737
|
+
t = "Unknown error loading component", n = -1;
|
|
735
738
|
}
|
|
736
|
-
typeof this.onLoadComponentError > "u" ? console.error(
|
|
739
|
+
typeof this.onLoadComponentError > "u" ? console.error(t) : this.onLoadComponentError(n, t);
|
|
737
740
|
},
|
|
738
741
|
onAppReady: function() {
|
|
739
742
|
var n = this.id || "";
|
|
740
743
|
this.events_onAppReady(window.DocEditor.instances[n]);
|
|
741
744
|
},
|
|
742
745
|
onChangeProps: function() {
|
|
743
|
-
var n,
|
|
744
|
-
!((n = window == null ? void 0 : window.DocEditor) === null || n === void 0) && n.instances[
|
|
746
|
+
var n, t = this.id || "";
|
|
747
|
+
!((n = window == null ? void 0 : window.DocEditor) === null || n === void 0) && n.instances[t] && (window.DocEditor.instances[t].destroyEditor(), window.DocEditor.instances[t] = void 0, console.log("Important props have been changed. Load new Editor."), this.onLoad());
|
|
745
748
|
}
|
|
746
749
|
}
|
|
747
750
|
});
|
|
748
751
|
const Re = ["id"];
|
|
749
|
-
function Se(n,
|
|
750
|
-
return
|
|
752
|
+
function Se(n, t, o, e, l, i) {
|
|
753
|
+
return r(), f("div", { id: n.id }, null, 8, Re);
|
|
751
754
|
}
|
|
752
755
|
T.render = Se;
|
|
753
756
|
T.__file = "src/components/DocumentEditor.vue";
|
|
754
|
-
const Ce = /* @__PURE__ */
|
|
757
|
+
const Ce = /* @__PURE__ */ y({
|
|
755
758
|
__name: "IkOnlyOffice",
|
|
756
759
|
props: {
|
|
757
760
|
// 文件服务器的服务的地址
|
|
@@ -772,26 +775,26 @@ const Ce = /* @__PURE__ */ h({
|
|
|
772
775
|
}
|
|
773
776
|
},
|
|
774
777
|
setup(n) {
|
|
775
|
-
const
|
|
778
|
+
const t = n, o = q({
|
|
776
779
|
width: "100%",
|
|
777
780
|
height: "100%",
|
|
778
|
-
...
|
|
779
|
-
...
|
|
780
|
-
}),
|
|
781
|
-
console.info("文档加载完成",
|
|
781
|
+
...t.configOptions || {},
|
|
782
|
+
...t.configOptions
|
|
783
|
+
}), e = () => {
|
|
784
|
+
console.info("文档加载完成", t.configOptions);
|
|
782
785
|
};
|
|
783
|
-
return (
|
|
786
|
+
return (l, i) => (r(), f(
|
|
784
787
|
"div",
|
|
785
788
|
{
|
|
786
|
-
style: m({ height:
|
|
789
|
+
style: m({ height: t.officeHeight })
|
|
787
790
|
},
|
|
788
791
|
[
|
|
789
|
-
D(
|
|
792
|
+
D(w(T), {
|
|
790
793
|
id: `${(/* @__PURE__ */ new Date()).getTime()}`,
|
|
791
794
|
ref: "editorRef",
|
|
792
795
|
"document-server-url": n.documentServerUrl,
|
|
793
796
|
config: o.value,
|
|
794
|
-
events_onDocumentReady:
|
|
797
|
+
events_onDocumentReady: e
|
|
795
798
|
}, null, 8, ["id", "document-server-url", "config"])
|
|
796
799
|
],
|
|
797
800
|
4
|
|
@@ -799,7 +802,7 @@ const Ce = /* @__PURE__ */ h({
|
|
|
799
802
|
));
|
|
800
803
|
}
|
|
801
804
|
});
|
|
802
|
-
const Ie = /* @__PURE__ */ V(Ce, [["__scopeId", "data-v-98d51ef9"]]), ze =
|
|
805
|
+
const Ie = /* @__PURE__ */ V(Ce, [["__scopeId", "data-v-98d51ef9"]]), ze = E(Ie), De = /* @__PURE__ */ y({
|
|
803
806
|
__name: "IkPreviewFileDialog",
|
|
804
807
|
props: /* @__PURE__ */ H({
|
|
805
808
|
file: {
|
|
@@ -836,81 +839,81 @@ const Ie = /* @__PURE__ */ V(Ce, [["__scopeId", "data-v-98d51ef9"]]), ze = q(Ie)
|
|
|
836
839
|
}),
|
|
837
840
|
emits: ["update:show"],
|
|
838
841
|
setup(n) {
|
|
839
|
-
const
|
|
842
|
+
const t = n, o = W(n, "show"), e = C(() => ({
|
|
840
843
|
name: "name",
|
|
841
844
|
url: "url",
|
|
842
845
|
suffix: "suffix",
|
|
843
846
|
size: "fileSize",
|
|
844
|
-
...
|
|
845
|
-
})),
|
|
847
|
+
...t.field
|
|
848
|
+
})), l = q(null), i = q(null), s = J({
|
|
846
849
|
image: !1,
|
|
847
850
|
office: !1,
|
|
848
851
|
video: !1
|
|
849
|
-
}),
|
|
850
|
-
var
|
|
852
|
+
}), c = (a) => {
|
|
853
|
+
var u, v, b, x, g, A, P;
|
|
851
854
|
try {
|
|
852
|
-
const
|
|
855
|
+
const p = ((u = a == null ? void 0 : a.response) == null ? void 0 : u.data) || a, j = p[e.value.url] || (p == null ? void 0 : p.id) || p.attachmentId, F = (v = p[e.value.suffix] || p.attachmentSuffix) == null ? void 0 : v.toLowerCase(), N = p[e.value.name] || (p == null ? void 0 : p.attachmentName) || (p == null ? void 0 : p.originName);
|
|
853
856
|
if (i.value = {
|
|
854
|
-
...
|
|
855
|
-
name:
|
|
856
|
-
url: M(
|
|
857
|
-
},
|
|
858
|
-
|
|
857
|
+
...a,
|
|
858
|
+
name: a[e.value.name],
|
|
859
|
+
url: M(t.loadUrl, j)
|
|
860
|
+
}, a && oe(a, e.value) === "image") {
|
|
861
|
+
s.image = !0;
|
|
859
862
|
return;
|
|
860
|
-
} else if ((((
|
|
861
|
-
|
|
862
|
-
...
|
|
863
|
+
} else if ((((b = t.onlyOfficeConfig) == null ? void 0 : b.accept) || t.onlyOfficeAccept).includes(F)) {
|
|
864
|
+
s.office = !0, l.value = {
|
|
865
|
+
...t.onlyOfficeConfig,
|
|
863
866
|
editorConfig: {
|
|
864
|
-
...((
|
|
867
|
+
...((x = t.onlyOfficeConfig) == null ? void 0 : x.editorConfig) || {},
|
|
865
868
|
customization: {
|
|
866
|
-
...((A = (
|
|
869
|
+
...((A = (g = t.onlyOfficeConfig) == null ? void 0 : g.editorConfig) == null ? void 0 : A.customization) || {},
|
|
867
870
|
review: {
|
|
868
871
|
reviewDisplay: "final"
|
|
869
872
|
}
|
|
870
873
|
}
|
|
871
874
|
},
|
|
872
875
|
document: {
|
|
873
|
-
key:
|
|
876
|
+
key: ne(),
|
|
874
877
|
title: N,
|
|
875
|
-
url: M(
|
|
876
|
-
fileType:
|
|
877
|
-
...((P =
|
|
878
|
+
url: M(t.loadUrl, j),
|
|
879
|
+
fileType: F,
|
|
880
|
+
...((P = t.onlyOfficeConfig) == null ? void 0 : P.document) || {}
|
|
878
881
|
},
|
|
879
|
-
documentType:
|
|
882
|
+
documentType: se(F)
|
|
880
883
|
};
|
|
881
884
|
return;
|
|
882
885
|
}
|
|
883
|
-
} catch (
|
|
884
|
-
console.info("预览错误: ",
|
|
886
|
+
} catch (p) {
|
|
887
|
+
console.info("预览错误: ", p);
|
|
885
888
|
}
|
|
886
889
|
};
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
+
Q([o, t.file], ([a, u]) => {
|
|
891
|
+
a && Z(() => {
|
|
892
|
+
c(t.file);
|
|
890
893
|
});
|
|
891
894
|
});
|
|
892
|
-
const
|
|
893
|
-
o.value = !1,
|
|
895
|
+
const d = () => {
|
|
896
|
+
o.value = !1, s.office = !1, s.image = !1, s.video = !1;
|
|
894
897
|
};
|
|
895
|
-
return (
|
|
896
|
-
var
|
|
897
|
-
const
|
|
898
|
-
return o.value ? (
|
|
899
|
-
|
|
898
|
+
return (a, u) => {
|
|
899
|
+
var b, x;
|
|
900
|
+
const v = z("el-image-viewer");
|
|
901
|
+
return o.value ? (r(), f(
|
|
902
|
+
ee,
|
|
900
903
|
{ key: 0 },
|
|
901
904
|
[
|
|
902
|
-
(
|
|
905
|
+
(b = i.value) != null && b.url && s.image ? (r(), k(v, {
|
|
903
906
|
key: 0,
|
|
904
|
-
onClose:
|
|
905
|
-
i.value = null,
|
|
907
|
+
onClose: u[0] || (u[0] = (g) => {
|
|
908
|
+
i.value = null, s.image = !1;
|
|
906
909
|
}),
|
|
907
910
|
ref: "previewImgRef",
|
|
908
|
-
"url-list": [(
|
|
909
|
-
}, null, 8, ["url-list"])) :
|
|
910
|
-
|
|
911
|
-
D(
|
|
912
|
-
modelValue:
|
|
913
|
-
"onUpdate:modelValue":
|
|
911
|
+
"url-list": [(x = i.value) == null ? void 0 : x.url]
|
|
912
|
+
}, null, 8, ["url-list"])) : R("v-if", !0),
|
|
913
|
+
R(" 文档类 "),
|
|
914
|
+
D(w(_e), {
|
|
915
|
+
modelValue: s.office,
|
|
916
|
+
"onUpdate:modelValue": u[1] || (u[1] = (g) => s.office = g),
|
|
914
917
|
draggable: "",
|
|
915
918
|
"no-footer": "",
|
|
916
919
|
"no-header": "",
|
|
@@ -920,27 +923,30 @@ const Ie = /* @__PURE__ */ V(Ce, [["__scopeId", "data-v-98d51ef9"]]), ze = q(Ie)
|
|
|
920
923
|
"close-on-click-modal": "",
|
|
921
924
|
"close-on-press-escape": !1,
|
|
922
925
|
"append-to-body": "",
|
|
923
|
-
onClose:
|
|
926
|
+
onClose: d,
|
|
924
927
|
"modal-class": "ik-only-preview-dialog"
|
|
925
928
|
}, {
|
|
926
|
-
default:
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
929
|
+
default: h(() => {
|
|
930
|
+
var g;
|
|
931
|
+
return [
|
|
932
|
+
D(w(ze), {
|
|
933
|
+
"config-options": l.value,
|
|
934
|
+
"document-server-url": ((g = n.onlyOfficeConfig) == null ? void 0 : g.serverUrl) || n.onlyofficeServer
|
|
935
|
+
}, null, 8, ["config-options", "document-server-url"])
|
|
936
|
+
];
|
|
937
|
+
}),
|
|
932
938
|
_: 1
|
|
933
939
|
/* STABLE */
|
|
934
940
|
}, 8, ["modelValue"])
|
|
935
941
|
],
|
|
936
942
|
64
|
|
937
943
|
/* STABLE_FRAGMENT */
|
|
938
|
-
)) :
|
|
944
|
+
)) : R("v-if", !0);
|
|
939
945
|
};
|
|
940
946
|
}
|
|
941
947
|
});
|
|
942
|
-
const
|
|
948
|
+
const Be = E(De);
|
|
943
949
|
export {
|
|
944
|
-
|
|
945
|
-
|
|
950
|
+
Be as IkPreviewFileDialog,
|
|
951
|
+
Be as default
|
|
946
952
|
};
|