@matbea-ui/matbea-ui 0.1.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.
@@ -0,0 +1,2672 @@
1
+ import Xe, { useState as W, forwardRef as Ie, useCallback as L, useId as we, useRef as Z, useMemo as ve, useLayoutEffect as Oe, useEffect as ye } from "react";
2
+ import $, { css as g, styled as s, keyframes as Ue } from "styled-components";
3
+ var xe = { exports: {} }, ce = {};
4
+ var Ee;
5
+ function qe() {
6
+ if (Ee) return ce;
7
+ Ee = 1;
8
+ var e = Symbol.for("react.transitional.element"), r = Symbol.for("react.fragment");
9
+ function o(i, l, c) {
10
+ var d = null;
11
+ if (c !== void 0 && (d = "" + c), l.key !== void 0 && (d = "" + l.key), "key" in l) {
12
+ c = {};
13
+ for (var x in l)
14
+ x !== "key" && (c[x] = l[x]);
15
+ } else c = l;
16
+ return l = c.ref, {
17
+ $$typeof: e,
18
+ type: i,
19
+ key: d,
20
+ ref: l !== void 0 ? l : null,
21
+ props: c
22
+ };
23
+ }
24
+ return ce.Fragment = r, ce.jsx = o, ce.jsxs = o, ce;
25
+ }
26
+ var de = {};
27
+ var Te;
28
+ function Je() {
29
+ return Te || (Te = 1, process.env.NODE_ENV !== "production" && (function() {
30
+ function e(n) {
31
+ if (n == null) return null;
32
+ if (typeof n == "function")
33
+ return n.$$typeof === R ? null : n.displayName || n.name || null;
34
+ if (typeof n == "string") return n;
35
+ switch (n) {
36
+ case _:
37
+ return "Fragment";
38
+ case O:
39
+ return "Profiler";
40
+ case C:
41
+ return "StrictMode";
42
+ case re:
43
+ return "Suspense";
44
+ case F:
45
+ return "SuspenseList";
46
+ case q:
47
+ return "Activity";
48
+ }
49
+ if (typeof n == "object")
50
+ switch (typeof n.tag == "number" && console.error(
51
+ "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
52
+ ), n.$$typeof) {
53
+ case B:
54
+ return "Portal";
55
+ case I:
56
+ return n.displayName || "Context";
57
+ case G:
58
+ return (n._context.displayName || "Context") + ".Consumer";
59
+ case P:
60
+ var h = n.render;
61
+ return n = n.displayName, n || (n = h.displayName || h.name || "", n = n !== "" ? "ForwardRef(" + n + ")" : "ForwardRef"), n;
62
+ case H:
63
+ return h = n.displayName || null, h !== null ? h : e(n.type) || "Memo";
64
+ case N:
65
+ h = n._payload, n = n._init;
66
+ try {
67
+ return e(n(h));
68
+ } catch {
69
+ }
70
+ }
71
+ return null;
72
+ }
73
+ function r(n) {
74
+ return "" + n;
75
+ }
76
+ function o(n) {
77
+ try {
78
+ r(n);
79
+ var h = !1;
80
+ } catch {
81
+ h = !0;
82
+ }
83
+ if (h) {
84
+ h = console;
85
+ var p = h.error, a = typeof Symbol == "function" && Symbol.toStringTag && n[Symbol.toStringTag] || n.constructor.name || "Object";
86
+ return p.call(
87
+ h,
88
+ "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
89
+ a
90
+ ), r(n);
91
+ }
92
+ }
93
+ function i(n) {
94
+ if (n === _) return "<>";
95
+ if (typeof n == "object" && n !== null && n.$$typeof === N)
96
+ return "<...>";
97
+ try {
98
+ var h = e(n);
99
+ return h ? "<" + h + ">" : "<...>";
100
+ } catch {
101
+ return "<...>";
102
+ }
103
+ }
104
+ function l() {
105
+ var n = U.A;
106
+ return n === null ? null : n.getOwner();
107
+ }
108
+ function c() {
109
+ return Error("react-stack-top-frame");
110
+ }
111
+ function d(n) {
112
+ if (V.call(n, "key")) {
113
+ var h = Object.getOwnPropertyDescriptor(n, "key").get;
114
+ if (h && h.isReactWarning) return !1;
115
+ }
116
+ return n.key !== void 0;
117
+ }
118
+ function x(n, h) {
119
+ function p() {
120
+ J || (J = !0, console.error(
121
+ "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
122
+ h
123
+ ));
124
+ }
125
+ p.isReactWarning = !0, Object.defineProperty(n, "key", {
126
+ get: p,
127
+ configurable: !0
128
+ });
129
+ }
130
+ function w() {
131
+ var n = e(this.type);
132
+ return D[n] || (D[n] = !0, console.error(
133
+ "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
134
+ )), n = this.props.ref, n !== void 0 ? n : null;
135
+ }
136
+ function b(n, h, p, a, f, E) {
137
+ var m = p.ref;
138
+ return n = {
139
+ $$typeof: k,
140
+ type: n,
141
+ key: h,
142
+ props: p,
143
+ _owner: a
144
+ }, (m !== void 0 ? m : null) !== null ? Object.defineProperty(n, "ref", {
145
+ enumerable: !1,
146
+ get: w
147
+ }) : Object.defineProperty(n, "ref", { enumerable: !1, value: null }), n._store = {}, Object.defineProperty(n._store, "validated", {
148
+ configurable: !1,
149
+ enumerable: !1,
150
+ writable: !0,
151
+ value: 0
152
+ }), Object.defineProperty(n, "_debugInfo", {
153
+ configurable: !1,
154
+ enumerable: !1,
155
+ writable: !0,
156
+ value: null
157
+ }), Object.defineProperty(n, "_debugStack", {
158
+ configurable: !1,
159
+ enumerable: !1,
160
+ writable: !0,
161
+ value: f
162
+ }), Object.defineProperty(n, "_debugTask", {
163
+ configurable: !1,
164
+ enumerable: !1,
165
+ writable: !0,
166
+ value: E
167
+ }), Object.freeze && (Object.freeze(n.props), Object.freeze(n)), n;
168
+ }
169
+ function j(n, h, p, a, f, E) {
170
+ var m = h.children;
171
+ if (m !== void 0)
172
+ if (a)
173
+ if (ie(m)) {
174
+ for (a = 0; a < m.length; a++)
175
+ y(m[a]);
176
+ Object.freeze && Object.freeze(m);
177
+ } else
178
+ console.error(
179
+ "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
180
+ );
181
+ else y(m);
182
+ if (V.call(h, "key")) {
183
+ m = e(n);
184
+ var z = Object.keys(h).filter(function(te) {
185
+ return te !== "key";
186
+ });
187
+ a = 0 < z.length ? "{key: someKey, " + z.join(": ..., ") + ": ...}" : "{key: someKey}", ee[m + a] || (z = 0 < z.length ? "{" + z.join(": ..., ") + ": ...}" : "{}", console.error(
188
+ `A props object containing a "key" prop is being spread into JSX:
189
+ let props = %s;
190
+ <%s {...props} />
191
+ React keys must be passed directly to JSX without using spread:
192
+ let props = %s;
193
+ <%s key={someKey} {...props} />`,
194
+ a,
195
+ m,
196
+ z,
197
+ m
198
+ ), ee[m + a] = !0);
199
+ }
200
+ if (m = null, p !== void 0 && (o(p), m = "" + p), d(h) && (o(h.key), m = "" + h.key), "key" in h) {
201
+ p = {};
202
+ for (var ae in h)
203
+ ae !== "key" && (p[ae] = h[ae]);
204
+ } else p = h;
205
+ return m && x(
206
+ p,
207
+ typeof n == "function" ? n.displayName || n.name || "Unknown" : n
208
+ ), b(
209
+ n,
210
+ m,
211
+ p,
212
+ l(),
213
+ f,
214
+ E
215
+ );
216
+ }
217
+ function y(n) {
218
+ S(n) ? n._store && (n._store.validated = 1) : typeof n == "object" && n !== null && n.$$typeof === N && (n._payload.status === "fulfilled" ? S(n._payload.value) && n._payload.value._store && (n._payload.value._store.validated = 1) : n._store && (n._store.validated = 1));
219
+ }
220
+ function S(n) {
221
+ return typeof n == "object" && n !== null && n.$$typeof === k;
222
+ }
223
+ var T = Xe, k = Symbol.for("react.transitional.element"), B = Symbol.for("react.portal"), _ = Symbol.for("react.fragment"), C = Symbol.for("react.strict_mode"), O = Symbol.for("react.profiler"), G = Symbol.for("react.consumer"), I = Symbol.for("react.context"), P = Symbol.for("react.forward_ref"), re = Symbol.for("react.suspense"), F = Symbol.for("react.suspense_list"), H = Symbol.for("react.memo"), N = Symbol.for("react.lazy"), q = Symbol.for("react.activity"), R = Symbol.for("react.client.reference"), U = T.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, V = Object.prototype.hasOwnProperty, ie = Array.isArray, Q = console.createTask ? console.createTask : function() {
224
+ return null;
225
+ };
226
+ T = {
227
+ react_stack_bottom_frame: function(n) {
228
+ return n();
229
+ }
230
+ };
231
+ var J, D = {}, Y = T.react_stack_bottom_frame.bind(
232
+ T,
233
+ c
234
+ )(), oe = Q(i(c)), ee = {};
235
+ de.Fragment = _, de.jsx = function(n, h, p) {
236
+ var a = 1e4 > U.recentlyCreatedOwnerStacks++;
237
+ return j(
238
+ n,
239
+ h,
240
+ p,
241
+ !1,
242
+ a ? Error("react-stack-top-frame") : Y,
243
+ a ? Q(i(n)) : oe
244
+ );
245
+ }, de.jsxs = function(n, h, p) {
246
+ var a = 1e4 > U.recentlyCreatedOwnerStacks++;
247
+ return j(
248
+ n,
249
+ h,
250
+ p,
251
+ !0,
252
+ a ? Error("react-stack-top-frame") : Y,
253
+ a ? Q(i(n)) : oe
254
+ );
255
+ };
256
+ })()), de;
257
+ }
258
+ var Re;
259
+ function Ke() {
260
+ return Re || (Re = 1, process.env.NODE_ENV === "production" ? xe.exports = qe() : xe.exports = Je()), xe.exports;
261
+ }
262
+ var t = Ke();
263
+ const ne = {
264
+ default: {
265
+ padding: "15px 22px",
266
+ minHeight: "48px",
267
+ fontSize: "15px",
268
+ lineHeight: "18px",
269
+ gap: "10px",
270
+ iconGap: "6px"
271
+ },
272
+ medium: {
273
+ padding: "12px 16px",
274
+ minHeight: "42px",
275
+ fontSize: "15px",
276
+ lineHeight: "18px",
277
+ gap: "10px",
278
+ iconGap: "6px"
279
+ },
280
+ small: {
281
+ padding: "10px",
282
+ minHeight: "36px",
283
+ fontSize: "14px",
284
+ lineHeight: "17px",
285
+ gap: "4px",
286
+ iconGap: "4px"
287
+ }
288
+ }, Qe = (e) => ({ theme: r }) => {
289
+ const o = r.colors, l = {
290
+ primary: {
291
+ default: {
292
+ bg: o.primary.primaryBlue,
293
+ color: o.primary.white,
294
+ border: o.primary.primaryBlue
295
+ },
296
+ hover: {
297
+ bg: o.primary.hoverBlue,
298
+ color: o.primary.white,
299
+ border: o.primary.hoverBlue
300
+ },
301
+ active: {
302
+ bg: o.primary.activeBlue,
303
+ color: o.primary.white,
304
+ border: o.primary.activeBlue
305
+ },
306
+ disabled: {
307
+ bg: o.gray.lightGray2,
308
+ color: o.gray.darkGray,
309
+ border: o.gray.lightGray2
310
+ }
311
+ },
312
+ secondary: {
313
+ default: {
314
+ bg: "transparent",
315
+ color: o.primary.primaryBlue,
316
+ border: o.primary.primaryBlue
317
+ },
318
+ hover: {
319
+ bg: o.primary.primaryBlue,
320
+ color: o.primary.white,
321
+ border: o.primary.primaryBlue
322
+ },
323
+ active: {
324
+ bg: o.primary.activeBlue,
325
+ color: o.primary.white,
326
+ border: o.primary.activeBlue
327
+ },
328
+ disabled: {
329
+ bg: "transparent",
330
+ color: o.gray.darkGray,
331
+ border: o.gray.lightGray2
332
+ }
333
+ },
334
+ tertiary: {
335
+ default: {
336
+ bg: "transparent",
337
+ color: o.primary.primaryBlue,
338
+ border: "transparent"
339
+ },
340
+ hover: {
341
+ bg: o.gray.lightBlueGray,
342
+ color: o.primary.primaryBlue,
343
+ border: "transparent"
344
+ },
345
+ active: {
346
+ bg: o.gray.lightBlueGray2,
347
+ color: o.primary.primaryBlue,
348
+ border: "transparent"
349
+ },
350
+ disabled: {
351
+ bg: "transparent",
352
+ color: o.gray.darkGray,
353
+ border: "transparent"
354
+ }
355
+ }
356
+ }[e];
357
+ return g`
358
+ background-color: ${l.default.bg};
359
+ color: ${l.default.color};
360
+ border-color: ${l.default.border};
361
+
362
+ &:hover:not(:disabled) {
363
+ background-color: ${l.hover.bg};
364
+ color: ${l.hover.color};
365
+ border-color: ${l.hover.border};
366
+ }
367
+
368
+ &:active:not(:disabled) {
369
+ background-color: ${l.active.bg};
370
+ color: ${l.active.color};
371
+ border-color: ${l.active.border};
372
+ }
373
+
374
+ &:disabled {
375
+ background-color: ${l.disabled.bg};
376
+ color: ${l.disabled.color};
377
+ border-color: ${l.disabled.border};
378
+ }
379
+ `;
380
+ }, et = $.button`
381
+ display: inline-flex;
382
+ align-items: center;
383
+ justify-content: center;
384
+ border: 1px solid transparent;
385
+ border-radius: ${({ $form: e }) => e === "brick-right" ? "0 5px 5px 0" : "5px"};
386
+ cursor: pointer;
387
+ transition: background-color 0.15s ease, border-color 0.15s ease,
388
+ color 0.15s ease, opacity 0.15s ease;
389
+ font-weight: 600;
390
+
391
+ ${({ $size: e }) => g`
392
+ padding: ${ne[e].padding};
393
+ min-height: ${ne[e].minHeight};
394
+ font-size: ${ne[e].fontSize};
395
+ line-height: ${ne[e].lineHeight};
396
+ `}
397
+
398
+ ${({ $hasIcon: e, $iconOnly: r, $size: o }) => g`
399
+ gap: ${r ? "0" : e ? ne[o].iconGap : ne[o].gap};
400
+ `}
401
+
402
+ ${({ $fullWidth: e }) => e && g`
403
+ width: 100%;
404
+ `}
405
+
406
+ ${({ $variant: e }) => Qe(e)}
407
+
408
+ &:disabled {
409
+ cursor: not-allowed;
410
+ }
411
+ `, je = $.span`
412
+ display: inline-flex;
413
+ align-items: center;
414
+ justify-content: center;
415
+ line-height: 0;
416
+ ${({ $iconOnly: e }) => e && g`
417
+ width: 18px;
418
+ height: 18px;
419
+ `}
420
+ `, tt = ({
421
+ variant: e = "primary",
422
+ size: r = "default",
423
+ form: o = "default",
424
+ fullWidth: i = !1,
425
+ icon: l,
426
+ iconPosition: c = "left",
427
+ children: d,
428
+ disabled: x,
429
+ ...w
430
+ }) => {
431
+ const b = !!d, j = !!l && (!b || c === "only"), y = !!l && !j && c === "left", S = !!l && !j && c === "right";
432
+ return /* @__PURE__ */ t.jsxs(
433
+ et,
434
+ {
435
+ type: "button",
436
+ $variant: e,
437
+ $size: r,
438
+ $form: o,
439
+ $fullWidth: i,
440
+ $hasIcon: !!l && b,
441
+ $iconOnly: j,
442
+ disabled: x,
443
+ ...w,
444
+ children: [
445
+ y && /* @__PURE__ */ t.jsx(je, { $iconOnly: !1, children: l }),
446
+ (!j || !l) && d,
447
+ j && l && /* @__PURE__ */ t.jsx(je, { $iconOnly: !0, children: l }),
448
+ S && /* @__PURE__ */ t.jsx(je, { $iconOnly: !1, children: l })
449
+ ]
450
+ }
451
+ );
452
+ }, be = s.div`
453
+ position: relative;
454
+ display: inline-flex;
455
+ align-items: center;
456
+ cursor: pointer;
457
+ `, rt = s.button`
458
+ border: none;
459
+ background: transparent;
460
+ padding: 4px 8px;
461
+ font: inherit;
462
+ color: inherit;
463
+ cursor: pointer;
464
+ `, ot = s.span`
465
+ position: absolute;
466
+ bottom: 100%;
467
+ left: 50%;
468
+ transform: translate(-50%, -6px);
469
+ white-space: nowrap;
470
+ background: rgba(0, 0, 0, 0.85);
471
+ color: #fff;
472
+ font-size: 12px;
473
+ padding: 4px 8px;
474
+ border-radius: 4px;
475
+ opacity: 0;
476
+ pointer-events: none;
477
+ transition: opacity 0.15s ease, transform 0.15s ease;
478
+
479
+ ${be}:hover &,
480
+ ${be}:focus-within &,
481
+ ${be}:active & {
482
+ opacity: 1;
483
+ transform: translate(-50%, -10px);
484
+ }
485
+ `, Nr = ({
486
+ label: e,
487
+ children: r,
488
+ copiedText: o = "Скопировано!",
489
+ copyDuration: i = 1500
490
+ }) => {
491
+ const [l, c] = W(!1), d = async () => {
492
+ try {
493
+ await navigator.clipboard.writeText(e), c(!0), setTimeout(() => c(!1), i);
494
+ } catch (x) {
495
+ console.error("Copy failed", x);
496
+ }
497
+ };
498
+ return /* @__PURE__ */ t.jsxs(be, { onClick: d, children: [
499
+ r ?? /* @__PURE__ */ t.jsx(rt, { type: "button", children: e }),
500
+ /* @__PURE__ */ t.jsx(ot, { children: l ? o : e })
501
+ ] });
502
+ }, u = {
503
+ regular: 400,
504
+ semibold: 600,
505
+ bold: 700
506
+ }, nt = {
507
+ h1: {
508
+ mobile: {
509
+ fontSize: "26px",
510
+ lineHeight: "32px",
511
+ fontWeight: u.semibold
512
+ },
513
+ tablet: {
514
+ fontSize: "34px",
515
+ lineHeight: "42px",
516
+ fontWeight: u.semibold
517
+ },
518
+ desktop: {
519
+ fontSize: "44px",
520
+ lineHeight: "54px",
521
+ fontWeight: u.semibold,
522
+ textTransform: "uppercase"
523
+ }
524
+ },
525
+ h2: {
526
+ mobile: {
527
+ fontSize: "22px",
528
+ lineHeight: "28px",
529
+ fontWeight: u.semibold
530
+ },
531
+ tablet: {
532
+ fontSize: "30px",
533
+ lineHeight: "37px",
534
+ fontWeight: u.semibold
535
+ },
536
+ desktop: {
537
+ fontSize: "32px",
538
+ lineHeight: "40px",
539
+ fontWeight: u.semibold
540
+ }
541
+ },
542
+ h3: {
543
+ mobile: {
544
+ fontSize: "20px",
545
+ lineHeight: "24px",
546
+ fontWeight: u.semibold
547
+ },
548
+ tablet: {
549
+ fontSize: "28px",
550
+ lineHeight: "34px",
551
+ fontWeight: u.semibold
552
+ },
553
+ desktop: {
554
+ fontSize: "30px",
555
+ lineHeight: "38px",
556
+ fontWeight: u.semibold
557
+ }
558
+ },
559
+ h4: {
560
+ mobile: {
561
+ fontSize: "18px",
562
+ lineHeight: "22px",
563
+ fontWeight: u.semibold
564
+ },
565
+ tablet: {
566
+ fontSize: "24px",
567
+ lineHeight: "30px",
568
+ fontWeight: u.semibold
569
+ },
570
+ desktop: {
571
+ fontSize: "24px",
572
+ lineHeight: "30px",
573
+ fontWeight: u.semibold
574
+ }
575
+ },
576
+ h5: {
577
+ mobile: {
578
+ fontSize: "16px",
579
+ lineHeight: "20px",
580
+ fontWeight: u.semibold
581
+ },
582
+ tablet: {
583
+ fontSize: "20px",
584
+ lineHeight: "24px",
585
+ fontWeight: u.semibold
586
+ },
587
+ desktop: {
588
+ fontSize: "20px",
589
+ lineHeight: "24px",
590
+ fontWeight: u.semibold
591
+ }
592
+ },
593
+ "body-xl-semibold": {
594
+ mobile: {
595
+ fontSize: "18px",
596
+ lineHeight: "22px",
597
+ fontWeight: u.semibold
598
+ },
599
+ tablet: {
600
+ fontSize: "22px",
601
+ lineHeight: "28px",
602
+ fontWeight: u.semibold
603
+ },
604
+ desktop: {
605
+ fontSize: "24px",
606
+ lineHeight: "30px",
607
+ fontWeight: u.semibold
608
+ }
609
+ },
610
+ "body-xl": {
611
+ mobile: {
612
+ fontSize: "18px",
613
+ lineHeight: "22px",
614
+ fontWeight: u.regular
615
+ },
616
+ tablet: {
617
+ fontSize: "22px",
618
+ lineHeight: "28px",
619
+ fontWeight: u.regular
620
+ },
621
+ desktop: {
622
+ fontSize: "24px",
623
+ lineHeight: "30px",
624
+ fontWeight: u.regular
625
+ }
626
+ },
627
+ "body-l-semibold": {
628
+ mobile: {
629
+ fontSize: "16px",
630
+ lineHeight: "19px",
631
+ fontWeight: u.semibold
632
+ },
633
+ tablet: {
634
+ fontSize: "18px",
635
+ lineHeight: "22px",
636
+ fontWeight: u.semibold
637
+ },
638
+ desktop: {
639
+ fontSize: "18px",
640
+ lineHeight: "22px",
641
+ fontWeight: u.semibold
642
+ }
643
+ },
644
+ "body-l": {
645
+ mobile: {
646
+ fontSize: "16px",
647
+ lineHeight: "19px",
648
+ fontWeight: u.regular
649
+ },
650
+ tablet: {
651
+ fontSize: "18px",
652
+ lineHeight: "22px",
653
+ fontWeight: u.regular
654
+ },
655
+ desktop: {
656
+ fontSize: "18px",
657
+ lineHeight: "22px",
658
+ fontWeight: u.regular
659
+ }
660
+ },
661
+ "body-m-bold": {
662
+ mobile: {
663
+ fontSize: "14px",
664
+ lineHeight: "17px",
665
+ fontWeight: u.bold
666
+ },
667
+ tablet: {
668
+ fontSize: "16px",
669
+ lineHeight: "20px",
670
+ fontWeight: u.bold
671
+ },
672
+ desktop: {
673
+ fontSize: "16px",
674
+ lineHeight: "20px",
675
+ fontWeight: u.bold
676
+ }
677
+ },
678
+ "body-m-semibold": {
679
+ mobile: {
680
+ fontSize: "14px",
681
+ lineHeight: "17px",
682
+ fontWeight: u.semibold
683
+ },
684
+ tablet: {
685
+ fontSize: "16px",
686
+ lineHeight: "20px",
687
+ fontWeight: u.semibold
688
+ },
689
+ desktop: {
690
+ fontSize: "16px",
691
+ lineHeight: "20px",
692
+ fontWeight: u.semibold
693
+ }
694
+ },
695
+ "body-m": {
696
+ mobile: {
697
+ fontSize: "14px",
698
+ lineHeight: "17px",
699
+ fontWeight: u.regular
700
+ },
701
+ tablet: {
702
+ fontSize: "16px",
703
+ lineHeight: "20px",
704
+ fontWeight: u.regular
705
+ },
706
+ desktop: {
707
+ fontSize: "16px",
708
+ lineHeight: "20px",
709
+ fontWeight: u.regular
710
+ }
711
+ },
712
+ "body-s-semibold": {
713
+ mobile: {
714
+ fontSize: "12px",
715
+ lineHeight: "15px",
716
+ fontWeight: u.semibold
717
+ },
718
+ tablet: {
719
+ fontSize: "14px",
720
+ lineHeight: "17px",
721
+ fontWeight: u.semibold
722
+ },
723
+ desktop: {
724
+ fontSize: "14px",
725
+ lineHeight: "17px",
726
+ fontWeight: u.semibold
727
+ }
728
+ },
729
+ "body-s": {
730
+ mobile: {
731
+ fontSize: "12px",
732
+ lineHeight: "15px",
733
+ fontWeight: u.regular
734
+ },
735
+ tablet: {
736
+ fontSize: "14px",
737
+ lineHeight: "17px",
738
+ fontWeight: u.regular
739
+ },
740
+ desktop: {
741
+ fontSize: "14px",
742
+ lineHeight: "17px",
743
+ fontWeight: u.regular
744
+ }
745
+ },
746
+ button: {
747
+ desktop: {
748
+ fontSize: "15px",
749
+ lineHeight: "18px",
750
+ fontWeight: u.semibold
751
+ }
752
+ },
753
+ "form-input": {
754
+ desktop: {
755
+ fontSize: "15px",
756
+ lineHeight: "18px",
757
+ fontWeight: u.regular
758
+ }
759
+ },
760
+ "avatar-basic": {
761
+ desktop: {
762
+ fontSize: "16px",
763
+ lineHeight: "18px",
764
+ fontWeight: u.semibold
765
+ }
766
+ },
767
+ "avatar-m": {
768
+ desktop: {
769
+ fontSize: "14px",
770
+ lineHeight: "16px",
771
+ fontWeight: u.semibold
772
+ }
773
+ },
774
+ "avatar-s": {
775
+ desktop: {
776
+ fontSize: "12px",
777
+ lineHeight: "14px",
778
+ fontWeight: u.semibold
779
+ }
780
+ }
781
+ }, it = (e) => {
782
+ const { mobile: r, tablet: o, desktop: i } = nt[e];
783
+ return g`
784
+ ${({ theme: l }) => g`
785
+ ${g`
786
+ font-size: ${i.fontSize};
787
+ font-weight: ${i.fontWeight};
788
+ line-height: ${i.lineHeight};
789
+ `}
790
+
791
+ ${o && g`
792
+ ${l.media.maxWidth.tablet} {
793
+ font-size: ${o.fontSize};
794
+ font-weight: ${o.fontWeight};
795
+ line-height: ${o.lineHeight};
796
+ }
797
+ `}
798
+
799
+ ${r && g`
800
+ ${l.media.maxWidth.mobile} {
801
+ font-size: ${r.fontSize};
802
+ font-weight: ${r.fontWeight};
803
+ line-height: ${r.lineHeight};
804
+ }
805
+ `}
806
+ `}
807
+ `;
808
+ }, at = s.span`
809
+ margin: 0;
810
+ color: ${({ $color: e }) => e ?? "inherit"};
811
+ ${({ $variant: e }) => it(e)};
812
+ text-align: ${({ $align: e }) => e ?? "inherit"};
813
+ ${({ $inline: e }) => e ? g`
814
+ display: inline;
815
+ ` : g`
816
+ display: block;
817
+ `};
818
+ ${({ $uppercase: e }) => e && g`
819
+ text-transform: uppercase;
820
+ letter-spacing: 0.04em;
821
+ `}
822
+ ${({ $truncate: e }) => e && g`
823
+ overflow: hidden;
824
+ text-overflow: ellipsis;
825
+ white-space: nowrap;
826
+ `}
827
+ `, v = ({
828
+ as: e = "span",
829
+ forwardedAs: r,
830
+ variant: o = "body-m-semibold",
831
+ color: i,
832
+ align: l,
833
+ uppercase: c = !1,
834
+ truncate: d = !1,
835
+ inline: x = !1,
836
+ children: w,
837
+ ...b
838
+ }) => /* @__PURE__ */ t.jsx(
839
+ at,
840
+ {
841
+ as: e,
842
+ forwardedAs: r,
843
+ $variant: o,
844
+ $color: i,
845
+ $align: l,
846
+ $uppercase: c,
847
+ $truncate: d,
848
+ $inline: x,
849
+ ...b,
850
+ children: w
851
+ }
852
+ ), X = ({ size: e = 24, children: r, ...o }) => /* @__PURE__ */ t.jsx(
853
+ "svg",
854
+ {
855
+ width: e,
856
+ height: e,
857
+ viewBox: "0 0 24 24",
858
+ fill: "none",
859
+ xmlns: "http://www.w3.org/2000/svg",
860
+ ...o,
861
+ children: r
862
+ }
863
+ ), lt = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, children: [
864
+ /* @__PURE__ */ t.jsx("circle", { cx: "12", cy: "12", r: "9", stroke: "#5E6F8D", "stroke-width": "2" }),
865
+ /* @__PURE__ */ t.jsx("path", { d: "M7 12L10.3333 15L17 9", stroke: "#5E6F8D", "stroke-width": "2" })
866
+ ] }), st = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, children: [
867
+ /* @__PURE__ */ t.jsxs("g", { "clip-path": "url(#clip0_487_8651)", children: [
868
+ /* @__PURE__ */ t.jsx(
869
+ "path",
870
+ {
871
+ d: "M4.99543 4.85076C5.38596 4.46024 6.01912 4.46024 6.40965 4.85076L19.265 17.7061C19.6555 18.0966 19.6555 18.7298 19.265 19.1203L19.0937 19.2916C18.7032 19.6821 18.07 19.6821 17.6795 19.2916L4.82414 6.43627C4.43362 6.04574 4.43362 5.41258 4.82414 5.02206L4.99543 4.85076Z",
872
+ fill: "#9296A5"
873
+ }
874
+ ),
875
+ /* @__PURE__ */ t.jsx(
876
+ "path",
877
+ {
878
+ d: "M4.85129 19.1203C4.46077 18.7298 4.46077 18.0966 4.85129 17.7061L17.7066 4.85075C18.0971 4.46023 18.7303 4.46023 19.1208 4.85075L19.2921 5.02205C19.6827 5.41257 19.6827 6.04574 19.2921 6.43626L6.4368 19.2916C6.04627 19.6821 5.41311 19.6821 5.02258 19.2916L4.85129 19.1203Z",
879
+ fill: "#9296A5"
880
+ }
881
+ )
882
+ ] }),
883
+ /* @__PURE__ */ t.jsx("defs", { children: /* @__PURE__ */ t.jsx("clipPath", { id: "clip0_487_8651", children: /* @__PURE__ */ t.jsx("rect", { width: "24", height: "24", fill: "white" }) }) })
884
+ ] }), ct = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, children: [
885
+ /* @__PURE__ */ t.jsx("rect", { x: "3", y: "5", width: "18", height: "2", rx: "1", fill: "#9296A5" }),
886
+ /* @__PURE__ */ t.jsx("rect", { x: "3", y: "11", width: "18", height: "2", rx: "1", fill: "#9296A5" }),
887
+ /* @__PURE__ */ t.jsx("rect", { x: "3", y: "17", width: "18", height: "2", rx: "1", fill: "#9296A5" })
888
+ ] }), dt = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, children: [
889
+ /* @__PURE__ */ t.jsx(
890
+ "path",
891
+ {
892
+ "fill-rule": "evenodd",
893
+ "clip-rule": "evenodd",
894
+ d: "M12 13C14.2091 13 16 11.2091 16 9C16 6.79086 14.2091 5 12 5C9.79086 5 8 6.79086 8 9C8 11.2091 9.79086 13 12 13ZM12 15C15.3137 15 18 12.3137 18 9C18 5.68629 15.3137 3 12 3C8.68629 3 6 5.68629 6 9C6 12.3137 8.68629 15 12 15Z",
895
+ fill: "#202D52"
896
+ }
897
+ ),
898
+ /* @__PURE__ */ t.jsx(
899
+ "path",
900
+ {
901
+ "fill-rule": "evenodd",
902
+ "clip-rule": "evenodd",
903
+ d: "M12 15C8.13401 15 5 18.134 5 22H3C3 17.0294 7.02944 13 12 13C16.9706 13 21 17.0294 21 22H19C19 18.134 15.866 15 12 15Z",
904
+ fill: "#202D52"
905
+ }
906
+ )
907
+ ] }), Me = (e) => /* @__PURE__ */ t.jsx(X, { ...e, viewBox: "0 0 18 18", children: /* @__PURE__ */ t.jsx(
908
+ "path",
909
+ {
910
+ d: "M9 16.5C4.85786 16.5 1.5 13.1421 1.5 9C1.5 4.85786 4.85786 1.5 9 1.5C13.1421 1.5 16.5 4.85786 16.5 9C16.4954 13.1402 13.1402 16.4954 9 16.5ZM9 3C5.68629 3 3 5.68629 3 9C3 12.3137 5.68629 15 9 15C12.3137 15 15 12.3137 15 9C14.9963 5.68783 12.3122 3.00372 9 3ZM12.75 9.75H8.25V5.25H9.75V8.25H12.75V9.75Z",
911
+ fill: "#9296A5"
912
+ }
913
+ ) }), pt = (e) => /* @__PURE__ */ t.jsx(X, { ...e, viewBox: "0 0 18 18", children: /* @__PURE__ */ t.jsx(
914
+ "path",
915
+ {
916
+ d: "M10.4999 16.5H2.9999C2.59796 16.514 2.20826 16.3604 1.92387 16.076C1.63948 15.7916 1.48593 15.4019 1.4999 15V7.50001C1.48593 7.09807 1.63948 6.70837 1.92387 6.42399C2.20826 6.1396 2.59796 5.98605 2.9999 6.00002H5.9999V3.00002C5.98593 2.59807 6.13948 2.20837 6.42387 1.92399C6.70826 1.6396 7.09796 1.48605 7.49991 1.50002H14.9999C15.4018 1.48605 15.7915 1.6396 16.0759 1.92399C16.3603 2.20837 16.5139 2.59807 16.4999 3.00002V10.5C16.5136 10.9019 16.36 11.2915 16.0757 11.5758C15.7914 11.8601 15.4018 12.0137 14.9999 12H11.9999V15C12.0136 15.4019 11.86 15.7915 11.5757 16.0758C11.2914 16.3601 10.9018 16.5137 10.4999 16.5ZM2.9999 7.50001V15H10.4999V12H7.49991C7.09802 12.0137 6.70845 11.8601 6.42411 11.5758C6.13977 11.2915 5.98616 10.9019 5.9999 10.5V7.50001H2.9999ZM7.49991 3.00002V10.5H14.9999V3.00002H7.49991Z",
917
+ fill: "#5E6F8D"
918
+ }
919
+ ) }), Pe = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, viewBox: "0 0 18 18", children: [
920
+ /* @__PURE__ */ t.jsx("g", { "clip-path": "url(#clip0_309_1899)", children: /* @__PURE__ */ t.jsx(
921
+ "path",
922
+ {
923
+ d: "M9 16.5C4.85786 16.5 1.5 13.1421 1.5 9C1.5 4.85786 4.85786 1.5 9 1.5C13.1421 1.5 16.5 4.85786 16.5 9C16.4955 13.1403 13.1403 16.4955 9 16.5ZM3 9.129C3.03549 12.4299 5.73083 15.0822 9.0319 15.0645C12.333 15.0467 14.9997 12.3656 14.9997 9.0645C14.9997 5.76338 12.333 3.08233 9.0319 3.0645C5.73083 3.04684 3.03549 5.69907 3 9V9.129ZM10.5 12.75H8.25V9.75H7.5V8.25H9.75V11.25H10.5V12.75ZM9.75 6.75H8.25V5.25H9.75V6.75Z",
924
+ fill: e.color || "#9296A5"
925
+ }
926
+ ) }),
927
+ /* @__PURE__ */ t.jsx("defs", { children: /* @__PURE__ */ t.jsx("clipPath", { id: "clip0_309_1899", children: /* @__PURE__ */ t.jsx("rect", { width: "18", height: "18", fill: "white" }) }) })
928
+ ] }), De = (e) => /* @__PURE__ */ t.jsx(X, { ...e, viewBox: "0 0 18 18", children: /* @__PURE__ */ t.jsx(
929
+ "path",
930
+ {
931
+ d: "M9 16.5C4.85975 16.4954 1.50454 13.1402 1.5 9.00001V8.85001C1.58245 4.72841 4.97594 1.44598 9.09803 1.50067C13.2201 1.55537 16.5253 4.92668 16.4984 9.04899C16.4714 13.1714 13.1224 16.4992 9 16.5ZM5.5575 8.69251L4.5 9.75001L7.5 12.75L13.5 6.75001L12.4425 5.68501L7.5 10.6275L5.5575 8.69251Z",
932
+ fill: "#1CD850"
933
+ }
934
+ ) }), ut = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, viewBox: "0 0 18 18", children: [
935
+ /* @__PURE__ */ t.jsx(
936
+ "path",
937
+ {
938
+ d: "M15.9495 15.7485H2.04978C1.78184 15.7485 1.53426 15.6056 1.40028 15.3735C1.26631 15.1415 1.26631 14.8556 1.40028 14.6235L8.3498 2.62349C8.4839 2.39183 8.73125 2.24918 8.99892 2.24918C9.2666 2.24918 9.51395 2.39183 9.64805 2.62349L16.5975 14.6235C16.7314 14.8554 16.7315 15.1412 16.5977 15.3731C16.464 15.6052 16.2166 15.7482 15.9488 15.7485H15.9495ZM9.00005 4.49849L3.35178 14.2485H14.6498L9.00005 4.49849ZM9.7463 11.2493H8.2463V7.49849H9.7463V11.2493Z",
939
+ fill: "#FFA63E"
940
+ }
941
+ ),
942
+ /* @__PURE__ */ t.jsx("path", { d: "M8.25 12H9.75V13.5H8.25V12Z", fill: "#FFA63E" })
943
+ ] }), ht = (e) => /* @__PURE__ */ t.jsxs(X, { ...e, viewBox: "0 0 18 18", children: [
944
+ /* @__PURE__ */ t.jsx("circle", { cx: "9", cy: "9", r: "9", fill: "#EFF2FB" }),
945
+ /* @__PURE__ */ t.jsx(
946
+ "path",
947
+ {
948
+ d: "M13 9L9 12L5 9",
949
+ stroke: "#5E6F8D",
950
+ "stroke-linecap": "round",
951
+ "stroke-linejoin": "round"
952
+ }
953
+ ),
954
+ /* @__PURE__ */ t.jsx(
955
+ "path",
956
+ {
957
+ d: "M13 6L9 9L5 6",
958
+ stroke: "#5E6F8D",
959
+ "stroke-linecap": "round",
960
+ "stroke-linejoin": "round"
961
+ }
962
+ )
963
+ ] }), xt = s.div`
964
+ display: grid;
965
+ align-items: center;
966
+ grid-template-columns: ${({ $icon: e }) => e ? "auto 1fr" : "1fr"};
967
+ gap: 12px;
968
+ width: 458px;
969
+ height: auto;
970
+ border-radius: 12px;
971
+ padding: 24px;
972
+ background-color: ${({ $type: e, theme: r }) => {
973
+ switch (e) {
974
+ case "success":
975
+ return r.colors.accent.green2Light;
976
+ case "error":
977
+ return r.colors.accent.red;
978
+ case "info":
979
+ return r.colors.primary.lightBlue2;
980
+ case "warning":
981
+ return r.colors.accent.orange;
982
+ }
983
+ }};
984
+ `, Vr = ({
985
+ label: e,
986
+ description: r,
987
+ type: o,
988
+ icon: i
989
+ }) => /* @__PURE__ */ t.jsxs(xt, { $icon: i, $type: o, children: [
990
+ i && /* @__PURE__ */ t.jsx(Pe, { size: 18, color: "#fff" }),
991
+ e && /* @__PURE__ */ t.jsx(v, { color: "#fff", variant: "body-l-semibold", children: e }),
992
+ i && /* @__PURE__ */ t.jsx("div", {}),
993
+ r && /* @__PURE__ */ t.jsx(v, { color: "#fff", variant: "body-m-semibold", children: r })
994
+ ] }), ft = s.div`
995
+ display: flex;
996
+ flex-direction: column;
997
+ gap: 4px;
998
+ width: 100%;
999
+ `, gt = s(v).attrs({
1000
+ variant: "form-input",
1001
+ forwardedAs: "label"
1002
+ })`
1003
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1004
+ `, mt = s.div`
1005
+ display: flex;
1006
+ align-items: center;
1007
+ gap: 8px;
1008
+ overflow: hidden;
1009
+ height: 48px;
1010
+ padding-left: 12px;
1011
+ border-radius: 5px;
1012
+ outline: 1px solid ${({ theme: e }) => e.colors.gray.lightGray2};
1013
+ outline-offset: -1px;
1014
+ background: ${({ theme: e }) => e.colors.primary.white};
1015
+ width: 100%;
1016
+ box-sizing: border-box;
1017
+ transition: border-color 140ms ease;
1018
+
1019
+ ${({ $disabled: e }) => e && g`
1020
+ opacity: 0.6;
1021
+ cursor: not-allowed;
1022
+ `}
1023
+
1024
+ ${({ $hasError: e, theme: r }) => e && g`
1025
+ outline-color: ${r.colors.accent.red};
1026
+ `}
1027
+
1028
+ &:hover {
1029
+ outline-color: ${({ theme: e, $hasError: r }) => r ? e.colors.accent.red : e.colors.primary.lightBlue2};
1030
+ }
1031
+
1032
+ &[data-state="active"] {
1033
+ outline-color: ${({ theme: e, $hasError: r }) => r ? e.colors.accent.red : e.colors.primary.primaryBlue};
1034
+ }
1035
+ `, bt = s.span`
1036
+ display: inline-flex;
1037
+ width: 24px;
1038
+ height: 24px;
1039
+ `, yt = s.span`
1040
+ display: inline-flex;
1041
+ align-items: center;
1042
+ justify-content: center;
1043
+ min-width: 48px;
1044
+ & > button {
1045
+ border-radius: 0px;
1046
+ }
1047
+ `, wt = s.input`
1048
+ flex: 1;
1049
+ border: none;
1050
+ outline: none;
1051
+ background: transparent;
1052
+ font-family: "Proxima Nova", sans-serif;
1053
+ padding-right: 12px;
1054
+ height: 100%;
1055
+ font-size: 15px;
1056
+ line-height: 18px;
1057
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1058
+
1059
+ &::placeholder {
1060
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
1061
+ }
1062
+ `, vt = s.span`
1063
+ font-family: "Proxima Nova", sans-serif;
1064
+ font-size: 15px;
1065
+ line-height: 18px;
1066
+ color: ${({ theme: e }) => e.colors.accent.red};
1067
+ `, $t = Ie(
1068
+ ({
1069
+ value: e,
1070
+ defaultValue: r,
1071
+ placeholder: o = "Text",
1072
+ label: i,
1073
+ error: l,
1074
+ disabled: c = !1,
1075
+ icon: d,
1076
+ action: x,
1077
+ name: w,
1078
+ type: b = "text",
1079
+ onChange: j,
1080
+ onFocus: y,
1081
+ onBlur: S,
1082
+ className: T
1083
+ }, k) => {
1084
+ const [B, _] = W(!1), C = !!l, O = (I) => {
1085
+ _(!0), y?.(I);
1086
+ }, G = (I) => {
1087
+ _(!1), S?.(I);
1088
+ };
1089
+ return /* @__PURE__ */ t.jsxs(ft, { className: T, children: [
1090
+ i && /* @__PURE__ */ t.jsx(gt, { children: i }),
1091
+ /* @__PURE__ */ t.jsxs(
1092
+ mt,
1093
+ {
1094
+ $hasError: C,
1095
+ $disabled: c,
1096
+ "data-state": C ? "error" : B ? "active" : void 0,
1097
+ children: [
1098
+ d && /* @__PURE__ */ t.jsx(bt, { children: d }),
1099
+ /* @__PURE__ */ t.jsx(
1100
+ wt,
1101
+ {
1102
+ ref: k,
1103
+ type: b,
1104
+ name: w,
1105
+ value: e,
1106
+ defaultValue: r,
1107
+ placeholder: o,
1108
+ disabled: c,
1109
+ onChange: j,
1110
+ onFocus: O,
1111
+ onBlur: G
1112
+ }
1113
+ ),
1114
+ x && /* @__PURE__ */ t.jsx(yt, { children: x })
1115
+ ]
1116
+ }
1117
+ ),
1118
+ l && /* @__PURE__ */ t.jsx(vt, { children: l })
1119
+ ] });
1120
+ }
1121
+ );
1122
+ $t.displayName = "TextField";
1123
+ const kt = s.div`
1124
+ display: flex;
1125
+ flex-direction: column;
1126
+ width: 100%;
1127
+ padding: 24px 28px;
1128
+ background-color: ${({ theme: e }) => e.colors.primary.white};
1129
+ border-radius: 10px;
1130
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
1131
+ padding: 24px 20px;
1132
+ }
1133
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
1134
+ padding: 16px;
1135
+ }
1136
+ `, Yr = kt, jt = s(v).attrs({
1137
+ forwardedAs: "div"
1138
+ })`
1139
+ display: flex;
1140
+ align-items: center;
1141
+ justify-content: center;
1142
+ padding: 0px;
1143
+ width: 22px;
1144
+ height: 22px;
1145
+ border-radius: 50%;
1146
+ color: #fff;
1147
+ background-color: ${({ theme: e }) => e.colors.primary.primaryBlue};
1148
+ `, Zr = ({ count: e = 0 }) => /* @__PURE__ */ t.jsx(jt, { variant: "body-s-semibold", children: e }), Xr = ({
1149
+ open: e,
1150
+ onToggle: r
1151
+ }) => {
1152
+ const [o, i] = W(!1), l = e !== void 0, c = l ? e : o, d = L(() => {
1153
+ const x = !c;
1154
+ l || i(x), r?.(x);
1155
+ }, [l, c, r]);
1156
+ return /* @__PURE__ */ t.jsx(
1157
+ tt,
1158
+ {
1159
+ iconPosition: "only",
1160
+ variant: "tertiary",
1161
+ icon: c ? /* @__PURE__ */ t.jsx(st, {}) : /* @__PURE__ */ t.jsx(ct, {}),
1162
+ size: "small",
1163
+ onClick: d
1164
+ }
1165
+ );
1166
+ }, Ct = Ue`
1167
+ 0% {
1168
+ transform: scale(0.5);
1169
+ }
1170
+ 25% {
1171
+ transform: scale(1);
1172
+ }
1173
+ 75% {
1174
+ transform: scale(0.5);
1175
+ }
1176
+ 100% {
1177
+ transform: scale(0.5);
1178
+ }
1179
+ `, St = s.div`
1180
+ display: flex;
1181
+ `, Ce = s.div`
1182
+ margin: 2px;
1183
+ width: 6px;
1184
+ height: 6px;
1185
+ border-radius: 50%;
1186
+ background-color: ${({ theme: e }) => e.colors.primary.primaryBlue};
1187
+ transform: scale(0.5);
1188
+ animation: ${Ct} 1.2s ease-out infinite;
1189
+
1190
+ &:nth-of-type(2) {
1191
+ animation-delay: 0.2s;
1192
+ }
1193
+ &:nth-of-type(3) {
1194
+ animation-delay: 0.3s;
1195
+ }
1196
+ &:nth-of-type(4) {
1197
+ animation-delay: 0.4s;
1198
+ }
1199
+ &:nth-of-type(5) {
1200
+ animation-delay: 0.5s;
1201
+ }
1202
+ `, Ur = () => /* @__PURE__ */ t.jsxs(St, { children: [
1203
+ /* @__PURE__ */ t.jsx(Ce, {}),
1204
+ /* @__PURE__ */ t.jsx(Ce, {}),
1205
+ /* @__PURE__ */ t.jsx(Ce, {})
1206
+ ] }), Et = s.label`
1207
+ display: inline-flex;
1208
+ align-items: center;
1209
+ gap: 8px;
1210
+ cursor: ${({ disabled: e }) => e ? "not-allowed" : "pointer"};
1211
+ `, Tt = s.input`
1212
+ position: absolute;
1213
+ opacity: 0;
1214
+ pointer-events: none;
1215
+ `, Rt = s.span`
1216
+ width: 16px;
1217
+ height: 16px;
1218
+ border-radius: 50%;
1219
+ border: 2px solid ${({ theme: e }) => e.colors.gray.darkGray2};
1220
+ background-color: transparent;
1221
+ transition: border-color 160ms ease, background-color 160ms ease;
1222
+ position: relative;
1223
+ display: inline-flex;
1224
+ justify-content: center;
1225
+ align-items: center;
1226
+
1227
+ ${({ $checked: e, theme: r }) => e && g`
1228
+ border-color: ${r.colors.primary.primaryBlue};
1229
+ &::after {
1230
+ content: "";
1231
+ width: 8px;
1232
+ height: 8px;
1233
+ border-radius: 50%;
1234
+ background-color: ${r.colors.primary.primaryBlue};
1235
+ transition: background-color 160ms ease;
1236
+ }
1237
+ `}
1238
+
1239
+ ${({ $checked: e, theme: r }) => !e && g`
1240
+ &:hover {
1241
+ border-color: ${r.colors.primary.hoverBlue};
1242
+ }
1243
+ `}
1244
+
1245
+ ${({ $checked: e, $disabled: r, theme: o }) => !r && e && g`
1246
+ &:hover {
1247
+ border-color: ${o.colors.primary.hoverBlue};
1248
+ &::after {
1249
+ background-color: ${o.colors.primary.hoverBlue};
1250
+ }
1251
+ }
1252
+ `}
1253
+
1254
+ ${({ $disabled: e, theme: r }) => e && g`
1255
+ border-color: ${r.colors.icon.iconSecondary};
1256
+ background-color: ${r.colors.gray.lightGray2};
1257
+ &::after {
1258
+ content: "";
1259
+ width: 8px;
1260
+ height: 8px;
1261
+ border-radius: 50%;
1262
+ background-color: ${r.colors.icon.iconSecondary};
1263
+ }
1264
+ `}
1265
+ `, Bt = s(v)`
1266
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1267
+ `, qr = ({
1268
+ checked: e,
1269
+ defaultChecked: r = !1,
1270
+ disabled: o = !1,
1271
+ name: i,
1272
+ value: l,
1273
+ label: c,
1274
+ onChange: d,
1275
+ className: x
1276
+ }) => {
1277
+ const w = we(), [b, j] = W(r), y = e !== void 0, S = y ? e : b, T = L(
1278
+ (k) => {
1279
+ o || (y || j(k.target.checked), d?.(k.target.checked));
1280
+ },
1281
+ [o, y, d]
1282
+ );
1283
+ return /* @__PURE__ */ t.jsxs(
1284
+ Et,
1285
+ {
1286
+ className: x,
1287
+ htmlFor: w,
1288
+ disabled: o,
1289
+ children: [
1290
+ /* @__PURE__ */ t.jsx(
1291
+ Tt,
1292
+ {
1293
+ id: w,
1294
+ type: "radio",
1295
+ checked: S,
1296
+ onChange: T,
1297
+ disabled: o,
1298
+ name: i,
1299
+ value: l
1300
+ }
1301
+ ),
1302
+ /* @__PURE__ */ t.jsx(Rt, { $checked: S, $disabled: o }),
1303
+ c && /* @__PURE__ */ t.jsx(Bt, { variant: "button", children: c })
1304
+ ]
1305
+ }
1306
+ );
1307
+ }, Ht = s.div`
1308
+ position: relative;
1309
+ display: flex;
1310
+ flex-direction: column;
1311
+ gap: 12px;
1312
+ width: 100%;
1313
+ `, At = s(v).attrs({
1314
+ variant: "form-input",
1315
+ forwardedAs: "label"
1316
+ })`
1317
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1318
+ `, Lt = s.div`
1319
+ display: flex;
1320
+ align-items: center;
1321
+ gap: 8px;
1322
+ overflow: hidden;
1323
+ height: 48px;
1324
+ padding: 0 12px;
1325
+ border-radius: 5px;
1326
+ outline: 1px solid ${({ theme: e }) => e.colors.gray.lightGray2};
1327
+ outline-offset: -1px;
1328
+ background: ${({ theme: e }) => e.colors.primary.white};
1329
+ width: 100%;
1330
+ box-sizing: border-box;
1331
+ transition: outline-color 140ms ease;
1332
+ cursor: pointer;
1333
+
1334
+ ${({ $disabled: e }) => e && g`
1335
+ opacity: 0.6;
1336
+ cursor: not-allowed;
1337
+ `}
1338
+
1339
+ ${({ $hasError: e, theme: r }) => e && g`
1340
+ outline-color: ${r.colors.accent.red};
1341
+ `}
1342
+
1343
+ &:hover {
1344
+ outline-color: ${({ theme: e, $hasError: r }) => r ? e.colors.accent.red : e.colors.primary.lightBlue2};
1345
+ }
1346
+
1347
+ &[data-state="active"] {
1348
+ outline-color: ${({ theme: e, $hasError: r }) => r ? e.colors.accent.red : e.colors.primary.primaryBlue};
1349
+ }
1350
+ `, zt = s.span`
1351
+ display: inline-flex;
1352
+ width: 24px;
1353
+ height: 24px;
1354
+ color: ${({ theme: e }) => e.colors.primary.primaryBlue};
1355
+ `, Wt = s.span`
1356
+ flex: 1;
1357
+ font-family: "Proxima Nova", sans-serif;
1358
+ font-size: 15px;
1359
+ line-height: 18px;
1360
+ color: ${({ theme: e, $placeholder: r }) => r ? e.colors.gray.darkGray : e.colors.primary.darkBlue};
1361
+ user-select: none;
1362
+ `, _t = s.input`
1363
+ position: absolute;
1364
+ opacity: 0;
1365
+ pointer-events: none;
1366
+ `, It = s.span`
1367
+ font-family: "Proxima Nova", sans-serif;
1368
+ font-size: 13px;
1369
+ line-height: 16px;
1370
+ color: ${({ theme: e }) => e.colors.accent.red};
1371
+ `, Ot = s.div`
1372
+ position: fixed;
1373
+ top: ${({ $top: e }) => `${e}px`};
1374
+ left: ${({ $left: e }) => `${e}px`};
1375
+ width: ${({ $width: e }) => `${e}px`};
1376
+ z-index: 999;
1377
+ border-radius: 5px;
1378
+ border: 1px solid ${({ theme: e }) => e.colors.gray.lightGray2};
1379
+ background: ${({ theme: e }) => e.colors.primary.white};
1380
+ box-shadow: 0px 8px 24px rgba(15, 23, 42, 0.12);
1381
+ display: flex;
1382
+ flex-direction: column;
1383
+ max-height: 260px;
1384
+ overflow-y: auto;
1385
+ `, Mt = s.button`
1386
+ display: flex;
1387
+ align-items: center;
1388
+ gap: 10px;
1389
+ padding: 0 13px;
1390
+ height: 40px;
1391
+ border: none;
1392
+ background: transparent;
1393
+ width: 100%;
1394
+ text-align: left;
1395
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1396
+ cursor: pointer;
1397
+ transition: background 140ms ease;
1398
+
1399
+ &[data-hovered="true"],
1400
+ &:hover {
1401
+ background: ${({ theme: e }) => e.colors.gray.lightBlueGray};
1402
+ }
1403
+
1404
+ &[data-active="true"] {
1405
+ background: ${({ theme: e }) => e.colors.gray.lightGray};
1406
+ }
1407
+ `, Pt = s.span`
1408
+ display: inline-flex;
1409
+ width: 24px;
1410
+ height: 24px;
1411
+ `, Dt = 8, Gt = Ie(
1412
+ ({
1413
+ options: e,
1414
+ value: r,
1415
+ defaultValue: o,
1416
+ placeholder: i = "Text",
1417
+ label: l,
1418
+ error: c,
1419
+ disabled: d = !1,
1420
+ icon: x,
1421
+ name: w,
1422
+ onChange: b,
1423
+ onFocus: j,
1424
+ onBlur: y,
1425
+ className: S
1426
+ }, T) => {
1427
+ const k = Z(null), B = Z(null), _ = Z(null), [C, O] = W(!1), [G, I] = W(!1), [P, re] = W(o ?? ""), [F, H] = W(null), [N, q] = W({
1428
+ top: 0,
1429
+ left: 0,
1430
+ width: 0
1431
+ }), R = r ?? P, U = ve(
1432
+ () => e.find((a) => a.value === R),
1433
+ [e, R]
1434
+ ), V = !!c, ie = !U, Q = U?.label ?? i, J = L(() => {
1435
+ if (!B.current) return;
1436
+ const a = B.current.getBoundingClientRect();
1437
+ q({
1438
+ top: a.bottom + Dt,
1439
+ left: a.left,
1440
+ width: a.width
1441
+ });
1442
+ }, []);
1443
+ Oe(() => {
1444
+ if (!C) return;
1445
+ J();
1446
+ const a = () => J();
1447
+ return window.addEventListener("resize", a), window.addEventListener("scroll", a, !0), () => {
1448
+ window.removeEventListener("resize", a), window.removeEventListener("scroll", a, !0);
1449
+ };
1450
+ }, [C, J]);
1451
+ const D = L(() => {
1452
+ O(!1), H(null);
1453
+ }, []), Y = L(() => {
1454
+ d || (O(!0), H((a) => {
1455
+ if (a !== null) return a;
1456
+ const f = e.findIndex(
1457
+ (E) => E.value === R
1458
+ );
1459
+ return f >= 0 ? f : 0;
1460
+ }));
1461
+ }, [d, e, R]), oe = L(() => {
1462
+ C ? D() : Y();
1463
+ }, [C, D, Y]), ee = (a) => {
1464
+ d || (re(a.value), b?.(a.value), D());
1465
+ }, n = (a) => {
1466
+ if (!d)
1467
+ switch (a.key) {
1468
+ case "ArrowDown":
1469
+ a.preventDefault(), Y(), H(
1470
+ (f) => f === null ? 0 : Math.min(f + 1, e.length - 1)
1471
+ );
1472
+ break;
1473
+ case "ArrowUp":
1474
+ a.preventDefault(), Y(), H(
1475
+ (f) => f === null ? e.length - 1 : Math.max(f - 1, 0)
1476
+ );
1477
+ break;
1478
+ case "Enter":
1479
+ case " ":
1480
+ a.preventDefault(), C ? F !== null && e[F] && ee(e[F]) : Y();
1481
+ break;
1482
+ case "Escape":
1483
+ case "Tab":
1484
+ D();
1485
+ break;
1486
+ }
1487
+ };
1488
+ ye(() => {
1489
+ if (!C) return;
1490
+ const a = (f) => {
1491
+ const E = f.target, m = k.current && k.current.contains(E), z = _.current && _.current.contains(E);
1492
+ !m && !z && D();
1493
+ };
1494
+ return document.addEventListener("mousedown", a), () => {
1495
+ document.removeEventListener("mousedown", a);
1496
+ };
1497
+ }, [C, D]);
1498
+ const h = (a) => {
1499
+ I(!0), j?.(a);
1500
+ }, p = (a) => {
1501
+ I(!1), y?.(a);
1502
+ };
1503
+ return /* @__PURE__ */ t.jsxs(
1504
+ Ht,
1505
+ {
1506
+ className: S,
1507
+ ref: k,
1508
+ onKeyDown: n,
1509
+ onFocus: h,
1510
+ onBlur: p,
1511
+ children: [
1512
+ l && /* @__PURE__ */ t.jsx(At, { children: l }),
1513
+ /* @__PURE__ */ t.jsxs(
1514
+ Lt,
1515
+ {
1516
+ ref: B,
1517
+ role: "button",
1518
+ tabIndex: d ? -1 : 0,
1519
+ "aria-haspopup": "listbox",
1520
+ "aria-expanded": C,
1521
+ "aria-invalid": V,
1522
+ "aria-disabled": d,
1523
+ $hasError: V,
1524
+ $disabled: d,
1525
+ "data-state": V ? "error" : C || G ? "active" : void 0,
1526
+ onClick: oe,
1527
+ children: [
1528
+ x && /* @__PURE__ */ t.jsx(zt, { children: x }),
1529
+ /* @__PURE__ */ t.jsx(Wt, { $placeholder: ie, children: Q }),
1530
+ /* @__PURE__ */ t.jsx(
1531
+ _t,
1532
+ {
1533
+ ref: T,
1534
+ readOnly: !0,
1535
+ name: w,
1536
+ value: R,
1537
+ tabIndex: -1,
1538
+ "aria-hidden": !0
1539
+ }
1540
+ )
1541
+ ]
1542
+ }
1543
+ ),
1544
+ c && /* @__PURE__ */ t.jsx(It, { children: c }),
1545
+ C && /* @__PURE__ */ t.jsx(
1546
+ Ot,
1547
+ {
1548
+ ref: _,
1549
+ role: "listbox",
1550
+ $top: N.top,
1551
+ $left: N.left,
1552
+ $width: N.width,
1553
+ children: e.map((a, f) => {
1554
+ const E = a.value === R, m = f === F;
1555
+ return /* @__PURE__ */ t.jsxs(
1556
+ Mt,
1557
+ {
1558
+ role: "option",
1559
+ "aria-selected": E,
1560
+ "data-active": E || void 0,
1561
+ "data-hovered": m || void 0,
1562
+ onMouseEnter: () => H(f),
1563
+ onMouseLeave: () => H(null),
1564
+ onMouseDown: (z) => z.preventDefault(),
1565
+ onClick: () => ee(a),
1566
+ children: [
1567
+ a.icon && /* @__PURE__ */ t.jsx(Pt, { children: a.icon }),
1568
+ /* @__PURE__ */ t.jsx(v, { variant: "form-input", children: a.label })
1569
+ ]
1570
+ },
1571
+ a.value
1572
+ );
1573
+ })
1574
+ }
1575
+ )
1576
+ ]
1577
+ }
1578
+ );
1579
+ }
1580
+ );
1581
+ Gt.displayName = "SelectField";
1582
+ const Ft = {
1583
+ top: "translate3d(0, 6px, 0)",
1584
+ bottom: "translate3d(0, -6px, 0)",
1585
+ left: "translate3d(6px, 0, 0)",
1586
+ right: "translate3d(-6px, 0, 0)"
1587
+ }, Nt = $.div`
1588
+ display: inline-flex;
1589
+ position: relative;
1590
+ `, Vt = $.div`
1591
+ display: inline-flex;
1592
+ align-items: center;
1593
+ justify-content: center;
1594
+ cursor: pointer;
1595
+ outline: none;
1596
+
1597
+ &:focus-visible {
1598
+ box-shadow: inset 0 0 0 2px rgba(84, 132, 255, 0.65);
1599
+ border-radius: 6px;
1600
+ }
1601
+
1602
+ &[data-open="true"] {
1603
+ cursor: default;
1604
+ }
1605
+
1606
+ &[data-disabled="true"] {
1607
+ cursor: not-allowed;
1608
+ }
1609
+ `, Yt = $.div`
1610
+ position: fixed;
1611
+ top: -9999px;
1612
+ left: -9999px;
1613
+ padding: 10px 14px;
1614
+ border-radius: 8px;
1615
+ font-size: 13px;
1616
+ line-height: 1.35;
1617
+ max-width: min(320px, calc(100vw - 16px));
1618
+ box-shadow: 0px 8px 24px 0px #0000001f;
1619
+ filter: drop-shadow(0px 8px 24px 0px #0000001f);
1620
+ background: ${({ theme: e }) => e.colors.primary.white};
1621
+ z-index: 9999;
1622
+ opacity: ${({ $visible: e }) => e ? 1 : 0};
1623
+ visibility: ${({ $visible: e }) => e ? "visible" : "hidden"};
1624
+ transform: ${({ $visible: e, $placement: r }) => e ? "translate3d(0, 0, 0)" : Ft[r]};
1625
+ transition: opacity 0.18s ease, transform 0.18s ease;
1626
+
1627
+ pointer-events: ${({ $visible: e, $interactive: r }) => e && r ? "auto" : "none"};
1628
+
1629
+ @media (prefers-reduced-motion: reduce) {
1630
+ transition: none;
1631
+ }
1632
+
1633
+ &::after {
1634
+ content: "";
1635
+ position: absolute;
1636
+ inset: 0;
1637
+ border-radius: inherit;
1638
+ pointer-events: none;
1639
+ }
1640
+
1641
+ &[data-placement="top"] {
1642
+ --tooltip-arrow-x: 0px;
1643
+ }
1644
+
1645
+ &[data-placement="bottom"] {
1646
+ --tooltip-arrow-x: 0px;
1647
+ }
1648
+
1649
+ &[data-placement="left"] {
1650
+ --tooltip-arrow-y: 0px;
1651
+ }
1652
+
1653
+ &[data-placement="right"] {
1654
+ --tooltip-arrow-y: 0px;
1655
+ }
1656
+ `, Zt = $.span`
1657
+ position: absolute;
1658
+ width: 10px;
1659
+ height: 10px;
1660
+ background: inherit;
1661
+ border: inherit;
1662
+ border-radius: 2px;
1663
+ transform: rotate(45deg);
1664
+ pointer-events: none;
1665
+
1666
+ ${({ $placement: e }) => {
1667
+ switch (e) {
1668
+ case "top":
1669
+ return g`
1670
+ bottom: -5px;
1671
+ left: 50%;
1672
+ transform: translateX(-50%) translateX(var(--tooltip-arrow-x, 0px))
1673
+ rotate(45deg);
1674
+ `;
1675
+ case "bottom":
1676
+ return g`
1677
+ top: -5px;
1678
+ left: 50%;
1679
+ transform: translateX(-50%) translateX(var(--tooltip-arrow-x, 0px))
1680
+ rotate(45deg);
1681
+ `;
1682
+ case "left":
1683
+ return g`
1684
+ right: -5px;
1685
+ top: 50%;
1686
+ transform: translateY(-50%) translateY(var(--tooltip-arrow-y, 0px))
1687
+ rotate(45deg);
1688
+ `;
1689
+ case "right":
1690
+ default:
1691
+ return g`
1692
+ left: -5px;
1693
+ top: 50%;
1694
+ transform: translateY(-50%) translateY(var(--tooltip-arrow-y, 0px))
1695
+ rotate(45deg);
1696
+ `;
1697
+ }
1698
+ }}
1699
+ `, Xt = $(v).attrs({
1700
+ variant: "body-s"
1701
+ })`
1702
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1703
+ `, M = 8, K = 12, Be = 12, Ut = {
1704
+ top: ["top", "bottom", "right", "left"],
1705
+ bottom: ["bottom", "top", "right", "left"],
1706
+ left: ["left", "right", "top", "bottom"],
1707
+ right: ["right", "left", "top", "bottom"]
1708
+ }, fe = (e, r, o) => Math.min(Math.max(e, r), o), qt = ({
1709
+ content: e,
1710
+ children: r,
1711
+ position: o = "top",
1712
+ open: i,
1713
+ defaultOpen: l = !1,
1714
+ onOpenChange: c,
1715
+ showDelay: d = 150,
1716
+ hideDelay: x = 150,
1717
+ interactive: w = !1,
1718
+ disabled: b = !1,
1719
+ hideOnClick: j = !1,
1720
+ maxWidth: y
1721
+ }) => {
1722
+ const [S, T] = W(l), k = typeof i == "boolean", B = k ? !!i : S, _ = Z(null), C = Z(null), O = Z(null), G = Z(null), I = Z(null), P = Z(null), re = we(), F = ve(
1723
+ () => ({
1724
+ top: -9999,
1725
+ left: -9999,
1726
+ arrowX: 0,
1727
+ arrowY: 0,
1728
+ placement: o
1729
+ }),
1730
+ [o]
1731
+ ), [H, N] = W(F), q = () => {
1732
+ G.current && (clearTimeout(G.current), G.current = null), I.current && (clearTimeout(I.current), I.current = null);
1733
+ }, R = L(
1734
+ (p) => {
1735
+ k || T(p), p || N(F), c?.(p);
1736
+ },
1737
+ [F, k, c]
1738
+ ), U = L(() => {
1739
+ b || (q(), G.current = setTimeout(() => R(!0), d));
1740
+ }, [b, R, d]), V = L(() => {
1741
+ b || (q(), I.current = setTimeout(() => R(!1), x));
1742
+ }, [b, R, x]), ie = () => {
1743
+ b || U();
1744
+ }, Q = () => {
1745
+ b || V();
1746
+ }, J = () => {
1747
+ b || U();
1748
+ }, D = () => {
1749
+ b || V();
1750
+ }, Y = () => {
1751
+ j && R(!1);
1752
+ }, oe = () => {
1753
+ w && q();
1754
+ }, ee = () => {
1755
+ w && V();
1756
+ }, n = L(() => {
1757
+ if (typeof window > "u" || !C.current || !O.current)
1758
+ return;
1759
+ const p = C.current.getBoundingClientRect(), a = O.current.getBoundingClientRect(), f = window.innerWidth, E = window.innerHeight, m = p.left + p.width / 2, z = p.top + p.height / 2, ae = (A) => {
1760
+ switch (A) {
1761
+ case "top":
1762
+ return p.top >= a.height + K + M;
1763
+ case "bottom":
1764
+ return E - p.bottom >= a.height + K + M;
1765
+ case "left":
1766
+ return p.left >= a.width + K + M;
1767
+ case "right":
1768
+ return f - p.right >= a.width + K + M;
1769
+ default:
1770
+ return !0;
1771
+ }
1772
+ }, te = Ut[o].find((A) => ae(A)) ?? o;
1773
+ let le = 0, se = 0;
1774
+ switch (te) {
1775
+ case "top":
1776
+ le = p.top - a.height - K, se = m - a.width / 2;
1777
+ break;
1778
+ case "bottom":
1779
+ le = p.bottom + K, se = m - a.width / 2;
1780
+ break;
1781
+ case "left":
1782
+ le = z - a.height / 2, se = p.left - a.width - K;
1783
+ break;
1784
+ case "right":
1785
+ default:
1786
+ le = z - a.height / 2, se = p.right + K;
1787
+ break;
1788
+ }
1789
+ const Ge = Math.max(f - M * 2, 0), Fe = Math.max(E - M * 2, 0), Ne = M, Ve = f - a.width - M, Ye = M, Ze = E - a.height - M, $e = a.width >= Ge ? M : fe(se, Ne, Ve), ke = a.height >= Fe ? M : fe(le, Ye, Ze);
1790
+ let ue = 0, he = 0;
1791
+ if (te === "top" || te === "bottom") {
1792
+ const A = Math.max(a.width / 2 - Be, 0);
1793
+ ue = fe(
1794
+ m - ($e + a.width / 2),
1795
+ -A,
1796
+ A
1797
+ ), he = 0;
1798
+ } else {
1799
+ const A = Math.max(a.height / 2 - Be, 0);
1800
+ he = fe(
1801
+ z - (ke + a.height / 2),
1802
+ -A,
1803
+ A
1804
+ ), ue = 0;
1805
+ }
1806
+ N((A) => A.top === ke && A.left === $e && A.arrowX === ue && A.arrowY === he && A.placement === te ? A : {
1807
+ top: ke,
1808
+ left: $e,
1809
+ arrowX: ue,
1810
+ arrowY: he,
1811
+ placement: te
1812
+ });
1813
+ }, [o]);
1814
+ Oe(() => {
1815
+ if (!B)
1816
+ return;
1817
+ const p = O.current, a = C.current;
1818
+ if (!p || !a) return;
1819
+ const f = () => {
1820
+ P.current !== null && cancelAnimationFrame(P.current), P.current = window.requestAnimationFrame(() => {
1821
+ P.current = null, n();
1822
+ });
1823
+ };
1824
+ f();
1825
+ const m = typeof window < "u" && "ResizeObserver" in window ? new ResizeObserver(f) : null;
1826
+ return m?.observe(p), m?.observe(a), window.addEventListener("resize", f), window.addEventListener("scroll", f, !0), () => {
1827
+ window.removeEventListener("resize", f), window.removeEventListener("scroll", f, !0), m?.disconnect(), P.current !== null && (cancelAnimationFrame(P.current), P.current = null);
1828
+ };
1829
+ }, [B, n]), ye(() => q, []), ye(() => {
1830
+ if (!B) return;
1831
+ const p = (f) => {
1832
+ f.key === "Escape" && R(!1);
1833
+ }, a = (f) => {
1834
+ const E = f.target;
1835
+ _.current?.contains(E) || O.current?.contains(E) || R(!1);
1836
+ };
1837
+ return document.addEventListener("keydown", p), document.addEventListener("pointerdown", a), () => {
1838
+ document.removeEventListener("keydown", p), document.removeEventListener("pointerdown", a);
1839
+ };
1840
+ }, [B, R]);
1841
+ const h = {
1842
+ top: H.top,
1843
+ left: H.left,
1844
+ "--tooltip-arrow-x": `${H.arrowX}px`,
1845
+ "--tooltip-arrow-y": `${H.arrowY}px`
1846
+ };
1847
+ return y !== void 0 && (h.maxWidth = typeof y == "number" ? `${y}px` : y), /* @__PURE__ */ t.jsxs(Nt, { ref: _, "data-disabled": b, children: [
1848
+ /* @__PURE__ */ t.jsx(
1849
+ Vt,
1850
+ {
1851
+ ref: C,
1852
+ tabIndex: b ? -1 : 0,
1853
+ "aria-describedby": B ? re : void 0,
1854
+ onMouseEnter: ie,
1855
+ onMouseLeave: Q,
1856
+ onFocus: J,
1857
+ onBlur: D,
1858
+ onClick: Y,
1859
+ "data-open": B,
1860
+ children: r
1861
+ }
1862
+ ),
1863
+ /* @__PURE__ */ t.jsxs(
1864
+ Yt,
1865
+ {
1866
+ ref: O,
1867
+ id: re,
1868
+ role: "tooltip",
1869
+ "aria-hidden": !B,
1870
+ $visible: B,
1871
+ $interactive: w,
1872
+ $placement: H.placement,
1873
+ style: h,
1874
+ "data-placement": H.placement,
1875
+ onMouseEnter: oe,
1876
+ onMouseLeave: ee,
1877
+ children: [
1878
+ ["string", "number"].includes(typeof e) ? /* @__PURE__ */ t.jsx(Xt, { variant: "body-m", children: e }) : e,
1879
+ /* @__PURE__ */ t.jsx(Zt, { $placement: H.placement })
1880
+ ]
1881
+ }
1882
+ )
1883
+ ] });
1884
+ }, Jt = (e, r = 4, o = 7) => {
1885
+ const i = e.trim();
1886
+ if (!i) return i;
1887
+ const l = i.lastIndexOf(".");
1888
+ if (l <= 0 || l === i.length - 1)
1889
+ return i;
1890
+ const c = i.slice(l + 1), x = i.slice(0, l).replace(/[@.]/g, "").slice(0, r), w = "*".repeat(o);
1891
+ return `${x}${w}${c}`;
1892
+ }, Kt = (e) => e.toString().padStart(16, "0").replace(/(\d{4})(?=\d)/g, "$1 "), Qt = async (e) => {
1893
+ try {
1894
+ await navigator.clipboard.writeText(e), console.log("Скопировано в буфер обмена");
1895
+ } catch (r) {
1896
+ console.error("Ошибка копирования:", r);
1897
+ }
1898
+ }, er = s.div`
1899
+ display: flex;
1900
+ gap: 10px;
1901
+ align-items: center;
1902
+ `, tr = s(v)`
1903
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
1904
+ `, Jr = ({ email: e }) => /* @__PURE__ */ t.jsxs(er, { children: [
1905
+ /* @__PURE__ */ t.jsx(dt, {}),
1906
+ /* @__PURE__ */ t.jsx(tr, { variant: "body-m-semibold", children: Jt(e) })
1907
+ ] }), pe = {
1908
+ m: { minWidth: 55, height: 46, fontSize: 16, lineHeight: 20, paddingX: 14 },
1909
+ l: { minWidth: 58, height: 48, fontSize: 18, lineHeight: 22, paddingX: 14 },
1910
+ xl: { minWidth: 68, height: 56, fontSize: 24, lineHeight: 30, paddingX: 14 }
1911
+ }, rr = $.button`
1912
+ ${({ $size: e }) => g`
1913
+ min-width: ${pe[e].minWidth}px;
1914
+ height: ${pe[e].height}px;
1915
+ padding: 0 ${pe[e].paddingX}px;
1916
+ font-size: ${pe[e].fontSize}px;
1917
+ line-height: ${pe[e].lineHeight}px;
1918
+ `}
1919
+ position: relative;
1920
+ background: transparent;
1921
+ border: none;
1922
+ display: inline-flex;
1923
+ align-items: flex-end;
1924
+ justify-content: center;
1925
+ font-weight: 700;
1926
+ cursor: pointer;
1927
+ text-transform: none;
1928
+ color: ${({ theme: e, $active: r }) => r ? e.colors.primary.darkBlue : e.colors.gray.darkGray};
1929
+ transition: color 120ms ease;
1930
+ padding-bottom: 25px;
1931
+ &::after {
1932
+ content: "";
1933
+ position: absolute;
1934
+ inset-inline: 0;
1935
+ bottom: 0;
1936
+ height: ${({ $active: e }) => e ? 2 : 1}px;
1937
+ background: ${({ theme: e, $active: r }) => r ? e.colors.primary.primaryBlue : e.colors.gray.lightGray2};
1938
+ transition: height 120ms ease, background 120ms ease;
1939
+ }
1940
+
1941
+ &:hover:not(:disabled) {
1942
+ color: ${({ theme: e }) => e.colors.primary.darkBlue2};
1943
+
1944
+ &::after {
1945
+ height: 2px;
1946
+ background: ${({ theme: e }) => e.colors.primary.hoverBlue};
1947
+ }
1948
+ }
1949
+
1950
+ &:focus-visible {
1951
+ outline: none;
1952
+ box-shadow: inset 0 -2px 0 ${({ theme: e }) => e.colors.primary.hoverBlue};
1953
+ }
1954
+
1955
+ &:disabled {
1956
+ cursor: not-allowed;
1957
+ color: ${({ theme: e }) => e.colors.gray.darkGray + "80"};
1958
+ &::after {
1959
+ background: ${({ theme: e }) => e.colors.gray.lightGray2};
1960
+ }
1961
+ }
1962
+ `, or = $.div`
1963
+ display: flex;
1964
+ box-shadow: inset 0 -1px 0 ${({ theme: e }) => e.colors.gray.lightGray2};
1965
+ `, nr = ({
1966
+ id: e,
1967
+ label: r,
1968
+ active: o = !1,
1969
+ disabled: i = !1,
1970
+ size: l = "m",
1971
+ onSelect: c,
1972
+ className: d
1973
+ }) => {
1974
+ const x = L(() => {
1975
+ i || c?.(e);
1976
+ }, [i, e, c]);
1977
+ return /* @__PURE__ */ t.jsx(
1978
+ rr,
1979
+ {
1980
+ type: "button",
1981
+ role: "tab",
1982
+ "aria-selected": o,
1983
+ "aria-disabled": i,
1984
+ disabled: i,
1985
+ $size: l,
1986
+ $active: o,
1987
+ className: d,
1988
+ onClick: x,
1989
+ children: r
1990
+ }
1991
+ );
1992
+ }, Kr = ({
1993
+ size: e = "m",
1994
+ activeId: r,
1995
+ items: o,
1996
+ onChange: i,
1997
+ className: l
1998
+ }) => {
1999
+ const c = L(
2000
+ (d) => {
2001
+ i(d);
2002
+ },
2003
+ [i]
2004
+ );
2005
+ return /* @__PURE__ */ t.jsx(or, { role: "tablist", className: l, children: o.map((d) => /* @__PURE__ */ t.jsx(
2006
+ nr,
2007
+ {
2008
+ ...d,
2009
+ size: e,
2010
+ active: d.id === r,
2011
+ onSelect: c
2012
+ },
2013
+ d.id
2014
+ )) });
2015
+ }, ir = $.table`
2016
+ width: 100%;
2017
+ border-collapse: collapse;
2018
+ overflow: hidden;
2019
+ `, He = $.tr`
2020
+ &:nth-child(2n) {
2021
+ background: ${({ theme: e }) => e.colors.gray.lightBlueGray};
2022
+ }
2023
+ `, ar = $(v).attrs({
2024
+ forwardedAs: "td",
2025
+ variant: "body-m"
2026
+ })`
2027
+ display: table-cell;
2028
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2029
+ padding: 16px 14px;
2030
+ &:first-child {
2031
+ border-radius: 10px 0 0 10px;
2032
+ }
2033
+ &:last-child {
2034
+ border-radius: 0 10px 10px 0;
2035
+ }
2036
+ `, lr = $(v).attrs({
2037
+ forwardedAs: "th",
2038
+ variant: "body-s"
2039
+ })`
2040
+ display: table-cell;
2041
+ color: ${({ theme: e }) => e.colors.gray.darkGray2};
2042
+ padding: 16px 14px;
2043
+ `, sr = $.tbody``, cr = $.thead``, Qr = ({ columns: e, data: r }) => /* @__PURE__ */ t.jsxs(ir, { children: [
2044
+ /* @__PURE__ */ t.jsx(cr, { children: /* @__PURE__ */ t.jsx(He, { children: e.map((o) => /* @__PURE__ */ t.jsx(
2045
+ lr,
2046
+ {
2047
+ width: o.width,
2048
+ align: o.align || "left",
2049
+ children: o.name
2050
+ },
2051
+ o.id
2052
+ )) }) }),
2053
+ /* @__PURE__ */ t.jsx(sr, { children: r.map((o) => /* @__PURE__ */ t.jsx(He, { children: e.map((i) => /* @__PURE__ */ t.jsx(
2054
+ ar,
2055
+ {
2056
+ width: i.width,
2057
+ align: i.align || "left",
2058
+ children: i.render ? i.render(o) : o[i.id]
2059
+ },
2060
+ i.id
2061
+ )) }, o.id)) })
2062
+ ] }), dr = s.div`
2063
+ display: inline-flex;
2064
+ `, pr = s.button`
2065
+ position: relative;
2066
+ width: 56px;
2067
+ height: 26px;
2068
+ padding: 4px;
2069
+ border: none;
2070
+ border-radius: 22px;
2071
+ background: ${({ $checked: e, theme: r }) => e ? r.colors.primary.primaryBlue : r.colors.gray.darkGray2};
2072
+ cursor: pointer;
2073
+ transition: background 150ms ease;
2074
+ outline: none;
2075
+
2076
+ &:focus-visible {
2077
+ box-shadow: 0 0 0 2px rgba(49, 99, 240, 0.4);
2078
+ }
2079
+
2080
+ &:hover {
2081
+ background: ${({ $checked: e, theme: r }) => e ? r.colors.primary.hoverBlue : r.colors.gray.darkGray};
2082
+ }
2083
+
2084
+ &:disabled {
2085
+ cursor: not-allowed;
2086
+ background: ${({ theme: e }) => e.colors.gray.darkGray};
2087
+ }
2088
+ `, ur = s.span`
2089
+ position: absolute;
2090
+ top: 50%;
2091
+ left: 4px;
2092
+ width: 18px;
2093
+ height: 18px;
2094
+ border-radius: 50%;
2095
+ background: ${({ $disabled: e, theme: r }) => e ? r.colors.primary.darkBlue2 : "#ffffff"};
2096
+ box-shadow: ${({ $disabled: e }) => e ? "none" : "0 3px 6px rgba(0, 0, 0, 0.25)"};
2097
+ transform: translate(${({ $checked: e }) => e ? "30px" : "0"}, -50%);
2098
+ transition: transform 180ms ease, background 150ms ease, box-shadow 150ms ease;
2099
+ `, eo = ({
2100
+ checked: e,
2101
+ defaultChecked: r = !1,
2102
+ disabled: o = !1,
2103
+ onChange: i,
2104
+ id: l,
2105
+ className: c
2106
+ }) => {
2107
+ const d = we(), x = l ?? d, w = e !== void 0, [b, j] = W(r), y = w ? e : b, S = L(() => {
2108
+ if (o) return;
2109
+ const k = !y;
2110
+ w || j(k), i?.(k);
2111
+ }, [y, w, o, i]), T = L(
2112
+ (k) => {
2113
+ (k.key === "Enter" || k.key === " ") && (k.preventDefault(), S());
2114
+ },
2115
+ [S]
2116
+ );
2117
+ return /* @__PURE__ */ t.jsx(dr, { className: c, children: /* @__PURE__ */ t.jsx(
2118
+ pr,
2119
+ {
2120
+ id: x,
2121
+ role: "switch",
2122
+ "aria-checked": y,
2123
+ "aria-disabled": o,
2124
+ tabIndex: o ? -1 : 0,
2125
+ onClick: S,
2126
+ onKeyDown: T,
2127
+ disabled: o,
2128
+ $checked: y,
2129
+ children: /* @__PURE__ */ t.jsx(ur, { $checked: y, $disabled: o })
2130
+ }
2131
+ ) });
2132
+ }, hr = $.label`
2133
+ display: inline-flex;
2134
+ align-items: center;
2135
+ gap: 12px;
2136
+ cursor: ${({ disabled: e }) => e ? "not-allowed" : "pointer"};
2137
+ `, xr = $.input`
2138
+ position: absolute;
2139
+ opacity: 0;
2140
+ pointer-events: none;
2141
+ `, fr = $.span`
2142
+ width: 24px;
2143
+ height: 24px;
2144
+ border-radius: 3px;
2145
+ border: 1px solid ${({ theme: e }) => e.colors.gray.lightGray3};
2146
+ background-color: ${({ theme: e }) => e.colors.primary.white};
2147
+ display: inline-flex;
2148
+ align-items: center;
2149
+ justify-content: center;
2150
+ transition: background-color 140ms ease, border-color 140ms ease;
2151
+
2152
+ ${({ $checked: e, theme: r }) => e && g`
2153
+ border-color: ${r.colors.primary.primaryBlue};
2154
+ background-color: ${r.colors.primary.primaryBlue};
2155
+ `}
2156
+
2157
+ ${({ $checked: e, $disabled: r, theme: o }) => !r && !e && g`
2158
+ &:hover {
2159
+ border-color: ${o.colors.primary.hoverBlue};
2160
+ }
2161
+ `}
2162
+
2163
+ ${({ $checked: e, $disabled: r, theme: o }) => !r && e && g`
2164
+ &:hover {
2165
+ border-color: ${o.colors.primary.hoverBlue};
2166
+ background-color: ${o.colors.primary.hoverBlue};
2167
+ }
2168
+ `}
2169
+
2170
+ ${({ $disabled: e, theme: r }) => e && g`
2171
+ border-color: ${r.colors.gray.lightGray2};
2172
+ background-color: ${r.colors.gray.lightGray};
2173
+ `}
2174
+ `, gr = $.svg`
2175
+ width: 12px;
2176
+ height: 9px;
2177
+ fill: none;
2178
+ stroke-linecap: round;
2179
+ stroke-linejoin: round;
2180
+ transition: opacity 120ms ease;
2181
+ stroke: ${({ theme: e }) => e.colors.primary.white};
2182
+ `, to = ({
2183
+ checked: e,
2184
+ defaultChecked: r = !1,
2185
+ disabled: o = !1,
2186
+ name: i,
2187
+ value: l,
2188
+ onChange: c,
2189
+ className: d
2190
+ }) => {
2191
+ const x = we(), w = e !== void 0, [b, j] = W(r), y = w ? e : b, S = L(
2192
+ (T) => {
2193
+ o || (w || j(T.target.checked), c?.(T.target.checked));
2194
+ },
2195
+ [o, w, c]
2196
+ );
2197
+ return /* @__PURE__ */ t.jsxs(hr, { htmlFor: x, disabled: o, className: d, children: [
2198
+ /* @__PURE__ */ t.jsx(
2199
+ xr,
2200
+ {
2201
+ id: x,
2202
+ type: "checkbox",
2203
+ checked: y,
2204
+ disabled: o,
2205
+ onChange: S,
2206
+ name: i,
2207
+ value: l
2208
+ }
2209
+ ),
2210
+ /* @__PURE__ */ t.jsx(fr, { $checked: y, $disabled: o, children: y && /* @__PURE__ */ t.jsx(gr, { viewBox: "0 0 15 11", children: /* @__PURE__ */ t.jsx(
2211
+ "path",
2212
+ {
2213
+ d: "M5.00034 11L0 6.18738L1.42838 4.81262L5.00185 8.24806L5.00034 8.24951L13.5716 0L15 1.37476L6.42872 9.62524L5.00135 10.999L5.00034 11Z",
2214
+ fill: "#fff"
2215
+ }
2216
+ ) }) })
2217
+ ] });
2218
+ }, mr = s.div`
2219
+ display: flex;
2220
+ column-gap: 10px;
2221
+ row-gap: 12px;
2222
+ width: 100%;
2223
+ flex: 1;
2224
+ flex-direction: column;
2225
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2226
+ flex-direction: row;
2227
+ justify-content: space-between;
2228
+ }
2229
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
2230
+ flex-direction: column;
2231
+ }
2232
+ `, br = s(v).attrs({
2233
+ forwardedAs: "p",
2234
+ variant: "body-s-semibold"
2235
+ })`
2236
+ white-space: nowrap;
2237
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
2238
+ `, Ae = s.div`
2239
+ display: flex;
2240
+ align-items: center;
2241
+ gap: 8px;
2242
+ height: 100%;
2243
+ `, yr = s(v).attrs({
2244
+ forwardedAs: "p",
2245
+ variant: "body-m-semibold"
2246
+ })`
2247
+ margin: 0;
2248
+ white-space: nowrap;
2249
+ color: ${({ theme: e }) => `${e.colors.primary.darkBlue}`};
2250
+ `, ro = ({
2251
+ label: e,
2252
+ statusValue: r,
2253
+ withdraw: o,
2254
+ info: i
2255
+ }) => /* @__PURE__ */ t.jsxs(mr, { children: [
2256
+ /* @__PURE__ */ t.jsxs(Ae, { children: [
2257
+ /* @__PURE__ */ t.jsx(br, { children: e }),
2258
+ i && /* @__PURE__ */ t.jsx(qt, { content: i, children: /* @__PURE__ */ t.jsx(Pe, { size: 18 }) })
2259
+ ] }),
2260
+ /* @__PURE__ */ t.jsxs(Ae, { children: [
2261
+ ["number", "string"].includes(typeof r) && /* @__PURE__ */ t.jsx(yr, { children: r }),
2262
+ !["number", "string"].includes(typeof r) && r,
2263
+ o && /* @__PURE__ */ t.jsx(ht, { size: 18 })
2264
+ ] })
2265
+ ] }), wr = s.div`
2266
+ display: flex;
2267
+ width: fit-content;
2268
+ align-items: center;
2269
+ gap: 22px;
2270
+ ${({ $variant: e }) => {
2271
+ switch (e) {
2272
+ case "secondary":
2273
+ return g`
2274
+ padding: 24px;
2275
+ background: #f5f5f5;
2276
+ `;
2277
+ case "primary":
2278
+ default:
2279
+ return g`
2280
+ padding: 24px 20px;
2281
+ background: ${({ theme: r }) => r.colors.primary.white};
2282
+ border: 1px solid ${({ theme: r }) => r.colors.gray.lightGray2};
2283
+ `;
2284
+ }
2285
+ }}
2286
+
2287
+ border-radius: 6px;
2288
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2289
+ width: 100%;
2290
+ flex-direction: column;
2291
+ gap: 18px;
2292
+ padding: 18px 20px;
2293
+ }
2294
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
2295
+ flex-direction: column;
2296
+ gap: 16px;
2297
+ padding: 16px 20px;
2298
+ }
2299
+ `, vr = s.div`
2300
+ display: flex;
2301
+ gap: 56px;
2302
+ width: fit-content;
2303
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2304
+ width: 100%;
2305
+ flex-direction: column;
2306
+ gap: 12px;
2307
+ }
2308
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
2309
+ flex-direction: column;
2310
+ gap: 8px;
2311
+ }
2312
+ `, $r = s.div`
2313
+ display: flex;
2314
+ gap: 22px;
2315
+ width: fit-content;
2316
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2317
+ width: 100%;
2318
+ gap: 20px;
2319
+ }
2320
+ `, oo = ({
2321
+ children: e,
2322
+ actions: r,
2323
+ variant: o = "primary"
2324
+ }) => /* @__PURE__ */ t.jsxs(wr, { $variant: o, children: [
2325
+ /* @__PURE__ */ t.jsx(vr, { children: e }),
2326
+ r && /* @__PURE__ */ t.jsx($r, { children: r })
2327
+ ] }), kr = s.div`
2328
+ display: flex;
2329
+ column-gap: 10px;
2330
+ row-gap: 12px;
2331
+ width: 100%;
2332
+ flex: 1;
2333
+ flex-direction: column;
2334
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2335
+ flex-direction: row;
2336
+ justify-content: space-between;
2337
+ }
2338
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
2339
+ flex-direction: column;
2340
+ }
2341
+ `, jr = s(v).attrs({
2342
+ forwardedAs: "p",
2343
+ variant: "body-s-semibold"
2344
+ })`
2345
+ margin: 0;
2346
+ white-space: nowrap;
2347
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
2348
+ `, Le = s.div`
2349
+ display: flex;
2350
+ align-items: center;
2351
+ gap: 8px;
2352
+ height: 100%;
2353
+ `, Cr = s(v).attrs({
2354
+ forwardedAs: "p",
2355
+ variant: "body-m-semibold"
2356
+ })`
2357
+ white-space: nowrap;
2358
+ margin: 0;
2359
+ ${({ $type: e, theme: r }) => {
2360
+ switch (e) {
2361
+ case "success":
2362
+ return `
2363
+ color: ${r.colors.accent.green};
2364
+ `;
2365
+ case "pending":
2366
+ return `
2367
+ color: ${r.colors.primary.darkBlue};
2368
+ `;
2369
+ case "warning":
2370
+ return `
2371
+ color: ${r.colors.accent.orange};
2372
+ `;
2373
+ }
2374
+ }}
2375
+ `, no = ({
2376
+ label: e,
2377
+ statusValue: r,
2378
+ type: o
2379
+ }) => {
2380
+ const i = ve(() => {
2381
+ switch (o) {
2382
+ case "success":
2383
+ return /* @__PURE__ */ t.jsx(De, { size: 18 });
2384
+ case "warning":
2385
+ return /* @__PURE__ */ t.jsx(ut, { size: 18 });
2386
+ case "pending":
2387
+ default:
2388
+ return /* @__PURE__ */ t.jsx(Me, { size: 18 });
2389
+ }
2390
+ }, [o]);
2391
+ return /* @__PURE__ */ t.jsxs(kr, { children: [
2392
+ /* @__PURE__ */ t.jsx(Le, { children: /* @__PURE__ */ t.jsx(jr, { children: e }) }),
2393
+ /* @__PURE__ */ t.jsxs(Le, { children: [
2394
+ i,
2395
+ /* @__PURE__ */ t.jsx(Cr, { $type: o, children: r })
2396
+ ] })
2397
+ ] });
2398
+ }, Sr = s.tr`
2399
+ position: relative;
2400
+ `, Se = s.td`
2401
+ padding: 14px 16px;
2402
+ border-collapse: separate;
2403
+ border-spacing: 0;
2404
+ white-space: nowrap;
2405
+ background: ${({ theme: e }) => e.colors.gray.lightBlueGray};
2406
+ `, Er = s.td`
2407
+ background: ${({ theme: e }) => e.colors.gray.lightBlueGray};
2408
+ `, io = ({
2409
+ valueLabel: e,
2410
+ count: r,
2411
+ amount: o,
2412
+ actions: i
2413
+ }) => /* @__PURE__ */ t.jsxs(Sr, { children: [
2414
+ /* @__PURE__ */ t.jsx(Se, { children: e }),
2415
+ /* @__PURE__ */ t.jsx(Se, { children: r }),
2416
+ /* @__PURE__ */ t.jsx(Se, { children: o }),
2417
+ /* @__PURE__ */ t.jsx(Er, { children: i })
2418
+ ] }), Tr = $.div`
2419
+ display: grid;
2420
+ grid-template-columns: ${({ $longname: e, $shortname: r, $network: o, $icon: i }) => `
2421
+ ${i ? "auto" : ""}
2422
+ ${e || o ? "1fr" : ""}
2423
+ ${r ? "auto" : ""}
2424
+ `};
2425
+ grid-template-areas: ${({ $network: e, $icon: r }) => `
2426
+ "${r ? "icon " : ""}longname shortname"
2427
+ ${e ? `"${r ? "." : ""} network ."` : ""}
2428
+ `};
2429
+ width: 100%;
2430
+ column-gap: 10px;
2431
+ align-items: center;
2432
+ `, Rr = $(v).attrs({
2433
+ variant: "body-m-bold"
2434
+ })`
2435
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2436
+ grid-area: longname;
2437
+ `, Br = $(v).attrs({
2438
+ variant: "body-m"
2439
+ })`
2440
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
2441
+ grid-area: shortname;
2442
+ `, Hr = $(v).attrs({
2443
+ variant: "body-s"
2444
+ })`
2445
+ color: ${({ theme: e }) => e.colors.gray.darkGray2};
2446
+ grid-area: network;
2447
+ `, Ar = ({
2448
+ icon: e,
2449
+ network: r,
2450
+ longName: o,
2451
+ shortName: i
2452
+ }) => /* @__PURE__ */ t.jsxs(
2453
+ Tr,
2454
+ {
2455
+ $icon: !!e,
2456
+ $longname: !!o,
2457
+ $shortname: !!i,
2458
+ $network: !!r,
2459
+ children: [
2460
+ e,
2461
+ /* @__PURE__ */ t.jsx(Rr, { children: o }),
2462
+ i && /* @__PURE__ */ t.jsx(Br, { children: i }),
2463
+ r && /* @__PURE__ */ t.jsx(Hr, { children: r })
2464
+ ]
2465
+ }
2466
+ ), Lr = s.div`
2467
+ display: flex;
2468
+ flex-direction: column;
2469
+ align-items: flex-start;
2470
+ padding: 16px;
2471
+ background: ${({ theme: e }) => e.colors.gray.lightBlueGray};
2472
+ border-radius: 10px;
2473
+ gap: 14px;
2474
+ `, zr = s.div`
2475
+ display: flex;
2476
+ flex-direction: row;
2477
+ align-items: flex-start;
2478
+ padding: 0px;
2479
+ gap: 10px;
2480
+ width: 100%;
2481
+ `, ze = s.div`
2482
+ display: flex;
2483
+ flex-direction: column;
2484
+ align-items: flex-start;
2485
+ gap: 8px;
2486
+ padding: 0px;
2487
+ width: 100%;
2488
+ `, We = s(v).attrs({
2489
+ variant: "body-s"
2490
+ })`
2491
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
2492
+ `, _e = s(v).attrs({
2493
+ variant: "body-m-bold"
2494
+ })`
2495
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2496
+ `, ao = ({
2497
+ longName: e,
2498
+ shortName: r,
2499
+ network: o,
2500
+ icon: i,
2501
+ buyLabel: l,
2502
+ sellLabel: c,
2503
+ buyValue: d,
2504
+ sellValue: x
2505
+ }) => /* @__PURE__ */ t.jsxs(Lr, { children: [
2506
+ /* @__PURE__ */ t.jsx(
2507
+ Ar,
2508
+ {
2509
+ longName: e,
2510
+ shortName: r,
2511
+ network: o,
2512
+ icon: i
2513
+ }
2514
+ ),
2515
+ (d || x) && /* @__PURE__ */ t.jsxs(zr, { children: [
2516
+ d && /* @__PURE__ */ t.jsxs(ze, { children: [
2517
+ /* @__PURE__ */ t.jsx(We, { children: l }),
2518
+ /* @__PURE__ */ t.jsx(_e, { children: d })
2519
+ ] }),
2520
+ x && /* @__PURE__ */ t.jsxs(ze, { children: [
2521
+ /* @__PURE__ */ t.jsx(We, { children: c }),
2522
+ /* @__PURE__ */ t.jsx(_e, { children: x })
2523
+ ] })
2524
+ ] })
2525
+ ] }), Wr = s.div`
2526
+ display: grid;
2527
+ grid-template-columns: auto 1fr;
2528
+ row-gap: 12px;
2529
+ column-gap: 10px;
2530
+ width: 100%;
2531
+ background: #f5f5f5;
2532
+ border-radius: 10px;
2533
+ padding: 18px 24px;
2534
+ ${({ theme: e }) => e.media.maxWidth.tablet} {
2535
+ grid-template-columns: 1fr 1fr;
2536
+ padding: 18px 20px;
2537
+ }
2538
+ ${({ theme: e }) => e.media.maxWidth.mobile} {
2539
+ padding: 16px 14px;
2540
+ grid-template-columns: auto;
2541
+ row-gap: 8px;
2542
+ & > *:not(:nth-child(2n)) {
2543
+ margin-top: 4px;
2544
+ }
2545
+ }
2546
+ `, ge = s(v).attrs({
2547
+ variant: "body-m",
2548
+ forwardedAs: "p"
2549
+ })`
2550
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2551
+ `, me = s(v).attrs({
2552
+ variant: "body-m-bold",
2553
+ forwardedAs: "p"
2554
+ })`
2555
+ display: flex;
2556
+ gap: 8px;
2557
+ align-items: center;
2558
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2559
+ `, _r = s.button`
2560
+ border: none;
2561
+ background: none;
2562
+ cursor: pointer;
2563
+ padding: 0;
2564
+ `, Ir = ({ text: e, size: r = 18 }) => {
2565
+ const [o, i] = W(!1), l = Z(null);
2566
+ ye(() => (o && (l.current = setTimeout(() => {
2567
+ i(!1);
2568
+ }, 1500)), () => {
2569
+ l.current && clearTimeout(l.current);
2570
+ }), [o]);
2571
+ const c = async () => {
2572
+ await Qt(e), i(!0);
2573
+ };
2574
+ return /* @__PURE__ */ t.jsx(_r, { onClick: c, children: o ? /* @__PURE__ */ t.jsx(lt, { size: r }) : /* @__PURE__ */ t.jsx(pt, { size: r }) });
2575
+ }, lo = ({
2576
+ cardHolderLabel: e,
2577
+ cardHolderName: r,
2578
+ cardNumberLabel: o,
2579
+ cardNumber: i,
2580
+ merchantLabel: l,
2581
+ merchantName: c,
2582
+ descriptionLabel: d,
2583
+ description: x
2584
+ }) => /* @__PURE__ */ t.jsxs(Wr, { children: [
2585
+ /* @__PURE__ */ t.jsx(ge, { children: e }),
2586
+ /* @__PURE__ */ t.jsx(me, { children: r }),
2587
+ /* @__PURE__ */ t.jsx(ge, { children: o }),
2588
+ /* @__PURE__ */ t.jsxs(me, { children: [
2589
+ i && Kt(i),
2590
+ i && /* @__PURE__ */ t.jsx(Ir, { text: i.toString() })
2591
+ ] }),
2592
+ /* @__PURE__ */ t.jsx(ge, { children: l }),
2593
+ /* @__PURE__ */ t.jsx(me, { children: c }),
2594
+ /* @__PURE__ */ t.jsx(ge, { children: d }),
2595
+ /* @__PURE__ */ t.jsx(me, { children: x })
2596
+ ] }), Or = s.div`
2597
+ display: flex;
2598
+ align-items: center;
2599
+ gap: 12px;
2600
+ flex-wrap: wrap;
2601
+ width: 100%;
2602
+ justify-content: space-between;
2603
+ `, Mr = s(v).attrs({
2604
+ forwardedAs: "p",
2605
+ variant: "body-m-semibold"
2606
+ })`
2607
+ margin: 0;
2608
+ flex: 1 1 auto;
2609
+ color: ${({ theme: e }) => e.colors.gray.darkGray};
2610
+ `, Pr = s.div`
2611
+ display: flex;
2612
+ align-items: center;
2613
+ gap: 8px;
2614
+ flex: 1 1 auto;
2615
+ `, Dr = s(v).attrs({
2616
+ forwardedAs: "p",
2617
+ variant: "body-s-semibold"
2618
+ })`
2619
+ margin: 0;
2620
+ color: ${({ theme: e }) => e.colors.primary.darkBlue};
2621
+ `, so = ({
2622
+ label: e,
2623
+ statusValue: r,
2624
+ type: o
2625
+ }) => {
2626
+ const i = ve(() => {
2627
+ switch (o) {
2628
+ case "success":
2629
+ return /* @__PURE__ */ t.jsx(De, { size: 18 });
2630
+ case "pending":
2631
+ default:
2632
+ return /* @__PURE__ */ t.jsx(Me, { size: 18 });
2633
+ }
2634
+ }, [o]);
2635
+ return /* @__PURE__ */ t.jsxs(Or, { children: [
2636
+ /* @__PURE__ */ t.jsx(Mr, { children: e }),
2637
+ /* @__PURE__ */ t.jsxs(Pr, { children: [
2638
+ i,
2639
+ /* @__PURE__ */ t.jsx(Dr, { children: r })
2640
+ ] })
2641
+ ] });
2642
+ };
2643
+ export {
2644
+ ro as ApplicationData,
2645
+ oo as ApplicationInfo,
2646
+ no as ApplicationStatus,
2647
+ io as BalanceRow,
2648
+ tt as Button,
2649
+ to as Checkbox,
2650
+ Yr as Container,
2651
+ Nr as CopyTooltip,
2652
+ Zr as Counter,
2653
+ Ar as CurrencyName,
2654
+ ao as CurrencyRate,
2655
+ Xr as HamburgerButton,
2656
+ Vr as Informer,
2657
+ Ur as Loader,
2658
+ qr as RadioButton,
2659
+ lo as Requisites,
2660
+ Gt as SelectField,
2661
+ eo as Switcher,
2662
+ Kr as TabList,
2663
+ Qr as Table,
2664
+ $t as TextField,
2665
+ qt as Tooltip,
2666
+ so as TransactionStatus,
2667
+ v as Typography,
2668
+ Jr as UserAccount,
2669
+ Qt as copyToClipboard,
2670
+ Kt as formatCardNumber,
2671
+ Jt as maskEmail
2672
+ };