kaleido-ui 0.1.16 → 0.1.18
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/web/index.cjs +21 -10
- package/dist/web/index.d.cts +4 -0
- package/dist/web/index.d.ts +4 -0
- package/dist/web/index.js +21 -10
- package/package.json +1 -1
package/dist/web/index.cjs
CHANGED
|
@@ -504,7 +504,12 @@ function Icon2({
|
|
|
504
504
|
"span",
|
|
505
505
|
{
|
|
506
506
|
className: cn(
|
|
507
|
-
|
|
507
|
+
// `inline-flex items-center justify-center leading-none` keeps the
|
|
508
|
+
// glyph centered inside its own box rather than drifting on the
|
|
509
|
+
// parent's text baseline. Without this, a Material-Symbols span
|
|
510
|
+
// sitting next to an <img>-based icon in a flex row renders a few
|
|
511
|
+
// pixels lower because the glyph adopts the surrounding line-height.
|
|
512
|
+
"material-symbols-outlined inline-flex items-center justify-center leading-none align-middle",
|
|
508
513
|
filled && "filled",
|
|
509
514
|
sizeClasses[size],
|
|
510
515
|
className
|
|
@@ -4137,7 +4142,7 @@ function RouteChoiceCard({
|
|
|
4137
4142
|
recommended,
|
|
4138
4143
|
onClick
|
|
4139
4144
|
}) {
|
|
4140
|
-
const { disabled = false, disabledReason } = route;
|
|
4145
|
+
const { disabled = false, disabledReason, accountIcon, balanceLabel } = route;
|
|
4141
4146
|
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
4142
4147
|
"button",
|
|
4143
4148
|
{
|
|
@@ -4153,15 +4158,21 @@ function RouteChoiceCard({
|
|
|
4153
4158
|
),
|
|
4154
4159
|
children: [
|
|
4155
4160
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex items-start justify-between gap-3", children: [
|
|
4156
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { children: [
|
|
4157
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.
|
|
4158
|
-
|
|
4159
|
-
|
|
4160
|
-
|
|
4161
|
-
|
|
4162
|
-
|
|
4161
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex min-w-0 items-start gap-3", children: [
|
|
4162
|
+
accountIcon && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "mt-0.5 shrink-0", children: accountIcon }),
|
|
4163
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "min-w-0", children: [
|
|
4164
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex flex-wrap items-center gap-2", children: [
|
|
4165
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "text-sm font-bold text-white", children: route.accountTitle }),
|
|
4166
|
+
recommended && !disabled && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "rounded-full border border-primary/20 bg-primary/10 px-2 py-0.5 text-xxs font-bold uppercase tracking-wider text-primary", children: "Recommended" }),
|
|
4167
|
+
disabled && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "rounded-full border border-danger/20 bg-danger/10 px-2 py-0.5 text-xxs font-bold uppercase tracking-wider text-danger", children: "Insufficient" })
|
|
4168
|
+
] }),
|
|
4169
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: "mt-1 text-xs text-white/45", children: route.methodLabel })
|
|
4170
|
+
] })
|
|
4163
4171
|
] }),
|
|
4164
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.
|
|
4172
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex shrink-0 flex-col items-end gap-1", children: [
|
|
4173
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "text-xxs font-bold uppercase tracking-wider text-white/35", children: route.feeHint }),
|
|
4174
|
+
balanceLabel && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "font-mono text-xxs text-white/50", children: balanceLabel })
|
|
4175
|
+
] })
|
|
4165
4176
|
] }),
|
|
4166
4177
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: "mt-3 text-xs leading-relaxed text-muted-foreground", children: route.summary }),
|
|
4167
4178
|
disabled && disabledReason && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: "mt-2 text-xxs leading-relaxed text-danger/80", children: disabledReason })
|
package/dist/web/index.d.cts
CHANGED
|
@@ -808,6 +808,10 @@ interface WithdrawRouteOption<TAccount extends string = string> {
|
|
|
808
808
|
disabled?: boolean;
|
|
809
809
|
/** Short reason shown under the disabled card. Pair with `disabled`. */
|
|
810
810
|
disabledReason?: string;
|
|
811
|
+
/** Optional account/protocol logo rendered on the left of the card (e.g. NetworkBadge). */
|
|
812
|
+
accountIcon?: ReactNode;
|
|
813
|
+
/** Optional pre-formatted balance label (e.g. "1.23 BTC available") shown on the card. */
|
|
814
|
+
balanceLabel?: string;
|
|
811
815
|
}
|
|
812
816
|
interface WithdrawRouteSummary {
|
|
813
817
|
method: string;
|
package/dist/web/index.d.ts
CHANGED
|
@@ -808,6 +808,10 @@ interface WithdrawRouteOption<TAccount extends string = string> {
|
|
|
808
808
|
disabled?: boolean;
|
|
809
809
|
/** Short reason shown under the disabled card. Pair with `disabled`. */
|
|
810
810
|
disabledReason?: string;
|
|
811
|
+
/** Optional account/protocol logo rendered on the left of the card (e.g. NetworkBadge). */
|
|
812
|
+
accountIcon?: ReactNode;
|
|
813
|
+
/** Optional pre-formatted balance label (e.g. "1.23 BTC available") shown on the card. */
|
|
814
|
+
balanceLabel?: string;
|
|
811
815
|
}
|
|
812
816
|
interface WithdrawRouteSummary {
|
|
813
817
|
method: string;
|
package/dist/web/index.js
CHANGED
|
@@ -343,7 +343,12 @@ function Icon2({
|
|
|
343
343
|
"span",
|
|
344
344
|
{
|
|
345
345
|
className: cn(
|
|
346
|
-
|
|
346
|
+
// `inline-flex items-center justify-center leading-none` keeps the
|
|
347
|
+
// glyph centered inside its own box rather than drifting on the
|
|
348
|
+
// parent's text baseline. Without this, a Material-Symbols span
|
|
349
|
+
// sitting next to an <img>-based icon in a flex row renders a few
|
|
350
|
+
// pixels lower because the glyph adopts the surrounding line-height.
|
|
351
|
+
"material-symbols-outlined inline-flex items-center justify-center leading-none align-middle",
|
|
347
352
|
filled && "filled",
|
|
348
353
|
sizeClasses[size],
|
|
349
354
|
className
|
|
@@ -3982,7 +3987,7 @@ function RouteChoiceCard({
|
|
|
3982
3987
|
recommended,
|
|
3983
3988
|
onClick
|
|
3984
3989
|
}) {
|
|
3985
|
-
const { disabled = false, disabledReason } = route;
|
|
3990
|
+
const { disabled = false, disabledReason, accountIcon, balanceLabel } = route;
|
|
3986
3991
|
return /* @__PURE__ */ jsxs33(
|
|
3987
3992
|
"button",
|
|
3988
3993
|
{
|
|
@@ -3998,15 +4003,21 @@ function RouteChoiceCard({
|
|
|
3998
4003
|
),
|
|
3999
4004
|
children: [
|
|
4000
4005
|
/* @__PURE__ */ jsxs33("div", { className: "flex items-start justify-between gap-3", children: [
|
|
4001
|
-
/* @__PURE__ */ jsxs33("div", { children: [
|
|
4002
|
-
/* @__PURE__ */
|
|
4003
|
-
|
|
4004
|
-
|
|
4005
|
-
|
|
4006
|
-
|
|
4007
|
-
|
|
4006
|
+
/* @__PURE__ */ jsxs33("div", { className: "flex min-w-0 items-start gap-3", children: [
|
|
4007
|
+
accountIcon && /* @__PURE__ */ jsx45("div", { className: "mt-0.5 shrink-0", children: accountIcon }),
|
|
4008
|
+
/* @__PURE__ */ jsxs33("div", { className: "min-w-0", children: [
|
|
4009
|
+
/* @__PURE__ */ jsxs33("div", { className: "flex flex-wrap items-center gap-2", children: [
|
|
4010
|
+
/* @__PURE__ */ jsx45("span", { className: "text-sm font-bold text-white", children: route.accountTitle }),
|
|
4011
|
+
recommended && !disabled && /* @__PURE__ */ jsx45("span", { className: "rounded-full border border-primary/20 bg-primary/10 px-2 py-0.5 text-xxs font-bold uppercase tracking-wider text-primary", children: "Recommended" }),
|
|
4012
|
+
disabled && /* @__PURE__ */ jsx45("span", { className: "rounded-full border border-danger/20 bg-danger/10 px-2 py-0.5 text-xxs font-bold uppercase tracking-wider text-danger", children: "Insufficient" })
|
|
4013
|
+
] }),
|
|
4014
|
+
/* @__PURE__ */ jsx45("p", { className: "mt-1 text-xs text-white/45", children: route.methodLabel })
|
|
4015
|
+
] })
|
|
4008
4016
|
] }),
|
|
4009
|
-
/* @__PURE__ */
|
|
4017
|
+
/* @__PURE__ */ jsxs33("div", { className: "flex shrink-0 flex-col items-end gap-1", children: [
|
|
4018
|
+
/* @__PURE__ */ jsx45("span", { className: "text-xxs font-bold uppercase tracking-wider text-white/35", children: route.feeHint }),
|
|
4019
|
+
balanceLabel && /* @__PURE__ */ jsx45("span", { className: "font-mono text-xxs text-white/50", children: balanceLabel })
|
|
4020
|
+
] })
|
|
4010
4021
|
] }),
|
|
4011
4022
|
/* @__PURE__ */ jsx45("p", { className: "mt-3 text-xs leading-relaxed text-muted-foreground", children: route.summary }),
|
|
4012
4023
|
disabled && disabledReason && /* @__PURE__ */ jsx45("p", { className: "mt-2 text-xxs leading-relaxed text-danger/80", children: disabledReason })
|
package/package.json
CHANGED