@chainberry/ui-components 1.0.49 → 1.0.50
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.cjs +1 -1
- package/dist/index.d.ts +109 -0
- package/dist/index.mjs +21092 -20549
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -221,6 +221,42 @@ export declare function AssetValue({ value, code, icon, className, }: {
|
|
|
221
221
|
className?: string;
|
|
222
222
|
}): JSX.Element;
|
|
223
223
|
|
|
224
|
+
/** The languages the interface ships in — feeds the language picker. The flag is
|
|
225
|
+
* a plain emoji so it needs no icon set and renders in the picker's `leading`
|
|
226
|
+
* slot (shown both in the closed trigger and in the open list). */
|
|
227
|
+
export declare const AUTH_LANGUAGES: {
|
|
228
|
+
value: AuthLanguage;
|
|
229
|
+
label: string;
|
|
230
|
+
flag: string;
|
|
231
|
+
}[];
|
|
232
|
+
|
|
233
|
+
export declare function AuthFormShell({ title, description,
|
|
234
|
+
/** badge above the title — result screens put an `AuthStatusIcon` here */
|
|
235
|
+
icon, children,
|
|
236
|
+
/** closing line under the form — links back into the flow */
|
|
237
|
+
footer,
|
|
238
|
+
/** hides the logo for screens that lead with their own icon */
|
|
239
|
+
brand, className, }: {
|
|
240
|
+
title: ReactNode;
|
|
241
|
+
description?: ReactNode;
|
|
242
|
+
icon?: ReactNode;
|
|
243
|
+
children: ReactNode;
|
|
244
|
+
footer?: ReactNode;
|
|
245
|
+
brand?: boolean;
|
|
246
|
+
className?: string;
|
|
247
|
+
}): JSX.Element;
|
|
248
|
+
|
|
249
|
+
export declare type AuthLanguage = "en" | "ru";
|
|
250
|
+
|
|
251
|
+
export declare function authLanguageLabel(value: AuthLanguage): string;
|
|
252
|
+
|
|
253
|
+
export declare function AuthUtilityBar({ language, onLanguageChange, supportEmail, className, }: {
|
|
254
|
+
language?: AuthLanguage;
|
|
255
|
+
onLanguageChange?: (language: AuthLanguage) => void;
|
|
256
|
+
supportEmail?: string;
|
|
257
|
+
className?: string;
|
|
258
|
+
}): JSX.Element;
|
|
259
|
+
|
|
224
260
|
/** One run of a scheduled automation rule — bundles many on-chain transactions
|
|
225
261
|
into a single activity row (Amount shows the batch total + a tx count). */
|
|
226
262
|
declare type AutomationActivity = ActivityBase & {
|
|
@@ -599,6 +635,17 @@ export declare namespace convertTypes {
|
|
|
599
635
|
}
|
|
600
636
|
}
|
|
601
637
|
|
|
638
|
+
declare const COPY: {
|
|
639
|
+
readonly reset: {
|
|
640
|
+
readonly label: "New password";
|
|
641
|
+
readonly submit: "Reset password";
|
|
642
|
+
};
|
|
643
|
+
readonly invite: {
|
|
644
|
+
readonly label: "Choose a password";
|
|
645
|
+
readonly submit: "Set password";
|
|
646
|
+
};
|
|
647
|
+
};
|
|
648
|
+
|
|
602
649
|
export declare function CopyableId({ value, head, tail, revealOnHover, asLink, mask, href, className, }: {
|
|
603
650
|
value: string;
|
|
604
651
|
head?: number;
|
|
@@ -1024,6 +1071,14 @@ export declare type FooterAction = {
|
|
|
1024
1071
|
className?: string;
|
|
1025
1072
|
};
|
|
1026
1073
|
|
|
1074
|
+
export declare function ForgotPasswordForm({ onSubmit, onBack, defaultEmail, className, }: {
|
|
1075
|
+
/** runs after the spinner with the address the link went to */
|
|
1076
|
+
onSubmit?: (email: string) => void;
|
|
1077
|
+
onBack?: () => void;
|
|
1078
|
+
defaultEmail?: string;
|
|
1079
|
+
className?: string;
|
|
1080
|
+
}): JSX.Element;
|
|
1081
|
+
|
|
1027
1082
|
/** Grouped crypto figure, 2–8 decimals, e.g. 6229.32 → "6,229.32". */
|
|
1028
1083
|
declare function formatCrypto(value: number): string;
|
|
1029
1084
|
|
|
@@ -1452,6 +1507,23 @@ declare const KIND_OPTIONS: {
|
|
|
1452
1507
|
|
|
1453
1508
|
export declare function Label({ className, ...props }: ComponentProps<typeof LabelPrimitive.Root>): JSX.Element;
|
|
1454
1509
|
|
|
1510
|
+
export declare function LoginForm({ onSubmit, onForgotPassword, defaultEmail,
|
|
1511
|
+
/** message shown in the banner regardless of validation (for stories/errors) */
|
|
1512
|
+
error, submitLabel, className, }: {
|
|
1513
|
+
/** runs after the spinner, once the form is considered valid */
|
|
1514
|
+
onSubmit?: (result: LoginSubmit) => void;
|
|
1515
|
+
onForgotPassword?: () => void;
|
|
1516
|
+
defaultEmail?: string;
|
|
1517
|
+
error?: ReactNode;
|
|
1518
|
+
submitLabel?: string;
|
|
1519
|
+
className?: string;
|
|
1520
|
+
}): JSX.Element;
|
|
1521
|
+
|
|
1522
|
+
declare type LoginSubmit = {
|
|
1523
|
+
email: string;
|
|
1524
|
+
password: string;
|
|
1525
|
+
};
|
|
1526
|
+
|
|
1455
1527
|
export declare function Logo({ src, alt, href, collapsed, className: imgClassName, }: {
|
|
1456
1528
|
src?: string;
|
|
1457
1529
|
alt?: string;
|
|
@@ -1927,6 +1999,16 @@ export declare function ReportSummaryGroup({ summaries, className, }: {
|
|
|
1927
1999
|
|
|
1928
2000
|
declare type ReportView = 'volume' | 'transactions';
|
|
1929
2001
|
|
|
2002
|
+
export declare function ResetPasswordForm({ mode, onSubmit, onBack, className, }: {
|
|
2003
|
+
mode?: ResetPasswordMode;
|
|
2004
|
+
/** runs after the spinner, once the rules pass and both fields match */
|
|
2005
|
+
onSubmit?: (password: string) => void;
|
|
2006
|
+
onBack?: () => void;
|
|
2007
|
+
className?: string;
|
|
2008
|
+
}): JSX.Element;
|
|
2009
|
+
|
|
2010
|
+
declare type ResetPasswordMode = keyof typeof COPY;
|
|
2011
|
+
|
|
1930
2012
|
export declare const RISK_ICONS: Record<RiskLevel, string>;
|
|
1931
2013
|
|
|
1932
2014
|
declare const RISK_OPTIONS: {
|
|
@@ -2150,6 +2232,9 @@ declare type SummaryFigure = {
|
|
|
2150
2232
|
strong?: boolean;
|
|
2151
2233
|
};
|
|
2152
2234
|
|
|
2235
|
+
/** Where "Contact support" points. */
|
|
2236
|
+
export declare const SUPPORT_EMAIL = "support@chainberry.io";
|
|
2237
|
+
|
|
2153
2238
|
export declare function Table({ className, containerClassName, ...props }: React_2.ComponentProps<"table"> & {
|
|
2154
2239
|
containerClassName?: string;
|
|
2155
2240
|
}): React_2.JSX.Element;
|
|
@@ -2501,6 +2586,30 @@ declare const TREASURY_ACTIVITY: TreasuryActivityRecord[];
|
|
|
2501
2586
|
/** One row in the Treasury Activity feed — a discriminated union over `kind`. */
|
|
2502
2587
|
declare type TreasuryActivityRecord = DepositActivity | WithdrawalActivity | TransferActivity | ConversionActivity | AutomationActivity;
|
|
2503
2588
|
|
|
2589
|
+
export declare function TwoFactorForm({ onVerify, onResend, onUseRecoveryCode, onBack, length, className, }: {
|
|
2590
|
+
/** runs after the spinner, with the code that was entered */
|
|
2591
|
+
onVerify?: (code: string) => void;
|
|
2592
|
+
onResend?: () => void;
|
|
2593
|
+
onUseRecoveryCode?: () => void;
|
|
2594
|
+
/** back to the credentials step */
|
|
2595
|
+
onBack?: () => void;
|
|
2596
|
+
length?: number;
|
|
2597
|
+
className?: string;
|
|
2598
|
+
}): JSX.Element;
|
|
2599
|
+
|
|
2600
|
+
export declare function TwoFactorSetupForm({
|
|
2601
|
+
/** otpauth:// URI the QR encodes */
|
|
2602
|
+
secret,
|
|
2603
|
+
/** base64-encoded PNG data URL for the QR code */
|
|
2604
|
+
qrDataUrl, onSubmit, submitLabel, className, }: {
|
|
2605
|
+
secret?: string;
|
|
2606
|
+
qrDataUrl?: string;
|
|
2607
|
+
/** runs after the spinner, with the code that was entered */
|
|
2608
|
+
onSubmit?: (code: string) => void;
|
|
2609
|
+
submitLabel?: string;
|
|
2610
|
+
className?: string;
|
|
2611
|
+
}): JSX.Element;
|
|
2612
|
+
|
|
2504
2613
|
declare type TxFilter = {
|
|
2505
2614
|
types: TxType[];
|
|
2506
2615
|
statuses: TxStatus[];
|