gasp-components 1.0.10 → 1.0.12

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 (86) hide show
  1. package/dist/UploadOutlined-9WKjHsqa.js +878 -0
  2. package/dist/components/ag-grid-table/index.js +57877 -38314
  3. package/dist/components/button/index.js +18 -18
  4. package/dist/components/checklist/checklist-item.js +3 -3
  5. package/dist/components/checklist/index.js +5 -5
  6. package/dist/components/date-picker/index.js +9 -5022
  7. package/dist/components/dragger/index.js +28 -28
  8. package/dist/components/dropdown/index.js +10 -11
  9. package/dist/components/form/index.js +8 -9
  10. package/dist/components/form-item/index.js +10 -10
  11. package/dist/components/input/index.js +8 -8
  12. package/dist/components/modal/index.js +18 -20
  13. package/dist/components/password-input/index.js +2 -2
  14. package/dist/components/progress/index.js +16 -18
  15. package/dist/components/progress-circle/index.js +3 -3
  16. package/dist/components/radio-button/index.js +8 -8
  17. package/dist/components/result-popup/index.js +13 -14
  18. package/dist/components/select/index.js +1 -1
  19. package/dist/components/side-menu/index.js +2 -2
  20. package/dist/components/side-menu/menu-item.js +4 -6
  21. package/dist/components/steps/index.js +9 -9
  22. package/dist/components/table/index.js +16 -9298
  23. package/dist/components/tabs/index.js +10 -10
  24. package/dist/components/tabs/tab.js +7 -8
  25. package/dist/components/tag/index.js +9 -258
  26. package/dist/components/timeline-horizontal/index.js +7 -7
  27. package/dist/components/upload/index.js +62 -77
  28. package/dist/index-WlPrqxgY.js +87 -0
  29. package/dist/main.js +69 -457
  30. package/package.json +1 -1
  31. package/dist/CheckCircleFilled-xt-0R96Z.js +0 -16
  32. package/dist/CheckOutlined-EgxCAgj_.js +0 -16
  33. package/dist/CloseCircleFilled-bIgIULWb.js +0 -16
  34. package/dist/CloseOutlined-Q3kC3EZS.js +0 -16
  35. package/dist/Compact-fdEKV_mF.js +0 -180
  36. package/dist/ExclamationCircleFilled-XzDBEGmA.js +0 -16
  37. package/dist/KeyCode-qFRXB1-n.js +0 -517
  38. package/dist/LoadingOutlined-6Ipqn0og.js +0 -16
  39. package/dist/Overflow-JFdXKgCr.js +0 -231
  40. package/dist/PurePanel-hLGnXbul.js +0 -60
  41. package/dist/SearchOutlined-rJTFGXUi.js +0 -16
  42. package/dist/TextArea-n3dknzTq.js +0 -716
  43. package/dist/UploadOutlined-D8jfLEgv.js +0 -27
  44. package/dist/asyncToGenerator-t4sKr8R4.js +0 -340
  45. package/dist/button-LN5ZDad8.js +0 -819
  46. package/dist/collapse-ilv4Tji1.js +0 -20
  47. package/dist/colors-opGg9oSz.js +0 -25
  48. package/dist/compact-item-jjuVmDBH.js +0 -61
  49. package/dist/context-h3WSVDPz.js +0 -2087
  50. package/dist/createFormattedComponent-FcpICAm8.js +0 -3260
  51. package/dist/index--6VfGMUo.js +0 -402
  52. package/dist/index-0mpuHoS5.js +0 -996
  53. package/dist/index-1KQbTQJ2.js +0 -4405
  54. package/dist/index-5Uo03BMk.js +0 -681
  55. package/dist/index-BFgxz47K.js +0 -89
  56. package/dist/index-D3LMPWyJ.js +0 -1437
  57. package/dist/index-DVS_nWxv.js +0 -3026
  58. package/dist/index-ELHBhuK9.js +0 -100
  59. package/dist/index-Fn8q8B3V.js +0 -107
  60. package/dist/index-GgkQrebz.js +0 -950
  61. package/dist/index-L-MzVDcK.js +0 -616
  62. package/dist/index-M3WnMjiA.js +0 -230
  63. package/dist/index-NQd_zMf0.js +0 -69
  64. package/dist/index-ZT64Ec6u.js +0 -267
  65. package/dist/index-aawDqn9q.js +0 -3337
  66. package/dist/index-k04G4nlS.js +0 -1416
  67. package/dist/index-s3u4YBl4.js +0 -8
  68. package/dist/index-vtDVJV8q.js +0 -19571
  69. package/dist/isVisible-Qi9l15Ty.js +0 -232
  70. package/dist/motion-0ToOu81j.js +0 -226
  71. package/dist/motion-NQme0FJ_.js +0 -32
  72. package/dist/omit-ylWA0ZLZ.js +0 -10
  73. package/dist/pickAttrs-zaQzRTqh.js +0 -42
  74. package/dist/progress-a1_pwKVT.js +0 -722
  75. package/dist/reactNode-R20zZQk1.js +0 -18
  76. package/dist/responsiveObserver-V1_1G14X.js +0 -71
  77. package/dist/roundedArrow-p1Pmd9av.js +0 -64
  78. package/dist/row-sPFiFm0C.js +0 -230
  79. package/dist/slide-mFXPRHku.js +0 -265
  80. package/dist/styleChecker-pZ3k2IiY.js +0 -37
  81. package/dist/useCSSVarCls-GwZT_WiF.js +0 -9
  82. package/dist/useClosable-4G12n4Bp.js +0 -15
  83. package/dist/useLocale-eThlLZJw.js +0 -16
  84. package/dist/useMergedState-qUafLuUa.js +0 -23
  85. package/dist/useVariants-s0IcneBD.js +0 -25
  86. package/dist/zoom-Ps8y0jNW.js +0 -174
