@retinalabsllc/zairusjs 14.0.70 → 14.0.85
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 +4 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +29 -9
- package/dist/index.mjs +31 -10
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -319,6 +319,8 @@ interface CardData {
|
|
|
319
319
|
preOrder?: boolean;
|
|
320
320
|
contentDark?: boolean;
|
|
321
321
|
bannerProps?: BannerProps;
|
|
322
|
+
prepaid?: boolean;
|
|
323
|
+
balance?: string;
|
|
322
324
|
}
|
|
323
325
|
interface UniversalCardPageProps {
|
|
324
326
|
cards: CardData[];
|
|
@@ -327,6 +329,8 @@ interface UniversalCardPageProps {
|
|
|
327
329
|
onFreeze?: (cardId: string) => void | Promise<void>;
|
|
328
330
|
onSetLimits?: (cardId: string) => void;
|
|
329
331
|
onDelete?: (cardId: string) => void | Promise<void>;
|
|
332
|
+
onFundCard?: (cardId: string) => void;
|
|
333
|
+
onCreateCard?: () => void;
|
|
330
334
|
}
|
|
331
335
|
declare const UniversalCardPage: React.FC<UniversalCardPageProps>;
|
|
332
336
|
|
package/dist/index.d.ts
CHANGED
|
@@ -319,6 +319,8 @@ interface CardData {
|
|
|
319
319
|
preOrder?: boolean;
|
|
320
320
|
contentDark?: boolean;
|
|
321
321
|
bannerProps?: BannerProps;
|
|
322
|
+
prepaid?: boolean;
|
|
323
|
+
balance?: string;
|
|
322
324
|
}
|
|
323
325
|
interface UniversalCardPageProps {
|
|
324
326
|
cards: CardData[];
|
|
@@ -327,6 +329,8 @@ interface UniversalCardPageProps {
|
|
|
327
329
|
onFreeze?: (cardId: string) => void | Promise<void>;
|
|
328
330
|
onSetLimits?: (cardId: string) => void;
|
|
329
331
|
onDelete?: (cardId: string) => void | Promise<void>;
|
|
332
|
+
onFundCard?: (cardId: string) => void;
|
|
333
|
+
onCreateCard?: () => void;
|
|
330
334
|
}
|
|
331
335
|
declare const UniversalCardPage: React.FC<UniversalCardPageProps>;
|
|
332
336
|
|
package/dist/index.js
CHANGED
|
@@ -232,8 +232,7 @@ var ThreeDActionButton = ({
|
|
|
232
232
|
disabled = false,
|
|
233
233
|
isLoading = false,
|
|
234
234
|
children,
|
|
235
|
-
className = ""
|
|
236
|
-
ariaLabel
|
|
235
|
+
className = ""
|
|
237
236
|
}) => {
|
|
238
237
|
const isInteractionDisabled = disabled || isLoading;
|
|
239
238
|
const baseShadow = `
|
|
@@ -1120,7 +1119,6 @@ var UniversalProfileSettings = ({
|
|
|
1120
1119
|
{
|
|
1121
1120
|
type: "button",
|
|
1122
1121
|
onClick: () => setIsPinModalOpen(true),
|
|
1123
|
-
"aria-label": "PIN Settings",
|
|
1124
1122
|
className: "w-9 h-9 flex items-center justify-center border border-neutral-200 rounded-full text-black hover:bg-neutral-50 transition-colors outline-none"
|
|
1125
1123
|
},
|
|
1126
1124
|
/* @__PURE__ */ import_react17.default.createElement(import_react18.HugeiconsIcon, { icon: import_core_free_icons4.LockKeyIcon, size: 17, className: "text-black" })
|
|
@@ -2054,7 +2052,9 @@ var UniversalCardPage = ({
|
|
|
2054
2052
|
onReveal,
|
|
2055
2053
|
onFreeze,
|
|
2056
2054
|
onSetLimits,
|
|
2057
|
-
onDelete
|
|
2055
|
+
onDelete,
|
|
2056
|
+
onFundCard,
|
|
2057
|
+
onCreateCard
|
|
2058
2058
|
}) => {
|
|
2059
2059
|
const router = (0, import_navigation4.useRouter)();
|
|
2060
2060
|
const sortedCards = import_react33.default.useMemo(() => {
|
|
@@ -2148,7 +2148,7 @@ var UniversalCardPage = ({
|
|
|
2148
2148
|
const capitalized = type.charAt(0).toUpperCase() + type.slice(1).toLowerCase();
|
|
2149
2149
|
return `${capitalized} Card`;
|
|
2150
2150
|
};
|
|
2151
|
-
return /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300" },
|
|
2151
|
+
return /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, sortedCards.length > 0 && /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex items-center bg-white rounded-full p-1 sm:p-1.5 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => {
|
|
2152
2152
|
const isActive = activeTabIndex === idx;
|
|
2153
2153
|
return /* @__PURE__ */ import_react33.default.createElement(
|
|
2154
2154
|
"button",
|
|
@@ -2159,7 +2159,16 @@ var UniversalCardPage = ({
|
|
|
2159
2159
|
},
|
|
2160
2160
|
formatTabLabel(tab.type)
|
|
2161
2161
|
);
|
|
2162
|
-
}))
|
|
2162
|
+
})), /* @__PURE__ */ import_react33.default.createElement(
|
|
2163
|
+
"button",
|
|
2164
|
+
{
|
|
2165
|
+
onClick: () => {
|
|
2166
|
+
if (onCreateCard) onCreateCard();
|
|
2167
|
+
},
|
|
2168
|
+
className: "w-10 h-10 rounded-full bg-white flex items-center justify-center text-neutral-500 hover:text-black transition-colors shrink-0 outline-none"
|
|
2169
|
+
},
|
|
2170
|
+
/* @__PURE__ */ import_react33.default.createElement(import_react34.HugeiconsIcon, { icon: import_core_free_icons12.PlusSignIcon, size: 18 })
|
|
2171
|
+
)), /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full pt-2 pb-2 flex justify-center" }, /* @__PURE__ */ import_react33.default.createElement(
|
|
2163
2172
|
"div",
|
|
2164
2173
|
{
|
|
2165
2174
|
className: "relative w-full max-w-85",
|
|
@@ -2204,7 +2213,7 @@ var UniversalCardPage = ({
|
|
|
2204
2213
|
className: "absolute inset-0 bg-cover bg-center",
|
|
2205
2214
|
style: { backgroundImage: `url(${activeCard.cardBgSrc})` }
|
|
2206
2215
|
}
|
|
2207
|
-
), /* @__PURE__ */ import_react33.default.createElement("div", { className: "relative z-10 w-full h-full p-5 flex flex-col justify-between" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex items-start w-full gap-4" }), /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex justify-between items-end w-full" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, "Card Tier"), /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[12px] tracking-widest font-medium
|
|
2216
|
+
), /* @__PURE__ */ import_react33.default.createElement("div", { className: "relative z-10 w-full h-full p-5 flex flex-col justify-between" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex items-start justify-end w-full gap-4" }, activeCard.prepaid && /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex flex-col items-end gap-1 text-right" }, /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, "Card Tier"), /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[12px] tracking-widest font-medium ${activeCard.contentDark ? "text-black" : "text-white"}` }, activeCard.tier))), /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex justify-between items-end w-full" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, activeCard.prepaid ? "Card Balance" : "Card Tier"), /* @__PURE__ */ import_react33.default.createElement("span", { className: `text-[12px] tracking-widest font-medium ${activeCard.contentDark ? "text-black" : "text-white"}` }, activeCard.prepaid ? activeCard.balance || "$0.00" : activeCard.tier)), activeCard.networkLogoSrc && /* @__PURE__ */ import_react33.default.createElement(
|
|
2208
2217
|
"img",
|
|
2209
2218
|
{
|
|
2210
2219
|
src: activeCard.networkLogoSrc,
|
|
@@ -2212,7 +2221,7 @@ var UniversalCardPage = ({
|
|
|
2212
2221
|
className: "h-10 w-auto max-w-20 object-contain opacity-90"
|
|
2213
2222
|
}
|
|
2214
2223
|
))))
|
|
2215
|
-
)), activeCard.bannerProps ? /* @__PURE__ */ import_react33.default.createElement("div", { className: "mb-6 w-full" }, /* @__PURE__ */ import_react33.default.createElement(Banner, { ...activeCard.bannerProps })) : isPreordered ? /* @__PURE__ */ import_react33.default.createElement("div", { className: "mb-6 w-full" }, /* @__PURE__ */ import_react33.default.createElement(
|
|
2224
|
+
)), activeCard.bannerProps ? /* @__PURE__ */ import_react33.default.createElement("div", { className: "mb-6 w-full mt-2" }, /* @__PURE__ */ import_react33.default.createElement(Banner, { ...activeCard.bannerProps })) : isPreordered ? /* @__PURE__ */ import_react33.default.createElement("div", { className: "mb-6 w-full mt-2" }, /* @__PURE__ */ import_react33.default.createElement(
|
|
2216
2225
|
Banner,
|
|
2217
2226
|
{
|
|
2218
2227
|
type: "success",
|
|
@@ -2220,7 +2229,18 @@ var UniversalCardPage = ({
|
|
|
2220
2229
|
message: `Your ${activeCard.tier} ${activeCard.type.toLowerCase()} card has been pre-ordered successfully and is pending batch processing.`,
|
|
2221
2230
|
isDismissible: false
|
|
2222
2231
|
}
|
|
2223
|
-
)) : null, /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full flex flex-col gap-4" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full bg-white rounded-2xl overflow-hidden" }, /* @__PURE__ */ import_react33.default.createElement(
|
|
2232
|
+
)) : null, /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full flex flex-col gap-4 mt-1" }, /* @__PURE__ */ import_react33.default.createElement("div", { className: "w-full bg-white rounded-2xl overflow-hidden" }, activeCard.prepaid && /* @__PURE__ */ import_react33.default.createElement(
|
|
2233
|
+
MenuRow,
|
|
2234
|
+
{
|
|
2235
|
+
icon: import_core_free_icons12.PlusSignIcon,
|
|
2236
|
+
title: "Fund Card",
|
|
2237
|
+
subtitle: "Add money to card",
|
|
2238
|
+
onClick: () => {
|
|
2239
|
+
if (!actionsDisabled && onFundCard) onFundCard(activeCard.id);
|
|
2240
|
+
},
|
|
2241
|
+
disabled: actionsDisabled
|
|
2242
|
+
}
|
|
2243
|
+
), /* @__PURE__ */ import_react33.default.createElement(
|
|
2224
2244
|
MenuRow,
|
|
2225
2245
|
{
|
|
2226
2246
|
icon: import_core_free_icons12.ViewOffSlashIcon,
|
package/dist/index.mjs
CHANGED
|
@@ -156,8 +156,7 @@ var ThreeDActionButton = ({
|
|
|
156
156
|
disabled = false,
|
|
157
157
|
isLoading = false,
|
|
158
158
|
children,
|
|
159
|
-
className = ""
|
|
160
|
-
ariaLabel
|
|
159
|
+
className = ""
|
|
161
160
|
}) => {
|
|
162
161
|
const isInteractionDisabled = disabled || isLoading;
|
|
163
162
|
const baseShadow = `
|
|
@@ -1058,7 +1057,6 @@ var UniversalProfileSettings = ({
|
|
|
1058
1057
|
{
|
|
1059
1058
|
type: "button",
|
|
1060
1059
|
onClick: () => setIsPinModalOpen(true),
|
|
1061
|
-
"aria-label": "PIN Settings",
|
|
1062
1060
|
className: "w-9 h-9 flex items-center justify-center border border-neutral-200 rounded-full text-black hover:bg-neutral-50 transition-colors outline-none"
|
|
1063
1061
|
},
|
|
1064
1062
|
/* @__PURE__ */ React12.createElement(HugeiconsIcon6, { icon: LockKeyIcon, size: 17, className: "text-black" })
|
|
@@ -1940,7 +1938,8 @@ import {
|
|
|
1940
1938
|
ArrowRight01Icon as ArrowRight01Icon3,
|
|
1941
1939
|
SlidersHorizontalIcon,
|
|
1942
1940
|
ViewOffSlashIcon as ViewOffSlashIcon2,
|
|
1943
|
-
Loading03Icon as Loading03Icon9
|
|
1941
|
+
Loading03Icon as Loading03Icon9,
|
|
1942
|
+
PlusSignIcon as PlusSignIcon2
|
|
1944
1943
|
} from "@hugeicons/core-free-icons";
|
|
1945
1944
|
|
|
1946
1945
|
// src/components/PinDialerBottomSheet.tsx
|
|
@@ -2028,7 +2027,9 @@ var UniversalCardPage = ({
|
|
|
2028
2027
|
onReveal,
|
|
2029
2028
|
onFreeze,
|
|
2030
2029
|
onSetLimits,
|
|
2031
|
-
onDelete
|
|
2030
|
+
onDelete,
|
|
2031
|
+
onFundCard,
|
|
2032
|
+
onCreateCard
|
|
2032
2033
|
}) => {
|
|
2033
2034
|
const router = useRouter();
|
|
2034
2035
|
const sortedCards = React20.useMemo(() => {
|
|
@@ -2122,7 +2123,7 @@ var UniversalCardPage = ({
|
|
|
2122
2123
|
const capitalized = type.charAt(0).toUpperCase() + type.slice(1).toLowerCase();
|
|
2123
2124
|
return `${capitalized} Card`;
|
|
2124
2125
|
};
|
|
2125
|
-
return /* @__PURE__ */ React20.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300" },
|
|
2126
|
+
return /* @__PURE__ */ React20.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300" }, /* @__PURE__ */ React20.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, sortedCards.length > 0 && /* @__PURE__ */ React20.createElement("div", { className: "flex items-center bg-white rounded-full p-1 sm:p-1.5 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => {
|
|
2126
2127
|
const isActive = activeTabIndex === idx;
|
|
2127
2128
|
return /* @__PURE__ */ React20.createElement(
|
|
2128
2129
|
"button",
|
|
@@ -2133,7 +2134,16 @@ var UniversalCardPage = ({
|
|
|
2133
2134
|
},
|
|
2134
2135
|
formatTabLabel(tab.type)
|
|
2135
2136
|
);
|
|
2136
|
-
}))
|
|
2137
|
+
})), /* @__PURE__ */ React20.createElement(
|
|
2138
|
+
"button",
|
|
2139
|
+
{
|
|
2140
|
+
onClick: () => {
|
|
2141
|
+
if (onCreateCard) onCreateCard();
|
|
2142
|
+
},
|
|
2143
|
+
className: "w-10 h-10 rounded-full bg-white flex items-center justify-center text-neutral-500 hover:text-black transition-colors shrink-0 outline-none"
|
|
2144
|
+
},
|
|
2145
|
+
/* @__PURE__ */ React20.createElement(HugeiconsIcon14, { icon: PlusSignIcon2, size: 18 })
|
|
2146
|
+
)), /* @__PURE__ */ React20.createElement("div", { className: "w-full pt-2 pb-2 flex justify-center" }, /* @__PURE__ */ React20.createElement(
|
|
2137
2147
|
"div",
|
|
2138
2148
|
{
|
|
2139
2149
|
className: "relative w-full max-w-85",
|
|
@@ -2178,7 +2188,7 @@ var UniversalCardPage = ({
|
|
|
2178
2188
|
className: "absolute inset-0 bg-cover bg-center",
|
|
2179
2189
|
style: { backgroundImage: `url(${activeCard.cardBgSrc})` }
|
|
2180
2190
|
}
|
|
2181
|
-
), /* @__PURE__ */ React20.createElement("div", { className: "relative z-10 w-full h-full p-5 flex flex-col justify-between" }, /* @__PURE__ */ React20.createElement("div", { className: "flex items-start w-full gap-4" }), /* @__PURE__ */ React20.createElement("div", { className: "flex justify-between items-end w-full" }, /* @__PURE__ */ React20.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React20.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, "Card Tier"), /* @__PURE__ */ React20.createElement("span", { className: `text-[12px] tracking-widest font-medium
|
|
2191
|
+
), /* @__PURE__ */ React20.createElement("div", { className: "relative z-10 w-full h-full p-5 flex flex-col justify-between" }, /* @__PURE__ */ React20.createElement("div", { className: "flex items-start justify-end w-full gap-4" }, activeCard.prepaid && /* @__PURE__ */ React20.createElement("div", { className: "flex flex-col items-end gap-1 text-right" }, /* @__PURE__ */ React20.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, "Card Tier"), /* @__PURE__ */ React20.createElement("span", { className: `text-[12px] tracking-widest font-medium ${activeCard.contentDark ? "text-black" : "text-white"}` }, activeCard.tier))), /* @__PURE__ */ React20.createElement("div", { className: "flex justify-between items-end w-full" }, /* @__PURE__ */ React20.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React20.createElement("span", { className: `text-[9px] tracking-widest ${activeCard.contentDark ? "text-black/60" : "text-white/60"}` }, activeCard.prepaid ? "Card Balance" : "Card Tier"), /* @__PURE__ */ React20.createElement("span", { className: `text-[12px] tracking-widest font-medium ${activeCard.contentDark ? "text-black" : "text-white"}` }, activeCard.prepaid ? activeCard.balance || "$0.00" : activeCard.tier)), activeCard.networkLogoSrc && /* @__PURE__ */ React20.createElement(
|
|
2182
2192
|
"img",
|
|
2183
2193
|
{
|
|
2184
2194
|
src: activeCard.networkLogoSrc,
|
|
@@ -2186,7 +2196,7 @@ var UniversalCardPage = ({
|
|
|
2186
2196
|
className: "h-10 w-auto max-w-20 object-contain opacity-90"
|
|
2187
2197
|
}
|
|
2188
2198
|
))))
|
|
2189
|
-
)), activeCard.bannerProps ? /* @__PURE__ */ React20.createElement("div", { className: "mb-6 w-full" }, /* @__PURE__ */ React20.createElement(Banner, { ...activeCard.bannerProps })) : isPreordered ? /* @__PURE__ */ React20.createElement("div", { className: "mb-6 w-full" }, /* @__PURE__ */ React20.createElement(
|
|
2199
|
+
)), activeCard.bannerProps ? /* @__PURE__ */ React20.createElement("div", { className: "mb-6 w-full mt-2" }, /* @__PURE__ */ React20.createElement(Banner, { ...activeCard.bannerProps })) : isPreordered ? /* @__PURE__ */ React20.createElement("div", { className: "mb-6 w-full mt-2" }, /* @__PURE__ */ React20.createElement(
|
|
2190
2200
|
Banner,
|
|
2191
2201
|
{
|
|
2192
2202
|
type: "success",
|
|
@@ -2194,7 +2204,18 @@ var UniversalCardPage = ({
|
|
|
2194
2204
|
message: `Your ${activeCard.tier} ${activeCard.type.toLowerCase()} card has been pre-ordered successfully and is pending batch processing.`,
|
|
2195
2205
|
isDismissible: false
|
|
2196
2206
|
}
|
|
2197
|
-
)) : null, /* @__PURE__ */ React20.createElement("div", { className: "w-full flex flex-col gap-4" }, /* @__PURE__ */ React20.createElement("div", { className: "w-full bg-white rounded-2xl overflow-hidden" }, /* @__PURE__ */ React20.createElement(
|
|
2207
|
+
)) : null, /* @__PURE__ */ React20.createElement("div", { className: "w-full flex flex-col gap-4 mt-1" }, /* @__PURE__ */ React20.createElement("div", { className: "w-full bg-white rounded-2xl overflow-hidden" }, activeCard.prepaid && /* @__PURE__ */ React20.createElement(
|
|
2208
|
+
MenuRow,
|
|
2209
|
+
{
|
|
2210
|
+
icon: PlusSignIcon2,
|
|
2211
|
+
title: "Fund Card",
|
|
2212
|
+
subtitle: "Add money to card",
|
|
2213
|
+
onClick: () => {
|
|
2214
|
+
if (!actionsDisabled && onFundCard) onFundCard(activeCard.id);
|
|
2215
|
+
},
|
|
2216
|
+
disabled: actionsDisabled
|
|
2217
|
+
}
|
|
2218
|
+
), /* @__PURE__ */ React20.createElement(
|
|
2198
2219
|
MenuRow,
|
|
2199
2220
|
{
|
|
2200
2221
|
icon: ViewOffSlashIcon2,
|