iking-web-ui-pro 0.0.2 → 0.0.3

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.
Files changed (53) hide show
  1. package/dist/IKApprovalProcess/index.es.js +1 -1
  2. package/dist/IKApprovalProcess/index.umd.js +1 -1
  3. package/dist/IKApprovalProcess/style.css +1 -1
  4. package/dist/IKApprovalProcessDetail/style.css +1 -1
  5. package/dist/IKCalendar/index.es.js +1 -1
  6. package/dist/IKCalendar/index.umd.js +1 -1
  7. package/dist/IKCalendar/style.css +1 -1
  8. package/dist/IKDetailPreviewFiles/index.es.js +244 -1424
  9. package/dist/IKDetailPreviewFiles/index.umd.js +1 -1
  10. package/dist/IKDetailPreviewFiles/style.css +1 -1
  11. package/dist/IKExpandCollapse/index.es.js +143 -1323
  12. package/dist/IKExpandCollapse/index.umd.js +1 -1
  13. package/dist/IKExpandCollapse/style.css +1 -1
  14. package/dist/IKSearch/index.es.js +1 -1
  15. package/dist/IKSearch/index.umd.js +1 -1
  16. package/dist/IKSearch/style.css +1 -1
  17. package/dist/IKVerticalStepBar/index.es.js +190 -1370
  18. package/dist/IKVerticalStepBar/index.umd.js +3 -3
  19. package/dist/IKVerticalStepBar/style.css +1 -1
  20. package/dist/IkBaseDialog/index.es.js +234 -0
  21. package/dist/IkBaseDialog/index.umd.js +1 -0
  22. package/dist/IkBaseDialog/style.css +1 -0
  23. package/dist/IkBtnSetting/index.es.js +336 -1517
  24. package/dist/IkBtnSetting/index.umd.js +1 -1
  25. package/dist/IkBtnSetting/style.css +1 -1
  26. package/dist/IkIconPicker/index.es.js +2885 -1449
  27. package/dist/IkIconPicker/index.umd.js +5 -1
  28. package/dist/IkIconPicker/style.css +1 -1
  29. package/dist/IkPageFull/index.es.js +1678 -2859
  30. package/dist/IkPageFull/index.umd.js +3 -3
  31. package/dist/IkPageFull/style.css +1 -1
  32. package/dist/IkPicker/index.es.js +1 -1
  33. package/dist/IkPicker/index.umd.js +1 -1
  34. package/dist/IkPicker/style.css +1 -1
  35. package/dist/IkPickerUser/index.es.js +255 -237
  36. package/dist/IkPickerUser/index.umd.js +1 -1
  37. package/dist/IkPickerUser/style.css +1 -1
  38. package/dist/IkSchedule/index.es.js +2181 -3362
  39. package/dist/IkSchedule/index.umd.js +1 -1
  40. package/dist/IkSchedule/style.css +1 -1
  41. package/dist/IkSvgIcon/index.es.js +125 -1310
  42. package/dist/IkSvgIcon/index.umd.js +1 -1
  43. package/dist/IkUploadFile/index.es.js +955 -596
  44. package/dist/IkUploadFile/index.umd.js +1 -1
  45. package/dist/IkUploadFile/style.css +1 -1
  46. package/dist/IkUploadImage/index.es.js +113 -110
  47. package/dist/IkUploadImage/index.umd.js +1 -1
  48. package/dist/IkUploadImage/style.css +1 -1
  49. package/dist/index.es.js +12914 -11169
  50. package/dist/index.umd.js +10 -6
  51. package/dist/style.css +1 -1
  52. package/package.json +3 -3
  53. package/dist/IkSvgIcon/style.css +0 -1
