@gx-design-vue/context 0.0.1 → 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.
package/dist/context.js CHANGED
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * Gx Design Pro
3
- * Version: 0.0.0
3
+ * Version: 0.0.2
4
4
  * Author: gx12358
5
5
  * Copyright (C) 2024 gx12358
6
6
  * License: MIT License
@@ -9,1912 +9,37 @@
9
9
  * Homepage:
10
10
  * Contact: gx12358@gmail.com
11
11
  */
12
- import { inject as ft, computed as d, defineComponent as je, createVNode as fe, mergeProps as he, provide as Qt, toRef as Zt, watch as W, isRef as Kt, ref as He } from "vue";
13
- import { Form as Jt, theme as Se, ConfigProvider as ht, useCacheToken as er } from "ant-design-vue";
14
- import { useColorMode as tr } from "@vueuse/core";
15
- /*!
16
- * Gx Design Pro
17
- * Version: 0.2.0-beta.79
18
- * Author: gx12358
19
- * Copyright (C) 2024 gx12358
20
- * License: MIT License
21
- * Description: Gx Design Pro Utils
22
- * Date Created: 2025-08-17
23
- * Homepage:
24
- * Contact: gx12358@gmail.com
25
- */
26
- const Ie = ({ suffixCls: e, customizePrefixCls: t, isPor: r, className: n }) => {
27
- const o = n || (r ? "gx-pro" : "gx");
28
- return t || (e ? `${o}-${e}` : o);
29
- };
30
- function rr() {
31
- const e = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split("");
32
- return {
33
- uuid(t, r) {
34
- const n = e, o = [], a = r || n.length;
35
- let i, s;
36
- if (t)
37
- for (i = 0; i < t; i += 1)
38
- o[i] = n[Number.parseInt(String(Math.random() * a))];
39
- else
40
- for (o[8] = "-", o[13] = "-", o[18] = "-", o[23] = "-", o[14] = "4", i = 0; i < 36; i += 1)
41
- o[i] || (s = Math.random() * 16, o[i] = n[i === 19 ? s && 3 || 8 : s]);
42
- return o.join("");
43
- },
44
- uuidFast() {
45
- const t = e, r = Array.from({ length: 36 });
46
- let n = 0, o, a;
47
- for (a = 0; a < 36; a += 1)
48
- a === 8 || a === 13 || a === 18 || a === 23 ? r[a] = "-" : a === 14 ? r[a] = "4" : (n <= 2 && (n = 33554432 + Math.random() * 16777216 || 0), o = n && 15, n = n > 4, r[a] = t[a === 19 ? o && 3 || 8 : o]);
49
- return r.join("");
50
- },
51
- uuidString() {
52
- return this.uuidFast().replace(new RegExp("-", "g"), "");
53
- },
54
- uuidCompact() {
55
- return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (t) => {
56
- const r = Math.random() * 16 || 0;
57
- return (t === "x" ? r : r && 3 || 8).toString(16);
58
- });
59
- }
60
- };
61
- }
62
- typeof process < "u" && process.versions != null && process.versions.node != null;
63
- const P = (...e) => {
64
- const t = {}, r = e.length;
65
- let n, o = 0;
66
- for (; o < r; o += 1)
67
- for (n in e[o])
68
- Object.prototype.hasOwnProperty.call(e[o], n) && (typeof t[n] == "object" && typeof e[o][n] == "object" && t[n] !== void 0 && t[n] !== null && !Array.isArray(t[n]) && !Array.isArray(e[o][n]) ? t[n] = {
69
- ...t[n],
70
- ...e[o][n]
71
- } : t[n] = e[o][n]);
72
- return t;
73
- };
74
- function p(e, t) {
75
- nr(e) && (e = "100%");
76
- var r = or(e);
77
- return e = t === 360 ? e : Math.min(t, Math.max(0, parseFloat(e))), r && (e = parseInt(String(e * t), 10) / 100), Math.abs(e - t) < 1e-6 ? 1 : (t === 360 ? e = (e < 0 ? e % t + t : e % t) / parseFloat(String(t)) : e = e % t / parseFloat(String(t)), e);
78
- }
79
- function Q(e) {
80
- return Math.min(1, Math.max(0, e));
81
- }
82
- function nr(e) {
83
- return typeof e == "string" && e.indexOf(".") !== -1 && parseFloat(e) === 1;
84
- }
85
- function or(e) {
86
- return typeof e == "string" && e.indexOf("%") !== -1;
87
- }
88
- function dt(e) {
89
- return e = parseFloat(e), (isNaN(e) || e < 0 || e > 1) && (e = 1), e;
90
- }
91
- function Z(e) {
92
- return e <= 1 ? "".concat(Number(e) * 100, "%") : e;
93
- }
94
- function H(e) {
95
- return e.length === 1 ? "0" + e : String(e);
96
- }
97
- function ar(e, t, r) {
98
- return {
99
- r: p(e, 255) * 255,
100
- g: p(t, 255) * 255,
101
- b: p(r, 255) * 255
102
- };
103
- }
104
- function Oe(e, t, r) {
105
- e = p(e, 255), t = p(t, 255), r = p(r, 255);
106
- var n = Math.max(e, t, r), o = Math.min(e, t, r), a = 0, i = 0, s = (n + o) / 2;
107
- if (n === o)
108
- i = 0, a = 0;
109
- else {
110
- var u = n - o;
111
- switch (i = s > 0.5 ? u / (2 - n - o) : u / (n + o), n) {
112
- case e:
113
- a = (t - r) / u + (t < r ? 6 : 0);
114
- break;
115
- case t:
116
- a = (r - e) / u + 2;
117
- break;
118
- case r:
119
- a = (e - t) / u + 4;
120
- break;
121
- }
122
- a /= 6;
123
- }
124
- return { h: a, s: i, l: s };
125
- }
126
- function oe(e, t, r) {
127
- return r < 0 && (r += 1), r > 1 && (r -= 1), r < 1 / 6 ? e + (t - e) * (6 * r) : r < 1 / 2 ? t : r < 2 / 3 ? e + (t - e) * (2 / 3 - r) * 6 : e;
128
- }
129
- function ir(e, t, r) {
130
- var n, o, a;
131
- if (e = p(e, 360), t = p(t, 100), r = p(r, 100), t === 0)
132
- o = r, a = r, n = r;
133
- else {
134
- var i = r < 0.5 ? r * (1 + t) : r + t - r * t, s = 2 * r - i;
135
- n = oe(s, i, e + 1 / 3), o = oe(s, i, e), a = oe(s, i, e - 1 / 3);
136
- }
137
- return { r: n * 255, g: o * 255, b: a * 255 };
138
- }
139
- function Fe(e, t, r) {
140
- e = p(e, 255), t = p(t, 255), r = p(r, 255);
141
- var n = Math.max(e, t, r), o = Math.min(e, t, r), a = 0, i = n, s = n - o, u = n === 0 ? 0 : s / n;
142
- if (n === o)
143
- a = 0;
144
- else {
145
- switch (n) {
146
- case e:
147
- a = (t - r) / s + (t < r ? 6 : 0);
148
- break;
149
- case t:
150
- a = (r - e) / s + 2;
151
- break;
152
- case r:
153
- a = (e - t) / s + 4;
154
- break;
155
- }
156
- a /= 6;
157
- }
158
- return { h: a, s: u, v: i };
159
- }
160
- function sr(e, t, r) {
161
- e = p(e, 360) * 6, t = p(t, 100), r = p(r, 100);
162
- var n = Math.floor(e), o = e - n, a = r * (1 - t), i = r * (1 - o * t), s = r * (1 - (1 - o) * t), u = n % 6, c = [r, i, a, a, s, r][u], h = [s, r, r, i, a, a][u], w = [a, a, s, r, r, i][u];
163
- return { r: c * 255, g: h * 255, b: w * 255 };
164
- }
165
- function Re(e, t, r, n) {
166
- var o = [
167
- H(Math.round(e).toString(16)),
168
- H(Math.round(t).toString(16)),
169
- H(Math.round(r).toString(16))
170
- ];
171
- return n && o[0].startsWith(o[0].charAt(1)) && o[1].startsWith(o[1].charAt(1)) && o[2].startsWith(o[2].charAt(1)) ? o[0].charAt(0) + o[1].charAt(0) + o[2].charAt(0) : o.join("");
172
- }
173
- function ur(e, t, r, n, o) {
174
- var a = [
175
- H(Math.round(e).toString(16)),
176
- H(Math.round(t).toString(16)),
177
- H(Math.round(r).toString(16)),
178
- H(cr(n))
179
- ];
180
- return o && a[0].startsWith(a[0].charAt(1)) && a[1].startsWith(a[1].charAt(1)) && a[2].startsWith(a[2].charAt(1)) && a[3].startsWith(a[3].charAt(1)) ? a[0].charAt(0) + a[1].charAt(0) + a[2].charAt(0) + a[3].charAt(0) : a.join("");
181
- }
182
- function cr(e) {
183
- return Math.round(parseFloat(e) * 255).toString(16);
184
- }
185
- function Ee(e) {
186
- return v(e) / 255;
187
- }
188
- function v(e) {
189
- return parseInt(e, 16);
190
- }
191
- function lr(e) {
192
- return {
193
- r: e >> 16,
194
- g: (e & 65280) >> 8,
195
- b: e & 255
196
- };
197
- }
198
- var de = {
199
- aliceblue: "#f0f8ff",
200
- antiquewhite: "#faebd7",
201
- aqua: "#00ffff",
202
- aquamarine: "#7fffd4",
203
- azure: "#f0ffff",
204
- beige: "#f5f5dc",
205
- bisque: "#ffe4c4",
206
- black: "#000000",
207
- blanchedalmond: "#ffebcd",
208
- blue: "#0000ff",
209
- blueviolet: "#8a2be2",
210
- brown: "#a52a2a",
211
- burlywood: "#deb887",
212
- cadetblue: "#5f9ea0",
213
- chartreuse: "#7fff00",
214
- chocolate: "#d2691e",
215
- coral: "#ff7f50",
216
- cornflowerblue: "#6495ed",
217
- cornsilk: "#fff8dc",
218
- crimson: "#dc143c",
219
- cyan: "#00ffff",
220
- darkblue: "#00008b",
221
- darkcyan: "#008b8b",
222
- darkgoldenrod: "#b8860b",
223
- darkgray: "#a9a9a9",
224
- darkgreen: "#006400",
225
- darkgrey: "#a9a9a9",
226
- darkkhaki: "#bdb76b",
227
- darkmagenta: "#8b008b",
228
- darkolivegreen: "#556b2f",
229
- darkorange: "#ff8c00",
230
- darkorchid: "#9932cc",
231
- darkred: "#8b0000",
232
- darksalmon: "#e9967a",
233
- darkseagreen: "#8fbc8f",
234
- darkslateblue: "#483d8b",
235
- darkslategray: "#2f4f4f",
236
- darkslategrey: "#2f4f4f",
237
- darkturquoise: "#00ced1",
238
- darkviolet: "#9400d3",
239
- deeppink: "#ff1493",
240
- deepskyblue: "#00bfff",
241
- dimgray: "#696969",
242
- dimgrey: "#696969",
243
- dodgerblue: "#1e90ff",
244
- firebrick: "#b22222",
245
- floralwhite: "#fffaf0",
246
- forestgreen: "#228b22",
247
- fuchsia: "#ff00ff",
248
- gainsboro: "#dcdcdc",
249
- ghostwhite: "#f8f8ff",
250
- goldenrod: "#daa520",
251
- gold: "#ffd700",
252
- gray: "#808080",
253
- green: "#008000",
254
- greenyellow: "#adff2f",
255
- grey: "#808080",
256
- honeydew: "#f0fff0",
257
- hotpink: "#ff69b4",
258
- indianred: "#cd5c5c",
259
- indigo: "#4b0082",
260
- ivory: "#fffff0",
261
- khaki: "#f0e68c",
262
- lavenderblush: "#fff0f5",
263
- lavender: "#e6e6fa",
264
- lawngreen: "#7cfc00",
265
- lemonchiffon: "#fffacd",
266
- lightblue: "#add8e6",
267
- lightcoral: "#f08080",
268
- lightcyan: "#e0ffff",
269
- lightgoldenrodyellow: "#fafad2",
270
- lightgray: "#d3d3d3",
271
- lightgreen: "#90ee90",
272
- lightgrey: "#d3d3d3",
273
- lightpink: "#ffb6c1",
274
- lightsalmon: "#ffa07a",
275
- lightseagreen: "#20b2aa",
276
- lightskyblue: "#87cefa",
277
- lightslategray: "#778899",
278
- lightslategrey: "#778899",
279
- lightsteelblue: "#b0c4de",
280
- lightyellow: "#ffffe0",
281
- lime: "#00ff00",
282
- limegreen: "#32cd32",
283
- linen: "#faf0e6",
284
- magenta: "#ff00ff",
285
- maroon: "#800000",
286
- mediumaquamarine: "#66cdaa",
287
- mediumblue: "#0000cd",
288
- mediumorchid: "#ba55d3",
289
- mediumpurple: "#9370db",
290
- mediumseagreen: "#3cb371",
291
- mediumslateblue: "#7b68ee",
292
- mediumspringgreen: "#00fa9a",
293
- mediumturquoise: "#48d1cc",
294
- mediumvioletred: "#c71585",
295
- midnightblue: "#191970",
296
- mintcream: "#f5fffa",
297
- mistyrose: "#ffe4e1",
298
- moccasin: "#ffe4b5",
299
- navajowhite: "#ffdead",
300
- navy: "#000080",
301
- oldlace: "#fdf5e6",
302
- olive: "#808000",
303
- olivedrab: "#6b8e23",
304
- orange: "#ffa500",
305
- orangered: "#ff4500",
306
- orchid: "#da70d6",
307
- palegoldenrod: "#eee8aa",
308
- palegreen: "#98fb98",
309
- paleturquoise: "#afeeee",
310
- palevioletred: "#db7093",
311
- papayawhip: "#ffefd5",
312
- peachpuff: "#ffdab9",
313
- peru: "#cd853f",
314
- pink: "#ffc0cb",
315
- plum: "#dda0dd",
316
- powderblue: "#b0e0e6",
317
- purple: "#800080",
318
- rebeccapurple: "#663399",
319
- red: "#ff0000",
320
- rosybrown: "#bc8f8f",
321
- royalblue: "#4169e1",
322
- saddlebrown: "#8b4513",
323
- salmon: "#fa8072",
324
- sandybrown: "#f4a460",
325
- seagreen: "#2e8b57",
326
- seashell: "#fff5ee",
327
- sienna: "#a0522d",
328
- silver: "#c0c0c0",
329
- skyblue: "#87ceeb",
330
- slateblue: "#6a5acd",
331
- slategray: "#708090",
332
- slategrey: "#708090",
333
- snow: "#fffafa",
334
- springgreen: "#00ff7f",
335
- steelblue: "#4682b4",
336
- tan: "#d2b48c",
337
- teal: "#008080",
338
- thistle: "#d8bfd8",
339
- tomato: "#ff6347",
340
- turquoise: "#40e0d0",
341
- violet: "#ee82ee",
342
- wheat: "#f5deb3",
343
- white: "#ffffff",
344
- whitesmoke: "#f5f5f5",
345
- yellow: "#ffff00",
346
- yellowgreen: "#9acd32"
347
- };
348
- function fr(e) {
349
- var t = { r: 0, g: 0, b: 0 }, r = 1, n = null, o = null, a = null, i = !1, s = !1;
350
- return typeof e == "string" && (e = pr(e)), typeof e == "object" && (A(e.r) && A(e.g) && A(e.b) ? (t = ar(e.r, e.g, e.b), i = !0, s = String(e.r).substr(-1) === "%" ? "prgb" : "rgb") : A(e.h) && A(e.s) && A(e.v) ? (n = Z(e.s), o = Z(e.v), t = sr(e.h, n, o), i = !0, s = "hsv") : A(e.h) && A(e.s) && A(e.l) && (n = Z(e.s), a = Z(e.l), t = ir(e.h, n, a), i = !0, s = "hsl"), Object.prototype.hasOwnProperty.call(e, "a") && (r = e.a)), r = dt(r), {
351
- ok: i,
352
- format: e.format || s,
353
- r: Math.min(255, Math.max(t.r, 0)),
354
- g: Math.min(255, Math.max(t.g, 0)),
355
- b: Math.min(255, Math.max(t.b, 0)),
356
- a: r
357
- };
358
- }
359
- var hr = "[-\\+]?\\d+%?", dr = "[-\\+]?\\d*\\.\\d+%?", k = "(?:".concat(dr, ")|(?:").concat(hr, ")"), ae = "[\\s|\\(]+(".concat(k, ")[,|\\s]+(").concat(k, ")[,|\\s]+(").concat(k, ")\\s*\\)?"), ie = "[\\s|\\(]+(".concat(k, ")[,|\\s]+(").concat(k, ")[,|\\s]+(").concat(k, ")[,|\\s]+(").concat(k, ")\\s*\\)?"), b = {
360
- CSS_UNIT: new RegExp(k),
361
- rgb: new RegExp("rgb" + ae),
362
- rgba: new RegExp("rgba" + ie),
363
- hsl: new RegExp("hsl" + ae),
364
- hsla: new RegExp("hsla" + ie),
365
- hsv: new RegExp("hsv" + ae),
366
- hsva: new RegExp("hsva" + ie),
367
- hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
368
- hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
369
- hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
370
- hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/
371
- };
372
- function pr(e) {
373
- if (e = e.trim().toLowerCase(), e.length === 0)
374
- return !1;
375
- var t = !1;
376
- if (de[e])
377
- e = de[e], t = !0;
378
- else if (e === "transparent")
379
- return { r: 0, g: 0, b: 0, a: 0, format: "name" };
380
- var r = b.rgb.exec(e);
381
- return r ? { r: r[1], g: r[2], b: r[3] } : (r = b.rgba.exec(e), r ? { r: r[1], g: r[2], b: r[3], a: r[4] } : (r = b.hsl.exec(e), r ? { h: r[1], s: r[2], l: r[3] } : (r = b.hsla.exec(e), r ? { h: r[1], s: r[2], l: r[3], a: r[4] } : (r = b.hsv.exec(e), r ? { h: r[1], s: r[2], v: r[3] } : (r = b.hsva.exec(e), r ? { h: r[1], s: r[2], v: r[3], a: r[4] } : (r = b.hex8.exec(e), r ? {
382
- r: v(r[1]),
383
- g: v(r[2]),
384
- b: v(r[3]),
385
- a: Ee(r[4]),
386
- format: t ? "name" : "hex8"
387
- } : (r = b.hex6.exec(e), r ? {
388
- r: v(r[1]),
389
- g: v(r[2]),
390
- b: v(r[3]),
391
- format: t ? "name" : "hex"
392
- } : (r = b.hex4.exec(e), r ? {
393
- r: v(r[1] + r[1]),
394
- g: v(r[2] + r[2]),
395
- b: v(r[3] + r[3]),
396
- a: Ee(r[4] + r[4]),
397
- format: t ? "name" : "hex8"
398
- } : (r = b.hex3.exec(e), r ? {
399
- r: v(r[1] + r[1]),
400
- g: v(r[2] + r[2]),
401
- b: v(r[3] + r[3]),
402
- format: t ? "name" : "hex"
403
- } : !1)))))))));
404
- }
405
- function A(e) {
406
- return !!b.CSS_UNIT.exec(String(e));
407
- }
408
- var gr = (
409
- /** @class */
410
- (function() {
411
- function e(t, r) {
412
- t === void 0 && (t = ""), r === void 0 && (r = {});
413
- var n;
414
- if (t instanceof e)
415
- return t;
416
- typeof t == "number" && (t = lr(t)), this.originalInput = t;
417
- var o = fr(t);
418
- this.originalInput = t, this.r = o.r, this.g = o.g, this.b = o.b, this.a = o.a, this.roundA = Math.round(100 * this.a) / 100, this.format = (n = r.format) !== null && n !== void 0 ? n : o.format, this.gradientType = r.gradientType, this.r < 1 && (this.r = Math.round(this.r)), this.g < 1 && (this.g = Math.round(this.g)), this.b < 1 && (this.b = Math.round(this.b)), this.isValid = o.ok;
419
- }
420
- return e.prototype.isDark = function() {
421
- return this.getBrightness() < 128;
422
- }, e.prototype.isLight = function() {
423
- return !this.isDark();
424
- }, e.prototype.getBrightness = function() {
425
- var t = this.toRgb();
426
- return (t.r * 299 + t.g * 587 + t.b * 114) / 1e3;
427
- }, e.prototype.getLuminance = function() {
428
- var t = this.toRgb(), r, n, o, a = t.r / 255, i = t.g / 255, s = t.b / 255;
429
- return a <= 0.03928 ? r = a / 12.92 : r = Math.pow((a + 0.055) / 1.055, 2.4), i <= 0.03928 ? n = i / 12.92 : n = Math.pow((i + 0.055) / 1.055, 2.4), s <= 0.03928 ? o = s / 12.92 : o = Math.pow((s + 0.055) / 1.055, 2.4), 0.2126 * r + 0.7152 * n + 0.0722 * o;
430
- }, e.prototype.getAlpha = function() {
431
- return this.a;
432
- }, e.prototype.setAlpha = function(t) {
433
- return this.a = dt(t), this.roundA = Math.round(100 * this.a) / 100, this;
434
- }, e.prototype.isMonochrome = function() {
435
- var t = this.toHsl().s;
436
- return t === 0;
437
- }, e.prototype.toHsv = function() {
438
- var t = Fe(this.r, this.g, this.b);
439
- return { h: t.h * 360, s: t.s, v: t.v, a: this.a };
440
- }, e.prototype.toHsvString = function() {
441
- var t = Fe(this.r, this.g, this.b), r = Math.round(t.h * 360), n = Math.round(t.s * 100), o = Math.round(t.v * 100);
442
- return this.a === 1 ? "hsv(".concat(r, ", ").concat(n, "%, ").concat(o, "%)") : "hsva(".concat(r, ", ").concat(n, "%, ").concat(o, "%, ").concat(this.roundA, ")");
443
- }, e.prototype.toHsl = function() {
444
- var t = Oe(this.r, this.g, this.b);
445
- return { h: t.h * 360, s: t.s, l: t.l, a: this.a };
446
- }, e.prototype.toHslString = function() {
447
- var t = Oe(this.r, this.g, this.b), r = Math.round(t.h * 360), n = Math.round(t.s * 100), o = Math.round(t.l * 100);
448
- return this.a === 1 ? "hsl(".concat(r, ", ").concat(n, "%, ").concat(o, "%)") : "hsla(".concat(r, ", ").concat(n, "%, ").concat(o, "%, ").concat(this.roundA, ")");
449
- }, e.prototype.toHex = function(t) {
450
- return t === void 0 && (t = !1), Re(this.r, this.g, this.b, t);
451
- }, e.prototype.toHexString = function(t) {
452
- return t === void 0 && (t = !1), "#" + this.toHex(t);
453
- }, e.prototype.toHex8 = function(t) {
454
- return t === void 0 && (t = !1), ur(this.r, this.g, this.b, this.a, t);
455
- }, e.prototype.toHex8String = function(t) {
456
- return t === void 0 && (t = !1), "#" + this.toHex8(t);
457
- }, e.prototype.toHexShortString = function(t) {
458
- return t === void 0 && (t = !1), this.a === 1 ? this.toHexString(t) : this.toHex8String(t);
459
- }, e.prototype.toRgb = function() {
460
- return {
461
- r: Math.round(this.r),
462
- g: Math.round(this.g),
463
- b: Math.round(this.b),
464
- a: this.a
465
- };
466
- }, e.prototype.toRgbString = function() {
467
- var t = Math.round(this.r), r = Math.round(this.g), n = Math.round(this.b);
468
- return this.a === 1 ? "rgb(".concat(t, ", ").concat(r, ", ").concat(n, ")") : "rgba(".concat(t, ", ").concat(r, ", ").concat(n, ", ").concat(this.roundA, ")");
469
- }, e.prototype.toPercentageRgb = function() {
470
- var t = function(r) {
471
- return "".concat(Math.round(p(r, 255) * 100), "%");
472
- };
473
- return {
474
- r: t(this.r),
475
- g: t(this.g),
476
- b: t(this.b),
477
- a: this.a
478
- };
479
- }, e.prototype.toPercentageRgbString = function() {
480
- var t = function(r) {
481
- return Math.round(p(r, 255) * 100);
482
- };
483
- return this.a === 1 ? "rgb(".concat(t(this.r), "%, ").concat(t(this.g), "%, ").concat(t(this.b), "%)") : "rgba(".concat(t(this.r), "%, ").concat(t(this.g), "%, ").concat(t(this.b), "%, ").concat(this.roundA, ")");
484
- }, e.prototype.toName = function() {
485
- if (this.a === 0)
486
- return "transparent";
487
- if (this.a < 1)
488
- return !1;
489
- for (var t = "#" + Re(this.r, this.g, this.b, !1), r = 0, n = Object.entries(de); r < n.length; r++) {
490
- var o = n[r], a = o[0], i = o[1];
491
- if (t === i)
492
- return a;
493
- }
494
- return !1;
495
- }, e.prototype.toString = function(t) {
496
- var r = !!t;
497
- t = t ?? this.format;
498
- var n = !1, o = this.a < 1 && this.a >= 0, a = !r && o && (t.startsWith("hex") || t === "name");
499
- return a ? t === "name" && this.a === 0 ? this.toName() : this.toRgbString() : (t === "rgb" && (n = this.toRgbString()), t === "prgb" && (n = this.toPercentageRgbString()), (t === "hex" || t === "hex6") && (n = this.toHexString()), t === "hex3" && (n = this.toHexString(!0)), t === "hex4" && (n = this.toHex8String(!0)), t === "hex8" && (n = this.toHex8String()), t === "name" && (n = this.toName()), t === "hsl" && (n = this.toHslString()), t === "hsv" && (n = this.toHsvString()), n || this.toHexString());
500
- }, e.prototype.toNumber = function() {
501
- return (Math.round(this.r) << 16) + (Math.round(this.g) << 8) + Math.round(this.b);
502
- }, e.prototype.clone = function() {
503
- return new e(this.toString());
504
- }, e.prototype.lighten = function(t) {
505
- t === void 0 && (t = 10);
506
- var r = this.toHsl();
507
- return r.l += t / 100, r.l = Q(r.l), new e(r);
508
- }, e.prototype.brighten = function(t) {
509
- t === void 0 && (t = 10);
510
- var r = this.toRgb();
511
- return r.r = Math.max(0, Math.min(255, r.r - Math.round(255 * -(t / 100)))), r.g = Math.max(0, Math.min(255, r.g - Math.round(255 * -(t / 100)))), r.b = Math.max(0, Math.min(255, r.b - Math.round(255 * -(t / 100)))), new e(r);
512
- }, e.prototype.darken = function(t) {
513
- t === void 0 && (t = 10);
514
- var r = this.toHsl();
515
- return r.l -= t / 100, r.l = Q(r.l), new e(r);
516
- }, e.prototype.tint = function(t) {
517
- return t === void 0 && (t = 10), this.mix("white", t);
518
- }, e.prototype.shade = function(t) {
519
- return t === void 0 && (t = 10), this.mix("black", t);
520
- }, e.prototype.desaturate = function(t) {
521
- t === void 0 && (t = 10);
522
- var r = this.toHsl();
523
- return r.s -= t / 100, r.s = Q(r.s), new e(r);
524
- }, e.prototype.saturate = function(t) {
525
- t === void 0 && (t = 10);
526
- var r = this.toHsl();
527
- return r.s += t / 100, r.s = Q(r.s), new e(r);
528
- }, e.prototype.greyscale = function() {
529
- return this.desaturate(100);
530
- }, e.prototype.spin = function(t) {
531
- var r = this.toHsl(), n = (r.h + t) % 360;
532
- return r.h = n < 0 ? 360 + n : n, new e(r);
533
- }, e.prototype.mix = function(t, r) {
534
- r === void 0 && (r = 50);
535
- var n = this.toRgb(), o = new e(t).toRgb(), a = r / 100, i = {
536
- r: (o.r - n.r) * a + n.r,
537
- g: (o.g - n.g) * a + n.g,
538
- b: (o.b - n.b) * a + n.b,
539
- a: (o.a - n.a) * a + n.a
540
- };
541
- return new e(i);
542
- }, e.prototype.analogous = function(t, r) {
543
- t === void 0 && (t = 6), r === void 0 && (r = 30);
544
- var n = this.toHsl(), o = 360 / r, a = [this];
545
- for (n.h = (n.h - (o * t >> 1) + 720) % 360; --t; )
546
- n.h = (n.h + o) % 360, a.push(new e(n));
547
- return a;
548
- }, e.prototype.complement = function() {
549
- var t = this.toHsl();
550
- return t.h = (t.h + 180) % 360, new e(t);
551
- }, e.prototype.monochromatic = function(t) {
552
- t === void 0 && (t = 6);
553
- for (var r = this.toHsv(), n = r.h, o = r.s, a = r.v, i = [], s = 1 / t; t--; )
554
- i.push(new e({ h: n, s: o, v: a })), a = (a + s) % 1;
555
- return i;
556
- }, e.prototype.splitcomplement = function() {
557
- var t = this.toHsl(), r = t.h;
558
- return [
559
- this,
560
- new e({ h: (r + 72) % 360, s: t.s, l: t.l }),
561
- new e({ h: (r + 216) % 360, s: t.s, l: t.l })
562
- ];
563
- }, e.prototype.onBackground = function(t) {
564
- var r = this.toRgb(), n = new e(t).toRgb(), o = r.a + n.a * (1 - r.a);
565
- return new e({
566
- r: (r.r * r.a + n.r * n.a * (1 - r.a)) / o,
567
- g: (r.g * r.a + n.g * n.a * (1 - r.a)) / o,
568
- b: (r.b * r.a + n.b * n.a * (1 - r.a)) / o,
569
- a: o
570
- });
571
- }, e.prototype.triad = function() {
572
- return this.polyad(3);
573
- }, e.prototype.tetrad = function() {
574
- return this.polyad(4);
575
- }, e.prototype.polyad = function(t) {
576
- for (var r = this.toHsl(), n = r.h, o = [this], a = 360 / t, i = 1; i < t; i++)
577
- o.push(new e({ h: (n + i * a) % 360, s: r.s, l: r.l }));
578
- return o;
579
- }, e.prototype.equals = function(t) {
580
- return this.toRgbString() === new e(t).toRgbString();
581
- }, e;
582
- })()
583
- );
584
- function x(e) {
585
- return {
586
- type: Object,
587
- default: e
588
- };
589
- }
590
- const vr = "anticon", pt = () => ({
591
- iconPrefixCls: String,
592
- getTargetContainer: {
593
- type: Function
594
- },
595
- getPopupContainer: {
596
- type: Function
597
- },
598
- prefixCls: String,
599
- getPrefixCls: {
600
- type: Function
601
- },
602
- renderEmpty: {
603
- type: Function
604
- },
605
- transformCellText: {
606
- type: Function
607
- },
608
- csp: x(),
609
- input: x(),
610
- autoInsertSpaceInButton: {
611
- type: Boolean,
612
- default: void 0
613
- },
614
- locale: x(),
615
- pageHeader: x(),
616
- componentSize: {
617
- type: String
618
- },
619
- componentDisabled: {
620
- type: Boolean,
621
- default: void 0
622
- },
623
- direction: {
624
- type: String,
625
- default: "ltr"
626
- },
627
- space: x(),
628
- virtual: {
629
- type: Boolean,
630
- default: void 0
631
- },
632
- dropdownMatchSelectWidth: {
633
- type: [Number, Boolean],
634
- default: !0
635
- },
636
- form: x(),
637
- pagination: x(),
638
- theme: x(),
639
- select: x(),
640
- wave: x()
641
- }), br = Symbol("configProvider"), yr = {
642
- getPrefixCls: (e, t) => t || (e ? `ant-${e}` : "ant"),
643
- iconPrefixCls: d(() => vr),
644
- getPopupContainer: d(() => () => document.body),
645
- direction: d(() => "ltr")
646
- }, gt = () => ft(br, yr), mr = {
647
- // Options.jsx
648
- items_per_page: "条/页",
649
- jump_to: "跳至",
650
- jump_to_confirm: "确定",
651
- page: "页",
652
- // Pagination.jsx
653
- prev_page: "上一页",
654
- next_page: "下一页",
655
- prev_5: "向前 5 页",
656
- next_5: "向后 5 页",
657
- prev_3: "向前 3 页",
658
- next_3: "向后 3 页"
659
- };
660
- function J() {
661
- return J = Object.assign ? Object.assign.bind() : function(e) {
662
- for (var t = 1; t < arguments.length; t++) {
663
- var r = arguments[t];
664
- for (var n in r) ({}).hasOwnProperty.call(r, n) && (e[n] = r[n]);
665
- }
666
- return e;
667
- }, J.apply(null, arguments);
668
- }
669
- const xr = {
670
- locale: "zh_CN",
671
- today: "今天",
672
- now: "此刻",
673
- backToToday: "返回今天",
674
- ok: "确定",
675
- timeSelect: "选择时间",
676
- dateSelect: "选择日期",
677
- weekSelect: "选择周",
678
- clear: "清除",
679
- month: "月",
680
- year: "年",
681
- previousMonth: "上个月 (翻页上键)",
682
- nextMonth: "下个月 (翻页下键)",
683
- monthSelect: "选择月份",
684
- yearSelect: "选择年份",
685
- decadeSelect: "选择年代",
686
- yearFormat: "YYYY年",
687
- dayFormat: "D日",
688
- dateFormat: "YYYY年M月D日",
689
- dateTimeFormat: "YYYY年M月D日 HH时mm分ss秒",
690
- previousYear: "上一年 (Control键加左方向键)",
691
- nextYear: "下一年 (Control键加右方向键)",
692
- previousDecade: "上一年代",
693
- nextDecade: "下一年代",
694
- previousCentury: "上一世纪",
695
- nextCentury: "下一世纪"
696
- }, vt = {
697
- placeholder: "请选择时间",
698
- rangePlaceholder: ["开始时间", "结束时间"]
699
- }, pe = {
700
- lang: J({
701
- placeholder: "请选择日期",
702
- yearPlaceholder: "请选择年份",
703
- quarterPlaceholder: "请选择季度",
704
- monthPlaceholder: "请选择月份",
705
- weekPlaceholder: "请选择周",
706
- rangePlaceholder: ["开始日期", "结束日期"],
707
- rangeYearPlaceholder: ["开始年份", "结束年份"],
708
- rangeMonthPlaceholder: ["开始月份", "结束月份"],
709
- rangeQuarterPlaceholder: ["开始季度", "结束季度"],
710
- rangeWeekPlaceholder: ["开始周", "结束周"]
711
- }, xr),
712
- timePickerLocale: J({}, vt)
713
- };
714
- pe.lang.ok = "确定";
715
- const g = "${label}不是一个有效的${type}", jr = {
716
- locale: "zh-cn",
717
- Pagination: mr,
718
- DatePicker: pe,
719
- TimePicker: vt,
720
- Calendar: pe,
721
- // locales for all components
722
- global: {
723
- placeholder: "请选择"
724
- },
725
- Table: {
726
- filterTitle: "筛选",
727
- filterConfirm: "确定",
728
- filterReset: "重置",
729
- filterEmptyText: "无筛选项",
730
- filterCheckall: "全选",
731
- filterSearchPlaceholder: "在筛选项中搜索",
732
- selectAll: "全选当页",
733
- selectInvert: "反选当页",
734
- selectNone: "清空所有",
735
- selectionAll: "全选所有",
736
- sortTitle: "排序",
737
- expand: "展开行",
738
- collapse: "关闭行",
739
- triggerDesc: "点击降序",
740
- triggerAsc: "点击升序",
741
- cancelSort: "取消排序"
742
- },
743
- Tour: {
744
- Next: "下一步",
745
- Previous: "上一步",
746
- Finish: "结束导览"
747
- },
748
- Modal: {
749
- okText: "确定",
750
- cancelText: "取消",
751
- justOkText: "知道了"
752
- },
753
- Popconfirm: {
754
- cancelText: "取消",
755
- okText: "确定"
756
- },
757
- Transfer: {
758
- searchPlaceholder: "请输入搜索内容",
759
- itemUnit: "项",
760
- itemsUnit: "项",
761
- remove: "删除",
762
- selectCurrent: "全选当页",
763
- removeCurrent: "删除当页",
764
- selectAll: "全选所有",
765
- removeAll: "删除全部",
766
- selectInvert: "反选当页"
767
- },
768
- Upload: {
769
- uploading: "文件上传中",
770
- removeFile: "删除文件",
771
- uploadError: "上传错误",
772
- previewFile: "预览文件",
773
- downloadFile: "下载文件"
774
- },
775
- Empty: {
776
- description: "暂无数据"
777
- },
778
- Icon: {
779
- icon: "图标"
780
- },
781
- Text: {
782
- edit: "编辑",
783
- copy: "复制",
784
- copied: "复制成功",
785
- expand: "展开"
786
- },
787
- PageHeader: {
788
- back: "返回"
789
- },
790
- Form: {
791
- optional: "(可选)",
792
- defaultValidateMessages: {
793
- default: "字段验证错误${label}",
794
- required: "请输入${label}",
795
- enum: "${label}必须是其中一个[${enum}]",
796
- whitespace: "${label}不能为空字符",
797
- date: {
798
- format: "${label}日期格式无效",
799
- parse: "${label}不能转换为日期",
800
- invalid: "${label}是一个无效日期"
801
- },
802
- types: {
803
- string: g,
804
- method: g,
805
- array: g,
806
- object: g,
807
- number: g,
808
- date: g,
809
- boolean: g,
810
- integer: g,
811
- float: g,
812
- regexp: g,
813
- email: g,
814
- url: g,
815
- hex: g
816
- },
817
- string: {
818
- len: "${label}须为${len}个字符",
819
- min: "${label}最少${min}个字符",
820
- max: "${label}最多${max}个字符",
821
- range: "${label}须在${min}-${max}字符之间"
822
- },
823
- number: {
824
- len: "${label}必须等于${len}",
825
- min: "${label}最小值为${min}",
826
- max: "${label}最大值为${max}",
827
- range: "${label}须在${min}-${max}之间"
828
- },
829
- array: {
830
- len: "须为${len}个${label}",
831
- min: "最少${min}个${label}",
832
- max: "最多${max}个${label}",
833
- range: "${label}数量须在${min}-${max}之间"
834
- },
835
- pattern: {
836
- mismatch: "${label}与模式不匹配${pattern}"
837
- }
838
- }
839
- },
840
- Image: {
841
- preview: "预览"
842
- },
843
- QRCode: {
844
- expired: "二维码已过期",
845
- refresh: "点击刷新",
846
- scanned: "已扫描"
847
- }
848
- };
849
- /*!
850
- * Gx Design Pro
851
- * Version: 0.1.0-beta.129
852
- * Author: gx12358
853
- * Copyright (C) 2024 gx12358
854
- * License: MIT License
855
- * Description: Gx Design Pro Provider
856
- * Date Created: 2025-11-05
857
- * Homepage:
858
- * Contact: gx12358@gmail.com
859
- */
860
- class bt {
861
- }
862
- const yt = "CALC_UNIT", Sr = new RegExp(yt, "g");
863
- function se(e) {
864
- return typeof e == "number" ? `${e}${yt}` : e;
865
- }
866
- class B extends bt {
867
- constructor(t, r) {
868
- super(), this.result = "";
869
- const n = typeof t;
870
- this.unitlessCssVar = r, t instanceof B ? this.result = `(${t.result})` : n === "number" ? this.result = se(t) : n === "string" && (this.result = t);
871
- }
872
- add(t) {
873
- return t instanceof B ? this.result = `${this.result} + ${t.getResult()}` : (typeof t == "number" || typeof t == "string") && (this.result = `${this.result} + ${se(t)}`), this.lowPriority = !0, this;
874
- }
875
- sub(t) {
876
- return t instanceof B ? this.result = `${this.result} - ${t.getResult()}` : (typeof t == "number" || typeof t == "string") && (this.result = `${this.result} - ${se(t)}`), this.lowPriority = !0, this;
877
- }
878
- mul(t) {
879
- return this.lowPriority && (this.result = `(${this.result})`), t instanceof B ? this.result = `${this.result} * ${t.getResult(!0)}` : (typeof t == "number" || typeof t == "string") && (this.result = `${this.result} * ${t}`), this.lowPriority = !1, this;
880
- }
881
- div(t) {
882
- return this.lowPriority && (this.result = `(${this.result})`), t instanceof B ? this.result = `${this.result} / ${t.getResult(!0)}` : (typeof t == "number" || typeof t == "string") && (this.result = `${this.result} / ${t}`), this.lowPriority = !1, this;
883
- }
884
- getResult(t) {
885
- return this.lowPriority || t ? `(${this.result})` : this.result;
886
- }
887
- equal(t) {
888
- const { unit: r } = t || {};
889
- let n = !0;
890
- return typeof r == "boolean" ? n = r : Array.from(this.unitlessCssVar).some((o) => this.result.includes(o)) && (n = !1), this.result = this.result.replace(Sr, n ? "px" : ""), typeof this.lowPriority < "u" ? `calc(${this.result})` : this.result;
891
- }
892
- }
893
- class C extends bt {
894
- constructor(t) {
895
- super(), this.result = 0, t instanceof C ? this.result = t.result : typeof t == "number" && (this.result = t);
896
- }
897
- add(t) {
898
- return t instanceof C ? this.result += t.result : typeof t == "number" && (this.result += t), this;
899
- }
900
- sub(t) {
901
- return t instanceof C ? this.result -= t.result : typeof t == "number" && (this.result -= t), this;
902
- }
903
- mul(t) {
904
- return t instanceof C ? this.result *= t.result : typeof t == "number" && (this.result *= t), this;
905
- }
906
- div(t) {
907
- return t instanceof C ? this.result /= t.result : typeof t == "number" && (this.result /= t), this;
908
- }
909
- equal() {
910
- return this.result;
911
- }
912
- }
913
- const Ar = (e, t) => {
914
- const r = e === "css" ? B : C;
915
- return (n) => new r(n, t);
916
- };
917
- function Ne(e) {
918
- return typeof e == "number" ? `${e}px` : e;
919
- }
920
- function Tr(e) {
921
- return e === "js" ? { max: Math.max, min: Math.min } : {
922
- max: (...t) => `max(${t.map((r) => Ne(r)).join(",")})`,
923
- min: (...t) => `min(${t.map((r) => Ne(r)).join(",")})`
924
- };
925
- }
926
- function Mr(e, t) {
927
- return e && e.contains ? e.contains(t) : !1;
928
- }
929
- const ze = "data-vc-order", De = "data-vc-priority", wr = "data-token-hash", _r = "data-css-hash", ge = /* @__PURE__ */ new Map();
930
- function kr(e, t) {
931
- const r = ge.get(e);
932
- if (!r || !Mr(document, r)) {
933
- const n = jt("", t), { parentNode: o } = n;
934
- ge.set(e, o), e.removeChild(n);
935
- }
936
- }
937
- function $r(e) {
938
- return e === "queue" ? "prependQueue" : e ? "prepend" : "append";
939
- }
940
- function Ae() {
941
- return document.querySelector("head") || document.body;
942
- }
943
- function mt() {
944
- return _r;
945
- }
946
- function xt(e) {
947
- return Array.from((ge.get(e) || e).children).filter((t) => t.tagName === "STYLE");
948
- }
949
- function Pr(e) {
950
- const t = Ae();
951
- return xt(t).find((r) => r.getAttribute(mt()) === e);
952
- }
953
- function jt(e, t = {}) {
954
- const { prepend: r, priority: n = 0 } = t, o = $r(r), a = o === "prependQueue", i = document.createElement("style");
955
- i.setAttribute(ze, o), a && n && i.setAttribute(De, `${n}`), i.innerHTML = e;
956
- const s = Ae(), { firstChild: u } = s;
957
- if (r) {
958
- if (a) {
959
- const c = xt(s).filter((h) => {
960
- if (!["prepend", "prependQueue"].includes(h.getAttribute(ze) || ""))
961
- return !1;
962
- const w = Number(h.getAttribute(De) || 0);
963
- return n >= w;
964
- });
965
- if (c.length)
966
- return s.insertBefore(i, c[c.length - 1].nextSibling), i;
967
- }
968
- s.insertBefore(i, u);
969
- } else
970
- s.appendChild(i);
971
- return i;
972
- }
973
- function Br(e, t, r = {}) {
974
- const n = Ae();
975
- kr(n, r);
976
- const o = Pr(t);
977
- if (o)
978
- return o.innerHTML !== e && (o.innerHTML = e), o;
979
- const a = jt(e, r);
980
- return a.setAttribute(mt(), t), a.setAttribute(wr, `theme-var-${t}`), a;
981
- }
982
- const Cr = "gx", Hr = [
983
- "colorPrimary",
984
- "colorSuccess",
985
- "colorError",
986
- "colorWarning",
987
- "colorBgBase",
988
- "colorBgLayout",
989
- "colorBgContainer",
990
- "colorText",
991
- "colorTextBase",
992
- "colorTextDescription",
993
- "colorBorder",
994
- "colorSplit",
995
- "colorPrimaryHover",
996
- "colorErrorHover",
997
- "colorWarningBgHover",
998
- "colorPrimaryActive",
999
- "colorErrorActive",
1000
- "colorWarningActive",
1001
- "colorPrimaryBorder",
1002
- "colorErrorBorder",
1003
- "colorWarningBorder",
1004
- "colorPrimaryBorderHover",
1005
- "colorWarningBorderHover",
1006
- "colorErrorBorderHover",
1007
- "colorPrimaryBg",
1008
- "colorWarningBg",
1009
- "colorErrorBg",
1010
- "colorPrimaryBgHover",
1011
- "colorWarningBgHover",
1012
- "colorErrorBgHover"
1013
- ], Ir = (e) => Object.keys(e).length ? `:root{${Object.entries(e).map(([t, r]) => `${t}:${r};`).join("")}}` : "", Or = (e, t = "") => `--${t ? `${t}-` : ""}${e}`.replace(/([a-z0-9])([A-Z])/g, "$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g, "$1-$2").replace(/([a-z])([A-Z0-9])/g, "$1-$2").toLowerCase();
1014
- function Fr(e = [], t) {
1015
- const r = `${rr().uuid(7)}`, n = Te(), o = document.querySelector("html");
1016
- (n?.token || t?.token?.value) && W([
1017
- () => n?.token ? n.token.value : t?.token?.value,
1018
- () => Kt(e) ? e.value : e
1019
- ], ([a, i]) => {
1020
- if (o && a) {
1021
- const s = {};
1022
- i.concat(Hr).forEach((c) => {
1023
- const h = Or(c, t?.prefix || Cr);
1024
- a[c] && !s[h] && (s[h] = a[c]);
1025
- });
1026
- const u = Ir(s);
1027
- Br(u, r, {
1028
- prepend: "queue",
1029
- priority: -999
1030
- });
1031
- }
1032
- }, { immediate: !0, deep: !0 });
1033
- }
1034
- function St(e, t) {
1035
- const r = Symbol(e);
1036
- return {
1037
- provideContext: (n) => {
1038
- Qt(r, n);
1039
- },
1040
- useInjectContext: (n) => ft(r, n || t || {}),
1041
- contextInjectKey: r
1042
- };
1043
- }
1044
- Jt.useForm;
1045
- const { provideContext: Rr, useInjectContext: Te } = St("pro-config-provider"), _ = (e, t) => new gr(e).setAlpha(t).toRgbString(), Er = (e, t) => {
1046
- const { key: r } = e, n = { ...e }, o = _(t.colorBgElevated, 0.6), a = r?.split(":")?.[0] === "dark";
1047
- return {
1048
- key: "",
1049
- bgLayout: `linear-gradient(${t.colorBgContainer}, ${t.colorBgLayout} 28%)`,
1050
- colorTextAppListIcon: t.colorTextSecondary,
1051
- appListIconHoverBgColor: n?.sider?.colorBgMenuItemSelected,
1052
- colorBgAppListIconHover: _(t.colorTextBase, 0.04),
1053
- colorTextAppListIconHover: t.colorTextBase,
1054
- menuItemIconSize: t.fontSize,
1055
- ...n,
1056
- header: {
1057
- colorBgHeader: o,
1058
- colorBgScrollHeader: _(t.colorBgElevated, 0.8),
1059
- colorHeaderTitle: t.colorText,
1060
- colorBgMenuItemHover: _(t.colorTextBase, 0.03),
1061
- colorBgMenuItemSelected: a ? t.colorPrimary : "transparent",
1062
- colorBgMenuElevated: (n?.header?.colorBgHeader ?? o) !== o ? n.header?.colorBgHeader : t.colorBgElevated,
1063
- colorTextMenuSelected: a ? t.colorTextLightSolid : t.colorPrimary,
1064
- colorBgRightActionsItemHover: t.colorBgTextHover,
1065
- colorTextRightActionsItem: t.colorTextTertiary,
1066
- colorTextRightActionsItemHover: t.colorText,
1067
- heightLayoutHeader: 48,
1068
- colorTextMenu: t.colorTextSecondary,
1069
- colorTextMenuSecondary: t.colorTextTertiary,
1070
- colorTextMenuTitle: t.colorText,
1071
- colorTextMenuActive: t.colorText,
1072
- itemBorderRadius: 4,
1073
- paddingMenuItem: P({ inline: t.margin }, n.header?.paddingMenuItem)
1074
- },
1075
- sider: {
1076
- colorBgCollapsedButton: t.colorBgElevated,
1077
- colorTextCollapsedButtonHover: t.colorTextSecondary,
1078
- colorTextCollapsedButton: _(t.colorTextBase, 0.25),
1079
- colorMenuBackground: "transparent",
1080
- colorMenuItemDivider: _(t.colorTextBase, 0.06),
1081
- colorBgMenuItemHover: t.colorBgTextHover,
1082
- colorBgMenuItemSelected: a ? t.colorPrimary : t.controlItemBgActive,
1083
- colorTextMenu: a ? t.colorTextSecondary : t.colorText,
1084
- colorTextMenuItemHover: t.colorText,
1085
- colorTextMenuSelected: a ? _(t.colorTextBase, 0.95) : t.colorPrimary,
1086
- colorTextMenuActive: a ? t.colorText : t.colorPrimary,
1087
- colorTextMenuSecondary: t.colorTextTertiary,
1088
- colorTextMenuTitle: t.colorText,
1089
- colorTextSubMenuSelected: _(t.colorTextBase, 0.95),
1090
- subMenuItemSelectedColor: a ? t.colorTextLightSolid : t.colorText,
1091
- ...n.sider,
1092
- paddingMenu: P({}, n.sider?.paddingMenu),
1093
- paddingMenuItem: P({ inline: t.padding }, n.sider?.paddingMenuItem),
1094
- marginMenuItem: P({ block: t.marginXXS, inline: t.marginXXS }, n.sider?.marginMenuItem),
1095
- marginSubMenu: P({ block: t.marginXXS, inline: t.marginXXS }, n.sider?.marginMenuItem)
1096
- },
1097
- pageContainer: {
1098
- borderRadius: t.borderRadiusLG,
1099
- colorBgPageContainer: "transparent",
1100
- paddingInlinePageContainerContent: n.pageContainer?.marginInlinePageContainerContent || 20,
1101
- paddingBlockPageContainerContent: n.pageContainer?.marginBlockPageContainerContent || 20,
1102
- colorBgPageContainerFixed: t.colorBgElevated,
1103
- ...n.pageContainer
1104
- }
1105
- };
1106
- };
1107
- function Nr(e = "js") {
1108
- const t = /* @__PURE__ */ new Set(), { max: r, min: n } = Tr(e);
1109
- return {
1110
- calc: Ar(e, t),
1111
- max: r,
1112
- min: n
1113
- };
1114
- }
1115
- process.env.NODE_ENV !== "production" || typeof CSSINJS_STATISTIC < "u";
1116
- Se.useToken;
1117
- var At = typeof global == "object" && global && global.Object === Object && global, zr = typeof self == "object" && self && self.Object === Object && self, S = At || zr || Function("return this")(), j = S.Symbol, Tt = Object.prototype, Dr = Tt.hasOwnProperty, Lr = Tt.toString, U = j ? j.toStringTag : void 0;
1118
- function Ur(e) {
1119
- var t = Dr.call(e, U), r = e[U];
1120
- try {
1121
- e[U] = void 0;
1122
- var n = !0;
1123
- } catch {
1124
- }
1125
- var o = Lr.call(e);
1126
- return n && (t ? e[U] = r : delete e[U]), o;
1127
- }
1128
- var Wr = Object.prototype, qr = Wr.toString;
1129
- function Vr(e) {
1130
- return qr.call(e);
1131
- }
1132
- var Yr = "[object Null]", Gr = "[object Undefined]", Le = j ? j.toStringTag : void 0;
1133
- function O(e) {
1134
- return e == null ? e === void 0 ? Gr : Yr : Le && Le in Object(e) ? Ur(e) : Vr(e);
1135
- }
1136
- function F(e) {
1137
- return e != null && typeof e == "object";
1138
- }
1139
- var Xr = "[object Symbol]";
1140
- function Me(e) {
1141
- return typeof e == "symbol" || F(e) && O(e) == Xr;
1142
- }
1143
- function Mt(e, t) {
1144
- for (var r = -1, n = e == null ? 0 : e.length, o = Array(n); ++r < n; )
1145
- o[r] = t(e[r], r, e);
1146
- return o;
1147
- }
1148
- var R = Array.isArray, Ue = j ? j.prototype : void 0, We = Ue ? Ue.toString : void 0;
1149
- function wt(e) {
1150
- if (typeof e == "string")
1151
- return e;
1152
- if (R(e))
1153
- return Mt(e, wt) + "";
1154
- if (Me(e))
1155
- return We ? We.call(e) : "";
1156
- var t = e + "";
1157
- return t == "0" && 1 / e == -1 / 0 ? "-0" : t;
1158
- }
1159
- function te(e) {
1160
- var t = typeof e;
1161
- return e != null && (t == "object" || t == "function");
1162
- }
1163
- function Qr(e) {
1164
- return e;
1165
- }
1166
- var Zr = "[object AsyncFunction]", Kr = "[object Function]", Jr = "[object GeneratorFunction]", en = "[object Proxy]";
1167
- function we(e) {
1168
- if (!te(e))
1169
- return !1;
1170
- var t = O(e);
1171
- return t == Kr || t == Jr || t == Zr || t == en;
1172
- }
1173
- var ue = S["__core-js_shared__"], qe = (function() {
1174
- var e = /[^.]+$/.exec(ue && ue.keys && ue.keys.IE_PROTO || "");
1175
- return e ? "Symbol(src)_1." + e : "";
1176
- })();
1177
- function tn(e) {
1178
- return !!qe && qe in e;
1179
- }
1180
- var rn = Function.prototype, nn = rn.toString;
1181
- function E(e) {
1182
- if (e != null) {
1183
- try {
1184
- return nn.call(e);
1185
- } catch {
1186
- }
1187
- try {
1188
- return e + "";
1189
- } catch {
1190
- }
1191
- }
1192
- return "";
1193
- }
1194
- var on = /[\\^$.*+?()[\]{}|]/g, an = /^\[object .+?Constructor\]$/, sn = Function.prototype, un = Object.prototype, cn = sn.toString, ln = un.hasOwnProperty, fn = RegExp(
1195
- "^" + cn.call(ln).replace(on, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1196
- );
1197
- function hn(e) {
1198
- if (!te(e) || tn(e))
1199
- return !1;
1200
- var t = we(e) ? fn : an;
1201
- return t.test(E(e));
1202
- }
1203
- function dn(e, t) {
1204
- return e?.[t];
1205
- }
1206
- function N(e, t) {
1207
- var r = dn(e, t);
1208
- return hn(r) ? r : void 0;
1209
- }
1210
- var ve = N(S, "WeakMap");
1211
- function pn(e, t, r) {
1212
- switch (r.length) {
1213
- case 0:
1214
- return e.call(t);
1215
- case 1:
1216
- return e.call(t, r[0]);
1217
- case 2:
1218
- return e.call(t, r[0], r[1]);
1219
- case 3:
1220
- return e.call(t, r[0], r[1], r[2]);
1221
- }
1222
- return e.apply(t, r);
1223
- }
1224
- var gn = 800, vn = 16, bn = Date.now;
1225
- function yn(e) {
1226
- var t = 0, r = 0;
1227
- return function() {
1228
- var n = bn(), o = vn - (n - r);
1229
- if (r = n, o > 0) {
1230
- if (++t >= gn)
1231
- return arguments[0];
1232
- } else
1233
- t = 0;
1234
- return e.apply(void 0, arguments);
1235
- };
1236
- }
1237
- function mn(e) {
1238
- return function() {
1239
- return e;
1240
- };
1241
- }
1242
- var ee = (function() {
1243
- try {
1244
- var e = N(Object, "defineProperty");
1245
- return e({}, "", {}), e;
1246
- } catch {
1247
- }
1248
- })(), xn = ee ? function(e, t) {
1249
- return ee(e, "toString", {
1250
- configurable: !0,
1251
- enumerable: !1,
1252
- value: mn(t),
1253
- writable: !0
1254
- });
1255
- } : Qr, jn = yn(xn);
1256
- function Sn(e, t) {
1257
- for (var r = -1, n = e == null ? 0 : e.length; ++r < n && t(e[r], r, e) !== !1; )
1258
- ;
1259
- return e;
1260
- }
1261
- var An = 9007199254740991, Tn = /^(?:0|[1-9]\d*)$/;
1262
- function Mn(e, t) {
1263
- var r = typeof e;
1264
- return t = t ?? An, !!t && (r == "number" || r != "symbol" && Tn.test(e)) && e > -1 && e % 1 == 0 && e < t;
1265
- }
1266
- function _t(e, t, r) {
1267
- t == "__proto__" && ee ? ee(e, t, {
1268
- configurable: !0,
1269
- enumerable: !0,
1270
- value: r,
1271
- writable: !0
1272
- }) : e[t] = r;
1273
- }
1274
- function kt(e, t) {
1275
- return e === t || e !== e && t !== t;
1276
- }
1277
- var wn = Object.prototype, _n = wn.hasOwnProperty;
1278
- function $t(e, t, r) {
1279
- var n = e[t];
1280
- (!(_n.call(e, t) && kt(n, r)) || r === void 0 && !(t in e)) && _t(e, t, r);
1281
- }
1282
- function kn(e, t, r, n) {
1283
- var o = !r;
1284
- r || (r = {});
1285
- for (var a = -1, i = t.length; ++a < i; ) {
1286
- var s = t[a], u = void 0;
1287
- u === void 0 && (u = e[s]), o ? _t(r, s, u) : $t(r, s, u);
1288
- }
1289
- return r;
1290
- }
1291
- var Ve = Math.max;
1292
- function $n(e, t, r) {
1293
- return t = Ve(t === void 0 ? e.length - 1 : t, 0), function() {
1294
- for (var n = arguments, o = -1, a = Ve(n.length - t, 0), i = Array(a); ++o < a; )
1295
- i[o] = n[t + o];
1296
- o = -1;
1297
- for (var s = Array(t + 1); ++o < t; )
1298
- s[o] = n[o];
1299
- return s[t] = r(i), pn(e, this, s);
1300
- };
1301
- }
1302
- var Pn = 9007199254740991;
1303
- function Pt(e) {
1304
- return typeof e == "number" && e > -1 && e % 1 == 0 && e <= Pn;
1305
- }
1306
- function Bn(e) {
1307
- return e != null && Pt(e.length) && !we(e);
1308
- }
1309
- var Cn = Object.prototype;
1310
- function Hn(e) {
1311
- var t = e && e.constructor, r = typeof t == "function" && t.prototype || Cn;
1312
- return e === r;
1313
- }
1314
- function In(e, t) {
1315
- for (var r = -1, n = Array(e); ++r < e; )
1316
- n[r] = t(r);
1317
- return n;
1318
- }
1319
- var On = "[object Arguments]";
1320
- function Ye(e) {
1321
- return F(e) && O(e) == On;
1322
- }
1323
- var Bt = Object.prototype, Fn = Bt.hasOwnProperty, Rn = Bt.propertyIsEnumerable, Ct = Ye(/* @__PURE__ */ (function() {
1324
- return arguments;
1325
- })()) ? Ye : function(e) {
1326
- return F(e) && Fn.call(e, "callee") && !Rn.call(e, "callee");
1327
- };
1328
- function En() {
1329
- return !1;
1330
- }
1331
- var Ht = typeof exports == "object" && exports && !exports.nodeType && exports, Ge = Ht && typeof module == "object" && module && !module.nodeType && module, Nn = Ge && Ge.exports === Ht, Xe = Nn ? S.Buffer : void 0, zn = Xe ? Xe.isBuffer : void 0, It = zn || En, Dn = "[object Arguments]", Ln = "[object Array]", Un = "[object Boolean]", Wn = "[object Date]", qn = "[object Error]", Vn = "[object Function]", Yn = "[object Map]", Gn = "[object Number]", Xn = "[object Object]", Qn = "[object RegExp]", Zn = "[object Set]", Kn = "[object String]", Jn = "[object WeakMap]", eo = "[object ArrayBuffer]", to = "[object DataView]", ro = "[object Float32Array]", no = "[object Float64Array]", oo = "[object Int8Array]", ao = "[object Int16Array]", io = "[object Int32Array]", so = "[object Uint8Array]", uo = "[object Uint8ClampedArray]", co = "[object Uint16Array]", lo = "[object Uint32Array]", f = {};
1332
- f[ro] = f[no] = f[oo] = f[ao] = f[io] = f[so] = f[uo] = f[co] = f[lo] = !0;
1333
- f[Dn] = f[Ln] = f[eo] = f[Un] = f[to] = f[Wn] = f[qn] = f[Vn] = f[Yn] = f[Gn] = f[Xn] = f[Qn] = f[Zn] = f[Kn] = f[Jn] = !1;
1334
- function fo(e) {
1335
- return F(e) && Pt(e.length) && !!f[O(e)];
1336
- }
1337
- function _e(e) {
1338
- return function(t) {
1339
- return e(t);
1340
- };
1341
- }
1342
- var Ot = typeof exports == "object" && exports && !exports.nodeType && exports, q = Ot && typeof module == "object" && module && !module.nodeType && module, ho = q && q.exports === Ot, ce = ho && At.process, D = (function() {
1343
- try {
1344
- var e = q && q.require && q.require("util").types;
1345
- return e || ce && ce.binding && ce.binding("util");
1346
- } catch {
1347
- }
1348
- })(), Qe = D && D.isTypedArray, po = Qe ? _e(Qe) : fo;
1349
- function go(e, t) {
1350
- var r = R(e), n = !r && Ct(e), o = !r && !n && It(e), a = !r && !n && !o && po(e), i = r || n || o || a, s = i ? In(e.length, String) : [], u = s.length;
1351
- for (var c in e)
1352
- i && // Safari 9 has enumerable `arguments.length` in strict mode.
1353
- (c == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
1354
- o && (c == "offset" || c == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
1355
- a && (c == "buffer" || c == "byteLength" || c == "byteOffset") || // Skip index properties.
1356
- Mn(c, u)) || s.push(c);
1357
- return s;
1358
- }
1359
- function vo(e, t) {
1360
- return function(r) {
1361
- return e(t(r));
1362
- };
1363
- }
1364
- function bo(e) {
1365
- var t = [];
1366
- if (e != null)
1367
- for (var r in Object(e))
1368
- t.push(r);
1369
- return t;
1370
- }
1371
- var yo = Object.prototype, mo = yo.hasOwnProperty;
1372
- function xo(e) {
1373
- if (!te(e))
1374
- return bo(e);
1375
- var t = Hn(e), r = [];
1376
- for (var n in e)
1377
- n == "constructor" && (t || !mo.call(e, n)) || r.push(n);
1378
- return r;
1379
- }
1380
- function jo(e) {
1381
- return Bn(e) ? go(e) : xo(e);
1382
- }
1383
- var So = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Ao = /^\w*$/;
1384
- function To(e, t) {
1385
- if (R(e))
1386
- return !1;
1387
- var r = typeof e;
1388
- return r == "number" || r == "symbol" || r == "boolean" || e == null || Me(e) ? !0 : Ao.test(e) || !So.test(e) || t != null && e in Object(t);
1389
- }
1390
- var V = N(Object, "create");
1391
- function Mo() {
1392
- this.__data__ = V ? V(null) : {}, this.size = 0;
1393
- }
1394
- function wo(e) {
1395
- var t = this.has(e) && delete this.__data__[e];
1396
- return this.size -= t ? 1 : 0, t;
1397
- }
1398
- var _o = "__lodash_hash_undefined__", ko = Object.prototype, $o = ko.hasOwnProperty;
1399
- function Po(e) {
1400
- var t = this.__data__;
1401
- if (V) {
1402
- var r = t[e];
1403
- return r === _o ? void 0 : r;
1404
- }
1405
- return $o.call(t, e) ? t[e] : void 0;
1406
- }
1407
- var Bo = Object.prototype, Co = Bo.hasOwnProperty;
1408
- function Ho(e) {
1409
- var t = this.__data__;
1410
- return V ? t[e] !== void 0 : Co.call(t, e);
1411
- }
1412
- var Io = "__lodash_hash_undefined__";
1413
- function Oo(e, t) {
1414
- var r = this.__data__;
1415
- return this.size += this.has(e) ? 0 : 1, r[e] = V && t === void 0 ? Io : t, this;
1416
- }
1417
- function I(e) {
1418
- var t = -1, r = e == null ? 0 : e.length;
1419
- for (this.clear(); ++t < r; ) {
1420
- var n = e[t];
1421
- this.set(n[0], n[1]);
1422
- }
1423
- }
1424
- I.prototype.clear = Mo;
1425
- I.prototype.delete = wo;
1426
- I.prototype.get = Po;
1427
- I.prototype.has = Ho;
1428
- I.prototype.set = Oo;
1429
- function Fo() {
1430
- this.__data__ = [], this.size = 0;
1431
- }
1432
- function re(e, t) {
1433
- for (var r = e.length; r--; )
1434
- if (kt(e[r][0], t))
1435
- return r;
1436
- return -1;
1437
- }
1438
- var Ro = Array.prototype, Eo = Ro.splice;
1439
- function No(e) {
1440
- var t = this.__data__, r = re(t, e);
1441
- if (r < 0)
1442
- return !1;
1443
- var n = t.length - 1;
1444
- return r == n ? t.pop() : Eo.call(t, r, 1), --this.size, !0;
1445
- }
1446
- function zo(e) {
1447
- var t = this.__data__, r = re(t, e);
1448
- return r < 0 ? void 0 : t[r][1];
1449
- }
1450
- function Do(e) {
1451
- return re(this.__data__, e) > -1;
1452
- }
1453
- function Lo(e, t) {
1454
- var r = this.__data__, n = re(r, e);
1455
- return n < 0 ? (++this.size, r.push([e, t])) : r[n][1] = t, this;
1456
- }
1457
- function M(e) {
1458
- var t = -1, r = e == null ? 0 : e.length;
1459
- for (this.clear(); ++t < r; ) {
1460
- var n = e[t];
1461
- this.set(n[0], n[1]);
1462
- }
1463
- }
1464
- M.prototype.clear = Fo;
1465
- M.prototype.delete = No;
1466
- M.prototype.get = zo;
1467
- M.prototype.has = Do;
1468
- M.prototype.set = Lo;
1469
- var Y = N(S, "Map");
1470
- function Uo() {
1471
- this.size = 0, this.__data__ = {
1472
- hash: new I(),
1473
- map: new (Y || M)(),
1474
- string: new I()
1475
- };
1476
- }
1477
- function Wo(e) {
1478
- var t = typeof e;
1479
- return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
1480
- }
1481
- function ne(e, t) {
1482
- var r = e.__data__;
1483
- return Wo(t) ? r[typeof t == "string" ? "string" : "hash"] : r.map;
1484
- }
1485
- function qo(e) {
1486
- var t = ne(this, e).delete(e);
1487
- return this.size -= t ? 1 : 0, t;
1488
- }
1489
- function Vo(e) {
1490
- return ne(this, e).get(e);
1491
- }
1492
- function Yo(e) {
1493
- return ne(this, e).has(e);
1494
- }
1495
- function Go(e, t) {
1496
- var r = ne(this, e), n = r.size;
1497
- return r.set(e, t), this.size += r.size == n ? 0 : 1, this;
1498
- }
1499
- function $(e) {
1500
- var t = -1, r = e == null ? 0 : e.length;
1501
- for (this.clear(); ++t < r; ) {
1502
- var n = e[t];
1503
- this.set(n[0], n[1]);
1504
- }
1505
- }
1506
- $.prototype.clear = Uo;
1507
- $.prototype.delete = qo;
1508
- $.prototype.get = Vo;
1509
- $.prototype.has = Yo;
1510
- $.prototype.set = Go;
1511
- var Xo = "Expected a function";
1512
- function ke(e, t) {
1513
- if (typeof e != "function" || t != null && typeof t != "function")
1514
- throw new TypeError(Xo);
1515
- var r = function() {
1516
- var n = arguments, o = t ? t.apply(this, n) : n[0], a = r.cache;
1517
- if (a.has(o))
1518
- return a.get(o);
1519
- var i = e.apply(this, n);
1520
- return r.cache = a.set(o, i) || a, i;
1521
- };
1522
- return r.cache = new (ke.Cache || $)(), r;
1523
- }
1524
- ke.Cache = $;
1525
- var Qo = 500;
1526
- function Zo(e) {
1527
- var t = ke(e, function(n) {
1528
- return r.size === Qo && r.clear(), n;
1529
- }), r = t.cache;
1530
- return t;
1531
- }
1532
- var Ko = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, Jo = /\\(\\)?/g, ea = Zo(function(e) {
1533
- var t = [];
1534
- return e.charCodeAt(0) === 46 && t.push(""), e.replace(Ko, function(r, n, o, a) {
1535
- t.push(o ? a.replace(Jo, "$1") : n || r);
1536
- }), t;
1537
- });
1538
- function ta(e) {
1539
- return e == null ? "" : wt(e);
1540
- }
1541
- function $e(e, t) {
1542
- return R(e) ? e : To(e, t) ? [e] : ea(ta(e));
1543
- }
1544
- function Ft(e) {
1545
- if (typeof e == "string" || Me(e))
1546
- return e;
1547
- var t = e + "";
1548
- return t == "0" && 1 / e == -1 / 0 ? "-0" : t;
1549
- }
1550
- function ra(e, t) {
1551
- t = $e(t, e);
1552
- for (var r = 0, n = t.length; e != null && r < n; )
1553
- e = e[Ft(t[r++])];
1554
- return r && r == n ? e : void 0;
1555
- }
1556
- function Pe(e, t) {
1557
- for (var r = -1, n = t.length, o = e.length; ++r < n; )
1558
- e[o + r] = t[r];
1559
- return e;
1560
- }
1561
- var Ze = j ? j.isConcatSpreadable : void 0;
1562
- function na(e) {
1563
- return R(e) || Ct(e) || !!(Ze && e && e[Ze]);
1564
- }
1565
- function oa(e, t, r, n, o) {
1566
- var a = -1, i = e.length;
1567
- for (r || (r = na), o || (o = []); ++a < i; ) {
1568
- var s = e[a];
1569
- r(s) ? Pe(o, s) : o[o.length] = s;
1570
- }
1571
- return o;
1572
- }
1573
- function aa(e) {
1574
- var t = e == null ? 0 : e.length;
1575
- return t ? oa(e) : [];
1576
- }
1577
- function ia(e) {
1578
- return jn($n(e, void 0, aa), e + "");
1579
- }
1580
- var Rt = vo(Object.getPrototypeOf, Object), sa = "[object Object]", ua = Function.prototype, ca = Object.prototype, Et = ua.toString, la = ca.hasOwnProperty, fa = Et.call(Object);
1581
- function ha(e) {
1582
- if (!F(e) || O(e) != sa)
1583
- return !1;
1584
- var t = Rt(e);
1585
- if (t === null)
1586
- return !0;
1587
- var r = la.call(t, "constructor") && t.constructor;
1588
- return typeof r == "function" && r instanceof r && Et.call(r) == fa;
1589
- }
1590
- function da(e, t, r) {
1591
- var n = -1, o = e.length;
1592
- t < 0 && (t = -t > o ? 0 : o + t), r = r > o ? o : r, r < 0 && (r += o), o = t > r ? 0 : r - t >>> 0, t >>>= 0;
1593
- for (var a = Array(o); ++n < o; )
1594
- a[n] = e[n + t];
1595
- return a;
1596
- }
1597
- function pa() {
1598
- this.__data__ = new M(), this.size = 0;
1599
- }
1600
- function ga(e) {
1601
- var t = this.__data__, r = t.delete(e);
1602
- return this.size = t.size, r;
1603
- }
1604
- function va(e) {
1605
- return this.__data__.get(e);
1606
- }
1607
- function ba(e) {
1608
- return this.__data__.has(e);
1609
- }
1610
- var ya = 200;
1611
- function ma(e, t) {
1612
- var r = this.__data__;
1613
- if (r instanceof M) {
1614
- var n = r.__data__;
1615
- if (!Y || n.length < ya - 1)
1616
- return n.push([e, t]), this.size = ++r.size, this;
1617
- r = this.__data__ = new $(n);
1618
- }
1619
- return r.set(e, t), this.size = r.size, this;
1620
- }
1621
- function L(e) {
1622
- var t = this.__data__ = new M(e);
1623
- this.size = t.size;
1624
- }
1625
- L.prototype.clear = pa;
1626
- L.prototype.delete = ga;
1627
- L.prototype.get = va;
1628
- L.prototype.has = ba;
1629
- L.prototype.set = ma;
1630
- var Nt = typeof exports == "object" && exports && !exports.nodeType && exports, Ke = Nt && typeof module == "object" && module && !module.nodeType && module, xa = Ke && Ke.exports === Nt, Je = xa ? S.Buffer : void 0;
1631
- Je && Je.allocUnsafe;
1632
- function ja(e, t) {
1633
- return e.slice();
1634
- }
1635
- function Sa(e, t) {
1636
- for (var r = -1, n = e == null ? 0 : e.length, o = 0, a = []; ++r < n; ) {
1637
- var i = e[r];
1638
- t(i, r, e) && (a[o++] = i);
1639
- }
1640
- return a;
1641
- }
1642
- function zt() {
1643
- return [];
1644
- }
1645
- var Aa = Object.prototype, Ta = Aa.propertyIsEnumerable, et = Object.getOwnPropertySymbols, Ma = et ? function(e) {
1646
- return e == null ? [] : (e = Object(e), Sa(et(e), function(t) {
1647
- return Ta.call(e, t);
1648
- }));
1649
- } : zt, wa = Object.getOwnPropertySymbols, _a = wa ? function(e) {
1650
- for (var t = []; e; )
1651
- Pe(t, Ma(e)), e = Rt(e);
1652
- return t;
1653
- } : zt;
1654
- function ka(e, t, r) {
1655
- var n = t(e);
1656
- return R(e) ? n : Pe(n, r(e));
1657
- }
1658
- function Dt(e) {
1659
- return ka(e, jo, _a);
1660
- }
1661
- var be = N(S, "DataView"), ye = N(S, "Promise"), me = N(S, "Set"), tt = "[object Map]", $a = "[object Object]", rt = "[object Promise]", nt = "[object Set]", ot = "[object WeakMap]", at = "[object DataView]", Pa = E(be), Ba = E(Y), Ca = E(ye), Ha = E(me), Ia = E(ve), T = O;
1662
- (be && T(new be(new ArrayBuffer(1))) != at || Y && T(new Y()) != tt || ye && T(ye.resolve()) != rt || me && T(new me()) != nt || ve && T(new ve()) != ot) && (T = function(e) {
1663
- var t = O(e), r = t == $a ? e.constructor : void 0, n = r ? E(r) : "";
1664
- if (n)
1665
- switch (n) {
1666
- case Pa:
1667
- return at;
1668
- case Ba:
1669
- return tt;
1670
- case Ca:
1671
- return rt;
1672
- case Ha:
1673
- return nt;
1674
- case Ia:
1675
- return ot;
1676
- }
1677
- return t;
1678
- });
1679
- var Oa = Object.prototype, Fa = Oa.hasOwnProperty;
1680
- function Ra(e) {
1681
- var t = e.length, r = new e.constructor(t);
1682
- return t && typeof e[0] == "string" && Fa.call(e, "index") && (r.index = e.index, r.input = e.input), r;
1683
- }
1684
- var it = S.Uint8Array;
1685
- function Be(e) {
1686
- var t = new e.constructor(e.byteLength);
1687
- return new it(t).set(new it(e)), t;
1688
- }
1689
- function Ea(e, t) {
1690
- var r = Be(e.buffer);
1691
- return new e.constructor(r, e.byteOffset, e.byteLength);
1692
- }
1693
- var Na = /\w*$/;
1694
- function za(e) {
1695
- var t = new e.constructor(e.source, Na.exec(e));
1696
- return t.lastIndex = e.lastIndex, t;
1697
- }
1698
- var st = j ? j.prototype : void 0, ut = st ? st.valueOf : void 0;
1699
- function Da(e) {
1700
- return ut ? Object(ut.call(e)) : {};
1701
- }
1702
- function La(e, t) {
1703
- var r = Be(e.buffer);
1704
- return new e.constructor(r, e.byteOffset, e.length);
1705
- }
1706
- var Ua = "[object Boolean]", Wa = "[object Date]", qa = "[object Map]", Va = "[object Number]", Ya = "[object RegExp]", Ga = "[object Set]", Xa = "[object String]", Qa = "[object Symbol]", Za = "[object ArrayBuffer]", Ka = "[object DataView]", Ja = "[object Float32Array]", ei = "[object Float64Array]", ti = "[object Int8Array]", ri = "[object Int16Array]", ni = "[object Int32Array]", oi = "[object Uint8Array]", ai = "[object Uint8ClampedArray]", ii = "[object Uint16Array]", si = "[object Uint32Array]";
1707
- function ui(e, t, r) {
1708
- var n = e.constructor;
1709
- switch (t) {
1710
- case Za:
1711
- return Be(e);
1712
- case Ua:
1713
- case Wa:
1714
- return new n(+e);
1715
- case Ka:
1716
- return Ea(e);
1717
- case Ja:
1718
- case ei:
1719
- case ti:
1720
- case ri:
1721
- case ni:
1722
- case oi:
1723
- case ai:
1724
- case ii:
1725
- case si:
1726
- return La(e);
1727
- case qa:
1728
- return new n();
1729
- case Va:
1730
- case Xa:
1731
- return new n(e);
1732
- case Ya:
1733
- return za(e);
1734
- case Ga:
1735
- return new n();
1736
- case Qa:
1737
- return Da(e);
1738
- }
1739
- }
1740
- var ci = "[object Map]";
1741
- function li(e) {
1742
- return F(e) && T(e) == ci;
1743
- }
1744
- var ct = D && D.isMap, fi = ct ? _e(ct) : li, hi = "[object Set]";
1745
- function di(e) {
1746
- return F(e) && T(e) == hi;
1747
- }
1748
- var lt = D && D.isSet, pi = lt ? _e(lt) : di, Lt = "[object Arguments]", gi = "[object Array]", vi = "[object Boolean]", bi = "[object Date]", yi = "[object Error]", Ut = "[object Function]", mi = "[object GeneratorFunction]", xi = "[object Map]", ji = "[object Number]", Wt = "[object Object]", Si = "[object RegExp]", Ai = "[object Set]", Ti = "[object String]", Mi = "[object Symbol]", wi = "[object WeakMap]", _i = "[object ArrayBuffer]", ki = "[object DataView]", $i = "[object Float32Array]", Pi = "[object Float64Array]", Bi = "[object Int8Array]", Ci = "[object Int16Array]", Hi = "[object Int32Array]", Ii = "[object Uint8Array]", Oi = "[object Uint8ClampedArray]", Fi = "[object Uint16Array]", Ri = "[object Uint32Array]", l = {};
1749
- l[Lt] = l[gi] = l[_i] = l[ki] = l[vi] = l[bi] = l[$i] = l[Pi] = l[Bi] = l[Ci] = l[Hi] = l[xi] = l[ji] = l[Wt] = l[Si] = l[Ai] = l[Ti] = l[Mi] = l[Ii] = l[Oi] = l[Fi] = l[Ri] = !0;
1750
- l[yi] = l[Ut] = l[wi] = !1;
1751
- function K(e, t, r, n, o, a) {
1752
- var i;
1753
- if (r && (i = o ? r(e, n, o, a) : r(e)), i !== void 0)
1754
- return i;
1755
- if (!te(e))
1756
- return e;
1757
- var s = R(e);
1758
- if (s)
1759
- i = Ra(e);
1760
- else {
1761
- var u = T(e), c = u == Ut || u == mi;
1762
- if (It(e))
1763
- return ja(e);
1764
- if (u == Wt || u == Lt || c && !o)
1765
- i = {};
1766
- else {
1767
- if (!l[u])
1768
- return o ? e : {};
1769
- i = ui(e, u);
1770
- }
1771
- }
1772
- a || (a = new L());
1773
- var h = a.get(e);
1774
- if (h)
1775
- return h;
1776
- a.set(e, i), pi(e) ? e.forEach(function(y) {
1777
- i.add(K(y, t, r, y, e, a));
1778
- }) : fi(e) && e.forEach(function(y, m) {
1779
- i.set(m, K(y, t, r, m, e, a));
12
+ import { useContext as g } from "@gx-design-vue/pro-provider";
13
+ import { useDark as f, useToggle as T, useColorMode as y } from "@vueuse/core";
14
+ import { nextTick as v, defineComponent as p, ref as l, watch as h, computed as C } from "vue";
15
+ const { provideContext: x, useInjectContext: R } = g("theme-provider"), k = f({
16
+ storageKey: "gx-pro-theme-appearance"
17
+ }), S = T(k);
18
+ function $(o, a) {
19
+ if (!(document.startViewTransition && !window.matchMedia("(prefers-reduced-motion: reduce)").matches)) {
20
+ a.setTheme?.(a.isDark ? "dark" : "light");
21
+ return;
22
+ }
23
+ const i = o.getBoundingClientRect(), t = i.left + i.width / 2, n = i.top + i.height / 2, s = Math.hypot(Math.max(t, innerWidth - t), Math.max(n, innerHeight - n)), m = 100 * t / innerWidth, r = 100 * n / innerHeight, c = Math.hypot(innerWidth, innerHeight) / Math.SQRT2, e = 100 * s / c;
24
+ document.startViewTransition(async () => {
25
+ a.setTheme?.(a.isDark ? "dark" : "light"), await v();
26
+ }).ready.then(() => {
27
+ const d = [
28
+ `circle(0% at ${m}% ${r}%)`,
29
+ `circle(${e}% at ${m}% ${r}%)`
30
+ ];
31
+ document.documentElement.animate({
32
+ clipPath: a.isDark ? [...d].reverse() : d
33
+ }, {
34
+ duration: 400,
35
+ // 保持最终状态
36
+ fill: "forwards",
37
+ easing: "ease-in",
38
+ pseudoElement: a.isDark ? "::view-transition-old(root)" : "::view-transition-new(root)"
39
+ });
1780
40
  });
1781
- var w = Dt, G = s ? void 0 : w(e);
1782
- return Sn(G || e, function(y, m) {
1783
- G && (m = y, y = e[m]), $t(i, m, K(y, t, r, m, e, a));
1784
- }), i;
1785
- }
1786
- function Ei(e) {
1787
- var t = e == null ? 0 : e.length;
1788
- return t ? e[t - 1] : void 0;
1789
41
  }
1790
- function Ni(e, t) {
1791
- return t.length < 2 ? e : ra(e, da(t, 0, -1));
1792
- }
1793
- function zi(e, t) {
1794
- return t = $e(t, e), e = Ni(e, t), e == null || delete e[Ft(Ei(t))];
1795
- }
1796
- function Di(e) {
1797
- return ha(e) ? void 0 : e;
1798
- }
1799
- var Li = 1, Ui = 2, Wi = 4, xe = ia(function(e, t) {
1800
- var r = {};
1801
- if (e == null)
1802
- return r;
1803
- var n = !1;
1804
- t = Mt(t, function(a) {
1805
- return a = $e(a, e), n || (n = a.length > 1), a;
1806
- }), kn(e, Dt(e), r), n && (r = K(r, Li | Ui | Wi, Di));
1807
- for (var o = t.length; o--; )
1808
- zi(r, t[o]);
1809
- return r;
1810
- });
1811
- const qt = {
1812
- dark: Boolean,
1813
- cssVar: {
1814
- type: Array,
1815
- default: () => []
1816
- },
1817
- hashed: {
1818
- type: Boolean,
1819
- default: void 0
1820
- },
1821
- components: Object,
1822
- token: Object
1823
- }, qi = /* @__PURE__ */ je({
1824
- name: "ConfigProviderContainer",
1825
- props: {
1826
- ...pt(),
1827
- ...qt
1828
- },
1829
- setup(e, {
1830
- slots: t
1831
- }) {
1832
- const r = gt(), n = Te(), o = r ? "." + r?.getPrefixCls() : "", a = Se.useToken?.(), i = `.${Ie({})}`, s = `.${Ie({
1833
- isPor: !0
1834
- })}`, u = `${s}`, c = d(() => Er(e.token?.layout || {}, a?.token?.value)), h = d(() => P(a?.token?.value || {}, xe(e.token || {}, "layout"), {
1835
- ...Nr(),
1836
- antCls: o,
1837
- componentsCls: i,
1838
- proComponentsCls: s,
1839
- layout: c.value
1840
- })), w = er(a.theme, d(() => [h.value ?? {}, a.token.value]), d(() => ({
1841
- salt: u,
1842
- override: h.value
1843
- }))), G = d(() => w.value?.[0]), y = d(() => w.value?.[1]), m = d(() => ({
1844
- ...P(n?.token?.value, a.token.value, {
1845
- componentsCls: i,
1846
- proComponentsCls: s,
1847
- antCls: o,
1848
- themeId: a.theme.value.id,
1849
- layout: c.value
1850
- }),
1851
- ...G.value || {}
1852
- })), Vt = d(() => !(e.hashed === !1 || n?.hashed?.value === !1)), Ce = d(() => e.hashed === !1 || n?.hashed?.value === !1 ? "" : a?.hashId?.value ? a?.hashId?.value : y.value), Yt = d(() => e.dark ?? n.dark?.value), Gt = d(() => {
1853
- const z = xe(r || {}, ["locale", "getPrefixCls", "theme"]);
1854
- for (const X in z)
1855
- z[X] = we(z[X]) ? z[X] : z[X]?.value;
1856
- return z;
1857
- }), Xt = d(() => ({
1858
- ...r.theme?.value,
1859
- hashId: Ce.value,
1860
- hashed: !0
1861
- }));
1862
- return Fr(Zt(e, "cssVar"), {
1863
- token: m
1864
- }), Rr({
1865
- ...n || {},
1866
- token: m,
1867
- dark: Yt,
1868
- hashId: Ce,
1869
- hashed: Vt,
1870
- theme: d(() => a.theme?.value)
1871
- }), () => fe(ht, he(Gt.value, {
1872
- theme: Xt.value
1873
- }), {
1874
- default: () => [t.default?.()]
1875
- });
1876
- }
1877
- }), le = /* @__PURE__ */ je({
1878
- name: "GProConfigProvider",
1879
- props: {
1880
- ...pt(),
1881
- ...qt
1882
- },
1883
- setup(e, {
1884
- slots: t
1885
- }) {
1886
- const r = gt(), n = Te(), o = d(() => e.dark ?? n?.dark?.value), a = () => o.value ? [e.theme?.algorithm, Se.darkAlgorithm].flat(1).filter(Boolean) : e.theme?.algorithm;
1887
- return () => {
1888
- const {
1889
- locale: i,
1890
- token: s,
1891
- components: u,
1892
- ...c
1893
- } = e;
1894
- return fe(ht, he(c, {
1895
- locale: i || r?.locale?.value || jr,
1896
- theme: {
1897
- ...xe(r?.theme?.value, ["locale", "theme"]),
1898
- token: {
1899
- ...s
1900
- },
1901
- components: r?.theme?.value?.components ?? u,
1902
- algorithm: a()
1903
- }
1904
- }), {
1905
- default: () => [fe(qi, he(e, {
1906
- token: s
1907
- }), {
1908
- default: () => [t.default?.()]
1909
- })]
1910
- });
1911
- };
1912
- }
1913
- });
1914
- le.install = (e) => (e.component(le.name, le), e);
1915
- const {
1916
- provideContext: Vi
1917
- } = St("theme-provider"), Qi = /* @__PURE__ */ je({
42
+ const B = /* @__PURE__ */ p({
1918
43
  name: "ThemeContext",
1919
44
  inheritAttrs: !1,
1920
45
  props: {
@@ -1937,43 +62,46 @@ const {
1937
62
  },
1938
63
  emits: ["change", "changeBase", "update:theme"],
1939
64
  slots: Object,
1940
- setup(e, {
1941
- slots: t,
1942
- emit: r
65
+ setup(o, {
66
+ slots: a,
67
+ emit: u
1943
68
  }) {
1944
- const n = document.querySelector("html"), o = He(), a = He(e.theme || e.defaultTheme || "system");
1945
- W(() => e.theme, (h) => {
1946
- h && (a.value = h);
69
+ const i = document.querySelector("html"), t = l(), n = l(o.theme || o.defaultTheme || "system");
70
+ h(() => o.theme, (e) => {
71
+ e && (n.value = e);
1947
72
  });
1948
73
  const {
1949
- system: i,
1950
- store: s
1951
- } = tr();
1952
- W(() => i.value, () => {
1953
- u();
74
+ system: s,
75
+ store: m
76
+ } = y();
77
+ h(() => s.value, () => {
78
+ r();
1954
79
  }, {
1955
80
  immediate: !0
1956
- }), W(() => o.value, (h) => {
1957
- h && e.onChangeBase?.(h);
81
+ }), h(() => t.value, (e) => {
82
+ e && o.onChangeBase?.(e);
1958
83
  }, {
1959
84
  immediate: !0
1960
- }), W(a, (h) => {
1961
- e.onChange?.(h), r("update:theme", h), u();
85
+ }), h(n, (e) => {
86
+ o.onChange?.(e), u("update:theme", e), r();
1962
87
  });
1963
- function u() {
1964
- n && (a.value === "system" ? (o.value = i.value, n.setAttribute("data-theme", o.value)) : (o.value = a.value, n.setAttribute("data-theme", a.value)), s.value = o.value);
88
+ function r() {
89
+ i && (n.value === "system" ? (t.value = s.value, i.setAttribute("data-theme", t.value)) : (t.value = n.value, i.setAttribute("data-theme", n.value)), m.value = t.value);
1965
90
  }
1966
- function c(h) {
1967
- a.value = h, u();
91
+ function c(e) {
92
+ n.value = e, r();
1968
93
  }
1969
- return Vi({
1970
- theme: a,
1971
- resolvedTheme: o,
1972
- isDark: d(() => o.value === "dark"),
94
+ return x({
95
+ theme: n,
96
+ resolvedTheme: t,
97
+ isDark: C(() => t.value === "dark"),
1973
98
  setTheme: c
1974
- }), () => t.default();
99
+ }), () => a.default();
1975
100
  }
1976
101
  });
1977
102
  export {
1978
- Qi as ThemeContext
103
+ B as ThemeContext,
104
+ $ as toggleAnimateTheme,
105
+ S as toggleDark,
106
+ R as useThemeContext
1979
107
  };