@vaebe/ccui 2.0.0-beta.0 → 2.0.1-beta.1

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 (83) hide show
  1. package/README.md +4 -0
  2. package/button/index.es.js +28 -22
  3. package/button/index.umd.js +1 -1
  4. package/calendar/index.es.js +445 -90
  5. package/calendar/index.umd.js +1 -1
  6. package/ccui-cli.css +1 -1
  7. package/check-box/index.es.js +8 -2
  8. package/check-box/index.umd.js +1 -1
  9. package/chunk-Ndeg2fpE.js +20 -0
  10. package/collapse/index.es.js +10 -7
  11. package/collapse/index.umd.js +1 -1
  12. package/config-provider/chunk-C_CI6nMA.js +13 -0
  13. package/config-provider/en-BG83iZ_P.js +24 -0
  14. package/config-provider/index.es.js +408 -53
  15. package/config-provider/index.umd.js +1 -1
  16. package/config-provider/ja-B-93MQG5.js +56 -0
  17. package/config-provider/ko-86th3uXt.js +56 -0
  18. package/config-provider/zh-cn-BQE-LNg1.js +59 -0
  19. package/date-picker/ccui-cli.css +1 -1
  20. package/date-picker/index.es.js +664 -482
  21. package/date-picker/index.umd.js +1 -1
  22. package/drawer/index.es.js +271 -279
  23. package/drawer/index.umd.js +1 -1
  24. package/dropdown/index.es.js +187 -171
  25. package/dropdown/index.umd.js +1 -1
  26. package/empty/index.es.js +341 -24
  27. package/empty/index.umd.js +1 -1
  28. package/en-BVwCvuzF.js +24 -0
  29. package/float-button/index.es.js +1134 -46
  30. package/float-button/index.umd.js +1 -1
  31. package/form/index.es.js +1357 -261
  32. package/form/index.umd.js +1 -1
  33. package/icon/index.es.js +93 -10
  34. package/icon/index.umd.js +1 -1
  35. package/image/index.es.js +353 -36
  36. package/image/index.umd.js +1 -1
  37. package/input/index.es.js +24 -15
  38. package/input/index.umd.js +1 -1
  39. package/input-number/index.es.js +45 -25
  40. package/input-number/index.umd.js +1 -1
  41. package/ja-B4U4rt8A.js +56 -0
  42. package/ko-BG35I8uK.js +56 -0
  43. package/menu/index.es.js +3 -1
  44. package/menu/index.umd.js +1 -1
  45. package/message/index.es.js +1179 -86
  46. package/message/index.umd.js +1 -1
  47. package/modal/index.es.js +735 -335
  48. package/modal/index.umd.js +1 -1
  49. package/notification/index.es.js +1176 -83
  50. package/notification/index.umd.js +1 -1
  51. package/package.json +9 -9
  52. package/pagination/index.es.js +381 -60
  53. package/pagination/index.umd.js +1 -1
  54. package/popconfirm/index.es.js +469 -143
  55. package/popconfirm/index.umd.js +1 -1
  56. package/popover/index.es.js +192 -175
  57. package/popover/index.umd.js +1 -1
  58. package/radio/index.es.js +8 -2
  59. package/radio/index.umd.js +1 -1
  60. package/rate/index.es.js +22 -12
  61. package/rate/index.umd.js +1 -1
  62. package/select/index.es.js +135 -53
  63. package/select/index.umd.js +1 -1
  64. package/slider/index.es.js +165 -155
  65. package/slider/index.umd.js +1 -1
  66. package/steps/index.es.js +1140 -49
  67. package/steps/index.umd.js +1 -1
  68. package/switch/index.es.js +2 -0
  69. package/switch/index.umd.js +1 -1
  70. package/tabs/index.es.js +31 -5
  71. package/tabs/index.umd.js +1 -1
  72. package/tag/index.es.js +53 -35
  73. package/tag/index.umd.js +1 -1
  74. package/tooltip/index.es.js +78 -77
  75. package/tooltip/index.umd.js +1 -1
  76. package/tree/ccui-cli.css +1 -1
  77. package/tree/index.es.js +1491 -276
  78. package/tree/index.umd.js +1 -1
  79. package/typography/index.es.js +1213 -125
  80. package/typography/index.umd.js +1 -1
  81. package/vue-ccui.es.js +8726 -7604
  82. package/vue-ccui.umd.js +1 -1
  83. package/zh-cn-C8nbfD5S.js +59 -0
@@ -1,22 +1,356 @@
1
- import { computed as e, createVNode as t, defineComponent as n, inject as r, provide as i } from "vue";
1
+ import { n as e, t } from "./chunk-C_CI6nMA.js";
2
+ import { computed as n, createVNode as r, defineComponent as i, inject as a, provide as o, watch as s } from "vue";
2
3
  //#region ../ccui/ui/shared/hooks/use-namespace.ts