@@ -1,1222 +1,27 @@
1
- import { defineComponent as ie, h as de, computed as P, resolveComponent as Ke, openBlock as w, createElementBlock as x, normalizeClass as E, normalizeStyle as J, createBlock as O, unref as V, createElementVNode as S, createCommentVNode as _, withCtx as Ge, mergeProps as Je, Fragment as he, renderList as pe, toDisplayString as W, createTextVNode as Xe } from "vue";
2
- const Pe = (e, t) => {
3
- if (e.install = (n) => {
4
- for (const i of [e, ...Object.values(t ?? {})])
5
- n.component(i.name, i);
6
- }, t)
7
- for (const [n, i] of Object.entries(t))
8
- e[n] = i;
9
- return e;
10
- }, Oe = (e, t) => {
11
- const n = e.__vccOpts || e;
12
- for (const [i, o] of t)
13
- n[i] = o;
14
- return n;
15
- }, M = /^[a-z0-9]+(-[a-z0-9]+)*$/, R = (e, t, n, i = "") => {
16
- const o = e.split(":");
17
- if (e.slice(0, 1) === "@") {
18
- if (o.length < 2 || o.length > 3)
19
- return null;
20
- i = o.shift().slice(1);
21
- }
22
- if (o.length > 3 || !o.length)
23
- return null;
24
- if (o.length > 1) {
25
- const c = o.pop(), l = o.pop(), a = {
26
- // Allow provider without '@': "provider:prefix:name"
27
- provider: o.length > 0 ? o[0] : i,
28
- prefix: l,
29
- name: c
30
- };
31
- return t && !N(a) ? null : a;
32
- }
33
- const r = o[0], s = r.split("-");
34
- if (s.length > 1) {
35
- const c = {
36
- provider: i,
37
- prefix: s.shift(),
38
- name: s.join("-")
39
- };
40
- return t && !N(c) ? null : c;
41
- }
42
- if (n && i === "") {
43
- const c = {
44
- provider: i,
45
- prefix: "",
46
- name: r
47
- };
48
- return t && !N(c, n) ? null : c;
49
- }
50
- return null;
51
- }, N = (e, t) => e ? !!((e.provider === "" || e.provider.match(M)) && (t && e.prefix === "" || e.prefix.match(M)) && e.name.match(M)) : !1, Me = Object.freeze(
52
- {
53
- left: 0,
54
- top: 0,
55
- width: 16,
56
- height: 16
57
- }
58
- ), H = Object.freeze({
59
- rotate: 0,
60
- vFlip: !1,
61
- hFlip: !1
62
- }), q = Object.freeze({
63
- ...Me,
64
- ...H
65
- }), X = Object.freeze({
66
- ...q,
67
- body: "",
68
- hidden: !1
69
- });
70
- function Ye(e, t) {
71
- const n = {};
72
- !e.hFlip != !t.hFlip && (n.hFlip = !0), !e.vFlip != !t.vFlip && (n.vFlip = !0);
73
- const i = ((e.rotate || 0) + (t.rotate || 0)) % 4;
74
- return i && (n.rotate = i), n;
75
- }
76
- function ge(e, t) {
77
- const n = Ye(e, t);
78
- for (const i in X)
79
- i in H ? i in e && !(i in n) && (n[i] = H[i]) : i in t ? n[i] = t[i] : i in e && (n[i] = e[i]);
80
- return n;
81
- }
82
- function Ze(e, t) {
83
- const n = e.icons, i = e.aliases || /* @__PURE__ */ Object.create(null), o = /* @__PURE__ */ Object.create(null);
84
- function r(s) {
85
- if (n[s])
86
- return o[s] = [];
87
- if (!(s in o)) {
88
- o[s] = null;
89
- const c = i[s] && i[s].parent, l = c && r(c);
90
- l && (o[s] = [c].concat(l));
91
- }
92
- return o[s];
93
- }
94
- return (t || Object.keys(n).concat(Object.keys(i))).forEach(r), o;
95
- }
96
- function et(e, t, n) {
97
- const i = e.icons, o = e.aliases || /* @__PURE__ */ Object.create(null);
98
- let r = {};
99
- function s(c) {
100
- r = ge(
101
- i[c] || o[c],
102
- r
103
- );
104
- }
105
- return s(t), n.forEach(s), ge(e, r);
106
- }
107
- function Le(e, t) {
108
- const n = [];
109
- if (typeof e != "object" || typeof e.icons != "object")
110
- return n;
111
- e.not_found instanceof Array && e.not_found.forEach((o) => {
112
- t(o, null), n.push(o);
113
- });
114
- const i = Ze(e);
115
- for (const o in i) {
116
- const r = i[o];
117
- r && (t(o, et(e, o, r)), n.push(o));
118
- }
119
- return n;
120
- }
121
- const tt = {
122
- provider: "",
123
- aliases: {},
124
- not_found: {},
125
- ...Me
126
- };
127
- function K(e, t) {
128
- for (const n in t)
129
- if (n in e && typeof e[n] != typeof t[n])
130
- return !1;
131
- return !0;
132
- }
133
- function Ae(e) {
134
- if (typeof e != "object" || e === null)
135
- return null;
136
- const t = e;
137
- if (typeof t.prefix != "string" || !e.icons || typeof e.icons != "object" || !K(e, tt))
138
- return null;
139
- const n = t.icons;
140
- for (const o in n) {
141
- const r = n[o];
142
- if (!o.match(M) || typeof r.body != "string" || !K(
143
- r,
144
- X
145
- ))
146
- return null;
147
- }
148
- const i = t.aliases || /* @__PURE__ */ Object.create(null);
149
- for (const o in i) {
150
- const r = i[o], s = r.parent;
151
- if (!o.match(M) || typeof s != "string" || !n[s] && !i[s] || !K(
152
- r,
153
- X
154
- ))
155
- return null;
156
- }
157
- return t;
158
- }
159
- const me = /* @__PURE__ */ Object.create(null);
160
- function nt(e, t) {
161
- return {
162
- provider: e,
163
- prefix: t,
164
- icons: /* @__PURE__ */ Object.create(null),
165
- missing: /* @__PURE__ */ new Set()
166
- };
167
- }
168
- function j(e, t) {
169
- const n = me[e] || (me[e] = /* @__PURE__ */ Object.create(null));
170
- return n[t] || (n[t] = nt(e, t));
171
- }
172
- function re(e, t) {
173
- return Ae(t) ? Le(t, (n, i) => {
174
- i ? e.icons[n] = i : e.missing.add(n);
175
- }) : [];
176
- }
177
- function ot(e, t, n) {
178
- try {
179
- if (typeof n.body == "string")
180
- return e.icons[t] = { ...n }, !0;
181
- } catch {
182
- }
183
- return !1;
184
- }
185
- let L = !1;
186
- function $e(e) {
187
- return typeof e == "boolean" && (L = e), L;
188
- }
189
- function it(e) {
190
- const t = typeof e == "string" ? R(e, !0, L) : e;
191
- if (t) {
192
- const n = j(t.provider, t.prefix), i = t.name;
193
- return n.icons[i] || (n.missing.has(i) ? null : void 0);
194
- }
195
- }
196
- function rt(e, t) {
197
- const n = R(e, !0, L);
198
- if (!n)
199
- return !1;
200
- const i = j(n.provider, n.prefix);
201
- return ot(i, n.name, t);
202
- }
203
- function st(e, t) {
204
- if (typeof e != "object")
205
- return !1;
206
- if (typeof t != "string" && (t = e.provider || ""), L && !t && !e.prefix) {
207
- let o = !1;
208
- return Ae(e) && (e.prefix = "", Le(e, (r, s) => {
209
- s && rt(r, s) && (o = !0);
210
- })), o;
211
- }
212
- const n = e.prefix;
213
- if (!N({
214
- provider: t,
215
- prefix: n,
216
- name: "a"
217
- }))
218
- return !1;
219
- const i = j(t, n);
220
- return !!re(i, e);
221
- }
222
- const ze = Object.freeze({
223
- width: null,
224
- height: null
225
- }), Ne = Object.freeze({
226
- // Dimensions
227
- ...ze,
228
- // Transformations
229
- ...H
230
- }), ct = /(-?[0-9.]*[0-9]+[0-9.]*)/g, lt = /^-?[0-9.]*[0-9]+[0-9.]*$/g;
231
- function ye(e, t, n) {
232
- if (t === 1)
233
- return e;
234
- if (n = n || 100, typeof e == "number")
235
- return Math.ceil(e * t * n) / n;
236
- if (typeof e != "string")
237
- return e;
238
- const i = e.split(ct);
239
- if (i === null || !i.length)
240
- return e;
241
- const o = [];
242
- let r = i.shift(), s = lt.test(r);
243
- for (; ; ) {
244
- if (s) {
245
- const c = parseFloat(r);
246
- isNaN(c) ? o.push(r) : o.push(Math.ceil(c * t * n) / n);
247
- } else
248
- o.push(r);
249
- if (r = i.shift(), r === void 0)
250
- return o.join("");
251
- s = !s;
252
- }
253
- }
254
- const at = (e) => e === "unset" || e === "undefined" || e === "none";
255
- function ut(e, t) {
256
- const n = {
257
- ...q,
258
- ...e
259
- }, i = {
260
- ...Ne,
261
- ...t
262
- }, o = {
263
- left: n.left,
264
- top: n.top,
265
- width: n.width,
266
- height: n.height
267
- };
268
- let r = n.body;
269
- [n, i].forEach((f) => {
270
- const d = [], g = f.hFlip, I = f.vFlip;
271
- let b = f.rotate;
272
- g ? I ? b += 2 : (d.push(
273
- "translate(" + (o.width + o.left).toString() + " " + (0 - o.top).toString() + ")"
274
- ), d.push("scale(-1 1)"), o.top = o.left = 0) : I && (d.push(
275
- "translate(" + (0 - o.left).toString() + " " + (o.height + o.top).toString() + ")"
276
- ), d.push("scale(1 -1)"), o.top = o.left = 0);
277
- let v;
278
- switch (b < 0 && (b -= Math.floor(b / 4) * 4), b = b % 4, b) {
279
- case 1:
280
- v = o.height / 2 + o.top, d.unshift(
281
- "rotate(90 " + v.toString() + " " + v.toString() + ")"
282
- );
283
- break;
284
- case 2:
285
- d.unshift(
286
- "rotate(180 " + (o.width / 2 + o.left).toString() + " " + (o.height / 2 + o.top).toString() + ")"
287
- );
288
- break;
289
- case 3:
290
- v = o.width / 2 + o.left, d.unshift(
291
- "rotate(-90 " + v.toString() + " " + v.toString() + ")"
292
- );
293
- break;
294
- }
295
- b % 2 === 1 && (o.left !== o.top && (v = o.left, o.left = o.top, o.top = v), o.width !== o.height && (v = o.width, o.width = o.height, o.height = v)), d.length && (r = '<g transform="' + d.join(" ") + '">' + r + "</g>");
296
- });
297
- const s = i.width, c = i.height, l = o.width, a = o.height;
298
- let u, m;
299
- s === null ? (m = c === null ? "1em" : c === "auto" ? a : c, u = ye(m, l / a)) : (u = s === "auto" ? l : s, m = c === null ? ye(u, a / l) : c === "auto" ? a : c);
300
- const h = {}, p = (f, d) => {
301
- at(d) || (h[f] = d.toString());
302
- };
303
- return p("width", u), p("height", m), h.viewBox = o.left.toString() + " " + o.top.toString() + " " + l.toString() + " " + a.toString(), {
304
- attributes: h,
305
- body: r
306
- };
307
- }
308
- const ft = /\sid="(\S+)"/g, dt = "IconifyId" + Date.now().toString(16) + (Math.random() * 16777216 | 0).toString(16);
309
- let ht = 0;
310
- function pt(e, t = dt) {
311
- const n = [];
312
- let i;
313
- for (; i = ft.exec(e); )
314
- n.push(i[1]);
315
- if (!n.length)
316
- return e;
317
- const o = "suffix" + (Math.random() * 16777216 | Date.now()).toString(16);
318
- return n.forEach((r) => {
319
- const s = typeof t == "function" ? t(r) : t + (ht++).toString(), c = r.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
320
- e = e.replace(
321
- // Allowed characters before id: [#;"]
322
- // Allowed characters after id: [)"], .[a-z]
323
- new RegExp('([#;"])(' + c + ')([")]|\\.[a-z])', "g"),
324
- "$1" + s + o + "$3"
325
- );
326
- }), e = e.replace(new RegExp(o, "g"), ""), e;
327
- }
328
- const Y = /* @__PURE__ */ Object.create(null);
329
- function gt(e, t) {
330
- Y[e] = t;
331
- }
332
- function Z(e) {
333
- return Y[e] || Y[""];
334
- }
335
- function se(e) {
336
- let t;
337
- if (typeof e.resources == "string")
338
- t = [e.resources];
339
- else if (t = e.resources, !(t instanceof Array) || !t.length)
340
- return null;
341
- return {
342
- // API hosts
343
- resources: t,
344
- // Root path
345
- path: e.path || "/",
346
- // URL length limit
347
- maxURL: e.maxURL || 500,
348
- // Timeout before next host is used.
349
- rotate: e.rotate || 750,
350
- // Timeout before failing query.
351
- timeout: e.timeout || 5e3,
352
- // Randomise default API end point.
353
- random: e.random === !0,
354
- // Start index
355
- index: e.index || 0,
356
- // Receive data after time out (used if time out kicks in first, then API module sends data anyway).
357
- dataAfterTimeout: e.dataAfterTimeout !== !1
358
- };
359
- }
360
- const ce = /* @__PURE__ */ Object.create(null), F = [
361
- "https://api.simplesvg.com",
362
- "https://api.unisvg.com"
363
- ], B = [];
364
- for (; F.length > 0; )
365
- F.length === 1 || Math.random() > 0.5 ? B.push(F.shift()) : B.push(F.pop());
366
- ce[""] = se({
367
- resources: ["https://api.iconify.design"].concat(B)
368
- });
369
- function mt(e, t) {
370
- const n = se(t);
371
- return n === null ? !1 : (ce[e] = n, !0);
372
- }
373
- function le(e) {
374
- return ce[e];
375
- }
376
- const yt = () => {
377
- let e;
378
- try {
379
- if (e = fetch, typeof e == "function")
380
- return e;
381
- } catch {
382
- }
383
- };
384
- let be = yt();
385
- function bt(e, t) {
386
- const n = le(e);
387
- if (!n)
388
- return 0;
389
- let i;
390
- if (!n.maxURL)
391
- i = 0;
392
- else {
393
- let o = 0;
394
- n.resources.forEach((s) => {
395
- o = Math.max(o, s.length);
396
- });
397
- const r = t + ".json?icons=";
398
- i = n.maxURL - o - n.path.length - r.length;
399
- }
1
+ import { defineComponent as F, computed as k, resolveComponent as E, openBlock as o, createElementBlock as u, normalizeClass as f, normalizeStyle as h, createElementVNode as d, createCommentVNode as m, createBlock as C, withCtx as K, Fragment as B, renderList as I, toDisplayString as w, createTextVNode as T, unref as S } from "vue";
2
+ import { ikColor as q } from "iking-utils";
3
+ const N = (s, l) => {
4
+ if (s.install = (i) => {
5
+ for (const c of [s, ...Object.values(l ?? {})])
6
+ i.component(c.name, c);
7
+ }, l)
8
+ for (const [i, c] of Object.entries(l))
9
+ s[i] = c;
10
+ return s;
11
+ }, X = (s, l) => {
12
+ const i = s.__vccOpts || s;
13
+ for (const [c, e] of l)
14
+ i[c] = e;
400
15
  return i;
401
- }
402
- function vt(e) {
403
- return e === 404;
404
- }
405
- const wt = (e, t, n) => {
406
- const i = [], o = bt(e, t), r = "icons";
407
- let s = {
408
- type: r,
409
- provider: e,
410
- prefix: t,
411
- icons: []
412
- }, c = 0;
413
- return n.forEach((l, a) => {
414
- c += l.length + 1, c >= o && a > 0 && (i.push(s), s = {
415
- type: r,
416
- provider: e,
417
- prefix: t,
418
- icons: []
419
- }, c = l.length), s.icons.push(l);
420
- }), i.push(s), i;
421
- };
422
- function kt(e) {
423
- if (typeof e == "string") {
424
- const t = le(e);
425
- if (t)
426
- return t.path;
427
- }
428
- return "/";
429
- }
430
- const It = (e, t, n) => {
431
- if (!be) {
432
- n("abort", 424);
433
- return;
434
- }
435
- let i = kt(t.provider);
436
- switch (t.type) {
437
- case "icons": {
438
- const r = t.prefix, c = t.icons.join(","), l = new URLSearchParams({
439
- icons: c
440
- });
441
- i += r + ".json?" + l.toString();
442
- break;
443
- }
444
- case "custom": {
445
- const r = t.uri;
446
- i += r.slice(0, 1) === "/" ? r.slice(1) : r;
447
- break;
448
- }
449
- default:
450
- n("abort", 400);
451
- return;
452
- }
453
- let o = 503;
454
- be(e + i).then((r) => {
455
- const s = r.status;
456
- if (s !== 200) {
457
- setTimeout(() => {
458
- n(vt(s) ? "abort" : "next", s);
459
- });
460
- return;
461
- }
462
- return o = 501, r.json();
463
- }).then((r) => {
464
- if (typeof r != "object" || r === null) {
465
- setTimeout(() => {
466
- r === 404 ? n("abort", r) : n("next", o);
467
- });
468
- return;
469
- }
470
- setTimeout(() => {
471
- n("success", r);
472
- });
473
- }).catch(() => {
474
- n("next", o);
475
- });
476
- }, xt = {
477
- prepare: wt,
478
- send: It
479
- };
480
- function St(e) {
481
- const t = {
482
- loaded: [],
483
- missing: [],
484
- pending: []
485
- }, n = /* @__PURE__ */ Object.create(null);
486
- e.sort((o, r) => o.provider !== r.provider ? o.provider.localeCompare(r.provider) : o.prefix !== r.prefix ? o.prefix.localeCompare(r.prefix) : o.name.localeCompare(r.name));
487
- let i = {
488
- provider: "",
489
- prefix: "",
490
- name: ""
491
- };
492
- return e.forEach((o) => {
493
- if (i.name === o.name && i.prefix === o.prefix && i.provider === o.provider)
494
- return;
495
- i = o;
496
- const r = o.provider, s = o.prefix, c = o.name, l = n[r] || (n[r] = /* @__PURE__ */ Object.create(null)), a = l[s] || (l[s] = j(r, s));
497
- let u;
498
- c in a.icons ? u = t.loaded : s === "" || a.missing.has(c) ? u = t.missing : u = t.pending;
499
- const m = {
500
- provider: r,
501
- prefix: s,
502
- name: c
503
- };
504
- u.push(m);
505
- }), t;
506
- }
507
- function Be(e, t) {
508
- e.forEach((n) => {
509
- const i = n.loaderCallbacks;
510
- i && (n.loaderCallbacks = i.filter((o) => o.id !== t));
511
- });
512
- }
513
- function Ct(e) {
514
- e.pendingCallbacksFlag || (e.pendingCallbacksFlag = !0, setTimeout(() => {
515
- e.pendingCallbacksFlag = !1;
516
- const t = e.loaderCallbacks ? e.loaderCallbacks.slice(0) : [];
517
- if (!t.length)
518
- return;
519
- let n = !1;
520
- const i = e.provider, o = e.prefix;
521
- t.forEach((r) => {
522
- const s = r.icons, c = s.pending.length;
523
- s.pending = s.pending.filter((l) => {
524
- if (l.prefix !== o)
525
- return !0;
526
- const a = l.name;
527
- if (e.icons[a])
528
- s.loaded.push({
529
- provider: i,
530
- prefix: o,
531
- name: a
532
- });
533
- else if (e.missing.has(a))
534
- s.missing.push({
535
- provider: i,
536
- prefix: o,
537
- name: a
538
- });
539
- else
540
- return n = !0, !0;
541
- return !1;
542
- }), s.pending.length !== c && (n || Be([e], r.id), r.callback(
543
- s.loaded.slice(0),
544
- s.missing.slice(0),
545
- s.pending.slice(0),
546
- r.abort
547
- ));
548
- });
549
- }));
550
- }
551
- let jt = 0;
552
- function _t(e, t, n) {
553
- const i = jt++, o = Be.bind(null, n, i);
554
- if (!t.pending.length)
555
- return o;
556
- const r = {
557
- id: i,
558
- icons: t,
559
- callback: e,
560
- abort: o
561
- };
562
- return n.forEach((s) => {
563
- (s.loaderCallbacks || (s.loaderCallbacks = [])).push(r);
564
- }), o;
565
- }
566
- function Tt(e, t = !0, n = !1) {
567
- const i = [];
568
- return e.forEach((o) => {
569
- const r = typeof o == "string" ? R(o, t, n) : o;
570
- r && i.push(r);
571
- }), i;
572
- }
573
- var Ft = {
574
- resources: [],
575
- index: 0,
576
- timeout: 2e3,
577
- rotate: 750,
578
- random: !1,
579
- dataAfterTimeout: !1
580
- };
581
- function Et(e, t, n, i) {
582
- const o = e.resources.length, r = e.random ? Math.floor(Math.random() * o) : e.index;
583
- let s;
584
- if (e.random) {
585
- let y = e.resources.slice(0);
586
- for (s = []; y.length > 1; ) {
587
- const k = Math.floor(Math.random() * y.length);
588
- s.push(y[k]), y = y.slice(0, k).concat(y.slice(k + 1));
589
- }
590
- s = s.concat(y);
591
- } else
592
- s = e.resources.slice(r).concat(e.resources.slice(0, r));
593
- const c = Date.now();
594
- let l = "pending", a = 0, u, m = null, h = [], p = [];
595
- typeof i == "function" && p.push(i);
596
- function f() {
597
- m && (clearTimeout(m), m = null);
598
- }
599
- function d() {
600
- l === "pending" && (l = "aborted"), f(), h.forEach((y) => {
601
- y.status === "pending" && (y.status = "aborted");
602
- }), h = [];
603
- }
604
- function g(y, k) {
605
- k && (p = []), typeof y == "function" && p.push(y);
606
- }
607
- function I() {
608
- return {
609
- startTime: c,
610
- payload: t,
611
- status: l,
612
- queriesSent: a,
613
- queriesPending: h.length,
614
- subscribe: g,
615
- abort: d
616
- };
617
- }
618
- function b() {
619
- l = "failed", p.forEach((y) => {
620
- y(void 0, u);
621
- });
622
- }
623
- function v() {
624
- h.forEach((y) => {
625
- y.status === "pending" && (y.status = "aborted");
626
- }), h = [];
627
- }
628
- function fe(y, k, T) {
629
- const $ = k !== "success";
630
- switch (h = h.filter((C) => C !== y), l) {
631
- case "pending":
632
- break;
633
- case "failed":
634
- if ($ || !e.dataAfterTimeout)
635
- return;
636
- break;
637
- default:
638
- return;
639
- }
640
- if (k === "abort") {
641
- u = T, b();
642
- return;
643
- }
644
- if ($) {
645
- u = T, h.length || (s.length ? U() : b());
646
- return;
647
- }
648
- if (f(), v(), !e.random) {
649
- const C = e.resources.indexOf(y.resource);
650
- C !== -1 && C !== e.index && (e.index = C);
651
- }
652
- l = "completed", p.forEach((C) => {
653
- C(T);
654
- });
655
- }
656
- function U() {
657
- if (l !== "pending")
658
- return;
659
- f();
660
- const y = s.shift();
661
- if (y === void 0) {
662
- if (h.length) {
663
- m = setTimeout(() => {
664
- f(), l === "pending" && (v(), b());
665
- }, e.timeout);
666
- return;
667
- }
668
- b();
669
- return;
670
- }
671
- const k = {
672
- status: "pending",
673
- resource: y,
674
- callback: (T, $) => {
675
- fe(k, T, $);
676
- }
677
- };
678
- h.push(k), a++, m = setTimeout(U, e.rotate), n(y, t, k.callback);
679
- }
680
- return setTimeout(U), I;
681
- }
682
- function De(e) {
683
- const t = {
684
- ...Ft,
685
- ...e
686
- };
687
- let n = [];
688
- function i() {
689
- n = n.filter((c) => c().status === "pending");
690
- }
691
- function o(c, l, a) {
692
- const u = Et(
693
- t,
694
- c,
695
- l,
696
- (m, h) => {
697
- i(), a && a(m, h);
698
- }
699
- );
700
- return n.push(u), u;
701
- }
702
- function r(c) {
703
- return n.find((l) => c(l)) || null;
704
- }
705
- return {
706
- query: o,
707
- find: r,
708
- setIndex: (c) => {
709
- t.index = c;
710
- },
711
- getIndex: () => t.index,
712
- cleanup: i
713
- };
714
- }
715
- function ve() {
716
- }
717
- const G = /* @__PURE__ */ Object.create(null);
718
- function Pt(e) {
719
- if (!G[e]) {
720
- const t = le(e);
721
- if (!t)
722
- return;
723
- const n = De(t), i = {
724
- config: t,
725
- redundancy: n
726
- };
727
- G[e] = i;
728
- }
729
- return G[e];
730
- }
731
- function Ot(e, t, n) {
732
- let i, o;
733
- if (typeof e == "string") {
734
- const r = Z(e);
735
- if (!r)
736
- return n(void 0, 424), ve;
737
- o = r.send;
738
- const s = Pt(e);
739
- s && (i = s.redundancy);
740
- } else {
741
- const r = se(e);
742
- if (r) {
743
- i = De(r);
744
- const s = e.resources ? e.resources[0] : "", c = Z(s);
745
- c && (o = c.send);
746
- }
747
- }
748
- return !i || !o ? (n(void 0, 424), ve) : i.query(t, o, n)().abort;
749
- }
750
- const we = "iconify2", A = "iconify", Ve = A + "-count", ke = A + "-version", He = 36e5, Mt = 168;
751
- function ee(e, t) {
752
- try {
753
- return e.getItem(t);
754
- } catch {
755
- }
756
- }
757
- function ae(e, t, n) {
758
- try {
759
- return e.setItem(t, n), !0;
760
- } catch {
761
- }
762
- }
763
- function Ie(e, t) {
764
- try {
765
- e.removeItem(t);
766
- } catch {
767
- }
768
- }
769
- function te(e, t) {
770
- return ae(e, Ve, t.toString());
771
- }
772
- function ne(e) {
773
- return parseInt(ee(e, Ve)) || 0;
774
- }
775
- const Q = {
776
- local: !0,
777
- session: !0
778
- }, Re = {
779
- local: /* @__PURE__ */ new Set(),
780
- session: /* @__PURE__ */ new Set()
781
- };
782
- let ue = !1;
783
- function Lt(e) {
784
- ue = e;
785
- }
786
- let z = typeof window > "u" ? {} : window;
787
- function qe(e) {
788
- const t = e + "Storage";
789
- try {
790
- if (z && z[t] && typeof z[t].length == "number")
791
- return z[t];
792
- } catch {
793
- }
794
- Q[e] = !1;
795
- }
796
- function Qe(e, t) {
797
- const n = qe(e);
798
- if (!n)
799
- return;
800
- const i = ee(n, ke);
801
- if (i !== we) {
802
- if (i) {
803
- const c = ne(n);
804
- for (let l = 0; l < c; l++)
805
- Ie(n, A + l.toString());
806
- }
807
- ae(n, ke, we), te(n, 0);
808
- return;
809
- }
810
- const o = Math.floor(Date.now() / He) - Mt, r = (c) => {
811
- const l = A + c.toString(), a = ee(n, l);
812
- if (typeof a == "string") {
813
- try {
814
- const u = JSON.parse(a);
815
- if (typeof u == "object" && typeof u.cached == "number" && u.cached > o && typeof u.provider == "string" && typeof u.data == "object" && typeof u.data.prefix == "string" && // Valid item: run callback
816
- t(u, c))
817
- return !0;
818
- } catch {
819
- }
820
- Ie(n, l);
821
- }
822
- };
823
- let s = ne(n);
824
- for (let c = s - 1; c >= 0; c--)
825
- r(c) || (c === s - 1 ? (s--, te(n, s)) : Re[e].add(c));
826
- }
827
- function Ue() {
828
- if (!ue) {
829
- Lt(!0);
830
- for (const e in Q)
831
- Qe(e, (t) => {
832
- const n = t.data, i = t.provider, o = n.prefix, r = j(
833
- i,
834
- o
835
- );
836
- if (!re(r, n).length)
837
- return !1;
838
- const s = n.lastModified || -1;
839
- return r.lastModifiedCached = r.lastModifiedCached ? Math.min(r.lastModifiedCached, s) : s, !0;
840
- });
841
- }
842
- }
843
- function At(e, t) {
844
- const n = e.lastModifiedCached;
845
- if (
846
- // Matches or newer
847
- n && n >= t
848
- )
849
- return n === t;
850
- if (e.lastModifiedCached = t, n)
851
- for (const i in Q)
852
- Qe(i, (o) => {
853
- const r = o.data;
854
- return o.provider !== e.provider || r.prefix !== e.prefix || r.lastModified === t;
855
- });
856
- return !0;
857
- }
858
- function $t(e, t) {
859
- ue || Ue();
860
- function n(i) {
861
- let o;
862
- if (!Q[i] || !(o = qe(i)))
863
- return;
864
- const r = Re[i];
865
- let s;
866
- if (r.size)
867
- r.delete(s = Array.from(r).shift());
868
- else if (s = ne(o), !te(o, s + 1))
869
- return;
870
- const c = {
871
- cached: Math.floor(Date.now() / He),
872
- provider: e.provider,
873
- data: t
874
- };
875
- return ae(
876
- o,
877
- A + s.toString(),
878
- JSON.stringify(c)
879
- );
880
- }
881
- t.lastModified && !At(e, t.lastModified) || Object.keys(t.icons).length && (t.not_found && (t = Object.assign({}, t), delete t.not_found), n("local") || n("session"));
882
- }
883
- function xe() {
884
- }
885
- function zt(e) {
886
- e.iconsLoaderFlag || (e.iconsLoaderFlag = !0, setTimeout(() => {
887
- e.iconsLoaderFlag = !1, Ct(e);
888
- }));
889
- }
890
- function Nt(e, t) {
891
- e.iconsToLoad ? e.iconsToLoad = e.iconsToLoad.concat(t).sort() : e.iconsToLoad = t, e.iconsQueueFlag || (e.iconsQueueFlag = !0, setTimeout(() => {
892
- e.iconsQueueFlag = !1;
893
- const { provider: n, prefix: i } = e, o = e.iconsToLoad;
894
- delete e.iconsToLoad;
895
- let r;
896
- if (!o || !(r = Z(n)))
897
- return;
898
- r.prepare(n, i, o).forEach((c) => {
899
- Ot(n, c, (l) => {
900
- if (typeof l != "object")
901
- c.icons.forEach((a) => {
902
- e.missing.add(a);
903
- });
904
- else
905
- try {
906
- const a = re(
907
- e,
908
- l
909
- );
910
- if (!a.length)
911
- return;
912
- const u = e.pendingIcons;
913
- u && a.forEach((m) => {
914
- u.delete(m);
915
- }), $t(e, l);
916
- } catch (a) {
917
- console.error(a);
918
- }
919
- zt(e);
920
- });
921
- });
922
- }));
923
- }
924
- const Bt = (e, t) => {
925
- const n = Tt(e, !0, $e()), i = St(n);
926
- if (!i.pending.length) {
927
- let l = !0;
928
- return t && setTimeout(() => {
929
- l && t(
930
- i.loaded,
931
- i.missing,
932
- i.pending,
933
- xe
934
- );
935
- }), () => {
936
- l = !1;
937
- };
938
- }
939
- const o = /* @__PURE__ */ Object.create(null), r = [];
940
- let s, c;
941
- return i.pending.forEach((l) => {
942
- const { provider: a, prefix: u } = l;
943
- if (u === c && a === s)
944
- return;
945
- s = a, c = u, r.push(j(a, u));
946
- const m = o[a] || (o[a] = /* @__PURE__ */ Object.create(null));
947
- m[u] || (m[u] = []);
948
- }), i.pending.forEach((l) => {
949
- const { provider: a, prefix: u, name: m } = l, h = j(a, u), p = h.pendingIcons || (h.pendingIcons = /* @__PURE__ */ new Set());
950
- p.has(m) || (p.add(m), o[a][u].push(m));
951
- }), r.forEach((l) => {
952
- const { provider: a, prefix: u } = l;
953
- o[a][u].length && Nt(l, o[a][u]);
954
- }), t ? _t(t, i, r) : xe;
955
- };
956
- function Dt(e, t) {
957
- const n = {
958
- ...e
959
- };
960
- for (const i in t) {
961
- const o = t[i], r = typeof o;
962
- i in ze ? (o === null || o && (r === "string" || r === "number")) && (n[i] = o) : r === typeof n[i] && (n[i] = i === "rotate" ? o % 4 : o);
963
- }
964
- return n;
965
- }
966
- const Vt = /[\s,]+/;
967
- function Ht(e, t) {
968
- t.split(Vt).forEach((n) => {
969
- switch (n.trim()) {
970
- case "horizontal":
971
- e.hFlip = !0;
972
- break;
973
- case "vertical":
974
- e.vFlip = !0;
975
- break;
976
- }
977
- });
978
- }
979
- function Rt(e, t = 0) {
980
- const n = e.replace(/^-?[0-9.]*/, "");
981
- function i(o) {
982
- for (; o < 0; )
983
- o += 4;
984
- return o % 4;
985
- }
986
- if (n === "") {
987
- const o = parseInt(e);
988
- return isNaN(o) ? 0 : i(o);
989
- } else if (n !== e) {
990
- let o = 0;
991
- switch (n) {
992
- case "%":
993
- o = 25;
994
- break;
995
- case "deg":
996
- o = 90;
997
- }
998
- if (o) {
999
- let r = parseFloat(e.slice(0, e.length - n.length));
1000
- return isNaN(r) ? 0 : (r = r / o, r % 1 === 0 ? i(r) : 0);
1001
- }
1002
- }
1003
- return t;
1004
- }
1005
- function qt(e, t) {
1006
- let n = e.indexOf("xlink:") === -1 ? "" : ' xmlns:xlink="http://www.w3.org/1999/xlink"';
1007
- for (const i in t)
1008
- n += " " + i + '="' + t[i] + '"';
1009
- return '<svg xmlns="http://www.w3.org/2000/svg"' + n + ">" + e + "</svg>";
1010
- }
1011
- function Qt(e) {
1012
- return e.replace(/"/g, "'").replace(/%/g, "%25").replace(/#/g, "%23").replace(/</g, "%3C").replace(/>/g, "%3E").replace(/\s+/g, " ");
1013
- }
1014
- function Ut(e) {
1015
- return "data:image/svg+xml," + Qt(e);
1016
- }
1017
- function Wt(e) {
1018
- return 'url("' + Ut(e) + '")';
1019
- }
1020
- const Se = {
1021
- ...Ne,
1022
- inline: !1
1023
- }, Kt = {
1024
- xmlns: "http://www.w3.org/2000/svg",
1025
- "xmlns:xlink": "http://www.w3.org/1999/xlink",
1026
- "aria-hidden": !0,
1027
- role: "img"
1028
- }, Gt = {
1029
- display: "inline-block"
1030
- }, oe = {
1031
- backgroundColor: "currentColor"
1032
- }, We = {
1033
- backgroundColor: "transparent"
1034
- }, Ce = {
1035
- Image: "var(--svg)",
1036
- Repeat: "no-repeat",
1037
- Size: "100% 100%"
1038
- }, je = {
1039
- webkitMask: oe,
1040
- mask: oe,
1041
- background: We
1042
- };
1043
- for (const e in je) {
1044
- const t = je[e];
1045
- for (const n in Ce)
1046
- t[e + n] = Ce[n];
1047
- }
1048
- const D = {};
1049
- ["horizontal", "vertical"].forEach((e) => {
1050
- const t = e.slice(0, 1) + "Flip";
1051
- D[e + "-flip"] = t, D[e.slice(0, 1) + "-flip"] = t, D[e + "Flip"] = t;
1052
- });
1053
- function _e(e) {
1054
- return e + (e.match(/^[-0-9.]+$/) ? "px" : "");
1055
- }
1056
- const Te = (e, t) => {
1057
- const n = Dt(Se, t), i = { ...Kt }, o = t.mode || "svg", r = {}, s = t.style, c = typeof s == "object" && !(s instanceof Array) ? s : {};
1058
- for (let d in t) {
1059
- const g = t[d];
1060
- if (g !== void 0)
1061
- switch (d) {
1062
- case "icon":
1063
- case "style":
1064
- case "onLoad":
1065
- case "mode":
1066
- break;
1067
- case "inline":
1068
- case "hFlip":
1069
- case "vFlip":
1070
- n[d] = g === !0 || g === "true" || g === 1;
1071
- break;
1072
- case "flip":
1073
- typeof g == "string" && Ht(n, g);
1074
- break;
1075
- case "color":
1076
- r.color = g;
1077
- break;
1078
- case "rotate":
1079
- typeof g == "string" ? n[d] = Rt(g) : typeof g == "number" && (n[d] = g);
1080
- break;
1081
- case "ariaHidden":
1082
- case "aria-hidden":
1083
- g !== !0 && g !== "true" && delete i["aria-hidden"];
1084
- break;
1085
- default: {
1086
- const I = D[d];
1087
- I ? (g === !0 || g === "true" || g === 1) && (n[I] = !0) : Se[d] === void 0 && (i[d] = g);
1088
- }
1089
- }
1090
- }
1091
- const l = ut(e, n), a = l.attributes;
1092
- if (n.inline && (r.verticalAlign = "-0.125em"), o === "svg") {
1093
- i.style = {
1094
- ...r,
1095
- ...c
1096
- }, Object.assign(i, a);
1097
- let d = 0, g = t.id;
1098
- return typeof g == "string" && (g = g.replace(/-/g, "_")), i.innerHTML = pt(l.body, g ? () => g + "ID" + d++ : "iconifyVue"), de("svg", i);
1099
- }
1100
- const { body: u, width: m, height: h } = e, p = o === "mask" || (o === "bg" ? !1 : u.indexOf("currentColor") !== -1), f = qt(u, {
1101
- ...a,
1102
- width: m + "",
1103
- height: h + ""
1104
- });
1105
- return i.style = {
1106
- ...r,
1107
- "--svg": Wt(f),
1108
- width: _e(a.width),
1109
- height: _e(a.height),
1110
- ...Gt,
1111
- ...p ? oe : We,
1112
- ...c
1113
- }, de("span", i);
1114
- };
1115
- $e(!0);
1116
- gt("", xt);
1117
- if (typeof document < "u" && typeof window < "u") {
1118
- Ue();
1119
- const e = window;
1120
- if (e.IconifyPreload !== void 0) {
1121
- const t = e.IconifyPreload, n = "Invalid IconifyPreload syntax.";
1122
- typeof t == "object" && t !== null && (t instanceof Array ? t : [t]).forEach((i) => {
1123
- try {
1124
- // Check if item is an object and not null/array
1125
- (typeof i != "object" || i === null || i instanceof Array || // Check for 'icons' and 'prefix'
1126
- typeof i.icons != "object" || typeof i.prefix != "string" || // Add icon set
1127
- !st(i)) && console.error(n);
1128
- } catch {
1129
- console.error(n);
1130
- }
1131
- });
1132
- }
1133
- if (e.IconifyProviders !== void 0) {
1134
- const t = e.IconifyProviders;
1135
- if (typeof t == "object" && t !== null)
1136
- for (let n in t) {
1137
- const i = "IconifyProviders[" + n + "] is invalid.";
1138
- try {
1139
- const o = t[n];
1140
- if (typeof o != "object" || !o || o.resources === void 0)
1141
- continue;
1142
- mt(n, o) || console.error(i);
1143
- } catch {
1144
- console.error(i);
1145
- }
1146
- }
1147
- }
1148
- }
1149
- const Jt = {
1150
- ...q,
1151
- body: ""
1152
- }, Fe = ie({
1153
- // Do not inherit other attributes: it is handled by render()
1154
- inheritAttrs: !1,
1155
- // Set initial data
1156
- data() {
1157
- return {
1158
- // Mounted status
1159
- iconMounted: !1,
1160
- // Callback counter to trigger re-render
1161
- counter: 0
1162
- };
1163
- },
1164
- mounted() {
1165
- this._name = "", this._loadingIcon = null, this.iconMounted = !0;
1166
- },
1167
- unmounted() {
1168
- this.abortLoading();
1169
- },
1170
- methods: {
1171
- abortLoading() {
1172
- this._loadingIcon && (this._loadingIcon.abort(), this._loadingIcon = null);
1173
- },
1174
- // Get data for icon to render or null
1175
- getIcon(e, t) {
1176
- if (typeof e == "object" && e !== null && typeof e.body == "string")
1177
- return this._name = "", this.abortLoading(), {
1178
- data: e
1179
- };
1180
- let n;
1181
- if (typeof e != "string" || (n = R(e, !1, !0)) === null)
1182
- return this.abortLoading(), null;
1183
- const i = it(n);
1184
- if (!i)
1185
- return (!this._loadingIcon || this._loadingIcon.name !== e) && (this.abortLoading(), this._name = "", i !== null && (this._loadingIcon = {
1186
- name: e,
1187
- abort: Bt([n], () => {
1188
- this.counter++;
1189
- })
1190
- })), null;
1191
- this.abortLoading(), this._name !== e && (this._name = e, t && t(e));
1192
- const o = ["iconify"];
1193
- return n.prefix !== "" && o.push("iconify--" + n.prefix), n.provider !== "" && o.push("iconify--" + n.provider), { data: i, classes: o };
1194
- }
1195
- },
1196
- // Render icon
1197
- render() {
1198
- this.counter;
1199
- const e = this.$attrs, t = this.iconMounted ? this.getIcon(e.icon, e.onLoad) : null;
1200
- if (!t)
1201
- return Te(Jt, e);
1202
- let n = e;
1203
- return t.classes && (n = {
1204
- ...e,
1205
- class: (typeof e.class == "string" ? e.class + " " : "") + t.classes.join(" ")
1206
- }), Te({
1207
- ...q,
1208
- ...t.data
1209
- }, n);
1210
- }
1211
- }), Xt = {
16
+ }, Y = { class: "inline-block ik-svg-icon ik-icon line-height-[0] inline-flex justify-center" }, A = {
1212
17
  key: 1,
1213
- class: "basicHeight basicWidth",
18
+ class: "h-[1em] w-[1em]",
1214
19
  "aria-hidden": "true"
1215
- }, Yt = ["xlink:href"], Zt = ["src"], en = {
20
+ }, D = ["xlink:href"], L = ["src"], W = {
1216
21
  key: 1,
1217
- class: "basicHeight basicWidth",
22
+ class: "h-[1em] w-[1em]",
1218
23
  "aria-hidden": "true"
1219
- }, tn = ["xlink:href"], nn = ["src"], on = /* @__PURE__ */ ie({
24
+ }, G = ["xlink:href"], H = ["src"], J = /* @__PURE__ */ F({
1220
25
  name: "IkSvgIcon",
1221
26
  __name: "index",
1222
27
  props: {
@@ -1224,6 +29,7 @@ const Jt = {
1224
29
  flip: {},
1225
30
  rotate: {},
1226
31
  color: {},
32
+ opacity: { default: 0.5 },
1227
33
  size: { default: "" },
1228
34
  bg: { type: Boolean, default: !1 },
1229
35
  showBg: { type: Boolean, default: !1 },
@@ -1232,111 +38,125 @@ const Jt = {
1232
38
  notip: { type: Boolean, default: !1 },
1233
39
  title: {}
1234
40
  },
1235
- setup(e) {
1236
- const t = e, n = P(() => {
1237
- var r;
1238
- return /^http?:\/\//.test(t.name) ? "img" : /i-[^:]+:[^:]+/.test(t.name) ? "unocss" : (r = t.name) != null && r.includes(":") ? "iconify" : "svg";
1239
- }), i = P(() => {
1240
- const r = [];
1241
- if (t.flip)
1242
- switch (t.flip) {
41
+ setup(s) {
42
+ const l = s, i = k(() => {
43
+ var e;
44
+ return /^http?:\/\//.test(l.name) ? "img" : /i-[^:]+:[^:]+/.test(l.name) ? "unocss" : l.name.startsWith("iksig") ? "iksig" : (e = l.name) != null && e.includes(":") ? "iconify" : "svg";
45
+ }), c = k(() => {
46
+ const e = [];
47
+ if (l.flip)
48
+ switch (l.flip) {
1243
49
  case "horizontal":
1244
- r.push("rotateY(180deg)");
50
+ e.push("rotateY(180deg)");
1245
51
  break;
1246
52
  case "vertical":
1247
- r.push("rotateX(180deg)");
53
+ e.push("rotateX(180deg)");
1248
54
  break;
1249
55
  case "both":
1250
- r.push("rotateX(180deg)"), r.push("rotateY(180deg)");
56
+ e.push("rotateX(180deg)"), e.push("rotateY(180deg)");
1251
57
  break;
1252
58
  }
1253
- return t.rotate && r.push(`rotate(${t.rotate % 360}deg)`), {
1254
- ...t.color && { color: t.color },
1255
- ...t.size && {
1256
- fontSize: typeof t.size == "number" ? `${t.size}px` : t.size
1257
- },
1258
- ...r.length && { transform: r.join(" ") },
1259
- padding: t.padding
59
+ return l.rotate && e.push(`rotate(${l.rotate % 360}deg)`), {
60
+ ...l.color && { color: l.color },
61
+ ...l.size && { fontSize: typeof l.size == "number" ? `${l.size}px` : l.size },
62
+ ...e.length && { transform: e.join(" ") },
63
+ padding: l.padding,
64
+ ...l.color && i.value !== "iksig" ? {
65
+ "--ik-color-icon-dark": l.color,
66
+ "--ik-color-icon-light": q.setOpacity(l.color, l.opacity || 0.4)
67
+ } : {}
1260
68
  };
1261
- }), o = P(
1262
- () => document.body.getAttribute("data-theme") === "dark"
1263
- );
1264
- return (r, s) => {
1265
- const c = Ke("el-tooltip");
1266
- return r.notip || !r.title ? (w(), x(
1267
- "i",
1268
- {
1269
- key: 0,
1270
- class: E(["ik-svg-icon ik-icon relative basicHeight basicWidth flex-inline items-center justify-center fill-current leading-[1em] transition", {
1271
- [r.name]: n.value === "unocss",
1272
- "show-bg": r.showBg || r.bg,
1273
- default: r.size === "default",
1274
- small: r.size === "small",
1275
- big: r.size === "big",
1276
- warning: r.warning
1277
- }]),
1278
- style: J(i.value)
1279
- },
1280
- [
1281
- n.value === "iconify" ? (w(), O(V(Fe), {
69
+ });
70
+ return (e, g) => {
71
+ const y = E("el-tooltip");
72
+ return o(), u("span", Y, [
73
+ e.notip || !e.title ? (o(), u(
74
+ "i",
75
+ {
1282
76
  key: 0,
1283
- icon: r.name
1284
- }, null, 8, ["icon"])) : n.value === "svg" ? (w(), x("svg", Xt, [
1285
- S("use", {
1286
- "xlink:href": `#${r.name}`
1287
- }, null, 8, Yt)
1288
- ])) : n.value === "img" ? (w(), x("img", {
1289
- key: 2,
1290
- src: r.name,
1291
- class: "basicHeight basicWidth"
1292
- }, null, 8, Zt)) : _("v-if", !0)
1293
- ],
1294
- 6
1295
- /* CLASS, STYLE */
1296
- )) : (w(), O(c, {
1297
- key: 1,
1298
- effect: o.value ? "dark" : "light",
1299
- content: r.title
1300
- }, {
1301
- default: Ge(() => [
1302
- S(
1303
- "i",
1304
- Je({
1305
- class: ["ik-svg-icon ik-icon relative basicHeight basicWidth flex-inline items-center justify-center fill-current leading-[1em] transition", {
1306
- [r.name]: n.value === "unocss",
1307
- "show-bg": r.showBg || r.bg,
1308
- default: r.size === "default",
1309
- small: r.size === "small",
1310
- big: r.size === "big",
1311
- warning: r.warning
1312
- }],
1313
- style: i.value
1314
- }, r.$attrs),
1315
- [
1316
- n.value === "iconify" ? (w(), O(V(Fe), {
77
+ class: f(["relative h-[1em] w-[1em] flex-inline items-center justify-center fill-current leading-[1em] transition", {
78
+ [e.name]: i.value === "unocss",
79
+ "show-bg": e.showBg || e.bg,
80
+ default: e.size === "default",
81
+ small: e.size === "small",
82
+ big: e.size === "big",
83
+ warning: e.warning
84
+ }]),
85
+ style: h(c.value)
86
+ },
87
+ [
88
+ i.value === "iksig" ? (o(), u(
89
+ "i",
90
+ {
1317
91
  key: 0,
1318
- icon: r.name
1319
- }, null, 8, ["icon"])) : n.value === "svg" ? (w(), x("svg", en, [
1320
- S("use", {
1321
- "xlink:href": `#${r.name}`
1322
- }, null, 8, tn)
1323
- ])) : n.value === "img" ? (w(), x("img", {
1324
- key: 2,
1325
- src: r.name,
1326
- class: "basicHeight basicWidth"
1327
- }, null, 8, nn)) : _("v-if", !0)
1328
- ],
1329
- 16
1330
- /* FULL_PROPS */
1331
- )
1332
- ]),
1333
- _: 1
1334
- /* STABLE */
1335
- }, 8, ["effect", "content"]));
92
+ class: f(`iksig ${e.name}`),
93
+ style: h(c.value)
94
+ },
95
+ null,
96
+ 6
97
+ /* CLASS, STYLE */
98
+ )) : i.value === "svg" ? (o(), u("svg", A, [
99
+ d("use", {
100
+ "xlink:href": `#${e.name}`
101
+ }, null, 8, D)
102
+ ])) : i.value === "img" ? (o(), u("img", {
103
+ key: 2,
104
+ src: e.name,
105
+ class: "h-[1em] w-[1em]"
106
+ }, null, 8, L)) : m("v-if", !0)
107
+ ],
108
+ 6
109
+ /* CLASS, STYLE */
110
+ )) : (o(), C(y, {
111
+ key: 1,
112
+ content: e.title
113
+ }, {
114
+ default: K(() => [
115
+ d(
116
+ "i",
117
+ {
118
+ class: f(["ik-svg-icon ik-icon relative h-[1em] w-[1em] flex-inline items-center justify-center fill-current leading-[1em] transition", {
119
+ [e.name]: i.value === "unocss",
120
+ "show-bg": e.showBg || e.bg,
121
+ default: e.size === "default",
122
+ small: e.size === "small",
123
+ big: e.size === "big",
124
+ warning: e.warning
125
+ }]),
126
+ style: h(c.value)
127
+ },
128
+ [
129
+ i.value === "iksig" ? (o(), u(
130
+ "i",
131
+ {
132
+ key: 0,
133
+ class: f(`iksig ${e.name}`),
134
+ style: h(c.value)
135
+ },
136
+ null,
137
+ 6
138
+ /* CLASS, STYLE */
139
+ )) : i.value === "svg" ? (o(), u("svg", W, [
140
+ d("use", {
141
+ "xlink:href": `#${e.name}`
142
+ }, null, 8, G)
143
+ ])) : i.value === "img" ? (o(), u("img", {
144
+ key: 2,
145
+ src: e.name,
146
+ class: "h-[1em] w-[1em]"
147
+ }, null, 8, H)) : m("v-if", !0)
148
+ ],
149
+ 6
150
+ /* CLASS, STYLE */
151
+ )
152
+ ]),
153
+ _: 1
154
+ /* STABLE */
155
+ }, 8, ["content"]))
156
+ ]);
1336
157
  };
1337
158
  }
1338
- });
1339
- const rn = /* @__PURE__ */ Oe(on, [["__scopeId", "data-v-1957ff53"]]), Ee = Pe(rn), sn = { class: "content" }, cn = { class: "top" }, ln = ["onClick"], an = ["id"], un = ["onClick"], fn = /* @__PURE__ */ ie({
159
+ }), j = N(J), M = { class: "content" }, P = { class: "top" }, Q = ["onClick"], R = ["id"], U = ["onClick"], Z = /* @__PURE__ */ F({
1340
160
  __name: "IKVerticalStepBar",
1341
161
  props: {
1342
162
  // 当前激活的下标
@@ -1364,104 +184,104 @@ const rn = /* @__PURE__ */ Oe(on, [["__scopeId", "data-v-1957ff53"]]), Ee = Pe(r
1364
184
  }
1365
185
  },
1366
186
  emits: ["click", "update:active"],
1367
- setup(e, { emit: t }) {
1368
- const n = e, i = t, o = P(() => Number(
1369
- n.active.indexOf("-") > 0 ? n.active.split("-")[0] : n.active
1370
- )), r = P(() => n.active.indexOf("-") > 0 ? Number(n.active.split("-")[1]) : 0), s = (h) => {
1371
- let p = "", f = h + 1;
1372
- return f < o.value ? p = "before-bg" : f === o.value ? p = "active-bg" : f > o.value && (p = "after-bg"), `${p} index`;
1373
- }, c = (h) => {
1374
- let p = "", f = h + 1;
1375
- return f < o.value ? p = "before-text" : f === o.value ? p = "active-text" : f > o.value && (p = "after-text"), `${p} text`;
1376
- }, l = (h) => {
1377
- let p = "", f = h + 1;
1378
- return f < o.value ? p = "before-style" : f < n.list.length && (p = "after-style"), `${p} bottom`;
1379
- }, a = (h, p) => {
1380
- let f = "", d = h + 1, g = p + 1;
1381
- return d < o.value ? f = "before-text" : d === o.value ? g < r.value ? f = "before-text" : g === r.value ? f = "active-text" : g > r.value && (f = "after-text") : d > o.value && (f = "after-text"), `${f} child-text`;
1382
- }, u = (h, p) => {
1383
- n.needClick && (h[n.propsField.children] || (i("update:active", p + ""), i("click", h)));
1384
- }, m = (h, p) => {
1385
- h.show = !h.show;
1386
- let f = document.getElementById(`children${p}`);
1387
- h.show ? f.style.display = "none" : f.style.display = "block";
187
+ setup(s, { emit: l }) {
188
+ const i = s, c = l, e = k(() => Number(
189
+ i.active.indexOf("-") > 0 ? i.active.split("-")[0] : i.active
190
+ )), g = k(() => i.active.indexOf("-") > 0 ? Number(i.active.split("-")[1]) : 0), y = (a) => {
191
+ let n = "", t = a + 1;
192
+ return t < e.value ? n = "before-bg" : t === e.value ? n = "active-bg" : t > e.value && (n = "after-bg"), `${n} index`;
193
+ }, O = (a) => {
194
+ let n = "", t = a + 1;
195
+ return t < e.value ? n = "before-text" : t === e.value ? n = "active-text" : t > e.value && (n = "after-text"), `${n} text`;
196
+ }, V = (a) => {
197
+ let n = "", t = a + 1;
198
+ return t < e.value ? n = "before-style" : t < i.list.length && (n = "after-style"), `${n} bottom`;
199
+ }, x = (a, n) => {
200
+ let t = "", r = a + 1, p = n + 1;
201
+ return r < e.value ? t = "before-text" : r === e.value ? p < g.value ? t = "before-text" : p === g.value ? t = "active-text" : p > g.value && (t = "after-text") : r > e.value && (t = "after-text"), `${t} child-text`;
202
+ }, $ = (a, n) => {
203
+ i.needClick && (a[i.propsField.children] || (c("update:active", n + ""), c("click", a)));
204
+ }, _ = (a, n) => {
205
+ a.show = !a.show;
206
+ let t = document.getElementById(`children${n}`);
207
+ a.show ? t.style.display = "none" : t.style.display = "block";
1388
208
  };
1389
- return (h, p) => (w(), x("div", sn, [
1390
- (w(!0), x(
1391
- he,
209
+ return (a, n) => (o(), u("div", M, [
210
+ (o(!0), u(
211
+ B,
1392
212
  null,
1393
- pe(e.list, (f, d) => {
1394
- var g, I;
1395
- return w(), x("div", {
213
+ I(s.list, (t, r) => {
214
+ var p, z;
215
+ return o(), u("div", {
1396
216
  class: "line-block",
1397
- key: d
217
+ key: r
1398
218
  }, [
1399
- S("div", cn, [
1400
- S(
219
+ d("div", P, [
220
+ d(
1401
221
  "div",
1402
222
  {
1403
- class: E(s(d))
223
+ class: f(y(r))
1404
224
  },
1405
- W(d + 1),
225
+ w(r + 1),
1406
226
  3
1407
227
  /* TEXT, CLASS */
1408
228
  ),
1409
- S("div", {
1410
- class: E(c(d)),
1411
- style: J(e.needClick ? "cursor: pointer;" : ""),
1412
- onClick: (b) => u(f, d + 1)
229
+ d("div", {
230
+ class: f(O(r)),
231
+ style: h(s.needClick ? "cursor: pointer;" : ""),
232
+ onClick: (v) => $(t, r + 1)
1413
233
  }, [
1414
- Xe(
1415
- W(f[e.propsField.name]) + " ",
234
+ T(
235
+ w(t[s.propsField.name]) + " ",
1416
236
  1
1417
237
  /* TEXT */
1418
238
  ),
1419
- _(` <i\r
239
+ m(` <i\r
1420
240
  v-if="item[propsField.children]?.length && !item.show"\r
1421
241
  class="ikapprove icon-a-putongjiantouzhankai"\r
1422
242
  @click="changeShow(item, index)"\r
1423
243
  ></i> `),
1424
- (g = f[e.propsField.children]) != null && g.length && !f.show ? (w(), O(V(Ee), {
244
+ (p = t[s.propsField.children]) != null && p.length && !t.show ? (o(), C(S(j), {
1425
245
  key: 0,
1426
246
  class: "ikapprove",
1427
- onClick: (b) => m(f, d),
247
+ onClick: (v) => _(t, r),
1428
248
  name: "iksvg_zhankai"
1429
- }, null, 8, ["onClick"])) : _("v-if", !0),
1430
- _(` <i\r
249
+ }, null, 8, ["onClick"])) : m("v-if", !0),
250
+ m(` <i\r
1431
251
  v-if="item[propsField.children]?.length && item.show"\r
1432
252
  @click="changeShow(item, index)"\r
1433
253
  class="ikapprove icon-a-putongjiantoushouqi"\r
1434
254
  ></i> `),
1435
- (I = f[e.propsField.children]) != null && I.length && f.show ? (w(), O(V(Ee), {
255
+ (z = t[s.propsField.children]) != null && z.length && t.show ? (o(), C(S(j), {
1436
256
  key: 1,
1437
257
  class: "ikapprove",
1438
- onClick: (b) => m(f, d),
258
+ onClick: (v) => _(t, r),
1439
259
  name: "iksvg_shouqi"
1440
- }, null, 8, ["onClick"])) : _("v-if", !0)
1441
- ], 14, ln)
260
+ }, null, 8, ["onClick"])) : m("v-if", !0)
261
+ ], 14, Q)
1442
262
  ]),
1443
- S(
263
+ d(
1444
264
  "ul",
1445
265
  {
1446
- class: E(l(d))
266
+ class: f(V(r))
1447
267
  },
1448
268
  [
1449
- S("div", {
1450
- id: `children${d}`
269
+ d("div", {
270
+ id: `children${r}`
1451
271
  }, [
1452
- (w(!0), x(
1453
- he,
272
+ (o(!0), u(
273
+ B,
1454
274
  null,
1455
- pe(f[e.propsField.children], (b, v) => (w(), x("li", {
1456
- class: E(a(d, v)),
1457
- style: J(e.needClick ? "cursor: pointer;" : ""),
1458
- key: v,
1459
- onClick: (fe) => u(b, d + 1 + "-" + (v + 1))
1460
- }, W(b.name), 15, un))),
275
+ I(t[s.propsField.children], (v, b) => (o(), u("li", {
276
+ class: f(x(r, b)),
277
+ style: h(s.needClick ? "cursor: pointer;" : ""),
278
+ key: b,
279
+ onClick: (te) => $(v, r + 1 + "-" + (b + 1))
280
+ }, w(v.name), 15, U))),
1461
281
  128
1462
282
  /* KEYED_FRAGMENT */
1463
283
  ))
1464
- ], 8, an)
284
+ ], 8, R)
1465
285
  ],
1466
286
  2
1467
287
  /* CLASS */
@@ -1474,8 +294,8 @@ const rn = /* @__PURE__ */ Oe(on, [["__scopeId", "data-v-1957ff53"]]), Ee = Pe(r
1474
294
  ]));
1475
295
  }
1476
296
  });
1477
- const dn = /* @__PURE__ */ Oe(fn, [["__scopeId", "data-v-240cff4f"]]), pn = Pe(dn);
297
+ const ee = /* @__PURE__ */ X(Z, [["__scopeId", "data-v-240cff4f"]]), ne = N(ee);
1478
298
  export {
1479
- pn as IKVerticalStepBar,
1480
- pn as default
299
+ ne as IKVerticalStepBar,
300
+ ne as default
1481
301
  };