@deframe-sdk/components 0.1.10 → 0.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +91 -113
- package/dist/index.d.ts +91 -113
- package/dist/index.js +672 -747
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +674 -745
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1041 -934
- package/package.json +4 -1
package/dist/index.js
CHANGED
|
@@ -71,24 +71,30 @@ function ActionButton(_a) {
|
|
|
71
71
|
"className",
|
|
72
72
|
"type"
|
|
73
73
|
]);
|
|
74
|
-
const
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
74
|
+
const baseClasses = [
|
|
75
|
+
"flex-1 inline-flex items-center justify-center overflow-hidden",
|
|
76
|
+
"h-[var(--deframe-widget-font-leading-lg)]",
|
|
77
|
+
"px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)]",
|
|
78
|
+
"rounded-[var(--deframe-widget-size-radius-sm)]",
|
|
79
|
+
"border border-[color:var(--deframe-widget-color-border-tertiary)]",
|
|
80
|
+
"font-[var(--deframe-widget-font-family)] [font-size:var(--deframe-widget-font-size-lg)] [line-height:var(--deframe-widget-font-leading-lg)] [font-weight:var(--deframe-widget-font-weight-semibold)]",
|
|
81
|
+
"transition-[background,border-color,box-shadow,opacity] duration-200",
|
|
82
|
+
"focus:outline-none focus:ring-2 focus:ring-[color:var(--deframe-widget-color-brand-primary)]"
|
|
83
|
+
].join(" ");
|
|
84
|
+
const stateClasses = disabled ? [
|
|
85
|
+
"cursor-not-allowed",
|
|
86
|
+
"bg-[var(--deframe-widget-color-bg-tertiary)]",
|
|
87
|
+
"text-[color:var(--deframe-widget-color-text-primary-disabled)]"
|
|
88
|
+
].join(" ") : [
|
|
89
|
+
"cursor-pointer",
|
|
90
|
+
"bg-[var(--deframe-widget-color-brand-primary)]",
|
|
91
|
+
"text-[color:var(--deframe-widget-color-text-primary-dark)]",
|
|
92
|
+
"hover:opacity-90",
|
|
93
|
+
"hover:shadow-[0_2px_8px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_18%,transparent)]"
|
|
94
|
+
].join(" ");
|
|
89
95
|
const containerClasses = tailwindMerge.twMerge(
|
|
90
|
-
|
|
91
|
-
|
|
96
|
+
baseClasses,
|
|
97
|
+
stateClasses,
|
|
92
98
|
className
|
|
93
99
|
);
|
|
94
100
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -98,7 +104,7 @@ function ActionButton(_a) {
|
|
|
98
104
|
className: containerClasses,
|
|
99
105
|
disabled
|
|
100
106
|
}, props), {
|
|
101
|
-
children
|
|
107
|
+
children
|
|
102
108
|
})
|
|
103
109
|
);
|
|
104
110
|
}
|
|
@@ -115,7 +121,13 @@ function PercentageButton(_a) {
|
|
|
115
121
|
"type"
|
|
116
122
|
]);
|
|
117
123
|
const containerClasses = tailwindMerge.twMerge(
|
|
118
|
-
"flex-1
|
|
124
|
+
"flex-1 inline-flex items-center justify-center",
|
|
125
|
+
"px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)]",
|
|
126
|
+
"rounded-[var(--deframe-widget-size-radius-sm)]",
|
|
127
|
+
"border border-[color:var(--deframe-widget-color-border-tertiary)]",
|
|
128
|
+
"bg-[var(--deframe-widget-color-bg-tertiary)] text-[color:var(--deframe-widget-color-text-secondary)]",
|
|
129
|
+
"font-[var(--deframe-widget-font-family)] [font-size:var(--deframe-widget-font-size-lg)] [line-height:var(--deframe-widget-font-leading-lg)] [font-weight:var(--deframe-widget-font-weight-semibold)]",
|
|
130
|
+
"hover:border-[color:var(--deframe-widget-color-border-secondary)] focus:outline-none focus:ring-2 focus:ring-[color:var(--deframe-widget-color-brand-primary)]",
|
|
119
131
|
disabled && "cursor-not-allowed",
|
|
120
132
|
className
|
|
121
133
|
);
|
|
@@ -146,7 +158,7 @@ function PrimaryButton(_a) {
|
|
|
146
158
|
/** layout */
|
|
147
159
|
"overflow-hidden w-full flex items-center justify-center transition-all duration-200",
|
|
148
160
|
/** typography */
|
|
149
|
-
"font-[var(--deframe-widget-font-family
|
|
161
|
+
"font-[var(--deframe-widget-font-family)]",
|
|
150
162
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
151
163
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
152
164
|
"[font-weight:var(--deframe-widget-font-weight-semibold)]",
|
|
@@ -210,7 +222,7 @@ function SecondaryButton(_a) {
|
|
|
210
222
|
/** layout */
|
|
211
223
|
"overflow-hidden w-full flex items-center justify-center transition-all duration-200",
|
|
212
224
|
/** typography */
|
|
213
|
-
"font-[var(--deframe-widget-font-family
|
|
225
|
+
"font-[var(--deframe-widget-font-family)]",
|
|
214
226
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
215
227
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
216
228
|
"[font-weight:var(--deframe-widget-font-weight-semibold)]",
|
|
@@ -271,7 +283,7 @@ function TertiaryButton(_a) {
|
|
|
271
283
|
/** layout */
|
|
272
284
|
"overflow-hidden w-full flex items-center justify-center transition-all duration-200",
|
|
273
285
|
/** typography */
|
|
274
|
-
"font-[var(--deframe-widget-font-family
|
|
286
|
+
"font-[var(--deframe-widget-font-family)]",
|
|
275
287
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
276
288
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
277
289
|
"[font-weight:var(--deframe-widget-font-weight-semibold)]",
|
|
@@ -331,7 +343,7 @@ function Input(_a) {
|
|
|
331
343
|
function InputLabel(_a) {
|
|
332
344
|
var _b = _a, { className = "" } = _b, props = __objRest(_b, ["className"]);
|
|
333
345
|
const baseClasses = [
|
|
334
|
-
"[font-family:var(--deframe-widget-font-family
|
|
346
|
+
"[font-family:var(--deframe-widget-font-family)]",
|
|
335
347
|
"[font-size:var(--deframe-widget-font-size-xs)]",
|
|
336
348
|
"[font-weight:var(--deframe-widget-font-weight-medium)]",
|
|
337
349
|
"text-[var(--deframe-widget-color-text-primary)]"
|
|
@@ -349,7 +361,7 @@ function InputField(_a) {
|
|
|
349
361
|
var _b = _a, { hasError = false, disabled, className = "" } = _b, props = __objRest(_b, ["hasError", "disabled", "className"]);
|
|
350
362
|
const baseClasses = [
|
|
351
363
|
"w-full",
|
|
352
|
-
"[font-family:var(--deframe-widget-font-family
|
|
364
|
+
"[font-family:var(--deframe-widget-font-family)]",
|
|
353
365
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
354
366
|
"[font-weight:var(--deframe-widget-font-weight-regular)]",
|
|
355
367
|
"text-[var(--deframe-widget-color-text-primary)]",
|
|
@@ -405,19 +417,19 @@ function Link(_a) {
|
|
|
405
417
|
"scroll"
|
|
406
418
|
]);
|
|
407
419
|
const baseClasses = [
|
|
408
|
-
"[font-family:var(--deframe-widget-font-family
|
|
420
|
+
"[font-family:var(--deframe-widget-font-family)]",
|
|
409
421
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
410
422
|
"[font-weight:var(--deframe-widget-font-weight-medium)]",
|
|
411
423
|
"[line-height:var(--deframe-widget-font-leading-lg)]"
|
|
412
424
|
].join(" ");
|
|
413
425
|
const stateClasses = {
|
|
414
426
|
enabled: [
|
|
415
|
-
"text-[var(--deframe-widget-color-
|
|
427
|
+
"text-[color:var(--deframe-widget-color-brand-primary)]",
|
|
416
428
|
"underline",
|
|
417
429
|
"cursor-pointer"
|
|
418
430
|
].join(" "),
|
|
419
431
|
disabled: [
|
|
420
|
-
"text-[var(--deframe-widget-color-
|
|
432
|
+
"text-[var(--deframe-widget-color-brand-primary-disabled)]",
|
|
421
433
|
"cursor-not-allowed",
|
|
422
434
|
"pointer-events-none"
|
|
423
435
|
].join(" ")
|
|
@@ -495,7 +507,8 @@ function Input2(_a) {
|
|
|
495
507
|
className: "text-right",
|
|
496
508
|
children: /* @__PURE__ */ jsxRuntime.jsx(Link_default, { href, disabled, children: repassword })
|
|
497
509
|
}
|
|
498
|
-
)
|
|
510
|
+
),
|
|
511
|
+
error && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-[var(--deframe-widget-size-gap-xs)] text-[color:var(--deframe-widget-color-state-error)] [font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: error })
|
|
499
512
|
] });
|
|
500
513
|
}
|
|
501
514
|
function ListItem(_a) {
|
|
@@ -504,52 +517,32 @@ function ListItem(_a) {
|
|
|
504
517
|
className,
|
|
505
518
|
containerClassName,
|
|
506
519
|
onClick
|
|
507
|
-
} = _b
|
|
520
|
+
} = _b; __objRest(_b, [
|
|
508
521
|
"children",
|
|
509
522
|
"className",
|
|
510
523
|
"containerClassName",
|
|
511
524
|
"onClick"
|
|
512
525
|
]);
|
|
513
|
-
const baseClasses = [
|
|
514
|
-
"self-stretch min-h-16 relative",
|
|
515
|
-
"rounded-[var(--deframe-widget-size-radius-xs)]",
|
|
516
|
-
"border-[length:var(--deframe-widget-size-border-xs)]",
|
|
517
|
-
"border-[var(--deframe-widget-color-border-primary)]",
|
|
518
|
-
"flex flex-col justify-center items-center",
|
|
519
|
-
"transition-colors",
|
|
520
|
-
"bg-[var(--deframe-widget-color-bg-primary)]"
|
|
521
|
-
].join(" ");
|
|
522
|
-
const stateClasses = {
|
|
523
|
-
clickable: "cursor-pointer hover:border-[var(--deframe-widget-color-border-secondary)]",
|
|
524
|
-
static: ""
|
|
525
|
-
};
|
|
526
526
|
const containerClasses = tailwindMerge.twMerge(
|
|
527
|
-
|
|
528
|
-
|
|
527
|
+
"self-stretch min-h-16 relative rounded-[var(--deframe-widget-size-radius-sm)] border border-[color:var(--deframe-widget-color-border-secondary)]",
|
|
528
|
+
"text-[color:var(--deframe-widget-color-text-primary)] flex flex-col justify-center items-center transition-colors",
|
|
529
|
+
"hover:border-[color:var(--deframe-widget-color-border-primary)] bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
530
|
+
onClick && "cursor-pointer",
|
|
529
531
|
containerClassName
|
|
530
532
|
);
|
|
531
|
-
|
|
532
|
-
"
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
className: containerClasses,
|
|
545
|
-
onClick,
|
|
546
|
-
tabIndex: onClick ? 0 : void 0,
|
|
547
|
-
role: onClick ? "button" : void 0,
|
|
548
|
-
onKeyDown: onClick ? (e) => e.key === "Enter" && onClick() : void 0
|
|
549
|
-
}, props), {
|
|
550
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: innerClasses, children })
|
|
551
|
-
})
|
|
552
|
-
);
|
|
533
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: containerClasses, onClick, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
534
|
+
"div",
|
|
535
|
+
{
|
|
536
|
+
className: tailwindMerge.twMerge(
|
|
537
|
+
"self-stretch inline-flex justify-between items-center",
|
|
538
|
+
"gap-[var(--deframe-widget-size-gap-md)]",
|
|
539
|
+
"px-[var(--deframe-widget-size-padding-x-lg)] py-[var(--deframe-widget-size-padding-y-sm)]",
|
|
540
|
+
"text-[color:var(--deframe-widget-color-text-primary)]",
|
|
541
|
+
className
|
|
542
|
+
),
|
|
543
|
+
children
|
|
544
|
+
}
|
|
545
|
+
) });
|
|
553
546
|
}
|
|
554
547
|
function ListItemLeftSide(_a) {
|
|
555
548
|
var _b = _a, { children, className } = _b, props = __objRest(_b, ["children", "className"]);
|
|
@@ -606,7 +599,292 @@ function WalletListContainer({
|
|
|
606
599
|
children,
|
|
607
600
|
className
|
|
608
601
|
}) {
|
|
609
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
602
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
603
|
+
"div",
|
|
604
|
+
{
|
|
605
|
+
"data-slot": "wallet-list-container",
|
|
606
|
+
className: tailwindMerge.twMerge("w-full flex flex-col gap-[var(--deframe-widget-size-gap-sm)]", className),
|
|
607
|
+
children
|
|
608
|
+
}
|
|
609
|
+
);
|
|
610
|
+
}
|
|
611
|
+
function WalletItem({
|
|
612
|
+
id,
|
|
613
|
+
name,
|
|
614
|
+
icon,
|
|
615
|
+
onClick,
|
|
616
|
+
className
|
|
617
|
+
}) {
|
|
618
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
619
|
+
"button",
|
|
620
|
+
{
|
|
621
|
+
"data-slot": "wallet-item",
|
|
622
|
+
"data-test-id": "wallet-item",
|
|
623
|
+
"aria-label": `Connect ${name} wallet`,
|
|
624
|
+
onClick,
|
|
625
|
+
className: tailwindMerge.twMerge(
|
|
626
|
+
"w-full flex items-center gap-[var(--deframe-widget-size-gap-sm)] px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)]",
|
|
627
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] border border-[color:var(--deframe-widget-color-border-secondary)]",
|
|
628
|
+
"rounded-[var(--deframe-widget-size-radius-sm)]",
|
|
629
|
+
"hover:bg-[color:color-mix(in_srgb,var(--deframe-widget-color-bg-secondary)_72%,transparent)] active:scale-[0.99]",
|
|
630
|
+
"transition-[background,border-color] duration-150",
|
|
631
|
+
"cursor-pointer outline-none text-left",
|
|
632
|
+
"font-[var(--deframe-widget-font-family)]",
|
|
633
|
+
className
|
|
634
|
+
),
|
|
635
|
+
children: [
|
|
636
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
637
|
+
"div",
|
|
638
|
+
{
|
|
639
|
+
"data-slot": "wallet-item-icon",
|
|
640
|
+
"data-test-id": "wallet-item-icon",
|
|
641
|
+
className: "shrink-0 w-12 h-12 rounded-[var(--deframe-widget-size-radius-full)] overflow-hidden flex items-center justify-center",
|
|
642
|
+
children: typeof icon === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
643
|
+
"img",
|
|
644
|
+
{
|
|
645
|
+
src: icon,
|
|
646
|
+
alt: name,
|
|
647
|
+
className: "object-cover w-full h-full"
|
|
648
|
+
}
|
|
649
|
+
) : icon
|
|
650
|
+
}
|
|
651
|
+
),
|
|
652
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 text-[17px] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-primary)] leading-[1.3] [font-family:inherit]", children: name }),
|
|
653
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
654
|
+
"svg",
|
|
655
|
+
{
|
|
656
|
+
"data-slot": "wallet-item-chevron",
|
|
657
|
+
"data-test-id": "wallet-item-chevron",
|
|
658
|
+
fill: "none",
|
|
659
|
+
"aria-hidden": "true",
|
|
660
|
+
className: "flex-shrink-0 text-(--deframe-widget-color-text-secondary)",
|
|
661
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
662
|
+
"path",
|
|
663
|
+
{
|
|
664
|
+
d: "M7.5 5L12.5 10L7.5 15",
|
|
665
|
+
stroke: "currentColor",
|
|
666
|
+
strokeWidth: "1.5",
|
|
667
|
+
strokeLinecap: "round",
|
|
668
|
+
strokeLinejoin: "round"
|
|
669
|
+
}
|
|
670
|
+
)
|
|
671
|
+
}
|
|
672
|
+
)
|
|
673
|
+
]
|
|
674
|
+
},
|
|
675
|
+
id
|
|
676
|
+
);
|
|
677
|
+
}
|
|
678
|
+
function ConnectWalletList({
|
|
679
|
+
wallets,
|
|
680
|
+
title,
|
|
681
|
+
subtitle,
|
|
682
|
+
className
|
|
683
|
+
}) {
|
|
684
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
685
|
+
"div",
|
|
686
|
+
{
|
|
687
|
+
"data-slot": "connect-wallet-list",
|
|
688
|
+
className: tailwindMerge.twMerge("w-full flex flex-col gap-[var(--deframe-widget-size-gap-md)]", className),
|
|
689
|
+
children: [
|
|
690
|
+
(title != null || subtitle != null) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
691
|
+
title != null && /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-[color:var(--deframe-widget-color-text-primary)] text-[20px] [font-weight:var(--deframe-widget-font-weight-bold)] leading-[1.25] font-[var(--deframe-widget-font-family)]", children: title }),
|
|
692
|
+
subtitle != null && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[color:var(--deframe-widget-color-text-secondary)] text-[14px] leading-[1.5] font-[var(--deframe-widget-font-family)]", children: subtitle })
|
|
693
|
+
] }),
|
|
694
|
+
/* @__PURE__ */ jsxRuntime.jsx(WalletListContainer, { children: wallets.map((wallet) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
695
|
+
WalletItem,
|
|
696
|
+
{
|
|
697
|
+
id: wallet.id,
|
|
698
|
+
name: wallet.name,
|
|
699
|
+
icon: wallet.icon,
|
|
700
|
+
onClick: () => {
|
|
701
|
+
var _a;
|
|
702
|
+
return (_a = wallet.onClick) == null ? void 0 : _a.call(wallet);
|
|
703
|
+
}
|
|
704
|
+
},
|
|
705
|
+
wallet.id
|
|
706
|
+
)) })
|
|
707
|
+
]
|
|
708
|
+
}
|
|
709
|
+
);
|
|
710
|
+
}
|
|
711
|
+
function WalletConnectPanel({
|
|
712
|
+
wallets,
|
|
713
|
+
title,
|
|
714
|
+
subtitle,
|
|
715
|
+
onClose,
|
|
716
|
+
className
|
|
717
|
+
}) {
|
|
718
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
719
|
+
"div",
|
|
720
|
+
{
|
|
721
|
+
"data-slot": "wallet-connect-panel",
|
|
722
|
+
"data-test-id": "wallet-connect-panel",
|
|
723
|
+
className: tailwindMerge.twMerge(
|
|
724
|
+
"w-full flex flex-col gap-[var(--deframe-widget-size-gap-md)] px-[var(--deframe-widget-size-padding-x-lg)] py-[var(--deframe-widget-size-padding-y-lg)]",
|
|
725
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] border border-[color:var(--deframe-widget-color-border-secondary)]",
|
|
726
|
+
"rounded-[var(--deframe-widget-size-radius-md)]",
|
|
727
|
+
"font-[var(--deframe-widget-font-family)]",
|
|
728
|
+
className
|
|
729
|
+
),
|
|
730
|
+
children: [
|
|
731
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-[var(--deframe-widget-size-gap-md)]", children: [
|
|
732
|
+
/* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-[color:var(--deframe-widget-color-text-primary)] text-[20px] [font-weight:var(--deframe-widget-font-weight-bold)] leading-[1.25] [font-family:inherit]", children: title != null ? title : "Conectar Carteira" }),
|
|
733
|
+
onClose != null && /* @__PURE__ */ jsxRuntime.jsx(
|
|
734
|
+
"button",
|
|
735
|
+
{
|
|
736
|
+
type: "button",
|
|
737
|
+
"data-slot": "wallet-connect-close",
|
|
738
|
+
"data-test-id": "wallet-connect-close",
|
|
739
|
+
onClick: onClose,
|
|
740
|
+
className: tailwindMerge.twMerge(
|
|
741
|
+
"text-[color:var(--deframe-widget-color-text-secondary)] text-[15px] [font-weight:var(--deframe-widget-font-weight-medium)] leading-none",
|
|
742
|
+
"hover:text-[color:var(--deframe-widget-color-text-primary)] transition-colors duration-150",
|
|
743
|
+
"cursor-pointer outline-none bg-transparent border-none px-[var(--deframe-widget-size-padding-x-none)] py-[var(--deframe-widget-size-padding-y-none)]",
|
|
744
|
+
"flex-shrink-0 [font-family:inherit]"
|
|
745
|
+
),
|
|
746
|
+
children: "Sair"
|
|
747
|
+
}
|
|
748
|
+
)
|
|
749
|
+
] }),
|
|
750
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[color:var(--deframe-widget-color-text-secondary)] text-[14px] leading-[1.5] [font-family:inherit] -mt-[var(--deframe-widget-size-gap-sm)]", children: subtitle != null ? subtitle : "Escolha sua carteira preferida para conectar" }),
|
|
751
|
+
/* @__PURE__ */ jsxRuntime.jsx(WalletListContainer, { children: wallets.map((wallet) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
752
|
+
WalletItem,
|
|
753
|
+
{
|
|
754
|
+
id: wallet.id,
|
|
755
|
+
name: wallet.name,
|
|
756
|
+
icon: wallet.icon,
|
|
757
|
+
onClick: () => {
|
|
758
|
+
var _a;
|
|
759
|
+
return (_a = wallet.onClick) == null ? void 0 : _a.call(wallet);
|
|
760
|
+
}
|
|
761
|
+
},
|
|
762
|
+
wallet.id
|
|
763
|
+
)) })
|
|
764
|
+
]
|
|
765
|
+
}
|
|
766
|
+
);
|
|
767
|
+
}
|
|
768
|
+
var CURRENCY_CONFIG = {
|
|
769
|
+
symbols: {
|
|
770
|
+
USD: "$",
|
|
771
|
+
BRL: "R$",
|
|
772
|
+
EUR: "\u20AC",
|
|
773
|
+
BTC: "\u20BF",
|
|
774
|
+
ETH: "\u039E",
|
|
775
|
+
USDC: "$",
|
|
776
|
+
USDT: "$"
|
|
777
|
+
},
|
|
778
|
+
labels: {
|
|
779
|
+
USD: "USD",
|
|
780
|
+
BRL: "BRL",
|
|
781
|
+
EUR: "EUR",
|
|
782
|
+
BTC: "BTC",
|
|
783
|
+
ETH: "ETH",
|
|
784
|
+
USDC: "USDC",
|
|
785
|
+
USDT: "USDT"
|
|
786
|
+
}
|
|
787
|
+
};
|
|
788
|
+
var STYLE_CONFIG = {
|
|
789
|
+
alignment: {
|
|
790
|
+
left: "items-start",
|
|
791
|
+
center: "items-center",
|
|
792
|
+
right: "items-end"
|
|
793
|
+
},
|
|
794
|
+
size: {
|
|
795
|
+
sm: {
|
|
796
|
+
primary: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)]",
|
|
797
|
+
secondary: "[font-size:var(--deframe-widget-font-size-lg)] [line-height:var(--deframe-widget-font-leading-lg)]",
|
|
798
|
+
gap: "gap-[var(--deframe-widget-size-gap-xs)]"
|
|
799
|
+
},
|
|
800
|
+
md: {
|
|
801
|
+
primary: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)]",
|
|
802
|
+
secondary: "[font-size:var(--deframe-widget-font-size-xl)] [line-height:var(--deframe-widget-font-leading-xl)]",
|
|
803
|
+
gap: "gap-[var(--deframe-widget-size-gap-xs)]"
|
|
804
|
+
},
|
|
805
|
+
lg: {
|
|
806
|
+
primary: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)]",
|
|
807
|
+
secondary: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)]",
|
|
808
|
+
gap: "gap-[var(--deframe-widget-size-gap-xs)]"
|
|
809
|
+
}
|
|
810
|
+
}
|
|
811
|
+
};
|
|
812
|
+
function Currency(props) {
|
|
813
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
814
|
+
const normalizedProps = "usdValue" in props ? {
|
|
815
|
+
amount: props.amount,
|
|
816
|
+
currency: "USD",
|
|
817
|
+
secondaryAmount: props.usdValue,
|
|
818
|
+
secondaryCurrency: void 0,
|
|
819
|
+
align: (_a = props.align) != null ? _a : "right",
|
|
820
|
+
size: (_b = props.size) != null ? _b : "lg",
|
|
821
|
+
showSymbol: false,
|
|
822
|
+
showLabel: false,
|
|
823
|
+
className: (_c = props.className) != null ? _c : ""
|
|
824
|
+
} : {
|
|
825
|
+
amount: props.amount,
|
|
826
|
+
currency: (_d = props.currency) != null ? _d : "USD",
|
|
827
|
+
secondaryAmount: props.secondaryAmount,
|
|
828
|
+
secondaryCurrency: props.secondaryCurrency,
|
|
829
|
+
align: (_e = props.align) != null ? _e : "right",
|
|
830
|
+
size: (_f = props.size) != null ? _f : "lg",
|
|
831
|
+
showSymbol: (_g = props.showSymbol) != null ? _g : true,
|
|
832
|
+
showLabel: (_h = props.showLabel) != null ? _h : false,
|
|
833
|
+
className: (_i = props.className) != null ? _i : ""
|
|
834
|
+
};
|
|
835
|
+
const {
|
|
836
|
+
amount,
|
|
837
|
+
currency,
|
|
838
|
+
secondaryAmount,
|
|
839
|
+
secondaryCurrency,
|
|
840
|
+
align,
|
|
841
|
+
size,
|
|
842
|
+
showSymbol,
|
|
843
|
+
showLabel,
|
|
844
|
+
className
|
|
845
|
+
} = normalizedProps;
|
|
846
|
+
const formatAmount = (value, curr, displaySymbol) => {
|
|
847
|
+
if (!displaySymbol && !showLabel) return value;
|
|
848
|
+
const symbol = displaySymbol ? CURRENCY_CONFIG.symbols[curr] : "";
|
|
849
|
+
const label = showLabel ? ` ${CURRENCY_CONFIG.labels[curr]}` : "";
|
|
850
|
+
if (["BTC", "ETH"].includes(curr) && !value.includes(".") && !value.includes(",")) {
|
|
851
|
+
return `${symbol}${value}${label}`;
|
|
852
|
+
}
|
|
853
|
+
return `${symbol} ${value}${label}`.trim();
|
|
854
|
+
};
|
|
855
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
856
|
+
"div",
|
|
857
|
+
{
|
|
858
|
+
className: tailwindMerge.twMerge(
|
|
859
|
+
"flex flex-col",
|
|
860
|
+
STYLE_CONFIG.alignment[align],
|
|
861
|
+
STYLE_CONFIG.size[size].gap,
|
|
862
|
+
className
|
|
863
|
+
),
|
|
864
|
+
children: [
|
|
865
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
866
|
+
"div",
|
|
867
|
+
{
|
|
868
|
+
className: tailwindMerge.twMerge(
|
|
869
|
+
"[font-weight:var(--deframe-widget-font-weight-bold)] text-[color:var(--deframe-widget-color-text-primary)] font-[var(--deframe-widget-font-family)]",
|
|
870
|
+
STYLE_CONFIG.size[size].primary
|
|
871
|
+
),
|
|
872
|
+
children: formatAmount(amount, currency, showSymbol)
|
|
873
|
+
}
|
|
874
|
+
),
|
|
875
|
+
secondaryAmount && /* @__PURE__ */ jsxRuntime.jsx(
|
|
876
|
+
"div",
|
|
877
|
+
{
|
|
878
|
+
className: tailwindMerge.twMerge(
|
|
879
|
+
"text-[color:var(--deframe-widget-color-text-secondary)] font-[var(--deframe-widget-font-family)]",
|
|
880
|
+
STYLE_CONFIG.size[size].secondary
|
|
881
|
+
),
|
|
882
|
+
children: secondaryCurrency ? formatAmount(secondaryAmount, secondaryCurrency, true) : secondaryAmount
|
|
883
|
+
}
|
|
884
|
+
)
|
|
885
|
+
]
|
|
886
|
+
}
|
|
887
|
+
);
|
|
610
888
|
}
|
|
611
889
|
var Text = React6__namespace.forwardRef(
|
|
612
890
|
(_a, ref) => {
|
|
@@ -620,7 +898,7 @@ var Text = React6__namespace.forwardRef(
|
|
|
620
898
|
"className"
|
|
621
899
|
]);
|
|
622
900
|
const baseClasses = [
|
|
623
|
-
"[font-family:var(--deframe-widget-font-family
|
|
901
|
+
"[font-family:var(--deframe-widget-font-family)]",
|
|
624
902
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
625
903
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
626
904
|
"[font-weight:var(--deframe-widget-font-weight-regular)]",
|
|
@@ -658,12 +936,12 @@ var TextAccent = React6__namespace.forwardRef(
|
|
|
658
936
|
].join(" "),
|
|
659
937
|
"accent-medium": [
|
|
660
938
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
661
|
-
"[line-height:var(--deframe-widget-font-leading-
|
|
939
|
+
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
662
940
|
"[font-weight:var(--deframe-widget-font-weight-semibold)]"
|
|
663
941
|
].join(" "),
|
|
664
942
|
"accent-small": [
|
|
665
943
|
"[font-size:var(--deframe-widget-font-size-sm)]",
|
|
666
|
-
"[line-height:var(--deframe-widget-font-leading-
|
|
944
|
+
"[line-height:var(--deframe-widget-font-leading-sm)]",
|
|
667
945
|
"[font-weight:var(--deframe-widget-font-weight-semibold)]"
|
|
668
946
|
].join(" ")
|
|
669
947
|
};
|
|
@@ -694,6 +972,11 @@ var TextBody = React6__namespace.forwardRef(
|
|
|
694
972
|
"className"
|
|
695
973
|
]);
|
|
696
974
|
const bodyVariants = {
|
|
975
|
+
"[font-size:var(--deframe-widget-font-size-lg)] [line-height:var(--deframe-widget-font-leading-lg)]": [
|
|
976
|
+
"[font-size:var(--deframe-widget-font-size-lg)]",
|
|
977
|
+
"[line-height:var(--deframe-widget-font-leading-lg)]",
|
|
978
|
+
"[font-weight:var(--deframe-widget-font-weight-regular)]"
|
|
979
|
+
].join(" "),
|
|
697
980
|
"text-large": [
|
|
698
981
|
"[font-size:var(--deframe-widget-font-size-lg)]",
|
|
699
982
|
"[line-height:var(--deframe-widget-font-leading-lg)]",
|
|
@@ -701,12 +984,12 @@ var TextBody = React6__namespace.forwardRef(
|
|
|
701
984
|
].join(" "),
|
|
702
985
|
"text-medium": [
|
|
703
986
|
"[font-size:var(--deframe-widget-font-size-md)]",
|
|
704
|
-
"[line-height:var(--deframe-widget-font-leading-
|
|
987
|
+
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
705
988
|
"[font-weight:var(--deframe-widget-font-weight-regular)]"
|
|
706
989
|
].join(" "),
|
|
707
990
|
"text-small": [
|
|
708
991
|
"[font-size:var(--deframe-widget-font-size-sm)]",
|
|
709
|
-
"[line-height:var(--deframe-widget-font-leading-
|
|
992
|
+
"[line-height:var(--deframe-widget-font-leading-sm)]",
|
|
710
993
|
"[font-weight:var(--deframe-widget-font-weight-regular)]"
|
|
711
994
|
].join(" ")
|
|
712
995
|
};
|
|
@@ -738,32 +1021,32 @@ var TextHeading = React6__namespace.forwardRef(
|
|
|
738
1021
|
]);
|
|
739
1022
|
const headingVariants = {
|
|
740
1023
|
"h-large": [
|
|
741
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1024
|
+
"[font-size:var(--deframe-widget-font-size-xxl)]",
|
|
742
1025
|
"[line-height:var(--deframe-widget-font-leading-sm)]",
|
|
743
1026
|
"[font-weight:var(--deframe-widget-font-weight-extrabold)]"
|
|
744
1027
|
].join(" "),
|
|
745
1028
|
h1: [
|
|
746
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1029
|
+
"[font-size:var(--deframe-widget-font-size-xxl)]",
|
|
747
1030
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
748
1031
|
"[font-weight:var(--deframe-widget-font-weight-extrabold)]"
|
|
749
1032
|
].join(" "),
|
|
750
1033
|
h2: [
|
|
751
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1034
|
+
"[font-size:var(--deframe-widget-font-size-xxl)]",
|
|
752
1035
|
"[line-height:var(--deframe-widget-font-leading-lg)]",
|
|
753
1036
|
"[font-weight:var(--deframe-widget-font-weight-extrabold)]"
|
|
754
1037
|
].join(" "),
|
|
755
1038
|
h3: [
|
|
756
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1039
|
+
"[font-size:var(--deframe-widget-font-size-xl)]",
|
|
757
1040
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
758
1041
|
"[font-weight:var(--deframe-widget-font-weight-bold)]"
|
|
759
1042
|
].join(" "),
|
|
760
1043
|
h4: [
|
|
761
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1044
|
+
"[font-size:var(--deframe-widget-font-size-xl)]",
|
|
762
1045
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
763
1046
|
"[font-weight:var(--deframe-widget-font-weight-bold)]"
|
|
764
1047
|
].join(" "),
|
|
765
1048
|
h5: [
|
|
766
|
-
"[font-size:var(--deframe-widget-font-size-
|
|
1049
|
+
"[font-size:var(--deframe-widget-font-size-lg)]",
|
|
767
1050
|
"[line-height:var(--deframe-widget-font-leading-md)]",
|
|
768
1051
|
"[font-weight:var(--deframe-widget-font-weight-bold)]"
|
|
769
1052
|
].join(" ")
|
|
@@ -794,232 +1077,6 @@ function Title(_a) {
|
|
|
794
1077
|
]);
|
|
795
1078
|
return /* @__PURE__ */ jsxRuntime.jsx(TextHeading_default, __spreadValues({ variant, className }, props));
|
|
796
1079
|
}
|
|
797
|
-
function ConnectWalletList({
|
|
798
|
-
wallets,
|
|
799
|
-
className
|
|
800
|
-
}) {
|
|
801
|
-
const handleWalletClick = (wallet) => {
|
|
802
|
-
var _a;
|
|
803
|
-
(_a = wallet.onClick) == null ? void 0 : _a.call(wallet);
|
|
804
|
-
};
|
|
805
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: tailwindMerge.twMerge("w-full", className), children: /* @__PURE__ */ jsxRuntime.jsx(WalletListContainer, { children: wallets.map((wallet) => /* @__PURE__ */ jsxRuntime.jsxs(ListItem, { onClick: () => handleWalletClick(wallet), children: [
|
|
806
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemLeftSide, { children: typeof wallet.icon === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
807
|
-
"img",
|
|
808
|
-
{
|
|
809
|
-
src: wallet.icon,
|
|
810
|
-
alt: wallet.name,
|
|
811
|
-
className: "w-10 h-10 rounded-full"
|
|
812
|
-
}
|
|
813
|
-
) : wallet.icon }),
|
|
814
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemContent, { children: /* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "text-medium", children: wallet.name }) }),
|
|
815
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemRightSide, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
816
|
-
"svg",
|
|
817
|
-
{
|
|
818
|
-
className: "flex-shrink-0 w-5 h-5 text-gray-400",
|
|
819
|
-
fill: "none",
|
|
820
|
-
viewBox: "0 0 24 24",
|
|
821
|
-
stroke: "currentColor",
|
|
822
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
823
|
-
"path",
|
|
824
|
-
{
|
|
825
|
-
strokeLinecap: "round",
|
|
826
|
-
strokeLinejoin: "round",
|
|
827
|
-
strokeWidth: 2,
|
|
828
|
-
d: "M9 5l7 7-7 7"
|
|
829
|
-
}
|
|
830
|
-
)
|
|
831
|
-
}
|
|
832
|
-
) })
|
|
833
|
-
] }, wallet.id)) }) });
|
|
834
|
-
}
|
|
835
|
-
function WalletItem({
|
|
836
|
-
id,
|
|
837
|
-
name,
|
|
838
|
-
icon,
|
|
839
|
-
onClick,
|
|
840
|
-
className
|
|
841
|
-
}) {
|
|
842
|
-
const baseClasses = [
|
|
843
|
-
"w-full flex items-center",
|
|
844
|
-
"[gap:var(--deframe-widget-size-gap-md)]",
|
|
845
|
-
"px-[var(--deframe-widget-size-padding-x-md)]",
|
|
846
|
-
"py-[var(--deframe-widget-size-padding-y-sm)]",
|
|
847
|
-
"rounded-[var(--deframe-widget-size-radius-xs)]",
|
|
848
|
-
"bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
849
|
-
"cursor-pointer",
|
|
850
|
-
"transition-colors",
|
|
851
|
-
"hover:bg-[var(--deframe-widget-color-bg-tertiary)]",
|
|
852
|
-
"focus:outline-none"
|
|
853
|
-
].join(" ");
|
|
854
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
855
|
-
"button",
|
|
856
|
-
{
|
|
857
|
-
"data-slot": "wallet-item",
|
|
858
|
-
"data-test-id": "wallet-item",
|
|
859
|
-
"aria-label": `Connect ${name} wallet`,
|
|
860
|
-
onClick,
|
|
861
|
-
className: tailwindMerge.twMerge(baseClasses, className),
|
|
862
|
-
children: [
|
|
863
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
864
|
-
"div",
|
|
865
|
-
{
|
|
866
|
-
"data-slot": "wallet-item-icon",
|
|
867
|
-
"data-test-id": "wallet-item-icon",
|
|
868
|
-
className: "flex-shrink-0 w-12 h-12 rounded-[var(--deframe-widget-size-radius-full)] overflow-hidden flex items-center justify-center",
|
|
869
|
-
children: typeof icon === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
870
|
-
"img",
|
|
871
|
-
{
|
|
872
|
-
src: icon,
|
|
873
|
-
alt: name,
|
|
874
|
-
className: "w-full h-full object-cover"
|
|
875
|
-
}
|
|
876
|
-
) : icon
|
|
877
|
-
}
|
|
878
|
-
),
|
|
879
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
880
|
-
TextBody,
|
|
881
|
-
{
|
|
882
|
-
"data-slot": "wallet-item-name",
|
|
883
|
-
"data-test-id": "wallet-item-name",
|
|
884
|
-
variant: "text-medium",
|
|
885
|
-
className: "flex-1 text-left text-[var(--deframe-widget-color-text-primary)]",
|
|
886
|
-
children: name
|
|
887
|
-
}
|
|
888
|
-
),
|
|
889
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
890
|
-
"svg",
|
|
891
|
-
{
|
|
892
|
-
"data-slot": "wallet-item-chevron",
|
|
893
|
-
"data-test-id": "wallet-item-chevron",
|
|
894
|
-
className: "flex-shrink-0 w-5 h-5 text-[var(--deframe-widget-color-text-secondary)]",
|
|
895
|
-
fill: "none",
|
|
896
|
-
viewBox: "0 0 24 24",
|
|
897
|
-
stroke: "currentColor",
|
|
898
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
899
|
-
"path",
|
|
900
|
-
{
|
|
901
|
-
strokeLinecap: "round",
|
|
902
|
-
strokeLinejoin: "round",
|
|
903
|
-
strokeWidth: 2,
|
|
904
|
-
d: "M9 5l7 7-7 7"
|
|
905
|
-
}
|
|
906
|
-
)
|
|
907
|
-
}
|
|
908
|
-
)
|
|
909
|
-
]
|
|
910
|
-
},
|
|
911
|
-
id
|
|
912
|
-
);
|
|
913
|
-
}
|
|
914
|
-
var CURRENCY_CONFIG = {
|
|
915
|
-
symbols: {
|
|
916
|
-
USD: "$",
|
|
917
|
-
BRL: "R$",
|
|
918
|
-
EUR: "\u20AC",
|
|
919
|
-
BTC: "\u20BF",
|
|
920
|
-
ETH: "\u039E",
|
|
921
|
-
USDC: "$",
|
|
922
|
-
USDT: "$"
|
|
923
|
-
},
|
|
924
|
-
labels: {
|
|
925
|
-
USD: "USD",
|
|
926
|
-
BRL: "BRL",
|
|
927
|
-
EUR: "EUR",
|
|
928
|
-
BTC: "BTC",
|
|
929
|
-
ETH: "ETH",
|
|
930
|
-
USDC: "USDC",
|
|
931
|
-
USDT: "USDT"
|
|
932
|
-
}
|
|
933
|
-
};
|
|
934
|
-
var STYLE_CONFIG = {
|
|
935
|
-
alignment: {
|
|
936
|
-
left: "items-start",
|
|
937
|
-
center: "items-center",
|
|
938
|
-
right: "items-end"
|
|
939
|
-
},
|
|
940
|
-
size: {
|
|
941
|
-
sm: { primary: "text-3xl", secondary: "text-sm", gap: "gap-0.5" },
|
|
942
|
-
md: { primary: "text-5xl", secondary: "text-base", gap: "gap-1" },
|
|
943
|
-
lg: { primary: "text-6xl", secondary: "text-lg", gap: "gap-1" }
|
|
944
|
-
}
|
|
945
|
-
};
|
|
946
|
-
function Currency(props) {
|
|
947
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
948
|
-
const normalizedProps = "usdValue" in props ? {
|
|
949
|
-
amount: props.amount,
|
|
950
|
-
currency: "USD",
|
|
951
|
-
secondaryAmount: props.usdValue,
|
|
952
|
-
secondaryCurrency: void 0,
|
|
953
|
-
align: (_a = props.align) != null ? _a : "right",
|
|
954
|
-
size: (_b = props.size) != null ? _b : "lg",
|
|
955
|
-
showSymbol: false,
|
|
956
|
-
showLabel: false,
|
|
957
|
-
className: (_c = props.className) != null ? _c : ""
|
|
958
|
-
} : {
|
|
959
|
-
amount: props.amount,
|
|
960
|
-
currency: (_d = props.currency) != null ? _d : "USD",
|
|
961
|
-
secondaryAmount: props.secondaryAmount,
|
|
962
|
-
secondaryCurrency: props.secondaryCurrency,
|
|
963
|
-
align: (_e = props.align) != null ? _e : "right",
|
|
964
|
-
size: (_f = props.size) != null ? _f : "lg",
|
|
965
|
-
showSymbol: (_g = props.showSymbol) != null ? _g : true,
|
|
966
|
-
showLabel: (_h = props.showLabel) != null ? _h : false,
|
|
967
|
-
className: (_i = props.className) != null ? _i : ""
|
|
968
|
-
};
|
|
969
|
-
const {
|
|
970
|
-
amount,
|
|
971
|
-
currency,
|
|
972
|
-
secondaryAmount,
|
|
973
|
-
secondaryCurrency,
|
|
974
|
-
align,
|
|
975
|
-
size,
|
|
976
|
-
showSymbol,
|
|
977
|
-
showLabel,
|
|
978
|
-
className
|
|
979
|
-
} = normalizedProps;
|
|
980
|
-
const formatAmount = (value, curr, displaySymbol) => {
|
|
981
|
-
if (!displaySymbol && !showLabel) return value;
|
|
982
|
-
const symbol = displaySymbol ? CURRENCY_CONFIG.symbols[curr] : "";
|
|
983
|
-
const label = showLabel ? ` ${CURRENCY_CONFIG.labels[curr]}` : "";
|
|
984
|
-
if (["BTC", "ETH"].includes(curr) && !value.includes(".") && !value.includes(",")) {
|
|
985
|
-
return `${symbol}${value}${label}`;
|
|
986
|
-
}
|
|
987
|
-
return `${symbol} ${value}${label}`.trim();
|
|
988
|
-
};
|
|
989
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
990
|
-
"div",
|
|
991
|
-
{
|
|
992
|
-
className: tailwindMerge.twMerge(
|
|
993
|
-
"flex flex-col",
|
|
994
|
-
STYLE_CONFIG.alignment[align],
|
|
995
|
-
STYLE_CONFIG.size[size].gap,
|
|
996
|
-
className
|
|
997
|
-
),
|
|
998
|
-
children: [
|
|
999
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1000
|
-
"div",
|
|
1001
|
-
{
|
|
1002
|
-
className: tailwindMerge.twMerge(
|
|
1003
|
-
"font-bold text-text-primary dark:text-text-primary-dark font-poppins",
|
|
1004
|
-
STYLE_CONFIG.size[size].primary
|
|
1005
|
-
),
|
|
1006
|
-
children: formatAmount(amount, currency, showSymbol)
|
|
1007
|
-
}
|
|
1008
|
-
),
|
|
1009
|
-
secondaryAmount && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1010
|
-
"div",
|
|
1011
|
-
{
|
|
1012
|
-
className: tailwindMerge.twMerge(
|
|
1013
|
-
"text-text-secondary dark:text-text-secondary-dark font-poppins",
|
|
1014
|
-
STYLE_CONFIG.size[size].secondary
|
|
1015
|
-
),
|
|
1016
|
-
children: secondaryCurrency ? formatAmount(secondaryAmount, secondaryCurrency, true) : secondaryAmount
|
|
1017
|
-
}
|
|
1018
|
-
)
|
|
1019
|
-
]
|
|
1020
|
-
}
|
|
1021
|
-
);
|
|
1022
|
-
}
|
|
1023
1080
|
var TabsContext = React6__namespace.createContext(
|
|
1024
1081
|
void 0
|
|
1025
1082
|
);
|
|
@@ -1079,14 +1136,12 @@ var TabsList = React6__namespace.forwardRef(
|
|
|
1079
1136
|
ref,
|
|
1080
1137
|
role: "tablist",
|
|
1081
1138
|
className: tailwindMerge.twMerge(
|
|
1082
|
-
"relative w-full flex items-center justify-between
|
|
1139
|
+
"relative w-full flex items-center justify-between",
|
|
1140
|
+
"pt-[var(--deframe-widget-size-padding-y-sm)]",
|
|
1141
|
+
"px-[var(--deframe-widget-size-padding-x-lg)]",
|
|
1142
|
+
"bg-[var(--deframe-widget-color-bg-primary)]",
|
|
1083
1143
|
className
|
|
1084
|
-
)
|
|
1085
|
-
style: {
|
|
1086
|
-
paddingLeft: "var(--spacing-md, 16px)",
|
|
1087
|
-
paddingRight: "var(--spacing-md, 16px)",
|
|
1088
|
-
backgroundColor: "var(--color-bg-default, transparent)"
|
|
1089
|
-
}
|
|
1144
|
+
)
|
|
1090
1145
|
}, props), {
|
|
1091
1146
|
children
|
|
1092
1147
|
})
|
|
@@ -1098,8 +1153,8 @@ var TabsList = React6__namespace.forwardRef(
|
|
|
1098
1153
|
ref,
|
|
1099
1154
|
role: "tablist",
|
|
1100
1155
|
className: tailwindMerge.twMerge(
|
|
1101
|
-
"relative w-full flex items-center bg-transparent border-b border-
|
|
1102
|
-
variant === "primary" ? "h-[72px] gap-
|
|
1156
|
+
"relative w-full flex items-center bg-transparent border-b border-[color:var(--deframe-widget-color-border-secondary)]",
|
|
1157
|
+
variant === "primary" ? "h-[72px] gap-[var(--deframe-widget-size-gap-lg)]" : "h-12",
|
|
1103
1158
|
className
|
|
1104
1159
|
)
|
|
1105
1160
|
}, props), {
|
|
@@ -1114,19 +1169,14 @@ var TabsTrigger = React6__namespace.forwardRef(
|
|
|
1114
1169
|
var _b = _a, {
|
|
1115
1170
|
value,
|
|
1116
1171
|
className,
|
|
1117
|
-
children
|
|
1118
|
-
style
|
|
1172
|
+
children
|
|
1119
1173
|
} = _b, props = __objRest(_b, [
|
|
1120
1174
|
"value",
|
|
1121
1175
|
"className",
|
|
1122
|
-
"children"
|
|
1123
|
-
"style"
|
|
1176
|
+
"children"
|
|
1124
1177
|
]);
|
|
1125
1178
|
const { value: activeValue, onValueChange, variant } = useTabs();
|
|
1126
1179
|
const isActive = activeValue === value;
|
|
1127
|
-
const headerStyle = variant === "header" ? __spreadValues({
|
|
1128
|
-
color: isActive ? "var(--color-brand-primary)" : "var(--color-text-secondary)"
|
|
1129
|
-
}, style) : style;
|
|
1130
1180
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1131
1181
|
"button",
|
|
1132
1182
|
__spreadProps(__spreadValues({
|
|
@@ -1135,12 +1185,11 @@ var TabsTrigger = React6__namespace.forwardRef(
|
|
|
1135
1185
|
"aria-selected": isActive,
|
|
1136
1186
|
onClick: () => onValueChange(value),
|
|
1137
1187
|
className: tailwindMerge.twMerge(
|
|
1138
|
-
"relative inline-flex flex-col items-center justify-center whitespace-nowrap font-
|
|
1139
|
-
variant === "header" ? "flex-1
|
|
1140
|
-
variant
|
|
1188
|
+
"relative inline-flex flex-col items-center justify-center whitespace-nowrap font-[var(--deframe-widget-font-family)] transition-colors cursor-pointer disabled:pointer-events-none disabled:opacity-50 outline-none",
|
|
1189
|
+
variant === "header" ? "flex-1 [font-size:var(--deframe-widget-font-size-lg)] [font-weight:var(--deframe-widget-font-weight-semibold)] py-[var(--deframe-widget-size-padding-y-md)]" : variant === "primary" ? "h-[72px] [font-size:var(--deframe-widget-font-size-md)] [line-height:var(--deframe-widget-font-leading-md)] [font-weight:var(--deframe-widget-font-weight-medium)] px-[var(--deframe-widget-size-padding-x-none)] pb-[var(--deframe-widget-size-padding-y-sm)] pt-[var(--deframe-widget-size-padding-y-sm)] flex-none" : "h-12 text-[12px] [font-weight:var(--deframe-widget-font-weight-semibold)] px-[var(--deframe-widget-size-padding-x-md)] flex-none",
|
|
1190
|
+
variant === "header" ? isActive ? "text-[color:var(--deframe-widget-color-brand-primary)]" : "text-[color:var(--deframe-widget-color-text-secondary)]" : isActive ? "text-[color:var(--deframe-widget-color-brand-primary)]" : "text-[color:var(--deframe-widget-color-text-secondary)] hover:text-[color:var(--deframe-widget-color-text-primary)]",
|
|
1141
1191
|
className
|
|
1142
|
-
)
|
|
1143
|
-
style: headerStyle
|
|
1192
|
+
)
|
|
1144
1193
|
}, props), {
|
|
1145
1194
|
children: [
|
|
1146
1195
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children }),
|
|
@@ -1148,17 +1197,7 @@ var TabsTrigger = React6__namespace.forwardRef(
|
|
|
1148
1197
|
framerMotion.motion.span,
|
|
1149
1198
|
{
|
|
1150
1199
|
layoutId: "header-tab-indicator",
|
|
1151
|
-
className: "absolute rounded-t-full",
|
|
1152
|
-
style: {
|
|
1153
|
-
bottom: 0,
|
|
1154
|
-
left: 0,
|
|
1155
|
-
right: 0,
|
|
1156
|
-
marginLeft: "auto",
|
|
1157
|
-
marginRight: "auto",
|
|
1158
|
-
width: "3.5rem",
|
|
1159
|
-
height: "3px",
|
|
1160
|
-
backgroundColor: "var(--color-brand-primary)"
|
|
1161
|
-
},
|
|
1200
|
+
className: "absolute bottom-0 left-1/2 -translate-x-1/2 w-14 h-[3px] rounded-t-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-brand-primary)]",
|
|
1162
1201
|
transition: { type: "spring", bounce: 0.2, duration: 0.6 }
|
|
1163
1202
|
}
|
|
1164
1203
|
),
|
|
@@ -1166,7 +1205,7 @@ var TabsTrigger = React6__namespace.forwardRef(
|
|
|
1166
1205
|
framerMotion.motion.span,
|
|
1167
1206
|
{
|
|
1168
1207
|
layoutId: "tab-indicator",
|
|
1169
|
-
className: "absolute bottom-0 left-0 right-0 h-0.5 bg-brand-primary z-10",
|
|
1208
|
+
className: "absolute bottom-0 left-0 right-0 h-0.5 bg-[var(--deframe-widget-color-brand-primary)] z-10",
|
|
1170
1209
|
transition: { type: "spring", bounce: 0.2, duration: 0.6 }
|
|
1171
1210
|
}
|
|
1172
1211
|
)
|
|
@@ -1188,7 +1227,7 @@ var TabsContent = React6__namespace.forwardRef(
|
|
|
1188
1227
|
role: "tabpanel",
|
|
1189
1228
|
className: tailwindMerge.twMerge(
|
|
1190
1229
|
"focus-visible:outline-none",
|
|
1191
|
-
variant === "primary" || variant === "header" ? "mt-
|
|
1230
|
+
variant === "primary" || variant === "header" ? "mt-[var(--deframe-widget-size-gap-none)]" : "mt-[var(--deframe-widget-size-gap-lg)]",
|
|
1192
1231
|
className
|
|
1193
1232
|
)
|
|
1194
1233
|
}, props), {
|
|
@@ -1304,12 +1343,12 @@ var SelectTrigger = React6__namespace.forwardRef(
|
|
|
1304
1343
|
"aria-haspopup": "listbox",
|
|
1305
1344
|
"aria-expanded": _isOpen,
|
|
1306
1345
|
className: tailwindMerge.twMerge(
|
|
1307
|
-
"w-full flex items-center justify-between gap-
|
|
1308
|
-
"bg-[var(--color-bg-
|
|
1309
|
-
"
|
|
1346
|
+
"w-full flex items-center justify-between gap-[var(--deframe-widget-size-gap-sm)]",
|
|
1347
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] border border-[color:var(--deframe-widget-color-border-secondary)] rounded-[var(--deframe-widget-size-radius-xs)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)].5",
|
|
1348
|
+
"[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-primary)] text-left",
|
|
1310
1349
|
"transition-colors cursor-pointer",
|
|
1311
|
-
"hover:border-[var(--color-border-
|
|
1312
|
-
"focus:outline-none focus:ring-2 focus:ring-[var(--color-brand-primary
|
|
1350
|
+
"hover:border-[color:var(--deframe-widget-color-border-primary)]",
|
|
1351
|
+
"focus:outline-none focus:ring-2 focus:ring-[color:var(--deframe-widget-color-brand-primary)] focus:border-[color:var(--deframe-widget-color-brand-primary)]",
|
|
1313
1352
|
_disabled && "opacity-50 cursor-not-allowed",
|
|
1314
1353
|
className
|
|
1315
1354
|
),
|
|
@@ -1317,7 +1356,7 @@ var SelectTrigger = React6__namespace.forwardRef(
|
|
|
1317
1356
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1318
1357
|
"span",
|
|
1319
1358
|
{
|
|
1320
|
-
className: !hasChildren ? "text-[var(--color-text-tertiary
|
|
1359
|
+
className: !hasChildren ? "text-[color:var(--deframe-widget-color-text-tertiary)]" : void 0,
|
|
1321
1360
|
children: hasChildren ? children : placeholder
|
|
1322
1361
|
}
|
|
1323
1362
|
),
|
|
@@ -1325,7 +1364,7 @@ var SelectTrigger = React6__namespace.forwardRef(
|
|
|
1325
1364
|
ChevronDownIcon,
|
|
1326
1365
|
{
|
|
1327
1366
|
className: tailwindMerge.twMerge(
|
|
1328
|
-
"w-4 h-4 text-[var(--color-text-secondary
|
|
1367
|
+
"w-4 h-4 text-[color:var(--deframe-widget-color-text-secondary)] transition-transform",
|
|
1329
1368
|
_isOpen && "rotate-180"
|
|
1330
1369
|
)
|
|
1331
1370
|
}
|
|
@@ -1401,10 +1440,10 @@ var SelectContent = React6__namespace.forwardRef(
|
|
|
1401
1440
|
animate: "visible",
|
|
1402
1441
|
exit: "exit",
|
|
1403
1442
|
className: tailwindMerge.twMerge(
|
|
1404
|
-
"absolute z-50 w-full mt-
|
|
1405
|
-
"bg-[var(--color-bg-
|
|
1443
|
+
"absolute z-50 w-full mt-[var(--deframe-widget-size-gap-xs)]",
|
|
1444
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] border border-[color:var(--deframe-widget-color-border-secondary)] rounded-[var(--deframe-widget-size-radius-xs)] shadow-[0_20px_50px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_28%,transparent)]",
|
|
1406
1445
|
"max-h-60 overflow-auto",
|
|
1407
|
-
"py-
|
|
1446
|
+
"py-[var(--deframe-widget-size-padding-y-xs)]",
|
|
1408
1447
|
className
|
|
1409
1448
|
),
|
|
1410
1449
|
children: enhancedChildren
|
|
@@ -1445,10 +1484,10 @@ var SelectItem = React6__namespace.forwardRef(
|
|
|
1445
1484
|
onClick: handleClick,
|
|
1446
1485
|
onMouseEnter: handleMouseEnter,
|
|
1447
1486
|
className: tailwindMerge.twMerge(
|
|
1448
|
-
"px-
|
|
1449
|
-
"text-[var(--color-text-primary
|
|
1450
|
-
_isSelected && "text-[var(--color-
|
|
1451
|
-
_isHighlighted && "bg-[var(--color-bg-
|
|
1487
|
+
"px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] [font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] cursor-pointer transition-colors",
|
|
1488
|
+
"text-[color:var(--deframe-widget-color-text-primary)]",
|
|
1489
|
+
_isSelected && "text-[color:var(--deframe-widget-color-brand-primary)]",
|
|
1490
|
+
_isHighlighted && "bg-[var(--deframe-widget-color-bg-tertiary)]",
|
|
1452
1491
|
disabled && "opacity-50 cursor-not-allowed",
|
|
1453
1492
|
className
|
|
1454
1493
|
),
|
|
@@ -1474,13 +1513,13 @@ var Skeleton = (_a) => {
|
|
|
1474
1513
|
"className",
|
|
1475
1514
|
"style"
|
|
1476
1515
|
]);
|
|
1477
|
-
const defaultGradient = "linear-gradient(25deg,
|
|
1516
|
+
const defaultGradient = "linear-gradient(25deg, var(--deframe-widget-color-bg-tertiary) 0%, var(--deframe-widget-color-bg-tertiary) 60%, var(--deframe-widget-color-bg-secondary) 100%)";
|
|
1478
1517
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1479
1518
|
"div",
|
|
1480
1519
|
__spreadProps(__spreadValues({
|
|
1481
1520
|
className: tailwindMerge.twMerge(
|
|
1482
1521
|
"relative overflow-hidden animate-fade-in",
|
|
1483
|
-
variant === "circle" ? "rounded-full" : "rounded",
|
|
1522
|
+
variant === "circle" ? "rounded-[var(--deframe-widget-size-radius-full)]" : "rounded-[var(--deframe-widget-size-radius-xs)]",
|
|
1484
1523
|
className
|
|
1485
1524
|
),
|
|
1486
1525
|
style: __spreadValues({
|
|
@@ -1489,7 +1528,7 @@ var Skeleton = (_a) => {
|
|
|
1489
1528
|
background: defaultGradient
|
|
1490
1529
|
}, style)
|
|
1491
1530
|
}, props), {
|
|
1492
|
-
children: shimmer && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 animate-shimmer bg-gradient-to-r from-transparent via-
|
|
1531
|
+
children: shimmer && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 animate-shimmer bg-gradient-to-r from-transparent via-[color-mix(in srgb, var(--deframe-widget-color-bg-tertiary) 92%, transparent)] to-transparent" })
|
|
1493
1532
|
})
|
|
1494
1533
|
);
|
|
1495
1534
|
};
|
|
@@ -1512,7 +1551,7 @@ function BannerNotificationIcon(_a) {
|
|
|
1512
1551
|
}
|
|
1513
1552
|
function BannerNotificationContent(_a) {
|
|
1514
1553
|
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
1515
|
-
const baseClasses = "flex-1 min-w-0
|
|
1554
|
+
const baseClasses = "flex-1 min-w-0 px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)]";
|
|
1516
1555
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1517
1556
|
"div",
|
|
1518
1557
|
__spreadValues({
|
|
@@ -1540,7 +1579,7 @@ function BannerNotificationMessage(_a) {
|
|
|
1540
1579
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1541
1580
|
TextBody,
|
|
1542
1581
|
__spreadValues({
|
|
1543
|
-
variant: "
|
|
1582
|
+
variant: "[font-size:var(--deframe-widget-font-size-md)] [line-height:var(--deframe-widget-font-leading-md)]",
|
|
1544
1583
|
"data-slot": "banner-notification-message",
|
|
1545
1584
|
"data-test-id": "banner-notification-message",
|
|
1546
1585
|
className: tailwindMerge.twMerge("text-inherit", className)
|
|
@@ -1565,7 +1604,7 @@ function BannerNotificationClose(_a) {
|
|
|
1565
1604
|
}, props)
|
|
1566
1605
|
);
|
|
1567
1606
|
}
|
|
1568
|
-
|
|
1607
|
+
var BannerNotification = (_a) => {
|
|
1569
1608
|
var _b = _a, {
|
|
1570
1609
|
type = "inline",
|
|
1571
1610
|
variant = "info",
|
|
@@ -1673,7 +1712,7 @@ function BannerNotification(_a) {
|
|
|
1673
1712
|
inline: variantInlineClasses[v],
|
|
1674
1713
|
toast: [
|
|
1675
1714
|
variantToastClasses[v],
|
|
1676
|
-
"fixed z-50 w-[clamp(18rem,40vw,30rem)] shadow-
|
|
1715
|
+
"fixed z-50 w-[clamp(18rem,40vw,30rem)] shadow-[0_20px_50px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_28%,transparent)]",
|
|
1677
1716
|
positionClasses[p]
|
|
1678
1717
|
].join(" ")
|
|
1679
1718
|
};
|
|
@@ -1704,7 +1743,7 @@ function BannerNotification(_a) {
|
|
|
1704
1743
|
]
|
|
1705
1744
|
})
|
|
1706
1745
|
);
|
|
1707
|
-
}
|
|
1746
|
+
};
|
|
1708
1747
|
BannerNotification.displayName = "BannerNotification";
|
|
1709
1748
|
var AddressDisplay = ({
|
|
1710
1749
|
address,
|
|
@@ -1728,7 +1767,10 @@ var AddressDisplay = ({
|
|
|
1728
1767
|
"div",
|
|
1729
1768
|
{
|
|
1730
1769
|
className: tailwindMerge.twMerge(
|
|
1731
|
-
"bg-[
|
|
1770
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] rounded-[var(--deframe-widget-size-radius-sm)]",
|
|
1771
|
+
"px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)]",
|
|
1772
|
+
"flex items-center justify-between gap-[var(--deframe-widget-size-gap-sm)]",
|
|
1773
|
+
"border border-[color:var(--deframe-widget-color-border-secondary)]",
|
|
1732
1774
|
className
|
|
1733
1775
|
),
|
|
1734
1776
|
children: [
|
|
@@ -1746,12 +1788,12 @@ var AddressDisplay = ({
|
|
|
1746
1788
|
"button",
|
|
1747
1789
|
{
|
|
1748
1790
|
onClick: handleCopy,
|
|
1749
|
-
className: "text-
|
|
1791
|
+
className: "text-[color:var(--deframe-widget-color-text-tertiary)] hover:text-[color:var(--deframe-widget-color-text-primary)] transition-colors flex-shrink-0 cursor-pointer",
|
|
1750
1792
|
"aria-label": "Copy address",
|
|
1751
1793
|
children: copied ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1752
1794
|
"svg",
|
|
1753
1795
|
{
|
|
1754
|
-
className: "w-5 h-5 text-
|
|
1796
|
+
className: "w-5 h-5 text-[color:var(--deframe-widget-color-state-success)]",
|
|
1755
1797
|
fill: "none",
|
|
1756
1798
|
stroke: "currentColor",
|
|
1757
1799
|
viewBox: "0 0 24 24",
|
|
@@ -1802,15 +1844,19 @@ var SummaryDetails = ({
|
|
|
1802
1844
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1803
1845
|
"details",
|
|
1804
1846
|
{
|
|
1805
|
-
className: tailwindMerge.twMerge(
|
|
1847
|
+
className: tailwindMerge.twMerge(
|
|
1848
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] rounded-[var(--deframe-widget-size-radius-sm)]",
|
|
1849
|
+
"p-[var(--deframe-widget-size-gap-lg)] group",
|
|
1850
|
+
className
|
|
1851
|
+
),
|
|
1806
1852
|
open: defaultOpen,
|
|
1807
1853
|
children: [
|
|
1808
1854
|
/* @__PURE__ */ jsxRuntime.jsx("summary", { className: tailwindMerge.twMerge("cursor-pointer block ", summaryClassName), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
1809
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { className: "text-
|
|
1855
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { className: "text-[color:var(--deframe-widget-color-text-primary)] [font-weight:var(--deframe-widget-font-weight-medium)]", children: title }),
|
|
1810
1856
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1811
1857
|
"svg",
|
|
1812
1858
|
{
|
|
1813
|
-
className: "w-5 h-5 text-
|
|
1859
|
+
className: "w-5 h-5 text-[color:var(--deframe-widget-color-text-tertiary)] transition-transform duration-300 group-open:rotate-180",
|
|
1814
1860
|
fill: "none",
|
|
1815
1861
|
stroke: "currentColor",
|
|
1816
1862
|
viewBox: "0 0 24 24",
|
|
@@ -1831,24 +1877,24 @@ var SummaryDetails = ({
|
|
|
1831
1877
|
"div",
|
|
1832
1878
|
{
|
|
1833
1879
|
className: tailwindMerge.twMerge(
|
|
1834
|
-
"mt-
|
|
1835
|
-
showDividers && "divide-y divide-[
|
|
1880
|
+
"mt-[var(--deframe-widget-size-gap-lg)]",
|
|
1881
|
+
showDividers && "divide-y divide-[color:var(--deframe-widget-color-border-tertiary)]",
|
|
1836
1882
|
contentClassName
|
|
1837
1883
|
),
|
|
1838
|
-
children: items.map((item, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between py-
|
|
1884
|
+
children: items.map((item, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between py-[var(--deframe-widget-size-padding-y-sm)]", children: [
|
|
1839
1885
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1840
1886
|
TextBody,
|
|
1841
1887
|
{
|
|
1842
|
-
variant: "
|
|
1843
|
-
className: tailwindMerge.twMerge("text-
|
|
1888
|
+
variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]",
|
|
1889
|
+
className: tailwindMerge.twMerge("text-[color:var(--deframe-widget-color-text-tertiary)]", item.labelClassName),
|
|
1844
1890
|
children: item.label
|
|
1845
1891
|
}
|
|
1846
1892
|
),
|
|
1847
1893
|
typeof item.value === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1848
1894
|
TextBody,
|
|
1849
1895
|
{
|
|
1850
|
-
variant: "
|
|
1851
|
-
className: tailwindMerge.twMerge("text-text-primary
|
|
1896
|
+
variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]",
|
|
1897
|
+
className: tailwindMerge.twMerge("text-[color:var(--deframe-widget-color-text-primary)] [font-weight:var(--deframe-widget-font-weight-medium)]", item.valueClassName),
|
|
1852
1898
|
children: item.value
|
|
1853
1899
|
}
|
|
1854
1900
|
) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: item.valueClassName, children: item.value })
|
|
@@ -1874,7 +1920,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1874
1920
|
"data-test-id": "summary-details-v2",
|
|
1875
1921
|
"data-slot": "summary-details-v2",
|
|
1876
1922
|
className: tailwindMerge.twMerge(
|
|
1877
|
-
"bg-[var(--color-bg-
|
|
1923
|
+
"bg-[var(--deframe-widget-color-bg-secondary)] rounded-[var(--deframe-widget-size-radius-md)] border border-[color:var(--deframe-widget-color-border-secondary)] px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)] w-full max-w-[320px] group",
|
|
1878
1924
|
className
|
|
1879
1925
|
),
|
|
1880
1926
|
open: defaultOpen,
|
|
@@ -1891,7 +1937,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1891
1937
|
{
|
|
1892
1938
|
"data-test-id": "summary-details-v2-title",
|
|
1893
1939
|
"data-slot": "summary-details-v2-title",
|
|
1894
|
-
className: "text-[15px] font-semibold text-
|
|
1940
|
+
className: "text-[15px] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-primary)]",
|
|
1895
1941
|
children: title
|
|
1896
1942
|
}
|
|
1897
1943
|
),
|
|
@@ -1900,7 +1946,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1900
1946
|
{
|
|
1901
1947
|
"data-test-id": "summary-details-v2-chevron",
|
|
1902
1948
|
"data-slot": "summary-details-v2-chevron",
|
|
1903
|
-
className: "w-4 h-4 text-
|
|
1949
|
+
className: "w-4 h-4 text-[color:var(--deframe-widget-color-text-secondary)] transition-transform duration-300 group-open:rotate-180 flex-shrink-0",
|
|
1904
1950
|
viewBox: "0 0 24 24",
|
|
1905
1951
|
fill: "none",
|
|
1906
1952
|
stroke: "currentColor",
|
|
@@ -1916,7 +1962,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1916
1962
|
{
|
|
1917
1963
|
"data-test-id": "summary-details-v2-top-divider",
|
|
1918
1964
|
"data-slot": "summary-details-v2-top-divider",
|
|
1919
|
-
className: "h-px bg-
|
|
1965
|
+
className: "h-px bg-[var(--deframe-widget-color-border-secondary)] mt-[var(--deframe-widget-size-gap-sm)]"
|
|
1920
1966
|
}
|
|
1921
1967
|
),
|
|
1922
1968
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1924,14 +1970,14 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1924
1970
|
{
|
|
1925
1971
|
"data-test-id": "summary-details-v2-content",
|
|
1926
1972
|
"data-slot": "summary-details-v2-content",
|
|
1927
|
-
className: tailwindMerge.twMerge("mt-
|
|
1973
|
+
className: tailwindMerge.twMerge("mt-[var(--deframe-widget-size-gap-none)]", contentClassName),
|
|
1928
1974
|
children: items.map((item, i) => /* @__PURE__ */ jsxRuntime.jsxs(React6__namespace.Fragment, { children: [
|
|
1929
1975
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1930
1976
|
"div",
|
|
1931
1977
|
{
|
|
1932
1978
|
"data-test-id": "summary-details-v2-row",
|
|
1933
1979
|
"data-slot": "summary-details-v2-row",
|
|
1934
|
-
className: "flex justify-between items-center py-[10px] gap-
|
|
1980
|
+
className: "flex justify-between items-center py-[10px] gap-[var(--deframe-widget-size-gap-sm)]",
|
|
1935
1981
|
children: [
|
|
1936
1982
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1937
1983
|
"span",
|
|
@@ -1939,7 +1985,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1939
1985
|
"data-test-id": "summary-details-v2-row-label",
|
|
1940
1986
|
"data-slot": "summary-details-v2-row-label",
|
|
1941
1987
|
className: tailwindMerge.twMerge(
|
|
1942
|
-
"text-[11px] font-medium uppercase tracking-[0.07em] text-
|
|
1988
|
+
"text-[11px] [font-weight:var(--deframe-widget-font-weight-medium)] uppercase tracking-[0.07em] text-[color:var(--deframe-widget-color-text-tertiary)] flex-shrink-0",
|
|
1943
1989
|
item.labelClassName
|
|
1944
1990
|
),
|
|
1945
1991
|
children: item.label
|
|
@@ -1951,7 +1997,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1951
1997
|
"data-test-id": "summary-details-v2-row-value",
|
|
1952
1998
|
"data-slot": "summary-details-v2-row-value",
|
|
1953
1999
|
className: tailwindMerge.twMerge(
|
|
1954
|
-
"text-[13px] font-semibold text-
|
|
2000
|
+
"text-[13px] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-primary)] text-right",
|
|
1955
2001
|
item.valueClassName
|
|
1956
2002
|
),
|
|
1957
2003
|
children: item.value
|
|
@@ -1973,7 +2019,7 @@ var SummaryDetailsCryptoControlV2 = ({
|
|
|
1973
2019
|
{
|
|
1974
2020
|
"data-test-id": "summary-details-v2-row-divider",
|
|
1975
2021
|
"data-slot": "summary-details-v2-row-divider",
|
|
1976
|
-
className: "h-px bg-
|
|
2022
|
+
className: "h-px bg-[var(--deframe-widget-color-border-secondary)]"
|
|
1977
2023
|
}
|
|
1978
2024
|
)
|
|
1979
2025
|
] }, i))
|
|
@@ -2096,7 +2142,7 @@ var ActionSheet = ({
|
|
|
2096
2142
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2097
2143
|
"div",
|
|
2098
2144
|
{
|
|
2099
|
-
className: "absolute inset-0 bg-
|
|
2145
|
+
className: "absolute inset-0 bg-[var(--deframe-widget-color-bg-primary)]/50 backdrop-blur-sm",
|
|
2100
2146
|
"aria-hidden": "true"
|
|
2101
2147
|
}
|
|
2102
2148
|
),
|
|
@@ -2104,8 +2150,8 @@ var ActionSheet = ({
|
|
|
2104
2150
|
framerMotion.motion.div,
|
|
2105
2151
|
{
|
|
2106
2152
|
className: tailwindMerge.twMerge(
|
|
2107
|
-
"relative w-full bg-[var(--
|
|
2108
|
-
position === "bottom" ? "max-w-full rounded-t-[
|
|
2153
|
+
"relative w-full bg-[var(--deframe-widget-color-bg-secondary)] shadow-[0_20px_50px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_28%,transparent)] overflow-hidden",
|
|
2154
|
+
position === "bottom" ? "max-w-full rounded-t-[var(--deframe-widget-size-radius-xl)]" : "max-w-lg rounded-[var(--deframe-widget-size-radius-xl)] mx-[var(--deframe-widget-size-gap-md)]",
|
|
2109
2155
|
getHeightClass(),
|
|
2110
2156
|
contentClassName
|
|
2111
2157
|
),
|
|
@@ -2120,168 +2166,51 @@ var ActionSheet = ({
|
|
|
2120
2166
|
}
|
|
2121
2167
|
) });
|
|
2122
2168
|
};
|
|
2123
|
-
|
|
2124
|
-
// src/stories/providers/types.ts
|
|
2125
|
-
var defaultThemeColors = {
|
|
2126
|
-
// Brand
|
|
2127
|
-
brandPrimary: "#405EFF",
|
|
2128
|
-
brandSecondary: "#A9ABF7",
|
|
2129
|
-
// Backgrounds
|
|
2130
|
-
bgDefault: "#FFFFFF",
|
|
2131
|
-
bgSubtle: "#F8F9FA",
|
|
2132
|
-
bgMuted: "#E3E4E8",
|
|
2133
|
-
// Text
|
|
2134
|
-
textPrimary: "#252050",
|
|
2135
|
-
textSecondary: "#5C5F66",
|
|
2136
|
-
textDisabled: "#C6C8CC",
|
|
2137
|
-
textInverse: "#FFFFFF",
|
|
2138
|
-
// States
|
|
2139
|
-
stateSuccess: "#2BA176",
|
|
2140
|
-
stateError: "#FF4D4F",
|
|
2141
|
-
stateWarning: "#F6A700"
|
|
2142
|
-
};
|
|
2143
|
-
var darkThemeColors = {
|
|
2144
|
-
// Brand
|
|
2145
|
-
brandPrimary: "#405EFF",
|
|
2146
|
-
brandSecondary: "#A9ABF7",
|
|
2147
|
-
// Backgrounds
|
|
2148
|
-
bgDefault: "#121212",
|
|
2149
|
-
bgSubtle: "#1E1E1E",
|
|
2150
|
-
bgMuted: "#2C2C2C",
|
|
2151
|
-
// Text
|
|
2152
|
-
textPrimary: "#FFFFFF",
|
|
2153
|
-
textSecondary: "#E3E4E8",
|
|
2154
|
-
textDisabled: "#898D95",
|
|
2155
|
-
textInverse: "#252050",
|
|
2156
|
-
// States
|
|
2157
|
-
stateSuccess: "#2BA176",
|
|
2158
|
-
stateError: "#FF4D4F",
|
|
2159
|
-
stateWarning: "#F6A700"
|
|
2160
|
-
};
|
|
2161
|
-
var cryptocontrolThemeColors = {
|
|
2162
|
-
// Brand - green primary for cryptocontrol
|
|
2163
|
-
brandPrimary: "#1FC16B",
|
|
2164
|
-
brandSecondary: "#A9ABF7",
|
|
2165
|
-
// Backgrounds (same as dark)
|
|
2166
|
-
bgDefault: "#121212",
|
|
2167
|
-
bgSubtle: "#1E1E1E",
|
|
2168
|
-
bgMuted: "#2C2C2C",
|
|
2169
|
-
// Text (same as dark)
|
|
2170
|
-
textPrimary: "#FFFFFF",
|
|
2171
|
-
textSecondary: "#E3E4E8",
|
|
2172
|
-
textDisabled: "#898D95",
|
|
2173
|
-
textInverse: "#252050",
|
|
2174
|
-
// States
|
|
2175
|
-
stateSuccess: "#2BA176",
|
|
2176
|
-
stateError: "#FF4D4F",
|
|
2177
|
-
stateWarning: "#F6A700"
|
|
2178
|
-
};
|
|
2179
|
-
function themeToCSS(theme) {
|
|
2180
|
-
if (!(theme == null ? void 0 : theme.colors)) return {};
|
|
2181
|
-
const vars = {};
|
|
2182
|
-
const colors = theme.colors;
|
|
2183
|
-
if (colors.brandPrimary) vars["--deframe-brand-primary"] = colors.brandPrimary;
|
|
2184
|
-
if (colors.brandSecondary) vars["--deframe-brand-secondary"] = colors.brandSecondary;
|
|
2185
|
-
if (colors.bgDefault) vars["--deframe-bg-default"] = colors.bgDefault;
|
|
2186
|
-
if (colors.bgSubtle) vars["--deframe-bg-subtle"] = colors.bgSubtle;
|
|
2187
|
-
if (colors.bgMuted) vars["--deframe-bg-muted"] = colors.bgMuted;
|
|
2188
|
-
if (colors.textPrimary) vars["--deframe-text-primary"] = colors.textPrimary;
|
|
2189
|
-
if (colors.textSecondary) vars["--deframe-text-secondary"] = colors.textSecondary;
|
|
2190
|
-
if (colors.textDisabled) vars["--deframe-text-disabled"] = colors.textDisabled;
|
|
2191
|
-
if (colors.textInverse) vars["--deframe-text-inverse"] = colors.textInverse;
|
|
2192
|
-
if (colors.stateSuccess) vars["--deframe-state-success"] = colors.stateSuccess;
|
|
2193
|
-
if (colors.stateError) vars["--deframe-state-error"] = colors.stateError;
|
|
2194
|
-
if (colors.stateWarning) vars["--deframe-state-warning"] = colors.stateWarning;
|
|
2195
|
-
return vars;
|
|
2196
|
-
}
|
|
2197
|
-
function getSystemColorMode() {
|
|
2198
|
-
if (typeof window === "undefined" || !window.matchMedia) return "light";
|
|
2199
|
-
return window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
2200
|
-
}
|
|
2201
|
-
function resolveThemeConfig(config, systemMode) {
|
|
2202
|
-
var _a, _b, _c, _d, _e, _f;
|
|
2203
|
-
const mode = (config == null ? void 0 : config.mode) === "auto" ? systemMode : (_a = config == null ? void 0 : config.mode) != null ? _a : "light";
|
|
2204
|
-
const preset = (_b = config == null ? void 0 : config.preset) != null ? _b : "default";
|
|
2205
|
-
const providerTheme = preset === "cryptocontrol" ? "cryptocontrol" : mode === "dark" ? "dark" : "light";
|
|
2206
|
-
const overrideColors = mode === "dark" ? (_d = (_c = config == null ? void 0 : config.overrides) == null ? void 0 : _c.dark) == null ? void 0 : _d.colors : (_f = (_e = config == null ? void 0 : config.overrides) == null ? void 0 : _e.light) == null ? void 0 : _f.colors;
|
|
2207
|
-
const customTheme = overrideColors ? { colors: overrideColors } : void 0;
|
|
2208
|
-
return { providerTheme, customTheme };
|
|
2209
|
-
}
|
|
2210
2169
|
function DeframeComponentsProvider({
|
|
2211
|
-
theme = "light",
|
|
2212
|
-
themeConfig,
|
|
2213
|
-
customTheme,
|
|
2214
2170
|
className,
|
|
2215
2171
|
children
|
|
2216
2172
|
}) {
|
|
2217
|
-
const [systemMode, setSystemMode] = React6.useState(() => getSystemColorMode());
|
|
2218
|
-
React6.useEffect(() => {
|
|
2219
|
-
var _a;
|
|
2220
|
-
const needsSystem = (themeConfig == null ? void 0 : themeConfig.mode) === "auto";
|
|
2221
|
-
if (!needsSystem || typeof window === "undefined" || !window.matchMedia) return;
|
|
2222
|
-
const mq = window.matchMedia("(prefers-color-scheme: dark)");
|
|
2223
|
-
const handler = () => setSystemMode(mq.matches ? "dark" : "light");
|
|
2224
|
-
handler();
|
|
2225
|
-
(_a = mq.addEventListener) == null ? void 0 : _a.call(mq, "change", handler);
|
|
2226
|
-
return () => {
|
|
2227
|
-
var _a2;
|
|
2228
|
-
return (_a2 = mq.removeEventListener) == null ? void 0 : _a2.call(mq, "change", handler);
|
|
2229
|
-
};
|
|
2230
|
-
}, [themeConfig == null ? void 0 : themeConfig.mode]);
|
|
2231
|
-
const resolvedTheme = React6.useMemo(() => {
|
|
2232
|
-
if (themeConfig) {
|
|
2233
|
-
return resolveThemeConfig(themeConfig, systemMode);
|
|
2234
|
-
}
|
|
2235
|
-
return {
|
|
2236
|
-
providerTheme: theme,
|
|
2237
|
-
customTheme
|
|
2238
|
-
};
|
|
2239
|
-
}, [themeConfig, theme, customTheme, systemMode]);
|
|
2240
|
-
const themeClass = resolvedTheme.providerTheme === "light" ? "" : resolvedTheme.providerTheme;
|
|
2241
|
-
const colorScheme = resolvedTheme.providerTheme === "light" ? "light" : "dark";
|
|
2242
|
-
const customCSSVars = themeToCSS(resolvedTheme.customTheme);
|
|
2243
2173
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2244
2174
|
"div",
|
|
2245
2175
|
{
|
|
2246
|
-
className: tailwindMerge.twMerge("deframe-widget",
|
|
2247
|
-
style: __spreadValues({ colorScheme }, customCSSVars),
|
|
2176
|
+
className: tailwindMerge.twMerge("deframe-widget", className),
|
|
2248
2177
|
children
|
|
2249
2178
|
}
|
|
2250
2179
|
);
|
|
2251
2180
|
}
|
|
2252
2181
|
var InfoRow = ({ children, borderBottom, className }) => {
|
|
2253
2182
|
const baseClasses = "self-stretch inline-flex justify-between items-start";
|
|
2254
|
-
const borderClasses = borderBottom ? "border-b border-
|
|
2183
|
+
const borderClasses = borderBottom ? "border-b border-[color:var(--deframe-widget-color-border-secondary)] pb-[var(--deframe-widget-size-padding-y-sm)]" : "";
|
|
2255
2184
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "info-row", className: tailwindMerge.twMerge(baseClasses, borderClasses, className), children });
|
|
2256
2185
|
};
|
|
2257
2186
|
var InfoLabel = ({ children, className }) => {
|
|
2258
|
-
const baseClasses = "
|
|
2187
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]";
|
|
2259
2188
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "info-label", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2260
2189
|
};
|
|
2261
2190
|
var variantClasses = {
|
|
2262
|
-
default: "text-
|
|
2263
|
-
success: "text-state-success",
|
|
2264
|
-
warning: "text-state-warning",
|
|
2265
|
-
error: "text-state-error"
|
|
2191
|
+
default: "text-[color:var(--deframe-widget-color-text-primary)]",
|
|
2192
|
+
success: "text-[color:var(--deframe-widget-color-state-success)]",
|
|
2193
|
+
warning: "text-[color:var(--deframe-widget-color-state-warning)]",
|
|
2194
|
+
error: "text-[color:var(--deframe-widget-color-state-error)]"
|
|
2266
2195
|
};
|
|
2267
2196
|
var InfoValue = ({ children, variant = "default", className }) => {
|
|
2268
|
-
const baseClasses = "
|
|
2197
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] [font-weight:var(--deframe-widget-font-weight-semibold)]";
|
|
2269
2198
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "info-value", className: tailwindMerge.twMerge(baseClasses, variantClasses[variant], className), children });
|
|
2270
2199
|
};
|
|
2271
2200
|
var InfoRowWithIcon = ({ children, borderBottom, className }) => {
|
|
2272
2201
|
const baseClasses = "flex items-start justify-between h-[17px]";
|
|
2273
|
-
const borderClasses = borderBottom ? "border-b border-
|
|
2202
|
+
const borderClasses = borderBottom ? "border-b border-[color:var(--deframe-widget-color-border-secondary)] pb-[var(--deframe-widget-size-padding-y-sm)]" : "";
|
|
2274
2203
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "info-row-with-icon", className: tailwindMerge.twMerge(baseClasses, borderClasses, className), children });
|
|
2275
2204
|
};
|
|
2276
2205
|
var InfoRowIconLabel = ({ children, className }) => {
|
|
2277
|
-
const baseClasses = "
|
|
2206
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]";
|
|
2278
2207
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "info-row-icon-label", className: tailwindMerge.twMerge(baseClasses, className), children: [
|
|
2279
2208
|
"\u2022 ",
|
|
2280
2209
|
children
|
|
2281
2210
|
] });
|
|
2282
2211
|
};
|
|
2283
2212
|
var InfoRowIconValue = ({ children, className }) => {
|
|
2284
|
-
const baseClasses = "
|
|
2213
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-primary)]";
|
|
2285
2214
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "info-row-icon-value", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2286
2215
|
};
|
|
2287
2216
|
var CollapsibleInfoRow = ({
|
|
@@ -2294,7 +2223,7 @@ var CollapsibleInfoRow = ({
|
|
|
2294
2223
|
expandLabel
|
|
2295
2224
|
}) => {
|
|
2296
2225
|
const [isOpen, setIsOpen] = React6__namespace.default.useState(defaultOpen);
|
|
2297
|
-
const baseClasses = "flex flex-col gap-sm w-full";
|
|
2226
|
+
const baseClasses = "flex flex-col gap-[var(--deframe-widget-size-gap-sm)] w-full";
|
|
2298
2227
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "collapsible-info-row", className: tailwindMerge.twMerge(baseClasses, className), children: [
|
|
2299
2228
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2300
2229
|
"button",
|
|
@@ -2306,10 +2235,10 @@ var CollapsibleInfoRow = ({
|
|
|
2306
2235
|
"aria-label": `${isOpen ? collapseLabel : expandLabel} ${label}`,
|
|
2307
2236
|
children: [
|
|
2308
2237
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-[2px]", children: [
|
|
2309
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
2310
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: isOpen ? /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronUp, { className: "w-3 h-3 text-
|
|
2238
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]", children: label }),
|
|
2239
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: isOpen ? /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronUp, { className: "w-3 h-3 text-[color:var(--deframe-widget-color-text-secondary)]" }) : /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronDown, { className: "w-3 h-3 text-[color:var(--deframe-widget-color-text-secondary)]" }) })
|
|
2311
2240
|
] }),
|
|
2312
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
2241
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-secondary)]", children: value })
|
|
2313
2242
|
]
|
|
2314
2243
|
}
|
|
2315
2244
|
),
|
|
@@ -2317,116 +2246,103 @@ var CollapsibleInfoRow = ({
|
|
|
2317
2246
|
] });
|
|
2318
2247
|
};
|
|
2319
2248
|
var BackgroundContainer = ({ children, className }) => {
|
|
2320
|
-
const baseClasses = "w-full flex-1 min-h-0 px-md bg-
|
|
2249
|
+
const baseClasses = "w-full flex-1 min-h-0 px-[var(--deframe-widget-size-padding-x-md)] bg-[var(--deframe-widget-color-bg-primary)] lg:bg-[var(--deframe-widget-color-bg-secondary)] text-[color:var(--deframe-widget-color-text-primary)] flex flex-col relative overflow-y-auto";
|
|
2321
2250
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "background-container", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2322
2251
|
};
|
|
2323
2252
|
var SectionCard = ({ children, className }) => {
|
|
2324
|
-
const baseClasses = "bg-
|
|
2253
|
+
const baseClasses = "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)] rounded-[var(--deframe-widget-size-radius-xs)] shadow-[0_2px_8px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_18%,transparent)] px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)] flex flex-col gap-[var(--deframe-widget-size-gap-sm)]";
|
|
2325
2254
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "section-card", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2326
2255
|
};
|
|
2327
2256
|
var Navbar = ({ children, className }) => {
|
|
2328
|
-
const baseClasses = "w-full px-sm pr-md pt-sm pb-md border-b items-center border-
|
|
2257
|
+
const baseClasses = "w-full px-[var(--deframe-widget-size-padding-x-sm)] pr-[var(--deframe-widget-size-padding-x-md)] pt-[var(--deframe-widget-size-padding-y-sm)] pb-[var(--deframe-widget-size-padding-y-md)] border-b items-center border-[color:var(--deframe-widget-color-border-tertiary)] flex";
|
|
2329
2258
|
return /* @__PURE__ */ jsxRuntime.jsx("nav", { "data-test-id": "navbar", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2330
2259
|
};
|
|
2331
2260
|
var gapClasses = {
|
|
2332
|
-
xs: "gap-xs",
|
|
2333
|
-
sm: "gap-sm",
|
|
2334
|
-
md: "gap-md",
|
|
2335
|
-
lg: "gap-lg"
|
|
2261
|
+
xs: "gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2262
|
+
sm: "gap-[var(--deframe-widget-size-gap-sm)]",
|
|
2263
|
+
md: "gap-[var(--deframe-widget-size-gap-md)]",
|
|
2264
|
+
lg: "gap-[var(--deframe-widget-size-gap-lg)]"
|
|
2336
2265
|
};
|
|
2337
2266
|
var FlexCol = ({ children, className, gap = "xs" }) => {
|
|
2338
2267
|
const baseClasses = "flex flex-col";
|
|
2339
2268
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "flex-col", className: tailwindMerge.twMerge(baseClasses, gapClasses[gap], className), children });
|
|
2340
2269
|
};
|
|
2341
2270
|
var gapClasses2 = {
|
|
2342
|
-
xs: "gap-xs",
|
|
2343
|
-
sm: "gap-sm",
|
|
2344
|
-
md: "gap-md",
|
|
2345
|
-
lg: "gap-lg"
|
|
2271
|
+
xs: "gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2272
|
+
sm: "gap-[var(--deframe-widget-size-gap-sm)]",
|
|
2273
|
+
md: "gap-[var(--deframe-widget-size-gap-md)]",
|
|
2274
|
+
lg: "gap-[var(--deframe-widget-size-gap-lg)]"
|
|
2346
2275
|
};
|
|
2347
2276
|
var FlexRow = ({ children, className, gap = "xs" }) => {
|
|
2348
2277
|
const baseClasses = "flex items-center";
|
|
2349
2278
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "flex-row", className: tailwindMerge.twMerge(baseClasses, gapClasses2[gap], className), children });
|
|
2350
2279
|
};
|
|
2351
2280
|
var ScrollableContent = ({ children, className }) => {
|
|
2352
|
-
const baseClasses = "flex-1 overflow-y-auto px-md py-lg";
|
|
2281
|
+
const baseClasses = "flex-1 overflow-y-auto px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-lg)]";
|
|
2353
2282
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "scrollable-content", className: tailwindMerge.twMerge(baseClasses, className), children });
|
|
2354
2283
|
};
|
|
2355
2284
|
var DetailsHeader = ({ title, onBack, className, backAriaLabel = "Back" }) => {
|
|
2356
|
-
const baseClasses = "w-full px-sm pr-md pt-sm pb-md border-b border-
|
|
2285
|
+
const baseClasses = "w-full px-[var(--deframe-widget-size-padding-x-sm)] pr-[var(--deframe-widget-size-padding-x-md)] pt-[var(--deframe-widget-size-padding-y-sm)] pb-[var(--deframe-widget-size-padding-y-md)] border-b border-[color:var(--deframe-widget-color-border-tertiary)] flex items-center";
|
|
2357
2286
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "details-header", className: tailwindMerge.twMerge(baseClasses, className), children: [
|
|
2358
2287
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2359
2288
|
"button",
|
|
2360
2289
|
{
|
|
2361
2290
|
"data-test-id": "details-header-back-button",
|
|
2362
2291
|
onClick: onBack,
|
|
2363
|
-
className: "w-12 h-12 rounded-full flex items-center justify-center text-
|
|
2292
|
+
className: "w-12 h-12 rounded-[var(--deframe-widget-size-radius-full)] flex items-center justify-center text-[color:var(--deframe-widget-color-text-secondary)] hover:text-[color:var(--deframe-widget-color-brand-primary)] cursor-pointer",
|
|
2364
2293
|
"aria-label": backAriaLabel,
|
|
2365
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronLeft, { className: "w-6 h-6 text-
|
|
2294
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronLeft, { className: "w-6 h-6 text-[color:var(--deframe-widget-color-text-tertiary)]" })
|
|
2366
2295
|
}
|
|
2367
2296
|
),
|
|
2368
2297
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 flex items-center", children: /* @__PURE__ */ jsxRuntime.jsx(TextHeading, { variant: "h-large", children: title }) })
|
|
2369
2298
|
] });
|
|
2370
2299
|
};
|
|
2371
|
-
var CloseButton = ({ onClick, testId, ariaLabel = "Close", className }) => {
|
|
2372
|
-
const baseClasses = "w-12 h-12 rounded-full flex items-center justify-center text-text-secondary dark:text-text-secondary-dark hover:text-brand-primary transition-colors cursor-pointer";
|
|
2373
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2374
|
-
"button",
|
|
2375
|
-
{
|
|
2376
|
-
"data-test-id": testId != null ? testId : "close-button",
|
|
2377
|
-
onClick,
|
|
2378
|
-
className: tailwindMerge.twMerge(baseClasses, className),
|
|
2379
|
-
"aria-label": ariaLabel,
|
|
2380
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiXMark, { className: "w-6 h-6" })
|
|
2381
|
-
}
|
|
2382
|
-
);
|
|
2383
|
-
};
|
|
2384
2300
|
var HighRiskBadge = ({ className, label }) => {
|
|
2385
|
-
const baseClasses = "inline-flex justify-start items-start gap-
|
|
2301
|
+
const baseClasses = "inline-flex justify-start items-start gap-[var(--deframe-widget-size-gap-xs)]";
|
|
2386
2302
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "high-risk-badge", className: tailwindMerge.twMerge(baseClasses, className), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2387
2303
|
"div",
|
|
2388
2304
|
{
|
|
2389
2305
|
"data-size": "Small",
|
|
2390
2306
|
"data-type": "Failed",
|
|
2391
|
-
className: "h-6 px-
|
|
2392
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-
|
|
2307
|
+
className: "h-6 px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] opacity-95 bg-[color:color-mix(in_srgb,var(--deframe-widget-color-state-error)_20%,transparent)] rounded-[var(--deframe-widget-size-radius-md)] outline outline-1 outline-offset-[-1px] outline-[color:var(--deframe-widget-color-state-error)] flex justify-center items-center gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2308
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-[var(--deframe-widget-size-gap-sm)].5", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "justify-start text-[color:var(--deframe-widget-color-state-error)] [font-size:var(--deframe-widget-font-size-xs)] [line-height:var(--deframe-widget-font-leading-xs)] [font-weight:var(--deframe-widget-font-weight-regular)] font-[var(--deframe-widget-font-family)] leading-4", children: label }) })
|
|
2393
2309
|
}
|
|
2394
2310
|
) });
|
|
2395
2311
|
};
|
|
2396
2312
|
var MediumRiskBadge = ({ className, label }) => {
|
|
2397
|
-
const baseClasses = "inline-flex justify-start items-start gap-
|
|
2313
|
+
const baseClasses = "inline-flex justify-start items-start gap-[var(--deframe-widget-size-gap-xs)]";
|
|
2398
2314
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "medium-risk-badge", className: tailwindMerge.twMerge(baseClasses, className), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2399
2315
|
"div",
|
|
2400
2316
|
{
|
|
2401
2317
|
"data-size": "Small",
|
|
2402
2318
|
"data-type": "Warning",
|
|
2403
|
-
className: "h-6 px-
|
|
2404
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-
|
|
2319
|
+
className: "h-6 px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] opacity-95 bg-[color:color-mix(in_srgb,var(--deframe-widget-color-state-warning)_20%,transparent)] rounded-[var(--deframe-widget-size-radius-md)] outline outline-1 outline-offset-[-1px] outline-[color:var(--deframe-widget-color-state-warning)] flex justify-center items-center gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2320
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-[var(--deframe-widget-size-gap-sm)].5", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "justify-start text-[color:var(--deframe-widget-color-state-warning)] [font-size:var(--deframe-widget-font-size-xs)] [line-height:var(--deframe-widget-font-leading-xs)] [font-weight:var(--deframe-widget-font-weight-regular)] font-[var(--deframe-widget-font-family)] leading-4", children: label }) })
|
|
2405
2321
|
}
|
|
2406
2322
|
) });
|
|
2407
2323
|
};
|
|
2408
2324
|
var LowRiskBadge = ({ className, label }) => {
|
|
2409
|
-
const baseClasses = "inline-flex justify-start items-start gap-
|
|
2325
|
+
const baseClasses = "inline-flex justify-start items-start gap-[var(--deframe-widget-size-gap-xs)]";
|
|
2410
2326
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "low-risk-badge", className: tailwindMerge.twMerge(baseClasses, className), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2411
2327
|
"div",
|
|
2412
2328
|
{
|
|
2413
2329
|
"data-size": "Small",
|
|
2414
2330
|
"data-type": "Completed",
|
|
2415
|
-
className: "h-6 px-
|
|
2416
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-
|
|
2331
|
+
className: "h-6 px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] opacity-95 bg-[color:color-mix(in_srgb,var(--deframe-widget-color-state-success)_20%,transparent)] rounded-[var(--deframe-widget-size-radius-md)] outline outline-1 outline-offset-[-1px] outline-[color:var(--deframe-widget-color-state-success)] flex justify-center items-center gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2332
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-start items-center gap-[var(--deframe-widget-size-gap-sm)].5", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "justify-start text-[color:var(--deframe-widget-color-state-success)] [font-size:var(--deframe-widget-font-size-xs)] [line-height:var(--deframe-widget-font-leading-xs)] [font-weight:var(--deframe-widget-font-weight-regular)] font-[var(--deframe-widget-font-family)] leading-4", children: label }) })
|
|
2417
2333
|
}
|
|
2418
2334
|
) });
|
|
2419
2335
|
};
|
|
2420
2336
|
var gapClasses3 = {
|
|
2421
|
-
xs: "gap-xs",
|
|
2422
|
-
sm: "gap-sm",
|
|
2423
|
-
md: "gap-md",
|
|
2424
|
-
lg: "gap-lg"
|
|
2337
|
+
xs: "gap-[var(--deframe-widget-size-gap-xs)]",
|
|
2338
|
+
sm: "gap-[var(--deframe-widget-size-gap-sm)]",
|
|
2339
|
+
md: "gap-[var(--deframe-widget-size-gap-md)]",
|
|
2340
|
+
lg: "gap-[var(--deframe-widget-size-gap-lg)]"
|
|
2425
2341
|
};
|
|
2426
2342
|
var HistoryFlexCol = ({ children, className, gap = "xs" }) => /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "history-flex-col", className: tailwindMerge.twMerge("flex flex-col", gapClasses3[gap], className), children });
|
|
2427
|
-
var TransactionTypeLabel = ({ children }) => /* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "transaction-type-label", className: "
|
|
2428
|
-
var Amount = ({ children }) => /* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "amount", className: "
|
|
2429
|
-
var AmountInUsd = ({ children }) => /* @__PURE__ */ jsxRuntime.jsxs("p", { "data-test-id": "amount-in-usd", className: "
|
|
2343
|
+
var TransactionTypeLabel = ({ children }) => /* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "transaction-type-label", className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]", children });
|
|
2344
|
+
var Amount = ({ children }) => /* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "amount", className: "[font-size:var(--deframe-widget-font-size-md)] [line-height:var(--deframe-widget-font-leading-md)] [font-weight:var(--deframe-widget-font-weight-medium)] text-[color:var(--deframe-widget-color-text-secondary)]", children });
|
|
2345
|
+
var AmountInUsd = ({ children }) => /* @__PURE__ */ jsxRuntime.jsxs("p", { "data-test-id": "amount-in-usd", className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
2430
2346
|
"~ ",
|
|
2431
2347
|
children
|
|
2432
2348
|
] });
|
|
@@ -2436,16 +2352,16 @@ var TokenIcon = ({ src, alt }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
2436
2352
|
"data-test-id": "token-icon",
|
|
2437
2353
|
src,
|
|
2438
2354
|
alt,
|
|
2439
|
-
className: "w-8 h-8 rounded-full",
|
|
2355
|
+
className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]",
|
|
2440
2356
|
onError: (e) => {
|
|
2441
2357
|
const fallbackText = encodeURIComponent((alt || "TOK").slice(0, 3).toUpperCase());
|
|
2442
2358
|
e.target.src = `https://placehold.co/40x40?text=${fallbackText}`;
|
|
2443
2359
|
}
|
|
2444
2360
|
}
|
|
2445
2361
|
);
|
|
2446
|
-
var SuccessBadge = ({ children }) => /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "success-badge", className: "bg-[
|
|
2447
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "w-2 h-2 rounded-full bg-state-success" }),
|
|
2448
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
2362
|
+
var SuccessBadge = ({ children }) => /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "success-badge", className: "bg-[color:color-mix(in_srgb,var(--deframe-widget-color-state-success)_12%,transparent)] flex items-center gap-[var(--deframe-widget-size-gap-xs)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] rounded-[var(--deframe-widget-size-radius-lg)]", children: [
|
|
2363
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "w-2 h-2 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-state-success)]" }),
|
|
2364
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-primary)]", children })
|
|
2449
2365
|
] });
|
|
2450
2366
|
var truncateHash = (hash, chars = 6) => {
|
|
2451
2367
|
if (hash.length <= chars * 2 + 3) return hash;
|
|
@@ -2453,15 +2369,15 @@ var truncateHash = (hash, chars = 6) => {
|
|
|
2453
2369
|
};
|
|
2454
2370
|
var TransactionId = ({ hash }) => {
|
|
2455
2371
|
if (!hash) {
|
|
2456
|
-
return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-test-id": "transaction-id", className: "
|
|
2372
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-test-id": "transaction-id", className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-primary)]", children: "-" });
|
|
2457
2373
|
}
|
|
2458
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "transaction-id", className: "flex items-center gap-xs", children: [
|
|
2459
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
2374
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": "transaction-id", className: "flex items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
2375
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-primary)]", children: truncateHash(hash) }),
|
|
2460
2376
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2461
2377
|
AddressDisplay,
|
|
2462
2378
|
{
|
|
2463
2379
|
address: hash,
|
|
2464
|
-
className: "border-none bg-transparent
|
|
2380
|
+
className: "border-none bg-transparent px-[var(--deframe-widget-size-padding-x-none)] py-[var(--deframe-widget-size-padding-y-none)] gap-[var(--deframe-widget-size-gap-none)]",
|
|
2465
2381
|
textClassName: "hidden"
|
|
2466
2382
|
}
|
|
2467
2383
|
)
|
|
@@ -2474,13 +2390,13 @@ var ExplorerLink = ({ href, children }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
2474
2390
|
href,
|
|
2475
2391
|
target: "_blank",
|
|
2476
2392
|
rel: "noopener noreferrer",
|
|
2477
|
-
className: "text-brand-primary underline
|
|
2393
|
+
className: "text-[color:var(--deframe-widget-color-brand-primary)] underline [font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] [font-weight:var(--deframe-widget-font-weight-semibold)] font-[var(--deframe-widget-font-family)]",
|
|
2478
2394
|
children
|
|
2479
2395
|
}
|
|
2480
2396
|
);
|
|
2481
2397
|
var TwoLineValue = ({ primary, secondary }) => /* @__PURE__ */ jsxRuntime.jsxs(HistoryFlexCol, { className: "items-end", children: [
|
|
2482
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "two-line-value-primary", className: "
|
|
2483
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "two-line-value-secondary", className: "
|
|
2398
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "two-line-value-primary", className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)] [font-weight:var(--deframe-widget-font-weight-semibold)]", children: primary }),
|
|
2399
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-test-id": "two-line-value-secondary", className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]", children: secondary })
|
|
2484
2400
|
] });
|
|
2485
2401
|
var HistoryDepositDetailsView = ({
|
|
2486
2402
|
transactionTypeLabel,
|
|
@@ -2535,7 +2451,7 @@ var HistoryDepositDetailsView = ({
|
|
|
2535
2451
|
] }) })
|
|
2536
2452
|
] })
|
|
2537
2453
|
] }) }),
|
|
2538
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!
|
|
2454
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)]", children: /* @__PURE__ */ jsxRuntime.jsxs(FlexCol, { gap: "sm", children: [
|
|
2539
2455
|
/* @__PURE__ */ jsxRuntime.jsxs(InfoRow, { borderBottom: true, children: [
|
|
2540
2456
|
/* @__PURE__ */ jsxRuntime.jsx(InfoLabel, { children: labels.currencyLabel }),
|
|
2541
2457
|
/* @__PURE__ */ jsxRuntime.jsx(InfoValue, { children: symbol })
|
|
@@ -2625,7 +2541,7 @@ var HistoryWithdrawDetailsView = ({
|
|
|
2625
2541
|
] }) })
|
|
2626
2542
|
] })
|
|
2627
2543
|
] }) }),
|
|
2628
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!
|
|
2544
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)]", children: /* @__PURE__ */ jsxRuntime.jsxs(FlexCol, { gap: "sm", children: [
|
|
2629
2545
|
/* @__PURE__ */ jsxRuntime.jsxs(InfoRow, { borderBottom: true, children: [
|
|
2630
2546
|
/* @__PURE__ */ jsxRuntime.jsx(InfoLabel, { children: labels.currencyLabel }),
|
|
2631
2547
|
/* @__PURE__ */ jsxRuntime.jsx(InfoValue, { children: symbol })
|
|
@@ -2670,21 +2586,21 @@ var SwapNetworkSelectorView = ({
|
|
|
2670
2586
|
testId = "swap-network-selector",
|
|
2671
2587
|
className
|
|
2672
2588
|
}) => {
|
|
2673
|
-
const baseClasses = "flex flex-row items-center gap-xs";
|
|
2589
|
+
const baseClasses = "flex flex-row items-center gap-[var(--deframe-widget-size-gap-xs)]";
|
|
2674
2590
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-test-id": testId, className: tailwindMerge.twMerge(baseClasses, className), children: [
|
|
2675
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "
|
|
2591
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", className: "tracking-wide text-[color:var(--deframe-widget-color-text-tertiary)]", children: directionLabel }),
|
|
2676
2592
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2677
2593
|
"button",
|
|
2678
2594
|
{
|
|
2679
2595
|
"data-testid": testId,
|
|
2680
2596
|
type: "button",
|
|
2681
2597
|
onClick,
|
|
2682
|
-
className: "ml-
|
|
2598
|
+
className: "ml-[var(--deframe-widget-size-gap-lg)] bg-[var(--deframe-widget-color-bg-tertiary)] border border-[color:var(--deframe-widget-color-border-tertiary)] rounded-[var(--deframe-widget-size-radius-md)] flex items-center gap-[var(--deframe-widget-size-gap-xs)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] hover:border-[color:var(--deframe-widget-color-border-secondary)] transition-colors [font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)] cursor-pointer",
|
|
2683
2599
|
"aria-label": `${directionLabel} ${chainLabel}`,
|
|
2684
2600
|
children: [
|
|
2685
|
-
chainImage ? /* @__PURE__ */ jsxRuntime.jsx("img", { src: chainImage, alt: chainLabel, className: "w-3 h-3 rounded-full" }) : null,
|
|
2601
|
+
chainImage ? /* @__PURE__ */ jsxRuntime.jsx("img", { src: chainImage, alt: chainLabel, className: "w-3 h-3 rounded-[var(--deframe-widget-size-radius-full)]" }) : null,
|
|
2686
2602
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children: chainLabel }),
|
|
2687
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronDown, { className: "w-3 h-3 text-
|
|
2603
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronDown, { className: "w-3 h-3 text-[color:var(--deframe-widget-color-text-tertiary)]" }) })
|
|
2688
2604
|
]
|
|
2689
2605
|
}
|
|
2690
2606
|
)
|
|
@@ -2695,10 +2611,10 @@ var SwapQuoteHeaderView = ({
|
|
|
2695
2611
|
timerElement,
|
|
2696
2612
|
className
|
|
2697
2613
|
}) => {
|
|
2698
|
-
const baseClasses = "border-b border-
|
|
2614
|
+
const baseClasses = "border-b border-[color:var(--deframe-widget-color-border-secondary)] pb-[var(--deframe-widget-size-padding-y-sm)]";
|
|
2699
2615
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "swap-quote-header", className: tailwindMerge.twMerge(baseClasses, className), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
2700
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "
|
|
2701
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-md", children: timerElement })
|
|
2616
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", className: "[font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-secondary)] inline-flex items-center", children: label }),
|
|
2617
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-[var(--deframe-widget-size-gap-md)]", children: timerElement })
|
|
2702
2618
|
] }) });
|
|
2703
2619
|
};
|
|
2704
2620
|
var SwapAmountInputView = ({
|
|
@@ -2729,8 +2645,8 @@ var SwapAmountInputView = ({
|
|
|
2729
2645
|
}
|
|
2730
2646
|
return val;
|
|
2731
2647
|
};
|
|
2732
|
-
const baseClasses = "
|
|
2733
|
-
const colorClasses = hasError ? "text-
|
|
2648
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] bg-transparent outline-none text-right w-full min-w-[120px] placeholder:text-[color:var(--deframe-widget-color-text-primary-disabled)]";
|
|
2649
|
+
const colorClasses = hasError ? "text-[color:var(--deframe-widget-color-state-error)]" : "text-[color:var(--deframe-widget-color-text-primary)]";
|
|
2734
2650
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2735
2651
|
"input",
|
|
2736
2652
|
__spreadProps(__spreadValues({
|
|
@@ -2765,8 +2681,8 @@ var SwapOutputAmountView = ({
|
|
|
2765
2681
|
searchingQuoteLabel = "Searching quote...",
|
|
2766
2682
|
className
|
|
2767
2683
|
}) => {
|
|
2768
|
-
const baseClasses = "
|
|
2769
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "swap-flow-output-amount", className: tailwindMerge.twMerge(baseClasses, className), children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "
|
|
2684
|
+
const baseClasses = "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] text-right w-full min-w-[120px] text-[color:var(--deframe-widget-color-text-primary)]";
|
|
2685
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "swap-flow-output-amount", className: tailwindMerge.twMerge(baseClasses, className), children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", className: "text-[color:var(--deframe-widget-color-text-primary-disabled)] inline-flex items-center", children: loadingElement != null ? loadingElement : searchingQuoteLabel }) : displayOutput });
|
|
2770
2686
|
};
|
|
2771
2687
|
var SwapQuoteErrorsView = ({
|
|
2772
2688
|
hasQuoteError,
|
|
@@ -2800,12 +2716,12 @@ var SwapSlippageToleranceButtonsView = ({
|
|
|
2800
2716
|
formatPercentage,
|
|
2801
2717
|
className
|
|
2802
2718
|
}) => {
|
|
2803
|
-
const baseClasses = "flex gap-xs";
|
|
2719
|
+
const baseClasses = "flex gap-[var(--deframe-widget-size-gap-xs)]";
|
|
2804
2720
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "swap-slippage-tolerance-buttons", className: tailwindMerge.twMerge(baseClasses, className), children: SLIPPAGE_OPTIONS.map((option) => {
|
|
2805
2721
|
const isActive = slippageBps === option;
|
|
2806
|
-
const activeClasses = "border-brand-primary text-brand-primary bg-
|
|
2807
|
-
const inactiveClasses = "border-
|
|
2808
|
-
const buttonBase = "px-sm py-xs rounded border
|
|
2722
|
+
const activeClasses = "border-[color:var(--deframe-widget-color-brand-primary)] text-[color:var(--deframe-widget-color-brand-primary)] bg-[color:color-mix(in_srgb,var(--deframe-widget-color-brand-primary)_18%,transparent)]";
|
|
2723
|
+
const inactiveClasses = "border-[color:var(--deframe-widget-color-border-tertiary)] text-[color:var(--deframe-widget-color-text-secondary)] bg-[var(--deframe-widget-color-bg-primary)]";
|
|
2724
|
+
const buttonBase = "px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-xs)] rounded-[var(--deframe-widget-size-radius-xs)] border [font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] cursor-pointer";
|
|
2809
2725
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2810
2726
|
"button",
|
|
2811
2727
|
{
|
|
@@ -2828,7 +2744,7 @@ var SwapTokenSelectorView = ({
|
|
|
2828
2744
|
selectTokenLabel = "Select token",
|
|
2829
2745
|
className
|
|
2830
2746
|
}) => {
|
|
2831
|
-
const baseClasses = "h-[56px] border border-border-
|
|
2747
|
+
const baseClasses = "h-[56px] border border-[color:var(--deframe-widget-color-border-secondary)] rounded-[var(--deframe-widget-size-radius-xs)] overflow-hidden hover:border-[color:var(--deframe-widget-color-border-primary)] transition-colors flex items-center px-[var(--deframe-widget-size-padding-x-sm)] py-[6px] w-full cursor-pointer";
|
|
2832
2748
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2833
2749
|
"button",
|
|
2834
2750
|
{
|
|
@@ -2838,11 +2754,11 @@ var SwapTokenSelectorView = ({
|
|
|
2838
2754
|
className: tailwindMerge.twMerge(baseClasses, className),
|
|
2839
2755
|
"aria-label": token ? token.symbol : selectTokenLabel,
|
|
2840
2756
|
children: [
|
|
2841
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-sm flex-1", children: token ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2842
|
-
token.logoURI ? /* @__PURE__ */ jsxRuntime.jsx("img", { src: token.logoURI, alt: token.symbol, className: "w-6 h-6 rounded-full" }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-
|
|
2843
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-
|
|
2844
|
-
] }) : /* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-
|
|
2845
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronDown, { className: "w-3 h-3 text-
|
|
2757
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-[var(--deframe-widget-size-gap-sm)] flex-1", children: token ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2758
|
+
token.logoURI ? /* @__PURE__ */ jsxRuntime.jsx("img", { src: token.logoURI, alt: token.symbol, className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)]" }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-bg-secondary)] text-[color:var(--deframe-widget-color-text-secondary)] flex items-center justify-center text-[10px] [font-weight:var(--deframe-widget-font-weight-semibold)]", children: (token.symbol || "").slice(0, 3).toUpperCase() }),
|
|
2759
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-[color:var(--deframe-widget-color-text-primary)]", children: token.symbol })
|
|
2760
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-[color:var(--deframe-widget-color-text-secondary)]", children: selectTokenLabel }) }),
|
|
2761
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center w-[18px] h-[18px]", children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiChevronDown, { className: "w-3 h-3 text-[color:var(--deframe-widget-color-text-tertiary)]" }) })
|
|
2846
2762
|
]
|
|
2847
2763
|
}
|
|
2848
2764
|
);
|
|
@@ -2866,7 +2782,7 @@ var SwapQuoteBlockchainCostsView = ({
|
|
|
2866
2782
|
defaultOpen: true,
|
|
2867
2783
|
collapseLabel,
|
|
2868
2784
|
expandLabel,
|
|
2869
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-sm", children: [
|
|
2785
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
2870
2786
|
/* @__PURE__ */ jsxRuntime.jsxs(InfoRowWithIcon, { children: [
|
|
2871
2787
|
/* @__PURE__ */ jsxRuntime.jsx(InfoRowIconLabel, { children: networkGasLabel }),
|
|
2872
2788
|
/* @__PURE__ */ jsxRuntime.jsx(InfoRowIconValue, { children: gasCostFormatted })
|
|
@@ -2879,6 +2795,19 @@ var SwapQuoteBlockchainCostsView = ({
|
|
|
2879
2795
|
}
|
|
2880
2796
|
) });
|
|
2881
2797
|
};
|
|
2798
|
+
var CloseButton = ({ onClick, testId, ariaLabel = "Close", className }) => {
|
|
2799
|
+
const baseClasses = "w-12 h-12 rounded-[var(--deframe-widget-size-radius-full)] flex items-center justify-center text-[color:var(--deframe-widget-color-text-secondary)] hover:text-[color:var(--deframe-widget-color-brand-primary)] transition-colors cursor-pointer";
|
|
2800
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2801
|
+
"button",
|
|
2802
|
+
{
|
|
2803
|
+
"data-test-id": testId != null ? testId : "close-button",
|
|
2804
|
+
onClick,
|
|
2805
|
+
className: tailwindMerge.twMerge(baseClasses, className),
|
|
2806
|
+
"aria-label": ariaLabel,
|
|
2807
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(hi2.HiXMark, { className: "w-6 h-6" })
|
|
2808
|
+
}
|
|
2809
|
+
);
|
|
2810
|
+
};
|
|
2882
2811
|
var ChooseAStrategyActionsheetView = ({
|
|
2883
2812
|
isOpen,
|
|
2884
2813
|
currentActionSheetId,
|
|
@@ -2912,19 +2841,19 @@ var ChooseAStrategyActionsheetView = ({
|
|
|
2912
2841
|
contentClassName: "w-full max-w-[620px] mx-auto",
|
|
2913
2842
|
children: /* @__PURE__ */ jsxRuntime.jsxs(BackgroundContainer, { className: "flex flex-col h-full", children: [
|
|
2914
2843
|
/* @__PURE__ */ jsxRuntime.jsx(Navbar, { children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { onClick: onClose, ariaLabel: closeAriaLabel }) }),
|
|
2915
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col flex-1 w-full
|
|
2844
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col flex-1 w-full px-[var(--deframe-widget-size-padding-x-lg)] py-[var(--deframe-widget-size-padding-y-lg)] overflow-hidden", children: [
|
|
2916
2845
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-shrink-0", children: [
|
|
2917
2846
|
/* @__PURE__ */ jsxRuntime.jsx(TextHeading, { children: resolvedYieldLabel }),
|
|
2918
2847
|
/* @__PURE__ */ jsxRuntime.jsx("br", {})
|
|
2919
2848
|
] }),
|
|
2920
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col gap-
|
|
2921
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemLeftSide, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: logoUrl, alt: assetName, className: "w-10 h-10 rounded-full" }) }),
|
|
2922
|
-
/* @__PURE__ */ jsxRuntime.jsxs(ListItemContent, { className: "gap-
|
|
2849
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col gap-[var(--deframe-widget-size-gap-sm)] w-full mt-[var(--deframe-widget-size-gap-md)] overflow-y-auto flex-1 min-h-0", children: /* @__PURE__ */ jsxRuntime.jsxs(ListItem, { className: "flex-shrink-0", onClick: onStrategyClick, children: [
|
|
2850
|
+
/* @__PURE__ */ jsxRuntime.jsx(ListItemLeftSide, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: logoUrl, alt: assetName, className: "w-10 h-10 rounded-[var(--deframe-widget-size-radius-full)]" }) }),
|
|
2851
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ListItemContent, { className: "gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
2923
2852
|
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { children: resolvedYieldLabel }),
|
|
2924
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
2853
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: Badge })
|
|
2925
2854
|
] }),
|
|
2926
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemRightSide, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-center items-center gap-
|
|
2927
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-state-success", children: [
|
|
2855
|
+
/* @__PURE__ */ jsxRuntime.jsx(ListItemRightSide, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-center items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
2856
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[color:var(--deframe-widget-color-state-success)]", children: [
|
|
2928
2857
|
apy,
|
|
2929
2858
|
"% ",
|
|
2930
2859
|
apyLabel
|
|
@@ -2951,23 +2880,23 @@ var StrategyDetailsView = ({
|
|
|
2951
2880
|
}) => {
|
|
2952
2881
|
return /* @__PURE__ */ jsxRuntime.jsxs(BackgroundContainer, { children: [
|
|
2953
2882
|
/* @__PURE__ */ jsxRuntime.jsx(DetailsHeader, { title: headerTitle, onBack, backAriaLabel }),
|
|
2954
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "strategy-details-content", className: "flex-1 min-h-0 overflow-y-auto
|
|
2955
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "inline-flex flex-col items-start gap-sm", children: [
|
|
2956
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { "data-test-id": "strategy-logo", src: logoUrl, alt: title, className: "w-20 h-20 rounded-full" }),
|
|
2883
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "strategy-details-content", className: "flex-1 min-h-0 overflow-y-auto px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)] py-[var(--deframe-widget-size-padding-y-lg)] pb-[var(--deframe-widget-size-padding-y-xxl)]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-[var(--deframe-widget-size-gap-lg)] min-h-full", children: [
|
|
2884
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "inline-flex flex-col items-start gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
2885
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { "data-test-id": "strategy-logo", src: logoUrl, alt: title, className: "w-20 h-20 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
2957
2886
|
/* @__PURE__ */ jsxRuntime.jsx(TextHeading, { variant: "h5", children: title })
|
|
2958
2887
|
] }),
|
|
2959
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
2888
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: description }),
|
|
2960
2889
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2961
2890
|
SummaryDetails,
|
|
2962
2891
|
{
|
|
2963
2892
|
title: strategyInfoTitle,
|
|
2964
2893
|
items: strategyInfo,
|
|
2965
2894
|
defaultOpen: true,
|
|
2966
|
-
className: "bg-
|
|
2895
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]"
|
|
2967
2896
|
}
|
|
2968
2897
|
)
|
|
2969
2898
|
] }) }),
|
|
2970
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "strategy-details-footer", className: "sticky bottom-0 left-0 right-0 border-t border-
|
|
2899
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { "data-test-id": "strategy-details-footer", className: "sticky bottom-0 left-0 right-0 border-t border-[color:var(--deframe-widget-color-border-tertiary)] px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)]", children: /* @__PURE__ */ jsxRuntime.jsx(PrimaryButton, { onClick: onDeposit, className: "w-full", children: depositButtonLabel }) })
|
|
2971
2900
|
] });
|
|
2972
2901
|
};
|
|
2973
2902
|
var ProgressIndicator = ({
|
|
@@ -2979,15 +2908,15 @@ var ProgressIndicator = ({
|
|
|
2979
2908
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2980
2909
|
"div",
|
|
2981
2910
|
{
|
|
2982
|
-
className: "h-[4px] bg-brand-primary rounded-
|
|
2911
|
+
className: "h-[4px] bg-[var(--deframe-widget-color-brand-primary)] rounded-[var(--deframe-widget-size-radius-md)] transition-all duration-300",
|
|
2983
2912
|
style: { width: `${clampedProgress}%` }
|
|
2984
2913
|
}
|
|
2985
2914
|
),
|
|
2986
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 h-[4px] bg-
|
|
2915
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 h-[4px] bg-[var(--deframe-widget-color-bg-tertiary)] rounded-[var(--deframe-widget-size-radius-md)] ml-[var(--deframe-widget-size-gap-xs)]" })
|
|
2987
2916
|
] }) });
|
|
2988
2917
|
};
|
|
2989
2918
|
var LoadingDots = ({ className = "" }) => {
|
|
2990
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: `flex gap-
|
|
2919
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: `flex gap-[var(--deframe-widget-size-gap-none)].5 ${className}`, children: [
|
|
2991
2920
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "animate-bounce", style: { animationDelay: "0ms", animationDuration: "1.4s" }, children: "." }),
|
|
2992
2921
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "animate-bounce", style: { animationDelay: "200ms", animationDuration: "1.4s" }, children: "." }),
|
|
2993
2922
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "animate-bounce", style: { animationDelay: "400ms", animationDuration: "1.4s" }, children: "." })
|
|
@@ -3028,28 +2957,28 @@ var SearchInput = ({
|
|
|
3028
2957
|
autoFocus,
|
|
3029
2958
|
onChange: (e) => handleInputChange(e.target.value),
|
|
3030
2959
|
className: [
|
|
3031
|
-
"w-full h-full rounded
|
|
3032
|
-
!inputClassName ? "bg-
|
|
3033
|
-
"placeholder:text-
|
|
2960
|
+
"w-full h-full rounded-[var(--deframe-widget-size-radius-xs)] px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-md)] pr-[var(--deframe-widget-size-padding-x-xxl)] leading-normal tracking-wide",
|
|
2961
|
+
!inputClassName ? "bg-[var(--deframe-widget-color-bg-secondary)]" : "",
|
|
2962
|
+
"placeholder:text-[color:var(--deframe-widget-color-text-primary-disabled)] text-[color:var(--deframe-widget-color-text-primary)]",
|
|
3034
2963
|
"focus:outline-none focus:ring-2 focus:ring-brand-primary",
|
|
3035
2964
|
disabled ? "cursor-not-allowed opacity-50" : "",
|
|
3036
2965
|
inputClassName || ""
|
|
3037
2966
|
].filter(Boolean).join(" ")
|
|
3038
2967
|
}
|
|
3039
2968
|
),
|
|
3040
|
-
/* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSearch, { className: "w-4 h-4 text-text-secondary absolute right-4" })
|
|
2969
|
+
/* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSearch, { className: "w-4 h-4 text-[color:var(--deframe-widget-color-text-secondary)] absolute right-4" })
|
|
3041
2970
|
] });
|
|
3042
2971
|
};
|
|
3043
2972
|
var SearchEmptyState = ({
|
|
3044
2973
|
title,
|
|
3045
2974
|
description
|
|
3046
2975
|
}) => {
|
|
3047
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full py-md bg-
|
|
3048
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col justify-center items-center gap-md text-center", children: [
|
|
3049
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-20 h-20 bg-
|
|
2976
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full py-[var(--deframe-widget-size-padding-y-md)] bg-[var(--deframe-widget-color-bg-primary)] rounded-[var(--deframe-widget-size-radius-md)] flex flex-col justify-center items-center gap-[var(--deframe-widget-size-gap-sm)] h-full", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full flex flex-col justify-center items-center gap-[var(--deframe-widget-size-gap-md)] py-[var(--deframe-widget-size-padding-y-xxl)]", children: [
|
|
2977
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col justify-center items-center gap-[var(--deframe-widget-size-gap-md)] text-center", children: [
|
|
2978
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-20 h-20 bg-[var(--deframe-widget-color-bg-tertiary)] rounded-[var(--deframe-widget-size-radius-full)] flex justify-center items-center", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSearchOff, { className: "w-10 h-10 text-[color:var(--deframe-widget-color-text-tertiary)]" }) }),
|
|
3050
2979
|
/* @__PURE__ */ jsxRuntime.jsx(TextHeading, { variant: "h3", children: title })
|
|
3051
2980
|
] }),
|
|
3052
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "self-stretch text-center", children: /* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
2981
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "self-stretch text-center", children: /* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: description }) })
|
|
3053
2982
|
] }) });
|
|
3054
2983
|
};
|
|
3055
2984
|
var CollapsibleSection = ({
|
|
@@ -3072,7 +3001,7 @@ var CollapsibleSection = ({
|
|
|
3072
3001
|
}
|
|
3073
3002
|
onOpenChange == null ? void 0 : onOpenChange(newOpenState);
|
|
3074
3003
|
};
|
|
3075
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `flex flex-col gap-sm w-full ${className}`, children: [
|
|
3004
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `flex flex-col gap-[var(--deframe-widget-size-gap-sm)] w-full ${className}`, children: [
|
|
3076
3005
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
3077
3006
|
"button",
|
|
3078
3007
|
{
|
|
@@ -3082,13 +3011,13 @@ var CollapsibleSection = ({
|
|
|
3082
3011
|
"aria-expanded": isOpen,
|
|
3083
3012
|
"aria-label": `${isOpen ? collapseText : expandText} ${title}`,
|
|
3084
3013
|
children: [
|
|
3085
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-xs", children: /* @__PURE__ */ jsxRuntime.jsx(TextBody, { className: "text-
|
|
3086
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-xs", children: [
|
|
3087
|
-
subtitle && /* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
3014
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-[var(--deframe-widget-size-gap-xs)]", children: /* @__PURE__ */ jsxRuntime.jsx(TextBody, { className: "text-[color:var(--deframe-widget-color-text-primary-dark)] [font-weight:var(--deframe-widget-font-weight-medium)]", children: title }) }),
|
|
3015
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3016
|
+
subtitle && /* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: subtitle }),
|
|
3088
3017
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3089
3018
|
framerMotion.motion.svg,
|
|
3090
3019
|
{
|
|
3091
|
-
className: "w-5 h-5 text-
|
|
3020
|
+
className: "w-5 h-5 text-[color:var(--deframe-widget-color-text-secondary)]",
|
|
3092
3021
|
fill: "none",
|
|
3093
3022
|
stroke: "currentColor",
|
|
3094
3023
|
viewBox: "0 0 24 24",
|
|
@@ -3116,15 +3045,15 @@ var CollapsibleSection = ({
|
|
|
3116
3045
|
};
|
|
3117
3046
|
var TransactionScreenIcon = ({
|
|
3118
3047
|
type,
|
|
3119
|
-
gradient = "linear-gradient(135deg,
|
|
3048
|
+
gradient = "linear-gradient(135deg, var(--deframe-widget-color-state-warning) 0%, color-mix(in srgb, var(--deframe-widget-color-state-warning) 78%, black) 100%)"
|
|
3120
3049
|
}) => {
|
|
3121
3050
|
if (type === "success") {
|
|
3122
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-20 h-20", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-full bg-brand-primary flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-8 h-8 text-
|
|
3051
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-20 h-20", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-brand-primary)] flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-8 h-8 text-[color:var(--deframe-widget-color-text-primary-dark)]", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 3, children: /* @__PURE__ */ jsxRuntime.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M5 13l4 4L19 7" }) }) }) });
|
|
3123
3052
|
}
|
|
3124
3053
|
if (type === "warning") {
|
|
3125
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-[83px] h-[83px]", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-full flex items-center justify-center", style: { background: gradient }, children: /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-8 h-8 text-
|
|
3054
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-[83px] h-[83px]", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-[var(--deframe-widget-size-radius-full)] flex items-center justify-center", style: { background: gradient }, children: /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-8 h-8 text-[color:var(--deframe-widget-color-bg-primary)]", fill: "currentColor", viewBox: "0 0 32 32", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M16 5.33334C15.6444 5.33334 15.3111 5.51112 15.1111 5.8L5.11112 21.8C4.91112 22.0889 4.91112 22.4667 5.11112 22.7556C5.31112 23.0444 5.64445 23.2222 6.00001 23.2222H26C26.3556 23.2222 26.6889 23.0444 26.8889 22.7556C27.0889 22.4667 27.0889 22.0889 26.8889 21.8L16.8889 5.8C16.6889 5.51112 16.3556 5.33334 16 5.33334ZM16 10.6667C16.5333 10.6667 17 11.1333 17 11.6667V16C17 16.5333 16.5333 17 16 17C15.4667 17 15 16.5333 15 16V11.6667C15 11.1333 15.4667 10.6667 16 10.6667ZM16 19.3333C16.7333 19.3333 17.3333 19.9333 17.3333 20.6667C17.3333 21.4 16.7333 22 16 22C15.2667 22 14.6667 21.4 14.6667 20.6667C14.6667 19.9333 15.2667 19.3333 16 19.3333Z" }) }) }) });
|
|
3126
3055
|
}
|
|
3127
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-[83px] h-[83px]", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-full flex items-center justify-center", style: { background: gradient }, children: /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "11", height: "10", viewBox: "0 0 11 10", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: "w-8 h-8 text-
|
|
3056
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-[83px] h-[83px]", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full rounded-[var(--deframe-widget-size-radius-full)] flex items-center justify-center", style: { background: gradient }, children: /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "11", height: "10", viewBox: "0 0 11 10", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: "w-8 h-8 text-[color:var(--deframe-widget-color-text-primary-dark)]", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M3.66659 8.33301H7.33325V7.08301C7.33325 6.62468 7.15374 6.23231 6.79471 5.90593C6.43568 5.57954 6.00409 5.41634 5.49992 5.41634C4.99575 5.41634 4.56415 5.57954 4.20513 5.90593C3.8461 6.23231 3.66659 6.62468 3.66659 7.08301V8.33301ZM5.49992 4.58301C6.00409 4.58301 6.43568 4.41981 6.79471 4.09342C7.15374 3.76704 7.33325 3.37467 7.33325 2.91634V1.66634H3.66659V2.91634C3.66659 3.37467 3.8461 3.76704 4.20513 4.09342C4.56415 4.41981 4.99575 4.58301 5.49992 4.58301ZM2.29159 9.16634C2.16172 9.16634 2.05287 9.12641 1.96502 9.04655C1.87718 8.96669 1.83325 8.86773 1.83325 8.74968C1.83325 8.63162 1.87718 8.53266 1.96502 8.4528C2.05287 8.37294 2.16172 8.33301 2.29159 8.33301H2.74992V7.08301C2.74992 6.6594 2.85877 6.26183 3.07648 5.8903C3.29419 5.51877 3.59784 5.2219 3.98742 4.99967C3.59784 4.77745 3.29419 4.48058 3.07648 4.10905C2.85877 3.73752 2.74992 3.33995 2.74992 2.91634V1.66634H2.29159C2.16172 1.66634 2.05287 1.62641 1.96502 1.54655C1.87718 1.46669 1.83325 1.36773 1.83325 1.24967C1.83325 1.13162 1.87718 1.03266 1.96502 0.952799C2.05287 0.872938 2.16172 0.833008 2.29159 0.833008H8.70825C8.83811 0.833008 8.94697 0.872938 9.03481 0.952799C9.12266 1.03266 9.16659 1.13162 9.16659 1.24967C9.16659 1.36773 9.12266 1.46669 9.03481 1.54655C8.94697 1.62641 8.83811 1.66634 8.70825 1.66634H8.24992V2.91634C8.24992 3.33995 8.14106 3.73752 7.92336 4.10905C7.70565 4.48058 7.402 4.77745 7.01242 4.99967C7.402 5.2219 7.70565 5.51877 7.92336 5.8903C8.14106 6.26183 8.24992 6.6594 8.24992 7.08301V8.33301H8.70825C8.83811 8.33301 8.94697 8.37294 9.03481 8.4528C9.12266 8.53266 9.16659 8.63162 9.16659 8.74968C9.16659 8.86773 9.12266 8.96669 9.03481 9.04655C8.94697 9.12641 8.83811 9.16634 8.70825 9.16634H2.29159Z", fill: "currentColor" }) }) }) });
|
|
3128
3057
|
};
|
|
3129
3058
|
var TransactionScreen = ({
|
|
3130
3059
|
progress,
|
|
@@ -3141,18 +3070,18 @@ var TransactionScreen = ({
|
|
|
3141
3070
|
}) => {
|
|
3142
3071
|
return /* @__PURE__ */ jsxRuntime.jsx(BackgroundContainer, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col h-full", children: [
|
|
3143
3072
|
onBack && /* @__PURE__ */ jsxRuntime.jsx(DetailsHeader, { title: backTitle, onBack }),
|
|
3144
|
-
onClose && /* @__PURE__ */ jsxRuntime.jsx("div", { "data-testid": testId, className: "flex justify-start px-md pt-md", children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { onClick: onClose }) }),
|
|
3145
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full px-md pt-sm", children: /* @__PURE__ */ jsxRuntime.jsx(ProgressIndicator, { progress }) }),
|
|
3146
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 overflow-y-auto px-md py-lg flex flex-col gap-lg", children: [
|
|
3147
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-md pt-lg", children: [
|
|
3073
|
+
onClose && /* @__PURE__ */ jsxRuntime.jsx("div", { "data-testid": testId, className: "flex justify-start px-[var(--deframe-widget-size-padding-x-md)] pt-md", children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { onClick: onClose }) }),
|
|
3074
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full px-[var(--deframe-widget-size-padding-x-md)] pt-[var(--deframe-widget-size-padding-y-sm)]", children: /* @__PURE__ */ jsxRuntime.jsx(ProgressIndicator, { progress }) }),
|
|
3075
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 overflow-y-auto px-[var(--deframe-widget-size-padding-x-md)] py-[var(--deframe-widget-size-padding-y-lg)] flex flex-col gap-[var(--deframe-widget-size-gap-lg)]", children: [
|
|
3076
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-md)] pt-lg", children: [
|
|
3148
3077
|
/* @__PURE__ */ jsxRuntime.jsx(TransactionScreenIcon, { type: iconType, gradient: iconGradient }),
|
|
3149
3078
|
/* @__PURE__ */ jsxRuntime.jsx(TextHeading, { variant: "h-large", children: title }),
|
|
3150
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3079
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-md)] [line-height:var(--deframe-widget-font-leading-md)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)] text-center", style: { maxWidth: "350px" }, children: description })
|
|
3151
3080
|
] }),
|
|
3152
3081
|
children,
|
|
3153
3082
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1" })
|
|
3154
3083
|
] }),
|
|
3155
|
-
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-md pb-md", children: actions })
|
|
3084
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-[var(--deframe-widget-size-padding-x-md)] pb-[var(--deframe-widget-size-padding-y-md)]", children: actions })
|
|
3156
3085
|
] }) });
|
|
3157
3086
|
};
|
|
3158
3087
|
var TransactionScreenInvestmentCard = ({
|
|
@@ -3171,19 +3100,19 @@ var TransactionScreenInvestmentCard = ({
|
|
|
3171
3100
|
const shouldShowImage = Boolean(iconSrc) && !hasImageError;
|
|
3172
3101
|
const fallbackLabel = (iconAlt || "?").slice(0, 1).toUpperCase();
|
|
3173
3102
|
return /* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
3174
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-start gap-xs", children: [
|
|
3175
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3176
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3103
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-start gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3104
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-lg)] [line-height:var(--deframe-widget-font-leading-lg)] [font-weight:var(--deframe-widget-font-weight-medium)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: strategyName }),
|
|
3105
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3177
3106
|
apyLabel,
|
|
3178
3107
|
" ",
|
|
3179
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-state-success", children: apyValue })
|
|
3108
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { as: "span", className: "text-[color:var(--deframe-widget-color-state-success)]", children: apyValue })
|
|
3180
3109
|
] })
|
|
3181
3110
|
] }),
|
|
3182
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-sm", children: [
|
|
3183
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-8 h-8 rounded-full bg-
|
|
3111
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3112
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-bg-tertiary)] flex items-center justify-center", children: shouldShowImage ? /* @__PURE__ */ jsxRuntime.jsx("img", { src: iconSrc, alt: iconAlt, className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)]", onError: () => setHasImageError(true) }) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-xs)] [line-height:var(--deframe-widget-font-leading-xs)] [font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-text-secondary)]", children: fallbackLabel }) }),
|
|
3184
3113
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-end", children: [
|
|
3185
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3186
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3114
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: amountUSD }),
|
|
3115
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: amountToken })
|
|
3187
3116
|
] })
|
|
3188
3117
|
] })
|
|
3189
3118
|
] }) });
|
|
@@ -3191,11 +3120,11 @@ var TransactionScreenInvestmentCard = ({
|
|
|
3191
3120
|
function StepStatusIcon({ status }) {
|
|
3192
3121
|
switch (status) {
|
|
3193
3122
|
case "completed":
|
|
3194
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-full bg-
|
|
3123
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-bg-tertiary)] flex items-center justify-center flex-shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx(io5.IoCheckmarkOutline, { className: "w-4 h-4 text-[color:var(--deframe-widget-color-state-success)]" }) });
|
|
3195
3124
|
case "processing":
|
|
3196
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-full bg-
|
|
3125
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-bg-tertiary)] flex items-center justify-center flex-shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx(io5.IoTimeOutline, { className: "w-4 h-4 text-[color:var(--deframe-widget-color-state-warning)]" }) });
|
|
3197
3126
|
case "failed":
|
|
3198
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-full bg-
|
|
3127
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-6 h-6 rounded-[var(--deframe-widget-size-radius-full)] bg-[var(--deframe-widget-color-bg-tertiary)] flex items-center justify-center flex-shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx(io5.IoAlertCircleOutline, { className: "w-4 h-4 text-[color:var(--deframe-widget-color-state-error)]" }) });
|
|
3199
3128
|
}
|
|
3200
3129
|
}
|
|
3201
3130
|
function StepStatusText({
|
|
@@ -3206,8 +3135,8 @@ function StepStatusText({
|
|
|
3206
3135
|
viewOnExplorerText
|
|
3207
3136
|
}) {
|
|
3208
3137
|
if (step.statusText) {
|
|
3209
|
-
const textColorClass2 = step.status === "completed" ? "text-
|
|
3210
|
-
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: `
|
|
3138
|
+
const textColorClass2 = step.status === "completed" ? "text-[color:var(--deframe-widget-color-text-primary)]" : step.status === "processing" ? "text-[color:var(--deframe-widget-color-text-secondary)]" : step.status === "failed" ? "text-[color:var(--deframe-widget-color-state-error)]" : "text-[color:var(--deframe-widget-color-text-primary-disabled)]";
|
|
3139
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: `[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] ${textColorClass2}`, children: step.statusText });
|
|
3211
3140
|
}
|
|
3212
3141
|
if (step.status === "completed" && step.explorerUrl) {
|
|
3213
3142
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -3216,24 +3145,24 @@ function StepStatusText({
|
|
|
3216
3145
|
href: step.explorerUrl,
|
|
3217
3146
|
target: "_blank",
|
|
3218
3147
|
rel: "noopener noreferrer",
|
|
3219
|
-
className: "
|
|
3148
|
+
className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-brand-primary)] underline hover:no-underline",
|
|
3220
3149
|
children: viewOnExplorerText
|
|
3221
3150
|
}
|
|
3222
3151
|
);
|
|
3223
3152
|
}
|
|
3224
3153
|
const defaultText = step.status === "completed" ? completedText : step.status === "processing" ? processingText : failedText;
|
|
3225
|
-
const textColorClass = step.status === "completed" ? "text-
|
|
3226
|
-
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: `
|
|
3154
|
+
const textColorClass = step.status === "completed" ? "text-[color:var(--deframe-widget-color-text-primary)]" : step.status === "processing" ? "text-[color:var(--deframe-widget-color-text-secondary)]" : "text-[color:var(--deframe-widget-color-state-error)]";
|
|
3155
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: `[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] ${textColorClass}`, children: defaultText });
|
|
3227
3156
|
}
|
|
3228
3157
|
function StepDisplay({ step, completedText, processingText, failedText, viewOnExplorerText }) {
|
|
3229
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-
|
|
3230
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "
|
|
3231
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-shrink-0", children: step.value ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
3158
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-[var(--deframe-widget-size-gap-md)] w-full", children: [
|
|
3159
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-primary)] [font-weight:var(--deframe-widget-font-weight-medium)]", children: step.label }) }),
|
|
3160
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-shrink-0", children: step.value ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] text-[color:var(--deframe-widget-color-text-secondary)]", children: step.value }) : /* @__PURE__ */ jsxRuntime.jsx(StepStatusText, { step, completedText, processingText, failedText, viewOnExplorerText }) })
|
|
3232
3161
|
] });
|
|
3233
3162
|
}
|
|
3234
3163
|
function TransactionProcessingDetails({
|
|
3235
3164
|
steps,
|
|
3236
|
-
className = "bg-
|
|
3165
|
+
className = "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3237
3166
|
defaultOpen = true,
|
|
3238
3167
|
labels
|
|
3239
3168
|
}) {
|
|
@@ -3241,19 +3170,19 @@ function TransactionProcessingDetails({
|
|
|
3241
3170
|
return null;
|
|
3242
3171
|
}
|
|
3243
3172
|
const getProcessingSteps = () => {
|
|
3244
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col w-full", children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-
|
|
3173
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col w-full", children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3245
3174
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center", children: [
|
|
3246
3175
|
step.status && /* @__PURE__ */ jsxRuntime.jsx(StepStatusIcon, { status: step.status }),
|
|
3247
|
-
index < steps.length - 1 && step.status && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-px flex-1 min-h-[16px] bg-
|
|
3176
|
+
index < steps.length - 1 && step.status && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-px flex-1 min-h-[16px] bg-[var(--deframe-widget-color-bg-primary-dark)] my-[var(--deframe-widget-size-gap-xs)]" })
|
|
3248
3177
|
] }),
|
|
3249
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 pb-
|
|
3178
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 pb-[var(--deframe-widget-size-padding-y-sm)] min-w-0", children: /* @__PURE__ */ jsxRuntime.jsx(StepDisplay, { step, completedText: labels.completedText, processingText: labels.processingText, failedText: labels.failedText, viewOnExplorerText: labels.viewOnExplorerText }) })
|
|
3250
3179
|
] }, `step-${index}`)) });
|
|
3251
3180
|
};
|
|
3252
3181
|
const items = [
|
|
3253
3182
|
{
|
|
3254
3183
|
label: "",
|
|
3255
3184
|
value: getProcessingSteps(),
|
|
3256
|
-
valueClassName: "flex flex-col gap-
|
|
3185
|
+
valueClassName: "flex flex-col gap-[var(--deframe-widget-size-gap-none)] w-full"
|
|
3257
3186
|
}
|
|
3258
3187
|
];
|
|
3259
3188
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -3280,7 +3209,7 @@ var TokenWithChainBadge = ({
|
|
|
3280
3209
|
{
|
|
3281
3210
|
src: tokenLogoUrl || fallbackSrc,
|
|
3282
3211
|
alt: tokenAlt || "",
|
|
3283
|
-
className: "object-cover w-10 h-10 rounded-full",
|
|
3212
|
+
className: "object-cover w-10 h-10 rounded-[var(--deframe-widget-size-radius-full)]",
|
|
3284
3213
|
onError: (e) => {
|
|
3285
3214
|
e.target.src = fallbackSrc;
|
|
3286
3215
|
}
|
|
@@ -3291,7 +3220,7 @@ var TokenWithChainBadge = ({
|
|
|
3291
3220
|
{
|
|
3292
3221
|
src: chainLogoUrl,
|
|
3293
3222
|
alt: chainName,
|
|
3294
|
-
className: "absolute object-cover w-6 h-6 p-px bg-
|
|
3223
|
+
className: "absolute object-cover w-6 h-6 p-px bg-[var(--deframe-widget-color-bg-primary-dark)] border rounded-[var(--deframe-widget-size-radius-full)] -bottom-1 -right-1 border-bg-default",
|
|
3295
3224
|
onError: (e) => {
|
|
3296
3225
|
e.target.style.display = "none";
|
|
3297
3226
|
}
|
|
@@ -3331,7 +3260,7 @@ var SwapProcessingView = ({
|
|
|
3331
3260
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
3332
3261
|
"span",
|
|
3333
3262
|
{
|
|
3334
|
-
className: "font-semibold underline underline-offset-2 cursor-pointer text-brand-primary",
|
|
3263
|
+
className: "[font-weight:var(--deframe-widget-font-weight-semibold)] underline underline-offset-2 cursor-pointer text-[color:var(--deframe-widget-color-brand-primary)]",
|
|
3335
3264
|
onClick: onGoToHistory,
|
|
3336
3265
|
children: [
|
|
3337
3266
|
activityHistoryText,
|
|
@@ -3341,29 +3270,29 @@ var SwapProcessingView = ({
|
|
|
3341
3270
|
)
|
|
3342
3271
|
] }),
|
|
3343
3272
|
children: [
|
|
3344
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-md", children: [
|
|
3345
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3346
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3347
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3348
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3273
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-[var(--deframe-widget-size-padding-x-md)]", children: [
|
|
3274
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3275
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3276
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3277
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3349
3278
|
formattedInputAmount,
|
|
3350
3279
|
" ",
|
|
3351
3280
|
fromTokenSymbol
|
|
3352
3281
|
] }),
|
|
3353
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3282
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedInputAmountUSD })
|
|
3354
3283
|
] })
|
|
3355
3284
|
] }),
|
|
3356
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-brand-secondary rounded-full
|
|
3357
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3358
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3359
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3360
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3285
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-[var(--deframe-widget-color-brand-secondary)] rounded-[var(--deframe-widget-size-radius-full)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] shadow-[0_10px_30px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_22%,transparent)] z-10", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSwapHoriz, { className: "w-5 h-5" }) }),
|
|
3286
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3287
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3288
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3289
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3361
3290
|
"~",
|
|
3362
3291
|
formattedOutputAmount,
|
|
3363
3292
|
" ",
|
|
3364
3293
|
toTokenSymbol
|
|
3365
3294
|
] }),
|
|
3366
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3295
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedOutputAmountUSD })
|
|
3367
3296
|
] })
|
|
3368
3297
|
] })
|
|
3369
3298
|
] }) }),
|
|
@@ -3371,7 +3300,7 @@ var SwapProcessingView = ({
|
|
|
3371
3300
|
TransactionProcessingDetails,
|
|
3372
3301
|
{
|
|
3373
3302
|
steps: transactionSteps,
|
|
3374
|
-
className: "bg-
|
|
3303
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3375
3304
|
labels: processingDetailsLabels
|
|
3376
3305
|
}
|
|
3377
3306
|
)
|
|
@@ -3416,7 +3345,7 @@ var SwapCrossChainProcessingView = ({
|
|
|
3416
3345
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3417
3346
|
"span",
|
|
3418
3347
|
{
|
|
3419
|
-
className: "font-semibold underline cursor-pointer underline-offset-2 text-brand-primary",
|
|
3348
|
+
className: "[font-weight:var(--deframe-widget-font-weight-semibold)] underline cursor-pointer underline-offset-2 text-[color:var(--deframe-widget-color-brand-primary)]",
|
|
3420
3349
|
onClick: onGoToHistory,
|
|
3421
3350
|
children: viewHistoryText
|
|
3422
3351
|
}
|
|
@@ -3424,8 +3353,8 @@ var SwapCrossChainProcessingView = ({
|
|
|
3424
3353
|
"."
|
|
3425
3354
|
] }),
|
|
3426
3355
|
children: [
|
|
3427
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex items-center justify-between w-full px-md", children: [
|
|
3428
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3356
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex items-center justify-between w-full px-[var(--deframe-widget-size-padding-x-md)]", children: [
|
|
3357
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3429
3358
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3430
3359
|
TokenWithChainBadge,
|
|
3431
3360
|
{
|
|
@@ -3436,17 +3365,17 @@ var SwapCrossChainProcessingView = ({
|
|
|
3436
3365
|
chainName: originChainName
|
|
3437
3366
|
}
|
|
3438
3367
|
),
|
|
3439
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3440
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3368
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3369
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3441
3370
|
formattedInputAmount,
|
|
3442
3371
|
" ",
|
|
3443
3372
|
fromTokenSymbol
|
|
3444
3373
|
] }),
|
|
3445
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3374
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedInputAmountUSD })
|
|
3446
3375
|
] })
|
|
3447
3376
|
] }),
|
|
3448
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute z-10
|
|
3449
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3377
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute z-10 px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] -translate-x-1/2 -translate-y-1/2 rounded-[var(--deframe-widget-size-radius-full)] shadow-[0_10px_30px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_22%,transparent)] left-1/2 top-1/2 bg-[var(--deframe-widget-color-brand-secondary)]", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSwapHoriz, { className: "w-5 h-5" }) }),
|
|
3378
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3450
3379
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3451
3380
|
TokenWithChainBadge,
|
|
3452
3381
|
{
|
|
@@ -3457,14 +3386,14 @@ var SwapCrossChainProcessingView = ({
|
|
|
3457
3386
|
chainName: destinationChainName
|
|
3458
3387
|
}
|
|
3459
3388
|
),
|
|
3460
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3461
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3389
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3390
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3462
3391
|
"~",
|
|
3463
3392
|
formattedOutputAmount,
|
|
3464
3393
|
" ",
|
|
3465
3394
|
toTokenSymbol
|
|
3466
3395
|
] }),
|
|
3467
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3396
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedOutputAmountUSD })
|
|
3468
3397
|
] })
|
|
3469
3398
|
] })
|
|
3470
3399
|
] }) }),
|
|
@@ -3472,7 +3401,7 @@ var SwapCrossChainProcessingView = ({
|
|
|
3472
3401
|
TransactionProcessingDetails,
|
|
3473
3402
|
{
|
|
3474
3403
|
steps: transactionSteps,
|
|
3475
|
-
className: "bg-
|
|
3404
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3476
3405
|
labels: processingDetailsLabels
|
|
3477
3406
|
}
|
|
3478
3407
|
)
|
|
@@ -3508,34 +3437,34 @@ var SwapSignatureWarningView = ({
|
|
|
3508
3437
|
iconType: "warning",
|
|
3509
3438
|
title: /* @__PURE__ */ jsxRuntime.jsx("span", { "data-testid": "swap-signature-warning-title", children: errorTitle }),
|
|
3510
3439
|
description: errorDescription,
|
|
3511
|
-
actions: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-testid": "swap-signature-warning-actions", className: "flex gap-sm w-full", children: [
|
|
3440
|
+
actions: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-testid": "swap-signature-warning-actions", className: "flex gap-[var(--deframe-widget-size-gap-sm)] w-full", children: [
|
|
3512
3441
|
/* @__PURE__ */ jsxRuntime.jsx(SecondaryButton, { "data-testid": "swap-signature-warning-cancel", className: "flex-1", onClick: onCancel, children: cancelButtonText }),
|
|
3513
3442
|
/* @__PURE__ */ jsxRuntime.jsx(PrimaryButton, { "data-testid": "swap-signature-warning-retry", className: "flex-1", onClick: onTryAgain, children: retryButtonText })
|
|
3514
3443
|
] }),
|
|
3515
3444
|
children: [
|
|
3516
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-md", children: [
|
|
3517
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3518
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3519
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3520
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3445
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-[var(--deframe-widget-size-padding-x-md)]", children: [
|
|
3446
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3447
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3448
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3449
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3521
3450
|
formattedInputAmount,
|
|
3522
3451
|
" ",
|
|
3523
3452
|
fromTokenSymbol
|
|
3524
3453
|
] }),
|
|
3525
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3454
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedInputAmountUSD })
|
|
3526
3455
|
] })
|
|
3527
3456
|
] }),
|
|
3528
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-brand-secondary rounded-full
|
|
3529
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3530
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3531
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3532
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3457
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-[var(--deframe-widget-color-brand-secondary)] rounded-[var(--deframe-widget-size-radius-full)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] shadow-[0_10px_30px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_22%,transparent)] z-10", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSwapHoriz, { className: "w-5 h-5" }) }),
|
|
3458
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3459
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3460
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3461
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3533
3462
|
"~",
|
|
3534
3463
|
formattedOutputAmount,
|
|
3535
3464
|
" ",
|
|
3536
3465
|
toTokenSymbol
|
|
3537
3466
|
] }),
|
|
3538
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3467
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedOutputAmountUSD })
|
|
3539
3468
|
] })
|
|
3540
3469
|
] })
|
|
3541
3470
|
] }) }),
|
|
@@ -3544,7 +3473,7 @@ var SwapSignatureWarningView = ({
|
|
|
3544
3473
|
{
|
|
3545
3474
|
steps: transactionSteps,
|
|
3546
3475
|
defaultOpen: true,
|
|
3547
|
-
className: "bg-
|
|
3476
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3548
3477
|
labels: processingDetailsLabels
|
|
3549
3478
|
}
|
|
3550
3479
|
)
|
|
@@ -3579,7 +3508,7 @@ var SwapSuccessView = ({
|
|
|
3579
3508
|
description: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
3580
3509
|
labels.descriptionPrefix,
|
|
3581
3510
|
" ",
|
|
3582
|
-
/* @__PURE__ */ jsxRuntime.jsxs("strong", { className: "font-semibold", children: [
|
|
3511
|
+
/* @__PURE__ */ jsxRuntime.jsxs("strong", { className: "[font-weight:var(--deframe-widget-font-weight-semibold)]", children: [
|
|
3583
3512
|
formattedInputAmount,
|
|
3584
3513
|
" ",
|
|
3585
3514
|
fromTokenSymbol
|
|
@@ -3587,7 +3516,7 @@ var SwapSuccessView = ({
|
|
|
3587
3516
|
" ",
|
|
3588
3517
|
labels.descriptionMiddle,
|
|
3589
3518
|
" ",
|
|
3590
|
-
/* @__PURE__ */ jsxRuntime.jsxs("strong", { className: "font-semibold", children: [
|
|
3519
|
+
/* @__PURE__ */ jsxRuntime.jsxs("strong", { className: "[font-weight:var(--deframe-widget-font-weight-semibold)]", children: [
|
|
3591
3520
|
formattedOutputAmount,
|
|
3592
3521
|
" ",
|
|
3593
3522
|
toTokenSymbol
|
|
@@ -3595,33 +3524,33 @@ var SwapSuccessView = ({
|
|
|
3595
3524
|
/* @__PURE__ */ jsxRuntime.jsx("br", {}),
|
|
3596
3525
|
labels.descriptionSuffix,
|
|
3597
3526
|
" ",
|
|
3598
|
-
/* @__PURE__ */ jsxRuntime.jsx("strong", { className: "font-semibold text-brand-primary cursor-pointer", onClick: onGoToWallet, children: labels.walletLinkText })
|
|
3527
|
+
/* @__PURE__ */ jsxRuntime.jsx("strong", { className: "[font-weight:var(--deframe-widget-font-weight-semibold)] text-[color:var(--deframe-widget-color-brand-primary)] cursor-pointer", onClick: onGoToWallet, children: labels.walletLinkText })
|
|
3599
3528
|
] }),
|
|
3600
3529
|
actions: /* @__PURE__ */ jsxRuntime.jsx("div", { "data-testid": "swap-start-new-wrapper", className: "w-full", children: /* @__PURE__ */ jsxRuntime.jsx(PrimaryButton, { "data-testid": "swap-start-new-button", className: "w-full", onClick: onStartNewSwap, children: labels.startNewSwapButton }) }),
|
|
3601
3530
|
children: [
|
|
3602
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-md", children: [
|
|
3603
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3604
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3605
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3606
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3531
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-[var(--deframe-widget-size-padding-x-md)]", children: [
|
|
3532
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3533
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3534
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3535
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3607
3536
|
formattedInputAmount,
|
|
3608
3537
|
" ",
|
|
3609
3538
|
fromTokenSymbol
|
|
3610
3539
|
] }),
|
|
3611
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3540
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedInputAmountUSD })
|
|
3612
3541
|
] })
|
|
3613
3542
|
] }),
|
|
3614
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-brand-secondary rounded-full
|
|
3615
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3616
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3617
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3618
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3543
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-[var(--deframe-widget-color-brand-secondary)] rounded-[var(--deframe-widget-size-radius-full)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] shadow-[0_10px_30px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_22%,transparent)] z-10", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSwapHoriz, { className: "w-5 h-5" }) }),
|
|
3544
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3545
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3546
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3547
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3619
3548
|
"~",
|
|
3620
3549
|
formattedOutputAmount,
|
|
3621
3550
|
" ",
|
|
3622
3551
|
toTokenSymbol
|
|
3623
3552
|
] }),
|
|
3624
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3553
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedOutputAmountUSD })
|
|
3625
3554
|
] })
|
|
3626
3555
|
] })
|
|
3627
3556
|
] }) }),
|
|
@@ -3630,7 +3559,7 @@ var SwapSuccessView = ({
|
|
|
3630
3559
|
{
|
|
3631
3560
|
steps: transactionSteps,
|
|
3632
3561
|
defaultOpen: true,
|
|
3633
|
-
className: "bg-
|
|
3562
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3634
3563
|
labels: processingDetailsLabels
|
|
3635
3564
|
}
|
|
3636
3565
|
)
|
|
@@ -3666,38 +3595,38 @@ var SwapTransactionFailedView = ({
|
|
|
3666
3595
|
onClose: onBack,
|
|
3667
3596
|
progress,
|
|
3668
3597
|
iconType: "warning",
|
|
3669
|
-
iconGradient: "linear-gradient(135deg,
|
|
3598
|
+
iconGradient: "linear-gradient(135deg, var(--deframe-widget-color-state-error) 0%, color-mix(in srgb, var(--deframe-widget-color-state-error) 78%, black) 100%)",
|
|
3670
3599
|
title: /* @__PURE__ */ jsxRuntime.jsx("span", { "data-testid": "swap-failed-title", children: errorTitle }),
|
|
3671
3600
|
description: errorDescription,
|
|
3672
|
-
actions: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-testid": "swap-failed-actions", className: "flex gap-sm w-full", children: [
|
|
3601
|
+
actions: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-testid": "swap-failed-actions", className: "flex gap-[var(--deframe-widget-size-gap-sm)] w-full", children: [
|
|
3673
3602
|
/* @__PURE__ */ jsxRuntime.jsx(SecondaryButton, { "data-testid": "swap-failed-view-explorer", className: "flex-1", onClick: onViewExplorer, disabled: !hasExplorerLink, children: viewOnExplorerText }),
|
|
3674
3603
|
/* @__PURE__ */ jsxRuntime.jsx(PrimaryButton, { "data-testid": "swap-failed-retry", className: "flex-1", onClick: onTryAgain, children: retryButtonText })
|
|
3675
3604
|
] }),
|
|
3676
3605
|
children: [
|
|
3677
|
-
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-md", children: [
|
|
3678
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3679
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3680
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3681
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3606
|
+
/* @__PURE__ */ jsxRuntime.jsx(SectionCard, { className: "!p-[22px]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between w-full relative px-[var(--deframe-widget-size-padding-x-md)]", children: [
|
|
3607
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3608
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: fromTokenIcon, alt: fromTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3609
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3610
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3682
3611
|
"~",
|
|
3683
3612
|
formattedInputAmount,
|
|
3684
3613
|
" ",
|
|
3685
3614
|
fromTokenSymbol
|
|
3686
3615
|
] }),
|
|
3687
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3616
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedInputAmountUSD })
|
|
3688
3617
|
] })
|
|
3689
3618
|
] }),
|
|
3690
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-brand-secondary rounded-full
|
|
3691
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-sm", children: [
|
|
3692
|
-
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-full" }),
|
|
3693
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-xs", children: [
|
|
3694
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3619
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 bg-[var(--deframe-widget-color-brand-secondary)] rounded-[var(--deframe-widget-size-radius-full)] px-[var(--deframe-widget-size-padding-x-sm)] py-[var(--deframe-widget-size-padding-y-sm)] shadow-[0_10px_30px_color-mix(in_srgb,var(--deframe-widget-color-text-primary)_22%,transparent)] z-10", children: /* @__PURE__ */ jsxRuntime.jsx(md.MdOutlineSwapHoriz, { className: "w-5 h-5" }) }),
|
|
3620
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-sm)]", children: [
|
|
3621
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: toTokenIcon, alt: toTokenSymbol, className: "w-8 h-8 rounded-[var(--deframe-widget-size-radius-full)]" }),
|
|
3622
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3623
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-secondary)]", children: [
|
|
3695
3624
|
"~",
|
|
3696
3625
|
formattedOutputAmount,
|
|
3697
3626
|
" ",
|
|
3698
3627
|
toTokenSymbol
|
|
3699
3628
|
] }),
|
|
3700
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
3629
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "[font-size:var(--deframe-widget-font-size-xxl)] [line-height:var(--deframe-widget-font-leading-xxl)] [font-weight:var(--deframe-widget-font-weight-extrabold)] font-[var(--deframe-widget-font-family)] text-[color:var(--deframe-widget-color-text-primary)]", children: formattedOutputAmountUSD })
|
|
3701
3630
|
] })
|
|
3702
3631
|
] })
|
|
3703
3632
|
] }) }),
|
|
@@ -3706,7 +3635,7 @@ var SwapTransactionFailedView = ({
|
|
|
3706
3635
|
{
|
|
3707
3636
|
steps: transactionSteps,
|
|
3708
3637
|
defaultOpen: true,
|
|
3709
|
-
className: "bg-
|
|
3638
|
+
className: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3710
3639
|
labels: processingDetailsLabels
|
|
3711
3640
|
}
|
|
3712
3641
|
)
|
|
@@ -3748,7 +3677,7 @@ var ChooseAnAssetSwapView = ({
|
|
|
3748
3677
|
contentClassName: "w-full max-w-[620px] mx-auto",
|
|
3749
3678
|
children: /* @__PURE__ */ jsxRuntime.jsxs(BackgroundContainer, { className: "flex flex-col h-full", children: [
|
|
3750
3679
|
/* @__PURE__ */ jsxRuntime.jsx(Navbar, { children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { testId: `swap-token-actionsheet-close-${actionSheetId}`, onClick: onClose }) }),
|
|
3751
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col flex-1 w-full
|
|
3680
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col flex-1 w-full px-[var(--deframe-widget-size-padding-x-lg)] py-[var(--deframe-widget-size-padding-y-lg)] overflow-hidden", children: [
|
|
3752
3681
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-shrink-0", children: [
|
|
3753
3682
|
/* @__PURE__ */ jsxRuntime.jsx(TextHeading, { children: labels.title }),
|
|
3754
3683
|
/* @__PURE__ */ jsxRuntime.jsx("br", {}),
|
|
@@ -3758,15 +3687,15 @@ var ChooseAnAssetSwapView = ({
|
|
|
3758
3687
|
onSearch: handleSearch,
|
|
3759
3688
|
placeholder: labels.searchPlaceholder,
|
|
3760
3689
|
autoFocus,
|
|
3761
|
-
inputClassName: "bg-
|
|
3690
|
+
inputClassName: "bg-[var(--deframe-widget-color-bg-secondary)] lg:!bg-[var(--deframe-widget-color-bg-secondary)]",
|
|
3762
3691
|
containerTestId: `swap-token-search-container-${actionSheetId}`,
|
|
3763
3692
|
inputTestId: `swap-token-search-input-${actionSheetId}`
|
|
3764
3693
|
}
|
|
3765
3694
|
)
|
|
3766
3695
|
] }),
|
|
3767
|
-
searchValue && displayedTokens.length === 0 && !isFetching ? /* @__PURE__ */ jsxRuntime.jsx(SearchEmptyState, { title: labels.searchEmptyTitle, description: labels.searchEmptyDescription }) : /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-
|
|
3768
|
-
isFetching && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-center w-full py-
|
|
3769
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
3696
|
+
searchValue && displayedTokens.length === 0 && !isFetching ? /* @__PURE__ */ jsxRuntime.jsx(SearchEmptyState, { title: labels.searchEmptyTitle, description: labels.searchEmptyDescription }) : /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-[var(--deframe-widget-size-gap-sm)] w-full mt-[var(--deframe-widget-size-gap-md)] overflow-y-auto flex-1 min-h-0", children: [
|
|
3697
|
+
isFetching && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-center w-full py-[var(--deframe-widget-size-padding-y-md)]", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-[var(--deframe-widget-size-gap-xs)]", children: [
|
|
3698
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", className: "text-[color:var(--deframe-widget-color-text-secondary)]", children: labels.searchingText }),
|
|
3770
3699
|
/* @__PURE__ */ jsxRuntime.jsx(LoadingDots, {})
|
|
3771
3700
|
] }) }),
|
|
3772
3701
|
displayedTokens.map((token, index) => {
|
|
@@ -3783,21 +3712,21 @@ var ChooseAnAssetSwapView = ({
|
|
|
3783
3712
|
"data-chain-id": token.chainId,
|
|
3784
3713
|
"data-symbol": token.symbol,
|
|
3785
3714
|
children: [
|
|
3786
|
-
/* @__PURE__ */ jsxRuntime.jsx(ListItemLeftSide, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: token.logoURI || "", alt: token.name, className: "w-10 h-10 rounded-full" }) }),
|
|
3715
|
+
/* @__PURE__ */ jsxRuntime.jsx(ListItemLeftSide, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: token.logoURI || "", alt: token.name, className: "w-10 h-10 rounded-[var(--deframe-widget-size-radius-full)]" }) }),
|
|
3787
3716
|
/* @__PURE__ */ jsxRuntime.jsxs(ListItemContent, { children: [
|
|
3788
3717
|
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { children: token.name }),
|
|
3789
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
3718
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: token.symbol })
|
|
3790
3719
|
] }),
|
|
3791
3720
|
/* @__PURE__ */ jsxRuntime.jsxs(ListItemRightSide, { children: [
|
|
3792
3721
|
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { children: formattedBalance }),
|
|
3793
|
-
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "
|
|
3722
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextBody, { variant: "[font-size:var(--deframe-widget-font-size-sm)] [line-height:var(--deframe-widget-font-leading-sm)]", children: formatCurrencyValue(Number(balance == null ? void 0 : balance.amountInUSD) || 0) })
|
|
3794
3723
|
] })
|
|
3795
3724
|
]
|
|
3796
3725
|
},
|
|
3797
3726
|
`token-${token.address}-${index}`
|
|
3798
3727
|
);
|
|
3799
3728
|
}),
|
|
3800
|
-
hasMore && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-center w-full py-
|
|
3729
|
+
hasMore && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-center w-full py-[var(--deframe-widget-size-padding-y-md)] flex-shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx(TertiaryButton, { onClick: onLoadMore, children: labels.loadMoreButton }) })
|
|
3801
3730
|
] })
|
|
3802
3731
|
] })
|
|
3803
3732
|
] })
|
|
@@ -4191,7 +4120,6 @@ exports.BackgroundContainer = BackgroundContainer;
|
|
|
4191
4120
|
exports.BannerNotification = BannerNotification;
|
|
4192
4121
|
exports.ChooseAStrategyActionsheetView = ChooseAStrategyActionsheetView;
|
|
4193
4122
|
exports.ChooseAnAssetSwapView = ChooseAnAssetSwapView;
|
|
4194
|
-
exports.CloseButton = CloseButton;
|
|
4195
4123
|
exports.CollapsibleInfoRow = CollapsibleInfoRow;
|
|
4196
4124
|
exports.CollapsibleSection = CollapsibleSection;
|
|
4197
4125
|
exports.ConfirmSwapButtonView = ConfirmSwapButtonView;
|
|
@@ -4273,12 +4201,9 @@ exports.TransactionProcessingDetails = TransactionProcessingDetails;
|
|
|
4273
4201
|
exports.TransactionScreen = TransactionScreen;
|
|
4274
4202
|
exports.TransactionScreenIcon = TransactionScreenIcon;
|
|
4275
4203
|
exports.TransactionScreenInvestmentCard = TransactionScreenInvestmentCard;
|
|
4204
|
+
exports.WalletConnectPanel = WalletConnectPanel;
|
|
4276
4205
|
exports.WalletItem = WalletItem;
|
|
4277
4206
|
exports.WalletList = ConnectWalletList;
|
|
4278
4207
|
exports.WalletListContainer = WalletListContainer;
|
|
4279
|
-
exports.cryptocontrolThemeColors = cryptocontrolThemeColors;
|
|
4280
|
-
exports.darkThemeColors = darkThemeColors;
|
|
4281
|
-
exports.defaultThemeColors = defaultThemeColors;
|
|
4282
|
-
exports.themeToCSS = themeToCSS;
|
|
4283
4208
|
//# sourceMappingURL=index.js.map
|
|
4284
4209
|
//# sourceMappingURL=index.js.map
|