@@ -1,231 +0,0 @@
1
- import { x as A, e as p, _ as b, y as Qe, b as R, z as Ze } from "./index-1KQbTQJ2.js";
2
- import * as a from "react";
3
- import et, { useState as fe, useMemo as ge, useCallback as we } from "react";
4
- import { c as oe } from "./index-NQd_zMf0.js";
5
- import { R as Ie } from "./index--6VfGMUo.js";
6
- import { u as tt } from "./isVisible-Qi9l15Ty.js";
7
- import { r as rt } from "./index-vtDVJV8q.js";
8
- var at = ["prefixCls", "invalidate", "item", "renderItem", "responsive", "responsiveDisabled", "registerSize", "itemKey", "className", "style", "children", "display", "order", "component"], x = void 0;
9
- function nt(e, s) {
10
- var l = e.prefixCls, f = e.invalidate, o = e.item, n = e.renderItem, u = e.responsive, E = e.responsiveDisabled, c = e.registerSize, C = e.itemKey, g = e.className, H = e.style, Y = e.children, q = e.display, v = e.order, O = e.component, z = O === void 0 ? "div" : O, P = A(e, at), m = u && !q;
11
- function $(S) {
12
- c(C, S);
13
- }
14
- a.useEffect(function() {
15
- return function() {
16
- $(null);
17
- };
18
- }, []);
19
- var J = n && o !== x ? n(o) : Y, w;
20
- f || (w = {
21
- opacity: m ? 0 : 1,
22
- height: m ? 0 : x,
23
- overflowY: m ? "hidden" : x,
24
- order: u ? v : x,
25
- pointerEvents: m ? "none" : x,
26
- position: m ? "absolute" : x
27
- });
28
- var V = {};
29
- m && (V["aria-hidden"] = !0);
30
- var _ = /* @__PURE__ */ a.createElement(z, p({
31
- className: oe(!f && l, g),
32
- style: b(b({}, w), H)
33
- }, V, P, {
34
- ref: s
35
- }), J);
36
- return u && (_ = /* @__PURE__ */ a.createElement(Ie, {
37
- onResize: function(Q) {
38
- var k = Q.offsetWidth;
39
- $(k);
40
- },
41
- disabled: E
42
- }, _)), _;
43
- }
44
- var K = /* @__PURE__ */ a.forwardRef(nt);
45
- K.displayName = "Item";
46
- function it(e) {
47
- if (typeof MessageChannel > "u")
48
- Qe(e);
49
- else {
50
- var s = new MessageChannel();
51
- s.port1.onmessage = function() {
52
- return e();
53
- }, s.port2.postMessage(void 0);
54
- }
55
- }
56
- function st() {
57
- var e = a.useRef(null), s = function(f) {
58
- e.current || (e.current = [], it(function() {
59
- rt.unstable_batchedUpdates(function() {
60
- e.current.forEach(function(o) {
61
- o();
62
- }), e.current = null;
63
- });
64
- })), e.current.push(f);
65
- };
66
- return s;
67
- }
68
- function M(e, s) {
69
- var l = a.useState(s), f = R(l, 2), o = f[0], n = f[1], u = tt(function(E) {
70
- e(function() {
71
- n(E);
72
- });
73
- });
74
- return [o, u];
75
- }
76
- var X = /* @__PURE__ */ et.createContext(null), ft = ["component"], ot = ["className"], lt = ["className"], ut = function(s, l) {
77
- var f = a.useContext(X);
78
- if (!f) {
79
- var o = s.component, n = o === void 0 ? "div" : o, u = A(s, ft);
80
- return /* @__PURE__ */ a.createElement(n, p({}, u, {
81
- ref: l
82
- }));
83
- }
84
- var E = f.className, c = A(f, ot), C = s.className, g = A(s, lt);
85
- return /* @__PURE__ */ a.createElement(X.Provider, {
86
- value: null
87
- }, /* @__PURE__ */ a.createElement(K, p({
88
- ref: l,
89
- className: oe(E, C)
90
- }, c, g)));
91
- }, xe = /* @__PURE__ */ a.forwardRef(ut);
92
- xe.displayName = "RawItem";
93
- var dt = ["prefixCls", "data", "renderItem", "renderRawItem", "itemKey", "itemWidth", "ssr", "style", "className", "maxCount", "renderRest", "renderRawRest", "suffix", "component", "itemComponent", "onVisibleChange"], be = "responsive", ze = "invalidate";
94
- function ct(e) {
95
- return "+ ".concat(e.length, " ...");
96
- }
97
- function vt(e, s) {
98
- var l = e.prefixCls, f = l === void 0 ? "rc-overflow" : l, o = e.data, n = o === void 0 ? [] : o, u = e.renderItem, E = e.renderRawItem, c = e.itemKey, C = e.itemWidth, g = C === void 0 ? 10 : C, H = e.ssr, Y = e.style, q = e.className, v = e.maxCount, O = e.renderRest, z = e.renderRawRest, P = e.suffix, m = e.component, $ = m === void 0 ? "div" : m, J = e.itemComponent, w = e.onVisibleChange, V = A(e, dt), _ = H === "full", S = st(), Q = M(S, null), k = R(Q, 2), U = k[0], Pe = k[1], h = U || 0, De = M(S, /* @__PURE__ */ new Map()), le = R(De, 2), ue = le[0], We = le[1], Me = M(S, 0), de = R(Me, 2), Ae = de[0], Ke = de[1], Oe = M(S, 0), ce = R(Oe, 2), F = ce[0], $e = ce[1], Ve = M(S, 0), ve = R(Ve, 2), T = ve[0], ke = ve[1], Ue = fe(null), me = R(Ue, 2), Z = me[0], ye = me[1], Fe = fe(null), Re = R(Fe, 2), L = Re[0], Te = Re[1], I = a.useMemo(function() {
99
- return L === null && _ ? Number.MAX_SAFE_INTEGER : L || 0;
100
- }, [L, U]), Le = fe(!1), Ee = R(Le, 2), je = Ee[0], Ge = Ee[1], ee = "".concat(f, "-item"), Se = Math.max(Ae, F), te = v === be, y = n.length && te, _e = v === ze, Xe = y || typeof v == "number" && n.length > v, N = ge(function() {
101
- var t = n;
102
- return y ? U === null && _ ? t = n : t = n.slice(0, Math.min(n.length, h / g)) : typeof v == "number" && (t = n.slice(0, v)), t;
103
- }, [n, g, U, v, y]), re = ge(function() {
104
- return y ? n.slice(I + 1) : n.slice(N.length);
105
- }, [n, N, y, I]), j = we(function(t, r) {
106
- var i;
107
- return typeof c == "function" ? c(t) : (i = c && (t == null ? void 0 : t[c])) !== null && i !== void 0 ? i : r;
108
- }, [c]), Be = we(u || function(t) {
109
- return t;
110
- }, [u]);
111
- function G(t, r, i) {
112
- L === t && (r === void 0 || r === Z) || (Te(t), i || (Ge(t < n.length - 1), w == null || w(t)), r !== void 0 && ye(r));
113
- }
114
- function He(t, r) {
115
- Pe(r.clientWidth);
116
- }
117
- function he(t, r) {
118
- We(function(i) {
119
- var d = new Map(i);
120
- return r === null ? d.delete(t) : d.set(t, r), d;
121
- });
122
- }
123
- function Ye(t, r) {
124
- $e(r), Ke(F);
125
- }
126
- function qe(t, r) {
127
- ke(r);
128
- }
129
- function ae(t) {
130
- return ue.get(j(N[t], t));
131
- }
132
- Ze(function() {
133
- if (h && typeof Se == "number" && N) {
134
- var t = T, r = N.length, i = r - 1;
135
- if (!r) {
136
- G(0, null);
137
- return;
138
- }
139
- for (var d = 0; d < r; d += 1) {
140
- var W = ae(d);
141
- if (_ && (W = W || 0), W === void 0) {
142
- G(d - 1, void 0, !0);
143
- break;
144
- }
145
- if (t += W, // Only one means `totalWidth` is the final width
146
- i === 0 && t <= h || // Last two width will be the final width
147
- d === i - 1 && t + ae(i) <= h) {
148
- G(i, null);
149
- break;
150
- } else if (t + Se > h) {
151
- G(d - 1, t - W - T + F);
152
- break;
153
- }
154
- }
155
- P && ae(0) + T > h && ye(null);
156
- }
157
- }, [h, ue, F, T, j, N]);
158
- var Ne = je && !!re.length, pe = {};
159
- Z !== null && y && (pe = {
160
- position: "absolute",
161
- left: Z,
162
- top: 0
163
- });
164
- var D = {
165
- prefixCls: ee,
166
- responsive: y,
167
- component: J,
168
- invalidate: _e
169
- }, Je = E ? function(t, r) {
170
- var i = j(t, r);
171
- return /* @__PURE__ */ a.createElement(X.Provider, {
172
- key: i,
173
- value: b(b({}, D), {}, {
174
- order: r,
175
- item: t,
176
- itemKey: i,
177
- registerSize: he,
178
- display: r <= I
179
- })
180
- }, E(t, r));
181
- } : function(t, r) {
182
- var i = j(t, r);
183
- return /* @__PURE__ */ a.createElement(K, p({}, D, {
184
- order: r,
185
- key: i,
186
- item: t,
187
- renderItem: Be,
188
- itemKey: i,
189
- registerSize: he,
190
- display: r <= I
191
- }));
192
- }, ne, Ce = {
193
- order: Ne ? I : Number.MAX_SAFE_INTEGER,
194
- className: "".concat(ee, "-rest"),
195
- registerSize: Ye,
196
- display: Ne
197
- };
198
- if (z)
199
- z && (ne = /* @__PURE__ */ a.createElement(X.Provider, {
200
- value: b(b({}, D), Ce)
201
- }, z(re)));
202
- else {
203
- var ie = O || ct;
204
- ne = /* @__PURE__ */ a.createElement(K, p({}, D, Ce), typeof ie == "function" ? ie(re) : ie);
205
- }
206
- var se = /* @__PURE__ */ a.createElement($, p({
207
- className: oe(!_e && f, q),
208
- style: Y,
209
- ref: s
210
- }, V), N.map(Je), Xe ? ne : null, P && /* @__PURE__ */ a.createElement(K, p({}, D, {
211
- responsive: te,
212
- responsiveDisabled: !y,
213
- order: I,
214
- className: "".concat(ee, "-suffix"),
215
- registerSize: qe,
216
- display: !0,
217
- style: pe
218
- }), P));
219
- return te && (se = /* @__PURE__ */ a.createElement(Ie, {
220
- onResize: He,
221
- disabled: !y
222
- }, se)), se;
223
- }
224
- var B = /* @__PURE__ */ a.forwardRef(vt);
225
- B.displayName = "Overflow";
226
- B.Item = xe;
227
- B.RESPONSIVE = be;
228
- B.INVALIDATE = ze;
229
- export {
230
- B as F
231
- };
@@ -1,60 +0,0 @@
1
- import * as e from "react";
2
- import { u as y } from "./useMergedState-qUafLuUa.js";
3
- import { A as R, C as z } from "./index-1KQbTQJ2.js";
4
- function E(s) {
5
- return (r) => /* @__PURE__ */ e.createElement(R, {
6
- theme: {
7
- token: {
8
- motion: !1,
9
- zIndexPopupBase: 0
10
- }
11
- }
12
- }, /* @__PURE__ */ e.createElement(s, Object.assign({}, r)));
13
- }
14
- const W = (s, r, c, l) => E((o) => {
15
- const {
16
- prefixCls: m,
17
- style: v
18
- } = o, i = e.useRef(null), [P, b] = e.useState(0), [h, C] = e.useState(0), [u, O] = y(!1, {
19
- value: o.open
20
- }), {
21
- getPrefixCls: x
22
- } = e.useContext(z), f = x(r || "select", m);
23
- e.useEffect(() => {
24
- if (O(!0), typeof ResizeObserver < "u") {
25
- const p = new ResizeObserver((t) => {
26
- const n = t[0].target;
27
- b(n.offsetHeight + 8), C(n.offsetWidth);
28
- }), d = setInterval(() => {
29
- var t;
30
- const n = c ? `.${c(f)}` : `.${f}-dropdown`, g = (t = i.current) === null || t === void 0 ? void 0 : t.querySelector(n);
31
- g && (clearInterval(d), p.observe(g));
32
- }, 10);
33
- return () => {
34
- clearInterval(d), p.disconnect();
35
- };
36
- }
37
- }, []);
38
- let a = Object.assign(Object.assign({}, o), {
39
- style: Object.assign(Object.assign({}, v), {
40
- margin: 0
41
- }),
42
- open: u,
43
- visible: u,
44
- getPopupContainer: () => i.current
45
- });
46
- l && (a = l(a));
47
- const j = {
48
- paddingBottom: P,
49
- position: "relative",
50
- minWidth: h
51
- };
52
- return /* @__PURE__ */ e.createElement("div", {
53
- ref: i,
54
- style: j
55
- }, /* @__PURE__ */ e.createElement(s, Object.assign({}, a)));
56
- });
57
- export {
58
- W as g,
59
- E as w
60
- };
@@ -1,16 +0,0 @@
1
- import { e as c } from "./index-1KQbTQJ2.js";
2
- import * as e from "react";
3
- import { A as n } from "./isVisible-Qi9l15Ty.js";
4
- var s = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "false" }, children: [{ tag: "path", attrs: { d: "M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z" } }] }, name: "search", theme: "outlined" };
5
- const o = s;
6
- var t = function(a, r) {
7
- return /* @__PURE__ */ e.createElement(n, c({}, a, {
8
- ref: r,
9
- icon: o
10
- }));
11
- };
12
- process.env.NODE_ENV !== "production" && (t.displayName = "SearchOutlined");
13
- const u = /* @__PURE__ */ e.forwardRef(t);
14
- export {
15
- u as S
16
- };