@univerjs/design 0.7.0 → 0.8.0-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 (55) hide show
  1. package/lib/cjs/index.js +108 -77
  2. package/lib/cjs/locale/en-US.js +1 -1
  3. package/lib/cjs/locale/fa-IR.js +1 -1
  4. package/lib/cjs/locale/fr-FR.js +1 -1
  5. package/lib/cjs/locale/ru-RU.js +1 -1
  6. package/lib/cjs/locale/vi-VN.js +1 -1
  7. package/lib/cjs/locale/zh-CN.js +1 -1
  8. package/lib/cjs/locale/zh-TW.js +1 -1
  9. package/lib/es/index.js +9431 -9257
  10. package/lib/es/locale/en-US.js +24 -19
  11. package/lib/es/locale/fa-IR.js +17 -12
  12. package/lib/es/locale/fr-FR.js +22 -17
  13. package/lib/es/locale/ru-RU.js +145 -140
  14. package/lib/es/locale/vi-VN.js +88 -83
  15. package/lib/es/locale/zh-CN.js +17 -12
  16. package/lib/es/locale/zh-TW.js +25 -20
  17. package/lib/index.css +1 -1
  18. package/lib/index.js +9431 -9257
  19. package/lib/locale/en-US.js +24 -19
  20. package/lib/locale/fa-IR.js +17 -12
  21. package/lib/locale/fr-FR.js +22 -17
  22. package/lib/locale/ru-RU.js +145 -140
  23. package/lib/locale/vi-VN.js +88 -83
  24. package/lib/locale/zh-CN.js +17 -12
  25. package/lib/locale/zh-TW.js +25 -20
  26. package/lib/types/components/avatar/Avatar.d.ts +7 -9
  27. package/lib/types/components/color-picker/AlphaSlider.d.ts +16 -2
  28. package/lib/types/components/color-picker/ColorInput.d.ts +2 -5
  29. package/lib/types/components/color-picker/ColorPicker.d.ts +1 -2
  30. package/lib/types/components/color-picker/color-conversion.d.ts +0 -2
  31. package/lib/types/components/config-provider/ConfigProvider.d.ts +3 -3
  32. package/lib/types/components/confirm/Confirm.d.ts +2 -2
  33. package/lib/types/components/dropdown/Dropdown.d.ts +2 -2
  34. package/lib/types/components/dropdown-menu/DropdownMenu.d.ts +9 -1
  35. package/lib/types/components/hover-card/HoverCard.d.ts +15 -0
  36. package/lib/types/components/hover-card/HoverCard.stories.d.ts +7 -0
  37. package/lib/types/components/hover-card/HoverCardPrimitive.d.ts +20 -0
  38. package/lib/types/components/input/Input.d.ts +4 -4
  39. package/lib/types/components/input-number/InputNumber.d.ts +6 -5
  40. package/lib/types/components/menu/Menu.d.ts +4 -4
  41. package/lib/types/components/radio/Radio.d.ts +2 -2
  42. package/lib/types/components/select/Select.d.ts +1 -0
  43. package/lib/types/helper/class-utilities.d.ts +3 -2
  44. package/lib/types/index.d.ts +3 -2
  45. package/lib/types/locale/interface.d.ts +1 -0
  46. package/lib/umd/index.js +108 -77
  47. package/lib/umd/locale/en-US.js +1 -1
  48. package/lib/umd/locale/fa-IR.js +1 -1
  49. package/lib/umd/locale/fr-FR.js +1 -1
  50. package/lib/umd/locale/ru-RU.js +1 -1
  51. package/lib/umd/locale/vi-VN.js +1 -1
  52. package/lib/umd/locale/zh-CN.js +1 -1
  53. package/lib/umd/locale/zh-TW.js +1 -1
  54. package/package.json +13 -12
  55. package/lib/types/components/dropdown/index.d.ts +0 -16