3
- function a(e, t, n) {
4
+ function c(e, t, n) {
4
5
  let r = e;
5
6
  return t && (r += `__${t}`), n && (r += `--${n}`), r;
6
7
  }
7
- function o(e, t = !1) {
8
+ function l(e, t = !1) {
8
9
  let n = t ? `.ccui-${e}` : `ccui-${e}`;
9
10
  return {
10
- b: () => a(n),
11
- e: (e) => e ? a(n, e) : "",
12
- m: (e) => e ? a(n, "", e) : "",
13
- em: (e, t) => e && t ? a(n, e, t) : "",
11
+ b: () => c(n),
12
+ e: (e) => e ? c(n, e) : "",
13
+ m: (e) => e ? c(n, "", e) : "",
14
+ em: (e, t) => e && t ? c(n, e, t) : "",
14
15
  is: (e) => `is-${e}`
15
16
  };
16
17
  }
17
18
  //#endregion
19
+ //#region ../../node_modules/.pnpm/dayjs@1.11.19/node_modules/dayjs/dayjs.min.js
20
+ var u = /* @__PURE__ */ t(((e, t) => {
21
+ (function(n, r) {
22
+ typeof e == "object" && t !== void 0 ? t.exports = r() : typeof define == "function" && define.amd ? define(r) : (n = typeof globalThis < "u" ? globalThis : n || self).dayjs = r();
23
+ })(e, (function() {
24
+ var e = 1e3, t = 6e4, n = 36e5, r = "millisecond", i = "second", a = "minute", o = "hour", s = "day", c = "week", l = "month", u = "quarter", d = "year", f = "date", p = "Invalid Date", m = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, h = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, g = {
25
+ name: "en",
26
+ weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),
27
+ months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"),
28
+ ordinal: function(e) {
29
+ var t = [
30
+ "th",
31
+ "st",
32
+ "nd",
33
+ "rd"
34
+ ], n = e % 100;
35
+ return "[" + e + (t[(n - 20) % 10] || t[n] || t[0]) + "]";
36
+ }
37
+ }, _ = function(e, t, n) {
38
+ var r = String(e);
39
+ return !r || r.length >= t ? e : "" + Array(t + 1 - r.length).join(n) + e;
40
+ }, v = {
41
+ s: _,
42
+ z: function(e) {
43
+ var t = -e.utcOffset(), n = Math.abs(t), r = Math.floor(n / 60), i = n % 60;
44
+ return (t <= 0 ? "+" : "-") + _(r, 2, "0") + ":" + _(i, 2, "0");
45
+ },
46
+ m: function e(t, n) {
47
+ if (t.date() < n.date()) return -e(n, t);
48
+ var r = 12 * (n.year() - t.year()) + (n.month() - t.month()), i = t.clone().add(r, l), a = n - i < 0, o = t.clone().add(r + (a ? -1 : 1), l);
49
+ return +(-(r + (n - i) / (a ? i - o : o - i)) || 0);
50
+ },
51
+ a: function(e) {
52
+ return e < 0 ? Math.ceil(e) || 0 : Math.floor(e);
53
+ },
54
+ p: function(e) {
55
+ return {
56
+ M: l,
57
+ y: d,
58
+ w: c,
59
+ d: s,
60
+ D: f,
61
+ h: o,
62
+ m: a,
63
+ s: i,
64
+ ms: r,
65
+ Q: u
66
+ }[e] || String(e || "").toLowerCase().replace(/s$/, "");
67
+ },
68
+ u: function(e) {
69
+ return e === void 0;
70
+ }
71
+ }, y = "en", b = {};
72
+ b[y] = g;
73
+ var x = "$isDayjsObject", S = function(e) {
74
+ return e instanceof E || !(!e || !e[x]);
75
+ }, C = function e(t, n, r) {
76
+ var i;
77
+ if (!t) return y;
78
+ if (typeof t == "string") {
79
+ var a = t.toLowerCase();
80
+ b[a] && (i = a), n && (b[a] = n, i = a);
81
+ var o = t.split("-");
82
+ if (!i && o.length > 1) return e(o[0]);
83
+ } else {
84
+ var s = t.name;
85
+ b[s] = t, i = s;
86
+ }
87
+ return !r && i && (y = i), i || !r && y;
88
+ }, w = function(e, t) {
89
+ if (S(e)) return e.clone();
90
+ var n = typeof t == "object" ? t : {};
91
+ return n.date = e, n.args = arguments, new E(n);
92
+ }, T = v;
93
+ T.l = C, T.i = S, T.w = function(e, t) {
94
+ return w(e, {
95
+ locale: t.$L,
96
+ utc: t.$u,
97
+ x: t.$x,
98
+ $offset: t.$offset
99
+ });
100
+ };
101
+ var E = function() {
102
+ function g(e) {
103
+ this.$L = C(e.locale, null, !0), this.parse(e), this.$x = this.$x || e.x || {}, this[x] = !0;
104
+ }
105
+ var _ = g.prototype;
106
+ return _.parse = function(e) {
107
+ this.$d = function(e) {
108
+ var t = e.date, n = e.utc;
109
+ if (t === null) return /* @__PURE__ */ new Date(NaN);
110
+ if (T.u(t)) return /* @__PURE__ */ new Date();
111
+ if (t instanceof Date) return new Date(t);
112
+ if (typeof t == "string" && !/Z$/i.test(t)) {
113
+ var r = t.match(m);
114
+ if (r) {
115
+ var i = r[2] - 1 || 0, a = (r[7] || "0").substring(0, 3);
116
+ return n ? new Date(Date.UTC(r[1], i, r[3] || 1, r[4] || 0, r[5] || 0, r[6] || 0, a)) : new Date(r[1], i, r[3] || 1, r[4] || 0, r[5] || 0, r[6] || 0, a);
117
+ }
118
+ }
119
+ return new Date(t);
120
+ }(e), this.init();
121
+ }, _.init = function() {
122
+ var e = this.$d;
123
+ this.$y = e.getFullYear(), this.$M = e.getMonth(), this.$D = e.getDate(), this.$W = e.getDay(), this.$H = e.getHours(), this.$m = e.getMinutes(), this.$s = e.getSeconds(), this.$ms = e.getMilliseconds();
124
+ }, _.$utils = function() {
125
+ return T;
126
+ }, _.isValid = function() {
127
+ return this.$d.toString() !== p;
128
+ }, _.isSame = function(e, t) {
129
+ var n = w(e);
130
+ return this.startOf(t) <= n && n <= this.endOf(t);
131
+ }, _.isAfter = function(e, t) {
132
+ return w(e) < this.startOf(t);
133
+ }, _.isBefore = function(e, t) {
134
+ return this.endOf(t) < w(e);
135
+ }, _.$g = function(e, t, n) {
136
+ return T.u(e) ? this[t] : this.set(n, e);
137
+ }, _.unix = function() {
138
+ return Math.floor(this.valueOf() / 1e3);
139
+ }, _.valueOf = function() {
140
+ return this.$d.getTime();
141
+ }, _.startOf = function(e, t) {
142
+ var n = this, r = !!T.u(t) || t, u = T.p(e), p = function(e, t) {
143
+ var i = T.w(n.$u ? Date.UTC(n.$y, t, e) : new Date(n.$y, t, e), n);
144
+ return r ? i : i.endOf(s);
145
+ }, m = function(e, t) {
146
+ return T.w(n.toDate()[e].apply(n.toDate("s"), (r ? [
147
+ 0,
148
+ 0,
149
+ 0,
150
+ 0
151
+ ] : [
152
+ 23,
153
+ 59,
154
+ 59,
155
+ 999
156
+ ]).slice(t)), n);
157
+ }, h = this.$W, g = this.$M, _ = this.$D, v = "set" + (this.$u ? "UTC" : "");
158
+ switch (u) {
159
+ case d: return r ? p(1, 0) : p(31, 11);
160
+ case l: return r ? p(1, g) : p(0, g + 1);
161
+ case c:
162
+ var y = this.$locale().weekStart || 0, b = (h < y ? h + 7 : h) - y;
163
+ return p(r ? _ - b : _ + (6 - b), g);
164
+ case s:
165
+ case f: return m(v + "Hours", 0);
166
+ case o: return m(v + "Minutes", 1);
167
+ case a: return m(v + "Seconds", 2);
168
+ case i: return m(v + "Milliseconds", 3);
169
+ default: return this.clone();
170
+ }
171
+ }, _.endOf = function(e) {
172
+ return this.startOf(e, !1);
173
+ }, _.$set = function(e, t) {
174
+ var n, c = T.p(e), u = "set" + (this.$u ? "UTC" : ""), p = (n = {}, n[s] = u + "Date", n[f] = u + "Date", n[l] = u + "Month", n[d] = u + "FullYear", n[o] = u + "Hours", n[a] = u + "Minutes", n[i] = u + "Seconds", n[r] = u + "Milliseconds", n)[c], m = c === s ? this.$D + (t - this.$W) : t;
175
+ if (c === l || c === d) {
176
+ var h = this.clone().set(f, 1);
177
+ h.$d[p](m), h.init(), this.$d = h.set(f, Math.min(this.$D, h.daysInMonth())).$d;
178
+ } else p && this.$d[p](m);
179
+ return this.init(), this;
180
+ }, _.set = function(e, t) {
181
+ return this.clone().$set(e, t);
182
+ }, _.get = function(e) {
183
+ return this[T.p(e)]();
184
+ }, _.add = function(r, u) {
185
+ var f, p = this;
186
+ r = Number(r);
187
+ var m = T.p(u), h = function(e) {
188
+ var t = w(p);
189
+ return T.w(t.date(t.date() + Math.round(e * r)), p);
190
+ };
191
+ if (m === l) return this.set(l, this.$M + r);
192
+ if (m === d) return this.set(d, this.$y + r);
193
+ if (m === s) return h(1);
194
+ if (m === c) return h(7);
195
+ var g = (f = {}, f[a] = t, f[o] = n, f[i] = e, f)[m] || 1, _ = this.$d.getTime() + r * g;
196
+ return T.w(_, this);
197
+ }, _.subtract = function(e, t) {
198
+ return this.add(-1 * e, t);
199
+ }, _.format = function(e) {
200
+ var t = this, n = this.$locale();
201
+ if (!this.isValid()) return n.invalidDate || p;
202
+ var r = e || "YYYY-MM-DDTHH:mm:ssZ", i = T.z(this), a = this.$H, o = this.$m, s = this.$M, c = n.weekdays, l = n.months, u = n.meridiem, d = function(e, n, i, a) {
203
+ return e && (e[n] || e(t, r)) || i[n].slice(0, a);
204
+ }, f = function(e) {
205
+ return T.s(a % 12 || 12, e, "0");
206
+ }, m = u || function(e, t, n) {
207
+ var r = e < 12 ? "AM" : "PM";
208
+ return n ? r.toLowerCase() : r;
209
+ };
210
+ return r.replace(h, (function(e, r) {
211
+ return r || function(e) {
212
+ switch (e) {
213
+ case "YY": return String(t.$y).slice(-2);
214
+ case "YYYY": return T.s(t.$y, 4, "0");
215
+ case "M": return s + 1;
216
+ case "MM": return T.s(s + 1, 2, "0");
217
+ case "MMM": return d(n.monthsShort, s, l, 3);
218
+ case "MMMM": return d(l, s);
219
+ case "D": return t.$D;
220
+ case "DD": return T.s(t.$D, 2, "0");
221
+ case "d": return String(t.$W);
222
+ case "dd": return d(n.weekdaysMin, t.$W, c, 2);
223
+ case "ddd": return d(n.weekdaysShort, t.$W, c, 3);
224
+ case "dddd": return c[t.$W];
225
+ case "H": return String(a);
226
+ case "HH": return T.s(a, 2, "0");
227
+ case "h": return f(1);
228
+ case "hh": return f(2);
229
+ case "a": return m(a, o, !0);
230
+ case "A": return m(a, o, !1);
231
+ case "m": return String(o);
232
+ case "mm": return T.s(o, 2, "0");
233
+ case "s": return String(t.$s);
234
+ case "ss": return T.s(t.$s, 2, "0");
235
+ case "SSS": return T.s(t.$ms, 3, "0");
236
+ case "Z": return i;
237
+ }
238
+ return null;
239
+ }(e) || i.replace(":", "");
240
+ }));
241
+ }, _.utcOffset = function() {
242
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
243
+ }, _.diff = function(r, f, p) {
244
+ var m, h = this, g = T.p(f), _ = w(r), v = (_.utcOffset() - this.utcOffset()) * t, y = this - _, b = function() {
245
+ return T.m(h, _);
246
+ };
247
+ switch (g) {
248
+ case d:
249
+ m = b() / 12;
250
+ break;
251
+ case l:
252
+ m = b();
253
+ break;
254
+ case u:
255
+ m = b() / 3;
256
+ break;
257
+ case c:
258
+ m = (y - v) / 6048e5;
259
+ break;
260
+ case s:
261
+ m = (y - v) / 864e5;
262
+ break;
263
+ case o:
264
+ m = y / n;
265
+ break;
266
+ case a:
267
+ m = y / t;
268
+ break;
269
+ case i:
270
+ m = y / e;
271
+ break;
272
+ default: m = y;
273
+ }
274
+ return p ? m : T.a(m);
275
+ }, _.daysInMonth = function() {
276
+ return this.endOf(l).$D;
277
+ }, _.$locale = function() {
278
+ return b[this.$L];
279
+ }, _.locale = function(e, t) {
280
+ if (!e) return this.$L;
281
+ var n = this.clone(), r = C(e, t, !0);
282
+ return r && (n.$L = r), n;
283
+ }, _.clone = function() {
284
+ return T.w(this.$d, this);
285
+ }, _.toDate = function() {
286
+ return new Date(this.valueOf());
287
+ }, _.toJSON = function() {
288
+ return this.isValid() ? this.toISOString() : null;
289
+ }, _.toISOString = function() {
290
+ return this.$d.toISOString();
291
+ }, _.toString = function() {
292
+ return this.$d.toUTCString();
293
+ }, g;
294
+ }(), D = E.prototype;
295
+ return w.prototype = D, [
296
+ ["$ms", r],
297
+ ["$s", i],
298
+ ["$m", a],
299
+ ["$H", o],
300
+ ["$W", s],
301
+ ["$M", l],
302
+ ["$y", d],
303
+ ["$D", f]
304
+ ].forEach((function(e) {
305
+ D[e[1]] = function(t) {
306
+ return this.$g(t, e[0], e[1]);
307
+ };
308
+ })), w.extend = function(e, t) {
309
+ return e.$i ||= (e(t, E, w), !0), w;
310
+ }, w.locale = C, w.isDayjs = S, w.unix = function(e) {
311
+ return w(1e3 * e);
312
+ }, w.en = b[y], w.Ls = b, w.p = {}, w;
313
+ }));
314
+ })), d = /* @__PURE__ */ e(u(), 1), f = /* @__PURE__ */ new Map(), p = new Set(["en"]);
315
+ async function m(e) {
316
+ let t = e.toLowerCase();
317
+ if (p.has(t)) {
318
+ d.default.locale(t);
319
+ return;
320
+ }
321
+ let n = f.get(t);
322
+ n || (n = h(t), f.set(t, n));
323
+ try {
324
+ await n, p.add(t), d.default.locale(t);
325
+ } catch (e) {
326
+ typeof console < "u" && console.warn(`[ccui] 无法加载 dayjs locale "${t}":`, e);
327
+ } finally {
328
+ f.delete(t);
329
+ }
330
+ }
331
+ async function h(t) {
332
+ switch (t) {
333
+ case "zh-cn":
334
+ await import("./zh-cn-BQE-LNg1.js").then((t) => /* @__PURE__ */ e(t.default, 1));
335
+ break;
336
+ case "en": break;
337
+ case "en-us":
338
+ await import("./en-BG83iZ_P.js").then((t) => /* @__PURE__ */ e(t.default, 1));
339
+ break;
340
+ case "ja":
341
+ case "ja-jp":
342
+ await import("./ja-B-93MQG5.js").then((t) => /* @__PURE__ */ e(t.default, 1));
343
+ break;
344
+ case "ko":
345
+ case "ko-kr":
346
+ await import("./ko-86th3uXt.js").then((t) => /* @__PURE__ */ e(t.default, 1));
347
+ break;
348
+ default: throw Error(`Unsupported dayjs locale: ${t}`);
349
+ }
350
+ }
351
+ //#endregion
18
352
  //#region ../ccui/ui/locale/zh-CN.ts
19
- var s = {
353
+ var g = {
20
354
  locale: "zh-CN",
21
355
  Modal: {
22
356
  okText: "确 定",
@@ -31,7 +365,10 @@ var s = {
31
365
  AutoComplete: { notFoundContent: "暂无数据" },
32
366
  Mentions: { notFoundContent: "暂无数据" },
33
367
  Cascader: { notFoundContent: "暂无数据" },
34
- TreeSelect: { notFoundContent: "暂无数据" },
368
+ TreeSelect: {
369
+ notFoundContent: "暂无数据",
370
+ searchPlaceholder: "搜索"
371
+ },
35
372
  Select: { notFoundContent: "暂无数据" },
36
373
  Pagination: {
37
374
  itemsPerPage: "条/页",
@@ -39,7 +376,8 @@ var s = {
39
376
  page: "页",
40
377
  prevPage: "上一页",
41
378
  nextPage: "下一页",
42
- total: "共 {total} 条"
379
+ total: "共 {total} 条",
380
+ pagination: "分页"
43
381
  },
44
382
  Image: {
45
383
  loading: "加载中",
@@ -88,8 +426,23 @@ var s = {
88
426
  nextYearLabel: "后一年",
89
427
  nextMonthLabel: "下个月",
90
428
  clearLabel: "清除"
429
+ },
430
+ Calendar: {
431
+ weekdaysShort: [
432
+ "日",
433
+ "一",
434
+ "二",
435
+ "三",
436
+ "四",
437
+ "五",
438
+ "六"
439
+ ],
440
+ prevMonthLabel: "上个月",
441
+ nextMonthLabel: "下个月",
442
+ todayLabel: "今天",
443
+ monthFormat: "YYYY 年 M 月"
91
444
  }
92
- }, c = {
445
+ }, _ = {
93
446
  prefixCls: {
94
447
  type: String,
95
448
  default: "ccui"
@@ -114,7 +467,7 @@ var s = {
114
467
  type: String,
115
468
  default: "ccui-icon"
116
469
  }
117
- }, l = Symbol("ccui-config"), u = {
470
+ }, v = Symbol("ccui-config"), y = {
118
471
  "--ccui-control-height": "24px",
119
472
  "--ccui-control-height-lg": "32px",
120
473
  "--ccui-control-height-sm": "16px",
@@ -132,73 +485,75 @@ var s = {
132
485
  "--ccui-margin-xs": "4px",
133
486
  "--ccui-margin-xxs": "0px"
134
487
  };
135
- function d(e) {
136
- if (!e) return s;
488
+ function b(e) {
489
+ if (!e) return g;
137
490
  let t = {
138
- ...s,
491
+ ...g,
139
492
  ...e
140
493
  };
141
- for (let n of Object.keys(s)) typeof s[n] == "object" && s[n] !== null && (t[n] = {
142
- ...s[n],
494
+ for (let n of Object.keys(g)) typeof g[n] == "object" && g[n] !== null && (t[n] = {
495
+ ...g[n],
143
496
  ...e[n]
144
497
  });
145
498
  return t;
146
499
  }
147
- function f() {
148
- return r(l, {
500
+ function x() {
501
+ return a(v, {
149
502
  prefixCls: "ccui",
150
503
  componentSize: "middle",
151
- locale: s,
504
+ locale: g,
152
505
  direction: "ltr",
153
506
  theme: void 0,
154
507
  iconPrefixCls: "ccui-icon"
155
508
  });
156
509
  }
157
- var p = /* @__PURE__ */ n({
510
+ var S = /* @__PURE__ */ i({
158
511
  name: "CConfigProvider",
159
- props: c,
160
- setup(n, { slots: r }) {
161
- let a = o("config-provider");
162
- i(l, e(() => ({
163
- prefixCls: n.prefixCls,
164
- componentSize: n.componentSize,
165
- locale: d(n.locale),
166
- direction: n.direction,
167
- theme: n.theme,
168
- iconPrefixCls: n.iconPrefixCls
169
- })).value);
170
- let s = e(() => {
171
- let e = {};
172
- n.theme?.algorithm === "compact" && Object.assign(e, u);
173
- let t = n.theme?.token;
174
- if (t) for (let r in t) {
175
- let i = `--${n.prefixCls}-${r.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`)}`;
176
- e[i] = String(t[r]);
512
+ props: _,
513
+ setup(e, { slots: t }) {
514
+ let i = l("config-provider"), a = n(() => ({
515
+ prefixCls: e.prefixCls,
516
+ componentSize: e.componentSize,
517
+ locale: b(e.locale),
518
+ direction: e.direction,
519
+ theme: e.theme,
520
+ iconPrefixCls: e.iconPrefixCls
521
+ }));
522
+ o(v, a.value), s(() => a.value.locale?.locale, (e) => {
523
+ e && m(e);
524
+ }, { immediate: !0 });
525
+ let c = n(() => {
526
+ let t = {};
527
+ e.theme?.algorithm === "compact" && Object.assign(t, y);
528
+ let n = e.theme?.token;
529
+ if (n) for (let r in n) {
530
+ let i = `--${e.prefixCls}-${r.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`)}`;
531
+ t[i] = String(n[r]);
177
532
  }
178
- return e;
179
- }), c = e(() => {
180
- let e = [a.b()];
181
- return n.theme?.algorithm === "dark" && e.push("dark"), e.filter(Boolean);
533
+ return t;
534
+ }), u = n(() => {
535
+ let t = [i.b()];
536
+ return e.theme?.algorithm === "dark" && t.push("dark"), t.filter(Boolean);
182
537
  });
183
- return () => t("div", {
184
- class: c.value,
185
- style: s.value,
186
- dir: n.direction
187
- }, [r.default?.()]);
538
+ return () => r("div", {
539
+ class: u.value,
540
+ style: c.value,
541
+ dir: e.direction
542
+ }, [t.default?.()]);
188
543
  }
189
544
  });
190
545
  //#endregion
191
546
  //#region ../ccui/ui/config-provider/index.ts
192
- p.install = function(e) {
193
- e.component(p.name, p);
547
+ S.install = function(e) {
548
+ e.component(S.name, S);
194
549
  };
195
- var m = {
550
+ var C = {
196
551
  title: "ConfigProvider 全局配置",
197
552
  category: "通用",
198
553
  status: "100%",
199
554
  install(e) {
200
- e.component(p.name, p);
555
+ e.component(S.name, S);
201
556
  }
202
557
  };
203
558
  //#endregion
204
- export { p as ConfigProvider, m as default, f as useConfig };
559
+ export { S as ConfigProvider, C as default, u as t, x as useConfig };
@@ -1 +1 @@
1
- (function(e,t){typeof exports==`object`&&typeof module<`u`?t(exports,require(`vue`)):typeof define==`function`&&define.amd?define([`exports`,`vue`],t):(e=typeof globalThis<`u`?globalThis:e||self,t(e.index={},e.Vue))})(this,function(e,t){Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});function n(e,t,n){let r=e;return t&&(r+=`__${t}`),n&&(r+=`--${n}`),r}function r(e,t=!1){let r=t?`.ccui-${e}`:`ccui-${e}`;return{b:()=>n(r),e:e=>e?n(r,e):``,m:e=>e?n(r,``,e):``,em:(e,t)=>e&&t?n(r,e,t):``,is:e=>`is-${e}`}}var i={locale:`zh-CN`,Modal:{okText:`确 定`,cancelText:`取 消`,justOkText:`知道了`},Popconfirm:{okText:`确 定`,cancelText:`取 消`},Empty:{description:`暂无数据`},AutoComplete:{notFoundContent:`暂无数据`},Mentions:{notFoundContent:`暂无数据`},Cascader:{notFoundContent:`暂无数据`},TreeSelect:{notFoundContent:`暂无数据`},Select:{notFoundContent:`暂无数据`},Pagination:{itemsPerPage:`条/页`,jumpTo:`跳至`,page:`页`,prevPage:`上一页`,nextPage:`下一页`,total:`共 {total} 条`},Image:{loading:`加载中`,error:`加载失败`},DatePicker:{placeholder:`请选择日期`,rangePlaceholder:[`开始日期`,`结束日期`],timePlaceholder:`请选择时间`,weekdaysShort:[`日`,`一`,`二`,`三`,`四`,`五`,`六`],panelLabelFormat:`YYYY 年 M 月`,monthNamesShort:[`1 月`,`2 月`,`3 月`,`4 月`,`5 月`,`6 月`,`7 月`,`8 月`,`9 月`,`10 月`,`11 月`,`12 月`],quarterNames:[`一季度`,`二季度`,`三季度`,`四季度`],weekFormat:`{weekYear} 年第 {weekNumber} 周`,weekHeader:`周`,now:`此刻`,ok:`确定`,prevYearLabel:`前一年`,prevMonthLabel:`上个月`,nextYearLabel:`后一年`,nextMonthLabel:`下个月`,clearLabel:`清除`}},a={prefixCls:{type:String,default:`ccui`},componentSize:{type:String,default:`middle`},locale:{type:Object,default:void 0},direction:{type:String,default:`ltr`},theme:{type:Object,default:void 0},iconPrefixCls:{type:String,default:`ccui-icon`}},o=Symbol(`ccui-config`),s={"--ccui-control-height":`24px`,"--ccui-control-height-lg":`32px`,"--ccui-control-height-sm":`16px`,"--ccui-control-height-xs":`12px`,"--ccui-padding":`12px`,"--ccui-padding-lg":`16px`,"--ccui-padding-md":`8px`,"--ccui-padding-sm":`8px`,"--ccui-padding-xs":`4px`,"--ccui-padding-xxs":`0px`,"--ccui-margin":`12px`,"--ccui-margin-lg":`16px`,"--ccui-margin-md":`8px`,"--ccui-margin-sm":`8px`,"--ccui-margin-xs":`4px`,"--ccui-margin-xxs":`0px`};function c(e){if(!e)return i;let t={...i,...e};for(let n of Object.keys(i))typeof i[n]==`object`&&i[n]!==null&&(t[n]={...i[n],...e[n]});return t}function l(){return(0,t.inject)(o,{prefixCls:`ccui`,componentSize:`middle`,locale:i,direction:`ltr`,theme:void 0,iconPrefixCls:`ccui-icon`})}var u=(0,t.defineComponent)({name:`CConfigProvider`,props:a,setup(e,{slots:n}){let i=r(`config-provider`);(0,t.provide)(o,(0,t.computed)(()=>({prefixCls:e.prefixCls,componentSize:e.componentSize,locale:c(e.locale),direction:e.direction,theme:e.theme,iconPrefixCls:e.iconPrefixCls})).value);let a=(0,t.computed)(()=>{let t={};e.theme?.algorithm===`compact`&&Object.assign(t,s);let n=e.theme?.token;if(n)for(let r in n){let i=`--${e.prefixCls}-${r.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}`;t[i]=String(n[r])}return t}),l=(0,t.computed)(()=>{let t=[i.b()];return e.theme?.algorithm===`dark`&&t.push(`dark`),t.filter(Boolean)});return()=>(0,t.createVNode)(`div`,{class:l.value,style:a.value,dir:e.direction},[n.default?.()])}});u.install=function(e){e.component(u.name,u)},e.ConfigProvider=u,e.default={title:`ConfigProvider 全局配置`,category:`通用`,status:`100%`,install(e){e.component(u.name,u)}},e.useConfig=l});
1
+ (function(e,t){typeof exports==`object`&&typeof module<`u`?t(exports,require(`vue`)):typeof define==`function`&&define.amd?define([`exports`,`vue`],t):(e=typeof globalThis<`u`?globalThis:e||self,t(e.index={},e.Vue))})(this,function(e,t){Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),l=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=a(t),l=0,u=c.length,d;l<u;l++)d=c[l],!s.call(e,d)&&d!==n&&r(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(o=i(t,d))||o.enumerable});return e},u=(e,t,i)=>(i=e==null?{}:n(o(e)),l(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e));function d(e,t,n){let r=e;return t&&(r+=`__${t}`),n&&(r+=`--${n}`),r}function f(e,t=!1){let n=t?`.ccui-${e}`:`ccui-${e}`;return{b:()=>d(n),e:e=>e?d(n,e):``,m:e=>e?d(n,``,e):``,em:(e,t)=>e&&t?d(n,e,t):``,is:e=>`is-${e}`}}var p=c(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs=r()})(e,(function(){"use strict";var e=1e3,t=6e4,n=36e5,r=`millisecond`,i=`second`,a=`minute`,o=`hour`,s=`day`,c=`week`,l=`month`,u=`quarter`,d=`year`,f=`date`,p=`Invalid Date`,m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}},_=function(e,t,n){var r=String(e);return!r||r.length>=t?e:``+Array(t+1-r.length).join(n)+e},v={s:_,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?`+`:`-`)+_(r,2,`0`)+`:`+_(i,2,`0`)},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var r=12*(n.year()-t.year())+(n.month()-t.month()),i=t.clone().add(r,l),a=n-i<0,o=t.clone().add(r+(a?-1:1),l);return+(-(r+(n-i)/(a?i-o:o-i))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:l,y:d,w:c,d:s,D:f,h:o,m:a,s:i,ms:r,Q:u}[e]||String(e||``).toLowerCase().replace(/s$/,``)},u:function(e){return e===void 0}},y=`en`,b={};b[y]=g;var x=`$isDayjsObject`,S=function(e){return e instanceof E||!(!e||!e[x])},C=function e(t,n,r){var i;if(!t)return y;if(typeof t==`string`){var a=t.toLowerCase();b[a]&&(i=a),n&&(b[a]=n,i=a);var o=t.split(`-`);if(!i&&o.length>1)return e(o[0])}else{var s=t.name;b[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},w=function(e,t){if(S(e))return e.clone();var n=typeof t==`object`?t:{};return n.date=e,n.args=arguments,new E(n)},T=v;T.l=C,T.i=S,T.w=function(e,t){return w(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var E=function(){function g(e){this.$L=C(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[x]=!0}var _=g.prototype;return _.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(t===null)return new Date(NaN);if(T.u(t))return new Date;if(t instanceof Date)return new Date(t);if(typeof t==`string`&&!/Z$/i.test(t)){var r=t.match(m);if(r){var i=r[2]-1||0,a=(r[7]||`0`).substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(t)}(e),this.init()},_.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},_.$utils=function(){return T},_.isValid=function(){return this.$d.toString()!==p},_.isSame=function(e,t){var n=w(e);return this.startOf(t)<=n&&n<=this.endOf(t)},_.isAfter=function(e,t){return w(e)<this.startOf(t)},_.isBefore=function(e,t){return this.endOf(t)<w(e)},_.$g=function(e,t,n){return T.u(e)?this[t]:this.set(n,e)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(e,t){var n=this,r=!!T.u(t)||t,u=T.p(e),p=function(e,t){var i=T.w(n.$u?Date.UTC(n.$y,t,e):new Date(n.$y,t,e),n);return r?i:i.endOf(s)},m=function(e,t){return T.w(n.toDate()[e].apply(n.toDate(`s`),(r?[0,0,0,0]:[23,59,59,999]).slice(t)),n)},h=this.$W,g=this.$M,_=this.$D,v=`set`+(this.$u?`UTC`:``);switch(u){case d:return r?p(1,0):p(31,11);case l:return r?p(1,g):p(0,g+1);case c:var y=this.$locale().weekStart||0,b=(h<y?h+7:h)-y;return p(r?_-b:_+(6-b),g);case s:case f:return m(v+`Hours`,0);case o:return m(v+`Minutes`,1);case a:return m(v+`Seconds`,2);case i:return m(v+`Milliseconds`,3);default:return this.clone()}},_.endOf=function(e){return this.startOf(e,!1)},_.$set=function(e,t){var n,c=T.p(e),u=`set`+(this.$u?`UTC`:``),p=(n={},n[s]=u+`Date`,n[f]=u+`Date`,n[l]=u+`Month`,n[d]=u+`FullYear`,n[o]=u+`Hours`,n[a]=u+`Minutes`,n[i]=u+`Seconds`,n[r]=u+`Milliseconds`,n)[c],m=c===s?this.$D+(t-this.$W):t;if(c===l||c===d){var h=this.clone().set(f,1);h.$d[p](m),h.init(),this.$d=h.set(f,Math.min(this.$D,h.daysInMonth())).$d}else p&&this.$d[p](m);return this.init(),this},_.set=function(e,t){return this.clone().$set(e,t)},_.get=function(e){return this[T.p(e)]()},_.add=function(r,u){var f,p=this;r=Number(r);var m=T.p(u),h=function(e){var t=w(p);return T.w(t.date(t.date()+Math.round(e*r)),p)};if(m===l)return this.set(l,this.$M+r);if(m===d)return this.set(d,this.$y+r);if(m===s)return h(1);if(m===c)return h(7);var g=(f={},f[a]=t,f[o]=n,f[i]=e,f)[m]||1,_=this.$d.getTime()+r*g;return T.w(_,this)},_.subtract=function(e,t){return this.add(-1*e,t)},_.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||p;var r=e||`YYYY-MM-DDTHH:mm:ssZ`,i=T.z(this),a=this.$H,o=this.$m,s=this.$M,c=n.weekdays,l=n.months,u=n.meridiem,d=function(e,n,i,a){return e&&(e[n]||e(t,r))||i[n].slice(0,a)},f=function(e){return T.s(a%12||12,e,`0`)},m=u||function(e,t,n){var r=e<12?`AM`:`PM`;return n?r.toLowerCase():r};return r.replace(h,(function(e,r){return r||function(e){switch(e){case`YY`:return String(t.$y).slice(-2);case`YYYY`:return T.s(t.$y,4,`0`);case`M`:return s+1;case`MM`:return T.s(s+1,2,`0`);case`MMM`:return d(n.monthsShort,s,l,3);case`MMMM`:return d(l,s);case`D`:return t.$D;case`DD`:return T.s(t.$D,2,`0`);case`d`:return String(t.$W);case`dd`:return d(n.weekdaysMin,t.$W,c,2);case`ddd`:return d(n.weekdaysShort,t.$W,c,3);case`dddd`:return c[t.$W];case`H`:return String(a);case`HH`:return T.s(a,2,`0`);case`h`:return f(1);case`hh`:return f(2);case`a`:return m(a,o,!0);case`A`:return m(a,o,!1);case`m`:return String(o);case`mm`:return T.s(o,2,`0`);case`s`:return String(t.$s);case`ss`:return T.s(t.$s,2,`0`);case`SSS`:return T.s(t.$ms,3,`0`);case`Z`:return i}return null}(e)||i.replace(`:`,``)}))},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(r,f,p){var m,h=this,g=T.p(f),_=w(r),v=(_.utcOffset()-this.utcOffset())*t,y=this-_,b=function(){return T.m(h,_)};switch(g){case d:m=b()/12;break;case l:m=b();break;case u:m=b()/3;break;case c:m=(y-v)/6048e5;break;case s:m=(y-v)/864e5;break;case o:m=y/n;break;case a:m=y/t;break;case i:m=y/e;break;default:m=y}return p?m:T.a(m)},_.daysInMonth=function(){return this.endOf(l).$D},_.$locale=function(){return b[this.$L]},_.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),r=C(e,t,!0);return r&&(n.$L=r),n},_.clone=function(){return T.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},g}(),D=E.prototype;return w.prototype=D,[[`$ms`,r],[`$s`,i],[`$m`,a],[`$H`,o],[`$W`,s],[`$M`,l],[`$y`,d],[`$D`,f]].forEach((function(e){D[e[1]]=function(t){return this.$g(t,e[0],e[1])}})),w.extend=function(e,t){return e.$i||=(e(t,E,w),!0),w},w.locale=C,w.isDayjs=S,w.unix=function(e){return w(1e3*e)},w.en=b[y],w.Ls=b,w.p={},w}))})),m=c(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r(p()):typeof define==`function`&&define.amd?define([`dayjs`],r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_locale_zh_cn=r(n.dayjs)})(e,(function(e){"use strict";function t(e){return e&&typeof e==`object`&&`default`in e?e:{default:e}}var n=t(e),r={name:`zh-cn`,weekdays:`星期日_星期一_星期二_星期三_星期四_星期五_星期六`.split(`_`),weekdaysShort:`周日_周一_周二_周三_周四_周五_周六`.split(`_`),weekdaysMin:`日_一_二_三_四_五_六`.split(`_`),months:`一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月`.split(`_`),monthsShort:`1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月`.split(`_`),ordinal:function(e,t){return t===`W`?e+`周`:e+`日`},weekStart:1,yearStart:4,formats:{LT:`HH:mm`,LTS:`HH:mm:ss`,L:`YYYY/MM/DD`,LL:`YYYY年M月D日`,LLL:`YYYY年M月D日Ah点mm分`,LLLL:`YYYY年M月D日ddddAh点mm分`,l:`YYYY/M/D`,ll:`YYYY年M月D日`,lll:`YYYY年M月D日 HH:mm`,llll:`YYYY年M月D日dddd HH:mm`},relativeTime:{future:`%s内`,past:`%s前`,s:`几秒`,m:`1 分钟`,mm:`%d 分钟`,h:`1 小时`,hh:`%d 小时`,d:`1 天`,dd:`%d 天`,M:`1 个月`,MM:`%d 个月`,y:`1 年`,yy:`%d 年`},meridiem:function(e,t){var n=100*e+t;return n<600?`凌晨`:n<900?`早上`:n<1100?`上午`:n<1300?`中午`:n<1800?`下午`:`晚上`}};return n.default.locale(r,null,!0),r}))})),h=c(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_locale_en=r()})(e,(function(){"use strict";return{name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}}}))})),g=c(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r(p()):typeof define==`function`&&define.amd?define([`dayjs`],r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_locale_ja=r(n.dayjs)})(e,(function(e){"use strict";function t(e){return e&&typeof e==`object`&&`default`in e?e:{default:e}}var n=t(e),r={name:`ja`,weekdays:`日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日`.split(`_`),weekdaysShort:`日_月_火_水_木_金_土`.split(`_`),weekdaysMin:`日_月_火_水_木_金_土`.split(`_`),months:`1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月`.split(`_`),monthsShort:`1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月`.split(`_`),ordinal:function(e){return e+`日`},formats:{LT:`HH:mm`,LTS:`HH:mm:ss`,L:`YYYY/MM/DD`,LL:`YYYY年M月D日`,LLL:`YYYY年M月D日 HH:mm`,LLLL:`YYYY年M月D日 dddd HH:mm`,l:`YYYY/MM/DD`,ll:`YYYY年M月D日`,lll:`YYYY年M月D日 HH:mm`,llll:`YYYY年M月D日(ddd) HH:mm`},meridiem:function(e){return e<12?`午前`:`午後`},relativeTime:{future:`%s後`,past:`%s前`,s:`数秒`,m:`1分`,mm:`%d分`,h:`1時間`,hh:`%d時間`,d:`1日`,dd:`%d日`,M:`1ヶ月`,MM:`%dヶ月`,y:`1年`,yy:`%d年`}};return n.default.locale(r,null,!0),r}))})),_=c(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r(p()):typeof define==`function`&&define.amd?define([`dayjs`],r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_locale_ko=r(n.dayjs)})(e,(function(e){"use strict";function t(e){return e&&typeof e==`object`&&`default`in e?e:{default:e}}var n=t(e),r={name:`ko`,weekdays:`일요일_월요일_화요일_수요일_목요일_금요일_토요일`.split(`_`),weekdaysShort:`일_월_화_수_목_금_토`.split(`_`),weekdaysMin:`일_월_화_수_목_금_토`.split(`_`),months:`1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월`.split(`_`),monthsShort:`1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월`.split(`_`),ordinal:function(e){return e+`일`},formats:{LT:`A h:mm`,LTS:`A h:mm:ss`,L:`YYYY.MM.DD.`,LL:`YYYY년 MMMM D일`,LLL:`YYYY년 MMMM D일 A h:mm`,LLLL:`YYYY년 MMMM D일 dddd A h:mm`,l:`YYYY.MM.DD.`,ll:`YYYY년 MMMM D일`,lll:`YYYY년 MMMM D일 A h:mm`,llll:`YYYY년 MMMM D일 dddd A h:mm`},meridiem:function(e){return e<12?`오전`:`오후`},relativeTime:{future:`%s 후`,past:`%s 전`,s:`몇 초`,m:`1분`,mm:`%d분`,h:`한 시간`,hh:`%d시간`,d:`하루`,dd:`%d일`,M:`한 달`,MM:`%d달`,y:`일 년`,yy:`%d년`}};return n.default.locale(r,null,!0),r}))})),v=u(p(),1),y=new Map,b=new Set([`en`]);async function x(e){let t=e.toLowerCase();if(b.has(t)){v.default.locale(t);return}let n=y.get(t);n||(n=S(t),y.set(t,n));try{await n,b.add(t),v.default.locale(t)}catch(e){typeof console<`u`&&console.warn(`[ccui] 无法加载 dayjs locale "${t}":`,e)}finally{y.delete(t)}}async function S(e){switch(e){case`zh-cn`:await Promise.resolve().then(()=>u(m(),1));break;case`en`:break;case`en-us`:await Promise.resolve().then(()=>u(h(),1));break;case`ja`:case`ja-jp`:await Promise.resolve().then(()=>u(g(),1));break;case`ko`:case`ko-kr`:await Promise.resolve().then(()=>u(_(),1));break;default:throw Error(`Unsupported dayjs locale: ${e}`)}}var C={locale:`zh-CN`,Modal:{okText:`确 定`,cancelText:`取 消`,justOkText:`知道了`},Popconfirm:{okText:`确 定`,cancelText:`取 消`},Empty:{description:`暂无数据`},AutoComplete:{notFoundContent:`暂无数据`},Mentions:{notFoundContent:`暂无数据`},Cascader:{notFoundContent:`暂无数据`},TreeSelect:{notFoundContent:`暂无数据`,searchPlaceholder:`搜索`},Select:{notFoundContent:`暂无数据`},Pagination:{itemsPerPage:`条/页`,jumpTo:`跳至`,page:`页`,prevPage:`上一页`,nextPage:`下一页`,total:`共 {total} 条`,pagination:`分页`},Image:{loading:`加载中`,error:`加载失败`},DatePicker:{placeholder:`请选择日期`,rangePlaceholder:[`开始日期`,`结束日期`],timePlaceholder:`请选择时间`,weekdaysShort:[`日`,`一`,`二`,`三`,`四`,`五`,`六`],panelLabelFormat:`YYYY 年 M 月`,monthNamesShort:[`1 月`,`2 月`,`3 月`,`4 月`,`5 月`,`6 月`,`7 月`,`8 月`,`9 月`,`10 月`,`11 月`,`12 月`],quarterNames:[`一季度`,`二季度`,`三季度`,`四季度`],weekFormat:`{weekYear} 年第 {weekNumber} 周`,weekHeader:`周`,now:`此刻`,ok:`确定`,prevYearLabel:`前一年`,prevMonthLabel:`上个月`,nextYearLabel:`后一年`,nextMonthLabel:`下个月`,clearLabel:`清除`},Calendar:{weekdaysShort:[`日`,`一`,`二`,`三`,`四`,`五`,`六`],prevMonthLabel:`上个月`,nextMonthLabel:`下个月`,todayLabel:`今天`,monthFormat:`YYYY 年 M 月`}},w={prefixCls:{type:String,default:`ccui`},componentSize:{type:String,default:`middle`},locale:{type:Object,default:void 0},direction:{type:String,default:`ltr`},theme:{type:Object,default:void 0},iconPrefixCls:{type:String,default:`ccui-icon`}},T=Symbol(`ccui-config`),E={"--ccui-control-height":`24px`,"--ccui-control-height-lg":`32px`,"--ccui-control-height-sm":`16px`,"--ccui-control-height-xs":`12px`,"--ccui-padding":`12px`,"--ccui-padding-lg":`16px`,"--ccui-padding-md":`8px`,"--ccui-padding-sm":`8px`,"--ccui-padding-xs":`4px`,"--ccui-padding-xxs":`0px`,"--ccui-margin":`12px`,"--ccui-margin-lg":`16px`,"--ccui-margin-md":`8px`,"--ccui-margin-sm":`8px`,"--ccui-margin-xs":`4px`,"--ccui-margin-xxs":`0px`};function D(e){if(!e)return C;let t={...C,...e};for(let n of Object.keys(C))typeof C[n]==`object`&&C[n]!==null&&(t[n]={...C[n],...e[n]});return t}function O(){return(0,t.inject)(T,{prefixCls:`ccui`,componentSize:`middle`,locale:C,direction:`ltr`,theme:void 0,iconPrefixCls:`ccui-icon`})}var k=(0,t.defineComponent)({name:`CConfigProvider`,props:w,setup(e,{slots:n}){let r=f(`config-provider`),i=(0,t.computed)(()=>({prefixCls:e.prefixCls,componentSize:e.componentSize,locale:D(e.locale),direction:e.direction,theme:e.theme,iconPrefixCls:e.iconPrefixCls}));(0,t.provide)(T,i.value),(0,t.watch)(()=>i.value.locale?.locale,e=>{e&&x(e)},{immediate:!0});let a=(0,t.computed)(()=>{let t={};e.theme?.algorithm===`compact`&&Object.assign(t,E);let n=e.theme?.token;if(n)for(let r in n){let i=`--${e.prefixCls}-${r.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}`;t[i]=String(n[r])}return t}),o=(0,t.computed)(()=>{let t=[r.b()];return e.theme?.algorithm===`dark`&&t.push(`dark`),t.filter(Boolean)});return()=>(0,t.createVNode)(`div`,{class:o.value,style:a.value,dir:e.direction},[n.default?.()])}});k.install=function(e){e.component(k.name,k)},e.ConfigProvider=k,e.default={title:`ConfigProvider 全局配置`,category:`通用`,status:`100%`,install(e){e.component(k.name,k)}},e.useConfig=O});
@@ -0,0 +1,56 @@
1
+ import { t as e } from "./chunk-C_CI6nMA.js";
2
+ import { t } from "./index.es.js";
3
+ //#region ../../node_modules/.pnpm/dayjs@1.11.19/node_modules/dayjs/locale/ja.js
4
+ var n = /* @__PURE__ */ e(((e, n) => {
5
+ (function(r, i) {
6
+ typeof e == "object" && n !== void 0 ? n.exports = i(t()) : typeof define == "function" && define.amd ? define(["dayjs"], i) : (r = typeof globalThis < "u" ? globalThis : r || self).dayjs_locale_ja = i(r.dayjs);
7
+ })(e, (function(e) {
8
+ function t(e) {
9
+ return e && typeof e == "object" && "default" in e ? e : { default: e };
10
+ }
11
+ var n = t(e), r = {
12
+ name: "ja",
13
+ weekdays: "日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),
14
+ weekdaysShort: "日_月_火_水_木_金_土".split("_"),
15
+ weekdaysMin: "日_月_火_水_木_金_土".split("_"),
16
+ months: "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),
17
+ monthsShort: "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),
18
+ ordinal: function(e) {
19
+ return e + "日";
20
+ },
21
+ formats: {
22
+ LT: "HH:mm",
23
+ LTS: "HH:mm:ss",
24
+ L: "YYYY/MM/DD",
25
+ LL: "YYYY年M月D日",
26
+ LLL: "YYYY年M月D日 HH:mm",
27
+ LLLL: "YYYY年M月D日 dddd HH:mm",
28
+ l: "YYYY/MM/DD",
29
+ ll: "YYYY年M月D日",
30
+ lll: "YYYY年M月D日 HH:mm",
31
+ llll: "YYYY年M月D日(ddd) HH:mm"
32
+ },
33
+ meridiem: function(e) {
34
+ return e < 12 ? "午前" : "午後";
35
+ },
36
+ relativeTime: {
37
+ future: "%s後",
38
+ past: "%s前",
39
+ s: "数秒",
40
+ m: "1分",
41
+ mm: "%d分",
42
+ h: "1時間",
43
+ hh: "%d時間",
44
+ d: "1日",
45
+ dd: "%d日",
46
+ M: "1ヶ月",
47
+ MM: "%dヶ月",
48
+ y: "1年",
49
+ yy: "%d年"
50
+ }
51
+ };
52
+ return n.default.locale(r, null, !0), r;
53
+ }));
54
+ }));
55
+ //#endregion
56
+ export default n();