@gct-paas/design-web 0.1.4-dev.10 → 0.1.4-dev.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.min.mjs +403 -1173
- package/dist/index.min.cjs +1 -57
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -57
- package/es/components/I18nSelect/src/i18n-select-btn.css +13 -13
- package/es/components/I18nSelect/src/i18n-select-btn.vue.d.ts +1 -2
- package/es/components/I18nSelect/src/i18n-select-btn.vue.mjs +1 -1
- package/package.json +9 -9
package/dist/index.esm.min.mjs
CHANGED
|
@@ -1,876 +1,106 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { has as
|
|
3
|
-
import { useModalInner as
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var t = mt(e);
|
|
8
|
-
return e = n === 360 ? e : Math.min(n, Math.max(0, parseFloat(e))), t && (e = parseInt(String(e * n), 10) / 100), Math.abs(e - n) < 1e-6 ? 1 : (n === 360 ? e = (e < 0 ? e % n + n : e % n) / parseFloat(String(n)) : e = e % n / parseFloat(String(n)), e);
|
|
9
|
-
}
|
|
10
|
-
function pt(e) {
|
|
11
|
-
return typeof e == "string" && e.indexOf(".") !== -1 && parseFloat(e) === 1;
|
|
12
|
-
}
|
|
13
|
-
function mt(e) {
|
|
14
|
-
return typeof e == "string" && e.indexOf("%") !== -1;
|
|
15
|
-
}
|
|
16
|
-
function gt(e) {
|
|
17
|
-
return e = parseFloat(e), (isNaN(e) || e < 0 || e > 1) && (e = 1), e;
|
|
18
|
-
}
|
|
19
|
-
function re(e) {
|
|
20
|
-
return e <= 1 ? "".concat(Number(e) * 100, "%") : e;
|
|
21
|
-
}
|
|
22
|
-
function fe(e) {
|
|
23
|
-
return e.length === 1 ? "0" + e : String(e);
|
|
24
|
-
}
|
|
25
|
-
function yt(e, n, t) {
|
|
26
|
-
return {
|
|
27
|
-
r: P(e, 255) * 255,
|
|
28
|
-
g: P(n, 255) * 255,
|
|
29
|
-
b: P(t, 255) * 255
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
function de(e, n, t) {
|
|
33
|
-
return t < 0 && (t += 1), t > 1 && (t -= 1), t < 1 / 6 ? e + (n - e) * (6 * t) : t < 1 / 2 ? n : t < 2 / 3 ? e + (n - e) * (2 / 3 - t) * 6 : e;
|
|
34
|
-
}
|
|
35
|
-
function bt(e, n, t) {
|
|
36
|
-
var r, a, o;
|
|
37
|
-
if (e = P(e, 360), n = P(n, 100), t = P(t, 100), n === 0)
|
|
38
|
-
a = t, o = t, r = t;
|
|
39
|
-
else {
|
|
40
|
-
var i = t < 0.5 ? t * (1 + n) : t + n - t * n, l = 2 * t - i;
|
|
41
|
-
r = de(l, i, e + 1 / 3), a = de(l, i, e), o = de(l, i, e - 1 / 3);
|
|
42
|
-
}
|
|
43
|
-
return { r: r * 255, g: a * 255, b: o * 255 };
|
|
44
|
-
}
|
|
45
|
-
function ht(e, n, t) {
|
|
46
|
-
e = P(e, 255), n = P(n, 255), t = P(t, 255);
|
|
47
|
-
var r = Math.max(e, n, t), a = Math.min(e, n, t), o = 0, i = r, l = r - a, s = r === 0 ? 0 : l / r;
|
|
48
|
-
if (r === a)
|
|
49
|
-
o = 0;
|
|
50
|
-
else {
|
|
51
|
-
switch (r) {
|
|
52
|
-
case e:
|
|
53
|
-
o = (n - t) / l + (n < t ? 6 : 0);
|
|
54
|
-
break;
|
|
55
|
-
case n:
|
|
56
|
-
o = (t - e) / l + 2;
|
|
57
|
-
break;
|
|
58
|
-
case t:
|
|
59
|
-
o = (e - n) / l + 4;
|
|
60
|
-
break;
|
|
61
|
-
}
|
|
62
|
-
o /= 6;
|
|
63
|
-
}
|
|
64
|
-
return { h: o, s, v: i };
|
|
65
|
-
}
|
|
66
|
-
function vt(e, n, t) {
|
|
67
|
-
e = P(e, 360) * 6, n = P(n, 100), t = P(t, 100);
|
|
68
|
-
var r = Math.floor(e), a = e - r, o = t * (1 - n), i = t * (1 - a * n), l = t * (1 - (1 - a) * n), s = r % 6, c = [t, i, o, o, l, t][s], p = [l, t, t, i, o, o][s], g = [o, o, l, t, t, i][s];
|
|
69
|
-
return { r: c * 255, g: p * 255, b: g * 255 };
|
|
70
|
-
}
|
|
71
|
-
function Ct(e, n, t, r) {
|
|
72
|
-
var a = [
|
|
73
|
-
fe(Math.round(e).toString(16)),
|
|
74
|
-
fe(Math.round(n).toString(16)),
|
|
75
|
-
fe(Math.round(t).toString(16))
|
|
76
|
-
];
|
|
77
|
-
return a.join("");
|
|
78
|
-
}
|
|
79
|
-
function _e(e) {
|
|
80
|
-
return _(e) / 255;
|
|
81
|
-
}
|
|
82
|
-
function _(e) {
|
|
83
|
-
return parseInt(e, 16);
|
|
84
|
-
}
|
|
85
|
-
var Ee = {
|
|
86
|
-
aliceblue: "#f0f8ff",
|
|
87
|
-
antiquewhite: "#faebd7",
|
|
88
|
-
aqua: "#00ffff",
|
|
89
|
-
aquamarine: "#7fffd4",
|
|
90
|
-
azure: "#f0ffff",
|
|
91
|
-
beige: "#f5f5dc",
|
|
92
|
-
bisque: "#ffe4c4",
|
|
93
|
-
black: "#000000",
|
|
94
|
-
blanchedalmond: "#ffebcd",
|
|
95
|
-
blue: "#0000ff",
|
|
96
|
-
blueviolet: "#8a2be2",
|
|
97
|
-
brown: "#a52a2a",
|
|
98
|
-
burlywood: "#deb887",
|
|
99
|
-
cadetblue: "#5f9ea0",
|
|
100
|
-
chartreuse: "#7fff00",
|
|
101
|
-
chocolate: "#d2691e",
|
|
102
|
-
coral: "#ff7f50",
|
|
103
|
-
cornflowerblue: "#6495ed",
|
|
104
|
-
cornsilk: "#fff8dc",
|
|
105
|
-
crimson: "#dc143c",
|
|
106
|
-
cyan: "#00ffff",
|
|
107
|
-
darkblue: "#00008b",
|
|
108
|
-
darkcyan: "#008b8b",
|
|
109
|
-
darkgoldenrod: "#b8860b",
|
|
110
|
-
darkgray: "#a9a9a9",
|
|
111
|
-
darkgreen: "#006400",
|
|
112
|
-
darkgrey: "#a9a9a9",
|
|
113
|
-
darkkhaki: "#bdb76b",
|
|
114
|
-
darkmagenta: "#8b008b",
|
|
115
|
-
darkolivegreen: "#556b2f",
|
|
116
|
-
darkorange: "#ff8c00",
|
|
117
|
-
darkorchid: "#9932cc",
|
|
118
|
-
darkred: "#8b0000",
|
|
119
|
-
darksalmon: "#e9967a",
|
|
120
|
-
darkseagreen: "#8fbc8f",
|
|
121
|
-
darkslateblue: "#483d8b",
|
|
122
|
-
darkslategray: "#2f4f4f",
|
|
123
|
-
darkslategrey: "#2f4f4f",
|
|
124
|
-
darkturquoise: "#00ced1",
|
|
125
|
-
darkviolet: "#9400d3",
|
|
126
|
-
deeppink: "#ff1493",
|
|
127
|
-
deepskyblue: "#00bfff",
|
|
128
|
-
dimgray: "#696969",
|
|
129
|
-
dimgrey: "#696969",
|
|
130
|
-
dodgerblue: "#1e90ff",
|
|
131
|
-
firebrick: "#b22222",
|
|
132
|
-
floralwhite: "#fffaf0",
|
|
133
|
-
forestgreen: "#228b22",
|
|
134
|
-
fuchsia: "#ff00ff",
|
|
135
|
-
gainsboro: "#dcdcdc",
|
|
136
|
-
ghostwhite: "#f8f8ff",
|
|
137
|
-
goldenrod: "#daa520",
|
|
138
|
-
gold: "#ffd700",
|
|
139
|
-
gray: "#808080",
|
|
140
|
-
green: "#008000",
|
|
141
|
-
greenyellow: "#adff2f",
|
|
142
|
-
grey: "#808080",
|
|
143
|
-
honeydew: "#f0fff0",
|
|
144
|
-
hotpink: "#ff69b4",
|
|
145
|
-
indianred: "#cd5c5c",
|
|
146
|
-
indigo: "#4b0082",
|
|
147
|
-
ivory: "#fffff0",
|
|
148
|
-
khaki: "#f0e68c",
|
|
149
|
-
lavenderblush: "#fff0f5",
|
|
150
|
-
lavender: "#e6e6fa",
|
|
151
|
-
lawngreen: "#7cfc00",
|
|
152
|
-
lemonchiffon: "#fffacd",
|
|
153
|
-
lightblue: "#add8e6",
|
|
154
|
-
lightcoral: "#f08080",
|
|
155
|
-
lightcyan: "#e0ffff",
|
|
156
|
-
lightgoldenrodyellow: "#fafad2",
|
|
157
|
-
lightgray: "#d3d3d3",
|
|
158
|
-
lightgreen: "#90ee90",
|
|
159
|
-
lightgrey: "#d3d3d3",
|
|
160
|
-
lightpink: "#ffb6c1",
|
|
161
|
-
lightsalmon: "#ffa07a",
|
|
162
|
-
lightseagreen: "#20b2aa",
|
|
163
|
-
lightskyblue: "#87cefa",
|
|
164
|
-
lightslategray: "#778899",
|
|
165
|
-
lightslategrey: "#778899",
|
|
166
|
-
lightsteelblue: "#b0c4de",
|
|
167
|
-
lightyellow: "#ffffe0",
|
|
168
|
-
lime: "#00ff00",
|
|
169
|
-
limegreen: "#32cd32",
|
|
170
|
-
linen: "#faf0e6",
|
|
171
|
-
magenta: "#ff00ff",
|
|
172
|
-
maroon: "#800000",
|
|
173
|
-
mediumaquamarine: "#66cdaa",
|
|
174
|
-
mediumblue: "#0000cd",
|
|
175
|
-
mediumorchid: "#ba55d3",
|
|
176
|
-
mediumpurple: "#9370db",
|
|
177
|
-
mediumseagreen: "#3cb371",
|
|
178
|
-
mediumslateblue: "#7b68ee",
|
|
179
|
-
mediumspringgreen: "#00fa9a",
|
|
180
|
-
mediumturquoise: "#48d1cc",
|
|
181
|
-
mediumvioletred: "#c71585",
|
|
182
|
-
midnightblue: "#191970",
|
|
183
|
-
mintcream: "#f5fffa",
|
|
184
|
-
mistyrose: "#ffe4e1",
|
|
185
|
-
moccasin: "#ffe4b5",
|
|
186
|
-
navajowhite: "#ffdead",
|
|
187
|
-
navy: "#000080",
|
|
188
|
-
oldlace: "#fdf5e6",
|
|
189
|
-
olive: "#808000",
|
|
190
|
-
olivedrab: "#6b8e23",
|
|
191
|
-
orange: "#ffa500",
|
|
192
|
-
orangered: "#ff4500",
|
|
193
|
-
orchid: "#da70d6",
|
|
194
|
-
palegoldenrod: "#eee8aa",
|
|
195
|
-
palegreen: "#98fb98",
|
|
196
|
-
paleturquoise: "#afeeee",
|
|
197
|
-
palevioletred: "#db7093",
|
|
198
|
-
papayawhip: "#ffefd5",
|
|
199
|
-
peachpuff: "#ffdab9",
|
|
200
|
-
peru: "#cd853f",
|
|
201
|
-
pink: "#ffc0cb",
|
|
202
|
-
plum: "#dda0dd",
|
|
203
|
-
powderblue: "#b0e0e6",
|
|
204
|
-
purple: "#800080",
|
|
205
|
-
rebeccapurple: "#663399",
|
|
206
|
-
red: "#ff0000",
|
|
207
|
-
rosybrown: "#bc8f8f",
|
|
208
|
-
royalblue: "#4169e1",
|
|
209
|
-
saddlebrown: "#8b4513",
|
|
210
|
-
salmon: "#fa8072",
|
|
211
|
-
sandybrown: "#f4a460",
|
|
212
|
-
seagreen: "#2e8b57",
|
|
213
|
-
seashell: "#fff5ee",
|
|
214
|
-
sienna: "#a0522d",
|
|
215
|
-
silver: "#c0c0c0",
|
|
216
|
-
skyblue: "#87ceeb",
|
|
217
|
-
slateblue: "#6a5acd",
|
|
218
|
-
slategray: "#708090",
|
|
219
|
-
slategrey: "#708090",
|
|
220
|
-
snow: "#fffafa",
|
|
221
|
-
springgreen: "#00ff7f",
|
|
222
|
-
steelblue: "#4682b4",
|
|
223
|
-
tan: "#d2b48c",
|
|
224
|
-
teal: "#008080",
|
|
225
|
-
thistle: "#d8bfd8",
|
|
226
|
-
tomato: "#ff6347",
|
|
227
|
-
turquoise: "#40e0d0",
|
|
228
|
-
violet: "#ee82ee",
|
|
229
|
-
wheat: "#f5deb3",
|
|
230
|
-
white: "#ffffff",
|
|
231
|
-
whitesmoke: "#f5f5f5",
|
|
232
|
-
yellow: "#ffff00",
|
|
233
|
-
yellowgreen: "#9acd32"
|
|
234
|
-
};
|
|
235
|
-
function Z(e) {
|
|
236
|
-
var n = { r: 0, g: 0, b: 0 }, t = 1, r = null, a = null, o = null, i = !1, l = !1;
|
|
237
|
-
return typeof e == "string" && (e = St(e)), typeof e == "object" && (z(e.r) && z(e.g) && z(e.b) ? (n = yt(e.r, e.g, e.b), i = !0, l = String(e.r).substr(-1) === "%" ? "prgb" : "rgb") : z(e.h) && z(e.s) && z(e.v) ? (r = re(e.s), a = re(e.v), n = vt(e.h, r, a), i = !0, l = "hsv") : z(e.h) && z(e.s) && z(e.l) && (r = re(e.s), o = re(e.l), n = bt(e.h, r, o), i = !0, l = "hsl"), Object.prototype.hasOwnProperty.call(e, "a") && (t = e.a)), t = gt(t), {
|
|
238
|
-
ok: i,
|
|
239
|
-
format: e.format || l,
|
|
240
|
-
r: Math.min(255, Math.max(n.r, 0)),
|
|
241
|
-
g: Math.min(255, Math.max(n.g, 0)),
|
|
242
|
-
b: Math.min(255, Math.max(n.b, 0)),
|
|
243
|
-
a: t
|
|
244
|
-
};
|
|
245
|
-
}
|
|
246
|
-
var xt = "[-\\+]?\\d+%?", wt = "[-\\+]?\\d*\\.\\d+%?", V = "(?:".concat(wt, ")|(?:").concat(xt, ")"), pe = "[\\s|\\(]+(".concat(V, ")[,|\\s]+(").concat(V, ")[,|\\s]+(").concat(V, ")\\s*\\)?"), me = "[\\s|\\(]+(".concat(V, ")[,|\\s]+(").concat(V, ")[,|\\s]+(").concat(V, ")[,|\\s]+(").concat(V, ")\\s*\\)?"), M = {
|
|
247
|
-
CSS_UNIT: new RegExp(V),
|
|
248
|
-
rgb: new RegExp("rgb" + pe),
|
|
249
|
-
rgba: new RegExp("rgba" + me),
|
|
250
|
-
hsl: new RegExp("hsl" + pe),
|
|
251
|
-
hsla: new RegExp("hsla" + me),
|
|
252
|
-
hsv: new RegExp("hsv" + pe),
|
|
253
|
-
hsva: new RegExp("hsva" + me),
|
|
254
|
-
hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
|
|
255
|
-
hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
|
|
256
|
-
hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
|
|
257
|
-
hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/
|
|
258
|
-
};
|
|
259
|
-
function St(e) {
|
|
260
|
-
if (e = e.trim().toLowerCase(), e.length === 0)
|
|
261
|
-
return !1;
|
|
262
|
-
var n = !1;
|
|
263
|
-
if (Ee[e])
|
|
264
|
-
e = Ee[e], n = !0;
|
|
265
|
-
else if (e === "transparent")
|
|
266
|
-
return { r: 0, g: 0, b: 0, a: 0, format: "name" };
|
|
267
|
-
var t = M.rgb.exec(e);
|
|
268
|
-
return t ? { r: t[1], g: t[2], b: t[3] } : (t = M.rgba.exec(e), t ? { r: t[1], g: t[2], b: t[3], a: t[4] } : (t = M.hsl.exec(e), t ? { h: t[1], s: t[2], l: t[3] } : (t = M.hsla.exec(e), t ? { h: t[1], s: t[2], l: t[3], a: t[4] } : (t = M.hsv.exec(e), t ? { h: t[1], s: t[2], v: t[3] } : (t = M.hsva.exec(e), t ? { h: t[1], s: t[2], v: t[3], a: t[4] } : (t = M.hex8.exec(e), t ? {
|
|
269
|
-
r: _(t[1]),
|
|
270
|
-
g: _(t[2]),
|
|
271
|
-
b: _(t[3]),
|
|
272
|
-
a: _e(t[4]),
|
|
273
|
-
format: n ? "name" : "hex8"
|
|
274
|
-
} : (t = M.hex6.exec(e), t ? {
|
|
275
|
-
r: _(t[1]),
|
|
276
|
-
g: _(t[2]),
|
|
277
|
-
b: _(t[3]),
|
|
278
|
-
format: n ? "name" : "hex"
|
|
279
|
-
} : (t = M.hex4.exec(e), t ? {
|
|
280
|
-
r: _(t[1] + t[1]),
|
|
281
|
-
g: _(t[2] + t[2]),
|
|
282
|
-
b: _(t[3] + t[3]),
|
|
283
|
-
a: _e(t[4] + t[4]),
|
|
284
|
-
format: n ? "name" : "hex8"
|
|
285
|
-
} : (t = M.hex3.exec(e), t ? {
|
|
286
|
-
r: _(t[1] + t[1]),
|
|
287
|
-
g: _(t[2] + t[2]),
|
|
288
|
-
b: _(t[3] + t[3]),
|
|
289
|
-
format: n ? "name" : "hex"
|
|
290
|
-
} : !1)))))))));
|
|
291
|
-
}
|
|
292
|
-
function z(e) {
|
|
293
|
-
return !!M.CSS_UNIT.exec(String(e));
|
|
294
|
-
}
|
|
295
|
-
var ae = 2, Ae = 0.16, kt = 0.05, Ot = 0.05, It = 0.15, Je = 5, Ge = 4, Tt = [{
|
|
296
|
-
index: 7,
|
|
297
|
-
opacity: 0.15
|
|
298
|
-
}, {
|
|
299
|
-
index: 6,
|
|
300
|
-
opacity: 0.25
|
|
301
|
-
}, {
|
|
302
|
-
index: 5,
|
|
303
|
-
opacity: 0.3
|
|
304
|
-
}, {
|
|
305
|
-
index: 5,
|
|
306
|
-
opacity: 0.45
|
|
307
|
-
}, {
|
|
308
|
-
index: 5,
|
|
309
|
-
opacity: 0.65
|
|
310
|
-
}, {
|
|
311
|
-
index: 5,
|
|
312
|
-
opacity: 0.85
|
|
313
|
-
}, {
|
|
314
|
-
index: 4,
|
|
315
|
-
opacity: 0.9
|
|
316
|
-
}, {
|
|
317
|
-
index: 3,
|
|
318
|
-
opacity: 0.95
|
|
319
|
-
}, {
|
|
320
|
-
index: 2,
|
|
321
|
-
opacity: 0.97
|
|
322
|
-
}, {
|
|
323
|
-
index: 1,
|
|
324
|
-
opacity: 0.98
|
|
325
|
-
}];
|
|
326
|
-
function Pe(e) {
|
|
327
|
-
var n = e.r, t = e.g, r = e.b, a = ht(n, t, r);
|
|
328
|
-
return {
|
|
329
|
-
h: a.h * 360,
|
|
330
|
-
s: a.s,
|
|
331
|
-
v: a.v
|
|
332
|
-
};
|
|
333
|
-
}
|
|
334
|
-
function oe(e) {
|
|
335
|
-
var n = e.r, t = e.g, r = e.b;
|
|
336
|
-
return "#".concat(Ct(n, t, r));
|
|
337
|
-
}
|
|
338
|
-
function _t(e, n, t) {
|
|
339
|
-
var r = t / 100, a = {
|
|
340
|
-
r: (n.r - e.r) * r + e.r,
|
|
341
|
-
g: (n.g - e.g) * r + e.g,
|
|
342
|
-
b: (n.b - e.b) * r + e.b
|
|
343
|
-
};
|
|
344
|
-
return a;
|
|
345
|
-
}
|
|
346
|
-
function Me(e, n, t) {
|
|
347
|
-
var r;
|
|
348
|
-
return Math.round(e.h) >= 60 && Math.round(e.h) <= 240 ? r = t ? Math.round(e.h) - ae * n : Math.round(e.h) + ae * n : r = t ? Math.round(e.h) + ae * n : Math.round(e.h) - ae * n, r < 0 ? r += 360 : r >= 360 && (r -= 360), r;
|
|
349
|
-
}
|
|
350
|
-
function $e(e, n, t) {
|
|
351
|
-
if (e.h === 0 && e.s === 0)
|
|
352
|
-
return e.s;
|
|
353
|
-
var r;
|
|
354
|
-
return t ? r = e.s - Ae * n : n === Ge ? r = e.s + Ae : r = e.s + kt * n, r > 1 && (r = 1), t && n === Je && r > 0.1 && (r = 0.1), r < 0.06 && (r = 0.06), Number(r.toFixed(2));
|
|
355
|
-
}
|
|
356
|
-
function je(e, n, t) {
|
|
357
|
-
var r;
|
|
358
|
-
return t ? r = e.v + Ot * n : r = e.v - It * n, r > 1 && (r = 1), Number(r.toFixed(2));
|
|
359
|
-
}
|
|
360
|
-
function Ce(e) {
|
|
361
|
-
for (var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = [], r = Z(e), a = Je; a > 0; a -= 1) {
|
|
362
|
-
var o = Pe(r), i = oe(Z({
|
|
363
|
-
h: Me(o, a, !0),
|
|
364
|
-
s: $e(o, a, !0),
|
|
365
|
-
v: je(o, a, !0)
|
|
366
|
-
}));
|
|
367
|
-
t.push(i);
|
|
368
|
-
}
|
|
369
|
-
t.push(oe(r));
|
|
370
|
-
for (var l = 1; l <= Ge; l += 1) {
|
|
371
|
-
var s = Pe(r), c = oe(Z({
|
|
372
|
-
h: Me(s, l),
|
|
373
|
-
s: $e(s, l),
|
|
374
|
-
v: je(s, l)
|
|
375
|
-
}));
|
|
376
|
-
t.push(c);
|
|
377
|
-
}
|
|
378
|
-
return n.theme === "dark" ? Tt.map(function(p) {
|
|
379
|
-
var g = p.index, b = p.opacity, f = oe(_t(Z(n.backgroundColor || "#141414"), Z(t[g]), b * 100));
|
|
380
|
-
return f;
|
|
381
|
-
}) : t;
|
|
382
|
-
}
|
|
383
|
-
var ge = {
|
|
384
|
-
red: "#F5222D",
|
|
385
|
-
volcano: "#FA541C",
|
|
386
|
-
orange: "#FA8C16",
|
|
387
|
-
gold: "#FAAD14",
|
|
388
|
-
yellow: "#FADB14",
|
|
389
|
-
lime: "#A0D911",
|
|
390
|
-
green: "#52C41A",
|
|
391
|
-
cyan: "#13C2C2",
|
|
392
|
-
blue: "#1890FF",
|
|
393
|
-
geekblue: "#2F54EB",
|
|
394
|
-
purple: "#722ED1",
|
|
395
|
-
magenta: "#EB2F96",
|
|
396
|
-
grey: "#666666"
|
|
397
|
-
}, ye = {}, be = {};
|
|
398
|
-
Object.keys(ge).forEach(function(e) {
|
|
399
|
-
ye[e] = Ce(ge[e]), ye[e].primary = ye[e][5], be[e] = Ce(ge[e], {
|
|
400
|
-
theme: "dark",
|
|
401
|
-
backgroundColor: "#141414"
|
|
402
|
-
}), be[e].primary = be[e][5];
|
|
403
|
-
});
|
|
404
|
-
var Re = [], Y = [], Et = "insert-css: You need to provide a CSS string. Usage: insertCss(cssString[, options]).";
|
|
405
|
-
function At() {
|
|
406
|
-
var e = document.createElement("style");
|
|
407
|
-
return e.setAttribute("type", "text/css"), e;
|
|
408
|
-
}
|
|
409
|
-
function Pt(e, n) {
|
|
410
|
-
if (n = n || {}, e === void 0)
|
|
411
|
-
throw new Error(Et);
|
|
412
|
-
var t = n.prepend === !0 ? "prepend" : "append", r = n.container !== void 0 ? n.container : document.querySelector("head"), a = Re.indexOf(r);
|
|
413
|
-
a === -1 && (a = Re.push(r) - 1, Y[a] = {});
|
|
414
|
-
var o;
|
|
415
|
-
return Y[a] !== void 0 && Y[a][t] !== void 0 ? o = Y[a][t] : (o = Y[a][t] = At(), t === "prepend" ? r.insertBefore(o, r.childNodes[0]) : r.appendChild(o)), e.charCodeAt(0) === 65279 && (e = e.substr(1, e.length)), o.styleSheet ? o.styleSheet.cssText += e : o.textContent += e, o;
|
|
416
|
-
}
|
|
417
|
-
function Ne(e) {
|
|
418
|
-
for (var n = 1; n < arguments.length; n++) {
|
|
419
|
-
var t = arguments[n] != null ? Object(arguments[n]) : {}, r = Object.keys(t);
|
|
420
|
-
typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(t).filter(function(a) {
|
|
421
|
-
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
422
|
-
}))), r.forEach(function(a) {
|
|
423
|
-
Mt(e, a, t[a]);
|
|
424
|
-
});
|
|
425
|
-
}
|
|
426
|
-
return e;
|
|
427
|
-
}
|
|
428
|
-
function Mt(e, n, t) {
|
|
429
|
-
return n in e ? Object.defineProperty(e, n, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[n] = t, e;
|
|
430
|
-
}
|
|
431
|
-
function $t(e, n) {
|
|
432
|
-
process.env.NODE_ENV !== "production" && !e && console !== void 0 && console.error("Warning: ".concat(n));
|
|
433
|
-
}
|
|
434
|
-
function jt(e, n) {
|
|
435
|
-
$t(e, "[@ant-design/icons-vue] ".concat(n));
|
|
436
|
-
}
|
|
437
|
-
function Fe(e) {
|
|
438
|
-
return typeof e == "object" && typeof e.name == "string" && typeof e.theme == "string" && (typeof e.icon == "object" || typeof e.icon == "function");
|
|
439
|
-
}
|
|
440
|
-
function xe(e, n, t) {
|
|
441
|
-
return t ? ke(e.tag, Ne({
|
|
442
|
-
key: n
|
|
443
|
-
}, t, e.attrs), (e.children || []).map(function(r, a) {
|
|
444
|
-
return xe(r, "".concat(n, "-").concat(e.tag, "-").concat(a));
|
|
445
|
-
})) : ke(e.tag, Ne({
|
|
446
|
-
key: n
|
|
447
|
-
}, e.attrs), (e.children || []).map(function(r, a) {
|
|
448
|
-
return xe(r, "".concat(n, "-").concat(e.tag, "-").concat(a));
|
|
449
|
-
}));
|
|
450
|
-
}
|
|
451
|
-
function Ze(e) {
|
|
452
|
-
return Ce(e)[0];
|
|
453
|
-
}
|
|
454
|
-
function Ye(e) {
|
|
455
|
-
return e ? Array.isArray(e) ? e : [e] : [];
|
|
456
|
-
}
|
|
457
|
-
var Rt = `
|
|
458
|
-
.anticon {
|
|
459
|
-
display: inline-block;
|
|
460
|
-
color: inherit;
|
|
461
|
-
font-style: normal;
|
|
462
|
-
line-height: 0;
|
|
463
|
-
text-align: center;
|
|
464
|
-
text-transform: none;
|
|
465
|
-
vertical-align: -0.125em;
|
|
466
|
-
text-rendering: optimizeLegibility;
|
|
467
|
-
-webkit-font-smoothing: antialiased;
|
|
468
|
-
-moz-osx-font-smoothing: grayscale;
|
|
469
|
-
}
|
|
470
|
-
|
|
471
|
-
.anticon > * {
|
|
472
|
-
line-height: 1;
|
|
473
|
-
}
|
|
474
|
-
|
|
475
|
-
.anticon svg {
|
|
476
|
-
display: inline-block;
|
|
477
|
-
}
|
|
478
|
-
|
|
479
|
-
.anticon::before {
|
|
480
|
-
display: none;
|
|
481
|
-
}
|
|
482
|
-
|
|
483
|
-
.anticon .anticon-icon {
|
|
484
|
-
display: block;
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
.anticon[tabindex] {
|
|
488
|
-
cursor: pointer;
|
|
489
|
-
}
|
|
490
|
-
|
|
491
|
-
.anticon-spin::before,
|
|
492
|
-
.anticon-spin {
|
|
493
|
-
display: inline-block;
|
|
494
|
-
-webkit-animation: loadingCircle 1s infinite linear;
|
|
495
|
-
animation: loadingCircle 1s infinite linear;
|
|
496
|
-
}
|
|
497
|
-
|
|
498
|
-
@-webkit-keyframes loadingCircle {
|
|
499
|
-
100% {
|
|
500
|
-
-webkit-transform: rotate(360deg);
|
|
501
|
-
transform: rotate(360deg);
|
|
502
|
-
}
|
|
503
|
-
}
|
|
504
|
-
|
|
505
|
-
@keyframes loadingCircle {
|
|
506
|
-
100% {
|
|
507
|
-
-webkit-transform: rotate(360deg);
|
|
508
|
-
transform: rotate(360deg);
|
|
509
|
-
}
|
|
510
|
-
}
|
|
511
|
-
`, ze = !1, Nt = function() {
|
|
512
|
-
var n = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : Rt;
|
|
513
|
-
it(function() {
|
|
514
|
-
ze || (typeof window < "u" && window.document && window.document.documentElement && Pt(n, {
|
|
515
|
-
prepend: !0
|
|
516
|
-
}), ze = !0);
|
|
517
|
-
});
|
|
518
|
-
}, Ft = ["icon", "primaryColor", "secondaryColor"];
|
|
519
|
-
function zt(e, n) {
|
|
520
|
-
if (e == null) return {};
|
|
521
|
-
var t = Bt(e, n), r, a;
|
|
522
|
-
if (Object.getOwnPropertySymbols) {
|
|
523
|
-
var o = Object.getOwnPropertySymbols(e);
|
|
524
|
-
for (a = 0; a < o.length; a++)
|
|
525
|
-
r = o[a], !(n.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (t[r] = e[r]);
|
|
526
|
-
}
|
|
527
|
-
return t;
|
|
528
|
-
}
|
|
529
|
-
function Bt(e, n) {
|
|
530
|
-
if (e == null) return {};
|
|
531
|
-
var t = {}, r = Object.keys(e), a, o;
|
|
532
|
-
for (o = 0; o < r.length; o++)
|
|
533
|
-
a = r[o], !(n.indexOf(a) >= 0) && (t[a] = e[a]);
|
|
534
|
-
return t;
|
|
535
|
-
}
|
|
536
|
-
function le(e) {
|
|
537
|
-
for (var n = 1; n < arguments.length; n++) {
|
|
538
|
-
var t = arguments[n] != null ? Object(arguments[n]) : {}, r = Object.keys(t);
|
|
539
|
-
typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(t).filter(function(a) {
|
|
540
|
-
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
541
|
-
}))), r.forEach(function(a) {
|
|
542
|
-
Vt(e, a, t[a]);
|
|
543
|
-
});
|
|
544
|
-
}
|
|
545
|
-
return e;
|
|
546
|
-
}
|
|
547
|
-
function Vt(e, n, t) {
|
|
548
|
-
return n in e ? Object.defineProperty(e, n, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[n] = t, e;
|
|
549
|
-
}
|
|
550
|
-
var ee = {
|
|
551
|
-
primaryColor: "#333",
|
|
552
|
-
secondaryColor: "#E6E6E6",
|
|
553
|
-
calculated: !1
|
|
554
|
-
};
|
|
555
|
-
function Lt(e) {
|
|
556
|
-
var n = e.primaryColor, t = e.secondaryColor;
|
|
557
|
-
ee.primaryColor = n, ee.secondaryColor = t || Ze(n), ee.calculated = !!t;
|
|
558
|
-
}
|
|
559
|
-
function Dt() {
|
|
560
|
-
return le({}, ee);
|
|
561
|
-
}
|
|
562
|
-
var H = function(n, t) {
|
|
563
|
-
var r = le({}, n, t.attrs), a = r.icon, o = r.primaryColor, i = r.secondaryColor, l = zt(r, Ft), s = ee;
|
|
564
|
-
if (o && (s = {
|
|
565
|
-
primaryColor: o,
|
|
566
|
-
secondaryColor: i || Ze(o)
|
|
567
|
-
}), Nt(), jt(Fe(a), "icon should be icon definiton, but got ".concat(a)), !Fe(a))
|
|
568
|
-
return null;
|
|
569
|
-
var c = a;
|
|
570
|
-
return c && typeof c.icon == "function" && (c = le({}, c, {
|
|
571
|
-
icon: c.icon(s.primaryColor, s.secondaryColor)
|
|
572
|
-
})), xe(c.icon, "svg-".concat(c.name), le({}, l, {
|
|
573
|
-
"data-icon": c.name,
|
|
574
|
-
width: "1em",
|
|
575
|
-
height: "1em",
|
|
576
|
-
fill: "currentColor",
|
|
577
|
-
"aria-hidden": "true"
|
|
578
|
-
}));
|
|
579
|
-
};
|
|
580
|
-
H.props = {
|
|
581
|
-
icon: Object,
|
|
582
|
-
primaryColor: String,
|
|
583
|
-
secondaryColor: String,
|
|
584
|
-
focusable: String
|
|
585
|
-
};
|
|
586
|
-
H.inheritAttrs = !1;
|
|
587
|
-
H.displayName = "IconBase";
|
|
588
|
-
H.getTwoToneColors = Dt;
|
|
589
|
-
H.setTwoToneColors = Lt;
|
|
590
|
-
function Ht(e, n) {
|
|
591
|
-
return qt(e) || Kt(e, n) || Wt(e, n) || Ut();
|
|
592
|
-
}
|
|
593
|
-
function Ut() {
|
|
594
|
-
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
595
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
596
|
-
}
|
|
597
|
-
function Wt(e, n) {
|
|
598
|
-
if (e) {
|
|
599
|
-
if (typeof e == "string") return Be(e, n);
|
|
600
|
-
var t = Object.prototype.toString.call(e).slice(8, -1);
|
|
601
|
-
if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
|
|
602
|
-
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return Be(e, n);
|
|
603
|
-
}
|
|
604
|
-
}
|
|
605
|
-
function Be(e, n) {
|
|
606
|
-
(n == null || n > e.length) && (n = e.length);
|
|
607
|
-
for (var t = 0, r = new Array(n); t < n; t++)
|
|
608
|
-
r[t] = e[t];
|
|
609
|
-
return r;
|
|
610
|
-
}
|
|
611
|
-
function Kt(e, n) {
|
|
612
|
-
var t = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
|
613
|
-
if (t != null) {
|
|
614
|
-
var r = [], a = !0, o = !1, i, l;
|
|
615
|
-
try {
|
|
616
|
-
for (t = t.call(e); !(a = (i = t.next()).done) && (r.push(i.value), !(n && r.length === n)); a = !0)
|
|
617
|
-
;
|
|
618
|
-
} catch (s) {
|
|
619
|
-
o = !0, l = s;
|
|
620
|
-
} finally {
|
|
621
|
-
try {
|
|
622
|
-
!a && t.return != null && t.return();
|
|
623
|
-
} finally {
|
|
624
|
-
if (o) throw l;
|
|
625
|
-
}
|
|
626
|
-
}
|
|
627
|
-
return r;
|
|
628
|
-
}
|
|
629
|
-
}
|
|
630
|
-
function qt(e) {
|
|
631
|
-
if (Array.isArray(e)) return e;
|
|
632
|
-
}
|
|
633
|
-
function Qe(e) {
|
|
634
|
-
var n = Ye(e), t = Ht(n, 2), r = t[0], a = t[1];
|
|
635
|
-
return H.setTwoToneColors({
|
|
636
|
-
primaryColor: r,
|
|
637
|
-
secondaryColor: a
|
|
638
|
-
});
|
|
639
|
-
}
|
|
640
|
-
function Jt() {
|
|
641
|
-
var e = H.getTwoToneColors();
|
|
642
|
-
return e.calculated ? [e.primaryColor, e.secondaryColor] : e.primaryColor;
|
|
643
|
-
}
|
|
644
|
-
var Gt = ["class", "icon", "spin", "rotate", "tabindex", "twoToneColor", "onClick"];
|
|
645
|
-
function Zt(e, n) {
|
|
646
|
-
return en(e) || Xt(e, n) || Qt(e, n) || Yt();
|
|
647
|
-
}
|
|
648
|
-
function Yt() {
|
|
649
|
-
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
650
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
651
|
-
}
|
|
652
|
-
function Qt(e, n) {
|
|
653
|
-
if (e) {
|
|
654
|
-
if (typeof e == "string") return Ve(e, n);
|
|
655
|
-
var t = Object.prototype.toString.call(e).slice(8, -1);
|
|
656
|
-
if (t === "Object" && e.constructor && (t = e.constructor.name), t === "Map" || t === "Set") return Array.from(e);
|
|
657
|
-
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return Ve(e, n);
|
|
658
|
-
}
|
|
659
|
-
}
|
|
660
|
-
function Ve(e, n) {
|
|
661
|
-
(n == null || n > e.length) && (n = e.length);
|
|
662
|
-
for (var t = 0, r = new Array(n); t < n; t++)
|
|
663
|
-
r[t] = e[t];
|
|
664
|
-
return r;
|
|
665
|
-
}
|
|
666
|
-
function Xt(e, n) {
|
|
667
|
-
var t = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
|
668
|
-
if (t != null) {
|
|
669
|
-
var r = [], a = !0, o = !1, i, l;
|
|
670
|
-
try {
|
|
671
|
-
for (t = t.call(e); !(a = (i = t.next()).done) && (r.push(i.value), !(n && r.length === n)); a = !0)
|
|
672
|
-
;
|
|
673
|
-
} catch (s) {
|
|
674
|
-
o = !0, l = s;
|
|
675
|
-
} finally {
|
|
676
|
-
try {
|
|
677
|
-
!a && t.return != null && t.return();
|
|
678
|
-
} finally {
|
|
679
|
-
if (o) throw l;
|
|
680
|
-
}
|
|
681
|
-
}
|
|
682
|
-
return r;
|
|
683
|
-
}
|
|
684
|
-
}
|
|
685
|
-
function en(e) {
|
|
686
|
-
if (Array.isArray(e)) return e;
|
|
687
|
-
}
|
|
688
|
-
function Le(e) {
|
|
689
|
-
for (var n = 1; n < arguments.length; n++) {
|
|
690
|
-
var t = arguments[n] != null ? Object(arguments[n]) : {}, r = Object.keys(t);
|
|
691
|
-
typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(t).filter(function(a) {
|
|
692
|
-
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
693
|
-
}))), r.forEach(function(a) {
|
|
694
|
-
we(e, a, t[a]);
|
|
695
|
-
});
|
|
696
|
-
}
|
|
697
|
-
return e;
|
|
698
|
-
}
|
|
699
|
-
function we(e, n, t) {
|
|
700
|
-
return n in e ? Object.defineProperty(e, n, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[n] = t, e;
|
|
701
|
-
}
|
|
702
|
-
function tn(e, n) {
|
|
703
|
-
if (e == null) return {};
|
|
704
|
-
var t = nn(e, n), r, a;
|
|
705
|
-
if (Object.getOwnPropertySymbols) {
|
|
706
|
-
var o = Object.getOwnPropertySymbols(e);
|
|
707
|
-
for (a = 0; a < o.length; a++)
|
|
708
|
-
r = o[a], !(n.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (t[r] = e[r]);
|
|
709
|
-
}
|
|
710
|
-
return t;
|
|
711
|
-
}
|
|
712
|
-
function nn(e, n) {
|
|
713
|
-
if (e == null) return {};
|
|
714
|
-
var t = {}, r = Object.keys(e), a, o;
|
|
715
|
-
for (o = 0; o < r.length; o++)
|
|
716
|
-
a = r[o], !(n.indexOf(a) >= 0) && (t[a] = e[a]);
|
|
717
|
-
return t;
|
|
718
|
-
}
|
|
719
|
-
Qe("#1890ff");
|
|
720
|
-
var G = function(n, t) {
|
|
721
|
-
var r, a = Le({}, n, t.attrs), o = a.class, i = a.icon, l = a.spin, s = a.rotate, c = a.tabindex, p = a.twoToneColor, g = a.onClick, b = tn(a, Gt), f = (r = {
|
|
722
|
-
anticon: !0
|
|
723
|
-
}, we(r, "anticon-".concat(i.name), !!i.name), we(r, o, o), r), w = l === "" || l || i.name === "loading" ? "anticon-spin" : "", y = c;
|
|
724
|
-
y === void 0 && g && (y = -1, b.tabindex = y);
|
|
725
|
-
var u = s ? {
|
|
726
|
-
msTransform: "rotate(".concat(s, "deg)"),
|
|
727
|
-
transform: "rotate(".concat(s, "deg)")
|
|
728
|
-
} : void 0, d = Ye(p), h = Zt(d, 2), R = h[0], N = h[1];
|
|
729
|
-
return m("span", Le({
|
|
730
|
-
role: "img",
|
|
731
|
-
"aria-label": i.name
|
|
732
|
-
}, b, {
|
|
733
|
-
onClick: g,
|
|
734
|
-
class: f
|
|
735
|
-
}), [m(H, {
|
|
736
|
-
class: w,
|
|
737
|
-
icon: i,
|
|
738
|
-
primaryColor: R,
|
|
739
|
-
secondaryColor: N,
|
|
740
|
-
style: u
|
|
741
|
-
}, null)]);
|
|
742
|
-
};
|
|
743
|
-
G.props = {
|
|
744
|
-
spin: Boolean,
|
|
745
|
-
rotate: Number,
|
|
746
|
-
icon: Object,
|
|
747
|
-
twoToneColor: String
|
|
748
|
-
};
|
|
749
|
-
G.displayName = "AntdIcon";
|
|
750
|
-
G.inheritAttrs = !1;
|
|
751
|
-
G.getTwoToneColor = Jt;
|
|
752
|
-
G.setTwoToneColor = Qe;
|
|
753
|
-
var rn = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "false" }, children: [{ tag: "path", attrs: { d: "M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z" } }] }, name: "search", theme: "outlined" };
|
|
754
|
-
function De(e) {
|
|
755
|
-
for (var n = 1; n < arguments.length; n++) {
|
|
756
|
-
var t = arguments[n] != null ? Object(arguments[n]) : {}, r = Object.keys(t);
|
|
757
|
-
typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(t).filter(function(a) {
|
|
758
|
-
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
759
|
-
}))), r.forEach(function(a) {
|
|
760
|
-
an(e, a, t[a]);
|
|
761
|
-
});
|
|
762
|
-
}
|
|
763
|
-
return e;
|
|
764
|
-
}
|
|
765
|
-
function an(e, n, t) {
|
|
766
|
-
return n in e ? Object.defineProperty(e, n, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[n] = t, e;
|
|
767
|
-
}
|
|
768
|
-
var Se = function(n, t) {
|
|
769
|
-
var r = De({}, n, t.attrs);
|
|
770
|
-
return m(G, De({}, r, {
|
|
771
|
-
icon: rn
|
|
772
|
-
}), null);
|
|
773
|
-
};
|
|
774
|
-
Se.displayName = "SearchOutlined";
|
|
775
|
-
Se.inheritAttrs = !1;
|
|
776
|
-
const on = /* @__PURE__ */ D({
|
|
1
|
+
import { defineComponent as z, ref as R, reactive as U, resolveComponent as k, openBlock as S, createBlock as N, mergeProps as O, unref as h, withCtx as y, createVNode as f, createElementBlock as j, Fragment as q, renderList as ne, toRaw as pe, computed as E, onMounted as ge, createElementVNode as V, createTextVNode as Y, toDisplayString as F, createApp as ye, watch as oe, normalizeClass as he, toValue as B, renderSlot as ve, createCommentVNode as be } from "vue";
|
|
2
|
+
import { has as ee, isEmpty as P, omit as ae } from "lodash-es";
|
|
3
|
+
import { useModalInner as ie, useModal as le } from "@gct-paas/core-web";
|
|
4
|
+
import { SearchOutlined as xe } from "@ant-design/icons-vue";
|
|
5
|
+
import { t as _, ButtonSize as te } from "@gct-paas/core";
|
|
6
|
+
const ke = /* @__PURE__ */ z({
|
|
777
7
|
__name: "i18n-modal",
|
|
778
8
|
props: {
|
|
779
9
|
lang: {},
|
|
780
10
|
getContainer: { type: Function }
|
|
781
11
|
},
|
|
782
12
|
emits: ["ok", "register"],
|
|
783
|
-
setup(e, { emit:
|
|
784
|
-
const
|
|
13
|
+
setup(e, { emit: c }) {
|
|
14
|
+
const a = e, n = c, o = R(), t = U({
|
|
785
15
|
id: ""
|
|
786
|
-
}),
|
|
787
|
-
|
|
788
|
-
}, [
|
|
789
|
-
|
|
790
|
-
}), p = (
|
|
791
|
-
|
|
792
|
-
const { lang:
|
|
793
|
-
console.log(
|
|
794
|
-
for (const
|
|
795
|
-
const
|
|
796
|
-
|
|
16
|
+
}), l = R(!1), m = (g) => {
|
|
17
|
+
g && (l.value = !1);
|
|
18
|
+
}, [d, { closeModal: u }] = ie((g) => {
|
|
19
|
+
g && p(g);
|
|
20
|
+
}), p = (g) => {
|
|
21
|
+
l.value = !0, t.id = g.key;
|
|
22
|
+
const { lang: i } = a;
|
|
23
|
+
console.log(i, "lang========");
|
|
24
|
+
for (const s of i) {
|
|
25
|
+
const x = s.dataIndex;
|
|
26
|
+
t[x] = g[x];
|
|
797
27
|
}
|
|
798
|
-
},
|
|
799
|
-
/^[a-zA-Z_.]*$/.test(
|
|
800
|
-
}, b = async (
|
|
801
|
-
|
|
802
|
-
|
|
28
|
+
}, v = (g, i, s) => {
|
|
29
|
+
/^[a-zA-Z_.]*$/.test(i) || s(_("sys.i18n.validated18nKeyErrorMsg")), s();
|
|
30
|
+
}, b = async (g, i) => /^\s*$/g.test(i) ? Promise.reject(_("sys.notEmptySth", { sth: _("sys.i18n") })) : Promise.resolve(), r = () => {
|
|
31
|
+
o.value?.validate().then(() => {
|
|
32
|
+
n("ok", { ...pe(t) }, l.value), u();
|
|
803
33
|
});
|
|
804
|
-
},
|
|
805
|
-
|
|
34
|
+
}, I = () => {
|
|
35
|
+
o.value?.resetFields();
|
|
806
36
|
};
|
|
807
|
-
return (
|
|
808
|
-
const
|
|
809
|
-
return
|
|
810
|
-
title:
|
|
37
|
+
return (g, i) => {
|
|
38
|
+
const s = k("a-input"), x = k("a-form-item"), K = k("a-form"), A = k("BasicModal");
|
|
39
|
+
return S(), N(A, O(g.$attrs, {
|
|
40
|
+
title: l.value ? h(_)("sys.edit") : h(_)("sys.new"),
|
|
811
41
|
centered: "",
|
|
812
42
|
width: "640px",
|
|
813
43
|
"min-height": 100,
|
|
814
44
|
"mask-closable": !1,
|
|
815
|
-
"after-close":
|
|
45
|
+
"after-close": I,
|
|
816
46
|
"get-container": e.getContainer,
|
|
817
|
-
onRegister:
|
|
818
|
-
onOk:
|
|
819
|
-
onVisibleChange:
|
|
47
|
+
onRegister: h(d),
|
|
48
|
+
onOk: r,
|
|
49
|
+
onVisibleChange: m
|
|
820
50
|
}), {
|
|
821
|
-
default:
|
|
822
|
-
|
|
51
|
+
default: y(() => [
|
|
52
|
+
f(K, {
|
|
823
53
|
ref_key: "formRef",
|
|
824
|
-
ref:
|
|
825
|
-
model:
|
|
54
|
+
ref: o,
|
|
55
|
+
model: t,
|
|
826
56
|
"label-col": { span: 6 },
|
|
827
57
|
"wrapper-col": { span: 16 },
|
|
828
58
|
autocomplete: "off",
|
|
829
59
|
layout: "horizontal"
|
|
830
60
|
}, {
|
|
831
|
-
default:
|
|
832
|
-
|
|
833
|
-
label:
|
|
61
|
+
default: y(() => [
|
|
62
|
+
f(x, {
|
|
63
|
+
label: h(_)("sys.i18n.resourceIdentification"),
|
|
834
64
|
name: "id",
|
|
835
65
|
rules: [
|
|
836
66
|
{
|
|
837
67
|
required: !0,
|
|
838
|
-
message:
|
|
839
|
-
sth:
|
|
68
|
+
message: h(_)("sys.pleaseInputSth", {
|
|
69
|
+
sth: h(_)("sys.i18n.resourceIdentification")
|
|
840
70
|
})
|
|
841
71
|
},
|
|
842
|
-
{ validator:
|
|
72
|
+
{ validator: v }
|
|
843
73
|
]
|
|
844
74
|
}, {
|
|
845
|
-
default:
|
|
846
|
-
|
|
847
|
-
value:
|
|
848
|
-
"onUpdate:value":
|
|
75
|
+
default: y(() => [
|
|
76
|
+
f(s, {
|
|
77
|
+
value: t.id,
|
|
78
|
+
"onUpdate:value": i[0] || (i[0] = (M) => t.id = M),
|
|
849
79
|
"show-count": "",
|
|
850
80
|
maxlength: 128,
|
|
851
|
-
disabled:
|
|
81
|
+
disabled: l.value
|
|
852
82
|
}, null, 8, ["value", "disabled"])
|
|
853
83
|
]),
|
|
854
84
|
_: 1
|
|
855
85
|
}, 8, ["label", "rules"]),
|
|
856
|
-
(
|
|
857
|
-
key:
|
|
858
|
-
label:
|
|
859
|
-
name:
|
|
86
|
+
(S(!0), j(q, null, ne(a.lang, (M) => (S(), N(x, {
|
|
87
|
+
key: M.dataIndex,
|
|
88
|
+
label: M.title,
|
|
89
|
+
name: M.dataIndex,
|
|
860
90
|
rules: [
|
|
861
91
|
{
|
|
862
92
|
required: !0,
|
|
863
|
-
message:
|
|
93
|
+
message: h(_)("sys.pleaseInputSth", { sth: M.title })
|
|
864
94
|
},
|
|
865
95
|
{
|
|
866
96
|
validator: b
|
|
867
97
|
}
|
|
868
98
|
]
|
|
869
99
|
}, {
|
|
870
|
-
default:
|
|
871
|
-
|
|
872
|
-
value:
|
|
873
|
-
"onUpdate:value": (
|
|
100
|
+
default: y(() => [
|
|
101
|
+
f(s, {
|
|
102
|
+
value: t[M.dataIndex],
|
|
103
|
+
"onUpdate:value": (Z) => t[M.dataIndex] = Z,
|
|
874
104
|
"show-count": "",
|
|
875
105
|
maxlength: 300
|
|
876
106
|
}, null, 8, ["value", "onUpdate:value"])
|
|
@@ -885,7 +115,7 @@ const on = /* @__PURE__ */ D({
|
|
|
885
115
|
}, 16, ["title", "get-container", "onRegister"]);
|
|
886
116
|
};
|
|
887
117
|
}
|
|
888
|
-
}),
|
|
118
|
+
}), Ce = { class: "i18n-select-container" }, Ie = { class: "table-wrap" }, _e = /* @__PURE__ */ z({
|
|
889
119
|
__name: "i18n-select-container",
|
|
890
120
|
props: {
|
|
891
121
|
i18nModalKey: {},
|
|
@@ -893,120 +123,120 @@ const on = /* @__PURE__ */ D({
|
|
|
893
123
|
saveCallback: { type: Function }
|
|
894
124
|
},
|
|
895
125
|
setup(e) {
|
|
896
|
-
const [
|
|
126
|
+
const [c, { closeModal: a }] = ie(), [n, { openModal: o }] = le(), t = e, l = () => document.querySelector(`#${t.i18nModalKey}`), m = R(), d = U({ keywords: "" }), u = U({
|
|
897
127
|
current: 1,
|
|
898
128
|
pageSize: 5,
|
|
899
129
|
total: 0,
|
|
900
130
|
size: "small",
|
|
901
|
-
showTotal: (
|
|
902
|
-
}), p =
|
|
131
|
+
showTotal: (C) => _("sys.component.table.total", { total: C })
|
|
132
|
+
}), p = R([]), v = R(), b = R({
|
|
903
133
|
type: "radio",
|
|
904
134
|
hideSelectAll: !0,
|
|
905
135
|
selectedRowKeys: [],
|
|
906
|
-
onChange:
|
|
907
|
-
}),
|
|
908
|
-
|
|
136
|
+
onChange: A
|
|
137
|
+
}), r = R(!1), I = E(() => []), g = async (C, w) => {
|
|
138
|
+
r.value = !0;
|
|
909
139
|
const T = await _api.apaas.i18NInfo.getPageList({
|
|
910
|
-
pageNo:
|
|
911
|
-
pageSize:
|
|
912
|
-
searchKey:
|
|
140
|
+
pageNo: w ?? u.current,
|
|
141
|
+
pageSize: u.pageSize,
|
|
142
|
+
searchKey: C
|
|
913
143
|
});
|
|
914
|
-
if (
|
|
915
|
-
const
|
|
916
|
-
const
|
|
144
|
+
if (r.value = !1, T && T.data) {
|
|
145
|
+
const $ = T.data.map((L) => {
|
|
146
|
+
const H = JSON.parse(L?.info);
|
|
917
147
|
return {
|
|
918
|
-
key:
|
|
919
|
-
type:
|
|
920
|
-
...Object.fromEntries(
|
|
148
|
+
key: L.key,
|
|
149
|
+
type: L.type,
|
|
150
|
+
...Object.fromEntries(H.map((J) => [J.locale, J.info]))
|
|
921
151
|
};
|
|
922
152
|
});
|
|
923
|
-
|
|
153
|
+
u.total = T.totalCount, p.value = $;
|
|
924
154
|
}
|
|
925
155
|
};
|
|
926
|
-
|
|
927
|
-
const
|
|
928
|
-
|
|
929
|
-
await
|
|
156
|
+
ge(g);
|
|
157
|
+
const i = () => {
|
|
158
|
+
m.value?.validate().then(async () => {
|
|
159
|
+
await g(d.keywords, 1);
|
|
930
160
|
});
|
|
931
|
-
},
|
|
932
|
-
const { current:
|
|
933
|
-
|
|
934
|
-
},
|
|
935
|
-
|
|
936
|
-
},
|
|
937
|
-
const T =
|
|
938
|
-
locale:
|
|
939
|
-
info:
|
|
161
|
+
}, s = (C) => {
|
|
162
|
+
const { current: w, total: T, pageSize: $ } = C;
|
|
163
|
+
u.current = w, u.total = T, u.pageSize = $, g();
|
|
164
|
+
}, x = () => {
|
|
165
|
+
o();
|
|
166
|
+
}, K = async (C, w) => {
|
|
167
|
+
const T = I.value.map(($) => ({
|
|
168
|
+
locale: $.dataIndex,
|
|
169
|
+
info: C[$.dataIndex]
|
|
940
170
|
}));
|
|
941
|
-
|
|
171
|
+
r.value = !0;
|
|
942
172
|
try {
|
|
943
|
-
|
|
944
|
-
{ key:
|
|
173
|
+
w ? await _api.apaas.i18NInfo.putKey(
|
|
174
|
+
{ key: C.id },
|
|
945
175
|
{ info: JSON.stringify(T) }
|
|
946
176
|
) : await _api.apaas.i18NInfo.post({
|
|
947
177
|
info: JSON.stringify(T),
|
|
948
|
-
key:
|
|
949
|
-
}),
|
|
178
|
+
key: C.id
|
|
179
|
+
}), g(), A([C.id], [U(C)]);
|
|
950
180
|
} catch {
|
|
951
|
-
|
|
181
|
+
r.value = !1;
|
|
952
182
|
}
|
|
953
183
|
};
|
|
954
|
-
function
|
|
955
|
-
b.value.selectedRowKeys =
|
|
184
|
+
function A(C, w) {
|
|
185
|
+
b.value.selectedRowKeys = C, v.value = w;
|
|
956
186
|
}
|
|
957
|
-
const
|
|
958
|
-
|
|
959
|
-
},
|
|
960
|
-
if (
|
|
961
|
-
const
|
|
962
|
-
if (
|
|
963
|
-
const T =
|
|
964
|
-
console.log("selectRow", T), Object.assign(
|
|
965
|
-
i18nKey:
|
|
187
|
+
const M = () => {
|
|
188
|
+
t.destroyCallback && typeof t.destroyCallback == "function" && t.destroyCallback();
|
|
189
|
+
}, Z = async () => {
|
|
190
|
+
if (t.saveCallback && typeof t.saveCallback == "function") {
|
|
191
|
+
const C = b.value.selectedRowKeys, w = {};
|
|
192
|
+
if (C && C[0]) {
|
|
193
|
+
const T = v.value?.[0];
|
|
194
|
+
console.log("selectRow", T), Object.assign(w, {
|
|
195
|
+
i18nKey: C[0]
|
|
966
196
|
// i18nTitle: selectRow[getLocale],
|
|
967
197
|
});
|
|
968
198
|
}
|
|
969
|
-
|
|
199
|
+
t.saveCallback(w);
|
|
970
200
|
}
|
|
971
|
-
|
|
201
|
+
a();
|
|
972
202
|
};
|
|
973
|
-
return (
|
|
974
|
-
const T =
|
|
975
|
-
return
|
|
203
|
+
return (C, w) => {
|
|
204
|
+
const T = k("a-input"), $ = k("a-form-item"), L = k("a-col"), H = k("a-button"), J = k("plus-outlined"), ce = k("a-row"), ue = k("a-form"), de = k("a-table"), fe = k("basic-modal");
|
|
205
|
+
return S(), N(fe, O(C.$attrs, {
|
|
976
206
|
"min-height": 40,
|
|
977
|
-
title:
|
|
207
|
+
title: h(_)("sys.i18n.i18nConfig"),
|
|
978
208
|
centered: "",
|
|
979
209
|
width: "640px",
|
|
980
210
|
"can-fullscreen": !1,
|
|
981
211
|
"mask-closable": !1,
|
|
982
|
-
"after-close":
|
|
983
|
-
"get-container":
|
|
984
|
-
onRegister:
|
|
985
|
-
onOk:
|
|
212
|
+
"after-close": M,
|
|
213
|
+
"get-container": l,
|
|
214
|
+
onRegister: h(c),
|
|
215
|
+
onOk: Z
|
|
986
216
|
}), {
|
|
987
|
-
default:
|
|
988
|
-
|
|
989
|
-
|
|
217
|
+
default: y(() => [
|
|
218
|
+
V("div", Ce, [
|
|
219
|
+
f(ue, {
|
|
990
220
|
ref_key: "formRef",
|
|
991
|
-
ref:
|
|
992
|
-
model:
|
|
221
|
+
ref: m,
|
|
222
|
+
model: d,
|
|
993
223
|
autocomplete: "off",
|
|
994
224
|
layout: "horizontal"
|
|
995
225
|
}, {
|
|
996
|
-
default:
|
|
997
|
-
|
|
998
|
-
default:
|
|
999
|
-
|
|
1000
|
-
default:
|
|
1001
|
-
|
|
226
|
+
default: y(() => [
|
|
227
|
+
f(ce, null, {
|
|
228
|
+
default: y(() => [
|
|
229
|
+
f(L, { span: 12 }, {
|
|
230
|
+
default: y(() => [
|
|
231
|
+
f($, {
|
|
1002
232
|
name: "keywords",
|
|
1003
|
-
label:
|
|
233
|
+
label: h(_)("sys.keywords")
|
|
1004
234
|
}, {
|
|
1005
|
-
default:
|
|
1006
|
-
|
|
1007
|
-
value:
|
|
1008
|
-
"onUpdate:value":
|
|
1009
|
-
placeholder:
|
|
235
|
+
default: y(() => [
|
|
236
|
+
f(T, {
|
|
237
|
+
value: d.keywords,
|
|
238
|
+
"onUpdate:value": w[0] || (w[0] = (me) => d.keywords = me),
|
|
239
|
+
placeholder: h(_)("sys.keywordsPlaceholder"),
|
|
1010
240
|
style: { display: "inline-flex" }
|
|
1011
241
|
}, null, 8, ["value", "placeholder"])
|
|
1012
242
|
]),
|
|
@@ -1015,33 +245,33 @@ const on = /* @__PURE__ */ D({
|
|
|
1015
245
|
]),
|
|
1016
246
|
_: 1
|
|
1017
247
|
}),
|
|
1018
|
-
|
|
248
|
+
f(L, {
|
|
1019
249
|
span: 12,
|
|
1020
250
|
style: { "text-align": "right" }
|
|
1021
251
|
}, {
|
|
1022
|
-
default:
|
|
1023
|
-
|
|
252
|
+
default: y(() => [
|
|
253
|
+
f(H, {
|
|
1024
254
|
type: "primary",
|
|
1025
|
-
onClick:
|
|
255
|
+
onClick: i
|
|
1026
256
|
}, {
|
|
1027
|
-
icon:
|
|
1028
|
-
|
|
257
|
+
icon: y(() => [
|
|
258
|
+
f(h(xe))
|
|
1029
259
|
]),
|
|
1030
|
-
default:
|
|
1031
|
-
|
|
260
|
+
default: y(() => [
|
|
261
|
+
Y(" " + F(h(_)("sys.queryText")), 1)
|
|
1032
262
|
]),
|
|
1033
263
|
_: 1
|
|
1034
264
|
}),
|
|
1035
|
-
|
|
265
|
+
f(H, {
|
|
1036
266
|
style: { margin: "0 8px" },
|
|
1037
267
|
type: "primary",
|
|
1038
|
-
onClick:
|
|
268
|
+
onClick: x
|
|
1039
269
|
}, {
|
|
1040
|
-
icon:
|
|
1041
|
-
|
|
270
|
+
icon: y(() => [
|
|
271
|
+
f(J)
|
|
1042
272
|
]),
|
|
1043
|
-
default:
|
|
1044
|
-
|
|
273
|
+
default: y(() => [
|
|
274
|
+
Y(" " + F(h(_)("sys.new")), 1)
|
|
1045
275
|
]),
|
|
1046
276
|
_: 1
|
|
1047
277
|
})
|
|
@@ -1054,24 +284,24 @@ const on = /* @__PURE__ */ D({
|
|
|
1054
284
|
]),
|
|
1055
285
|
_: 1
|
|
1056
286
|
}, 8, ["model"]),
|
|
1057
|
-
|
|
1058
|
-
|
|
287
|
+
V("div", Ie, [
|
|
288
|
+
f(de, {
|
|
1059
289
|
ref: "tableRef",
|
|
1060
290
|
"data-source": p.value,
|
|
1061
|
-
columns:
|
|
291
|
+
columns: I.value,
|
|
1062
292
|
"show-index-column": !1,
|
|
1063
|
-
pagination:
|
|
293
|
+
pagination: u,
|
|
1064
294
|
striped: !1,
|
|
1065
295
|
bordered: !0,
|
|
1066
296
|
"row-selection": b.value,
|
|
1067
|
-
loading:
|
|
1068
|
-
onChange:
|
|
297
|
+
loading: r.value,
|
|
298
|
+
onChange: s
|
|
1069
299
|
}, null, 8, ["data-source", "columns", "pagination", "row-selection", "loading"]),
|
|
1070
|
-
|
|
1071
|
-
lang:
|
|
1072
|
-
"get-container":
|
|
1073
|
-
onRegister:
|
|
1074
|
-
onOk:
|
|
300
|
+
f(ke, {
|
|
301
|
+
lang: I.value,
|
|
302
|
+
"get-container": l,
|
|
303
|
+
onRegister: h(n),
|
|
304
|
+
onOk: K
|
|
1075
305
|
}, null, 8, ["lang", "onRegister"])
|
|
1076
306
|
])
|
|
1077
307
|
])
|
|
@@ -1080,53 +310,53 @@ const on = /* @__PURE__ */ D({
|
|
|
1080
310
|
}, 16, ["title", "onRegister"]);
|
|
1081
311
|
};
|
|
1082
312
|
}
|
|
1083
|
-
}),
|
|
1084
|
-
const
|
|
1085
|
-
for (const [
|
|
1086
|
-
|
|
1087
|
-
return
|
|
1088
|
-
},
|
|
313
|
+
}), G = (e, c) => {
|
|
314
|
+
const a = e.__vccOpts || e;
|
|
315
|
+
for (const [n, o] of c)
|
|
316
|
+
a[n] = o;
|
|
317
|
+
return a;
|
|
318
|
+
}, Se = /* @__PURE__ */ G(_e, [["__scopeId", "data-v-0160ed5e"]]), we = /* @__PURE__ */ z({
|
|
1089
319
|
__name: "i18n-select-modal",
|
|
1090
|
-
setup(e, { expose:
|
|
1091
|
-
const [
|
|
1092
|
-
return
|
|
320
|
+
setup(e, { expose: c }) {
|
|
321
|
+
const [a, { openModal: n }] = le();
|
|
322
|
+
return c({
|
|
1093
323
|
open: () => {
|
|
1094
|
-
|
|
324
|
+
n();
|
|
1095
325
|
}
|
|
1096
|
-
}), (
|
|
326
|
+
}), (t, l) => (S(), N(Se, { onRegister: h(a) }, null, 8, ["onRegister"]));
|
|
1097
327
|
}
|
|
1098
328
|
});
|
|
1099
|
-
function
|
|
1100
|
-
let e = null,
|
|
1101
|
-
const
|
|
1102
|
-
function
|
|
1103
|
-
let
|
|
1104
|
-
if (
|
|
1105
|
-
const
|
|
1106
|
-
|
|
329
|
+
function Te() {
|
|
330
|
+
let e = null, c = null;
|
|
331
|
+
const a = R("");
|
|
332
|
+
function n(t) {
|
|
333
|
+
let l, m = document.body;
|
|
334
|
+
if (ee(t, "target") || ee(t, "props")) {
|
|
335
|
+
const u = t;
|
|
336
|
+
l = u.props || {}, m = u.target || document.body;
|
|
1107
337
|
} else
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
const
|
|
1111
|
-
...
|
|
1112
|
-
destroyCallback: () =>
|
|
1113
|
-
i18nModalKey:
|
|
338
|
+
l = t;
|
|
339
|
+
a.value = l.i18nModalKey || `i18n-select-modal-${Math.random().toString(16).substring(8)}`;
|
|
340
|
+
const d = {
|
|
341
|
+
...l,
|
|
342
|
+
destroyCallback: () => o(l?.destroyCallback),
|
|
343
|
+
i18nModalKey: h(a)
|
|
1114
344
|
};
|
|
1115
345
|
if (!e) {
|
|
1116
|
-
const
|
|
1117
|
-
|
|
346
|
+
const u = document.createElement("div");
|
|
347
|
+
u.id = h(a), h(m)?.appendChild(u), e = ye(we, d), c = e.mount(u);
|
|
1118
348
|
}
|
|
1119
|
-
|
|
349
|
+
c?.open();
|
|
1120
350
|
}
|
|
1121
|
-
function
|
|
1122
|
-
typeof
|
|
351
|
+
function o(t) {
|
|
352
|
+
typeof t == "function" && t(), document.querySelector(`#${h(a)}`).remove(), e && (e.unmount(), e = null);
|
|
1123
353
|
}
|
|
1124
354
|
return {
|
|
1125
|
-
open:
|
|
1126
|
-
close:
|
|
355
|
+
open: n,
|
|
356
|
+
close: o
|
|
1127
357
|
};
|
|
1128
358
|
}
|
|
1129
|
-
const
|
|
359
|
+
const Re = { class: "i18n-tooltip-title" }, Ee = { style: { "margin-left": "4px" } }, Me = /* @__PURE__ */ z({
|
|
1130
360
|
__name: "i18n-select-btn",
|
|
1131
361
|
props: {
|
|
1132
362
|
i18nValue: {},
|
|
@@ -1138,80 +368,80 @@ const pn = { class: "i18n-tooltip-title" }, mn = { style: { "margin-left": "4px"
|
|
|
1138
368
|
btnWidth: {}
|
|
1139
369
|
},
|
|
1140
370
|
emits: ["on-select-i18n", "closed"],
|
|
1141
|
-
setup(e, { emit:
|
|
1142
|
-
const
|
|
1143
|
-
const
|
|
371
|
+
setup(e, { emit: c }) {
|
|
372
|
+
const a = R(), n = Te(), o = e, t = c, l = U({}), m = E(() => !P(o.i18nValue)), d = async (p) => {
|
|
373
|
+
const v = await _api.apaas.i18NInfo.getPageList({
|
|
1144
374
|
pageNo: 1,
|
|
1145
375
|
pageSize: 20,
|
|
1146
376
|
searchKey: p
|
|
1147
377
|
});
|
|
1148
|
-
if (
|
|
1149
|
-
const b =
|
|
378
|
+
if (v && v.data) {
|
|
379
|
+
const b = v.data.find((r) => r.key === o.i18nValue);
|
|
1150
380
|
b && Object.assign(
|
|
1151
|
-
|
|
381
|
+
l,
|
|
1152
382
|
Object.fromEntries(
|
|
1153
|
-
Object.entries(JSON.parse(b.info)).map(([
|
|
1154
|
-
|
|
1155
|
-
|
|
383
|
+
Object.entries(JSON.parse(b.info)).map(([r, I]) => [
|
|
384
|
+
I.locale,
|
|
385
|
+
I.info
|
|
1156
386
|
])
|
|
1157
387
|
)
|
|
1158
388
|
);
|
|
1159
389
|
}
|
|
1160
390
|
};
|
|
1161
|
-
|
|
1162
|
-
() =>
|
|
391
|
+
oe(
|
|
392
|
+
() => o.i18nValue,
|
|
1163
393
|
() => {
|
|
1164
|
-
|
|
394
|
+
P(o.i18nValue) || d(o.i18nValue);
|
|
1165
395
|
},
|
|
1166
396
|
{
|
|
1167
397
|
immediate: !0
|
|
1168
398
|
}
|
|
1169
399
|
);
|
|
1170
|
-
const
|
|
1171
|
-
|
|
1172
|
-
i18nModalKey:
|
|
400
|
+
const u = () => {
|
|
401
|
+
n.open({
|
|
402
|
+
i18nModalKey: o.i18nModalKey,
|
|
1173
403
|
saveCallback: (p) => {
|
|
1174
|
-
|
|
404
|
+
t("on-select-i18n", { ...p });
|
|
1175
405
|
},
|
|
1176
406
|
destroyCallback: () => {
|
|
1177
|
-
|
|
407
|
+
t("closed");
|
|
1178
408
|
}
|
|
1179
409
|
});
|
|
1180
410
|
};
|
|
1181
|
-
return (p,
|
|
1182
|
-
const b =
|
|
1183
|
-
return e.simpleBtn ? (
|
|
411
|
+
return (p, v) => {
|
|
412
|
+
const b = k("Icon"), r = k("a-button"), I = k("a-tooltip");
|
|
413
|
+
return e.simpleBtn ? (S(), N(b, {
|
|
1184
414
|
key: 0,
|
|
1185
|
-
class:
|
|
415
|
+
class: he(["i18n-icon simple-btn", { "is-highlight": m.value }]),
|
|
1186
416
|
icon: "ion:language",
|
|
1187
|
-
onClick:
|
|
1188
|
-
}, null, 8, ["class"])) :
|
|
417
|
+
onClick: u
|
|
418
|
+
}, null, 8, ["class"])) : m.value ? (S(), N(I, {
|
|
1189
419
|
key: 1,
|
|
1190
420
|
color: "#fff",
|
|
1191
421
|
placement: "topRight"
|
|
1192
422
|
}, {
|
|
1193
|
-
title:
|
|
1194
|
-
|
|
1195
|
-
(
|
|
1196
|
-
key:
|
|
423
|
+
title: y(() => [
|
|
424
|
+
V("div", Re, "语言标识:" + F(e.i18nValue), 1),
|
|
425
|
+
(S(!0), j(q, null, ne(a.value, (g) => (S(), j("div", {
|
|
426
|
+
key: g.id,
|
|
1197
427
|
class: "i18n-tooltip-item"
|
|
1198
428
|
}, [
|
|
1199
|
-
|
|
1200
|
-
|
|
429
|
+
V("strong", null, F(g.language) + ": ", 1),
|
|
430
|
+
V("span", Ee, F(l[g.languageTag]), 1)
|
|
1201
431
|
]))), 128))
|
|
1202
432
|
]),
|
|
1203
|
-
default:
|
|
1204
|
-
|
|
1205
|
-
class: { "is-highlight":
|
|
433
|
+
default: y(() => [
|
|
434
|
+
f(r, O(e.buttonExtraProps, {
|
|
435
|
+
class: { "is-highlight": m.value },
|
|
1206
436
|
style: {
|
|
1207
437
|
"--btn-width": e.btnWidth,
|
|
1208
438
|
"--btn-height": e.btnHeight
|
|
1209
439
|
},
|
|
1210
440
|
size: e.size,
|
|
1211
|
-
onClick:
|
|
441
|
+
onClick: u
|
|
1212
442
|
}), {
|
|
1213
|
-
icon:
|
|
1214
|
-
|
|
443
|
+
icon: y(() => [
|
|
444
|
+
f(b, {
|
|
1215
445
|
class: "i18n-icon",
|
|
1216
446
|
icon: "ion:language"
|
|
1217
447
|
})
|
|
@@ -1220,17 +450,17 @@ const pn = { class: "i18n-tooltip-title" }, mn = { style: { "margin-left": "4px"
|
|
|
1220
450
|
}, 16, ["class", "style", "size"])
|
|
1221
451
|
]),
|
|
1222
452
|
_: 1
|
|
1223
|
-
})) : (
|
|
1224
|
-
class: { "is-highlight":
|
|
453
|
+
})) : (S(), N(r, O({ key: 2 }, e.buttonExtraProps, {
|
|
454
|
+
class: { "is-highlight": m.value },
|
|
1225
455
|
style: {
|
|
1226
456
|
"--btn-width": e.btnWidth,
|
|
1227
457
|
"--btn-height": e.btnHeight
|
|
1228
458
|
},
|
|
1229
459
|
size: e.size,
|
|
1230
|
-
onClick:
|
|
460
|
+
onClick: u
|
|
1231
461
|
}), {
|
|
1232
|
-
icon:
|
|
1233
|
-
|
|
462
|
+
icon: y(() => [
|
|
463
|
+
f(b, {
|
|
1234
464
|
class: "i18n-icon",
|
|
1235
465
|
icon: "ion:language"
|
|
1236
466
|
})
|
|
@@ -1239,112 +469,112 @@ const pn = { class: "i18n-tooltip-title" }, mn = { style: { "margin-left": "4px"
|
|
|
1239
469
|
}, 16, ["class", "style", "size"]));
|
|
1240
470
|
};
|
|
1241
471
|
}
|
|
1242
|
-
}),
|
|
472
|
+
}), se = /* @__PURE__ */ G(Me, [["__scopeId", "data-v-dc8ffb2c"]]), Oe = typeof window < "u" && typeof document < "u";
|
|
1243
473
|
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
|
|
1244
|
-
const
|
|
474
|
+
const $e = Object.prototype.toString, Ne = (e) => $e.call(e) === "[object Object]", D = () => {
|
|
1245
475
|
};
|
|
1246
|
-
function
|
|
476
|
+
function Q(e) {
|
|
1247
477
|
return Array.isArray(e) ? e : [e];
|
|
1248
478
|
}
|
|
1249
|
-
function
|
|
1250
|
-
return
|
|
1251
|
-
...
|
|
479
|
+
function Pe(e, c, a) {
|
|
480
|
+
return oe(e, c, {
|
|
481
|
+
...a,
|
|
1252
482
|
immediate: !0
|
|
1253
483
|
});
|
|
1254
484
|
}
|
|
1255
|
-
const
|
|
1256
|
-
function
|
|
1257
|
-
var
|
|
1258
|
-
const
|
|
1259
|
-
return (
|
|
485
|
+
const re = Oe ? window : void 0;
|
|
486
|
+
function W(e) {
|
|
487
|
+
var c;
|
|
488
|
+
const a = B(e);
|
|
489
|
+
return (c = a?.$el) !== null && c !== void 0 ? c : a;
|
|
1260
490
|
}
|
|
1261
|
-
function
|
|
1262
|
-
const
|
|
1263
|
-
const
|
|
1264
|
-
return
|
|
491
|
+
function X(...e) {
|
|
492
|
+
const c = (n, o, t, l) => (n.addEventListener(o, t, l), () => n.removeEventListener(o, t, l)), a = E(() => {
|
|
493
|
+
const n = Q(B(e[0])).filter((o) => o != null);
|
|
494
|
+
return n.every((o) => typeof o != "string") ? n : void 0;
|
|
1265
495
|
});
|
|
1266
|
-
return
|
|
1267
|
-
var
|
|
496
|
+
return Pe(() => {
|
|
497
|
+
var n, o;
|
|
1268
498
|
return [
|
|
1269
|
-
(
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
499
|
+
(n = (o = a.value) === null || o === void 0 ? void 0 : o.map((t) => W(t))) !== null && n !== void 0 ? n : [re].filter((t) => t != null),
|
|
500
|
+
Q(B(a.value ? e[1] : e[0])),
|
|
501
|
+
Q(h(a.value ? e[2] : e[1])),
|
|
502
|
+
B(a.value ? e[3] : e[2])
|
|
1273
503
|
];
|
|
1274
|
-
}, ([
|
|
1275
|
-
if (!
|
|
1276
|
-
const
|
|
1277
|
-
|
|
1278
|
-
p.forEach((
|
|
504
|
+
}, ([n, o, t, l], m, d) => {
|
|
505
|
+
if (!n?.length || !o?.length || !t?.length) return;
|
|
506
|
+
const u = Ne(l) ? { ...l } : l, p = n.flatMap((v) => o.flatMap((b) => t.map((r) => c(v, b, r, u))));
|
|
507
|
+
d(() => {
|
|
508
|
+
p.forEach((v) => v());
|
|
1279
509
|
});
|
|
1280
510
|
}, { flush: "post" });
|
|
1281
511
|
}
|
|
1282
|
-
function
|
|
1283
|
-
const { window:
|
|
1284
|
-
if (!
|
|
1285
|
-
stop:
|
|
1286
|
-
cancel:
|
|
1287
|
-
trigger:
|
|
1288
|
-
} :
|
|
1289
|
-
let
|
|
1290
|
-
const
|
|
1291
|
-
if (typeof
|
|
512
|
+
function ze(e, c, a = {}) {
|
|
513
|
+
const { window: n = re, ignore: o = [], capture: t = !0, detectIframe: l = !1, controls: m = !1 } = a;
|
|
514
|
+
if (!n) return m ? {
|
|
515
|
+
stop: D,
|
|
516
|
+
cancel: D,
|
|
517
|
+
trigger: D
|
|
518
|
+
} : D;
|
|
519
|
+
let d = !0;
|
|
520
|
+
const u = (i) => B(o).some((s) => {
|
|
521
|
+
if (typeof s == "string") return Array.from(n.document.querySelectorAll(s)).some((x) => x === i.target || i.composedPath().includes(x));
|
|
1292
522
|
{
|
|
1293
|
-
const
|
|
1294
|
-
return
|
|
523
|
+
const x = W(s);
|
|
524
|
+
return x && (i.target === x || i.composedPath().includes(x));
|
|
1295
525
|
}
|
|
1296
526
|
});
|
|
1297
|
-
function p(
|
|
1298
|
-
const
|
|
1299
|
-
return
|
|
527
|
+
function p(i) {
|
|
528
|
+
const s = B(i);
|
|
529
|
+
return s && s.$.subTree.shapeFlag === 16;
|
|
1300
530
|
}
|
|
1301
|
-
function
|
|
1302
|
-
const
|
|
1303
|
-
return
|
|
531
|
+
function v(i, s) {
|
|
532
|
+
const x = B(i), K = x.$.subTree && x.$.subTree.children;
|
|
533
|
+
return K == null || !Array.isArray(K) ? !1 : K.some((A) => A.el === s.target || s.composedPath().includes(A.el));
|
|
1304
534
|
}
|
|
1305
|
-
const b = (
|
|
1306
|
-
const
|
|
1307
|
-
if (
|
|
1308
|
-
if ("detail" in
|
|
1309
|
-
|
|
535
|
+
const b = (i) => {
|
|
536
|
+
const s = W(e);
|
|
537
|
+
if (i.target != null && !(!(s instanceof Element) && p(e) && v(e, i)) && !(!s || s === i.target || i.composedPath().includes(s))) {
|
|
538
|
+
if ("detail" in i && i.detail === 0 && (d = !u(i)), !d) {
|
|
539
|
+
d = !0;
|
|
1310
540
|
return;
|
|
1311
541
|
}
|
|
1312
|
-
|
|
542
|
+
c(i);
|
|
1313
543
|
}
|
|
1314
544
|
};
|
|
1315
|
-
let
|
|
1316
|
-
const
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
}, 0), b(
|
|
545
|
+
let r = !1;
|
|
546
|
+
const I = [
|
|
547
|
+
X(n, "click", (i) => {
|
|
548
|
+
r || (r = !0, setTimeout(() => {
|
|
549
|
+
r = !1;
|
|
550
|
+
}, 0), b(i));
|
|
1321
551
|
}, {
|
|
1322
552
|
passive: !0,
|
|
1323
|
-
capture:
|
|
553
|
+
capture: t
|
|
1324
554
|
}),
|
|
1325
|
-
|
|
1326
|
-
const
|
|
1327
|
-
|
|
555
|
+
X(n, "pointerdown", (i) => {
|
|
556
|
+
const s = W(e);
|
|
557
|
+
d = !u(i) && !!(s && !i.composedPath().includes(s));
|
|
1328
558
|
}, { passive: !0 }),
|
|
1329
|
-
|
|
559
|
+
l && X(n, "blur", (i) => {
|
|
1330
560
|
setTimeout(() => {
|
|
1331
|
-
var
|
|
1332
|
-
const
|
|
1333
|
-
((
|
|
561
|
+
var s;
|
|
562
|
+
const x = W(e);
|
|
563
|
+
((s = n.document.activeElement) === null || s === void 0 ? void 0 : s.tagName) === "IFRAME" && !x?.contains(n.document.activeElement) && c(i);
|
|
1334
564
|
}, 0);
|
|
1335
565
|
}, { passive: !0 })
|
|
1336
|
-
].filter(Boolean),
|
|
1337
|
-
return
|
|
1338
|
-
stop:
|
|
566
|
+
].filter(Boolean), g = () => I.forEach((i) => i());
|
|
567
|
+
return m ? {
|
|
568
|
+
stop: g,
|
|
1339
569
|
cancel: () => {
|
|
1340
|
-
|
|
570
|
+
d = !1;
|
|
1341
571
|
},
|
|
1342
|
-
trigger: (
|
|
1343
|
-
|
|
572
|
+
trigger: (i) => {
|
|
573
|
+
d = !0, b(i), d = !1;
|
|
1344
574
|
}
|
|
1345
|
-
} :
|
|
575
|
+
} : g;
|
|
1346
576
|
}
|
|
1347
|
-
const
|
|
577
|
+
const Ke = /* @__PURE__ */ z({
|
|
1348
578
|
__name: "i18n-select-input",
|
|
1349
579
|
props: {
|
|
1350
580
|
attr: {},
|
|
@@ -1366,72 +596,72 @@ const xn = /* @__PURE__ */ D({
|
|
|
1366
596
|
"focus",
|
|
1367
597
|
"blur"
|
|
1368
598
|
],
|
|
1369
|
-
setup(e, { emit:
|
|
1370
|
-
const
|
|
599
|
+
setup(e, { emit: c }) {
|
|
600
|
+
const a = E(() => !!_gct.store.appInfo.id), n = e, o = c, t = E({
|
|
1371
601
|
get() {
|
|
1372
|
-
return
|
|
602
|
+
return n.i18nText ?? "";
|
|
1373
603
|
},
|
|
1374
|
-
set(
|
|
1375
|
-
|
|
604
|
+
set(r) {
|
|
605
|
+
r !== n.i18nText && o("update:i18nText", r);
|
|
1376
606
|
}
|
|
1377
|
-
}),
|
|
1378
|
-
console.log("emit",
|
|
607
|
+
}), l = E(() => P(n.i18nConfig) ? {} : typeof n.i18nConfig == "string" ? JSON.parse(n.i18nConfig) ?? {} : n.i18nConfig ?? {}), m = E(() => l.value?.[n.attr]), d = (r) => {
|
|
608
|
+
console.log("emit", r), r && ((P(t.value) || n.forceUpdate === !0) && o("update:i18nText", r.i18nTitle), o(
|
|
1379
609
|
"update:i18nConfig",
|
|
1380
610
|
JSON.stringify(
|
|
1381
|
-
|
|
611
|
+
P(r) ? ae(l.value, n.attr) : { ...l.value, [n.attr]: r.i18nKey }
|
|
1382
612
|
)
|
|
1383
|
-
),
|
|
1384
|
-
},
|
|
1385
|
-
|
|
1386
|
-
},
|
|
1387
|
-
|
|
1388
|
-
}, b =
|
|
1389
|
-
return
|
|
1390
|
-
|
|
1391
|
-
}), (
|
|
1392
|
-
const
|
|
1393
|
-
return
|
|
613
|
+
), o("on-i18n-select", r));
|
|
614
|
+
}, u = R(), p = () => {
|
|
615
|
+
o("focus", u.value);
|
|
616
|
+
}, v = () => {
|
|
617
|
+
o("blur", u.value);
|
|
618
|
+
}, b = R();
|
|
619
|
+
return ze(b, () => {
|
|
620
|
+
o("clickOutside");
|
|
621
|
+
}), (r, I) => {
|
|
622
|
+
const g = k("a-input"), i = k("a-input-group");
|
|
623
|
+
return S(), N(i, {
|
|
1394
624
|
id: "i18nInputGroup",
|
|
1395
625
|
ref_key: "i18nInputGroup",
|
|
1396
626
|
ref: b,
|
|
1397
627
|
compact: ""
|
|
1398
628
|
}, {
|
|
1399
|
-
default:
|
|
1400
|
-
|
|
1401
|
-
|
|
629
|
+
default: y(() => [
|
|
630
|
+
ve(r.$slots, "i18n-input", {}, () => [
|
|
631
|
+
f(g, O({
|
|
1402
632
|
ref_key: "inputRef",
|
|
1403
|
-
ref:
|
|
633
|
+
ref: u
|
|
1404
634
|
}, e.inputExtraProps, {
|
|
1405
|
-
value:
|
|
1406
|
-
"onUpdate:value":
|
|
635
|
+
value: t.value,
|
|
636
|
+
"onUpdate:value": I[0] || (I[0] = (s) => t.value = s),
|
|
1407
637
|
valueModifiers: { trim: !0 },
|
|
1408
638
|
style: {
|
|
1409
|
-
height: e.btnHeight ? e.btnHeight : e.size ===
|
|
1410
|
-
width:
|
|
639
|
+
height: e.btnHeight ? e.btnHeight : e.size === h(te).SMALL ? "26px" : "32px",
|
|
640
|
+
width: a.value ? `calc(100% - ${e.btnWidth ? e.btnWidth : e.size === h(te).SMALL ? "26px" : "32px"}` : "100%"
|
|
1411
641
|
},
|
|
1412
642
|
placeholder: e.placeholderText,
|
|
1413
643
|
size: e.size,
|
|
1414
644
|
"allow-clear": "",
|
|
1415
645
|
onFocus: p,
|
|
1416
|
-
onBlur:
|
|
646
|
+
onBlur: v
|
|
1417
647
|
}), null, 16, ["value", "style", "placeholder", "size"])
|
|
1418
648
|
], !0),
|
|
1419
|
-
|
|
649
|
+
a.value ? (S(), N(se, {
|
|
1420
650
|
key: 0,
|
|
1421
651
|
"btn-height": e.btnHeight,
|
|
1422
652
|
"btn-width": e.btnWidth,
|
|
1423
|
-
"i18n-value":
|
|
653
|
+
"i18n-value": m.value,
|
|
1424
654
|
size: e.size,
|
|
1425
655
|
"i18n-modal-key": e.i18nModalKey,
|
|
1426
|
-
onOnSelectI18n:
|
|
1427
|
-
onClosed:
|
|
1428
|
-
}, null, 8, ["btn-height", "btn-width", "i18n-value", "size", "i18n-modal-key"])) :
|
|
656
|
+
onOnSelectI18n: d,
|
|
657
|
+
onClosed: I[1] || (I[1] = (s) => o("clickOutside"))
|
|
658
|
+
}, null, 8, ["btn-height", "btn-width", "i18n-value", "size", "i18n-modal-key"])) : be("", !0)
|
|
1429
659
|
]),
|
|
1430
660
|
_: 3
|
|
1431
661
|
}, 512);
|
|
1432
662
|
};
|
|
1433
663
|
}
|
|
1434
|
-
}),
|
|
664
|
+
}), Ae = /* @__PURE__ */ G(Ke, [["__scopeId", "data-v-412e1309"]]), Je = /* @__PURE__ */ z({
|
|
1435
665
|
__name: "i18n-select-input-form",
|
|
1436
666
|
props: {
|
|
1437
667
|
formItemName: {},
|
|
@@ -1442,44 +672,44 @@ const xn = /* @__PURE__ */ D({
|
|
|
1442
672
|
formRef: {}
|
|
1443
673
|
},
|
|
1444
674
|
emits: ["update:text"],
|
|
1445
|
-
setup(e, { emit:
|
|
1446
|
-
const
|
|
675
|
+
setup(e, { emit: c }) {
|
|
676
|
+
const a = e, n = c, o = E({
|
|
1447
677
|
get() {
|
|
1448
|
-
return
|
|
678
|
+
return a.text ?? "";
|
|
1449
679
|
},
|
|
1450
|
-
set(
|
|
1451
|
-
|
|
680
|
+
set(t) {
|
|
681
|
+
n("update:text", t), a.formRef?.validateFields([a.formItemName]);
|
|
1452
682
|
}
|
|
1453
683
|
});
|
|
1454
|
-
return (
|
|
1455
|
-
const
|
|
1456
|
-
return
|
|
1457
|
-
m
|
|
1458
|
-
default:
|
|
1459
|
-
|
|
1460
|
-
"i18n-text":
|
|
1461
|
-
"onUpdate:i18nText":
|
|
684
|
+
return (t, l) => {
|
|
685
|
+
const m = k("a-form-item");
|
|
686
|
+
return S(), j(q, null, [
|
|
687
|
+
f(m, O({ name: e.formItemName }, e.fromItemExtraProps), {
|
|
688
|
+
default: y(() => [
|
|
689
|
+
f(Ae, O(t.$attrs, {
|
|
690
|
+
"i18n-text": o.value,
|
|
691
|
+
"onUpdate:i18nText": l[0] || (l[0] = (d) => o.value = d),
|
|
1462
692
|
"input-extra-props": e.inputExtraProps,
|
|
1463
693
|
"i18n-config": e.i18nConfig,
|
|
1464
694
|
attr: Array.isArray(e.formItemName) ? e.formItemName.join(".") : e.formItemName,
|
|
1465
|
-
"placeholder-text":
|
|
695
|
+
"placeholder-text": t.$t("sys.inputText")
|
|
1466
696
|
}), null, 16, ["i18n-text", "input-extra-props", "i18n-config", "attr", "placeholder-text"])
|
|
1467
697
|
]),
|
|
1468
698
|
_: 1
|
|
1469
699
|
}, 16, ["name"]),
|
|
1470
|
-
m
|
|
700
|
+
f(m, {
|
|
1471
701
|
name: "i18nConfig",
|
|
1472
702
|
hidden: ""
|
|
1473
703
|
}, {
|
|
1474
|
-
default:
|
|
1475
|
-
|
|
704
|
+
default: y(() => [
|
|
705
|
+
V("span", null, F(e.i18nConfig), 1)
|
|
1476
706
|
]),
|
|
1477
707
|
_: 1
|
|
1478
708
|
})
|
|
1479
709
|
], 64);
|
|
1480
710
|
};
|
|
1481
711
|
}
|
|
1482
|
-
}),
|
|
712
|
+
}), Ve = { class: "inline-block w100% relative" }, Fe = /* @__PURE__ */ z({
|
|
1483
713
|
__name: "i18n-select-textarea",
|
|
1484
714
|
props: {
|
|
1485
715
|
attr: {},
|
|
@@ -1497,51 +727,51 @@ const xn = /* @__PURE__ */ D({
|
|
|
1497
727
|
"clickOutside",
|
|
1498
728
|
"focus"
|
|
1499
729
|
],
|
|
1500
|
-
setup(e, { emit:
|
|
1501
|
-
const
|
|
730
|
+
setup(e, { emit: c }) {
|
|
731
|
+
const a = e, n = c, o = E({
|
|
1502
732
|
get() {
|
|
1503
|
-
return
|
|
733
|
+
return a.i18nText ?? "";
|
|
1504
734
|
},
|
|
1505
735
|
set(p) {
|
|
1506
|
-
|
|
736
|
+
n("update:i18nText", p);
|
|
1507
737
|
}
|
|
1508
|
-
}),
|
|
1509
|
-
p && (
|
|
738
|
+
}), t = E(() => P(a.i18nConfig) ? {} : typeof a.i18nConfig == "string" ? JSON.parse(a.i18nConfig) ?? {} : a.i18nConfig ?? {}), l = E(() => t.value?.[a.attr]), m = (p) => {
|
|
739
|
+
p && (P(o.value) && n("update:i18nText", p.i18nTitle), n(
|
|
1510
740
|
"update:i18nConfig",
|
|
1511
741
|
JSON.stringify(
|
|
1512
|
-
|
|
742
|
+
P(p) ? ae(t.value, a.attr) : { ...t.value, [a.attr]: p.i18nKey }
|
|
1513
743
|
)
|
|
1514
|
-
),
|
|
1515
|
-
},
|
|
1516
|
-
|
|
744
|
+
), n("on-i18n-select", p));
|
|
745
|
+
}, d = R(), u = () => {
|
|
746
|
+
n("focus", d.value);
|
|
1517
747
|
};
|
|
1518
|
-
return (p,
|
|
1519
|
-
const b =
|
|
1520
|
-
return
|
|
1521
|
-
|
|
748
|
+
return (p, v) => {
|
|
749
|
+
const b = k("a-textarea");
|
|
750
|
+
return S(), j("div", Ve, [
|
|
751
|
+
f(b, O({
|
|
1522
752
|
ref_key: "inputRef",
|
|
1523
|
-
ref:
|
|
1524
|
-
value:
|
|
1525
|
-
"onUpdate:value":
|
|
753
|
+
ref: d,
|
|
754
|
+
value: o.value,
|
|
755
|
+
"onUpdate:value": v[0] || (v[0] = (r) => o.value = r),
|
|
1526
756
|
placeholder: e.placeholderText
|
|
1527
757
|
}, e.inputExtraProps, {
|
|
1528
758
|
style: {
|
|
1529
759
|
resize: "none",
|
|
1530
760
|
...e.style
|
|
1531
761
|
},
|
|
1532
|
-
onFocus:
|
|
762
|
+
onFocus: u
|
|
1533
763
|
}), null, 16, ["value", "placeholder", "style"]),
|
|
1534
|
-
|
|
1535
|
-
"i18n-value":
|
|
764
|
+
f(se, {
|
|
765
|
+
"i18n-value": l.value,
|
|
1536
766
|
"simple-btn": !0,
|
|
1537
767
|
type: "text",
|
|
1538
|
-
onOnSelectI18n:
|
|
1539
|
-
onClosed:
|
|
768
|
+
onOnSelectI18n: m,
|
|
769
|
+
onClosed: v[1] || (v[1] = (r) => n("clickOutside"))
|
|
1540
770
|
}, null, 8, ["i18n-value"])
|
|
1541
771
|
]);
|
|
1542
772
|
};
|
|
1543
773
|
}
|
|
1544
|
-
}),
|
|
774
|
+
}), Be = /* @__PURE__ */ G(Fe, [["__scopeId", "data-v-cd95c416"]]), De = /* @__PURE__ */ z({
|
|
1545
775
|
__name: "i18n-select-textarea-form",
|
|
1546
776
|
props: {
|
|
1547
777
|
formItemName: {},
|
|
@@ -1552,24 +782,24 @@ const xn = /* @__PURE__ */ D({
|
|
|
1552
782
|
formRef: {}
|
|
1553
783
|
},
|
|
1554
784
|
emits: ["update:text"],
|
|
1555
|
-
setup(e, { emit:
|
|
1556
|
-
const
|
|
785
|
+
setup(e, { emit: c }) {
|
|
786
|
+
const a = e, n = c, o = E({
|
|
1557
787
|
get() {
|
|
1558
|
-
return
|
|
788
|
+
return a.text ?? "";
|
|
1559
789
|
},
|
|
1560
|
-
set(
|
|
1561
|
-
|
|
790
|
+
set(t) {
|
|
791
|
+
n("update:text", t), a.formRef?.validateFields([a.formItemName]);
|
|
1562
792
|
}
|
|
1563
793
|
});
|
|
1564
|
-
return (
|
|
1565
|
-
const
|
|
1566
|
-
return
|
|
1567
|
-
m
|
|
1568
|
-
default:
|
|
1569
|
-
|
|
1570
|
-
"i18n-text":
|
|
1571
|
-
"onUpdate:i18nText":
|
|
1572
|
-
"placeholder-text":
|
|
794
|
+
return (t, l) => {
|
|
795
|
+
const m = k("a-form-item");
|
|
796
|
+
return S(), j(q, null, [
|
|
797
|
+
f(m, O({ name: e.formItemName }, e.fromItemExtraProps), {
|
|
798
|
+
default: y(() => [
|
|
799
|
+
f(Be, O(t.$attrs, {
|
|
800
|
+
"i18n-text": o.value,
|
|
801
|
+
"onUpdate:i18nText": l[0] || (l[0] = (d) => o.value = d),
|
|
802
|
+
"placeholder-text": t.$t("sys.inputText"),
|
|
1573
803
|
"input-extra-props": e.inputExtraProps,
|
|
1574
804
|
"i18n-config": e.i18nConfig,
|
|
1575
805
|
attr: Array.isArray(e.formItemName) ? e.formItemName.join(".") : e.formItemName
|
|
@@ -1577,30 +807,30 @@ const xn = /* @__PURE__ */ D({
|
|
|
1577
807
|
]),
|
|
1578
808
|
_: 1
|
|
1579
809
|
}, 16, ["name"]),
|
|
1580
|
-
m
|
|
810
|
+
f(m, {
|
|
1581
811
|
name: "i18nConfig",
|
|
1582
812
|
hidden: ""
|
|
1583
813
|
}, {
|
|
1584
|
-
default:
|
|
1585
|
-
|
|
814
|
+
default: y(() => [
|
|
815
|
+
V("span", null, F(e.i18nConfig), 1)
|
|
1586
816
|
]),
|
|
1587
817
|
_: 1
|
|
1588
818
|
})
|
|
1589
819
|
], 64);
|
|
1590
820
|
};
|
|
1591
821
|
}
|
|
1592
|
-
}),
|
|
822
|
+
}), qe = {
|
|
1593
823
|
install(e) {
|
|
1594
824
|
console.log("Design Web install", e);
|
|
1595
825
|
}
|
|
1596
826
|
};
|
|
1597
827
|
export {
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
828
|
+
ke as I18Modal,
|
|
829
|
+
se as I18nSelectBtn,
|
|
830
|
+
Ae as I18nSelectInput,
|
|
831
|
+
Je as I18nSelectInputForm,
|
|
832
|
+
Be as I18nSelectTextarea,
|
|
833
|
+
De as I18nSelectTextareaForm,
|
|
834
|
+
qe as default,
|
|
835
|
+
Te as useI18nSelect
|
|
1606
836
|
};
|