@stella-source/stellasource-dsl 3.5.2 → 3.6.0
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/cjs/index.js +630 -368
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/CheckBox/CheckBox.d.ts +4 -0
- package/dist/cjs/types/components/CheckBox/CheckBox.stories.d.ts +30 -0
- package/dist/cjs/types/components/CheckBox/styles.d.ts +20 -0
- package/dist/cjs/types/components/CheckBox/types.d.ts +19 -0
- package/dist/cjs/types/components/CheckBoxGroup/CheckBoxGroup.d.ts +4 -0
- package/dist/cjs/types/components/CheckBoxGroup/CheckBoxGroup.stories.d.ts +63 -0
- package/dist/cjs/types/components/CheckBoxGroup/styles.d.ts +4 -0
- package/dist/cjs/types/components/CheckBoxGroup/types.d.ts +28 -0
- package/dist/cjs/types/components/Label/Label.d.ts +1 -1
- package/dist/cjs/types/components/Label/Label.stories.d.ts +1 -1
- package/dist/cjs/types/components/Label/styles.d.ts +2 -1
- package/dist/cjs/types/components/Label/types.d.ts +2 -0
- package/dist/cjs/types/components/Sync/styles.d.ts +1 -1
- package/dist/cjs/types/index.d.ts +3 -1
- package/dist/esm/index.esm.js +952 -692
- package/dist/esm/index.esm.js.map +1 -1
- package/dist/esm/types/components/CheckBox/CheckBox.d.ts +4 -0
- package/dist/esm/types/components/CheckBox/CheckBox.stories.d.ts +30 -0
- package/dist/esm/types/components/CheckBox/styles.d.ts +20 -0
- package/dist/esm/types/components/CheckBox/types.d.ts +19 -0
- package/dist/esm/types/components/CheckBoxGroup/CheckBoxGroup.d.ts +4 -0
- package/dist/esm/types/components/CheckBoxGroup/CheckBoxGroup.stories.d.ts +63 -0
- package/dist/esm/types/components/CheckBoxGroup/styles.d.ts +4 -0
- package/dist/esm/types/components/CheckBoxGroup/types.d.ts +28 -0
- package/dist/esm/types/components/Label/Label.d.ts +1 -1
- package/dist/esm/types/components/Label/Label.stories.d.ts +1 -1
- package/dist/esm/types/components/Label/styles.d.ts +2 -1
- package/dist/esm/types/components/Label/types.d.ts +2 -0
- package/dist/esm/types/components/Sync/styles.d.ts +1 -1
- package/dist/esm/types/index.d.ts +3 -1
- package/dist/index.d.ts +54 -2
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var a$
|
|
3
|
+
var a$n = require('react');
|
|
4
4
|
var styled = require('styled-components');
|
|
5
5
|
var ReactDOM = require('react-dom');
|
|
6
6
|
|
|
@@ -21,7 +21,7 @@ function _interopNamespaceDefault(e) {
|
|
|
21
21
|
return Object.freeze(n);
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
-
var a__namespace = /*#__PURE__*/_interopNamespaceDefault(a$
|
|
24
|
+
var a__namespace = /*#__PURE__*/_interopNamespaceDefault(a$n);
|
|
25
25
|
|
|
26
26
|
const colorTokens = {
|
|
27
27
|
white: "var(--white)",
|
|
@@ -127,7 +127,7 @@ const Styles = {
|
|
|
127
127
|
font: fontTokens,
|
|
128
128
|
};
|
|
129
129
|
|
|
130
|
-
const a$
|
|
130
|
+
const a$m = /* @__PURE__ */ new Map([
|
|
131
131
|
[
|
|
132
132
|
"bold",
|
|
133
133
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm40.49-100.49a12,12,0,0,1-17,17L140,117v51a12,12,0,0,1-24,0V117l-11.51,11.52a12,12,0,0,1-17-17l32-32a12,12,0,0,1,17,0Z" }))
|
|
@@ -154,7 +154,7 @@ const a$l = /* @__PURE__ */ new Map([
|
|
|
154
154
|
]
|
|
155
155
|
]);
|
|
156
156
|
|
|
157
|
-
const a$
|
|
157
|
+
const a$l = /* @__PURE__ */ new Map([
|
|
158
158
|
[
|
|
159
159
|
"bold",
|
|
160
160
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208.49,120.49a12,12,0,0,1-17,0L140,69V216a12,12,0,0,1-24,0V69L64.49,120.49a12,12,0,0,1-17-17l72-72a12,12,0,0,1,17,0l72,72A12,12,0,0,1,208.49,120.49Z" }))
|
|
@@ -181,7 +181,7 @@ const a$k = /* @__PURE__ */ new Map([
|
|
|
181
181
|
]
|
|
182
182
|
]);
|
|
183
183
|
|
|
184
|
-
const e$
|
|
184
|
+
const e$H = /* @__PURE__ */ new Map([
|
|
185
185
|
[
|
|
186
186
|
"bold",
|
|
187
187
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M228,48V96a12,12,0,0,1-12,12H168a12,12,0,0,1,0-24h19l-7.8-7.8a75.55,75.55,0,0,0-53.32-22.26h-.43A75.49,75.49,0,0,0,72.39,75.57,12,12,0,1,1,55.61,58.41a99.38,99.38,0,0,1,69.87-28.47H126A99.42,99.42,0,0,1,196.2,59.23L204,67V48a12,12,0,0,1,24,0ZM183.61,180.43a75.49,75.49,0,0,1-53.09,21.63h-.43A75.55,75.55,0,0,1,76.77,179.8L69,172H88a12,12,0,0,0,0-24H40a12,12,0,0,0-12,12v48a12,12,0,0,0,24,0V189l7.8,7.8A99.42,99.42,0,0,0,130,226.06h.56a99.38,99.38,0,0,0,69.87-28.47,12,12,0,0,0-16.78-17.16Z" }))
|
|
@@ -208,7 +208,7 @@ const e$G = /* @__PURE__ */ new Map([
|
|
|
208
208
|
]
|
|
209
209
|
]);
|
|
210
210
|
|
|
211
|
-
const e$
|
|
211
|
+
const e$G = /* @__PURE__ */ new Map([
|
|
212
212
|
[
|
|
213
213
|
"bold",
|
|
214
214
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M140,104V64a12,12,0,0,1,24,0V75l35.51-35.52a12,12,0,0,1,17,17L181,92h11a12,12,0,0,1,0,24H152A12,12,0,0,1,140,104Zm-36,36H64a12,12,0,0,0,0,24H75L39.51,199.51a12,12,0,0,0,17,17L92,181v11a12,12,0,0,0,24,0V152A12,12,0,0,0,104,140Zm77,24h11a12,12,0,0,0,0-24H152a12,12,0,0,0-12,12v40a12,12,0,0,0,24,0V181l35.51,35.52a12,12,0,0,0,17-17ZM104,52A12,12,0,0,0,92,64V75L56.49,39.51a12,12,0,0,0-17,17L75,92H64a12,12,0,0,0,0,24h40a12,12,0,0,0,12-12V64A12,12,0,0,0,104,52Z" }))
|
|
@@ -241,7 +241,7 @@ const e$F = /* @__PURE__ */ new Map([
|
|
|
241
241
|
]
|
|
242
242
|
]);
|
|
243
243
|
|
|
244
|
-
const e$
|
|
244
|
+
const e$F = /* @__PURE__ */ new Map([
|
|
245
245
|
[
|
|
246
246
|
"bold",
|
|
247
247
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M228,128a12,12,0,0,1-12,12H40a12,12,0,0,1,0-24H216A12,12,0,0,1,228,128ZM104.49,56.48,116,45V88a12,12,0,0,0,24,0V45l11.51,11.51a12,12,0,0,0,17-17l-32-32a12,12,0,0,0-17,0l-32,32a12,12,0,0,0,17,17Zm47,143L140,211V168a12,12,0,0,0-24,0v43l-11.51-11.52a12,12,0,0,0-17,17l32,32a12,12,0,0,0,17,0l32-32a12,12,0,0,0-17-17Z" }))
|
|
@@ -274,7 +274,7 @@ const e$E = /* @__PURE__ */ new Map([
|
|
|
274
274
|
]
|
|
275
275
|
]);
|
|
276
276
|
|
|
277
|
-
const e$
|
|
277
|
+
const e$E = /* @__PURE__ */ new Map([
|
|
278
278
|
[
|
|
279
279
|
"bold",
|
|
280
280
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M218.29,182.17a12,12,0,0,1-16.47,4.12L140,149.19V216a12,12,0,0,1-24,0V149.19l-61.82,37.1a12,12,0,1,1-12.35-20.58L104.68,128,41.83,90.29A12,12,0,1,1,54.18,69.71L116,106.81V40a12,12,0,0,1,24,0v66.81l61.82-37.1a12,12,0,1,1,12.35,20.58L151.32,128l62.85,37.71A12,12,0,0,1,218.29,182.17Z" }))
|
|
@@ -301,7 +301,7 @@ const e$D = /* @__PURE__ */ new Map([
|
|
|
301
301
|
]
|
|
302
302
|
]);
|
|
303
303
|
|
|
304
|
-
const e$
|
|
304
|
+
const e$D = /* @__PURE__ */ new Map([
|
|
305
305
|
[
|
|
306
306
|
"bold",
|
|
307
307
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M24,108H44v48H32a12,12,0,0,0,0,24H224a12,12,0,0,0,0-24H212V108h20a12,12,0,0,0,6.29-22.22l-104-64a12,12,0,0,0-12.58,0l-104,64A12,12,0,0,0,24,108Zm44,0H92v48H68Zm72,0v48H116V108Zm48,48H164V108h24ZM128,46.09,189.6,84H66.4ZM252,208a12,12,0,0,1-12,12H16a12,12,0,0,1,0-24H240A12,12,0,0,1,252,208Z" }))
|
|
@@ -328,7 +328,7 @@ const e$C = /* @__PURE__ */ new Map([
|
|
|
328
328
|
]
|
|
329
329
|
]);
|
|
330
330
|
|
|
331
|
-
const e$
|
|
331
|
+
const e$C = /* @__PURE__ */ new Map([
|
|
332
332
|
[
|
|
333
333
|
"bold",
|
|
334
334
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,84a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,84Zm0,64a20,20,0,1,1,20-20A20,20,0,0,1,128,148Zm77.39,12.7A83.94,83.94,0,0,1,190.61,184a12,12,0,0,1-17.89-16,59.92,59.92,0,0,0,0-80,12,12,0,0,1,17.89-16,84.07,84.07,0,0,1,14.78,88.7ZM83.28,168a12,12,0,0,1-17.89,16,83.94,83.94,0,0,1,0-112A12,12,0,0,1,83.28,88a59.92,59.92,0,0,0,0,80ZM252,128a123.63,123.63,0,0,1-35.43,86.78A12,12,0,1,1,199.43,198a99.88,99.88,0,0,0,0-140,12,12,0,0,1,17.14-16.8A123.63,123.63,0,0,1,252,128ZM56.57,198a12,12,0,0,1-17.14,16.8,123.89,123.89,0,0,1,0-173.56A12,12,0,0,1,56.57,58a99.88,99.88,0,0,0,0,140Z" }))
|
|
@@ -355,7 +355,7 @@ const e$B = /* @__PURE__ */ new Map([
|
|
|
355
355
|
]
|
|
356
356
|
]);
|
|
357
357
|
|
|
358
|
-
const e$
|
|
358
|
+
const e$B = /* @__PURE__ */ new Map([
|
|
359
359
|
[
|
|
360
360
|
"bold",
|
|
361
361
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M200,20H56A20,20,0,0,0,36,40V216a20,20,0,0,0,20,20H200a20,20,0,0,0,20-20V40A20,20,0,0,0,200,20Zm-4,192H60V44H196ZM80,76A12,12,0,0,1,92,64h72a12,12,0,0,1,0,24H92A12,12,0,0,1,80,76Zm40,52a16,16,0,1,1-16-16A16,16,0,0,1,120,128Zm48,0a16,16,0,1,1-16-16A16,16,0,0,1,168,128Zm-48,48a16,16,0,1,1-16-16A16,16,0,0,1,120,176Zm48,0a16,16,0,1,1-16-16A16,16,0,0,1,168,176Z" }))
|
|
@@ -382,7 +382,7 @@ const e$A = /* @__PURE__ */ new Map([
|
|
|
382
382
|
]
|
|
383
383
|
]);
|
|
384
384
|
|
|
385
|
-
const e$
|
|
385
|
+
const e$A = /* @__PURE__ */ new Map([
|
|
386
386
|
[
|
|
387
387
|
"bold",
|
|
388
388
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,28H188V24a12,12,0,0,0-24,0v4H92V24a12,12,0,0,0-24,0v4H48A20,20,0,0,0,28,48V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V48A20,20,0,0,0,208,28ZM68,52a12,12,0,0,0,24,0h72a12,12,0,0,0,24,0h16V76H52V52ZM52,204V100H204V204Z" }))
|
|
@@ -442,7 +442,7 @@ const t$6 = /* @__PURE__ */ new Map([
|
|
|
442
442
|
]
|
|
443
443
|
]);
|
|
444
444
|
|
|
445
|
-
const a$
|
|
445
|
+
const a$k = /* @__PURE__ */ new Map([
|
|
446
446
|
[
|
|
447
447
|
"bold",
|
|
448
448
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M168.49,199.51a12,12,0,0,1-17,17l-80-80a12,12,0,0,1,0-17l80-80a12,12,0,0,1,17,17L97,128Z" }))
|
|
@@ -496,7 +496,7 @@ const t$5 = /* @__PURE__ */ new Map([
|
|
|
496
496
|
]
|
|
497
497
|
]);
|
|
498
498
|
|
|
499
|
-
const e$
|
|
499
|
+
const e$z = /* @__PURE__ */ new Map([
|
|
500
500
|
[
|
|
501
501
|
"bold",
|
|
502
502
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M224,92H188V56a12,12,0,0,0-12-12H60V40a12,12,0,0,0-24,0V216a12,12,0,0,0,24,0v-4h84a12,12,0,0,0,12-12V164h68a12,12,0,0,0,12-12V104A12,12,0,0,0,224,92ZM164,68V92H60V68ZM132,188H60V164h72Zm80-48H60V116H212Z" }))
|
|
@@ -523,7 +523,7 @@ const e$y = /* @__PURE__ */ new Map([
|
|
|
523
523
|
]
|
|
524
524
|
]);
|
|
525
525
|
|
|
526
|
-
const a$
|
|
526
|
+
const a$j = /* @__PURE__ */ new Map([
|
|
527
527
|
[
|
|
528
528
|
"bold",
|
|
529
529
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M176.49,95.51a12,12,0,0,1,0,17l-56,56a12,12,0,0,1-17,0l-24-24a12,12,0,1,1,17-17L112,143l47.51-47.52A12,12,0,0,1,176.49,95.51ZM236,128A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128Z" }))
|
|
@@ -583,7 +583,7 @@ const l$6 = /* @__PURE__ */ new Map([
|
|
|
583
583
|
]
|
|
584
584
|
]);
|
|
585
585
|
|
|
586
|
-
const e$
|
|
586
|
+
const e$y = /* @__PURE__ */ new Map([
|
|
587
587
|
[
|
|
588
588
|
"bold",
|
|
589
589
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M79.51,144.49a12,12,0,1,1,17-17L112,143l47.51-47.52a12,12,0,0,1,17,17l-56,56a12,12,0,0,1-17,0ZM228,48V208a20,20,0,0,1-20,20H48a20,20,0,0,1-20-20V48A20,20,0,0,1,48,28H208A20,20,0,0,1,228,48Zm-24,4H52V204H204Z" }))
|
|
@@ -616,7 +616,7 @@ const e$x = /* @__PURE__ */ new Map([
|
|
|
616
616
|
]
|
|
617
617
|
]);
|
|
618
618
|
|
|
619
|
-
const a$
|
|
619
|
+
const a$i = /* @__PURE__ */ new Map([
|
|
620
620
|
[
|
|
621
621
|
"bold",
|
|
622
622
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm12,24.87a83.53,83.53,0,0,1,24,7.25V203.88a83.53,83.53,0,0,1-24,7.25ZM44,128a84.12,84.12,0,0,1,72-83.13V211.13A84.12,84.12,0,0,1,44,128Zm144,58.71V69.29a83.81,83.81,0,0,1,0,117.42Z" }))
|
|
@@ -649,7 +649,7 @@ const a$h = /* @__PURE__ */ new Map([
|
|
|
649
649
|
]
|
|
650
650
|
]);
|
|
651
651
|
|
|
652
|
-
const e$
|
|
652
|
+
const e$x = /* @__PURE__ */ new Map([
|
|
653
653
|
[
|
|
654
654
|
"bold",
|
|
655
655
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm44-64a32,32,0,0,1-32,32v4a12,12,0,0,1-24,0v-4H104a12,12,0,0,1,0-24h36a8,8,0,0,0,0-16H116a32,32,0,0,1,0-64V72a12,12,0,0,1,24,0v4h12a12,12,0,0,1,0,24H116a8,8,0,0,0,0,16h24A32,32,0,0,1,172,148Z" }))
|
|
@@ -676,7 +676,7 @@ const e$w = /* @__PURE__ */ new Map([
|
|
|
676
676
|
]
|
|
677
677
|
]);
|
|
678
678
|
|
|
679
|
-
const e$
|
|
679
|
+
const e$w = /* @__PURE__ */ new Map([
|
|
680
680
|
[
|
|
681
681
|
"bold",
|
|
682
682
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M238.16,113.89,142.1,17.83a20,20,0,0,0-28.21,0l-96,96.06a20,20,0,0,0,0,28.22l96.05,96.06h0a20,20,0,0,0,28.21,0l96-96.06a20,20,0,0,0,0-28.22ZM128,218.33,37.68,128,128,37.67,218.32,128Z" }))
|
|
@@ -709,7 +709,7 @@ const e$v = /* @__PURE__ */ new Map([
|
|
|
709
709
|
]
|
|
710
710
|
]);
|
|
711
711
|
|
|
712
|
-
const e$
|
|
712
|
+
const e$v = /* @__PURE__ */ new Map([
|
|
713
713
|
[
|
|
714
714
|
"bold",
|
|
715
715
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,96a32,32,0,1,0,32,32A32,32,0,0,0,128,96Zm0,40a8,8,0,1,1,8-8A8,8,0,0,1,128,136Zm0-56A32,32,0,1,0,96,48,32,32,0,0,0,128,80Zm0-40a8,8,0,1,1-8,8A8,8,0,0,1,128,40Zm0,136a32,32,0,1,0,32,32A32,32,0,0,0,128,176Zm0,40a8,8,0,1,1,8-8A8,8,0,0,1,128,216Z" }))
|
|
@@ -742,7 +742,7 @@ const e$u = /* @__PURE__ */ new Map([
|
|
|
742
742
|
]
|
|
743
743
|
]);
|
|
744
744
|
|
|
745
|
-
const a$
|
|
745
|
+
const a$h = /* @__PURE__ */ new Map([
|
|
746
746
|
[
|
|
747
747
|
"bold",
|
|
748
748
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M203.63,62.65l13.25-14.58a12,12,0,0,0-17.76-16.14L185.88,46.49A100,100,0,0,0,52.37,193.35L39.12,207.93a12,12,0,1,0,17.76,16.14l13.24-14.56A100,100,0,0,0,203.63,62.65ZM52,128A75.94,75.94,0,0,1,169.58,64.43l-100.91,111A75.6,75.6,0,0,1,52,128Zm76,76a75.52,75.52,0,0,1-41.58-12.43l100.91-111A75.94,75.94,0,0,1,128,204Z" }))
|
|
@@ -769,7 +769,7 @@ const a$g = /* @__PURE__ */ new Map([
|
|
|
769
769
|
]
|
|
770
770
|
]);
|
|
771
771
|
|
|
772
|
-
const a$
|
|
772
|
+
const a$g = /* @__PURE__ */ new Map([
|
|
773
773
|
[
|
|
774
774
|
"bold",
|
|
775
775
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M251,123.13c-.37-.81-9.13-20.26-28.48-39.61C196.63,57.67,164,44,128,44S59.37,57.67,33.51,83.52C14.16,102.87,5.4,122.32,5,123.13a12.08,12.08,0,0,0,0,9.75c.37.82,9.13,20.26,28.49,39.61C59.37,198.34,92,212,128,212s68.63-13.66,94.48-39.51c19.36-19.35,28.12-38.79,28.49-39.61A12.08,12.08,0,0,0,251,123.13Zm-46.06,33C183.47,177.27,157.59,188,128,188s-55.47-10.73-76.91-31.88A130.36,130.36,0,0,1,29.52,128,130.45,130.45,0,0,1,51.09,99.89C72.54,78.73,98.41,68,128,68s55.46,10.73,76.91,31.89A130.36,130.36,0,0,1,226.48,128,130.45,130.45,0,0,1,204.91,156.12ZM128,84a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,84Zm0,64a20,20,0,1,1,20-20A20,20,0,0,1,128,148Z" }))
|
|
@@ -802,7 +802,7 @@ const a$f = /* @__PURE__ */ new Map([
|
|
|
802
802
|
]
|
|
803
803
|
]);
|
|
804
804
|
|
|
805
|
-
const e$
|
|
805
|
+
const e$u = /* @__PURE__ */ new Map([
|
|
806
806
|
[
|
|
807
807
|
"bold",
|
|
808
808
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M56.88,31.93A12,12,0,1,0,39.12,48.07l16,17.65C20.67,88.66,5.72,121.58,5,123.13a12.08,12.08,0,0,0,0,9.75c.37.82,9.13,20.26,28.49,39.61C59.37,198.34,92,212,128,212a131.34,131.34,0,0,0,51-10l20.09,22.1a12,12,0,0,0,17.76-16.14ZM128,188c-29.59,0-55.47-10.73-76.91-31.88A130.69,130.69,0,0,1,29.52,128c5.27-9.31,18.79-29.9,42-44.29l90.09,99.11A109.33,109.33,0,0,1,128,188Zm123-55.12c-.36.81-9,20-28,39.16a12,12,0,1,1-17-16.9A130.48,130.48,0,0,0,226.48,128a130.36,130.36,0,0,0-21.57-28.12C183.46,78.73,157.59,68,128,68c-3.35,0-6.7.14-10,.42a12,12,0,1,1-2-23.91c3.93-.34,8-.51,12-.51,36,0,68.63,13.67,94.49,39.52,19.35,19.35,28.11,38.8,28.48,39.61A12.08,12.08,0,0,1,251,132.88Z" }))
|
|
@@ -934,7 +934,7 @@ const l$3 = /* @__PURE__ */ new Map([
|
|
|
934
934
|
]
|
|
935
935
|
]);
|
|
936
936
|
|
|
937
|
-
const a$
|
|
937
|
+
const a$f = /* @__PURE__ */ new Map([
|
|
938
938
|
[
|
|
939
939
|
"bold",
|
|
940
940
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M108,84a16,16,0,1,1,16,16A16,16,0,0,1,108,84Zm128,44A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128Zm-72,36.68V132a20,20,0,0,0-20-20,12,12,0,0,0-4,23.32V168a20,20,0,0,0,20,20,12,12,0,0,0,4-23.32Z" }))
|
|
@@ -988,7 +988,7 @@ const H = /* @__PURE__ */ new Map([
|
|
|
988
988
|
]
|
|
989
989
|
]);
|
|
990
990
|
|
|
991
|
-
const a$
|
|
991
|
+
const a$e = /* @__PURE__ */ new Map([
|
|
992
992
|
[
|
|
993
993
|
"bold",
|
|
994
994
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm0-144a44,44,0,0,0-33.61,72.41l-9.86,32.06A12,12,0,0,0,96,188h64a12,12,0,0,0,11.47-15.53l-9.86-32.06A44,44,0,0,0,128,68Zm8.53,72.51L143.75,164h-31.5l7.22-23.49a12,12,0,0,0-4-12.89,20,20,0,1,1,25,0A12,12,0,0,0,136.53,140.51Z" }))
|
|
@@ -1048,7 +1048,7 @@ const l$2 = /* @__PURE__ */ new Map([
|
|
|
1048
1048
|
]
|
|
1049
1049
|
]);
|
|
1050
1050
|
|
|
1051
|
-
const e$
|
|
1051
|
+
const e$t = /* @__PURE__ */ new Map([
|
|
1052
1052
|
[
|
|
1053
1053
|
"bold",
|
|
1054
1054
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,76H100V56a28,28,0,0,1,28-28c13.51,0,25.65,9.62,28.24,22.39a12,12,0,1,0,23.52-4.78C174.87,21.5,153.1,4,128,4A52.06,52.06,0,0,0,76,56V76H48A20,20,0,0,0,28,96V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V96A20,20,0,0,0,208,76Zm-4,128H52V100H204Z" }))
|
|
@@ -1081,7 +1081,7 @@ const e$s = /* @__PURE__ */ new Map([
|
|
|
1081
1081
|
]
|
|
1082
1082
|
]);
|
|
1083
1083
|
|
|
1084
|
-
const a$
|
|
1084
|
+
const a$d = /* @__PURE__ */ new Map([
|
|
1085
1085
|
[
|
|
1086
1086
|
"bold",
|
|
1087
1087
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M232.49,215.51,185,168a92.12,92.12,0,1,0-17,17l47.53,47.54a12,12,0,0,0,17-17ZM44,112a68,68,0,1,1,68,68A68.07,68.07,0,0,1,44,112Z" }))
|
|
@@ -1108,6 +1108,39 @@ const a$c = /* @__PURE__ */ new Map([
|
|
|
1108
1108
|
]
|
|
1109
1109
|
]);
|
|
1110
1110
|
|
|
1111
|
+
const e$s = /* @__PURE__ */ new Map([
|
|
1112
|
+
[
|
|
1113
|
+
"bold",
|
|
1114
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,28H48A20,20,0,0,0,28,48V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V48A20,20,0,0,0,208,28Zm-4,176H52V52H204ZM76,128a12,12,0,0,1,12-12h80a12,12,0,0,1,0,24H88A12,12,0,0,1,76,128Z" }))
|
|
1115
|
+
],
|
|
1116
|
+
[
|
|
1117
|
+
"duotone",
|
|
1118
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement(
|
|
1119
|
+
"path",
|
|
1120
|
+
{
|
|
1121
|
+
d: "M216,48V208a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V48a8,8,0,0,1,8-8H208A8,8,0,0,1,216,48Z",
|
|
1122
|
+
opacity: "0.2"
|
|
1123
|
+
}
|
|
1124
|
+
), /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32Zm0,176H48V48H208V208Zm-32-80a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h80A8,8,0,0,1,176,128Z" }))
|
|
1125
|
+
],
|
|
1126
|
+
[
|
|
1127
|
+
"fill",
|
|
1128
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32ZM168,136H88a8,8,0,0,1,0-16h80a8,8,0,0,1,0,16Z" }))
|
|
1129
|
+
],
|
|
1130
|
+
[
|
|
1131
|
+
"light",
|
|
1132
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,34H48A14,14,0,0,0,34,48V208a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V48A14,14,0,0,0,208,34Zm2,174a2,2,0,0,1-2,2H48a2,2,0,0,1-2-2V48a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2Zm-36-80a6,6,0,0,1-6,6H88a6,6,0,0,1,0-12h80A6,6,0,0,1,174,128Z" }))
|
|
1133
|
+
],
|
|
1134
|
+
[
|
|
1135
|
+
"regular",
|
|
1136
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32Zm0,176H48V48H208V208Zm-32-80a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h80A8,8,0,0,1,176,128Z" }))
|
|
1137
|
+
],
|
|
1138
|
+
[
|
|
1139
|
+
"thin",
|
|
1140
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,36H48A12,12,0,0,0,36,48V208a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V48A12,12,0,0,0,208,36Zm4,172a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V48a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4Zm-40-80a4,4,0,0,1-4,4H88a4,4,0,0,1,0-8h80A4,4,0,0,1,172,128Z" }))
|
|
1141
|
+
]
|
|
1142
|
+
]);
|
|
1143
|
+
|
|
1111
1144
|
const e$r = /* @__PURE__ */ new Map([
|
|
1112
1145
|
[
|
|
1113
1146
|
"bold",
|
|
@@ -1234,7 +1267,7 @@ const e$o = /* @__PURE__ */ new Map([
|
|
|
1234
1267
|
]
|
|
1235
1268
|
]);
|
|
1236
1269
|
|
|
1237
|
-
const a$
|
|
1270
|
+
const a$c = /* @__PURE__ */ new Map([
|
|
1238
1271
|
[
|
|
1239
1272
|
"bold",
|
|
1240
1273
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M228,128a12,12,0,0,1-12,12H140v76a12,12,0,0,1-24,0V140H40a12,12,0,0,1,0-24h76V40a12,12,0,0,1,24,0v76h76A12,12,0,0,1,228,128Z" }))
|
|
@@ -1267,7 +1300,7 @@ const a$b = /* @__PURE__ */ new Map([
|
|
|
1267
1300
|
]
|
|
1268
1301
|
]);
|
|
1269
1302
|
|
|
1270
|
-
const a$
|
|
1303
|
+
const a$b = /* @__PURE__ */ new Map([
|
|
1271
1304
|
[
|
|
1272
1305
|
"bold",
|
|
1273
1306
|
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M144,180a16,16,0,1,1-16-16A16,16,0,0,1,144,180Zm92-52A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128ZM128,64c-24.26,0-44,17.94-44,40v4a12,12,0,0,0,24,0v-4c0-8.82,9-16,20-16s20,7.18,20,16-9,16-20,16a12,12,0,0,0-12,12v8a12,12,0,0,0,23.73,2.56C158.31,137.88,172,122.37,172,104,172,81.94,152.26,64,128,64Z" }))
|
|
@@ -1420,6 +1453,39 @@ const e$k = /* @__PURE__ */ new Map([
|
|
|
1420
1453
|
]
|
|
1421
1454
|
]);
|
|
1422
1455
|
|
|
1456
|
+
const a$a = /* @__PURE__ */ new Map([
|
|
1457
|
+
[
|
|
1458
|
+
"bold",
|
|
1459
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,28H48A20,20,0,0,0,28,48V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V48A20,20,0,0,0,208,28Zm-4,176H52V52H204Z" }))
|
|
1460
|
+
],
|
|
1461
|
+
[
|
|
1462
|
+
"duotone",
|
|
1463
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement(
|
|
1464
|
+
"path",
|
|
1465
|
+
{
|
|
1466
|
+
d: "M216,48V208a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V48a8,8,0,0,1,8-8H208A8,8,0,0,1,216,48Z",
|
|
1467
|
+
opacity: "0.2"
|
|
1468
|
+
}
|
|
1469
|
+
), /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32Zm0,176H48V48H208V208Z" }))
|
|
1470
|
+
],
|
|
1471
|
+
[
|
|
1472
|
+
"fill",
|
|
1473
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M224,48V208a16,16,0,0,1-16,16H48a16,16,0,0,1-16-16V48A16,16,0,0,1,48,32H208A16,16,0,0,1,224,48Z" }))
|
|
1474
|
+
],
|
|
1475
|
+
[
|
|
1476
|
+
"light",
|
|
1477
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,34H48A14,14,0,0,0,34,48V208a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V48A14,14,0,0,0,208,34Zm2,174a2,2,0,0,1-2,2H48a2,2,0,0,1-2-2V48a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2Z" }))
|
|
1478
|
+
],
|
|
1479
|
+
[
|
|
1480
|
+
"regular",
|
|
1481
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32Zm0,176H48V48H208V208Z" }))
|
|
1482
|
+
],
|
|
1483
|
+
[
|
|
1484
|
+
"thin",
|
|
1485
|
+
/* @__PURE__ */ a__namespace.createElement(a__namespace.Fragment, null, /* @__PURE__ */ a__namespace.createElement("path", { d: "M208,36H48A12,12,0,0,0,36,48V208a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V48A12,12,0,0,0,208,36Zm4,172a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V48a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4Z" }))
|
|
1486
|
+
]
|
|
1487
|
+
]);
|
|
1488
|
+
|
|
1423
1489
|
const a$9 = /* @__PURE__ */ new Map([
|
|
1424
1490
|
[
|
|
1425
1491
|
"bold",
|
|
@@ -1780,7 +1846,7 @@ const a$5 = /* @__PURE__ */ new Map([
|
|
|
1780
1846
|
]
|
|
1781
1847
|
]);
|
|
1782
1848
|
|
|
1783
|
-
const o$
|
|
1849
|
+
const o$m = a$n.createContext({
|
|
1784
1850
|
color: "currentColor",
|
|
1785
1851
|
size: "1em",
|
|
1786
1852
|
weight: "regular",
|
|
@@ -1804,7 +1870,7 @@ const p$2 = a__namespace.forwardRef(
|
|
|
1804
1870
|
weight: f = "regular",
|
|
1805
1871
|
mirrored: g = false,
|
|
1806
1872
|
...w
|
|
1807
|
-
} = a__namespace.useContext(o$
|
|
1873
|
+
} = a__namespace.useContext(o$m);
|
|
1808
1874
|
return /* @__PURE__ */ a__namespace.createElement(
|
|
1809
1875
|
"svg",
|
|
1810
1876
|
{
|
|
@@ -1826,41 +1892,41 @@ const p$2 = a__namespace.forwardRef(
|
|
|
1826
1892
|
);
|
|
1827
1893
|
p$2.displayName = "IconBase";
|
|
1828
1894
|
|
|
1829
|
-
const o$
|
|
1830
|
-
o$
|
|
1831
|
-
const p$1 = o$
|
|
1895
|
+
const o$l = a__namespace.forwardRef((e, c) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: c, ...e, weights: a$m }));
|
|
1896
|
+
o$l.displayName = "ArrowCircleUpIcon";
|
|
1897
|
+
const p$1 = o$l;
|
|
1832
1898
|
|
|
1833
|
-
const r$7 = a__namespace.forwardRef((e, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...e, weights: a$
|
|
1899
|
+
const r$7 = a__namespace.forwardRef((e, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...e, weights: a$l }));
|
|
1834
1900
|
r$7.displayName = "ArrowUpIcon";
|
|
1835
1901
|
const s$7 = r$7;
|
|
1836
1902
|
|
|
1837
|
-
const r$6 = a__namespace.forwardRef((e, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...e, weights: e$
|
|
1903
|
+
const r$6 = a__namespace.forwardRef((e, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...e, weights: e$H }));
|
|
1838
1904
|
r$6.displayName = "ArrowsClockwiseIcon";
|
|
1839
1905
|
|
|
1840
|
-
const r$5 = a__namespace.forwardRef((e, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...e, weights: e$
|
|
1906
|
+
const r$5 = a__namespace.forwardRef((e, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...e, weights: e$G }));
|
|
1841
1907
|
r$5.displayName = "ArrowsInIcon";
|
|
1842
1908
|
const c$a = r$5;
|
|
1843
1909
|
|
|
1844
|
-
const e$d = a__namespace.forwardRef((o, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...o, weights: e$
|
|
1910
|
+
const e$d = a__namespace.forwardRef((o, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...o, weights: e$F }));
|
|
1845
1911
|
e$d.displayName = "ArrowsOutLineVerticalIcon";
|
|
1846
1912
|
const n$c = e$d;
|
|
1847
1913
|
|
|
1848
|
-
const o$
|
|
1849
|
-
o$
|
|
1850
|
-
const c$9 = o$
|
|
1914
|
+
const o$k = a__namespace.forwardRef((r, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...r, weights: e$E }));
|
|
1915
|
+
o$k.displayName = "AsteriskIcon";
|
|
1916
|
+
const c$9 = o$k;
|
|
1851
1917
|
|
|
1852
|
-
const a$4 = a__namespace.forwardRef((e, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...e, weights: e$
|
|
1918
|
+
const a$4 = a__namespace.forwardRef((e, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...e, weights: e$D }));
|
|
1853
1919
|
a$4.displayName = "BankIcon";
|
|
1854
1920
|
const s$6 = a$4;
|
|
1855
1921
|
|
|
1856
|
-
const a$3 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: e$
|
|
1922
|
+
const a$3 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: e$C }));
|
|
1857
1923
|
a$3.displayName = "BroadcastIcon";
|
|
1858
1924
|
|
|
1859
|
-
const a$2 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: e$
|
|
1925
|
+
const a$2 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: e$B }));
|
|
1860
1926
|
a$2.displayName = "CalculatorIcon";
|
|
1861
1927
|
const s$5 = a$2;
|
|
1862
1928
|
|
|
1863
|
-
const e$c = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: e$
|
|
1929
|
+
const e$c = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: e$A }));
|
|
1864
1930
|
e$c.displayName = "CalendarBlankIcon";
|
|
1865
1931
|
const c$8 = e$c;
|
|
1866
1932
|
|
|
@@ -1868,66 +1934,66 @@ const e$b = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.creat
|
|
|
1868
1934
|
e$b.displayName = "CaretDownIcon";
|
|
1869
1935
|
const s$4 = e$b;
|
|
1870
1936
|
|
|
1871
|
-
const t$4 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: a$
|
|
1937
|
+
const t$4 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: a$k }));
|
|
1872
1938
|
t$4.displayName = "CaretLeftIcon";
|
|
1873
1939
|
|
|
1874
1940
|
const e$a = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: t$5 }));
|
|
1875
1941
|
e$a.displayName = "CaretRightIcon";
|
|
1876
1942
|
const s$3 = e$a;
|
|
1877
1943
|
|
|
1878
|
-
const r$4 = a__namespace.forwardRef((a, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...a, weights: e$
|
|
1944
|
+
const r$4 = a__namespace.forwardRef((a, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...a, weights: e$z }));
|
|
1879
1945
|
r$4.displayName = "ChartBarHorizontalIcon";
|
|
1880
1946
|
const c$7 = r$4;
|
|
1881
1947
|
|
|
1882
|
-
const c$6 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: a$
|
|
1948
|
+
const c$6 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: a$j }));
|
|
1883
1949
|
c$6.displayName = "CheckCircleIcon";
|
|
1884
1950
|
const s$2 = c$6;
|
|
1885
1951
|
|
|
1886
|
-
const o$
|
|
1887
|
-
o$
|
|
1888
|
-
const n$b = o$
|
|
1952
|
+
const o$j = a__namespace.forwardRef((t, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...t, weights: l$6 }));
|
|
1953
|
+
o$j.displayName = "CheckFatIcon";
|
|
1954
|
+
const n$b = o$j;
|
|
1889
1955
|
|
|
1890
|
-
const o$
|
|
1891
|
-
o$
|
|
1956
|
+
const o$i = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: e$y }));
|
|
1957
|
+
o$i.displayName = "CheckSquareIcon";
|
|
1892
1958
|
|
|
1893
|
-
const o$
|
|
1894
|
-
o$
|
|
1895
|
-
const l = o$
|
|
1959
|
+
const o$h = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: a$i }));
|
|
1960
|
+
o$h.displayName = "CircleHalfIcon";
|
|
1961
|
+
const l = o$h;
|
|
1896
1962
|
|
|
1897
|
-
const e$9 = a__namespace.forwardRef((o, c) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: c, ...o, weights: e$
|
|
1963
|
+
const e$9 = a__namespace.forwardRef((o, c) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: c, ...o, weights: e$x }));
|
|
1898
1964
|
e$9.displayName = "CurrencyCircleDollarIcon";
|
|
1899
1965
|
|
|
1900
|
-
const a$1 = a__namespace.forwardRef((m, e) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: e, ...m, weights: e$
|
|
1966
|
+
const a$1 = a__namespace.forwardRef((m, e) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: e, ...m, weights: e$w }));
|
|
1901
1967
|
a$1.displayName = "DiamondIcon";
|
|
1902
1968
|
const c$5 = a$1;
|
|
1903
1969
|
|
|
1904
|
-
const t$3 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: e$
|
|
1970
|
+
const t$3 = a__namespace.forwardRef((o, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...o, weights: e$v }));
|
|
1905
1971
|
t$3.displayName = "DotsThreeOutlineVerticalIcon";
|
|
1906
1972
|
const n$a = t$3;
|
|
1907
1973
|
|
|
1908
|
-
const t$2 = a__namespace.forwardRef((m, e) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: e, ...m, weights: a$
|
|
1974
|
+
const t$2 = a__namespace.forwardRef((m, e) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: e, ...m, weights: a$h }));
|
|
1909
1975
|
t$2.displayName = "EmptyIcon";
|
|
1910
1976
|
|
|
1911
|
-
const o$
|
|
1912
|
-
o$
|
|
1913
|
-
const n$9 = o$
|
|
1977
|
+
const o$g = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: a$g }));
|
|
1978
|
+
o$g.displayName = "EyeIcon";
|
|
1979
|
+
const n$9 = o$g;
|
|
1914
1980
|
|
|
1915
|
-
const o$
|
|
1916
|
-
o$
|
|
1917
|
-
const n$8 = o$
|
|
1981
|
+
const o$f = a__namespace.forwardRef((a, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...a, weights: e$u }));
|
|
1982
|
+
o$f.displayName = "EyeSlashIcon";
|
|
1983
|
+
const n$8 = o$f;
|
|
1918
1984
|
|
|
1919
|
-
const o$
|
|
1920
|
-
o$
|
|
1921
|
-
const s$1 = o$
|
|
1985
|
+
const o$e = a__namespace.forwardRef((n, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...n, weights: l$5 }));
|
|
1986
|
+
o$e.displayName = "FunnelIcon";
|
|
1987
|
+
const s$1 = o$e;
|
|
1922
1988
|
|
|
1923
|
-
const o$
|
|
1924
|
-
o$
|
|
1925
|
-
const n$7 = o$
|
|
1989
|
+
const o$d = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: l$4 }));
|
|
1990
|
+
o$d.displayName = "GearIcon";
|
|
1991
|
+
const n$7 = o$d;
|
|
1926
1992
|
|
|
1927
1993
|
const e$8 = a__namespace.forwardRef((r, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...r, weights: l$3 }));
|
|
1928
1994
|
e$8.displayName = "HourglassSimpleLowIcon";
|
|
1929
1995
|
|
|
1930
|
-
const e$7 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: a$
|
|
1996
|
+
const e$7 = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: a$f }));
|
|
1931
1997
|
e$7.displayName = "InfoIcon";
|
|
1932
1998
|
const c$4 = e$7;
|
|
1933
1999
|
|
|
@@ -1935,58 +2001,64 @@ const e$6 = a__namespace.forwardRef((c, r) => /* @__PURE__ */ a__namespace.creat
|
|
|
1935
2001
|
e$6.displayName = "InvoiceIcon";
|
|
1936
2002
|
const m$8 = e$6;
|
|
1937
2003
|
|
|
1938
|
-
const o$
|
|
1939
|
-
o$
|
|
1940
|
-
const n$6 = o$
|
|
2004
|
+
const o$c = a__namespace.forwardRef((r, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...r, weights: a$e }));
|
|
2005
|
+
o$c.displayName = "KeyholeIcon";
|
|
2006
|
+
const n$6 = o$c;
|
|
2007
|
+
|
|
2008
|
+
const o$b = a__namespace.forwardRef((s, t) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: t, ...s, weights: l$2 }));
|
|
2009
|
+
o$b.displayName = "ListChecksIcon";
|
|
1941
2010
|
|
|
1942
|
-
const o$
|
|
1943
|
-
o$
|
|
2011
|
+
const o$a = a__namespace.forwardRef((m, p) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: p, ...m, weights: e$t }));
|
|
2012
|
+
o$a.displayName = "LockSimpleOpenIcon";
|
|
2013
|
+
const a = o$a;
|
|
1944
2014
|
|
|
1945
|
-
const o$
|
|
1946
|
-
o$
|
|
1947
|
-
const
|
|
2015
|
+
const o$9 = a__namespace.forwardRef((s, n) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: n, ...s, weights: a$d }));
|
|
2016
|
+
o$9.displayName = "MagnifyingGlassIcon";
|
|
2017
|
+
const f = o$9;
|
|
1948
2018
|
|
|
1949
|
-
const o$
|
|
1950
|
-
o$
|
|
1951
|
-
const f = o$7;
|
|
2019
|
+
const o$8 = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: e$s }));
|
|
2020
|
+
o$8.displayName = "MinusSquareIcon";
|
|
1952
2021
|
|
|
1953
2022
|
const e$5 = a__namespace.forwardRef((a, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...a, weights: e$r }));
|
|
1954
2023
|
e$5.displayName = "MoneyWavyIcon";
|
|
1955
2024
|
|
|
1956
|
-
const o$
|
|
1957
|
-
o$
|
|
2025
|
+
const o$7 = a__namespace.forwardRef((t, c) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: c, ...t, weights: e$q }));
|
|
2026
|
+
o$7.displayName = "NotePencilIcon";
|
|
1958
2027
|
|
|
1959
2028
|
const t$1 = a__namespace.forwardRef((o, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...o, weights: e$p }));
|
|
1960
2029
|
t$1.displayName = "PaletteIcon";
|
|
1961
2030
|
const n$5 = t$1;
|
|
1962
2031
|
|
|
1963
|
-
const o$
|
|
1964
|
-
o$
|
|
1965
|
-
const m$7 = o$
|
|
2032
|
+
const o$6 = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: e$o }));
|
|
2033
|
+
o$6.displayName = "PaperclipIcon";
|
|
2034
|
+
const m$7 = o$6;
|
|
1966
2035
|
|
|
1967
|
-
const e$4 = a__namespace.forwardRef((r, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...r, weights: a$
|
|
2036
|
+
const e$4 = a__namespace.forwardRef((r, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...r, weights: a$c }));
|
|
1968
2037
|
e$4.displayName = "PlusIcon";
|
|
1969
2038
|
const n$4 = e$4;
|
|
1970
2039
|
|
|
1971
|
-
const e$3 = a__namespace.forwardRef((t, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...t, weights: a$
|
|
2040
|
+
const e$3 = a__namespace.forwardRef((t, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...t, weights: a$b }));
|
|
1972
2041
|
e$3.displayName = "QuestionIcon";
|
|
1973
2042
|
const m$6 = e$3;
|
|
1974
2043
|
|
|
1975
|
-
const o$
|
|
1976
|
-
o$
|
|
1977
|
-
const h = o$
|
|
2044
|
+
const o$5 = a__namespace.forwardRef((c, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...c, weights: e$n }));
|
|
2045
|
+
o$5.displayName = "ShieldCheckIcon";
|
|
2046
|
+
const h = o$5;
|
|
1978
2047
|
|
|
1979
2048
|
const p = a__namespace.forwardRef((e, r) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: r, ...e, weights: e$m }));
|
|
1980
2049
|
p.displayName = "ShoppingCartSimpleIcon";
|
|
1981
2050
|
const n$3 = p;
|
|
1982
2051
|
|
|
1983
|
-
const o$
|
|
1984
|
-
o$
|
|
1985
|
-
const c$3 = o$
|
|
2052
|
+
const o$4 = a__namespace.forwardRef((r, s) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: s, ...r, weights: e$l }));
|
|
2053
|
+
o$4.displayName = "SlidersIcon";
|
|
2054
|
+
const c$3 = o$4;
|
|
1986
2055
|
|
|
1987
|
-
const o$
|
|
1988
|
-
o$
|
|
1989
|
-
const m$5 = o$
|
|
2056
|
+
const o$3 = a__namespace.forwardRef((r, n) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: n, ...r, weights: e$k }));
|
|
2057
|
+
o$3.displayName = "SpinnerGapIcon";
|
|
2058
|
+
const m$5 = o$3;
|
|
2059
|
+
|
|
2060
|
+
const o$2 = a__namespace.forwardRef((r, a) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: a, ...r, weights: a$a }));
|
|
2061
|
+
o$2.displayName = "SquareIcon";
|
|
1990
2062
|
|
|
1991
2063
|
const t = a__namespace.forwardRef((a, c) => /* @__PURE__ */ a__namespace.createElement(p$2, { ref: c, ...a, weights: a$9 }));
|
|
1992
2064
|
t.displayName = "StackIcon";
|
|
@@ -2067,7 +2139,7 @@ const selectIcon = (iconName) => {
|
|
|
2067
2139
|
return { icon: n$4, color: Styles.color.core.primary };
|
|
2068
2140
|
case "stella-logo":
|
|
2069
2141
|
return {
|
|
2070
|
-
icon: ({ size, color, id, className, dataTestId }) => (a$
|
|
2142
|
+
icon: ({ size, color, id, className, dataTestId }) => (a$n.createElement(StellaIcon$1, { size: size, color: color, id: id, className: className, "data-testid": dataTestId })),
|
|
2071
2143
|
color: Styles.color.core.primary,
|
|
2072
2144
|
};
|
|
2073
2145
|
case "chevron-right":
|
|
@@ -2143,7 +2215,7 @@ const selectIcon = (iconName) => {
|
|
|
2143
2215
|
case "sync":
|
|
2144
2216
|
return { icon: r$6, color: Styles.color.blue.primary };
|
|
2145
2217
|
case "check-square":
|
|
2146
|
-
return { icon: o$
|
|
2218
|
+
return { icon: o$i, color: Styles.color.blue.primary };
|
|
2147
2219
|
case "empty":
|
|
2148
2220
|
return { icon: t$2, color: Styles.color.states.error };
|
|
2149
2221
|
case "money":
|
|
@@ -2162,12 +2234,12 @@ const selectIcon = (iconName) => {
|
|
|
2162
2234
|
case "truck":
|
|
2163
2235
|
return { icon: r$2, color: Styles.color.grey.shadow };
|
|
2164
2236
|
case "list-checks":
|
|
2165
|
-
return { icon: o$
|
|
2237
|
+
return { icon: o$b, color: Styles.color.blue.primary };
|
|
2166
2238
|
case "note-pencil":
|
|
2167
|
-
return { icon: o$
|
|
2239
|
+
return { icon: o$7, color: Styles.color.grey.charcoal };
|
|
2168
2240
|
default:
|
|
2169
2241
|
return {
|
|
2170
|
-
icon: ({ size, color, id, className, dataTestId }) => (a$
|
|
2242
|
+
icon: ({ size, color, id, className, dataTestId }) => (a$n.createElement(StellaIcon$1, { size: size, color: color, id: id, className: className, "data-testid": dataTestId })),
|
|
2171
2243
|
color: Styles.color.core.primary,
|
|
2172
2244
|
};
|
|
2173
2245
|
}
|
|
@@ -2219,12 +2291,12 @@ const getFill = (iconName) => {
|
|
|
2219
2291
|
};
|
|
2220
2292
|
|
|
2221
2293
|
const StellaIcon = ({ iconName, size = 18, color, className, id, dataTestId, }) => {
|
|
2222
|
-
const iconInfo = a$
|
|
2294
|
+
const iconInfo = a$n.useMemo(() => {
|
|
2223
2295
|
const icon = selectIcon(iconName);
|
|
2224
2296
|
const fill = getFill(iconName);
|
|
2225
2297
|
return { icon, fill };
|
|
2226
2298
|
}, [iconName]);
|
|
2227
|
-
return (a$
|
|
2299
|
+
return (a$n.createElement(iconInfo.icon.icon, { size: size, weight: iconInfo.fill, color: color || iconInfo.icon.color, className: className, id: id, "data-testid": dataTestId }));
|
|
2228
2300
|
};
|
|
2229
2301
|
|
|
2230
2302
|
var TooltipIconType;
|
|
@@ -2358,7 +2430,7 @@ function isFragment$1(object) {
|
|
|
2358
2430
|
function toArray$2(children) {
|
|
2359
2431
|
var option = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
2360
2432
|
var ret = [];
|
|
2361
|
-
a$
|
|
2433
|
+
a$n.Children.forEach(children, function (child) {
|
|
2362
2434
|
if ((child === undefined || child === null) && !option.keepEmpty) {
|
|
2363
2435
|
return;
|
|
2364
2436
|
}
|
|
@@ -2515,7 +2587,7 @@ function findDOMNode(node) {
|
|
|
2515
2587
|
if (domNode) {
|
|
2516
2588
|
return domNode;
|
|
2517
2589
|
}
|
|
2518
|
-
if (node instanceof a$
|
|
2590
|
+
if (node instanceof a$n.Component) {
|
|
2519
2591
|
var _ReactDOM$findDOMNode;
|
|
2520
2592
|
return (_ReactDOM$findDOMNode = ReactDOM.findDOMNode) === null || _ReactDOM$findDOMNode === void 0 ? void 0 : _ReactDOM$findDOMNode.call(ReactDOM, node);
|
|
2521
2593
|
}
|
|
@@ -2795,7 +2867,7 @@ function useMemo(getValue, condition, shouldUpdate) {
|
|
|
2795
2867
|
return cacheRef.current.value;
|
|
2796
2868
|
}
|
|
2797
2869
|
|
|
2798
|
-
var ReactMajorVersion = Number(a$
|
|
2870
|
+
var ReactMajorVersion = Number(a$n.version.split('.')[0]);
|
|
2799
2871
|
var fillRef = function fillRef(ref, node) {
|
|
2800
2872
|
if (typeof ref === 'function') {
|
|
2801
2873
|
ref(node);
|
|
@@ -2857,7 +2929,7 @@ var supportRef = function supportRef(nodeOrComponent) {
|
|
|
2857
2929
|
return true;
|
|
2858
2930
|
};
|
|
2859
2931
|
function isReactElement(node) {
|
|
2860
|
-
return /*#__PURE__*/a$
|
|
2932
|
+
return /*#__PURE__*/a$n.isValidElement(node) && !isFragment$1(node);
|
|
2861
2933
|
}
|
|
2862
2934
|
|
|
2863
2935
|
/**
|
|
@@ -5181,7 +5253,7 @@ var TOKEN_PREFIX = 'token';
|
|
|
5181
5253
|
*/
|
|
5182
5254
|
function useCacheToken(theme, tokens) {
|
|
5183
5255
|
var option = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
5184
|
-
var _useContext = a$
|
|
5256
|
+
var _useContext = a$n.useContext(StyleContext),
|
|
5185
5257
|
instanceId = _useContext.cache.instanceId,
|
|
5186
5258
|
container = _useContext.container;
|
|
5187
5259
|
var _option$salt = option.salt,
|
|
@@ -6368,7 +6440,7 @@ var useCSSVarRegister = function useCSSVarRegister(config, fn) {
|
|
|
6368
6440
|
token = config.token,
|
|
6369
6441
|
_config$scope = config.scope,
|
|
6370
6442
|
scope = _config$scope === void 0 ? '' : _config$scope;
|
|
6371
|
-
var _useContext = a$
|
|
6443
|
+
var _useContext = a$n.useContext(StyleContext),
|
|
6372
6444
|
instanceId = _useContext.cache.instanceId,
|
|
6373
6445
|
container = _useContext.container;
|
|
6374
6446
|
var tokenKey = token._tokenKey;
|
|
@@ -7730,7 +7802,7 @@ const defaultConfig = {
|
|
|
7730
7802
|
},
|
|
7731
7803
|
hashed: true
|
|
7732
7804
|
};
|
|
7733
|
-
const DesignTokenContext = /*#__PURE__*/a$
|
|
7805
|
+
const DesignTokenContext = /*#__PURE__*/a$n.createContext(defaultConfig);
|
|
7734
7806
|
|
|
7735
7807
|
const defaultPrefixCls = 'ant';
|
|
7736
7808
|
const defaultIconPrefixCls = 'anticon';
|
|
@@ -8284,7 +8356,7 @@ var uniqueMap = new ArrayKeyMap();
|
|
|
8284
8356
|
* Like `useMemo`, but this hook result will be shared across all instances.
|
|
8285
8357
|
*/
|
|
8286
8358
|
function useUniqueMemo(memoFn, deps) {
|
|
8287
|
-
return a$
|
|
8359
|
+
return a$n.useMemo(function () {
|
|
8288
8360
|
var cachedValue = uniqueMap.get(deps);
|
|
8289
8361
|
if (cachedValue) {
|
|
8290
8362
|
return cachedValue;
|
|
@@ -8383,7 +8455,7 @@ function genStyleUtils(config) {
|
|
|
8383
8455
|
var _useToken2 = useToken(),
|
|
8384
8456
|
cssVar = _useToken2.cssVar;
|
|
8385
8457
|
return [function (node) {
|
|
8386
|
-
return injectStyle && cssVar ? /*#__PURE__*/a$
|
|
8458
|
+
return injectStyle && cssVar ? /*#__PURE__*/a$n.createElement(a$n.Fragment, null, /*#__PURE__*/a$n.createElement(CSSVarRegister, {
|
|
8387
8459
|
rootCls: rootCls,
|
|
8388
8460
|
cssVar: cssVar,
|
|
8389
8461
|
component: component
|
|
@@ -8835,7 +8907,7 @@ function useToken() {
|
|
|
8835
8907
|
theme,
|
|
8836
8908
|
override,
|
|
8837
8909
|
cssVar
|
|
8838
|
-
} = a$
|
|
8910
|
+
} = a$n.useContext(DesignTokenContext);
|
|
8839
8911
|
const salt = `${version}-${hashed || ''}`;
|
|
8840
8912
|
const mergedTheme = theme || defaultTheme;
|
|
8841
8913
|
const [token, hashId, realToken] = useCacheToken(mergedTheme, [seedToken, rootDesignToken], {
|
|
@@ -8956,7 +9028,7 @@ const {
|
|
|
8956
9028
|
const {
|
|
8957
9029
|
getPrefixCls,
|
|
8958
9030
|
iconPrefixCls
|
|
8959
|
-
} = a$
|
|
9031
|
+
} = a$n.useContext(ConfigContext);
|
|
8960
9032
|
const rootPrefixCls = getPrefixCls();
|
|
8961
9033
|
return {
|
|
8962
9034
|
rootPrefixCls,
|
|
@@ -8976,7 +9048,7 @@ const {
|
|
|
8976
9048
|
useCSP: () => {
|
|
8977
9049
|
const {
|
|
8978
9050
|
csp
|
|
8979
|
-
} = a$
|
|
9051
|
+
} = a$n.useContext(ConfigContext);
|
|
8980
9052
|
return csp !== null && csp !== void 0 ? csp : {};
|
|
8981
9053
|
},
|
|
8982
9054
|
getResetStyles: (token, config) => {
|
|
@@ -9128,7 +9200,7 @@ function getTransitionName$1(transitionName, transitionType) {
|
|
|
9128
9200
|
}
|
|
9129
9201
|
|
|
9130
9202
|
var useDomMotionEvents = (function (onInternalMotionEnd) {
|
|
9131
|
-
var cacheElementRef = a$
|
|
9203
|
+
var cacheElementRef = a$n.useRef();
|
|
9132
9204
|
|
|
9133
9205
|
// Remove events
|
|
9134
9206
|
function removeMotionEvents(element) {
|
|
@@ -9162,7 +9234,7 @@ var useDomMotionEvents = (function (onInternalMotionEnd) {
|
|
|
9162
9234
|
});
|
|
9163
9235
|
|
|
9164
9236
|
// It's safe to use `useLayoutEffect` but the warning is annoying
|
|
9165
|
-
var useIsomorphicLayoutEffect = canUseDom() ? a$
|
|
9237
|
+
var useIsomorphicLayoutEffect = canUseDom() ? a$n.useLayoutEffect : a$n.useEffect;
|
|
9166
9238
|
|
|
9167
9239
|
var useNextFrame = (function () {
|
|
9168
9240
|
var nextFrameRef = a__namespace.useRef(null);
|
|
@@ -9286,8 +9358,8 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9286
9358
|
style = _useState4[0],
|
|
9287
9359
|
setStyle = _useState4[1];
|
|
9288
9360
|
var currentStatus = getStatus();
|
|
9289
|
-
var mountedRef = a$
|
|
9290
|
-
var deadlineRef = a$
|
|
9361
|
+
var mountedRef = a$n.useRef(false);
|
|
9362
|
+
var deadlineRef = a$n.useRef(null);
|
|
9291
9363
|
|
|
9292
9364
|
// =========================== Dom Node ===========================
|
|
9293
9365
|
function getDomElement() {
|
|
@@ -9295,7 +9367,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9295
9367
|
}
|
|
9296
9368
|
|
|
9297
9369
|
// ========================== Motion End ==========================
|
|
9298
|
-
var activeRef = a$
|
|
9370
|
+
var activeRef = a$n.useRef(false);
|
|
9299
9371
|
|
|
9300
9372
|
/**
|
|
9301
9373
|
* Clean up status & style
|
|
@@ -9392,7 +9464,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9392
9464
|
activeRef.current = active;
|
|
9393
9465
|
|
|
9394
9466
|
// ============================ Status ============================
|
|
9395
|
-
var visibleRef = a$
|
|
9467
|
+
var visibleRef = a$n.useRef(null);
|
|
9396
9468
|
|
|
9397
9469
|
// Update with new status
|
|
9398
9470
|
useIsomorphicLayoutEffect(function () {
|
|
@@ -9441,7 +9513,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9441
9513
|
|
|
9442
9514
|
// ============================ Effect ============================
|
|
9443
9515
|
// Reset when motion changed
|
|
9444
|
-
a$
|
|
9516
|
+
a$n.useEffect(function () {
|
|
9445
9517
|
if (
|
|
9446
9518
|
// Cancel appear
|
|
9447
9519
|
currentStatus === STATUS_APPEAR && !motionAppear ||
|
|
@@ -9452,7 +9524,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9452
9524
|
setStatus(STATUS_NONE);
|
|
9453
9525
|
}
|
|
9454
9526
|
}, [motionAppear, motionEnter, motionLeave]);
|
|
9455
|
-
a$
|
|
9527
|
+
a$n.useEffect(function () {
|
|
9456
9528
|
return function () {
|
|
9457
9529
|
mountedRef.current = false;
|
|
9458
9530
|
clearTimeout(deadlineRef.current);
|
|
@@ -9461,7 +9533,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
9461
9533
|
|
|
9462
9534
|
// Trigger `onVisibleChanged`
|
|
9463
9535
|
var firstMountChangeRef = a__namespace.useRef(false);
|
|
9464
|
-
a$
|
|
9536
|
+
a$n.useEffect(function () {
|
|
9465
9537
|
// [visible & motion not end] => [!visible & motion end] still need trigger onVisibleChanged
|
|
9466
9538
|
if (asyncVisible) {
|
|
9467
9539
|
firstMountChangeRef.current = true;
|
|
@@ -9512,9 +9584,9 @@ function genCSSMotion(config) {
|
|
|
9512
9584
|
var supportMotion = isSupportTransition(props, contextMotion);
|
|
9513
9585
|
|
|
9514
9586
|
// Ref to the react node, it may be a HTMLElement
|
|
9515
|
-
var nodeRef = a$
|
|
9587
|
+
var nodeRef = a$n.useRef();
|
|
9516
9588
|
// Ref to the dom wrapper in case ref can not pass to HTMLElement
|
|
9517
|
-
var wrapperNodeRef = a$
|
|
9589
|
+
var wrapperNodeRef = a$n.useRef();
|
|
9518
9590
|
function getDomElement() {
|
|
9519
9591
|
try {
|
|
9520
9592
|
// Here we're avoiding call for findDOMNode since it's deprecated
|
|
@@ -9850,19 +9922,19 @@ function getShadowRoot(ele) {
|
|
|
9850
9922
|
}
|
|
9851
9923
|
|
|
9852
9924
|
function isFragment(child) {
|
|
9853
|
-
return child && /*#__PURE__*/a$
|
|
9925
|
+
return child && /*#__PURE__*/a$n.isValidElement(child) && child.type === a$n.Fragment;
|
|
9854
9926
|
}
|
|
9855
9927
|
const replaceElement = (element, replacement, props) => {
|
|
9856
|
-
if (! /*#__PURE__*/a$
|
|
9928
|
+
if (! /*#__PURE__*/a$n.isValidElement(element)) {
|
|
9857
9929
|
return replacement;
|
|
9858
9930
|
}
|
|
9859
|
-
return /*#__PURE__*/a$
|
|
9931
|
+
return /*#__PURE__*/a$n.cloneElement(element, typeof props === 'function' ? props(element.props || {}) : props);
|
|
9860
9932
|
};
|
|
9861
9933
|
function cloneElement(element, props) {
|
|
9862
9934
|
return replaceElement(element, element, props);
|
|
9863
9935
|
}
|
|
9864
9936
|
|
|
9865
|
-
const zIndexContext = /*#__PURE__*/a$
|
|
9937
|
+
const zIndexContext = /*#__PURE__*/a$n.createContext(undefined);
|
|
9866
9938
|
if (process.env.NODE_ENV !== 'production') {
|
|
9867
9939
|
zIndexContext.displayName = 'zIndexContext';
|
|
9868
9940
|
}
|
|
@@ -9901,7 +9973,7 @@ function isContainerType(type) {
|
|
|
9901
9973
|
}
|
|
9902
9974
|
const useZIndex = (componentType, customZIndex) => {
|
|
9903
9975
|
const [, token] = useToken();
|
|
9904
|
-
const parentZIndex = a$
|
|
9976
|
+
const parentZIndex = a$n.useContext(zIndexContext);
|
|
9905
9977
|
const isContainer = isContainerType(componentType);
|
|
9906
9978
|
let result;
|
|
9907
9979
|
if (customZIndex !== undefined) {
|
|
@@ -10392,11 +10464,11 @@ var ColorBlock = function ColorBlock(_ref) {
|
|
|
10392
10464
|
style = _ref.style,
|
|
10393
10465
|
onClick = _ref.onClick;
|
|
10394
10466
|
var colorBlockCls = "".concat(prefixCls, "-color-block");
|
|
10395
|
-
return /*#__PURE__*/a$
|
|
10467
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10396
10468
|
className: classNames(colorBlockCls, className),
|
|
10397
10469
|
style: style,
|
|
10398
10470
|
onClick: onClick
|
|
10399
|
-
}, /*#__PURE__*/a$
|
|
10471
|
+
}, /*#__PURE__*/a$n.createElement("div", {
|
|
10400
10472
|
className: "".concat(colorBlockCls, "-inner"),
|
|
10401
10473
|
style: {
|
|
10402
10474
|
background: color
|
|
@@ -10422,21 +10494,21 @@ function useColorDrag(props) {
|
|
|
10422
10494
|
calculate = props.calculate,
|
|
10423
10495
|
color = props.color,
|
|
10424
10496
|
disabledDrag = props.disabledDrag;
|
|
10425
|
-
var _useState = a$
|
|
10497
|
+
var _useState = a$n.useState({
|
|
10426
10498
|
x: 0,
|
|
10427
10499
|
y: 0
|
|
10428
10500
|
}),
|
|
10429
10501
|
_useState2 = _slicedToArray(_useState, 2),
|
|
10430
10502
|
offsetValue = _useState2[0],
|
|
10431
10503
|
setOffsetValue = _useState2[1];
|
|
10432
|
-
var mouseMoveRef = a$
|
|
10433
|
-
var mouseUpRef = a$
|
|
10504
|
+
var mouseMoveRef = a$n.useRef(null);
|
|
10505
|
+
var mouseUpRef = a$n.useRef(null);
|
|
10434
10506
|
|
|
10435
10507
|
// Always get position from `color`
|
|
10436
|
-
a$
|
|
10508
|
+
a$n.useEffect(function () {
|
|
10437
10509
|
setOffsetValue(calculate());
|
|
10438
10510
|
}, [color]);
|
|
10439
|
-
a$
|
|
10511
|
+
a$n.useEffect(function () {
|
|
10440
10512
|
return function () {
|
|
10441
10513
|
document.removeEventListener('mousemove', mouseMoveRef.current);
|
|
10442
10514
|
document.removeEventListener('mouseup', mouseUpRef.current);
|
|
@@ -10510,7 +10582,7 @@ var Handler = function Handler(_ref) {
|
|
|
10510
10582
|
size = _ref$size === void 0 ? 'default' : _ref$size,
|
|
10511
10583
|
color = _ref.color,
|
|
10512
10584
|
prefixCls = _ref.prefixCls;
|
|
10513
|
-
return /*#__PURE__*/a$
|
|
10585
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10514
10586
|
className: classNames("".concat(prefixCls, "-handler"), _defineProperty({}, "".concat(prefixCls, "-handler-sm"), size === 'small')),
|
|
10515
10587
|
style: {
|
|
10516
10588
|
backgroundColor: color
|
|
@@ -10522,7 +10594,7 @@ var Palette = function Palette(_ref) {
|
|
|
10522
10594
|
var children = _ref.children,
|
|
10523
10595
|
style = _ref.style,
|
|
10524
10596
|
prefixCls = _ref.prefixCls;
|
|
10525
|
-
return /*#__PURE__*/a$
|
|
10597
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10526
10598
|
className: "".concat(prefixCls, "-palette"),
|
|
10527
10599
|
style: _objectSpread2({
|
|
10528
10600
|
position: 'relative'
|
|
@@ -10530,11 +10602,11 @@ var Palette = function Palette(_ref) {
|
|
|
10530
10602
|
}, children);
|
|
10531
10603
|
};
|
|
10532
10604
|
|
|
10533
|
-
var Transform = /*#__PURE__*/a$
|
|
10605
|
+
var Transform = /*#__PURE__*/a$n.forwardRef(function (props, ref) {
|
|
10534
10606
|
var children = props.children,
|
|
10535
10607
|
x = props.x,
|
|
10536
10608
|
y = props.y;
|
|
10537
|
-
return /*#__PURE__*/a$
|
|
10609
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10538
10610
|
ref: ref,
|
|
10539
10611
|
style: {
|
|
10540
10612
|
position: 'absolute',
|
|
@@ -10552,9 +10624,9 @@ var Picker = function Picker(_ref) {
|
|
|
10552
10624
|
prefixCls = _ref.prefixCls,
|
|
10553
10625
|
onChangeComplete = _ref.onChangeComplete,
|
|
10554
10626
|
disabled = _ref.disabled;
|
|
10555
|
-
var pickerRef = a$
|
|
10556
|
-
var transformRef = a$
|
|
10557
|
-
var colorRef = a$
|
|
10627
|
+
var pickerRef = a$n.useRef();
|
|
10628
|
+
var transformRef = a$n.useRef();
|
|
10629
|
+
var colorRef = a$n.useRef(color);
|
|
10558
10630
|
var onDragChange = useEvent(function (offsetValue) {
|
|
10559
10631
|
var calcColor = calculateColor({
|
|
10560
10632
|
offset: offsetValue,
|
|
@@ -10581,21 +10653,21 @@ var Picker = function Picker(_ref) {
|
|
|
10581
10653
|
_useColorDrag2 = _slicedToArray(_useColorDrag, 2),
|
|
10582
10654
|
offset = _useColorDrag2[0],
|
|
10583
10655
|
dragStartHandle = _useColorDrag2[1];
|
|
10584
|
-
return /*#__PURE__*/a$
|
|
10656
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10585
10657
|
ref: pickerRef,
|
|
10586
10658
|
className: "".concat(prefixCls, "-select"),
|
|
10587
10659
|
onMouseDown: dragStartHandle,
|
|
10588
10660
|
onTouchStart: dragStartHandle
|
|
10589
|
-
}, /*#__PURE__*/a$
|
|
10661
|
+
}, /*#__PURE__*/a$n.createElement(Palette, {
|
|
10590
10662
|
prefixCls: prefixCls
|
|
10591
|
-
}, /*#__PURE__*/a$
|
|
10663
|
+
}, /*#__PURE__*/a$n.createElement(Transform, {
|
|
10592
10664
|
x: offset.x,
|
|
10593
10665
|
y: offset.y,
|
|
10594
10666
|
ref: transformRef
|
|
10595
|
-
}, /*#__PURE__*/a$
|
|
10667
|
+
}, /*#__PURE__*/a$n.createElement(Handler, {
|
|
10596
10668
|
color: color.toRgbString(),
|
|
10597
10669
|
prefixCls: prefixCls
|
|
10598
|
-
})), /*#__PURE__*/a$
|
|
10670
|
+
})), /*#__PURE__*/a$n.createElement("div", {
|
|
10599
10671
|
className: "".concat(prefixCls, "-saturation"),
|
|
10600
10672
|
style: {
|
|
10601
10673
|
backgroundColor: "hsl(".concat(color.toHsb().h, ",100%, 50%)"),
|
|
@@ -10611,7 +10683,7 @@ var useColorState = function useColorState(defaultValue, value) {
|
|
|
10611
10683
|
_useMergedState2 = _slicedToArray(_useMergedState, 2),
|
|
10612
10684
|
mergedValue = _useMergedState2[0],
|
|
10613
10685
|
setValue = _useMergedState2[1];
|
|
10614
|
-
var color = a$
|
|
10686
|
+
var color = a$n.useMemo(function () {
|
|
10615
10687
|
return generateColor$1(mergedValue);
|
|
10616
10688
|
}, [mergedValue]);
|
|
10617
10689
|
return [color, setValue];
|
|
@@ -10624,7 +10696,7 @@ var Gradient = function Gradient(_ref) {
|
|
|
10624
10696
|
direction = _ref$direction === void 0 ? 'to right' : _ref$direction,
|
|
10625
10697
|
type = _ref.type,
|
|
10626
10698
|
prefixCls = _ref.prefixCls;
|
|
10627
|
-
var gradientColors = a$
|
|
10699
|
+
var gradientColors = a$n.useMemo(function () {
|
|
10628
10700
|
return colors.map(function (color, idx) {
|
|
10629
10701
|
var result = generateColor$1(color);
|
|
10630
10702
|
if (type === 'alpha' && idx === colors.length - 1) {
|
|
@@ -10633,7 +10705,7 @@ var Gradient = function Gradient(_ref) {
|
|
|
10633
10705
|
return result.toRgbString();
|
|
10634
10706
|
}).join(',');
|
|
10635
10707
|
}, [colors, type]);
|
|
10636
|
-
return /*#__PURE__*/a$
|
|
10708
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10637
10709
|
className: "".concat(prefixCls, "-gradient"),
|
|
10638
10710
|
style: {
|
|
10639
10711
|
position: 'absolute',
|
|
@@ -10651,9 +10723,9 @@ var Slider = function Slider(props) {
|
|
|
10651
10723
|
onChangeComplete = props.onChangeComplete,
|
|
10652
10724
|
color = props.color,
|
|
10653
10725
|
type = props.type;
|
|
10654
|
-
var sliderRef = a$
|
|
10655
|
-
var transformRef = a$
|
|
10656
|
-
var colorRef = a$
|
|
10726
|
+
var sliderRef = a$n.useRef();
|
|
10727
|
+
var transformRef = a$n.useRef();
|
|
10728
|
+
var colorRef = a$n.useRef(color);
|
|
10657
10729
|
var getValue = function getValue(c) {
|
|
10658
10730
|
return type === 'hue' ? c.getHue() : c.a * 100;
|
|
10659
10731
|
};
|
|
@@ -10685,7 +10757,7 @@ var Slider = function Slider(props) {
|
|
|
10685
10757
|
_useColorDrag2 = _slicedToArray(_useColorDrag, 2),
|
|
10686
10758
|
offset = _useColorDrag2[0],
|
|
10687
10759
|
dragStartHandle = _useColorDrag2[1];
|
|
10688
|
-
var handleColor = a$
|
|
10760
|
+
var handleColor = a$n.useMemo(function () {
|
|
10689
10761
|
if (type === 'hue') {
|
|
10690
10762
|
var hsb = color.toHsb();
|
|
10691
10763
|
hsb.s = 1;
|
|
@@ -10698,29 +10770,29 @@ var Slider = function Slider(props) {
|
|
|
10698
10770
|
}, [color, type]);
|
|
10699
10771
|
|
|
10700
10772
|
// ========================= Gradient =========================
|
|
10701
|
-
var gradientList = a$
|
|
10773
|
+
var gradientList = a$n.useMemo(function () {
|
|
10702
10774
|
return colors.map(function (info) {
|
|
10703
10775
|
return "".concat(info.color, " ").concat(info.percent, "%");
|
|
10704
10776
|
});
|
|
10705
10777
|
}, [colors]);
|
|
10706
10778
|
|
|
10707
10779
|
// ========================== Render ==========================
|
|
10708
|
-
return /*#__PURE__*/a$
|
|
10780
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10709
10781
|
ref: sliderRef,
|
|
10710
10782
|
className: classNames("".concat(prefixCls, "-slider"), "".concat(prefixCls, "-slider-").concat(type)),
|
|
10711
10783
|
onMouseDown: dragStartHandle,
|
|
10712
10784
|
onTouchStart: dragStartHandle
|
|
10713
|
-
}, /*#__PURE__*/a$
|
|
10785
|
+
}, /*#__PURE__*/a$n.createElement(Palette, {
|
|
10714
10786
|
prefixCls: prefixCls
|
|
10715
|
-
}, /*#__PURE__*/a$
|
|
10787
|
+
}, /*#__PURE__*/a$n.createElement(Transform, {
|
|
10716
10788
|
x: offset.x,
|
|
10717
10789
|
y: offset.y,
|
|
10718
10790
|
ref: transformRef
|
|
10719
|
-
}, /*#__PURE__*/a$
|
|
10791
|
+
}, /*#__PURE__*/a$n.createElement(Handler, {
|
|
10720
10792
|
size: "small",
|
|
10721
10793
|
color: handleColor.toHexString(),
|
|
10722
10794
|
prefixCls: prefixCls
|
|
10723
|
-
})), /*#__PURE__*/a$
|
|
10795
|
+
})), /*#__PURE__*/a$n.createElement(Gradient, {
|
|
10724
10796
|
colors: gradientList,
|
|
10725
10797
|
type: type,
|
|
10726
10798
|
prefixCls: prefixCls
|
|
@@ -10757,7 +10829,7 @@ var HUE_COLORS = [{
|
|
|
10757
10829
|
color: 'rgb(255, 0, 0)',
|
|
10758
10830
|
percent: 100
|
|
10759
10831
|
}];
|
|
10760
|
-
var ColorPicker = /*#__PURE__*/a$
|
|
10832
|
+
var ColorPicker = /*#__PURE__*/a$n.forwardRef(function (props, ref) {
|
|
10761
10833
|
var value = props.value,
|
|
10762
10834
|
defaultValue = props.defaultValue,
|
|
10763
10835
|
_props$prefixCls = props.prefixCls,
|
|
@@ -10783,7 +10855,7 @@ var ColorPicker = /*#__PURE__*/a$m.forwardRef(function (props, ref) {
|
|
|
10783
10855
|
_useColorState2 = _slicedToArray(_useColorState, 2),
|
|
10784
10856
|
colorValue = _useColorState2[0],
|
|
10785
10857
|
setColorValue = _useColorState2[1];
|
|
10786
|
-
var alphaColor = a$
|
|
10858
|
+
var alphaColor = a$n.useMemo(function () {
|
|
10787
10859
|
return colorValue.setA(1).toRgbString();
|
|
10788
10860
|
}, [colorValue]);
|
|
10789
10861
|
|
|
@@ -10836,15 +10908,15 @@ var ColorPicker = /*#__PURE__*/a$m.forwardRef(function (props, ref) {
|
|
|
10836
10908
|
disabled: disabled,
|
|
10837
10909
|
color: colorValue
|
|
10838
10910
|
};
|
|
10839
|
-
var defaultPanel = /*#__PURE__*/a$
|
|
10911
|
+
var defaultPanel = /*#__PURE__*/a$n.createElement(a$n.Fragment, null, /*#__PURE__*/a$n.createElement(Picker, _extends({
|
|
10840
10912
|
onChange: handleChange
|
|
10841
10913
|
}, sharedSliderProps, {
|
|
10842
10914
|
onChangeComplete: onChangeComplete
|
|
10843
|
-
})), /*#__PURE__*/a$
|
|
10915
|
+
})), /*#__PURE__*/a$n.createElement("div", {
|
|
10844
10916
|
className: "".concat(prefixCls, "-slider-container")
|
|
10845
|
-
}, /*#__PURE__*/a$
|
|
10917
|
+
}, /*#__PURE__*/a$n.createElement("div", {
|
|
10846
10918
|
className: classNames("".concat(prefixCls, "-slider-group"), _defineProperty({}, "".concat(prefixCls, "-slider-group-disabled-alpha"), disabledAlpha))
|
|
10847
|
-
}, /*#__PURE__*/a$
|
|
10919
|
+
}, /*#__PURE__*/a$n.createElement(Slider, _extends({}, sharedSliderProps, {
|
|
10848
10920
|
type: "hue",
|
|
10849
10921
|
colors: HUE_COLORS,
|
|
10850
10922
|
min: 0,
|
|
@@ -10852,7 +10924,7 @@ var ColorPicker = /*#__PURE__*/a$m.forwardRef(function (props, ref) {
|
|
|
10852
10924
|
value: colorValue.getHue(),
|
|
10853
10925
|
onChange: onHueChange,
|
|
10854
10926
|
onChangeComplete: onHueChangeComplete
|
|
10855
|
-
})), !disabledAlpha && /*#__PURE__*/a$
|
|
10927
|
+
})), !disabledAlpha && /*#__PURE__*/a$n.createElement(Slider, _extends({}, sharedSliderProps, {
|
|
10856
10928
|
type: "alpha",
|
|
10857
10929
|
colors: [{
|
|
10858
10930
|
percent: 0,
|
|
@@ -10866,11 +10938,11 @@ var ColorPicker = /*#__PURE__*/a$m.forwardRef(function (props, ref) {
|
|
|
10866
10938
|
value: colorValue.a * 100,
|
|
10867
10939
|
onChange: onAlphaChange,
|
|
10868
10940
|
onChangeComplete: onAlphaChangeComplete
|
|
10869
|
-
}))), /*#__PURE__*/a$
|
|
10941
|
+
}))), /*#__PURE__*/a$n.createElement(ColorBlock, {
|
|
10870
10942
|
color: colorValue.toRgbString(),
|
|
10871
10943
|
prefixCls: prefixCls
|
|
10872
10944
|
})));
|
|
10873
|
-
return /*#__PURE__*/a$
|
|
10945
|
+
return /*#__PURE__*/a$n.createElement("div", {
|
|
10874
10946
|
className: mergeCls,
|
|
10875
10947
|
style: style,
|
|
10876
10948
|
ref: ref
|
|
@@ -15080,7 +15152,7 @@ function stringify(value) {
|
|
|
15080
15152
|
}
|
|
15081
15153
|
var useWatchWarning = process.env.NODE_ENV !== 'production' ? function (namePath) {
|
|
15082
15154
|
var fullyStr = namePath.join('__RC_FIELD_FORM_SPLIT__');
|
|
15083
|
-
var nameStrRef = a$
|
|
15155
|
+
var nameStrRef = a$n.useRef(fullyStr);
|
|
15084
15156
|
warningOnce(nameStrRef.current === fullyStr, '`useWatch` is not support dynamic `namePath`. Please provide static instead.');
|
|
15085
15157
|
} : function () {};
|
|
15086
15158
|
|
|
@@ -15099,16 +15171,16 @@ function useWatch$1() {
|
|
|
15099
15171
|
form: _form
|
|
15100
15172
|
} : _form;
|
|
15101
15173
|
var form = options.form;
|
|
15102
|
-
var _useState = a$
|
|
15174
|
+
var _useState = a$n.useState(),
|
|
15103
15175
|
_useState2 = _slicedToArray(_useState, 2),
|
|
15104
15176
|
value = _useState2[0],
|
|
15105
15177
|
setValue = _useState2[1];
|
|
15106
|
-
var valueStr = a$
|
|
15178
|
+
var valueStr = a$n.useMemo(function () {
|
|
15107
15179
|
return stringify(value);
|
|
15108
15180
|
}, [value]);
|
|
15109
|
-
var valueStrRef = a$
|
|
15181
|
+
var valueStrRef = a$n.useRef(valueStr);
|
|
15110
15182
|
valueStrRef.current = valueStr;
|
|
15111
|
-
var fieldContext = a$
|
|
15183
|
+
var fieldContext = a$n.useContext(Context);
|
|
15112
15184
|
var formInstance = form || fieldContext;
|
|
15113
15185
|
var isValidForm = formInstance && formInstance._init;
|
|
15114
15186
|
|
|
@@ -15117,10 +15189,10 @@ function useWatch$1() {
|
|
|
15117
15189
|
warningOnce(args.length === 2 ? form ? isValidForm : true : isValidForm, 'useWatch requires a form instance since it can not auto detect from context.');
|
|
15118
15190
|
}
|
|
15119
15191
|
var namePath = getNamePath(dependencies);
|
|
15120
|
-
var namePathRef = a$
|
|
15192
|
+
var namePathRef = a$n.useRef(namePath);
|
|
15121
15193
|
namePathRef.current = namePath;
|
|
15122
15194
|
useWatchWarning(namePath);
|
|
15123
|
-
a$
|
|
15195
|
+
a$n.useEffect(function () {
|
|
15124
15196
|
// Skip if not exist form instance
|
|
15125
15197
|
if (!isValidForm) {
|
|
15126
15198
|
return;
|
|
@@ -15206,13 +15278,13 @@ const ContextIsolator = props => {
|
|
|
15206
15278
|
}
|
|
15207
15279
|
let result = children;
|
|
15208
15280
|
if (form) {
|
|
15209
|
-
result = /*#__PURE__*/a$
|
|
15281
|
+
result = /*#__PURE__*/a$n.createElement(NoFormStyle, {
|
|
15210
15282
|
override: true,
|
|
15211
15283
|
status: true
|
|
15212
15284
|
}, result);
|
|
15213
15285
|
}
|
|
15214
15286
|
if (space) {
|
|
15215
|
-
result = /*#__PURE__*/a$
|
|
15287
|
+
result = /*#__PURE__*/a$n.createElement(NoCompactStyle, null, result);
|
|
15216
15288
|
}
|
|
15217
15289
|
return result;
|
|
15218
15290
|
};
|
|
@@ -16959,8 +17031,8 @@ var Tooltip$2 = function Tooltip(props, ref) {
|
|
|
16959
17031
|
tooltipStyles = props.styles,
|
|
16960
17032
|
restProps = _objectWithoutProperties(props, _excluded);
|
|
16961
17033
|
var mergedId = useId(id);
|
|
16962
|
-
var triggerRef = a$
|
|
16963
|
-
a$
|
|
17034
|
+
var triggerRef = a$n.useRef(null);
|
|
17035
|
+
a$n.useImperativeHandle(ref, function () {
|
|
16964
17036
|
return triggerRef.current;
|
|
16965
17037
|
});
|
|
16966
17038
|
var extraProps = _objectSpread2({}, restProps);
|
|
@@ -17007,7 +17079,7 @@ var Tooltip$2 = function Tooltip(props, ref) {
|
|
|
17007
17079
|
arrow: showArrow
|
|
17008
17080
|
}, extraProps), getChildren());
|
|
17009
17081
|
};
|
|
17010
|
-
var Tooltip$3 = /*#__PURE__*/a$
|
|
17082
|
+
var Tooltip$3 = /*#__PURE__*/a$n.forwardRef(Tooltip$2);
|
|
17011
17083
|
|
|
17012
17084
|
function getArrowToken(token) {
|
|
17013
17085
|
const {
|
|
@@ -17790,15 +17862,15 @@ const Tooltip = ({ title, placement, type = TooltipIconType.INFO, ariaLabel, ico
|
|
|
17790
17862
|
const renderIcon = (type) => {
|
|
17791
17863
|
switch (type) {
|
|
17792
17864
|
case TooltipIconType.INFO:
|
|
17793
|
-
return (a$
|
|
17865
|
+
return (a$n.createElement(StellaIcon, { iconName: "help", size: iconSize, dataTestId: "info-icon" }));
|
|
17794
17866
|
case TooltipIconType.WARNING:
|
|
17795
|
-
return (a$
|
|
17867
|
+
return (a$n.createElement(StellaIcon, { iconName: "warning", size: iconSize, dataTestId: "warning-icon" }));
|
|
17796
17868
|
default:
|
|
17797
|
-
return a$
|
|
17869
|
+
return a$n.createElement(StellaIcon, { iconName: "help", size: iconSize });
|
|
17798
17870
|
}
|
|
17799
17871
|
};
|
|
17800
|
-
return (a$
|
|
17801
|
-
a$
|
|
17872
|
+
return (a$n.createElement(Tooltip$1, { title: title, placement: placement, trigger: ["hover", "focus"], classNames: { body: "DSL-custom-tooltip" }, className: className, arrow: false, id: id, ...htmlProps },
|
|
17873
|
+
a$n.createElement("button", { className: "DSL-tooltip-button", type: "button", "aria-label": ariaLabel ?? title }, renderIcon(type))));
|
|
17802
17874
|
};
|
|
17803
17875
|
|
|
17804
17876
|
const RequiredIcon = styled(StellaIcon) `
|
|
@@ -17825,18 +17897,24 @@ const LabelComponent = styled.label `
|
|
|
17825
17897
|
font-size: 0px;
|
|
17826
17898
|
height: 0px;
|
|
17827
17899
|
`};
|
|
17900
|
+
${({ $isPointerOnHover }) => $isPointerOnHover &&
|
|
17901
|
+
styled.css `
|
|
17902
|
+
:hover {
|
|
17903
|
+
cursor: pointer;
|
|
17904
|
+
}
|
|
17905
|
+
`}
|
|
17828
17906
|
`;
|
|
17829
17907
|
const LabelContainer = styled.span `
|
|
17830
17908
|
display: flex;
|
|
17831
17909
|
align-items: center;
|
|
17832
17910
|
`;
|
|
17833
17911
|
|
|
17834
|
-
const Label = ({ hideLabel, labelValue, required = false, tooltipText, children, htmlFor, htmlProps, id, className, }) => {
|
|
17835
|
-
return (a$
|
|
17836
|
-
a$
|
|
17912
|
+
const Label = ({ hideLabel, labelValue, required = false, tooltipText, children, htmlFor, htmlProps, id, isPointerOnHover = false, className, }) => {
|
|
17913
|
+
return (a$n.createElement(LabelComponent, { "$hideLabel": hideLabel, "$isPointerOnHover": isPointerOnHover, htmlFor: htmlFor, className: className, id: id, ...htmlProps },
|
|
17914
|
+
a$n.createElement(LabelContainer, null,
|
|
17837
17915
|
labelValue,
|
|
17838
|
-
required && (a$
|
|
17839
|
-
!!tooltipText && (a$
|
|
17916
|
+
required && (a$n.createElement(RequiredIcon, { size: 11, iconName: "required", dataTestId: "required-icon" })),
|
|
17917
|
+
!!tooltipText && (a$n.createElement(ToolTipIcon, { iconSize: 14, title: tooltipText, placement: "right" }))),
|
|
17840
17918
|
children));
|
|
17841
17919
|
};
|
|
17842
17920
|
|
|
@@ -18003,21 +18081,21 @@ const CustomLoader = styled(m$5) `
|
|
|
18003
18081
|
`;
|
|
18004
18082
|
|
|
18005
18083
|
const Loader = ({ size = 14, dataTestId, color, className, id, }) => {
|
|
18006
|
-
return (a$
|
|
18084
|
+
return (a$n.createElement(CustomLoader, { "data-testid": dataTestId, size: size, weight: "bold", color: color ?? "var(--primary)", className: className, id: id }));
|
|
18007
18085
|
};
|
|
18008
18086
|
|
|
18009
|
-
const StellaButton = a$
|
|
18087
|
+
const StellaButton = a$n.forwardRef(({ disabled, variant = "primary", label, startIcon, endIcon, isLoading = false, className, id, htmlProps, onClick, preventDefault = true, type = "button", }, ref) => {
|
|
18010
18088
|
const getIcon = (iconType, dataTestId) => {
|
|
18011
|
-
return (a$
|
|
18089
|
+
return (a$n.createElement(StellaIcon, { iconName: iconType, dataTestId: dataTestId, size: 14 }));
|
|
18012
18090
|
};
|
|
18013
18091
|
const handleClick = (e) => {
|
|
18014
18092
|
preventDefault && e.preventDefault();
|
|
18015
18093
|
onClick?.(e);
|
|
18016
18094
|
};
|
|
18017
|
-
return (a$
|
|
18095
|
+
return (a$n.createElement(ButtonComponent, { "$variant": variant, "$isLoading": isLoading, type: type, disabled: disabled, className: className, ref: ref, id: id, onClick: handleClick, ...htmlProps },
|
|
18018
18096
|
startIcon && getIcon(startIcon, "start-icon"),
|
|
18019
18097
|
label.toUpperCase(),
|
|
18020
|
-
isLoading && a$
|
|
18098
|
+
isLoading && a$n.createElement(Loader, { dataTestId: "loader", size: 14 }),
|
|
18021
18099
|
endIcon && !isLoading && getIcon(endIcon, "end-icon")));
|
|
18022
18100
|
});
|
|
18023
18101
|
|
|
@@ -18045,9 +18123,9 @@ const Icon = styled.div `
|
|
|
18045
18123
|
`;
|
|
18046
18124
|
|
|
18047
18125
|
const HelperText = ({ id, className, affectLayout = true, text, type = "info", htmlProps, }) => {
|
|
18048
|
-
return (a$
|
|
18049
|
-
a$
|
|
18050
|
-
a$
|
|
18126
|
+
return (a$n.createElement(Wrapper$1, { id: id, "$affectLayout": affectLayout, className: className, ...htmlProps },
|
|
18127
|
+
a$n.createElement(Icon, null, type === "info" ? (a$n.createElement(StellaIcon, { iconName: "info" })) : (a$n.createElement(StellaIcon, { iconName: "error" }))),
|
|
18128
|
+
a$n.createElement(Text, { "$type": type }, text)));
|
|
18051
18129
|
};
|
|
18052
18130
|
|
|
18053
18131
|
const IconButtonComponent = styled(ButtonComponent) `
|
|
@@ -18056,12 +18134,12 @@ const IconButtonComponent = styled(ButtonComponent) `
|
|
|
18056
18134
|
min-width: fit-content;
|
|
18057
18135
|
`;
|
|
18058
18136
|
|
|
18059
|
-
const IconButton = a$
|
|
18137
|
+
const IconButton = a$n.forwardRef(({ iconName, onClick, disabled, variant = "primary", isLoading = false, ariaLabel, preventDefault = true, className, dataTestId, id, htmlProps, size = 18, }, ref) => {
|
|
18060
18138
|
const handleClick = (e) => {
|
|
18061
18139
|
preventDefault && e.preventDefault();
|
|
18062
18140
|
onClick?.(e);
|
|
18063
18141
|
};
|
|
18064
|
-
return (a$
|
|
18142
|
+
return (a$n.createElement(IconButtonComponent, { "$variant": variant, "$isLoading": isLoading, ref: ref, disabled: disabled, className: className, "aria-label": ariaLabel, id: id, onClick: handleClick, ...htmlProps }, isLoading ? (a$n.createElement(Loader, { size: size, dataTestId: `${id ?? ""}-loader` })) : (a$n.createElement(StellaIcon, { iconName: iconName, size: size, dataTestId: dataTestId }))));
|
|
18065
18143
|
});
|
|
18066
18144
|
|
|
18067
18145
|
const Wrapper = styled.div `
|
|
@@ -18143,17 +18221,17 @@ const IconContainer = styled.div `
|
|
|
18143
18221
|
`;
|
|
18144
18222
|
|
|
18145
18223
|
const TextFieldContainer = ({ id, label, children, tooltipText, endIcon, className, rightCategory, leftCategory, helperText, dataTestId, helperTextAffectLayout = true, disabled = false, hideLabel = false, isLoading = false, hasError = false, isRequired = false, }) => {
|
|
18146
|
-
return (a$
|
|
18147
|
-
a$
|
|
18148
|
-
a$
|
|
18149
|
-
leftCategory && a$
|
|
18224
|
+
return (a$n.createElement(Wrapper, { "data-testid": dataTestId, className: className },
|
|
18225
|
+
a$n.createElement(Label, { tooltipText: tooltipText, required: isRequired, labelValue: label, hideLabel: hideLabel, id: `${id}-label`, htmlFor: `${id}-text-field` }),
|
|
18226
|
+
a$n.createElement(TextFieldWrapper, { id: id, "$hasError": hasError, "$isDisabled": disabled, "$isLoading": isLoading, "data-testid": "text-input-wrapper" },
|
|
18227
|
+
leftCategory && a$n.createElement(Category, null, leftCategory),
|
|
18150
18228
|
children,
|
|
18151
|
-
isLoading && (a$
|
|
18152
|
-
a$
|
|
18153
|
-
endIcon && !isLoading && (a$
|
|
18154
|
-
a$
|
|
18155
|
-
rightCategory && a$
|
|
18156
|
-
helperText && (a$
|
|
18229
|
+
isLoading && (a$n.createElement(IconContainer, null,
|
|
18230
|
+
a$n.createElement(Loader, { dataTestId: "textfield-loader", size: 25 }))),
|
|
18231
|
+
endIcon && !isLoading && (a$n.createElement(IconContainer, null,
|
|
18232
|
+
a$n.createElement(StellaIcon, { dataTestId: "end-icon", iconName: endIcon }))),
|
|
18233
|
+
rightCategory && a$n.createElement(Category, null, rightCategory)),
|
|
18234
|
+
helperText && (a$n.createElement(HelperText, { id: `${id}-helper-text`, text: helperText, affectLayout: helperTextAffectLayout, type: hasError ? "error" : "info" }))));
|
|
18157
18235
|
};
|
|
18158
18236
|
|
|
18159
18237
|
const TextInput = ({ id, className, htmlProps, label, onChange, onBlur, onFocus, value, isRequired, maxLength, tooltipText, helperText, endIcon, placeholder = "", textAlign = "left", helperTextAffectLayout = true, hideLabel = false, disabled = false, hasError = false, isLoading = false, ariaDescribedBy, enableAutocomplete = false, }) => {
|
|
@@ -18173,15 +18251,15 @@ const TextInput = ({ id, className, htmlProps, label, onChange, onBlur, onFocus,
|
|
|
18173
18251
|
disabled,
|
|
18174
18252
|
isLoading,
|
|
18175
18253
|
};
|
|
18176
|
-
const [inputValue, setInputValue] = a$
|
|
18254
|
+
const [inputValue, setInputValue] = a$n.useState("");
|
|
18177
18255
|
const valueToUse = value ?? inputValue;
|
|
18178
18256
|
const handleChange = (e) => {
|
|
18179
18257
|
const value = e.target.value;
|
|
18180
18258
|
setInputValue(value);
|
|
18181
18259
|
onChange(value);
|
|
18182
18260
|
};
|
|
18183
|
-
return (a$
|
|
18184
|
-
a$
|
|
18261
|
+
return (a$n.createElement(TextFieldContainer, { ...containerProps },
|
|
18262
|
+
a$n.createElement(TextFieldInput, { autoComplete: enableAutocomplete ? "on" : "off", "aria-describedby": `${id}-helper-text ${ariaDescribedBy}`, type: "text", id: `${id}-text-field`, disabled: disabled, placeholder: placeholder, onChange: handleChange, onBlur: (e) => onBlur?.(e.target.value), onFocus: (e) => onFocus?.(e.target.value), value: valueToUse, maxLength: maxLength, "$textAlign": textAlign, "$isDisabled": disabled, "$isLoading": isLoading, ...htmlProps })));
|
|
18185
18263
|
};
|
|
18186
18264
|
|
|
18187
18265
|
const CustomIconButton$2 = styled(IconButton) `
|
|
@@ -18203,17 +18281,17 @@ const PasswordInput = ({ id, className, htmlProps, label, placeholder = "Enter P
|
|
|
18203
18281
|
hideLabel,
|
|
18204
18282
|
disabled,
|
|
18205
18283
|
};
|
|
18206
|
-
const [inputValue, setInputValue] = a$
|
|
18207
|
-
const [show, setShow] = a$
|
|
18284
|
+
const [inputValue, setInputValue] = a$n.useState("");
|
|
18285
|
+
const [show, setShow] = a$n.useState(!isHidden);
|
|
18208
18286
|
const valueToUse = value ?? inputValue;
|
|
18209
18287
|
const handleChange = (e) => {
|
|
18210
18288
|
const value = e.target.value;
|
|
18211
18289
|
setInputValue(value);
|
|
18212
18290
|
onChange(value);
|
|
18213
18291
|
};
|
|
18214
|
-
return (a$
|
|
18215
|
-
a$
|
|
18216
|
-
a$
|
|
18292
|
+
return (a$n.createElement(TextFieldContainer, { ...containerProps },
|
|
18293
|
+
a$n.createElement(TextFieldInput, { autoComplete: enableAutocomplete ? "on" : "off", "aria-describedby": `${id}-helper-text ${ariaDescribedBy}`, type: show ? "text" : "password", id: `${id}-text-field`, disabled: disabled, placeholder: placeholder, onChange: handleChange, onBlur: (e) => onBlur?.(e.target.value), onFocus: (e) => onFocus?.(e.target.value), value: valueToUse, maxLength: maxLength, "$textAlign": textAlign, "$isDisabled": disabled, ...htmlProps }),
|
|
18294
|
+
a$n.createElement(CustomIconButton$2, { variant: "tertiary", iconName: show ? "eye" : "eye-slash", ariaLabel: show ? "Hide" : "Show", onClick: () => setShow(!show), disabled: disabled })));
|
|
18217
18295
|
};
|
|
18218
18296
|
|
|
18219
18297
|
const formatDynamicNumbersWithCommas = (num, decimalPlaces, isDegrees) => {
|
|
@@ -18257,9 +18335,9 @@ const NumberInput = ({ id, className, htmlProps, leftCategory, rightCategory, la
|
|
|
18257
18335
|
hideLabel,
|
|
18258
18336
|
disabled,
|
|
18259
18337
|
};
|
|
18260
|
-
const [inputValue, setInputValue] = a$
|
|
18261
|
-
const [placeholderText, setPlaceholderText] = a$
|
|
18262
|
-
const ref = a$
|
|
18338
|
+
const [inputValue, setInputValue] = a$n.useState("");
|
|
18339
|
+
const [placeholderText, setPlaceholderText] = a$n.useState(placeholder);
|
|
18340
|
+
const ref = a$n.useRef(null);
|
|
18263
18341
|
const valueToUse = value ?? inputValue;
|
|
18264
18342
|
const moveCursorBeforeDegree = () => {
|
|
18265
18343
|
const pos = ref.current?.selectionStart ?? 0;
|
|
@@ -18312,8 +18390,8 @@ const NumberInput = ({ id, className, htmlProps, leftCategory, rightCategory, la
|
|
|
18312
18390
|
!onFocus && setPlaceholderText("");
|
|
18313
18391
|
isDegrees && moveCursorBeforeDegree();
|
|
18314
18392
|
};
|
|
18315
|
-
return (a$
|
|
18316
|
-
a$
|
|
18393
|
+
return (a$n.createElement(TextFieldContainer, { ...containerProps },
|
|
18394
|
+
a$n.createElement(TextFieldInput, { ref: ref, autoComplete: enableAutocomplete ? "on" : "off", "aria-describedby": `${id}-helper-text ${ariaDescribedBy}`, type: "text", inputMode: "numeric", pattern: allowNegativeNumbers ? "^[\\d,.\\-°]*$" : "^[\\d,.°]*$", id: `${id}-text-field`, disabled: disabled || isLoading, placeholder: placeholderText, onChange: handleChange, onBlur: handleBlur, onFocus: handleFocus, onKeyDown: handleKeyDown, onClick: isDegrees ? moveCursorBeforeDegree : undefined, onKeyUp: isDegrees ? moveCursorBeforeDegree : undefined, onSelect: handleSelect, value: thousandSeparator
|
|
18317
18395
|
? formatDynamicNumbersWithCommas(valueToUse, decimalPlaces, isDegrees)
|
|
18318
18396
|
: valueToUse, maxLength: maxLength &&
|
|
18319
18397
|
maxLength +
|
|
@@ -21819,17 +21897,17 @@ const PageTotals = styled.span `
|
|
|
21819
21897
|
`;
|
|
21820
21898
|
|
|
21821
21899
|
const Pagination = ({ isLoading, rowsPerPage = 100, totalRows, ariaLabel = "Pagination", onPageChange, startingPage = 1, id, className, htmlProps, }) => {
|
|
21822
|
-
const [pageNumber, setPageNumber] = a$
|
|
21823
|
-
const [total, setTotal] = a$
|
|
21824
|
-
const totalPages = a$
|
|
21900
|
+
const [pageNumber, setPageNumber] = a$n.useState(startingPage || 1);
|
|
21901
|
+
const [total, setTotal] = a$n.useState(totalRows || 5);
|
|
21902
|
+
const totalPages = a$n.useMemo(() => {
|
|
21825
21903
|
return Math.ceil(total / rowsPerPage);
|
|
21826
21904
|
}, [rowsPerPage, total]);
|
|
21827
|
-
const currentRows = a$
|
|
21905
|
+
const currentRows = a$n.useMemo(() => {
|
|
21828
21906
|
const startRow = (pageNumber - 1) * rowsPerPage + 1;
|
|
21829
21907
|
const endRow = Math.min(startRow + rowsPerPage - 1, total);
|
|
21830
21908
|
return { startRow, endRow };
|
|
21831
21909
|
}, [pageNumber, rowsPerPage, total]);
|
|
21832
|
-
a$
|
|
21910
|
+
a$n.useEffect(() => {
|
|
21833
21911
|
setPageNumber(startingPage);
|
|
21834
21912
|
setTotal(totalRows);
|
|
21835
21913
|
}, [totalRows, startingPage]);
|
|
@@ -21839,29 +21917,29 @@ const Pagination = ({ isLoading, rowsPerPage = 100, totalRows, ariaLabel = "Pagi
|
|
|
21839
21917
|
onPageChange?.(newPage, rowsPerPage);
|
|
21840
21918
|
}
|
|
21841
21919
|
};
|
|
21842
|
-
return isLoading ? (a$
|
|
21843
|
-
a$
|
|
21844
|
-
a$
|
|
21845
|
-
a$
|
|
21920
|
+
return isLoading ? (a$n.createElement(LoadingContainer, { "data-testid": "loading-container" })) : (a$n.createElement(a$n.Fragment, null,
|
|
21921
|
+
a$n.createElement(PaginationContainer, { id: id, className: className, "aria-label": ariaLabel, ...htmlProps },
|
|
21922
|
+
a$n.createElement(RowInfo, null,
|
|
21923
|
+
a$n.createElement(DarkText, null,
|
|
21846
21924
|
"Rows per page \u00A0",
|
|
21847
21925
|
rowsPerPage),
|
|
21848
|
-
a$
|
|
21926
|
+
a$n.createElement(LightText, null,
|
|
21849
21927
|
"Rows ",
|
|
21850
21928
|
currentRows.startRow,
|
|
21851
21929
|
" - ",
|
|
21852
21930
|
currentRows.endRow,
|
|
21853
21931
|
" of ",
|
|
21854
21932
|
totalRows)),
|
|
21855
|
-
a$
|
|
21856
|
-
a$
|
|
21857
|
-
a$
|
|
21858
|
-
totalPages > 1 ? (a$
|
|
21859
|
-
a$
|
|
21860
|
-
a$
|
|
21861
|
-
a$
|
|
21933
|
+
a$n.createElement(PageInfo, null,
|
|
21934
|
+
a$n.createElement(PageText, null, "Page"),
|
|
21935
|
+
a$n.createElement(IconButton, { iconName: "chevron-left", ariaLabel: "previous page", size: 10, disabled: pageNumber === 1, onClick: () => handlePageChange(pageNumber - 1), variant: "tertiary" }),
|
|
21936
|
+
totalPages > 1 ? (a$n.createElement(CustomSelectContainer, { "$currentPageCount": pageNumber },
|
|
21937
|
+
a$n.createElement(CustomSelect, { name: "page-number", id: "page-number-select", value: pageNumber, onChange: (e) => handlePageChange(Number(e.target.value)) }, Array.from({ length: totalPages }, (_, i) => (a$n.createElement("option", { key: i + 1, value: i + 1 }, i + 1)))),
|
|
21938
|
+
a$n.createElement(SelectCaret, { iconName: "chevron-down", size: 16 }))) : (a$n.createElement(DarkText, null, "1")),
|
|
21939
|
+
a$n.createElement(PageTotals, null,
|
|
21862
21940
|
"of \u00A0",
|
|
21863
21941
|
totalPages),
|
|
21864
|
-
a$
|
|
21942
|
+
a$n.createElement(IconButton, { iconName: "chevron-right", ariaLabel: "next page", size: 10, disabled: pageNumber === totalPages, onClick: () => handlePageChange(pageNumber + 1), variant: "tertiary" })))));
|
|
21865
21943
|
};
|
|
21866
21944
|
|
|
21867
21945
|
const HeaderCell = styled.th `
|
|
@@ -22221,21 +22299,21 @@ const ClearFilterButtonRow = styled.div `
|
|
|
22221
22299
|
`;
|
|
22222
22300
|
|
|
22223
22301
|
const IndeterminateCheckbox = ({ isIndeterminate, isChecked, onChange, }) => {
|
|
22224
|
-
const ref = a$
|
|
22225
|
-
a$
|
|
22302
|
+
const ref = a$n.useRef(null);
|
|
22303
|
+
a$n.useEffect(() => {
|
|
22226
22304
|
if (ref.current)
|
|
22227
22305
|
ref.current.indeterminate = !!isIndeterminate;
|
|
22228
22306
|
}, [isIndeterminate]);
|
|
22229
|
-
return (a$
|
|
22307
|
+
return (a$n.createElement(Checkbox, { ref: ref, checked: isChecked, onChange: (e) => onChange?.(e) }));
|
|
22230
22308
|
};
|
|
22231
22309
|
|
|
22232
22310
|
/**
|
|
22233
22311
|
* Returns a debounced version of a callback, along with flush and cancel methods.
|
|
22234
22312
|
*/
|
|
22235
22313
|
function useDebounceCallback(callback, delay) {
|
|
22236
|
-
const timeoutRef = a$
|
|
22237
|
-
const lastArgsRef = a$
|
|
22238
|
-
const debounced = a$
|
|
22314
|
+
const timeoutRef = a$n.useRef(null);
|
|
22315
|
+
const lastArgsRef = a$n.useRef(null);
|
|
22316
|
+
const debounced = a$n.useCallback((...args) => {
|
|
22239
22317
|
lastArgsRef.current = args;
|
|
22240
22318
|
if (timeoutRef.current)
|
|
22241
22319
|
clearTimeout(timeoutRef.current);
|
|
@@ -22245,14 +22323,14 @@ function useDebounceCallback(callback, delay) {
|
|
|
22245
22323
|
timeoutRef.current = null;
|
|
22246
22324
|
}, delay);
|
|
22247
22325
|
}, [callback, delay]);
|
|
22248
|
-
const flush = a$
|
|
22326
|
+
const flush = a$n.useCallback(() => {
|
|
22249
22327
|
if (timeoutRef.current && lastArgsRef.current) {
|
|
22250
22328
|
clearTimeout(timeoutRef.current);
|
|
22251
22329
|
callback(...lastArgsRef.current);
|
|
22252
22330
|
timeoutRef.current = null;
|
|
22253
22331
|
}
|
|
22254
22332
|
}, [callback]);
|
|
22255
|
-
const cancel = a$
|
|
22333
|
+
const cancel = a$n.useCallback(() => {
|
|
22256
22334
|
if (timeoutRef.current) {
|
|
22257
22335
|
clearTimeout(timeoutRef.current);
|
|
22258
22336
|
timeoutRef.current = null;
|
|
@@ -22278,24 +22356,24 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22278
22356
|
const columnDef = column.columnDef;
|
|
22279
22357
|
const meta = columnDef.meta;
|
|
22280
22358
|
// Filter dropdown logic
|
|
22281
|
-
const menuRef = a$
|
|
22282
|
-
const buttonRef = a$
|
|
22283
|
-
const [showFilter, setShowFilter] = a$
|
|
22284
|
-
const [coords, setCoords] = a$
|
|
22285
|
-
const [tempFilters, setTempFilters] = a$
|
|
22286
|
-
const [currentAppliedFilters, setCurrentAppliedFilters] = a$
|
|
22287
|
-
const [filterOptions, setFilterOptions] = a$
|
|
22359
|
+
const menuRef = a$n.useRef(null);
|
|
22360
|
+
const buttonRef = a$n.useRef(null);
|
|
22361
|
+
const [showFilter, setShowFilter] = a$n.useState(false);
|
|
22362
|
+
const [coords, setCoords] = a$n.useState({ top: 0, left: 0 });
|
|
22363
|
+
const [tempFilters, setTempFilters] = a$n.useState([]);
|
|
22364
|
+
const [currentAppliedFilters, setCurrentAppliedFilters] = a$n.useState([]);
|
|
22365
|
+
const [filterOptions, setFilterOptions] = a$n.useState([]);
|
|
22288
22366
|
const displayOptions = serverSide
|
|
22289
22367
|
? filterOptions
|
|
22290
22368
|
: normalizeOptions(Array.from(header.column.getFacetedUniqueValues().keys()));
|
|
22291
|
-
const [textAlign, setTextAlign] = a$
|
|
22369
|
+
const [textAlign, setTextAlign] = a$n.useState("left");
|
|
22292
22370
|
const [handleSave, { flush }] = useDebounceCallback((value) => {
|
|
22293
22371
|
column?.setFilterValue([value]);
|
|
22294
22372
|
if (value === "")
|
|
22295
22373
|
column?.setFilterValue([]);
|
|
22296
22374
|
onFilterApply?.();
|
|
22297
22375
|
}, 300);
|
|
22298
|
-
a$
|
|
22376
|
+
a$n.useEffect(() => {
|
|
22299
22377
|
setFilterOptions(normalizeOptions(meta?.filterOptions || []));
|
|
22300
22378
|
}, [meta]);
|
|
22301
22379
|
const toggleMenu = (e) => {
|
|
@@ -22314,7 +22392,7 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22314
22392
|
setShowFilter(active);
|
|
22315
22393
|
};
|
|
22316
22394
|
// Close on outside click
|
|
22317
|
-
a$
|
|
22395
|
+
a$n.useEffect(() => {
|
|
22318
22396
|
if (!showFilter)
|
|
22319
22397
|
return;
|
|
22320
22398
|
const handleClickOutside = (e) => {
|
|
@@ -22329,19 +22407,19 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22329
22407
|
document.addEventListener("click", handleClickOutside, true);
|
|
22330
22408
|
return () => document.removeEventListener("click", handleClickOutside, true);
|
|
22331
22409
|
}, [showFilter]);
|
|
22332
|
-
a$
|
|
22410
|
+
a$n.useEffect(() => {
|
|
22333
22411
|
setTextAlign(meta?.headerAlign || (meta?.dataType === "number" ? "right" : "left"));
|
|
22334
22412
|
}, [meta]);
|
|
22335
|
-
a$
|
|
22413
|
+
a$n.useEffect(() => {
|
|
22336
22414
|
const currentFilters = filters?.[header.id];
|
|
22337
22415
|
setTempFilters(currentFilters ? currentFilters : []);
|
|
22338
22416
|
}, [filters]);
|
|
22339
|
-
a$
|
|
22417
|
+
a$n.useEffect(() => {
|
|
22340
22418
|
if (meta?.pin) {
|
|
22341
22419
|
column.pin(meta?.pin);
|
|
22342
22420
|
}
|
|
22343
22421
|
}, []);
|
|
22344
|
-
return (a$
|
|
22422
|
+
return (a$n.createElement(HeaderCell, { "$isPinnedLeft": column.getIsPinned() === "left", "$isPinnedRight": column.getIsPinned() === "right", "$columnInfo": column, "$filterMenuOpen": showFilter, style: {
|
|
22345
22423
|
textAlign: meta?.headerAlign || (meta?.dataType === "number" ? "right" : "left"),
|
|
22346
22424
|
width: header.getSize(),
|
|
22347
22425
|
minWidth: header.getSize(),
|
|
@@ -22351,33 +22429,33 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22351
22429
|
? "none"
|
|
22352
22430
|
: undefined,
|
|
22353
22431
|
} },
|
|
22354
|
-
a$
|
|
22432
|
+
a$n.createElement(HeaderCellPosition, { style: {
|
|
22355
22433
|
justifyContent: textAlign === "left" ? "start" : "end",
|
|
22356
22434
|
} },
|
|
22357
|
-
textAlign === "left" && (a$
|
|
22358
|
-
header.column.getCanFilter() && (a$
|
|
22435
|
+
textAlign === "left" && (a$n.createElement("span", { style: { fontWeight: 600 } }, flexRender(columnDef.header, header.getContext()))),
|
|
22436
|
+
header.column.getCanFilter() && (a$n.createElement("div", { style: {
|
|
22359
22437
|
display: "flex",
|
|
22360
22438
|
alignItems: "center",
|
|
22361
22439
|
position: "relative",
|
|
22362
22440
|
} },
|
|
22363
|
-
a$
|
|
22441
|
+
a$n.createElement(CustomIconButton$1, { className: "icon", iconName: "filter", ariaLabel: "Filter Button", variant: "tertiary", "$active": filters[header.id]?.length > 0 || showFilter, onClick: (e) => toggleMenu(e), ref: buttonRef }),
|
|
22364
22442
|
showFilter &&
|
|
22365
|
-
ReactDOM.createPortal(a$
|
|
22443
|
+
ReactDOM.createPortal(a$n.createElement(FilterMenu, { style: {
|
|
22366
22444
|
top: coords.top,
|
|
22367
22445
|
left: coords.left,
|
|
22368
22446
|
position: "absolute",
|
|
22369
22447
|
}, ref: menuRef },
|
|
22370
|
-
a$
|
|
22371
|
-
meta?.filterMode === "search" && (a$
|
|
22372
|
-
a$
|
|
22448
|
+
a$n.createElement(MenuItemGroup, null,
|
|
22449
|
+
meta?.filterMode === "search" && (a$n.createElement("div", { style: { padding: "4px 10px" } },
|
|
22450
|
+
a$n.createElement(TextInput, { id: `${columnDef.header}-search`, label: `${columnDef.header} search`, placeholder: "Search", hideLabel: true, onChange: (value) => {
|
|
22373
22451
|
value === ""
|
|
22374
22452
|
? setTempFilters([])
|
|
22375
22453
|
: setTempFilters([value]);
|
|
22376
22454
|
!serverSide && handleSave(value);
|
|
22377
22455
|
}, onBlur: () => !serverSide && flush(), endIcon: "search", value: tempFilters?.[0] }))),
|
|
22378
22456
|
(meta?.filterMode === "multiSelect" ||
|
|
22379
|
-
!meta?.filterMode) && (a$
|
|
22380
|
-
a$
|
|
22457
|
+
!meta?.filterMode) && (a$n.createElement(MenuItem, { key: "select-all" },
|
|
22458
|
+
a$n.createElement(Checkbox, { id: "all-checkbox", name: "all-checkbox", checked: displayOptions?.every((opt) => tempFilters?.includes(opt.key)), onChange: () => {
|
|
22381
22459
|
setTempFilters((prev) => {
|
|
22382
22460
|
if (prev?.length === displayOptions?.length) {
|
|
22383
22461
|
return [];
|
|
@@ -22387,10 +22465,10 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22387
22465
|
}
|
|
22388
22466
|
});
|
|
22389
22467
|
} }),
|
|
22390
|
-
a$
|
|
22468
|
+
a$n.createElement(FilterBoxLabel, { htmlFor: "all-checkbox" }, "Select All"))),
|
|
22391
22469
|
displayOptions?.map(({ key, value }, index) => {
|
|
22392
22470
|
if (meta?.filterMode === "singleSelect") {
|
|
22393
|
-
return (a$
|
|
22471
|
+
return (a$n.createElement(MenuItemOption, { key: `${key}-${index}`, id: `${key}-button`, onClick: () => {
|
|
22394
22472
|
setCurrentAppliedFilters([key]);
|
|
22395
22473
|
column?.setFilterValue([key]);
|
|
22396
22474
|
showFilterMenu(false);
|
|
@@ -22399,8 +22477,8 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22399
22477
|
}
|
|
22400
22478
|
if (meta?.filterMode === "multiSelect" ||
|
|
22401
22479
|
!meta?.filterMode) {
|
|
22402
|
-
return (a$
|
|
22403
|
-
a$
|
|
22480
|
+
return (a$n.createElement(MenuItem, { key: key },
|
|
22481
|
+
a$n.createElement(Checkbox, { id: `${key}-checkbox`, name: `${key}-checkbox`, checked: tempFilters?.includes(key), onChange: () => {
|
|
22404
22482
|
setTempFilters((prev) => {
|
|
22405
22483
|
if (prev?.includes(key))
|
|
22406
22484
|
return prev.filter((i) => i !== key);
|
|
@@ -22408,33 +22486,33 @@ const TableHeaderCell = ({ header, serverSide, filters, sorting, scrollPosition,
|
|
|
22408
22486
|
return [...prev, key];
|
|
22409
22487
|
});
|
|
22410
22488
|
} }),
|
|
22411
|
-
a$
|
|
22412
|
-
a$
|
|
22489
|
+
a$n.createElement(FilterLabelTransparent, null, value),
|
|
22490
|
+
a$n.createElement(FilterBoxLabel, { htmlFor: `${key}-checkbox` }, value)));
|
|
22413
22491
|
}
|
|
22414
22492
|
})),
|
|
22415
22493
|
(meta?.filterMode === "multiSelect" ||
|
|
22416
22494
|
(meta?.filterMode === "search" && serverSide) ||
|
|
22417
|
-
!meta?.filterMode) && (a$
|
|
22495
|
+
!meta?.filterMode) && (a$n.createElement(MenuButton, { key: "apply", onClick: () => {
|
|
22418
22496
|
setCurrentAppliedFilters(tempFilters);
|
|
22419
22497
|
column?.setFilterValue(tempFilters?.length > 0 ? tempFilters : []);
|
|
22420
22498
|
showFilterMenu(false);
|
|
22421
22499
|
onFilterApply?.();
|
|
22422
22500
|
} }, "Apply Selection")),
|
|
22423
|
-
filters?.[header.id]?.length > 0 && (a$
|
|
22501
|
+
filters?.[header.id]?.length > 0 && (a$n.createElement(MenuButton, { key: "clear", onClick: () => {
|
|
22424
22502
|
column?.setFilterValue([]);
|
|
22425
22503
|
showFilterMenu(false);
|
|
22426
22504
|
setTempFilters([]);
|
|
22427
22505
|
setCurrentAppliedFilters([]);
|
|
22428
22506
|
onFilterApply?.();
|
|
22429
22507
|
} }, "Clear Filter"))), document.body))),
|
|
22430
|
-
header.column.getCanSort() && (a$
|
|
22431
|
-
textAlign === "right" && (a$
|
|
22508
|
+
header.column.getCanSort() && (a$n.createElement(SortButton, { className: "icon", iconName: "sort", ariaLabel: "Sort Button", variant: "tertiary", "$active": sorting.some((s) => s.id === header.column.id), "$sort": column.getIsSorted(), onClick: (e) => header.column.getToggleSortingHandler()?.(e) })),
|
|
22509
|
+
textAlign === "right" && (a$n.createElement("span", { style: { fontWeight: 600 } }, flexRender(columnDef.header, header.getContext()))))));
|
|
22432
22510
|
};
|
|
22433
22511
|
|
|
22434
22512
|
const RowOptions = ({ row, selectionMenuItems }) => {
|
|
22435
|
-
const [open, setOpen] = a$
|
|
22436
|
-
const buttonRef = a$
|
|
22437
|
-
const [coords, setCoords] = a$
|
|
22513
|
+
const [open, setOpen] = a$n.useState(false);
|
|
22514
|
+
const buttonRef = a$n.useRef(null);
|
|
22515
|
+
const [coords, setCoords] = a$n.useState({ top: 0, left: 0 });
|
|
22438
22516
|
const toggleMenu = (e) => {
|
|
22439
22517
|
e.stopPropagation();
|
|
22440
22518
|
if (buttonRef.current) {
|
|
@@ -22447,7 +22525,7 @@ const RowOptions = ({ row, selectionMenuItems }) => {
|
|
|
22447
22525
|
setOpen((p) => !p);
|
|
22448
22526
|
};
|
|
22449
22527
|
// Close menu when clicking outside
|
|
22450
|
-
a$
|
|
22528
|
+
a$n.useEffect(() => {
|
|
22451
22529
|
if (!open)
|
|
22452
22530
|
return;
|
|
22453
22531
|
const handleClick = (e) => {
|
|
@@ -22457,16 +22535,16 @@ const RowOptions = ({ row, selectionMenuItems }) => {
|
|
|
22457
22535
|
document.addEventListener("click", handleClick);
|
|
22458
22536
|
return () => document.removeEventListener("click", handleClick);
|
|
22459
22537
|
}, [open]);
|
|
22460
|
-
return (a$
|
|
22461
|
-
a$
|
|
22462
|
-
a$
|
|
22538
|
+
return (a$n.createElement(a$n.Fragment, null,
|
|
22539
|
+
a$n.createElement(KebabAlign, null,
|
|
22540
|
+
a$n.createElement(IconButton, { ariaLabel: "Options", iconName: "kebab-menu", variant: "tertiary", onClick: (e) => toggleMenu(e), ref: buttonRef })),
|
|
22463
22541
|
open &&
|
|
22464
|
-
ReactDOM.createPortal(a$
|
|
22542
|
+
ReactDOM.createPortal(a$n.createElement(FilterMenu, { style: {
|
|
22465
22543
|
top: coords.top,
|
|
22466
22544
|
left: coords.left,
|
|
22467
22545
|
position: "absolute",
|
|
22468
22546
|
} }, selectionMenuItems?.map((item) => {
|
|
22469
|
-
return ((!item.conditional || item.conditional()) && (a$
|
|
22547
|
+
return ((!item.conditional || item.conditional()) && (a$n.createElement(MenuItem, { key: item.label, onClick: () => {
|
|
22470
22548
|
item.onClick(row);
|
|
22471
22549
|
setOpen(false);
|
|
22472
22550
|
} }, item.label)));
|
|
@@ -22474,12 +22552,12 @@ const RowOptions = ({ row, selectionMenuItems }) => {
|
|
|
22474
22552
|
};
|
|
22475
22553
|
|
|
22476
22554
|
const EmptyTableState = ({ id, className, header, subHeader, showClearFilterButton, colSpan, size = "large", onClearFilters, }) => {
|
|
22477
|
-
return (a$
|
|
22478
|
-
a$
|
|
22479
|
-
a$
|
|
22480
|
-
a$
|
|
22481
|
-
a$
|
|
22482
|
-
a$
|
|
22555
|
+
return (a$n.createElement("tr", null,
|
|
22556
|
+
a$n.createElement(EmptyTableCell, { colSpan: colSpan },
|
|
22557
|
+
a$n.createElement(EmptyTableSection, { "$size": size, id: id, className: className },
|
|
22558
|
+
a$n.createElement(EmptyTableHeader, null, header),
|
|
22559
|
+
a$n.createElement(EmptyTableSubHeader, null, subHeader),
|
|
22560
|
+
a$n.createElement(ClearFilterButtonRow, null, showClearFilterButton && (a$n.createElement(StellaButton, { label: "Clear Filters", onClick: () => onClearFilters?.(), variant: "secondary" })))))));
|
|
22483
22561
|
};
|
|
22484
22562
|
|
|
22485
22563
|
function Table({ columns, data, isLoading, serverSide = false, onPageChange, onSortChange, onFilterChange, onRowSelect, onRowClick, rowStatuses, showSelection = false, showRowOptions = false, showPagination = true, variant, paginationDetails = {
|
|
@@ -22487,20 +22565,20 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22487
22565
|
rowsPerPage: 10,
|
|
22488
22566
|
totalRows: data.length,
|
|
22489
22567
|
}, selectionMenuItems, dataAuto, dataTestId, id, className, htmlProps, resetTrigger, emptyTableState, defaultFilters, staticFilters, }) {
|
|
22490
|
-
const [rowSelection, setRowSelection] = a$
|
|
22491
|
-
const [selectedRows] = a$
|
|
22492
|
-
const [pageIndex, setPageIndex] = a$
|
|
22493
|
-
const [pagination, setPagination] = a$
|
|
22568
|
+
const [rowSelection, setRowSelection] = a$n.useState({});
|
|
22569
|
+
const [selectedRows] = a$n.useState({});
|
|
22570
|
+
const [pageIndex, setPageIndex] = a$n.useState(paginationDetails?.startingPage);
|
|
22571
|
+
const [pagination, setPagination] = a$n.useState({
|
|
22494
22572
|
pageIndex: paginationDetails?.startingPage - 1,
|
|
22495
22573
|
pageSize: paginationDetails?.rowsPerPage || 10,
|
|
22496
22574
|
});
|
|
22497
|
-
const [localData, setLocalData] = a$
|
|
22498
|
-
const [localColumns, setLocalColumns] = a$
|
|
22499
|
-
const [totalData, setTotalData] = a$
|
|
22500
|
-
const [sorting, setSorting] = a$
|
|
22501
|
-
const [filters, setFilters] = a$
|
|
22502
|
-
const [rowState, setRowState] = a$
|
|
22503
|
-
const [columnFilters, setColumnFilters] = a$
|
|
22575
|
+
const [localData, setLocalData] = a$n.useState(data);
|
|
22576
|
+
const [localColumns, setLocalColumns] = a$n.useState(columns);
|
|
22577
|
+
const [totalData, setTotalData] = a$n.useState(paginationDetails?.totalRows);
|
|
22578
|
+
const [sorting, setSorting] = a$n.useState([]);
|
|
22579
|
+
const [filters, setFilters] = a$n.useState({});
|
|
22580
|
+
const [rowState, setRowState] = a$n.useState({});
|
|
22581
|
+
const [columnFilters, setColumnFilters] = a$n.useState(() => {
|
|
22504
22582
|
const base = defaultFilters ?? [];
|
|
22505
22583
|
if (!staticFilters?.length)
|
|
22506
22584
|
return base;
|
|
@@ -22520,18 +22598,18 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22520
22598
|
});
|
|
22521
22599
|
return merged;
|
|
22522
22600
|
});
|
|
22523
|
-
const [columnPinning, setColumnPinning] = a$
|
|
22524
|
-
const scrollRef = a$
|
|
22525
|
-
const [scrollState, setScrollState] = a$
|
|
22601
|
+
const [columnPinning, setColumnPinning] = a$n.useState({ left: ["select"], right: ["options"] });
|
|
22602
|
+
const scrollRef = a$n.useRef(null);
|
|
22603
|
+
const [scrollState, setScrollState] = a$n.useState({
|
|
22526
22604
|
atLeft: true,
|
|
22527
22605
|
atRight: false,
|
|
22528
22606
|
});
|
|
22529
|
-
const [rowStatusesState, setRowStatusesState] = a$
|
|
22530
|
-
const [filterMenuOpen, setFilterMenuOpen] = a$
|
|
22531
|
-
a$
|
|
22607
|
+
const [rowStatusesState, setRowStatusesState] = a$n.useState(rowStatuses || {});
|
|
22608
|
+
const [filterMenuOpen, setFilterMenuOpen] = a$n.useState({});
|
|
22609
|
+
a$n.useEffect(() => {
|
|
22532
22610
|
setRowStatusesState(rowStatuses || {});
|
|
22533
22611
|
}, [rowStatuses]);
|
|
22534
|
-
a$
|
|
22612
|
+
a$n.useEffect(() => {
|
|
22535
22613
|
setTotalData(paginationDetails?.totalRows);
|
|
22536
22614
|
setPagination({
|
|
22537
22615
|
pageIndex: paginationDetails?.startingPage - 1,
|
|
@@ -22542,7 +22620,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22542
22620
|
if (paginationDetails && paginationDetails.startingPage !== pageIndex)
|
|
22543
22621
|
setPageIndex(paginationDetails?.startingPage);
|
|
22544
22622
|
}, [paginationDetails, data, columns]);
|
|
22545
|
-
a$
|
|
22623
|
+
a$n.useLayoutEffect(() => {
|
|
22546
22624
|
const el = scrollRef.current;
|
|
22547
22625
|
if (!el)
|
|
22548
22626
|
return;
|
|
@@ -22586,7 +22664,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22586
22664
|
[rowId]: { ...prev[rowId], [field]: value },
|
|
22587
22665
|
}));
|
|
22588
22666
|
};
|
|
22589
|
-
const enhancedColumns = a$
|
|
22667
|
+
const enhancedColumns = a$n.useMemo(() => {
|
|
22590
22668
|
const cols = [];
|
|
22591
22669
|
if (showSelection) {
|
|
22592
22670
|
cols.push({
|
|
@@ -22594,9 +22672,9 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22594
22672
|
header: () => {
|
|
22595
22673
|
const isIndeterminate = table.getIsSomePageRowsSelected() &&
|
|
22596
22674
|
!table.getIsAllPageRowsSelected();
|
|
22597
|
-
return (a$
|
|
22675
|
+
return (a$n.createElement(IndeterminateCheckbox, { isIndeterminate: isIndeterminate, isChecked: table.getIsAllPageRowsSelected(), onChange: table.getToggleAllPageRowsSelectedHandler() }));
|
|
22598
22676
|
},
|
|
22599
|
-
cell: ({ row }) => (a$
|
|
22677
|
+
cell: ({ row }) => (a$n.createElement(Checkbox, { checked: row.getIsSelected(), onChange: row.getToggleSelectedHandler() })),
|
|
22600
22678
|
size: 20,
|
|
22601
22679
|
});
|
|
22602
22680
|
}
|
|
@@ -22606,7 +22684,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22606
22684
|
id: "options",
|
|
22607
22685
|
header: "",
|
|
22608
22686
|
cell: ({ row }) => {
|
|
22609
|
-
return (a$
|
|
22687
|
+
return (a$n.createElement(RowOptions, { row: row, selectionMenuItems: selectionMenuItems }));
|
|
22610
22688
|
},
|
|
22611
22689
|
size: 30,
|
|
22612
22690
|
});
|
|
@@ -22692,7 +22770,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22692
22770
|
},
|
|
22693
22771
|
},
|
|
22694
22772
|
});
|
|
22695
|
-
a$
|
|
22773
|
+
a$n.useEffect(() => {
|
|
22696
22774
|
if (onRowSelect) {
|
|
22697
22775
|
const selectedData = table
|
|
22698
22776
|
.getSelectedRowModel()
|
|
@@ -22700,8 +22778,8 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22700
22778
|
onRowSelect?.(selectedData);
|
|
22701
22779
|
}
|
|
22702
22780
|
}, [rowSelection]);
|
|
22703
|
-
const isMounted = a$
|
|
22704
|
-
a$
|
|
22781
|
+
const isMounted = a$n.useRef(false);
|
|
22782
|
+
a$n.useEffect(() => {
|
|
22705
22783
|
if (!isMounted.current) {
|
|
22706
22784
|
isMounted.current = true;
|
|
22707
22785
|
return;
|
|
@@ -22719,9 +22797,9 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22719
22797
|
});
|
|
22720
22798
|
table.toggleAllRowsSelected(false);
|
|
22721
22799
|
};
|
|
22722
|
-
return (a$
|
|
22723
|
-
a$
|
|
22724
|
-
a$
|
|
22800
|
+
return (a$n.createElement(TableWrapper, { className: className, id: id, "data-testid": dataTestId, "data-auto": dataAuto },
|
|
22801
|
+
a$n.createElement(TableWrapperScroll, { "$stopScroll": Object.values(filterMenuOpen).some((value) => value), ref: scrollRef }, isLoading ? (a$n.createElement("div", null,
|
|
22802
|
+
a$n.createElement("div", { style: {
|
|
22725
22803
|
width: "100%",
|
|
22726
22804
|
maxWidth: "100%",
|
|
22727
22805
|
height: "100%",
|
|
@@ -22733,7 +22811,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22733
22811
|
boxSizing: "border-box",
|
|
22734
22812
|
} }, Array.from({
|
|
22735
22813
|
length: pagination?.pageSize,
|
|
22736
|
-
}).map((_, index) => (a$
|
|
22814
|
+
}).map((_, index) => (a$n.createElement("div", { style: {
|
|
22737
22815
|
position: "relative",
|
|
22738
22816
|
display: "flex",
|
|
22739
22817
|
flexDirection: "row",
|
|
@@ -22746,9 +22824,9 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22746
22824
|
minHeight: "50px",
|
|
22747
22825
|
}, key: index + "loading-row" }, Array.from({
|
|
22748
22826
|
length: 10,
|
|
22749
|
-
}).map((_, i) => (a$
|
|
22750
|
-
a$
|
|
22751
|
-
return (a$
|
|
22827
|
+
}).map((_, i) => (a$n.createElement(LoadingShimmer, { key: `${i}-loading`, "$width": "110px", "$height": "25px" }))))))))) : (a$n.createElement(StyledTable, { id: `${id}-table`, ...htmlProps },
|
|
22828
|
+
a$n.createElement("thead", null, table.getHeaderGroups().map((headerGroup) => (a$n.createElement(HeaderRow, { key: headerGroup.id }, headerGroup.headers.map((header, i) => {
|
|
22829
|
+
return (a$n.createElement(TableHeaderCell, { key: header.id, serverSide: serverSide, header: header, filters: filters, sorting: sorting, scrollPosition: scrollState, onFilterMenuInteraction: (id, active) => {
|
|
22752
22830
|
setFilterMenuOpen((prev) => ({
|
|
22753
22831
|
...prev,
|
|
22754
22832
|
[id]: active,
|
|
@@ -22761,16 +22839,16 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22761
22839
|
}));
|
|
22762
22840
|
} }));
|
|
22763
22841
|
}))))),
|
|
22764
|
-
a$
|
|
22765
|
-
table.getRowModel().rows.length === 0 && (a$
|
|
22766
|
-
table.getRowModel().rows.map((row) => (a$
|
|
22842
|
+
a$n.createElement("tbody", null,
|
|
22843
|
+
table.getRowModel().rows.length === 0 && (a$n.createElement(EmptyTableState, { header: emptyTableState?.header || "No data available.", subHeader: emptyTableState?.subHeader, showClearFilterButton: emptyTableState?.showClearFilterButton, onClearFilters: resetTable, colSpan: table.getVisibleLeafColumns().length, size: "large" })),
|
|
22844
|
+
table.getRowModel().rows.map((row) => (a$n.createElement(CellRow, { key: row.id, onClick: () => onRowClick?.(row.original), "$isClickable": !!onRowClick }, row.getVisibleCells().map((cell) => {
|
|
22767
22845
|
const value = flexRender(cell.column.columnDef.cell, {
|
|
22768
22846
|
...cell.getContext(),
|
|
22769
22847
|
localValue: rowState[row.id]?.[cell.column.id],
|
|
22770
22848
|
onLocalChange: (val) => handleInputChange(row.id, cell.column.id, val),
|
|
22771
22849
|
});
|
|
22772
22850
|
const meta = cell.column.columnDef.meta;
|
|
22773
|
-
return (a$
|
|
22851
|
+
return (a$n.createElement(BodyCell, { key: cell.id, style: {
|
|
22774
22852
|
width: cell.column.getSize(),
|
|
22775
22853
|
textAlign: meta?.cellAlign ||
|
|
22776
22854
|
(typeof cell.getValue() === "number" ||
|
|
@@ -22799,7 +22877,7 @@ function Table({ columns, data, isLoading, serverSide = false, onPageChange, onS
|
|
|
22799
22877
|
pagination.pageSize * pagination.pageIndex ===
|
|
22800
22878
|
table.getRowModel().rows.length - 1 }, value));
|
|
22801
22879
|
})))))))),
|
|
22802
|
-
showPagination && paginationDetails?.totalRows > 0 && (a$
|
|
22880
|
+
showPagination && paginationDetails?.totalRows > 0 && (a$n.createElement(CustomPagination, { "$hasData": table.getRowModel().rows.length > 0, totalRows: serverSide ? totalData : table.getFilteredRowModel().rows.length, isLoading: isLoading, rowsPerPage: paginationDetails?.rowsPerPage, startingPage: pageIndex, onPageChange: (page, pageSize) => {
|
|
22803
22881
|
table.toggleAllRowsSelected(false);
|
|
22804
22882
|
setPageIndex(page);
|
|
22805
22883
|
setPagination((prev) => ({
|
|
@@ -22853,7 +22931,7 @@ function convertUTCDateForClient(providedDate) {
|
|
|
22853
22931
|
}
|
|
22854
22932
|
|
|
22855
22933
|
const Sync = ({ dataTestId, onClick, className, id, showTime = false, labelPosition = "left", }) => {
|
|
22856
|
-
const [time, setTime] = a$
|
|
22934
|
+
const [time, setTime] = a$n.useState(formatDateToTime(new Date()));
|
|
22857
22935
|
const handleClick = (e) => {
|
|
22858
22936
|
const svg = e?.currentTarget?.children?.[0];
|
|
22859
22937
|
const button = e?.currentTarget;
|
|
@@ -22866,9 +22944,9 @@ const Sync = ({ dataTestId, onClick, className, id, showTime = false, labelPosit
|
|
|
22866
22944
|
setTime(formatDateToTime(new Date()));
|
|
22867
22945
|
onClick?.(e, time);
|
|
22868
22946
|
};
|
|
22869
|
-
return (a$
|
|
22870
|
-
a$
|
|
22871
|
-
a$
|
|
22947
|
+
return (a$n.createElement(SyncContainer, { "$labelPosition": labelPosition },
|
|
22948
|
+
a$n.createElement(CustomIconButton, { variant: "tertiary", iconName: "sync", size: 16, id: id, className: className, dataTestId: dataTestId, ariaLabel: "Sync Button", onClick: (e) => handleClick(e) }),
|
|
22949
|
+
a$n.createElement(CustomLabel, { htmlFor: id, id: `${id}-label`, labelValue: showTime ? `Last Updated at ${time}` : "" })));
|
|
22872
22950
|
};
|
|
22873
22951
|
|
|
22874
22952
|
const Container = styled.div `
|
|
@@ -22910,10 +22988,10 @@ const TableUnitsAndTotals = ({ id, className, value, subValue, valueRightCategor
|
|
|
22910
22988
|
let subHeader = subValueLeftCategory ?? "";
|
|
22911
22989
|
subHeader += subValue;
|
|
22912
22990
|
subHeader += subValueRightCategory ? ` ${subValueRightCategory}` : "";
|
|
22913
|
-
return (a$
|
|
22914
|
-
a$
|
|
22915
|
-
a$
|
|
22916
|
-
subValue && a$
|
|
22991
|
+
return (a$n.createElement(Container, { id: id, className: className },
|
|
22992
|
+
a$n.createElement(Column, { "$align": "right" },
|
|
22993
|
+
a$n.createElement(HeaderText, null, header),
|
|
22994
|
+
subValue && a$n.createElement(SubHeaderText, null, subHeader))));
|
|
22917
22995
|
};
|
|
22918
22996
|
|
|
22919
22997
|
const PaymentStatusComponent = styled.div `
|
|
@@ -22967,9 +23045,9 @@ const PaymentStatus = ({ variant, id, className }) => {
|
|
|
22967
23045
|
label = "Paid";
|
|
22968
23046
|
if (variant === PaymentStatusVariant.PAYMENT_CANCELED)
|
|
22969
23047
|
label = "Canceled";
|
|
22970
|
-
return (a$
|
|
22971
|
-
iconName ? a$
|
|
22972
|
-
a$
|
|
23048
|
+
return (a$n.createElement(PaymentStatusComponent, { id: id, className: className },
|
|
23049
|
+
iconName ? a$n.createElement(PaymentStatusIcon, { iconName: iconName, size: 16 }) : "",
|
|
23050
|
+
a$n.createElement(PaymentStatusLabel, null, label)));
|
|
22973
23051
|
};
|
|
22974
23052
|
|
|
22975
23053
|
const tabButtonVariantSelector = (variant) => {
|
|
@@ -23070,18 +23148,18 @@ const Tab = ({ id, className, onClick, htmlProps, label, variant = "light", acti
|
|
|
23070
23148
|
const notificationText = typeof notifications === "number" && notifications <= 0
|
|
23071
23149
|
? undefined
|
|
23072
23150
|
: notifications;
|
|
23073
|
-
return (a$
|
|
23151
|
+
return (a$n.createElement(TabButton, { id: id, "$variant": variant, className: `${className} ${active && "active"}`, onClick: () => onClick?.(label), ...htmlProps },
|
|
23074
23152
|
label,
|
|
23075
|
-
!!notificationText && (a$
|
|
23153
|
+
!!notificationText && (a$n.createElement(NotificationBubble, { "$isActive": active }, notificationText))));
|
|
23076
23154
|
};
|
|
23077
23155
|
|
|
23078
23156
|
const Tabs = ({ id, className, tabs, htmlProps, onTabClick, defaultActiveTab, variant = "light", isPill, }) => {
|
|
23079
|
-
const [activeTab, setActiveTab] = a$
|
|
23157
|
+
const [activeTab, setActiveTab] = a$n.useState(defaultActiveTab ?? tabs[0]);
|
|
23080
23158
|
const handleClick = (label) => {
|
|
23081
23159
|
setActiveTab(label);
|
|
23082
23160
|
onTabClick(label);
|
|
23083
23161
|
};
|
|
23084
|
-
return (a$
|
|
23162
|
+
return (a$n.createElement(TabsBar, { "$variant": variant, "$isPill": isPill, id: id, className: className, ...htmlProps }, tabs.map((tab) => (a$n.createElement(Tab, { key: `${id}-${tab.label}`, id: `${id}-${tab.label}`, label: tab.label, active: tab.label === activeTab, variant: variant, onClick: () => handleClick(tab.label), notifications: tab.notifications })))));
|
|
23085
23163
|
};
|
|
23086
23164
|
|
|
23087
23165
|
const SelectorChipWrapper = styled.div `
|
|
@@ -23143,13 +23221,13 @@ const SelectorChipClose = styled.button `
|
|
|
23143
23221
|
`;
|
|
23144
23222
|
|
|
23145
23223
|
const SelectorChip = ({ id, className, label, selected = false, disabled = false, onClick, onClose, }) => {
|
|
23146
|
-
return (a$
|
|
23147
|
-
a$
|
|
23148
|
-
a$
|
|
23149
|
-
selected && (a$
|
|
23224
|
+
return (a$n.createElement(SelectorChipWrapper, { className: className, "$selected": selected, "$disabled": disabled, onClick: onClick, id: id },
|
|
23225
|
+
a$n.createElement(SelectorChipComponent, { "$selected": selected, id: id, type: "button" },
|
|
23226
|
+
a$n.createElement(SelectorChipLabel, { "$selected": selected }, label)),
|
|
23227
|
+
selected && (a$n.createElement(SelectorChipClose, { type: "button", "aria-label": "Remove chip", disabled: disabled, onClick: (e) => {
|
|
23150
23228
|
onClose?.();
|
|
23151
23229
|
} },
|
|
23152
|
-
a$
|
|
23230
|
+
a$n.createElement(e, { size: 16 })))));
|
|
23153
23231
|
};
|
|
23154
23232
|
|
|
23155
23233
|
const OrderStatusComponent = styled.div `
|
|
@@ -23226,12 +23304,196 @@ const OrderStatus = ({ variant = "", id, className, isPurchaser, }) => {
|
|
|
23226
23304
|
};
|
|
23227
23305
|
const iconName = variant ? STATUS_ICON_MAP[variant] : null;
|
|
23228
23306
|
const label = getOrderStatusLabel(variant, isPurchaser);
|
|
23229
|
-
return (a$
|
|
23230
|
-
iconName && a$
|
|
23231
|
-
!iconName && label !== "--" && (a$
|
|
23232
|
-
a$
|
|
23307
|
+
return (a$n.createElement(OrderStatusComponent, { id: id, className: className },
|
|
23308
|
+
iconName && a$n.createElement(OrderStatusIcon, { iconName: iconName, size: 16 }),
|
|
23309
|
+
!iconName && label !== "--" && (a$n.createElement(OrderStatusIcon, { iconName: "warning", size: 16 })),
|
|
23310
|
+
a$n.createElement(OrderStatusLabel, null, label)));
|
|
23311
|
+
};
|
|
23312
|
+
|
|
23313
|
+
const GroupWrapper = styled.fieldset `
|
|
23314
|
+
display: inline-flex;
|
|
23315
|
+
flex-direction: column;
|
|
23316
|
+
border: none;
|
|
23317
|
+
padding: 0;
|
|
23318
|
+
margin: 0;
|
|
23319
|
+
`;
|
|
23320
|
+
const HeadingRow = styled.div `
|
|
23321
|
+
display: flex;
|
|
23322
|
+
align-items: center;
|
|
23323
|
+
margin-bottom: 10px;
|
|
23324
|
+
gap: 10px;
|
|
23325
|
+
|
|
23326
|
+
& > label {
|
|
23327
|
+
margin-bottom: 0;
|
|
23328
|
+
margin-top: 0;
|
|
23329
|
+
font-weight: 600;
|
|
23330
|
+
}
|
|
23331
|
+
`;
|
|
23332
|
+
const Legend = styled.legend `
|
|
23333
|
+
position: absolute;
|
|
23334
|
+
width: 1px;
|
|
23335
|
+
height: 1px;
|
|
23336
|
+
padding: 0;
|
|
23337
|
+
margin: -1px;
|
|
23338
|
+
overflow: hidden;
|
|
23339
|
+
clip: rect(0, 0, 0, 0);
|
|
23340
|
+
white-space: nowrap;
|
|
23341
|
+
border: 0;
|
|
23342
|
+
`;
|
|
23343
|
+
|
|
23344
|
+
var CheckBoxFontSizeVariant;
|
|
23345
|
+
(function (CheckBoxFontSizeVariant) {
|
|
23346
|
+
CheckBoxFontSizeVariant["SIZE_12"] = "12px";
|
|
23347
|
+
CheckBoxFontSizeVariant["SIZE_14"] = "14px";
|
|
23348
|
+
CheckBoxFontSizeVariant["SIZE_16"] = "16px";
|
|
23349
|
+
})(CheckBoxFontSizeVariant || (CheckBoxFontSizeVariant = {}));
|
|
23350
|
+
|
|
23351
|
+
const IconWrapper = styled.span `
|
|
23352
|
+
display: flex;
|
|
23353
|
+
align-items: center;
|
|
23354
|
+
flex-shrink: 0;
|
|
23355
|
+
padding-right: ${({ $hasLabel }) => ($hasLabel ? "9px" : "0px")};
|
|
23356
|
+
padding-top: 1px;
|
|
23357
|
+
position: relative;
|
|
23358
|
+
|
|
23359
|
+
& > svg {
|
|
23360
|
+
display: block;
|
|
23361
|
+
position: relative;
|
|
23362
|
+
z-index: 1;
|
|
23363
|
+
}
|
|
23364
|
+
|
|
23365
|
+
&::before {
|
|
23366
|
+
content: "";
|
|
23367
|
+
position: absolute;
|
|
23368
|
+
top: 3px;
|
|
23369
|
+
left: 2px;
|
|
23370
|
+
width: 14px;
|
|
23371
|
+
height: 14px;
|
|
23372
|
+
background-color: transparent;
|
|
23373
|
+
border-radius: 2px;
|
|
23374
|
+
z-index: 0;
|
|
23375
|
+
transition: background-color 0.15s ease;
|
|
23376
|
+
}
|
|
23377
|
+
`;
|
|
23378
|
+
const CheckBoxWrapper = styled.label `
|
|
23379
|
+
display: inline-flex;
|
|
23380
|
+
width: fit-content;
|
|
23381
|
+
font-weight: 500;
|
|
23382
|
+
font-size: ${({ $fontSize }) => $fontSize};
|
|
23383
|
+
align-items: ${({ $align }) => $align === "center" ? "center" : "flex-start"};
|
|
23384
|
+
cursor: ${({ $disabled }) => ($disabled ? "not-allowed" : "pointer")};
|
|
23385
|
+
color: ${({ $disabled }) => $disabled ? Styles.color.grey.smoke : Styles.color.grey.charcoal};
|
|
23386
|
+
user-select: none;
|
|
23387
|
+
margin-bottom: 10px;
|
|
23388
|
+
margin-top: 0px;
|
|
23389
|
+
${({ $disabled }) => !$disabled &&
|
|
23390
|
+
styled.css `
|
|
23391
|
+
&:hover ${IconWrapper}::before {
|
|
23392
|
+
background-color: ${Styles.color.blue.light};
|
|
23393
|
+
}
|
|
23394
|
+
`}
|
|
23395
|
+
`;
|
|
23396
|
+
const HiddenInput = styled.input.attrs({ type: "checkbox" }) `
|
|
23397
|
+
position: absolute;
|
|
23398
|
+
opacity: 0;
|
|
23399
|
+
width: 0;
|
|
23400
|
+
height: 0;
|
|
23401
|
+
`;
|
|
23402
|
+
const LabelGroup = styled.div `
|
|
23403
|
+
display: flex;
|
|
23404
|
+
flex-direction: column;
|
|
23405
|
+
`;
|
|
23406
|
+
const MainLabel = styled.span `
|
|
23407
|
+
font-family: ${Styles.font.fontFamily.primary};
|
|
23408
|
+
line-height: 1.4;
|
|
23409
|
+
margin-bottom: 0px;
|
|
23410
|
+
`;
|
|
23411
|
+
|
|
23412
|
+
const CheckBox = ({ id, className, label, checked, indeterminate = false, disabled = false, defaultChecked = false, align = "top", fontSize = CheckBoxFontSizeVariant.SIZE_14, onChange, htmlProps, }) => {
|
|
23413
|
+
const [internalChecked, setInternalChecked] = a$n.useState(defaultChecked);
|
|
23414
|
+
const isChecked = checked ?? internalChecked;
|
|
23415
|
+
const [isIndeterminate, setIsIndeterminate] = a$n.useState(indeterminate);
|
|
23416
|
+
const [prevIndeterminate, setPrevIndeterminate] = a$n.useState(indeterminate);
|
|
23417
|
+
const inputRef = a$n.useRef(null);
|
|
23418
|
+
if (prevIndeterminate !== indeterminate) {
|
|
23419
|
+
setPrevIndeterminate(indeterminate);
|
|
23420
|
+
setIsIndeterminate(indeterminate);
|
|
23421
|
+
}
|
|
23422
|
+
a$n.useEffect(() => {
|
|
23423
|
+
if (inputRef.current) {
|
|
23424
|
+
inputRef.current.indeterminate = isIndeterminate;
|
|
23425
|
+
}
|
|
23426
|
+
}, [isIndeterminate]);
|
|
23427
|
+
const handleChange = (e) => {
|
|
23428
|
+
setIsIndeterminate(false);
|
|
23429
|
+
if (!checked)
|
|
23430
|
+
setInternalChecked(e.target.checked);
|
|
23431
|
+
onChange?.(id, e.target.checked);
|
|
23432
|
+
};
|
|
23433
|
+
const getIcon = () => {
|
|
23434
|
+
const color = disabled
|
|
23435
|
+
? Styles.color.grey.medium
|
|
23436
|
+
: Styles.color.core.primary;
|
|
23437
|
+
if (isIndeterminate)
|
|
23438
|
+
return (a$n.createElement(o$8, { "data-testid": "indeterminate-icon", className: "checkbox-icon", size: 18, weight: "fill", color: color }));
|
|
23439
|
+
if (isChecked)
|
|
23440
|
+
return (a$n.createElement(o$i, { "data-testid": "check-icon", className: "checkbox-icon", size: 18, weight: "fill", color: color }));
|
|
23441
|
+
return (a$n.createElement(o$2, { "data-testid": "square-icon", className: "checkbox-icon", size: 18, weight: "regular", color: color }));
|
|
23442
|
+
};
|
|
23443
|
+
return (a$n.createElement(CheckBoxWrapper, { id: `${id}-label`, className: className, "$disabled": disabled, "$align": align, "$fontSize": fontSize },
|
|
23444
|
+
a$n.createElement(HiddenInput, { id: id, ref: inputRef, checked: isChecked, disabled: disabled, onChange: handleChange, ...htmlProps }),
|
|
23445
|
+
a$n.createElement(IconWrapper, { "$disabled": disabled, "$hasLabel": !!label }, getIcon()),
|
|
23446
|
+
label && (a$n.createElement(LabelGroup, null,
|
|
23447
|
+
a$n.createElement(MainLabel, null, label)))));
|
|
23448
|
+
};
|
|
23449
|
+
|
|
23450
|
+
const CheckBoxGroup = ({ defaultOptions, onChange, heading, required, tooltipText, disabled, isSelectAllEnabled, fontSize, className, }) => {
|
|
23451
|
+
const [options, setOptions] = a$n.useState(defaultOptions);
|
|
23452
|
+
const selectableOptions = options.filter((o) => !o.disabled);
|
|
23453
|
+
const allSelected = selectableOptions.length > 0 && selectableOptions.every((o) => o.checked);
|
|
23454
|
+
const someSelected = selectableOptions.some((o) => o.checked);
|
|
23455
|
+
const mergeOptions = (prev, updated) => prev.map((o) => {
|
|
23456
|
+
const u = updated.find((x) => x.id === o.id);
|
|
23457
|
+
return u ? { ...o, checked: u.isChecked } : o;
|
|
23458
|
+
});
|
|
23459
|
+
const buildPayload = (updatedOptions) => {
|
|
23460
|
+
const optionsPayload = options.map((o) => {
|
|
23461
|
+
const updated = updatedOptions.find((u) => u.id === o.id);
|
|
23462
|
+
return (updated ?? {
|
|
23463
|
+
id: o.id,
|
|
23464
|
+
isChecked: !!o.checked,
|
|
23465
|
+
isSelectAllClicked: false,
|
|
23466
|
+
});
|
|
23467
|
+
});
|
|
23468
|
+
setOptions((prev) => mergeOptions(prev, optionsPayload));
|
|
23469
|
+
return { options: optionsPayload };
|
|
23470
|
+
};
|
|
23471
|
+
const handleSelectAll = (id, checked) => {
|
|
23472
|
+
const updatedOptions = selectableOptions.map((o) => ({
|
|
23473
|
+
id: o.id,
|
|
23474
|
+
isChecked: checked,
|
|
23475
|
+
isSelectAllClicked: true,
|
|
23476
|
+
}));
|
|
23477
|
+
onChange(buildPayload(updatedOptions));
|
|
23478
|
+
};
|
|
23479
|
+
return (a$n.createElement(GroupWrapper, { className: className },
|
|
23480
|
+
heading && a$n.createElement(Legend, null, heading),
|
|
23481
|
+
heading && (a$n.createElement(HeadingRow, null,
|
|
23482
|
+
isSelectAllEnabled && (a$n.createElement(CheckBox, { id: "select-all", checked: allSelected, indeterminate: someSelected && !allSelected, disabled: disabled, fontSize: fontSize, onChange: handleSelectAll })),
|
|
23483
|
+
a$n.createElement(Label, { id: "checkbox-group-label", labelValue: heading, required: required, tooltipText: tooltipText, htmlFor: isSelectAllEnabled ? "select-all" : "", isPointerOnHover: true }))),
|
|
23484
|
+
options.map((option) => (a$n.createElement(CheckBox, { key: option.id, id: option.id, label: option.label, checked: option.checked, disabled: disabled || option.disabled, indeterminate: option.indeterminate, fontSize: fontSize, onChange: (clickedId, checked) => {
|
|
23485
|
+
onChange(buildPayload([
|
|
23486
|
+
{
|
|
23487
|
+
id: clickedId,
|
|
23488
|
+
isChecked: checked,
|
|
23489
|
+
isSelectAllClicked: false,
|
|
23490
|
+
},
|
|
23491
|
+
]));
|
|
23492
|
+
} })))));
|
|
23233
23493
|
};
|
|
23234
23494
|
|
|
23495
|
+
exports.CheckBox = CheckBox;
|
|
23496
|
+
exports.CheckBoxGroup = CheckBoxGroup;
|
|
23235
23497
|
exports.HelperText = HelperText;
|
|
23236
23498
|
exports.IconButton = IconButton;
|
|
23237
23499
|
exports.Label = Label;
|