@e1011/es-kit 1.1.58 → 1.1.62
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/hooks/esm/index.css +252 -236
- package/dist/hooks/esm/src/core/hooks/index.js +1 -1
- package/dist/hooks/esm/src/core/hooks/useToggle2.js +2 -0
- package/dist/hooks/esm/src/core/hooks/useToggle2.js.map +1 -0
- package/dist/hooks/index.css +252 -236
- package/dist/hooks/src/core/hooks/index.js +1 -1
- package/dist/hooks/src/core/hooks/useToggle2.js +2 -0
- package/dist/hooks/src/core/hooks/useToggle2.js.map +1 -0
- package/dist/lib/cjs/index.css +16 -0
- package/dist/lib/cjs/src/core/hooks/useToggle2.js +2 -0
- package/dist/lib/cjs/src/core/hooks/useToggle2.js.map +1 -0
- package/dist/lib/cjs/src/core/ui/components/atoms/button/Button.js +1 -1
- package/dist/lib/cjs/src/core/ui/components/atoms/button/Button.js.map +1 -1
- package/dist/lib/cjs/src/core/ui/components/atoms/button/button.module.scss.js +1 -1
- package/dist/lib/cjs/src/core/ui/components/field/Field.js +1 -1
- package/dist/lib/cjs/src/core/ui/components/field/Field.js.map +1 -1
- package/dist/lib/cjs/src/index.js +1 -1
- package/dist/lib/esm/index.css +16 -0
- package/dist/lib/esm/src/core/hooks/useToggle2.js +2 -0
- package/dist/lib/esm/src/core/hooks/useToggle2.js.map +1 -0
- package/dist/lib/esm/src/core/ui/components/atoms/button/Button.js +1 -1
- package/dist/lib/esm/src/core/ui/components/atoms/button/Button.js.map +1 -1
- package/dist/lib/esm/src/core/ui/components/atoms/button/button.module.scss.js +1 -1
- package/dist/lib/esm/src/core/ui/components/field/Field.js +1 -1
- package/dist/lib/esm/src/core/ui/components/field/Field.js.map +1 -1
- package/dist/lib/esm/src/index.js +1 -1
- package/dist/lib/tsconfig.tsbuildinfo +1 -1
- package/dist/types/src/core/hooks/index.d.ts +1 -0
- package/dist/types/src/core/hooks/index.d.ts.map +1 -1
- package/dist/types/src/core/hooks/useToggle2.d.ts +22 -0
- package/dist/types/src/core/hooks/useToggle2.d.ts.map +1 -0
- package/dist/types/src/core/ui/components/atoms/button/Button.d.ts.map +1 -1
- package/dist/types/src/core/ui/components/atoms/button/button.stories.d.ts.map +1 -1
- package/dist/types/src/core/ui/components/atoms/text/Typography.stories.d.ts.map +1 -1
- package/dist/ui/esm/index.css +16 -0
- package/dist/ui/esm/src/core/ui/components/atoms/button/Button.js +1 -1
- package/dist/ui/esm/src/core/ui/components/atoms/button/Button.js.map +1 -1
- package/dist/ui/esm/src/core/ui/components/atoms/button/button.module.scss.js +1 -1
- package/dist/ui/esm/src/core/ui/components/field/Field.js +1 -1
- package/dist/ui/esm/src/core/ui/components/field/Field.js.map +1 -1
- package/dist/ui/index.css +16 -0
- package/dist/ui/src/core/ui/components/atoms/button/Button.js +1 -1
- package/dist/ui/src/core/ui/components/atoms/button/Button.js.map +1 -1
- package/dist/ui/src/core/ui/components/atoms/button/button.module.scss.js +1 -1
- package/dist/ui/src/core/ui/components/field/Field.js +1 -1
- package/dist/ui/src/core/ui/components/field/Field.js.map +1 -1
- package/dist/utils/esm/index.css +252 -236
- package/dist/utils/index.css +252 -236
- package/package.json +1 -1
package/dist/hooks/index.css
CHANGED
|
@@ -1,42 +1,3 @@
|
|
|
1
|
-
.errorBoundary-module_errorBoundary__gk9ps {
|
|
2
|
-
background: #EFEFEF;
|
|
3
|
-
width: 100%;
|
|
4
|
-
height: 100%;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
.errorBoundary-module_StyledIcon__IYHiU {
|
|
8
|
-
margin-right: 10px;
|
|
9
|
-
}
|
|
10
|
-
.icon-module_icon-base-parent__nOMvW {
|
|
11
|
-
line-height: 1px !important;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.icon-module_icon-base__S0tHf {
|
|
15
|
-
min-width: var(--min-width);
|
|
16
|
-
min-height: var(--min-height);
|
|
17
|
-
width: var(--width) !important;
|
|
18
|
-
height: var(--height) !important;
|
|
19
|
-
line-height: 1px !important;
|
|
20
|
-
background-color: var(--icon-color);
|
|
21
|
-
color: var(--icon-content-color);
|
|
22
|
-
background-repeat: no-repeat;
|
|
23
|
-
mask-image: var(--icon-url);
|
|
24
|
-
-webkit-mask-image: var(--icon-url);
|
|
25
|
-
mask-repeat: no-repeat;
|
|
26
|
-
-webkit-mask-repeat: no-repeat;
|
|
27
|
-
mask-size: contain;
|
|
28
|
-
-webkit-mask-size: contain;
|
|
29
|
-
mask-position: center;
|
|
30
|
-
-webkit-mask-position: center;
|
|
31
|
-
display: inline-block;
|
|
32
|
-
will-change: transform;
|
|
33
|
-
transform: translate3d(0, 0, 0);
|
|
34
|
-
}
|
|
35
|
-
.icon-module_icon-base__S0tHf svg {
|
|
36
|
-
fill: var(--icon-content-color);
|
|
37
|
-
width: var(--height);
|
|
38
|
-
height: var(--width);
|
|
39
|
-
}
|
|
40
1
|
.CollapsibleContainer-module_collapsible-container__u0Jmm {
|
|
41
2
|
transform-origin: 0% 0%;
|
|
42
3
|
opacity: 0;
|
|
@@ -70,25 +31,6 @@
|
|
|
70
31
|
max-width: var(--prop-value);
|
|
71
32
|
opacity: 1;
|
|
72
33
|
}
|
|
73
|
-
.divider-module_divider-line__6CesR {
|
|
74
|
-
position: relative;
|
|
75
|
-
display: block;
|
|
76
|
-
transition: opacity, width, height 250ms ease-in-out;
|
|
77
|
-
background-color: var(--color);
|
|
78
|
-
opacity: var(--opacity);
|
|
79
|
-
}
|
|
80
|
-
.divider-module_divider-line__6CesR.divider-module_vertical__qSVWD {
|
|
81
|
-
height: var(--length);
|
|
82
|
-
left: var(--left);
|
|
83
|
-
width: var(--width);
|
|
84
|
-
margin: var(--margin);
|
|
85
|
-
}
|
|
86
|
-
.divider-module_divider-line__6CesR.divider-module_horizontal__Gz-Oj {
|
|
87
|
-
width: var(--length);
|
|
88
|
-
left: var(--left);
|
|
89
|
-
height: var(--height);
|
|
90
|
-
margin: var(--margin);
|
|
91
|
-
}
|
|
92
34
|
.field-module_field__UfKm3 {
|
|
93
35
|
opacity: 1;
|
|
94
36
|
pointer-events: auto;
|
|
@@ -163,6 +105,64 @@
|
|
|
163
105
|
.field-module_field__UfKm3 label {
|
|
164
106
|
text-align: left;
|
|
165
107
|
}
|
|
108
|
+
.errorBoundary-module_errorBoundary__gk9ps {
|
|
109
|
+
background: #EFEFEF;
|
|
110
|
+
width: 100%;
|
|
111
|
+
height: 100%;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.errorBoundary-module_StyledIcon__IYHiU {
|
|
115
|
+
margin-right: 10px;
|
|
116
|
+
}
|
|
117
|
+
.divider-module_divider-line__6CesR {
|
|
118
|
+
position: relative;
|
|
119
|
+
display: block;
|
|
120
|
+
transition: opacity, width, height 250ms ease-in-out;
|
|
121
|
+
background-color: var(--color);
|
|
122
|
+
opacity: var(--opacity);
|
|
123
|
+
}
|
|
124
|
+
.divider-module_divider-line__6CesR.divider-module_vertical__qSVWD {
|
|
125
|
+
height: var(--length);
|
|
126
|
+
left: var(--left);
|
|
127
|
+
width: var(--width);
|
|
128
|
+
margin: var(--margin);
|
|
129
|
+
}
|
|
130
|
+
.divider-module_divider-line__6CesR.divider-module_horizontal__Gz-Oj {
|
|
131
|
+
width: var(--length);
|
|
132
|
+
left: var(--left);
|
|
133
|
+
height: var(--height);
|
|
134
|
+
margin: var(--margin);
|
|
135
|
+
}
|
|
136
|
+
.icon-module_icon-base-parent__nOMvW {
|
|
137
|
+
line-height: 1px !important;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.icon-module_icon-base__S0tHf {
|
|
141
|
+
min-width: var(--min-width);
|
|
142
|
+
min-height: var(--min-height);
|
|
143
|
+
width: var(--width) !important;
|
|
144
|
+
height: var(--height) !important;
|
|
145
|
+
line-height: 1px !important;
|
|
146
|
+
background-color: var(--icon-color);
|
|
147
|
+
color: var(--icon-content-color);
|
|
148
|
+
background-repeat: no-repeat;
|
|
149
|
+
mask-image: var(--icon-url);
|
|
150
|
+
-webkit-mask-image: var(--icon-url);
|
|
151
|
+
mask-repeat: no-repeat;
|
|
152
|
+
-webkit-mask-repeat: no-repeat;
|
|
153
|
+
mask-size: contain;
|
|
154
|
+
-webkit-mask-size: contain;
|
|
155
|
+
mask-position: center;
|
|
156
|
+
-webkit-mask-position: center;
|
|
157
|
+
display: inline-block;
|
|
158
|
+
will-change: transform;
|
|
159
|
+
transform: translate3d(0, 0, 0);
|
|
160
|
+
}
|
|
161
|
+
.icon-module_icon-base__S0tHf svg {
|
|
162
|
+
fill: var(--icon-content-color);
|
|
163
|
+
width: var(--height);
|
|
164
|
+
height: var(--width);
|
|
165
|
+
}
|
|
166
166
|
.layoutBox-module_layout-box__ZIID8 {
|
|
167
167
|
display: flex;
|
|
168
168
|
position: relative;
|
|
@@ -230,77 +230,6 @@
|
|
|
230
230
|
stroke-dashoffset: -124;
|
|
231
231
|
}
|
|
232
232
|
}
|
|
233
|
-
.textAndContent-module_textAndContent__X5P1n {
|
|
234
|
-
align-items: baseline;
|
|
235
|
-
flex-shrink: 1;
|
|
236
|
-
gap: 8px;
|
|
237
|
-
}
|
|
238
|
-
:root {
|
|
239
|
-
--divider-line: #4a4b4b;
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
.typography-module_overflow-hidden__UmQ-v, .typography-module_text-truncate__8MgV9 {
|
|
243
|
-
overflow: hidden !important;
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
.typography-module_text-nowrap__dt3uu, .typography-module_text-truncate__8MgV9 {
|
|
247
|
-
white-space: nowrap !important;
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
.typography-module_text-ellipsis__iyHeZ, .typography-module_text-truncate__8MgV9 {
|
|
251
|
-
text-overflow: ellipsis !important;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
.typography-module_headline__b0XlP {
|
|
255
|
-
font-size: 28px;
|
|
256
|
-
line-height: 32px;
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
.typography-module_headlineSecondary__IDnhT {
|
|
260
|
-
font-size: 24px;
|
|
261
|
-
line-height: 28px;
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
.typography-module_headlineTertiary__mlG-v {
|
|
265
|
-
font-size: 18px;
|
|
266
|
-
line-height: 24x;
|
|
267
|
-
}
|
|
268
|
-
|
|
269
|
-
.typography-module_paragraph__tgBAx, .typography-module_paragraphBold__PmcZU, .typography-module_paragraphBoldSmall__qExmY, .typography-module_paragraphSmall__vTMiI {
|
|
270
|
-
font-size: 14px;
|
|
271
|
-
line-height: 18px;
|
|
272
|
-
font-weight: 300;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
.typography-module_paragraphSmall__vTMiI, .typography-module_paragraphBoldSmall__qExmY {
|
|
276
|
-
font-size: 12px;
|
|
277
|
-
}
|
|
278
|
-
|
|
279
|
-
.typography-module_paragraphBold__PmcZU, .typography-module_paragraphBoldSmall__qExmY {
|
|
280
|
-
font-weight: 600;
|
|
281
|
-
}
|
|
282
|
-
|
|
283
|
-
.typography-module_link__DWurf {
|
|
284
|
-
overflow: hidden !important;
|
|
285
|
-
white-space: nowrap !important;
|
|
286
|
-
text-overflow: ellipsis !important;
|
|
287
|
-
text-decoration: none;
|
|
288
|
-
color: #65C5F6;
|
|
289
|
-
display: inline;
|
|
290
|
-
gap: 4px;
|
|
291
|
-
flex-grow: 0;
|
|
292
|
-
max-width: 400px;
|
|
293
|
-
position: relative;
|
|
294
|
-
vertical-align: center;
|
|
295
|
-
}
|
|
296
|
-
.typography-module_link__DWurf:hover:not(.typography-module_disabled__hjK8C) {
|
|
297
|
-
text-decoration: underline;
|
|
298
|
-
color: #65C5F6;
|
|
299
|
-
}
|
|
300
|
-
.typography-module_link__DWurf.typography-module_disabled__hjK8C {
|
|
301
|
-
pointer-events: none;
|
|
302
|
-
opacity: 0.6;
|
|
303
|
-
}
|
|
304
233
|
:root {
|
|
305
234
|
--divider-line: #4a4b4b;
|
|
306
235
|
}
|
|
@@ -363,6 +292,19 @@
|
|
|
363
292
|
.button-module_button__NDMQS.button-module_warning__MdmiZ.button-module_transparent__zbeBu {
|
|
364
293
|
border: 1px solid #FFCC3D !important;
|
|
365
294
|
}
|
|
295
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu {
|
|
296
|
+
border: none !important;
|
|
297
|
+
background-color: transparent !important;
|
|
298
|
+
background: transparent !important;
|
|
299
|
+
}
|
|
300
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu:hover {
|
|
301
|
+
border: none !important;
|
|
302
|
+
background-color: transparent !important;
|
|
303
|
+
background: transparent !important;
|
|
304
|
+
}
|
|
305
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu:hover * {
|
|
306
|
+
text-decoration: underline !important;
|
|
307
|
+
}
|
|
366
308
|
.button-module_button__NDMQS.button-module_transparent__zbeBu {
|
|
367
309
|
border: none !important;
|
|
368
310
|
background-color: transparent !important;
|
|
@@ -403,6 +345,9 @@
|
|
|
403
345
|
.button-module_button__NDMQS:hover.button-module_animated__gLwPl {
|
|
404
346
|
transform: scale(1.2);
|
|
405
347
|
}
|
|
348
|
+
.button-module_button__NDMQS:hover.button-module_transparent__zbeBu {
|
|
349
|
+
background-color: rgba(197, 197, 197, 0.1254901961) !important;
|
|
350
|
+
}
|
|
406
351
|
.button-module_button__NDMQS.button-module_disabled__hEydO {
|
|
407
352
|
user-select: none;
|
|
408
353
|
pointer-events: none;
|
|
@@ -415,6 +360,11 @@
|
|
|
415
360
|
.cui-theme-light .button-module_button__NDMQS {
|
|
416
361
|
color: #090A0A;
|
|
417
362
|
}
|
|
363
|
+
.textAndContent-module_textAndContent__X5P1n {
|
|
364
|
+
align-items: baseline;
|
|
365
|
+
flex-shrink: 1;
|
|
366
|
+
gap: 8px;
|
|
367
|
+
}
|
|
418
368
|
:root {
|
|
419
369
|
--divider-line: #4a4b4b;
|
|
420
370
|
}
|
|
@@ -579,113 +529,6 @@
|
|
|
579
529
|
border-color: #FD8F3E;
|
|
580
530
|
color: #632E03;
|
|
581
531
|
}
|
|
582
|
-
:root {
|
|
583
|
-
--divider-line: #4a4b4b;
|
|
584
|
-
}
|
|
585
|
-
|
|
586
|
-
.toggle-module_overflow-hidden__NxfFx, .toggle-module_text-truncate__Wg-Jx {
|
|
587
|
-
overflow: hidden !important;
|
|
588
|
-
}
|
|
589
|
-
|
|
590
|
-
.toggle-module_text-nowrap__F9ld6, .toggle-module_text-truncate__Wg-Jx {
|
|
591
|
-
white-space: nowrap !important;
|
|
592
|
-
}
|
|
593
|
-
|
|
594
|
-
.toggle-module_text-ellipsis__ftYlg, .toggle-module_text-truncate__Wg-Jx {
|
|
595
|
-
text-overflow: ellipsis !important;
|
|
596
|
-
}
|
|
597
|
-
|
|
598
|
-
.toggle-module_toggle__p1Ep4 {
|
|
599
|
-
display: inline-block;
|
|
600
|
-
position: relative;
|
|
601
|
-
max-width: 48px;
|
|
602
|
-
max-height: 24px;
|
|
603
|
-
width: 48px;
|
|
604
|
-
height: 24px;
|
|
605
|
-
border-radius: 16px !important;
|
|
606
|
-
}
|
|
607
|
-
.toggle-module_toggle__p1Ep4 input {
|
|
608
|
-
opacity: 0;
|
|
609
|
-
width: 0;
|
|
610
|
-
height: 0;
|
|
611
|
-
}
|
|
612
|
-
.toggle-module_toggle__p1Ep4 .toggle-module_slider__2IVaG {
|
|
613
|
-
box-sizing: border-box;
|
|
614
|
-
position: absolute;
|
|
615
|
-
cursor: pointer;
|
|
616
|
-
width: 48px;
|
|
617
|
-
height: 24px;
|
|
618
|
-
top: 0;
|
|
619
|
-
left: 0;
|
|
620
|
-
right: 0;
|
|
621
|
-
bottom: 0;
|
|
622
|
-
background-color: transparent;
|
|
623
|
-
border: 1px solid #F4F4F4;
|
|
624
|
-
transition: transform, background-color 0.4s ease;
|
|
625
|
-
border-radius: 16px;
|
|
626
|
-
}
|
|
627
|
-
.toggle-module_toggle__p1Ep4 .toggle-module_slider__2IVaG:before {
|
|
628
|
-
position: absolute;
|
|
629
|
-
content: "";
|
|
630
|
-
height: 20px;
|
|
631
|
-
width: 20px;
|
|
632
|
-
left: 1px;
|
|
633
|
-
bottom: 1px;
|
|
634
|
-
background-color: #F4F4F4;
|
|
635
|
-
transition: transform 0.4s ease;
|
|
636
|
-
border-radius: 50%;
|
|
637
|
-
}
|
|
638
|
-
.toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG {
|
|
639
|
-
background-color: #282A2A;
|
|
640
|
-
border-color: #282A2A;
|
|
641
|
-
}
|
|
642
|
-
.toggle-module_toggle__p1Ep4 input:focus + .toggle-module_slider__2IVaG {
|
|
643
|
-
box-shadow: 0 0 1px 1px #282A2A;
|
|
644
|
-
}
|
|
645
|
-
.toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:before {
|
|
646
|
-
transform: translateX(24px);
|
|
647
|
-
}
|
|
648
|
-
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH {
|
|
649
|
-
opacity: 0.65;
|
|
650
|
-
}
|
|
651
|
-
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH input {
|
|
652
|
-
pointer-events: none;
|
|
653
|
-
}
|
|
654
|
-
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH .toggle-module_slider__2IVaG {
|
|
655
|
-
cursor: not-allowed;
|
|
656
|
-
}
|
|
657
|
-
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH .toggle-module_slider__2IVaG:after {
|
|
658
|
-
content: " ";
|
|
659
|
-
z-index: -1;
|
|
660
|
-
display: block;
|
|
661
|
-
position: absolute;
|
|
662
|
-
height: 100%;
|
|
663
|
-
top: 0;
|
|
664
|
-
left: 0;
|
|
665
|
-
right: 0;
|
|
666
|
-
}
|
|
667
|
-
|
|
668
|
-
.cui-theme-dark .toggle-module_toggle__p1Ep4 input:enabled + .toggle-module_slider__2IVaG:hover {
|
|
669
|
-
background-color: #003A4C;
|
|
670
|
-
}
|
|
671
|
-
.cui-theme-dark .toggle-module_toggle__p1Ep4 input:checked:enabled + .toggle-module_slider__2IVaG:hover {
|
|
672
|
-
background-color: #262828;
|
|
673
|
-
}
|
|
674
|
-
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG {
|
|
675
|
-
border-color: #202929;
|
|
676
|
-
}
|
|
677
|
-
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG:hover {
|
|
678
|
-
background-color: rgba(40, 42, 42, 0.05);
|
|
679
|
-
}
|
|
680
|
-
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG:before {
|
|
681
|
-
background-color: #282A2A;
|
|
682
|
-
}
|
|
683
|
-
.cui-theme-light .toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:before {
|
|
684
|
-
background-color: #F4F4F4;
|
|
685
|
-
}
|
|
686
|
-
.cui-theme-light .toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:hover {
|
|
687
|
-
background-color: #374646;
|
|
688
|
-
}
|
|
689
532
|
.flowLayout-module_flowLayout__VHpnY {
|
|
690
533
|
overflow: auto;
|
|
691
534
|
}
|
|
@@ -799,6 +642,72 @@
|
|
|
799
642
|
--divider-line: #4a4b4b;
|
|
800
643
|
}
|
|
801
644
|
|
|
645
|
+
.typography-module_overflow-hidden__UmQ-v, .typography-module_text-truncate__8MgV9 {
|
|
646
|
+
overflow: hidden !important;
|
|
647
|
+
}
|
|
648
|
+
|
|
649
|
+
.typography-module_text-nowrap__dt3uu, .typography-module_text-truncate__8MgV9 {
|
|
650
|
+
white-space: nowrap !important;
|
|
651
|
+
}
|
|
652
|
+
|
|
653
|
+
.typography-module_text-ellipsis__iyHeZ, .typography-module_text-truncate__8MgV9 {
|
|
654
|
+
text-overflow: ellipsis !important;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
.typography-module_headline__b0XlP {
|
|
658
|
+
font-size: 28px;
|
|
659
|
+
line-height: 32px;
|
|
660
|
+
}
|
|
661
|
+
|
|
662
|
+
.typography-module_headlineSecondary__IDnhT {
|
|
663
|
+
font-size: 24px;
|
|
664
|
+
line-height: 28px;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
.typography-module_headlineTertiary__mlG-v {
|
|
668
|
+
font-size: 18px;
|
|
669
|
+
line-height: 24x;
|
|
670
|
+
}
|
|
671
|
+
|
|
672
|
+
.typography-module_paragraph__tgBAx, .typography-module_paragraphBold__PmcZU, .typography-module_paragraphBoldSmall__qExmY, .typography-module_paragraphSmall__vTMiI {
|
|
673
|
+
font-size: 14px;
|
|
674
|
+
line-height: 18px;
|
|
675
|
+
font-weight: 300;
|
|
676
|
+
}
|
|
677
|
+
|
|
678
|
+
.typography-module_paragraphSmall__vTMiI, .typography-module_paragraphBoldSmall__qExmY {
|
|
679
|
+
font-size: 12px;
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
.typography-module_paragraphBold__PmcZU, .typography-module_paragraphBoldSmall__qExmY {
|
|
683
|
+
font-weight: 600;
|
|
684
|
+
}
|
|
685
|
+
|
|
686
|
+
.typography-module_link__DWurf {
|
|
687
|
+
overflow: hidden !important;
|
|
688
|
+
white-space: nowrap !important;
|
|
689
|
+
text-overflow: ellipsis !important;
|
|
690
|
+
text-decoration: none;
|
|
691
|
+
color: #65C5F6;
|
|
692
|
+
display: inline;
|
|
693
|
+
gap: 4px;
|
|
694
|
+
flex-grow: 0;
|
|
695
|
+
max-width: 400px;
|
|
696
|
+
position: relative;
|
|
697
|
+
vertical-align: center;
|
|
698
|
+
}
|
|
699
|
+
.typography-module_link__DWurf:hover:not(.typography-module_disabled__hjK8C) {
|
|
700
|
+
text-decoration: underline;
|
|
701
|
+
color: #65C5F6;
|
|
702
|
+
}
|
|
703
|
+
.typography-module_link__DWurf.typography-module_disabled__hjK8C {
|
|
704
|
+
pointer-events: none;
|
|
705
|
+
opacity: 0.6;
|
|
706
|
+
}
|
|
707
|
+
:root {
|
|
708
|
+
--divider-line: #4a4b4b;
|
|
709
|
+
}
|
|
710
|
+
|
|
802
711
|
.tooltip-module_overflow-hidden__YDzdx, .tooltip-module_text-truncate__CPvp3 {
|
|
803
712
|
overflow: hidden !important;
|
|
804
713
|
}
|
|
@@ -936,6 +845,113 @@
|
|
|
936
845
|
--divider-line: #4a4b4b;
|
|
937
846
|
}
|
|
938
847
|
|
|
848
|
+
.toggle-module_overflow-hidden__NxfFx, .toggle-module_text-truncate__Wg-Jx {
|
|
849
|
+
overflow: hidden !important;
|
|
850
|
+
}
|
|
851
|
+
|
|
852
|
+
.toggle-module_text-nowrap__F9ld6, .toggle-module_text-truncate__Wg-Jx {
|
|
853
|
+
white-space: nowrap !important;
|
|
854
|
+
}
|
|
855
|
+
|
|
856
|
+
.toggle-module_text-ellipsis__ftYlg, .toggle-module_text-truncate__Wg-Jx {
|
|
857
|
+
text-overflow: ellipsis !important;
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
.toggle-module_toggle__p1Ep4 {
|
|
861
|
+
display: inline-block;
|
|
862
|
+
position: relative;
|
|
863
|
+
max-width: 48px;
|
|
864
|
+
max-height: 24px;
|
|
865
|
+
width: 48px;
|
|
866
|
+
height: 24px;
|
|
867
|
+
border-radius: 16px !important;
|
|
868
|
+
}
|
|
869
|
+
.toggle-module_toggle__p1Ep4 input {
|
|
870
|
+
opacity: 0;
|
|
871
|
+
width: 0;
|
|
872
|
+
height: 0;
|
|
873
|
+
}
|
|
874
|
+
.toggle-module_toggle__p1Ep4 .toggle-module_slider__2IVaG {
|
|
875
|
+
box-sizing: border-box;
|
|
876
|
+
position: absolute;
|
|
877
|
+
cursor: pointer;
|
|
878
|
+
width: 48px;
|
|
879
|
+
height: 24px;
|
|
880
|
+
top: 0;
|
|
881
|
+
left: 0;
|
|
882
|
+
right: 0;
|
|
883
|
+
bottom: 0;
|
|
884
|
+
background-color: transparent;
|
|
885
|
+
border: 1px solid #F4F4F4;
|
|
886
|
+
transition: transform, background-color 0.4s ease;
|
|
887
|
+
border-radius: 16px;
|
|
888
|
+
}
|
|
889
|
+
.toggle-module_toggle__p1Ep4 .toggle-module_slider__2IVaG:before {
|
|
890
|
+
position: absolute;
|
|
891
|
+
content: "";
|
|
892
|
+
height: 20px;
|
|
893
|
+
width: 20px;
|
|
894
|
+
left: 1px;
|
|
895
|
+
bottom: 1px;
|
|
896
|
+
background-color: #F4F4F4;
|
|
897
|
+
transition: transform 0.4s ease;
|
|
898
|
+
border-radius: 50%;
|
|
899
|
+
}
|
|
900
|
+
.toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG {
|
|
901
|
+
background-color: #282A2A;
|
|
902
|
+
border-color: #282A2A;
|
|
903
|
+
}
|
|
904
|
+
.toggle-module_toggle__p1Ep4 input:focus + .toggle-module_slider__2IVaG {
|
|
905
|
+
box-shadow: 0 0 1px 1px #282A2A;
|
|
906
|
+
}
|
|
907
|
+
.toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:before {
|
|
908
|
+
transform: translateX(24px);
|
|
909
|
+
}
|
|
910
|
+
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH {
|
|
911
|
+
opacity: 0.65;
|
|
912
|
+
}
|
|
913
|
+
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH input {
|
|
914
|
+
pointer-events: none;
|
|
915
|
+
}
|
|
916
|
+
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH .toggle-module_slider__2IVaG {
|
|
917
|
+
cursor: not-allowed;
|
|
918
|
+
}
|
|
919
|
+
.toggle-module_toggle__p1Ep4.toggle-module_disabled__0nElH .toggle-module_slider__2IVaG:after {
|
|
920
|
+
content: " ";
|
|
921
|
+
z-index: -1;
|
|
922
|
+
display: block;
|
|
923
|
+
position: absolute;
|
|
924
|
+
height: 100%;
|
|
925
|
+
top: 0;
|
|
926
|
+
left: 0;
|
|
927
|
+
right: 0;
|
|
928
|
+
}
|
|
929
|
+
|
|
930
|
+
.cui-theme-dark .toggle-module_toggle__p1Ep4 input:enabled + .toggle-module_slider__2IVaG:hover {
|
|
931
|
+
background-color: #003A4C;
|
|
932
|
+
}
|
|
933
|
+
.cui-theme-dark .toggle-module_toggle__p1Ep4 input:checked:enabled + .toggle-module_slider__2IVaG:hover {
|
|
934
|
+
background-color: #262828;
|
|
935
|
+
}
|
|
936
|
+
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG {
|
|
937
|
+
border-color: #202929;
|
|
938
|
+
}
|
|
939
|
+
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG:hover {
|
|
940
|
+
background-color: rgba(40, 42, 42, 0.05);
|
|
941
|
+
}
|
|
942
|
+
.cui-theme-light .toggle-module_toggle__p1Ep4 input + .toggle-module_slider__2IVaG:before {
|
|
943
|
+
background-color: #282A2A;
|
|
944
|
+
}
|
|
945
|
+
.cui-theme-light .toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:before {
|
|
946
|
+
background-color: #F4F4F4;
|
|
947
|
+
}
|
|
948
|
+
.cui-theme-light .toggle-module_toggle__p1Ep4 input:checked + .toggle-module_slider__2IVaG:hover {
|
|
949
|
+
background-color: #374646;
|
|
950
|
+
}
|
|
951
|
+
:root {
|
|
952
|
+
--divider-line: #4a4b4b;
|
|
953
|
+
}
|
|
954
|
+
|
|
939
955
|
.anchorLink-module_overflow-hidden__-MElA, .anchorLink-module_text-truncate__62t8P {
|
|
940
956
|
overflow: hidden !important;
|
|
941
957
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var e=require("./useApi.js"),s=require("./useToggle.js"),r=require("./
|
|
1
|
+
"use strict";var e=require("./useApi.js"),s=require("./useToggle.js"),r=require("./useToggle2.js"),u=require("./useOutsideClick.js"),o=require("./useResize.js"),t=require("./useClassNames.js"),i=require("./useParseProps.js"),p=require("./useThemePreference.js"),m=require("./useAnimation.js"),a=require("./useIntersectionObserver.js"),l=require("./useSetTimeout.js");exports.useApi=e.useApi,exports.useToggle=s.useToggle,exports.useToggle2=r.useToggle2,exports.outsideClickHandler=u.outsideClickHandler,exports.useOutsideClick=u.useOutsideClick,exports.useResize=o.useResize,exports.useClassNames=t.useClassNames,exports.useParseProps=i.useParseProps,exports.getBaseThemes=p.getBaseThemes,exports.observeThemePreference=p.observeThemePreference,exports.setThemeClassNames=p.setThemeClassNames,exports.switchColorTheme=p.switchColorTheme,exports.updateColorTheme=p.updateColorTheme,exports.useThemePreference=p.useThemePreference,exports.useAnimation=m.useAnimation,exports.useIntersectionObserver=a.useIntersectionObserver,exports.useTimeoutFn=l.useTimeoutFn;
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var e=require("react");exports.useToggle2=a=>{const[s,t]=e.useState(a),l=e.useCallback((e=>{t((a=>"boolean"==typeof e?e:!a))}),[]),o=e.useCallback((e=>l(void 0===e||e)),[l]),r=e.useCallback((e=>l(void 0!==e&&e)),[l]);return[s,l,o,r]};
|
|
2
|
+
//# sourceMappingURL=useToggle2.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useToggle2.js","sources":["../../../../../src/core/hooks/useToggle2.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\n/**\n * Type definition for the return value of the `useToggle` hook.\n * @typedef {Array} useToggleReturnType\n * @property {boolean} 0 - The current toggled state.\n * @property {(value?: any | boolean) => void} 1 - Function to toggle the state.\n * @property {(value?: any | boolean) => void} 2 - Function to forcefully set the state to true.\n * @property {(value?: any | boolean) => void} 3 - Function to forcefully set the state to false.\n */\nexport type useToggleReturnType2 = [\n boolean,\n (value?: any | boolean) => void,\n (value?: any | boolean) => void,\n (value?: any | boolean) => void\n]\n\n/**\n * Custom hook to manage a boolean state with toggle functionality.\n * @param {boolean} defaultValue - The initial value of the toggled state.\n * @returns {useToggleReturnType2} An array containing the current state, a toggle function,\n * and functions to set the state to true or false.\n */\nexport const useToggle2 = (defaultValue: boolean): useToggleReturnType2 => {\n const [toggled, setToggled] = useState(defaultValue)\n\n /**\n * Function to toggle the state.\n * @param {any | boolean} [value] - Optional value to set the state. If not provided, the state will be toggled.\n */\n const handleToggle: (value?: any | boolean) => void = useCallback((value?: any | boolean) => {\n setToggled((prevToggled) => (typeof (value) === 'boolean' ? value : !prevToggled))\n }, [])\n\n /**\n * Function to set the state to true.\n * @param {boolean} [forceValue] - Optional value to forcefully set the state.\n * If not provided, the state will be set to true.\n */\n const handleToggleTrue = useCallback(\n (forceValue?: boolean) => handleToggle(forceValue === undefined ? true : forceValue), [handleToggle],\n )\n\n /**\n * Function to set the state to false.\n * @param {boolean} [forceValue] - Optional value to forcefully set the state.\n * If not provided, the state will be set to false.\n */\n const handleToggleFalse = useCallback(\n (forceValue?: boolean) => handleToggle(forceValue === undefined ? false : forceValue), [handleToggle],\n )\n\n return [toggled, handleToggle, handleToggleTrue, handleToggleFalse]\n}\n"],"names":["defaultValue","toggled","setToggled","useState","handleToggle","useCallback","value","prevToggled","handleToggleTrue","forceValue","undefined","handleToggleFalse"],"mappings":"uDAuB2BA,IACzB,MAAOC,EAASC,GAAcC,EAAQA,SAACH,GAMjCI,EAAgDC,EAAWA,aAAEC,IACjEJ,GAAYK,GAAoC,kBAAXD,EAAuBA,GAASC,GAAa,GACjF,IAOGC,EAAmBH,EAAAA,aACtBI,GAAyBL,OAA4BM,IAAfD,GAAkCA,IAAa,CAACL,IAQnFO,EAAoBN,EAAAA,aACvBI,GAAyBL,OAA4BM,IAAfD,GAAmCA,IAAa,CAACL,IAG1F,MAAO,CAACH,EAASG,EAAcI,EAAkBG,EAAkB"}
|
package/dist/lib/cjs/index.css
CHANGED
|
@@ -392,6 +392,19 @@
|
|
|
392
392
|
.button-module_button__NDMQS.button-module_warning__MdmiZ.button-module_transparent__zbeBu {
|
|
393
393
|
border: 1px solid #FFCC3D !important;
|
|
394
394
|
}
|
|
395
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu {
|
|
396
|
+
border: none !important;
|
|
397
|
+
background-color: transparent !important;
|
|
398
|
+
background: transparent !important;
|
|
399
|
+
}
|
|
400
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu:hover {
|
|
401
|
+
border: none !important;
|
|
402
|
+
background-color: transparent !important;
|
|
403
|
+
background: transparent !important;
|
|
404
|
+
}
|
|
405
|
+
.button-module_button__NDMQS.button-module_link__e-4Fu:hover * {
|
|
406
|
+
text-decoration: underline !important;
|
|
407
|
+
}
|
|
395
408
|
.button-module_button__NDMQS.button-module_transparent__zbeBu {
|
|
396
409
|
border: none !important;
|
|
397
410
|
background-color: transparent !important;
|
|
@@ -432,6 +445,9 @@
|
|
|
432
445
|
.button-module_button__NDMQS:hover.button-module_animated__gLwPl {
|
|
433
446
|
transform: scale(1.2);
|
|
434
447
|
}
|
|
448
|
+
.button-module_button__NDMQS:hover.button-module_transparent__zbeBu {
|
|
449
|
+
background-color: rgba(197, 197, 197, 0.1254901961) !important;
|
|
450
|
+
}
|
|
435
451
|
.button-module_button__NDMQS.button-module_disabled__hEydO {
|
|
436
452
|
user-select: none;
|
|
437
453
|
pointer-events: none;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var e=require("react");exports.useToggle2=a=>{const[s,t]=e.useState(a),l=e.useCallback((e=>{t((a=>"boolean"==typeof e?e:!a))}),[]),o=e.useCallback((e=>l(void 0===e||e)),[l]),r=e.useCallback((e=>l(void 0!==e&&e)),[l]);return[s,l,o,r]};
|
|
2
|
+
//# sourceMappingURL=useToggle2.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useToggle2.js","sources":["../../../../../../src/core/hooks/useToggle2.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\n/**\n * Type definition for the return value of the `useToggle` hook.\n * @typedef {Array} useToggleReturnType\n * @property {boolean} 0 - The current toggled state.\n * @property {(value?: any | boolean) => void} 1 - Function to toggle the state.\n * @property {(value?: any | boolean) => void} 2 - Function to forcefully set the state to true.\n * @property {(value?: any | boolean) => void} 3 - Function to forcefully set the state to false.\n */\nexport type useToggleReturnType2 = [\n boolean,\n (value?: any | boolean) => void,\n (value?: any | boolean) => void,\n (value?: any | boolean) => void\n]\n\n/**\n * Custom hook to manage a boolean state with toggle functionality.\n * @param {boolean} defaultValue - The initial value of the toggled state.\n * @returns {useToggleReturnType2} An array containing the current state, a toggle function,\n * and functions to set the state to true or false.\n */\nexport const useToggle2 = (defaultValue: boolean): useToggleReturnType2 => {\n const [toggled, setToggled] = useState(defaultValue)\n\n /**\n * Function to toggle the state.\n * @param {any | boolean} [value] - Optional value to set the state. If not provided, the state will be toggled.\n */\n const handleToggle: (value?: any | boolean) => void = useCallback((value?: any | boolean) => {\n setToggled((prevToggled) => (typeof (value) === 'boolean' ? value : !prevToggled))\n }, [])\n\n /**\n * Function to set the state to true.\n * @param {boolean} [forceValue] - Optional value to forcefully set the state.\n * If not provided, the state will be set to true.\n */\n const handleToggleTrue = useCallback(\n (forceValue?: boolean) => handleToggle(forceValue === undefined ? true : forceValue), [handleToggle],\n )\n\n /**\n * Function to set the state to false.\n * @param {boolean} [forceValue] - Optional value to forcefully set the state.\n * If not provided, the state will be set to false.\n */\n const handleToggleFalse = useCallback(\n (forceValue?: boolean) => handleToggle(forceValue === undefined ? false : forceValue), [handleToggle],\n )\n\n return [toggled, handleToggle, handleToggleTrue, handleToggleFalse]\n}\n"],"names":["defaultValue","toggled","setToggled","useState","handleToggle","useCallback","value","prevToggled","handleToggleTrue","forceValue","undefined","handleToggleFalse"],"mappings":"uDAuB2BA,IACzB,MAAOC,EAASC,GAAcC,EAAQA,SAACH,GAMjCI,EAAgDC,EAAWA,aAAEC,IACjEJ,GAAYK,GAAoC,kBAAXD,EAAuBA,GAASC,GAAa,GACjF,IAOGC,EAAmBH,EAAAA,aACtBI,GAAyBL,OAA4BM,IAAfD,GAAkCA,IAAa,CAACL,IAQnFO,EAAoBN,EAAAA,aACvBI,GAAyBL,OAA4BM,IAAfD,GAAmCA,IAAa,CAACL,IAG1F,MAAO,CAACH,EAASG,EAAcI,EAAkBG,EAAkB"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var e=require("../../../../../../_virtual/_rollupPluginBabelHelpers.js"),t=require("react"),a=require("
|
|
1
|
+
"use strict";var e=require("../../../../../../_virtual/_rollupPluginBabelHelpers.js"),t=require("react"),a=require("./button.module.scss.js"),n=require("../text/Link.js"),r=require("../../../../utils/helpers/ui.js"),o=require("../../../../utils/helpers/text.js"),i=require("../../icon/IconBase.js");const s={ENTER:{key:"Enter",keyCode:13}},l=t.memo((e=>{let{variant:a,href:o,target:i,children:s,...l}=e;return"link"===a?t.createElement(n.Link,{width:"100%",href:o,target:i,...l,onClick:r.noop},s):t.createElement("span",{},s)}));l.displayName="InnerElement";const c=t.memo((n=>{let{label:i,children:c,variant:d,tiny:u,truncate:p,fluid:m,preventDefualt:h,stopPropagation:f,onClick:E,type:I="button",transparent:g,hasShadow:k,hasIcon:y,disabled:b,animated:v=!1,className:C="",id:x,href:N,target:j,...q}=n;const B=`${i||c?.toString()}`,P=t.useCallback((e=>{h&&e.preventDefault(),f&&(e.stopPropagation(),e.nativeEvent.stopImmediatePropagation()),E?.(e)}),[E,h,f]),R=t.useCallback((e=>{e.key===s.ENTER.key&&(h&&e.preventDefault(),f&&(e.stopPropagation(),e.nativeEvent.stopImmediatePropagation()),E?.(e))}),[E,h,f]);return React.createElement("button",e.extends({type:I,tabIndex:-1,onClick:P,onKeyDown:R,className:r.classNames(a.default.button,u&&a.default.tiny,d&&a.default[d],p&&a.default.truncate,m&&a.default.fluid,v&&a.default.animated,g&&a.default.transparent,k&&a.default.hasShadow,y&&a.default.hasIcon,b&&a.default.disabled,C),id:`${x||B&&o.composeId(B)}`,"data-testid":`${q.dataTestId||q["data-testid"]||x||B&&o.composeId(B)}`},q),React.createElement(l,{variant:d,href:N,target:j},i&&i,c||c))}));c.displayName="Button";const d=["iconUrl","minWidth","minHeight","width","height","size","fontSize","color"],u=t.memo((t=>{const a={},n={};return Object.entries(t).forEach((e=>{let[t,r]=e;d.includes(t)?n[t]=r:a[t]=r})),n.children=t.children,React.createElement(c,e.extends({},a,{hasIcon:!0}),t.iconContent&&t.iconContent,!t.iconContent&&React.createElement(i.IconBase,n))}));u.displayName="IconButton",exports.Button=c,exports.IconButton=u,exports.keys=s;
|
|
2
2
|
//# sourceMappingURL=Button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.js","sources":["../../../../../../../../../src/core/ui/components/atoms/button/Button.tsx"],"sourcesContent":["import { memo, useCallback, MouseEvent, KeyboardEvent, createElement, FC, HTMLAttributes } from 'react'\n\nimport { classNames, composeId, noop } from '../../../../utils'\nimport { Alerts } from '../../../../constants'\nimport {
|
|
1
|
+
{"version":3,"file":"Button.js","sources":["../../../../../../../../../src/core/ui/components/atoms/button/Button.tsx"],"sourcesContent":["import { memo, useCallback, MouseEvent, KeyboardEvent, createElement, FC, HTMLAttributes } from 'react'\n\nimport { classNames, composeId, noop } from '../../../../utils'\nimport { Alerts } from '../../../../constants'\nimport { Link } from '../text'\nimport { IconBase, IconBaseProps } from '../../icon'\n\nimport type { ButtonProps, IconButtonProps } from './button.types'\nimport classes from './button.module.scss'\n\n\nexport const keys = {\n ENTER: {\n key: 'Enter',\n keyCode: 13,\n },\n}\n\ntype InnerElementsProps = Partial<ButtonProps> & Partial<HTMLAttributes<HTMLAnchorElement>>\n\nconst InnerElement: FC<InnerElementsProps> = memo(({\n variant, href, target, children, ...props\n}: Omit<InnerElementsProps, 'onClick'>) => {\n if (variant === 'link') {\n return createElement(Link, { width: '100%', href, target, ...props, onClick: noop }, children)\n }\n return createElement('span', {}, children)\n})\n\nInnerElement.displayName = 'InnerElement'\n\n/**\n * Button component for displaying buttons with optional features.\n * @component\n *\n * Generated component from Template\n * @param {object} props - The component props.\n * @param {string} props.label - The value to be displayed in the button.\n * @param {ReactNode} [props.children] - Additional content to be displayed inside the button.\n * @param {string} [props.variant] - The variant of the button (e.g., 'primary', 'secondary').\n * @param {boolean} [props.tiny] - Whether the button should be tiny.\n * @param {boolean} [props.truncate] - Whether the content inside the button should be truncated.\n * @param {boolean} [props.fluid] - Whether the button should have a fluid width.\n * @param {boolean} [props.animated=true] - Whether the button should have animation (default is true).\n * @param {string} [props.className] - Additional classes to be applied to the button.\n * @param {...object} props.props - Additional props to be spread to the underlying div element.\n *\n * @returns {JSX.Element} The rendered Button component.\n */\nexport const Button = memo(({\n label, children,\n variant, tiny, truncate, fluid,\n preventDefualt, stopPropagation,\n onClick,\n type = 'button',\n transparent,\n hasShadow,\n hasIcon,\n disabled,\n animated = false, className = '', id,\n href,\n target,\n ...props\n}: ButtonProps) => {\n const textFromChildren: string | undefined = `${label || children?.toString()}`\n\n const clickHandler = useCallback((event: MouseEvent) => {\n if (preventDefualt) {\n event.preventDefault()\n }\n if (stopPropagation) {\n event.stopPropagation()\n event.nativeEvent.stopImmediatePropagation()\n }\n onClick?.(event)\n }, [onClick, preventDefualt, stopPropagation])\n\n const keyDownHandler = useCallback((event: KeyboardEvent) => {\n if (event.key === keys.ENTER.key) {\n if (preventDefualt) {\n event.preventDefault()\n }\n if (stopPropagation) {\n event.stopPropagation()\n event.nativeEvent.stopImmediatePropagation()\n }\n onClick?.(event)\n }\n }, [onClick, preventDefualt, stopPropagation])\n\n return (\n <button\n // eslint-disable-next-line react/button-has-type\n type={type}\n tabIndex={-1}\n onClick={clickHandler}\n onKeyDown={keyDownHandler}\n className={classNames(\n classes.button,\n tiny && classes.tiny,\n variant && classes[variant as Alerts],\n truncate && classes.truncate,\n fluid && classes.fluid,\n animated && classes.animated,\n transparent && classes.transparent,\n hasShadow && classes.hasShadow,\n hasIcon && classes.hasIcon,\n disabled && classes.disabled,\n className,\n )}\n id={`${id || (textFromChildren && composeId(textFromChildren))}`}\n data-testid={`${(props as Record<string, string>).dataTestId || (props as Record<string, string>)['data-testid'] || id || (textFromChildren && composeId(textFromChildren))}`}\n {...props}\n >\n <InnerElement variant={variant} href={href} target={target}>\n {label && label}\n {children || children}\n </InnerElement>\n </button>\n )\n})\n\nexport type ButtonType = typeof Button\n\n// Set display name for the component.\nButton.displayName = 'Button'\n\nconst iconBaseProps = [\n 'iconUrl',\n 'minWidth',\n 'minHeight',\n 'width',\n 'height',\n 'size',\n 'fontSize',\n 'color',\n]\n\nexport const IconButton: FC<IconButtonProps> = memo<IconButtonProps>((props: IconButtonProps) => {\n const buttonProps: Record<string, unknown> = {}\n const iconProps: Record<string, unknown> = {}\n\n Object.entries(props).forEach(([name, value]: [string, unknown]) => {\n if (iconBaseProps.includes(name)) {\n // eslint-disable-next-line no-param-reassign\n iconProps[name] = value\n } else {\n buttonProps[name] = value\n }\n })\n\n iconProps.children = props.children\n\n return (\n <Button {...(buttonProps as ButtonProps)} hasIcon>\n {props.iconContent && props.iconContent}\n {!props.iconContent && (<IconBase {...(iconProps as IconBaseProps)} />)}\n </Button>\n )\n})\n\nIconButton.displayName = 'IconButton'\n"],"names":["keys","ENTER","key","keyCode","InnerElement","memo","_ref","variant","href","target","children","props","createElement","Link","width","onClick","noop","displayName","Button","_ref2","label","tiny","truncate","fluid","preventDefualt","stopPropagation","type","transparent","hasShadow","hasIcon","disabled","animated","className","id","textFromChildren","toString","clickHandler","useCallback","event","preventDefault","nativeEvent","stopImmediatePropagation","keyDownHandler","React","_extends","tabIndex","onKeyDown","classNames","classes","default","button","composeId","dataTestId","iconBaseProps","IconButton","buttonProps","iconProps","Object","entries","forEach","_ref3","name","value","includes","iconContent","IconBase"],"mappings":"2SAWO,MAAMA,EAAO,CAClBC,MAAO,CACLC,IAAK,QACLC,QAAS,KAMPC,EAAuCC,EAAIA,MAACC,IAEP,IAFQC,QACjDA,EAAOC,KAAEA,EAAIC,OAAEA,EAAMC,SAAEA,KAAaC,GACAL,EACpC,MAAgB,SAAZC,EACKK,EAAAA,cAAcC,EAAAA,KAAM,CAAEC,MAAO,OAAQN,OAAMC,YAAWE,EAAOI,QAASC,EAAAA,MAAQN,GAEhFE,gBAAc,OAAQ,CAAE,EAAEF,EAAS,IAG5CN,EAAaa,YAAc,qBAoBdC,EAASb,EAAIA,MAACc,IAcR,IAdSC,MAC1BA,EAAKV,SAAEA,EAAQH,QACfA,EAAOc,KAAEA,EAAIC,SAAEA,EAAQC,MAAEA,EAAKC,eAC9BA,EAAcC,gBAAEA,EAAeV,QAC/BA,EAAOW,KACPA,EAAO,SAAQC,YACfA,EAAWC,UACXA,EAASC,QACTA,EAAOC,SACPA,EAAQC,SACRA,GAAW,EAAKC,UAAEA,EAAY,GAAEC,GAAEA,EAAEzB,KACpCA,EAAIC,OACJA,KACGE,GACSQ,EACZ,MAAMe,EAAuC,GAAGd,GAASV,GAAUyB,aAE7DC,EAAeC,EAAWA,aAAEC,IAC5Bd,GACFc,EAAMC,iBAEJd,IACFa,EAAMb,kBACNa,EAAME,YAAYC,4BAEpB1B,IAAUuB,EAAM,GACf,CAACvB,EAASS,EAAgBC,IAEvBiB,EAAiBL,EAAWA,aAAEC,IAC9BA,EAAMpC,MAAQF,EAAKC,MAAMC,MACvBsB,GACFc,EAAMC,iBAEJd,IACFa,EAAMb,kBACNa,EAAME,YAAYC,4BAEpB1B,IAAUuB,GACZ,GACC,CAACvB,EAASS,EAAgBC,IAE7B,OACEkB,MAAA/B,cAAA,SAAAgC,UAAA,CAEElB,KAAMA,EACNmB,UAAW,EACX9B,QAASqB,EACTU,UAAWJ,EACXV,UAAWe,EAAUA,WACnBC,EAAOC,QAACC,OACR7B,GAAQ2B,EAAOC,QAAC5B,KAChBd,GAAWyC,EAAAA,QAAQzC,GACnBe,GAAY0B,EAAOC,QAAC3B,SACpBC,GAASyB,UAAQzB,MACjBQ,GAAYiB,EAAAA,QAAQjB,SACpBJ,GAAeqB,EAAAA,QAAQrB,YACvBC,GAAaoB,EAAOC,QAACrB,UACrBC,GAAWmB,EAAOC,QAACpB,QACnBC,GAAYkB,EAAOC,QAACnB,SACpBE,GAEFC,GAAI,GAAGA,GAAOC,GAAoBiB,EAASA,UAACjB,KAC5C,cAAa,GAAIvB,EAAiCyC,YAAezC,EAAiC,gBAAkBsB,GAAOC,GAAoBiB,YAAUjB,MACrJvB,GAEJgC,MAAA/B,cAACR,EAAY,CAACG,QAASA,EAASC,KAAMA,EAAMC,OAAQA,GACjDW,GAASA,EACTV,GAAYA,GAER,IAObQ,EAAOD,YAAc,SAErB,MAAMoC,EAAgB,CACpB,UACA,WACA,YACA,QACA,SACA,OACA,WACA,SAGWC,EAAkCjD,EAAIA,MAAmBM,IACpE,MAAM4C,EAAuC,CAAA,EACvCC,EAAqC,CAAA,EAa3C,OAXAC,OAAOC,QAAQ/C,GAAOgD,SAAQC,IAAsC,IAApCC,EAAMC,GAAyBF,EACzDP,EAAcU,SAASF,GAEzBL,EAAUK,GAAQC,EAElBP,EAAYM,GAAQC,CACtB,IAGFN,EAAU9C,SAAWC,EAAMD,SAGzBiC,MAAA/B,cAACM,EAAM0B,EAAAA,WAAMW,EAAW,CAAkB1B,SAAO,IAC9ClB,EAAMqD,aAAerD,EAAMqD,aAC1BrD,EAAMqD,aAAgBrB,MAAA/B,cAACqD,WAAcT,GAChC,IAIbF,EAAWrC,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default={"overflow-hidden":"button-module_overflow-hidden__Vc5AU","text-truncate":"button-module_text-truncate__a89Bp","text-nowrap":"button-module_text-nowrap__tR-VJ","text-ellipsis":"button-module_text-ellipsis__5MFA9",button:"button-module_button__NDMQS",info:"button-module_info__O6gEW",transparent:"button-module_transparent__zbeBu",success:"button-module_success__gM25y",error:"button-module_error__q9qqo",warning:"button-module_warning__MdmiZ",tiny:"button-module_tiny__pBNwo",fluid:"button-module_fluid__GXxID",truncate:"button-module_truncate__c-G9k",animated:"button-module_animated__gLwPl",hasShadow:"button-module_hasShadow__42BQv",hasIcon:"button-module_hasIcon__dXLlJ",disabled:"button-module_disabled__hEydO"};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default={"overflow-hidden":"button-module_overflow-hidden__Vc5AU","text-truncate":"button-module_text-truncate__a89Bp","text-nowrap":"button-module_text-nowrap__tR-VJ","text-ellipsis":"button-module_text-ellipsis__5MFA9",button:"button-module_button__NDMQS",info:"button-module_info__O6gEW",transparent:"button-module_transparent__zbeBu",success:"button-module_success__gM25y",error:"button-module_error__q9qqo",warning:"button-module_warning__MdmiZ",link:"button-module_link__e-4Fu",tiny:"button-module_tiny__pBNwo",fluid:"button-module_fluid__GXxID",truncate:"button-module_truncate__c-G9k",animated:"button-module_animated__gLwPl",hasShadow:"button-module_hasShadow__42BQv",hasIcon:"button-module_hasIcon__dXLlJ",disabled:"button-module_disabled__hEydO"};
|
|
2
2
|
//# sourceMappingURL=button.module.scss.js.map
|