@@ -1,8 +1,8 @@
1
- function g(e) {
1
+ function M(e) {
2
2
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
3
3
  }
4
4
  var c = { exports: {} }, w = c.exports, _;
5
- function Y() {
5
+ function C() {
6
6
  return _ || (_ = 1, function(e, n) {
7
7
  (function(t, r) {
8
8
  e.exports = r();
@@ -14,11 +14,11 @@ function Y() {
14
14
  });
15
15
  }(c)), c.exports;
16
16
  }
17
- var C = Y();
18
- const R = /* @__PURE__ */ g(C);
19
- var s = {}, f = { exports: {} }, b;
20
- function k() {
21
- return b || (b = 1, function(e) {
17
+ var Y = C();
18
+ const k = /* @__PURE__ */ M(Y);
19
+ var s = {}, f = { exports: {} }, m;
20
+ function R() {
21
+ return m || (m = 1, function(e) {
22
22
  function n(t) {
23
23
  return t && t.__esModule ? t : {
24
24
  default: t
@@ -27,9 +27,9 @@ function k() {
27
27
  e.exports = n, e.exports.__esModule = !0, e.exports.default = e.exports;
28
28
  }(f)), f.exports;
29
29
  }
30
- var y = { exports: {} }, l = { exports: {} }, d = { exports: {} }, x = { exports: {} }, m;
31
- function M() {
32
- return m || (m = 1, function(e) {
30
+ var y = { exports: {} }, l = { exports: {} }, d = { exports: {} }, x = { exports: {} }, b;
31
+ function g() {
32
+ return b || (b = 1, function(e) {
33
33
  function n(t) {
34
34
  "@babel/helpers - typeof";
35
35
  return e.exports = n = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(r) {
@@ -41,10 +41,10 @@ function M() {
41
41
  e.exports = n, e.exports.__esModule = !0, e.exports.default = e.exports;
42
42
  }(x)), x.exports;
43
43
  }
44
- var v = { exports: {} }, h;
44
+ var v = { exports: {} }, P;
45
45
  function E() {
46
- return h || (h = 1, function(e) {
47
- var n = M().default;
46
+ return P || (P = 1, function(e) {
47
+ var n = g().default;
48
48
  function t(r, o) {
49
49
  if (n(r) != "object" || !r) return r;
50
50
  var a = r[Symbol.toPrimitive];
@@ -58,10 +58,10 @@ function E() {
58
58
  e.exports = t, e.exports.__esModule = !0, e.exports.default = e.exports;
59
59
  }(v)), v.exports;
60
60
  }
61
- var P;
61
+ var h;
62
62
  function T() {
63
- return P || (P = 1, function(e) {
64
- var n = M().default, t = E();
63
+ return h || (h = 1, function(e) {
64
+ var n = g().default, t = E();
65
65
  function r(o) {
66
66
  var a = t(o, "string");
67
67
  return n(a) == "symbol" ? a : a + "";
@@ -127,7 +127,7 @@ var q;
127
127
  function K() {
128
128
  if (q) return s;
129
129
  q = 1;
130
- var e = k().default;
130
+ var e = R().default;
131
131
  Object.defineProperty(s, "__esModule", {
132
132
  value: !0
133
133
  }), s.default = void 0;
@@ -161,14 +161,14 @@ function K() {
161
161
  return s.default = r, s;
162
162
  }
163
163
  var L = K();
164
- const A = /* @__PURE__ */ g(L), J = {
164
+ const A = /* @__PURE__ */ M(L), J = {
165
165
  design: {
166
166
  Confirm: {
167
167
  cancel: "cancel",
168
168
  confirm: "ok"
169
169
  },
170
170
  Picker: {
171
- ...R,
171
+ ...k,
172
172
  ...A
173
173
  },
174
174
  CascaderList: {
@@ -176,6 +176,11 @@ const A = /* @__PURE__ */ g(L), J = {
176
176
  },
177
177
  Select: {
178
178
  empty: "None"
179
+ },
180
+ ColorPicker: {
181
+ more: "More Colors",
182
+ cancel: "cancel",
183
+ confirm: "ok"
179
184
  }
180
185
  }
181
186
  };
@@ -16,9 +16,9 @@ function Y() {
16
16
  }
17
17
  var C = Y();
18
18
  const R = /* @__PURE__ */ g(C);
19
- var s = {}, f = { exports: {} }, b;
20
- function E() {
21
- return b || (b = 1, function(e) {
19
+ var s = {}, f = { exports: {} }, m;
20
+ function k() {
21
+ return m || (m = 1, function(e) {
22
22
  function n(t) {
23
23
  return t && t.__esModule ? t : {
24
24
  default: t
@@ -27,9 +27,9 @@ function E() {
27
27
  e.exports = n, e.exports.__esModule = !0, e.exports.default = e.exports;
28
28
  }(f)), f.exports;
29
29
  }
30
- var y = { exports: {} }, l = { exports: {} }, d = { exports: {} }, x = { exports: {} }, m;
30
+ var y = { exports: {} }, l = { exports: {} }, d = { exports: {} }, x = { exports: {} }, b;
31
31
  function M() {
32
- return m || (m = 1, function(e) {
32
+ return b || (b = 1, function(e) {
33
33
  function n(t) {
34
34
  "@babel/helpers - typeof";
35
35
  return e.exports = n = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(r) {
@@ -41,9 +41,9 @@ function M() {
41
41
  e.exports = n, e.exports.__esModule = !0, e.exports.default = e.exports;
42
42
  }(x)), x.exports;
43
43
  }
44
- var v = { exports: {} }, h;
45
- function k() {
46
- return h || (h = 1, function(e) {
44
+ var v = { exports: {} }, P;
45
+ function E() {
46
+ return P || (P = 1, function(e) {
47
47
  var n = M().default;
48
48
  function t(r, o) {
49
49
  if (n(r) != "object" || !r) return r;
@@ -58,10 +58,10 @@ function k() {
58
58
  e.exports = t, e.exports.__esModule = !0, e.exports.default = e.exports;
59
59
  }(v)), v.exports;
60
60
  }
61
- var P;
61
+ var h;
62
62
  function T() {
63
- return P || (P = 1, function(e) {
64
- var n = M().default, t = k();
63
+ return h || (h = 1, function(e) {
64
+ var n = M().default, t = E();
65
65
  function r(o) {
66
66
  var a = t(o, "string");
67
67
  return n(a) == "symbol" ? a : a + "";
@@ -127,7 +127,7 @@ var q;
127
127
  function L() {
128
128
  if (q) return s;
129
129
  q = 1;
130
- var e = E().default;
130
+ var e = k().default;
131
131
  Object.defineProperty(s, "__esModule", {
132
132
  value: !0
133
133
  }), s.default = void 0;
@@ -176,6 +176,11 @@ const A = /* @__PURE__ */ g(N), J = {
176
176
  },
177
177
  Select: {
178
178
  empty: "هیچ‌کدام"
179
+ },
180
+ ColorPicker: {
181
+ more: "رنگ‌های بیشتر",
182
+ cancel: "لغو",
183
+ confirm: "باشه"
179
184
  }
180
185
  }
181
186
  };
@@ -7,7 +7,7 @@ function $e() {
7
7
  (function(l, a) {
8
8
  i.exports = a();
9
9
  })(_e, function() {
10
- var l = 1e3, a = 6e4, h = 36e5, p = "millisecond", c = "second", $ = "minute", S = "hour", g = "day", C = "week", b = "month", G = "quarter", O = "year", q = "date", X = "Invalid Date", he = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, me = /\[([^\]]+)]|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, ye = { 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(u) {
10
+ var l = 1e3, a = 6e4, h = 36e5, p = "millisecond", c = "second", $ = "minute", S = "hour", g = "day", C = "week", b = "month", G = "quarter", O = "year", k = "date", X = "Invalid Date", he = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, me = /\[([^\]]+)]|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, ye = { 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(u) {
11
11
  var r = ["th", "st", "nd", "rd"], e = u % 100;
12
12
  return "[" + u + (r[(e - 20) % 10] || r[e] || r[0]) + "]";
13
13
  } }, z = function(u, r, e) {
@@ -23,7 +23,7 @@ function $e() {
23
23
  }, a: function(u) {
24
24
  return u < 0 ? Math.ceil(u) || 0 : Math.floor(u);
25
25
  }, p: function(u) {
26
- return { M: b, y: O, w: C, d: g, D: q, h: S, m: $, s: c, ms: p, Q: G }[u] || String(u || "").toLowerCase().replace(/s$/, "");
26
+ return { M: b, y: O, w: C, d: g, D: k, h: S, m: $, s: c, ms: p, Q: G }[u] || String(u || "").toLowerCase().replace(/s$/, "");
27
27
  }, u: function(u) {
28
28
  return u === void 0;
29
29
  } }, L = "en", w = {};
@@ -97,7 +97,7 @@ function $e() {
97
97
  return s ? j : j.endOf(g);
98
98
  }, m = function(P, x) {
99
99
  return f.w(t.toDate()[P].apply(t.toDate("s"), (s ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(x)), t);
100
- }, _ = this.$W, M = this.$M, D = this.$D, k = "set" + (this.$u ? "UTC" : "");
100
+ }, _ = this.$W, M = this.$M, D = this.$D, q = "set" + (this.$u ? "UTC" : "");
101
101
  switch (o) {
102
102
  case O:
103
103
  return s ? d(1, 0) : d(31, 11);
@@ -107,24 +107,24 @@ function $e() {
107
107
  var Y = this.$locale().weekStart || 0, F = (_ < Y ? _ + 7 : _) - Y;
108
108
  return d(s ? D - F : D + (6 - F), M);
109
109
  case g:
110
- case q:
111
- return m(k + "Hours", 0);
110
+ case k:
111
+ return m(q + "Hours", 0);
112
112
  case S:
113
- return m(k + "Minutes", 1);
113
+ return m(q + "Minutes", 1);
114
114
  case $:
115
- return m(k + "Seconds", 2);
115
+ return m(q + "Seconds", 2);
116
116
  case c:
117
- return m(k + "Milliseconds", 3);
117
+ return m(q + "Milliseconds", 3);
118
118
  default:
119
119
  return this.clone();
120
120
  }
121
121
  }, r.endOf = function(e) {
122
122
  return this.startOf(e, !1);
123
123
  }, r.$set = function(e, n) {
124
- var t, s = f.p(e), o = "set" + (this.$u ? "UTC" : ""), d = (t = {}, t[g] = o + "Date", t[q] = o + "Date", t[b] = o + "Month", t[O] = o + "FullYear", t[S] = o + "Hours", t[$] = o + "Minutes", t[c] = o + "Seconds", t[p] = o + "Milliseconds", t)[s], m = s === g ? this.$D + (n - this.$W) : n;
124
+ var t, s = f.p(e), o = "set" + (this.$u ? "UTC" : ""), d = (t = {}, t[g] = o + "Date", t[k] = o + "Date", t[b] = o + "Month", t[O] = o + "FullYear", t[S] = o + "Hours", t[$] = o + "Minutes", t[c] = o + "Seconds", t[p] = o + "Milliseconds", t)[s], m = s === g ? this.$D + (n - this.$W) : n;
125
125
  if (s === b || s === O) {
126
- var _ = this.clone().set(q, 1);
127
- _.$d[d](m), _.init(), this.$d = _.set(q, Math.min(this.$D, _.daysInMonth())).$d;
126
+ var _ = this.clone().set(k, 1);
127
+ _.$d[d](m), _.init(), this.$d = _.set(k, Math.min(this.$D, _.daysInMonth())).$d;
128
128
  } else d && this.$d[d](m);
129
129
  return this.init(), this;
130
130
  }, r.set = function(e, n) {
@@ -149,11 +149,11 @@ function $e() {
149
149
  }, r.format = function(e) {
150
150
  var n = this, t = this.$locale();
151
151
  if (!this.isValid()) return t.invalidDate || X;
152
- var s = e || "YYYY-MM-DDTHH:mm:ssZ", o = f.z(this), d = this.$H, m = this.$m, _ = this.$M, M = t.weekdays, D = t.months, k = t.meridiem, Y = function(x, j, R, I) {
152
+ var s = e || "YYYY-MM-DDTHH:mm:ssZ", o = f.z(this), d = this.$H, m = this.$m, _ = this.$M, M = t.weekdays, D = t.months, q = t.meridiem, Y = function(x, j, R, I) {
153
153
  return x && (x[j] || x(n, s)) || R[j].slice(0, I);
154
154
  }, F = function(x) {
155
155
  return f.s(d % 12 || 12, x, "0");
156
- }, P = k || function(x, j, R) {
156
+ }, P = q || function(x, j, R) {
157
157
  var I = x < 12 ? "AM" : "PM";
158
158
  return R ? I.toLowerCase() : I;
159
159
  };
@@ -267,7 +267,7 @@ function $e() {
267
267
  return this.$d.toUTCString();
268
268
  }, u;
269
269
  }(), te = W.prototype;
270
- return v.prototype = te, [["$ms", p], ["$s", c], ["$m", $], ["$H", S], ["$W", g], ["$M", b], ["$y", O], ["$D", q]].forEach(function(u) {
270
+ return v.prototype = te, [["$ms", p], ["$s", c], ["$m", $], ["$H", S], ["$W", g], ["$M", b], ["$y", O], ["$D", k]].forEach(function(u) {
271
271
  te[u[1]] = function(r) {
272
272
  return this.$g(r, u[0], u[1]);
273
273
  };
@@ -441,8 +441,8 @@ function Pe() {
441
441
  });
442
442
  return T.default = a, T;
443
443
  }
444
- var qe = Pe();
445
- const ke = /* @__PURE__ */ le(qe), Le = {
444
+ var ke = Pe();
445
+ const qe = /* @__PURE__ */ le(ke), Le = {
446
446
  design: {
447
447
  Confirm: {
448
448
  cancel: "annuler",
@@ -450,13 +450,18 @@ const ke = /* @__PURE__ */ le(qe), Le = {
450
450
  },
451
451
  Picker: {
452
452
  ...be,
453
- ...ke
453
+ ...qe
454
454
  },
455
455
  CascaderList: {
456
456
  empty: "Aucun"
457
457
  },
458
458
  Select: {
459
459
  empty: "Aucun"
460
+ },
461
+ ColorPicker: {
462
+ more: "Plus de couleurs",
463
+ cancel: "annuler",
464
+ confirm: "ok"
460
465
  }
461
466
  }
462
467
  };