@canton-network/core-wallet-ui-components 1.16.0 → 1.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/activity-utils-CsiZsTG2.cjs +4 -0
- package/dist/activity-utils-CsiZsTG2.cjs.map +1 -0
- package/dist/activity-utils-glrdQSNU.js +1944 -0
- package/dist/activity-utils-glrdQSNU.js.map +1 -0
- package/dist/components/auth-editor.d.ts.map +1 -1
- package/dist/components/idp-form.d.ts.map +1 -1
- package/dist/components/message-detail.d.ts +30 -0
- package/dist/components/message-detail.d.ts.map +1 -0
- package/dist/components/transaction-detail.d.ts +1 -1
- package/dist/components/transaction-detail.d.ts.map +1 -1
- package/dist/components/wallet-create-form.d.ts +1 -1
- package/dist/components/wallet-create-form.d.ts.map +1 -1
- package/dist/components/wallet-edit-form.d.ts.map +1 -1
- package/dist/components/wallet-form.d.ts +4 -0
- package/dist/components/wallet-form.d.ts.map +1 -1
- package/dist/handle-errors.d.ts +2 -7
- package/dist/handle-errors.d.ts.map +1 -1
- package/dist/index.cjs +514 -590
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4065 -4186
- package/dist/index.js.map +1 -1
- package/dist/internal/activity-render.d.ts +2 -0
- package/dist/internal/activity-render.d.ts.map +1 -0
- package/dist/internal/activity-utils.d.ts +2 -0
- package/dist/internal/activity-utils.d.ts.map +1 -1
- package/dist/internal/error-toast.d.ts +12 -0
- package/dist/internal/error-toast.d.ts.map +1 -0
- package/dist/react/components/ApiKeyCard.d.ts +8 -0
- package/dist/react/components/ApiKeyCard.d.ts.map +1 -0
- package/dist/react/components/ApiKeyForm.d.ts +8 -0
- package/dist/react/components/ApiKeyForm.d.ts.map +1 -0
- package/dist/react/components/AppHeader.d.ts +30 -0
- package/dist/react/components/AppHeader.d.ts.map +1 -0
- package/dist/react/components/ApprovalActions.d.ts +20 -0
- package/dist/react/components/ApprovalActions.d.ts.map +1 -0
- package/dist/react/components/AuthEditor.d.ts +21 -0
- package/dist/react/components/AuthEditor.d.ts.map +1 -0
- package/dist/react/components/BackLink.d.ts +18 -0
- package/dist/react/components/BackLink.d.ts.map +1 -0
- package/dist/react/components/CardDetailRow.d.ts +15 -0
- package/dist/react/components/CardDetailRow.d.ts.map +1 -0
- package/dist/react/components/CopyButton.d.ts +8 -0
- package/dist/react/components/CopyButton.d.ts.map +1 -0
- package/dist/react/components/ErrorPage.d.ts +10 -0
- package/dist/react/components/ErrorPage.d.ts.map +1 -0
- package/dist/react/components/IdpCard.d.ts +9 -0
- package/dist/react/components/IdpCard.d.ts.map +1 -0
- package/dist/react/components/IdpForm.d.ts +19 -0
- package/dist/react/components/IdpForm.d.ts.map +1 -0
- package/dist/react/components/LoadingState.d.ts +7 -0
- package/dist/react/components/LoadingState.d.ts.map +1 -0
- package/dist/react/components/LoginForm.d.ts +30 -0
- package/dist/react/components/LoginForm.d.ts.map +1 -0
- package/dist/react/components/MessageDetail.d.ts +27 -0
- package/dist/react/components/MessageDetail.d.ts.map +1 -0
- package/dist/react/components/NetworkCard.d.ts +13 -0
- package/dist/react/components/NetworkCard.d.ts.map +1 -0
- package/dist/react/components/NetworkForm.d.ts +17 -0
- package/dist/react/components/NetworkForm.d.ts.map +1 -0
- package/dist/react/components/Pagination.d.ts +13 -0
- package/dist/react/components/Pagination.d.ts.map +1 -0
- package/dist/react/components/SigningProviderSelect.d.ts +15 -0
- package/dist/react/components/SigningProviderSelect.d.ts.map +1 -0
- package/dist/react/components/Toast.d.ts +20 -0
- package/dist/react/components/Toast.d.ts.map +1 -0
- package/dist/react/components/TransactionCard.d.ts +17 -0
- package/dist/react/components/TransactionCard.d.ts.map +1 -0
- package/dist/react/components/TransactionDetail.d.ts +29 -0
- package/dist/react/components/TransactionDetail.d.ts.map +1 -0
- package/dist/react/components/WalletCard.d.ts +21 -0
- package/dist/react/components/WalletCard.d.ts.map +1 -0
- package/dist/react/components/WalletCreateForm.d.ts +35 -0
- package/dist/react/components/WalletCreateForm.d.ts.map +1 -0
- package/dist/react/components/WalletEditForm.d.ts +35 -0
- package/dist/react/components/WalletEditForm.d.ts.map +1 -0
- package/dist/react/components/WalletForm.d.ts +25 -0
- package/dist/react/components/WalletForm.d.ts.map +1 -0
- package/dist/react/components/WalletsSync.d.ts +13 -0
- package/dist/react/components/WalletsSync.d.ts.map +1 -0
- package/dist/react/contexts/ToastContext.d.ts +14 -0
- package/dist/react/contexts/ToastContext.d.ts.map +1 -0
- package/dist/react/contexts/ToastProvider.d.ts +10 -0
- package/dist/react/contexts/ToastProvider.d.ts.map +1 -0
- package/dist/react/hooks/useErrorToast.d.ts +8 -0
- package/dist/react/hooks/useErrorToast.d.ts.map +1 -0
- package/dist/react/hooks/useToast.d.ts +4 -0
- package/dist/react/hooks/useToast.d.ts.map +1 -0
- package/dist/react/index.cjs +19 -0
- package/dist/react/index.cjs.map +1 -0
- package/dist/react/index.d.ts +31 -0
- package/dist/react/index.d.ts.map +1 -0
- package/dist/react/index.js +2488 -0
- package/dist/react/index.js.map +1 -0
- package/dist/react/logger.d.ts +2 -0
- package/dist/react/logger.d.ts.map +1 -0
- package/dist/routing.d.ts +1 -1
- package/dist/routing.d.ts.map +1 -1
- package/dist/windows/popup.d.ts.map +1 -1
- package/dist/windows/wallet-picker.d.ts.map +1 -1
- package/package.json +58 -24
- package/dist/components/api-key-card.test.d.ts +0 -1
- package/dist/components/api-key-card.test.d.ts.map +0 -1
- package/dist/components/api-key-form.test.d.ts +0 -1
- package/dist/components/api-key-form.test.d.ts.map +0 -1
- package/dist/components/app-header.test.d.ts +0 -1
- package/dist/components/app-header.test.d.ts.map +0 -1
- package/dist/components/app-layout.test.d.ts +0 -2
- package/dist/components/app-layout.test.d.ts.map +0 -1
- package/dist/components/auth-editor.test.d.ts +0 -1
- package/dist/components/auth-editor.test.d.ts.map +0 -1
- package/dist/components/back-link.test.d.ts +0 -2
- package/dist/components/back-link.test.d.ts.map +0 -1
- package/dist/components/copy-button.test.d.ts +0 -1
- package/dist/components/copy-button.test.d.ts.map +0 -1
- package/dist/components/custom-toast.test.d.ts +0 -1
- package/dist/components/custom-toast.test.d.ts.map +0 -1
- package/dist/components/error-page.test.d.ts +0 -2
- package/dist/components/error-page.test.d.ts.map +0 -1
- package/dist/components/fixtures.d.ts +0 -15
- package/dist/components/fixtures.d.ts.map +0 -1
- package/dist/components/form-input.test.d.ts +0 -1
- package/dist/components/form-input.test.d.ts.map +0 -1
- package/dist/components/idp-card.test.d.ts +0 -1
- package/dist/components/idp-card.test.d.ts.map +0 -1
- package/dist/components/idp-form.test.d.ts +0 -2
- package/dist/components/idp-form.test.d.ts.map +0 -1
- package/dist/components/loading-state.test.d.ts +0 -2
- package/dist/components/loading-state.test.d.ts.map +0 -1
- package/dist/components/login-form.test.d.ts +0 -2
- package/dist/components/login-form.test.d.ts.map +0 -1
- package/dist/components/network-card.test.d.ts +0 -1
- package/dist/components/network-card.test.d.ts.map +0 -1
- package/dist/components/network-form.test.d.ts +0 -1
- package/dist/components/network-form.test.d.ts.map +0 -1
- package/dist/components/network-table.d.ts +0 -10
- package/dist/components/network-table.d.ts.map +0 -1
- package/dist/components/network-table.test.d.ts +0 -1
- package/dist/components/network-table.test.d.ts.map +0 -1
- package/dist/components/networks.d.ts +0 -16
- package/dist/components/networks.d.ts.map +0 -1
- package/dist/components/networks.test.d.ts +0 -2
- package/dist/components/networks.test.d.ts.map +0 -1
- package/dist/components/not-found.test.d.ts +0 -2
- package/dist/components/not-found.test.d.ts.map +0 -1
- package/dist/components/pagination.test.d.ts +0 -1
- package/dist/components/pagination.test.d.ts.map +0 -1
- package/dist/components/sessions.d.ts +0 -8
- package/dist/components/sessions.d.ts.map +0 -1
- package/dist/components/sessions.test.d.ts +0 -1
- package/dist/components/sessions.test.d.ts.map +0 -1
- package/dist/components/transaction-card.test.d.ts +0 -1
- package/dist/components/transaction-card.test.d.ts.map +0 -1
- package/dist/components/transaction-detail.test.d.ts +0 -1
- package/dist/components/transaction-detail.test.d.ts.map +0 -1
- package/dist/components/wallet-card.test.d.ts +0 -1
- package/dist/components/wallet-card.test.d.ts.map +0 -1
- package/dist/components/wallet-create-form.test.d.ts +0 -1
- package/dist/components/wallet-create-form.test.d.ts.map +0 -1
- package/dist/components/wallet-edit-form.test.d.ts +0 -1
- package/dist/components/wallet-edit-form.test.d.ts.map +0 -1
- package/dist/components/wallet-picker.test.d.ts +0 -1
- package/dist/components/wallet-picker.test.d.ts.map +0 -1
- package/dist/components/wallets-sync.test.d.ts +0 -1
- package/dist/components/wallets-sync.test.d.ts.map +0 -1
- package/dist/handle-errors.test.d.ts +0 -1
- package/dist/handle-errors.test.d.ts.map +0 -1
- package/dist/routing.test.d.ts +0 -2
- package/dist/routing.test.d.ts.map +0 -1
- package/dist/utils.test.d.ts +0 -2
- package/dist/utils.test.d.ts.map +0 -1
- package/dist/windows/popup.test.d.ts +0 -2
- package/dist/windows/popup.test.d.ts.map +0 -1
- package/dist/windows/wallet-picker.test.d.ts +0 -2
- package/dist/windows/wallet-picker.test.d.ts.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"activity-render.d.ts","sourceRoot":"","sources":["../../src/internal/activity-render.ts"],"names":[],"mappings":"AAKA,wBAAgB,mBAAmB,CAC/B,KAAK,EAAE,MAAM,EACb,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAChC,SAAS,EAAE,MAAM,mCA0BpB"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ParsedTransactionInfo } from '@canton-network/core-tx-visualizer';
|
|
2
2
|
export declare function getActivityStatusTone(status: string): 'success' | 'warning' | 'danger' | 'default';
|
|
3
|
+
/** The MUI colour for an activity's status badge */
|
|
4
|
+
export declare function getActivityStatusColor(status: string): 'success' | 'warning' | 'error' | 'default';
|
|
3
5
|
export declare function getActivityStatusLabel(status: string): string;
|
|
4
6
|
export declare function getActivityStatusBadgeClass(status: string): string;
|
|
5
7
|
export declare function formatActivityDate(value: string | null | undefined): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"activity-utils.d.ts","sourceRoot":"","sources":["../../src/internal/activity-utils.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAA;AAE/E,wBAAgB,qBAAqB,CACjC,MAAM,EAAE,MAAM,GACf,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAc9C;AAED,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAE7D;AAED,wBAAgB,2BAA2B,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAWlE;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,CAO3E;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,qBAAqB,GAAG,IAAI,GAAG,MAAM,CAG5E;AAED,wBAAgB,iBAAiB,CAC7B,MAAM,EAAE,qBAAqB,GAAG,IAAI,GACrC,MAAM,CAOR"}
|
|
1
|
+
{"version":3,"file":"activity-utils.d.ts","sourceRoot":"","sources":["../../src/internal/activity-utils.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAA;AAE/E,wBAAgB,qBAAqB,CACjC,MAAM,EAAE,MAAM,GACf,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAc9C;AAED,oDAAoD;AACpD,wBAAgB,sBAAsB,CAClC,MAAM,EAAE,MAAM,GACf,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAG7C;AAED,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAE7D;AAED,wBAAgB,2BAA2B,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAWlE;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,CAO3E;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,qBAAqB,GAAG,IAAI,GAAG,MAAM,CAG5E;AAED,wBAAgB,iBAAiB,CAC7B,MAAM,EAAE,qBAAqB,GAAG,IAAI,GACrC,MAAM,CAOR"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type ErrorToastFallback = {
|
|
2
|
+
message?: string;
|
|
3
|
+
buttonText?: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
};
|
|
6
|
+
/** Turns any thrown value into the text shown by an error toast */
|
|
7
|
+
export declare function getErrorToastContent(e: unknown, fallback?: ErrorToastFallback): {
|
|
8
|
+
title: string;
|
|
9
|
+
message: string;
|
|
10
|
+
buttonText: string;
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=error-toast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"error-toast.d.ts","sourceRoot":"","sources":["../../src/internal/error-toast.ts"],"names":[],"mappings":"AAwBA,MAAM,MAAM,kBAAkB,GAAG;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,mEAAmE;AACnE,wBAAgB,oBAAoB,CAChC,CAAC,EAAE,OAAO,EACV,QAAQ,CAAC,EAAE,kBAAkB,GAC9B;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,CAYxD"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ApiKey } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface ApiKeyCardProps {
|
|
3
|
+
apiKey: ApiKey;
|
|
4
|
+
onRevoke: (apiKey: ApiKey) => void;
|
|
5
|
+
}
|
|
6
|
+
export declare const ApiKeyCard: ({ apiKey, onRevoke }: ApiKeyCardProps) => import('react').JSX.Element;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=ApiKeyCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ApiKeyCard.d.ts","sourceRoot":"","sources":["../../../src/react/components/ApiKeyCard.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6CAA6C,CAAA;AAYzE,UAAU,eAAe;IACrB,MAAM,EAAE,MAAM,CAAA;IACd,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;CACrC;AAED,eAAO,MAAM,UAAU,GAAI,sBAAsB,eAAe,gCAuB/D,CAAA"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { GenerateApiKeyParams } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface ApiKeyFormProps {
|
|
3
|
+
/** Called with the entered values when the form is submitted; the caller generates the key */
|
|
4
|
+
onGenerate: (apiKeyParams: GenerateApiKeyParams) => void;
|
|
5
|
+
}
|
|
6
|
+
export declare const ApiKeyForm: ({ onGenerate }: ApiKeyFormProps) => import('react').JSX.Element;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=ApiKeyForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ApiKeyForm.d.ts","sourceRoot":"","sources":["../../../src/react/components/ApiKeyForm.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6CAA6C,CAAA;AAGvF,UAAU,eAAe;IACrB,8FAA8F;IAC9F,UAAU,EAAE,CAAC,YAAY,EAAE,oBAAoB,KAAK,IAAI,CAAA;CAC3D;AAED,eAAO,MAAM,UAAU,GAAI,gBAAgB,eAAe,gCA8BzD,CAAA"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
interface StatusDotProps {
|
|
2
|
+
online: boolean;
|
|
3
|
+
}
|
|
4
|
+
export declare const StatusDot: ({ online }: StatusDotProps) => import('react').JSX.Element;
|
|
5
|
+
export interface AppHeaderNavItem {
|
|
6
|
+
label: string;
|
|
7
|
+
href: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const defaultNavItems: AppHeaderNavItem[];
|
|
10
|
+
/**
|
|
11
|
+
* Navigation renders plain `href`s. Apps using a client-side router should set
|
|
12
|
+
* `MuiButtonBase.defaultProps.LinkComponent` in their theme to an adapter around
|
|
13
|
+
* the router's link component; without one, links are regular anchors.
|
|
14
|
+
*/
|
|
15
|
+
interface AppHeaderProps {
|
|
16
|
+
iconSrc?: string;
|
|
17
|
+
networkName?: string;
|
|
18
|
+
networkConnected?: boolean;
|
|
19
|
+
dappApiUrl?: string;
|
|
20
|
+
/** Target of the logo link */
|
|
21
|
+
homeHref?: string;
|
|
22
|
+
/** Links shown in the menu, above the Dapp API URL and Logout items. `defaultNavItems` has the wallet gateway's pages */
|
|
23
|
+
navItems: AppHeaderNavItem[];
|
|
24
|
+
onLogout: () => void;
|
|
25
|
+
/** Called when the "Dapp API URL" menu item is clicked; the caller is responsible for copying the URL. The item is hidden when omitted */
|
|
26
|
+
onDappApiUrlCopy?: () => void;
|
|
27
|
+
}
|
|
28
|
+
export declare const AppHeader: ({ iconSrc, networkName, networkConnected, dappApiUrl, homeHref, navItems, onLogout, onDappApiUrlCopy, }: AppHeaderProps) => import('react').JSX.Element;
|
|
29
|
+
export {};
|
|
30
|
+
//# sourceMappingURL=AppHeader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AppHeader.d.ts","sourceRoot":"","sources":["../../../src/react/components/AppHeader.tsx"],"names":[],"mappings":"AAqBA,UAAU,cAAc;IACpB,MAAM,EAAE,OAAO,CAAA;CAClB;AAED,eAAO,MAAM,SAAS,GAAI,YAAY,cAAc,gCAanD,CAAA;AAED,MAAM,WAAW,gBAAgB;IAC7B,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,MAAM,CAAA;CACf;AAED,eAAO,MAAM,eAAe,EAAE,gBAAgB,EAM7C,CAAA;AAED;;;;GAIG;AACH,UAAU,cAAc;IACpB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,8BAA8B;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,yHAAyH;IACzH,QAAQ,EAAE,gBAAgB,EAAE,CAAA;IAC5B,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,0IAA0I;IAC1I,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAA;CAChC;AAED,eAAO,MAAM,SAAS,GAAI,yGASvB,cAAc,gCA+GhB,CAAA"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
interface ApprovalActionsProps {
|
|
2
|
+
/** Called when the approve button is clicked */
|
|
3
|
+
onApprove: () => void;
|
|
4
|
+
/** Called when "Reject" is clicked. The button is hidden when omitted */
|
|
5
|
+
onReject?: (() => void) | undefined;
|
|
6
|
+
/** The approve button's text @default 'Approve' */
|
|
7
|
+
approveLabel?: string;
|
|
8
|
+
/** Shows progress on the approve button and disables both buttons @default false */
|
|
9
|
+
approving?: boolean;
|
|
10
|
+
/** Shows progress on "Reject" and disables both buttons @default false */
|
|
11
|
+
rejecting?: boolean;
|
|
12
|
+
/** Shows progress on the approve button and disables it. "Reject" stays available, so a request can still be turned down while it is being signed @default false */
|
|
13
|
+
signing?: boolean;
|
|
14
|
+
/** Disables both buttons @default false */
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
}
|
|
17
|
+
/** The Reject and Approve buttons of an approval page, with their busy states */
|
|
18
|
+
export declare const ApprovalActions: ({ onApprove, onReject, approveLabel, approving, rejecting, signing, disabled, }: ApprovalActionsProps) => import('react').JSX.Element;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=ApprovalActions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ApprovalActions.d.ts","sourceRoot":"","sources":["../../../src/react/components/ApprovalActions.tsx"],"names":[],"mappings":"AAKA,UAAU,oBAAoB;IAC1B,gDAAgD;IAChD,SAAS,EAAE,MAAM,IAAI,CAAA;IACrB,yEAAyE;IACzE,QAAQ,CAAC,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAA;IACnC,mDAAmD;IACnD,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,oFAAoF;IACpF,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,0EAA0E;IAC1E,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,oKAAoK;IACpK,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,2CAA2C;IAC3C,QAAQ,CAAC,EAAE,OAAO,CAAA;CACrB;AAMD,iFAAiF;AACjF,eAAO,MAAM,eAAe,GAAI,iFAQ7B,oBAAoB,gCAwBtB,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Auth } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
export type AuthMethod = 'authorization_code' | 'client_credentials' | 'self_signed' | 'self_issued';
|
|
3
|
+
interface AuthEditorProps {
|
|
4
|
+
/** The current auth. The editor is controlled: pass back what `onChange` reports */
|
|
5
|
+
auth?: Auth | undefined;
|
|
6
|
+
/** Called with the edited auth as the user types, or `undefined` when it is removed or cancelled */
|
|
7
|
+
onChange: (auth: Auth | undefined) => void;
|
|
8
|
+
/** Methods offered in the select, the first one is the default @default all four */
|
|
9
|
+
allowedMethods?: AuthMethod[];
|
|
10
|
+
/** Lets the auth be absent: shows an Add button, and Edit/Remove once configured @default false */
|
|
11
|
+
optional?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* What this auth is for, used in the messages of an optional auth: "No
|
|
14
|
+
* admin auth configured." and "Admin auth will be removed after submitting
|
|
15
|
+
* this form." @default 'auth'
|
|
16
|
+
*/
|
|
17
|
+
label?: string;
|
|
18
|
+
}
|
|
19
|
+
export declare const AuthEditor: ({ auth, onChange, allowedMethods, optional, label, }: AuthEditorProps) => import('react').JSX.Element;
|
|
20
|
+
export {};
|
|
21
|
+
//# sourceMappingURL=AuthEditor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthEditor.d.ts","sourceRoot":"","sources":["../../../src/react/components/AuthEditor.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACR,IAAI,EAKP,MAAM,6CAA6C,CAAA;AAGpD,MAAM,MAAM,UAAU,GAChB,oBAAoB,GACpB,oBAAoB,GACpB,aAAa,GACb,aAAa,CAAA;AA0JnB,UAAU,eAAe;IACrB,oFAAoF;IACpF,IAAI,CAAC,EAAE,IAAI,GAAG,SAAS,CAAA;IACvB,oGAAoG;IACpG,QAAQ,EAAE,CAAC,IAAI,EAAE,IAAI,GAAG,SAAS,KAAK,IAAI,CAAA;IAC1C,oFAAoF;IACpF,cAAc,CAAC,EAAE,UAAU,EAAE,CAAA;IAC7B,mGAAmG;IACnG,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;CACjB;AAED,eAAO,MAAM,UAAU,GAAI,sDAMxB,eAAe,gCAuVjB,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
interface BackLinkBaseProps {
|
|
2
|
+
/** @default 'Back' */
|
|
3
|
+
label?: string;
|
|
4
|
+
}
|
|
5
|
+
interface BackLinkHrefProps extends BackLinkBaseProps {
|
|
6
|
+
/** Renders a link; navigation goes through the theme's LinkComponent */
|
|
7
|
+
href: string;
|
|
8
|
+
onClick?: never;
|
|
9
|
+
}
|
|
10
|
+
interface BackLinkClickProps extends BackLinkBaseProps {
|
|
11
|
+
href?: never;
|
|
12
|
+
/** Renders a button; the caller decides how to navigate */
|
|
13
|
+
onClick: () => void;
|
|
14
|
+
}
|
|
15
|
+
export type BackLinkProps = BackLinkHrefProps | BackLinkClickProps;
|
|
16
|
+
export declare const BackLink: ({ label, href, onClick }: BackLinkProps) => import('react').JSX.Element;
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=BackLink.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BackLink.d.ts","sourceRoot":"","sources":["../../../src/react/components/BackLink.tsx"],"names":[],"mappings":"AAMA,UAAU,iBAAiB;IACvB,sBAAsB;IACtB,KAAK,CAAC,EAAE,MAAM,CAAA;CACjB;AAED,UAAU,iBAAkB,SAAQ,iBAAiB;IACjD,wEAAwE;IACxE,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,KAAK,CAAA;CAClB;AAED,UAAU,kBAAmB,SAAQ,iBAAiB;IAClD,IAAI,CAAC,EAAE,KAAK,CAAA;IACZ,2DAA2D;IAC3D,OAAO,EAAE,MAAM,IAAI,CAAA;CACtB;AAED,MAAM,MAAM,aAAa,GAAG,iBAAiB,GAAG,kBAAkB,CAAA;AAElE,eAAO,MAAM,QAAQ,GAAI,0BAAmC,aAAa,gCASxE,CAAA"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface CardDetailRowProps {
|
|
3
|
+
label: string;
|
|
4
|
+
/** Text is truncated with an ellipsis; any other node (e.g. chips) is right-aligned and wraps */
|
|
5
|
+
value: ReactNode;
|
|
6
|
+
/** Tooltip for a text value. Defaults to the value; set it when `value` is shortened */
|
|
7
|
+
title?: string;
|
|
8
|
+
/** Renders the value in the secondary text colour, e.g. for masked values */
|
|
9
|
+
muted?: boolean;
|
|
10
|
+
/** Rendered after the value, e.g. a copy button */
|
|
11
|
+
action?: ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export declare const CardDetailRow: ({ label, value, title, muted, action, }: CardDetailRowProps) => import('react').JSX.Element;
|
|
14
|
+
export {};
|
|
15
|
+
//# sourceMappingURL=CardDetailRow.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CardDetailRow.d.ts","sourceRoot":"","sources":["../../../src/react/components/CardDetailRow.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,UAAU,kBAAkB;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,iGAAiG;IACjG,KAAK,EAAE,SAAS,CAAA;IAChB,wFAAwF;IACxF,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,6EAA6E;IAC7E,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,mDAAmD;IACnD,MAAM,CAAC,EAAE,SAAS,CAAA;CACrB;AAED,eAAO,MAAM,aAAa,GAAI,yCAM3B,kBAAkB,gCAkDpB,CAAA"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface CopyButtonProps {
|
|
2
|
+
onCopy?: (value: string) => void;
|
|
3
|
+
value: string;
|
|
4
|
+
label?: string;
|
|
5
|
+
}
|
|
6
|
+
export declare const CopyButton: ({ onCopy, value, label, }: CopyButtonProps) => import('react').JSX.Element;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=CopyButton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CopyButton.d.ts","sourceRoot":"","sources":["../../../src/react/components/CopyButton.tsx"],"names":[],"mappings":"AASA,UAAU,eAAe;IACrB,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IAChC,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,CAAC,EAAE,MAAM,CAAA;CACjB;AAED,eAAO,MAAM,UAAU,GAAI,2BAIxB,eAAe,gCA2CjB,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
interface ErrorPageProps {
|
|
2
|
+
mode: 'back' | 'refresh';
|
|
3
|
+
title?: string;
|
|
4
|
+
message?: string;
|
|
5
|
+
/** Called when the Back/Refresh button is clicked; the caller decides how to navigate or reload */
|
|
6
|
+
onAction: () => void;
|
|
7
|
+
}
|
|
8
|
+
export declare const ErrorPage: ({ mode, title, message, onAction, }: ErrorPageProps) => import('react').JSX.Element;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=ErrorPage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ErrorPage.d.ts","sourceRoot":"","sources":["../../../src/react/components/ErrorPage.tsx"],"names":[],"mappings":"AAQA,UAAU,cAAc;IACpB,IAAI,EAAE,MAAM,GAAG,SAAS,CAAA;IACxB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,mGAAmG;IACnG,QAAQ,EAAE,MAAM,IAAI,CAAA;CACvB;AAED,eAAO,MAAM,SAAS,GAAI,qCAKvB,cAAc,gCAsChB,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Idp } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface IdpCardProps {
|
|
3
|
+
idp: Idp;
|
|
4
|
+
/** Called when the card is clicked. The card is read-only (not clickable) when omitted */
|
|
5
|
+
onReview?: (idp: Idp) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare const IdpCard: ({ idp, onReview }: IdpCardProps) => import('react').JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=IdpCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IdpCard.d.ts","sourceRoot":"","sources":["../../../src/react/components/IdpCard.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,6CAA6C,CAAA;AAKtE,UAAU,YAAY;IAClB,GAAG,EAAE,GAAG,CAAA;IACR,0FAA0F;IAC1F,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAA;CAChC;AAED,eAAO,MAAM,OAAO,GAAI,mBAAmB,YAAY,gCAmFtD,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Idp } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface IdpFormProps {
|
|
3
|
+
/**
|
|
4
|
+
* The identity provider to review and edit. Leave it out to add a new one.
|
|
5
|
+
* The form starts over whenever a different object is passed
|
|
6
|
+
*/
|
|
7
|
+
idp?: Idp | undefined;
|
|
8
|
+
/** Disables the fields and the submit button, e.g. while saving */
|
|
9
|
+
loading?: boolean;
|
|
10
|
+
/** Called with the entered identity provider when the form is submitted */
|
|
11
|
+
onSave: (idp: Idp) => void;
|
|
12
|
+
/** Reviewing only. Called when "Delete identity provider" is clicked, with the `idp` prop. The delete section is hidden when omitted */
|
|
13
|
+
onDelete?: (idp: Idp) => void;
|
|
14
|
+
/** Reviewing only. Called when Cancel is clicked. The button is hidden when omitted */
|
|
15
|
+
onCancel?: () => void;
|
|
16
|
+
}
|
|
17
|
+
export declare const IdpForm: ({ idp, loading, onSave, onDelete, onCancel, }: IdpFormProps) => import('react').JSX.Element;
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=IdpForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IdpForm.d.ts","sourceRoot":"","sources":["../../../src/react/components/IdpForm.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,6CAA6C,CAAA;AAatE,UAAU,YAAY;IAClB;;;OAGG;IACH,GAAG,CAAC,EAAE,GAAG,GAAG,SAAS,CAAA;IACrB,mEAAmE;IACnE,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,2EAA2E;IAC3E,MAAM,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAA;IAC1B,wIAAwI;IACxI,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAA;IAC7B,uFAAuF;IACvF,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;CACxB;AAKD,eAAO,MAAM,OAAO,GAAI,+CAMrB,YAAY,gCAiLd,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LoadingState.d.ts","sourceRoot":"","sources":["../../../src/react/components/LoadingState.tsx"],"names":[],"mappings":"AAMA,UAAU,iBAAiB;IACvB,yBAAyB;IACzB,IAAI,CAAC,EAAE,MAAM,CAAA;CAChB;AAaD,eAAO,MAAM,YAAY,GAAI,UAAsB,iBAAiB,gCAkCnE,CAAA"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Idp, PublicNetwork } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
export interface LoginFormMessage {
|
|
3
|
+
type: 'error' | 'info';
|
|
4
|
+
text: string;
|
|
5
|
+
}
|
|
6
|
+
interface LoginFormProps {
|
|
7
|
+
/** Available networks to show in the dropdown */
|
|
8
|
+
networks: PublicNetwork[];
|
|
9
|
+
/** Available identity providers */
|
|
10
|
+
idps: Idp[];
|
|
11
|
+
/** Locks the form until the networks and identity providers are loaded */
|
|
12
|
+
loading?: boolean;
|
|
13
|
+
/** Locks the form while the caller is connecting */
|
|
14
|
+
connecting?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* A status message from the caller, e.g. a failed login. Pass a new object
|
|
17
|
+
* for each message: the form hides it when the user changes the network and
|
|
18
|
+
* shows the next one
|
|
19
|
+
*/
|
|
20
|
+
message?: LoginFormMessage | null;
|
|
21
|
+
/**
|
|
22
|
+
* Called when the form is submitted for a valid network and identity
|
|
23
|
+
* provider. `clientId` and `clientSecret` are set for self-signed identity
|
|
24
|
+
* providers, `username` for self-issued ones
|
|
25
|
+
*/
|
|
26
|
+
onConnect: (selectedNetwork: PublicNetwork, selectedIdp: Idp, clientId?: string, clientSecret?: string, username?: string) => void;
|
|
27
|
+
}
|
|
28
|
+
export declare const LoginForm: ({ networks, idps, loading, connecting, message, onConnect, }: LoginFormProps) => import('react').JSX.Element;
|
|
29
|
+
export {};
|
|
30
|
+
//# sourceMappingURL=LoginForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LoginForm.d.ts","sourceRoot":"","sources":["../../../src/react/components/LoginForm.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACR,GAAG,EACH,aAAa,EAChB,MAAM,6CAA6C,CAAA;AAIpD,MAAM,WAAW,gBAAgB;IAC7B,IAAI,EAAE,OAAO,GAAG,MAAM,CAAA;IACtB,IAAI,EAAE,MAAM,CAAA;CACf;AAED,UAAU,cAAc;IACpB,iDAAiD;IACjD,QAAQ,EAAE,aAAa,EAAE,CAAA;IACzB,mCAAmC;IACnC,IAAI,EAAE,GAAG,EAAE,CAAA;IACX,0EAA0E;IAC1E,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,oDAAoD;IACpD,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB;;;;OAIG;IACH,OAAO,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAA;IACjC;;;;OAIG;IACH,SAAS,EAAE,CACP,eAAe,EAAE,aAAa,EAC9B,WAAW,EAAE,GAAG,EAChB,QAAQ,CAAC,EAAE,MAAM,EACjB,YAAY,CAAC,EAAE,MAAM,EACrB,QAAQ,CAAC,EAAE,MAAM,KAChB,IAAI,CAAA;CACZ;AAKD,eAAO,MAAM,SAAS,GAAI,8DAOvB,cAAc,gCAqNhB,CAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
interface MessageDetailProps {
|
|
2
|
+
messageId: string;
|
|
3
|
+
/** The message to sign, shown as is */
|
|
4
|
+
message: string;
|
|
5
|
+
/** e.g. 'pending', 'signed', 'failed'. Only pending messages can be acted on */
|
|
6
|
+
status: string;
|
|
7
|
+
/** Who asked for the message to be signed. The row is hidden when omitted */
|
|
8
|
+
origin?: string | null;
|
|
9
|
+
externalTxId?: string | null;
|
|
10
|
+
/** Shows a "Back" link to this URL. The link is hidden when omitted */
|
|
11
|
+
backHref?: string;
|
|
12
|
+
/** Shows progress on "Approve" and disables both buttons @default false */
|
|
13
|
+
approving?: boolean;
|
|
14
|
+
/** Shows progress on "Reject" and disables both buttons @default false */
|
|
15
|
+
rejecting?: boolean;
|
|
16
|
+
/** Shows progress on "Approve" and disables it. "Reject" stays available, so a message can still be turned down while it is signed @default false */
|
|
17
|
+
signing?: boolean;
|
|
18
|
+
/** Disables both buttons, whatever the status @default false */
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
/** Called when "Approve" is clicked */
|
|
21
|
+
onApprove: (messageId: string) => void;
|
|
22
|
+
/** Called when "Reject" is clicked. The button is hidden when omitted */
|
|
23
|
+
onReject?: (messageId: string) => void;
|
|
24
|
+
}
|
|
25
|
+
export declare const MessageDetail: ({ messageId, message, status, origin, externalTxId, backHref, approving, rejecting, signing, disabled, onApprove, onReject, }: MessageDetailProps) => import('react').JSX.Element;
|
|
26
|
+
export {};
|
|
27
|
+
//# sourceMappingURL=MessageDetail.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MessageDetail.d.ts","sourceRoot":"","sources":["../../../src/react/components/MessageDetail.tsx"],"names":[],"mappings":"AAaA,UAAU,kBAAkB;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,uCAAuC;IACvC,OAAO,EAAE,MAAM,CAAA;IACf,gFAAgF;IAChF,MAAM,EAAE,MAAM,CAAA;IACd,6EAA6E;IAC7E,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACtB,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,uEAAuE;IACvE,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,0EAA0E;IAC1E,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,qJAAqJ;IACrJ,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,gEAAgE;IAChE,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,uCAAuC;IACvC,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IACtC,yEAAyE;IACzE,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CACzC;AAED,eAAO,MAAM,aAAa,GAAI,+HAa3B,kBAAkB,gCAyEpB,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { PublicNetwork } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface NetworkCardProps {
|
|
3
|
+
network: PublicNetwork;
|
|
4
|
+
/** Shows the "CONNECTED" badge and the access token row */
|
|
5
|
+
activeSession?: boolean;
|
|
6
|
+
/** Value copied by the "Copy access token" button; only shown with `activeSession` */
|
|
7
|
+
accessToken?: string;
|
|
8
|
+
/** Called when the card is clicked. The card is read-only (not clickable) when omitted */
|
|
9
|
+
onReview?: (network: PublicNetwork) => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const NetworkCard: ({ network, activeSession, accessToken, onReview, }: NetworkCardProps) => import('react').JSX.Element;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=NetworkCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NetworkCard.d.ts","sourceRoot":"","sources":["../../../src/react/components/NetworkCard.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6CAA6C,CAAA;AAKhF,UAAU,gBAAgB;IACtB,OAAO,EAAE,aAAa,CAAA;IACtB,2DAA2D;IAC3D,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,sFAAsF;IACtF,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,0FAA0F;IAC1F,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,aAAa,KAAK,IAAI,CAAA;CAC9C;AAED,eAAO,MAAM,WAAW,GAAI,oDAKzB,gBAAgB,gCAkGlB,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Network } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface NetworkFormProps {
|
|
3
|
+
/**
|
|
4
|
+
* The network to review and edit. Leave it out to add a new one. The form
|
|
5
|
+
* starts over whenever a different object is passed
|
|
6
|
+
*/
|
|
7
|
+
network?: Network | undefined;
|
|
8
|
+
/** Called with the entered network when the form is submitted */
|
|
9
|
+
onSave: (network: Network) => void;
|
|
10
|
+
/** Reviewing only. Called when "Delete Network" is clicked, with the `network` prop. The delete section is hidden when omitted */
|
|
11
|
+
onDelete?: (network: Network) => void;
|
|
12
|
+
/** Reviewing only. Called when Cancel is clicked. The button is hidden when omitted */
|
|
13
|
+
onCancel?: () => void;
|
|
14
|
+
}
|
|
15
|
+
export declare const NetworkForm: ({ network: reviewedNetwork, onSave, onDelete, onCancel, }: NetworkFormProps) => import('react').JSX.Element;
|
|
16
|
+
export {};
|
|
17
|
+
//# sourceMappingURL=NetworkForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NetworkForm.d.ts","sourceRoot":"","sources":["../../../src/react/components/NetworkForm.tsx"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAQ,OAAO,EAAE,MAAM,6CAA6C,CAAA;AAgFhF,UAAU,gBAAgB;IACtB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC7B,iEAAiE;IACjE,MAAM,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAA;IAClC,kIAAkI;IAClI,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAA;IACrC,uFAAuF;IACvF,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;CACxB;AAED,eAAO,MAAM,WAAW,GAAI,2DAKzB,gBAAgB,gCA+NlB,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
interface PaginationProps {
|
|
2
|
+
/** Total number of items across all pages */
|
|
3
|
+
total: number;
|
|
4
|
+
/** @default 5 */
|
|
5
|
+
pageSize?: number;
|
|
6
|
+
/** Current 1-based page. Out-of-range values are clamped for display. @default 1 */
|
|
7
|
+
page?: number;
|
|
8
|
+
/** Called with the requested 1-based page when Previous/Next is clicked */
|
|
9
|
+
onPageChange: (page: number) => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const Pagination: ({ total, pageSize, page, onPageChange, }: PaginationProps) => import('react').JSX.Element;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=Pagination.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Pagination.d.ts","sourceRoot":"","sources":["../../../src/react/components/Pagination.tsx"],"names":[],"mappings":"AAOA,UAAU,eAAe;IACrB,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAA;IACb,iBAAiB;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,oFAAoF;IACpF,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,2EAA2E;IAC3E,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;CACvC;AAED,eAAO,MAAM,UAAU,GAAI,0CAKxB,eAAe,gCAqCjB,CAAA"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
interface SigningProviderSelectProps {
|
|
2
|
+
/** The signing provider ids to choose from. `undefined` while they are loading, which disables the select */
|
|
3
|
+
signingProviders?: string[] | undefined;
|
|
4
|
+
/** The selected signing provider id, or '' when none is selected */
|
|
5
|
+
value: string;
|
|
6
|
+
onChange: (signingProviderId: string) => void;
|
|
7
|
+
/** Disables the select, e.g. while submitting @default false */
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
/** Providers that are listed but can't be chosen */
|
|
10
|
+
disabledProviders?: string[];
|
|
11
|
+
}
|
|
12
|
+
/** The signing provider field shared by the wallet create and edit forms */
|
|
13
|
+
export declare const SigningProviderSelect: ({ signingProviders, value, onChange, disabled, disabledProviders, }: SigningProviderSelectProps) => import('react').JSX.Element;
|
|
14
|
+
export {};
|
|
15
|
+
//# sourceMappingURL=SigningProviderSelect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SigningProviderSelect.d.ts","sourceRoot":"","sources":["../../../src/react/components/SigningProviderSelect.tsx"],"names":[],"mappings":"AAKA,UAAU,0BAA0B;IAChC,6GAA6G;IAC7G,gBAAgB,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACvC,oEAAoE;IACpE,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,iBAAiB,EAAE,MAAM,KAAK,IAAI,CAAA;IAC7C,gEAAgE;IAChE,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,oDAAoD;IACpD,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAA;CAC/B;AAED,4EAA4E;AAC5E,eAAO,MAAM,qBAAqB,GAAI,qEAMnC,0BAA0B,gCAuC5B,CAAA"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export type ToastMessageType = 'info' | 'success' | 'error';
|
|
2
|
+
interface ToastProps {
|
|
3
|
+
title: string;
|
|
4
|
+
message: string;
|
|
5
|
+
/** @default 'error' */
|
|
6
|
+
type?: ToastMessageType;
|
|
7
|
+
/** Accessible name of the dismiss button @default 'Dismiss notification' */
|
|
8
|
+
buttonText?: string;
|
|
9
|
+
/** How long the toast stays before dismissing itself, in ms */
|
|
10
|
+
autoHideDuration: number;
|
|
11
|
+
/** Called once the toast has been dismissed and finished its exit animation */
|
|
12
|
+
onExited?: () => void;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* A single toast. It is not positioned: it renders where it is placed, which
|
|
16
|
+
* lets `ToastProvider` stack several of them. Use `useToast()` to raise toasts
|
|
17
|
+
*/
|
|
18
|
+
export declare const Toast: ({ title, message, type, buttonText, autoHideDuration, onExited, }: ToastProps) => import('react').JSX.Element;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=Toast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../src/react/components/Toast.tsx"],"names":[],"mappings":"AAMA,MAAM,MAAM,gBAAgB,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,CAAA;AAE3D,UAAU,UAAU;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,uBAAuB;IACvB,IAAI,CAAC,EAAE,gBAAgB,CAAA;IACvB,4EAA4E;IAC5E,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,+DAA+D;IAC/D,gBAAgB,EAAE,MAAM,CAAA;IACxB,+EAA+E;IAC/E,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;CACxB;AAED;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,mEAOnB,UAAU,gCA4BZ,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ParsedTransactionInfo } from '@canton-network/core-tx-visualizer';
|
|
2
|
+
interface TransactionCardProps {
|
|
3
|
+
transactionId: string;
|
|
4
|
+
commandId: string;
|
|
5
|
+
externalTxId?: string | null;
|
|
6
|
+
/** e.g. 'pending', 'signed', 'executed', 'failed'. Shown as a coloured badge */
|
|
7
|
+
status: string;
|
|
8
|
+
parsed?: ParsedTransactionInfo | null;
|
|
9
|
+
createdAt?: string | null;
|
|
10
|
+
/** Disables the card, e.g. while the list is being refreshed */
|
|
11
|
+
loading?: boolean;
|
|
12
|
+
/** Called when the card is clicked */
|
|
13
|
+
onReview: (transactionId: string, commandId: string) => void;
|
|
14
|
+
}
|
|
15
|
+
export declare const TransactionCard: ({ transactionId, commandId, externalTxId, status, parsed, createdAt, loading, onReview, }: TransactionCardProps) => import('react').JSX.Element;
|
|
16
|
+
export {};
|
|
17
|
+
//# sourceMappingURL=TransactionCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionCard.d.ts","sourceRoot":"","sources":["../../../src/react/components/TransactionCard.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAA;AAW/E,UAAU,oBAAoB;IAC1B,aAAa,EAAE,MAAM,CAAA;IACrB,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,gFAAgF;IAChF,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,qBAAqB,GAAG,IAAI,CAAA;IACrC,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACzB,gEAAgE;IAChE,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,sCAAsC;IACtC,QAAQ,EAAE,CAAC,aAAa,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CAC/D;AAED,eAAO,MAAM,eAAe,GAAI,2FAS7B,oBAAoB,gCA2CtB,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ParsedTransactionInfo } from '@canton-network/core-tx-visualizer';
|
|
2
|
+
interface TransactionDetailProps {
|
|
3
|
+
commandId: string;
|
|
4
|
+
externalTxId?: string | null;
|
|
5
|
+
/** e.g. 'pending', 'signed', 'executed', 'failed'. Only pending and signed transactions can be acted on */
|
|
6
|
+
status: string;
|
|
7
|
+
txHash?: string;
|
|
8
|
+
parsed?: ParsedTransactionInfo | null;
|
|
9
|
+
createdAt?: string | null;
|
|
10
|
+
/** Shows a "Back" link to this URL. The link is hidden when omitted */
|
|
11
|
+
backHref?: string;
|
|
12
|
+
/** Shows progress on "Approve" and disables both buttons @default false */
|
|
13
|
+
approving?: boolean;
|
|
14
|
+
/** Shows progress on "Reject" and disables both buttons @default false */
|
|
15
|
+
rejecting?: boolean;
|
|
16
|
+
/** Shows progress on "Approve" and disables it. "Reject" stays available, so a transaction can still be turned down while it is signed @default false */
|
|
17
|
+
signing?: boolean;
|
|
18
|
+
/** The last submit of a signed transaction failed: "Approve" becomes "Retry submit" @default false */
|
|
19
|
+
submitFailed?: boolean;
|
|
20
|
+
/** Disables both buttons, whatever the status @default false */
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
/** Called when "Approve" (or "Retry submit") is clicked */
|
|
23
|
+
onApprove: (commandId: string) => void;
|
|
24
|
+
/** Called when "Reject" is clicked. The button is hidden when omitted */
|
|
25
|
+
onReject?: (commandId: string) => void;
|
|
26
|
+
}
|
|
27
|
+
export declare const TransactionDetail: ({ commandId, externalTxId, status, txHash, parsed, createdAt, backHref, approving, rejecting, signing, submitFailed, disabled, onApprove, onReject, }: TransactionDetailProps) => import('react').JSX.Element;
|
|
28
|
+
export {};
|
|
29
|
+
//# sourceMappingURL=TransactionDetail.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionDetail.d.ts","sourceRoot":"","sources":["../../../src/react/components/TransactionDetail.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAA;AA+B/E,UAAU,sBAAsB;IAC5B,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,2GAA2G;IAC3G,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,CAAC,EAAE,qBAAqB,GAAG,IAAI,CAAA;IACrC,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACzB,uEAAuE;IACvE,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,2EAA2E;IAC3E,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,0EAA0E;IAC1E,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,yJAAyJ;IACzJ,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,sGAAsG;IACtG,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gEAAgE;IAChE,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,2DAA2D;IAC3D,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IACtC,yEAAyE;IACzE,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CACzC;AAED,eAAO,MAAM,iBAAiB,GAAI,uJAe/B,sBAAsB,gCAuKxB,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Wallet } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface WalletCardProps {
|
|
3
|
+
wallet: Wallet;
|
|
4
|
+
/** Whether the party has been allocated. Unverified wallets offer "Allocate party" instead of "Set as primary" and "Edit" */
|
|
5
|
+
verified?: boolean;
|
|
6
|
+
/** Disables the action buttons, e.g. while a request is in flight */
|
|
7
|
+
loading?: boolean;
|
|
8
|
+
/** Called when "Allocate party" is clicked (unverified wallets). The button is hidden when omitted */
|
|
9
|
+
onAllocate?: (wallet: Wallet) => void;
|
|
10
|
+
/** Called when "Set as primary" is clicked (verified, non-primary, enabled wallets). The button is hidden when omitted */
|
|
11
|
+
onSetPrimary?: (wallet: Wallet) => void;
|
|
12
|
+
/** Called when "Edit" is clicked (verified wallets). The button is hidden when omitted */
|
|
13
|
+
onEdit?: (wallet: Wallet) => void;
|
|
14
|
+
/** Called when the select button is clicked. When set, it replaces all other actions and the badge */
|
|
15
|
+
onSelect?: (wallet: Wallet) => void;
|
|
16
|
+
/** Label of the select button @default 'Select' */
|
|
17
|
+
selectLabel?: string;
|
|
18
|
+
}
|
|
19
|
+
export declare const WalletCard: ({ wallet, verified, loading, onAllocate, onSetPrimary, onEdit, onSelect, selectLabel, }: WalletCardProps) => import('react').JSX.Element;
|
|
20
|
+
export {};
|
|
21
|
+
//# sourceMappingURL=WalletCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WalletCard.d.ts","sourceRoot":"","sources":["../../../src/react/components/WalletCard.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6CAA6C,CAAA;AAoCzE,UAAU,eAAe;IACrB,MAAM,EAAE,MAAM,CAAA;IACd,6HAA6H;IAC7H,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,qEAAqE;IACrE,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,sGAAsG;IACtG,UAAU,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,0HAA0H;IAC1H,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;IACvC,0FAA0F;IAC1F,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;IACjC,sGAAsG;IACtG,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;IACnC,mDAAmD;IACnD,WAAW,CAAC,EAAE,MAAM,CAAA;CACvB;AAED,eAAO,MAAM,UAAU,GAAI,yFASxB,eAAe,gCAmJjB,CAAA"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Key, KeyName, PartyHint, SigningProviderId } from '@canton-network/core-wallet-user-rpc-client';
|
|
2
|
+
interface WalletCreateFormProps {
|
|
3
|
+
/** The signing provider ids to choose from. `undefined` while they are loading, which disables the form */
|
|
4
|
+
signingProviders?: string[] | undefined;
|
|
5
|
+
/** Signing providers whose wallets are created with one of `publicKeys`, chosen in a "Vault name" select @default [] */
|
|
6
|
+
keySigningProviders?: string[];
|
|
7
|
+
/**
|
|
8
|
+
* The keys offered for `keySigningProviders`: load them when
|
|
9
|
+
* `onSigningProviderChange` reports such a provider. `undefined` while they
|
|
10
|
+
* are loading, which disables the form once one of those providers is selected
|
|
11
|
+
*/
|
|
12
|
+
publicKeys?: Key[] | undefined;
|
|
13
|
+
/** The selected signing provider. Pass it, together with `onSigningProviderChange`, to control the selection; without it the form keeps its own */
|
|
14
|
+
selectedSigningProvider?: string;
|
|
15
|
+
/** Offers the "Set as primary wallet" checkbox @default true */
|
|
16
|
+
showPrimary?: boolean;
|
|
17
|
+
/** Disables the form and shows `submittingLabel` and `submittingMessage` @default false */
|
|
18
|
+
submitting?: boolean;
|
|
19
|
+
/** @default 'Add' */
|
|
20
|
+
submitLabel?: string;
|
|
21
|
+
/** @default 'Adding...' */
|
|
22
|
+
submittingLabel?: string;
|
|
23
|
+
/** @default 'Creating party, please wait...' */
|
|
24
|
+
submittingMessage?: string;
|
|
25
|
+
/**
|
|
26
|
+
* Called when the form is submitted. `keyName` is the name of the chosen
|
|
27
|
+
* key, for the signing providers that have keys
|
|
28
|
+
*/
|
|
29
|
+
onCreate: (partyHint: PartyHint, signingProviderId: SigningProviderId, primary: boolean, keyName?: KeyName) => void;
|
|
30
|
+
/** Called when another signing provider is chosen */
|
|
31
|
+
onSigningProviderChange?: (signingProviderId: SigningProviderId) => void;
|
|
32
|
+
}
|
|
33
|
+
export declare const WalletCreateForm: ({ signingProviders, keySigningProviders, publicKeys, selectedSigningProvider, showPrimary, submitting, submitLabel, submittingLabel, submittingMessage, onCreate, onSigningProviderChange, }: WalletCreateFormProps) => import('react').JSX.Element;
|
|
34
|
+
export {};
|
|
35
|
+
//# sourceMappingURL=WalletCreateForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WalletCreateForm.d.ts","sourceRoot":"","sources":["../../../src/react/components/WalletCreateForm.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACR,GAAG,EACH,OAAO,EACP,SAAS,EACT,iBAAiB,EACpB,MAAM,6CAA6C,CAAA;AAKpD,UAAU,qBAAqB;IAC3B,2GAA2G;IAC3G,gBAAgB,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACvC,wHAAwH;IACxH,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC9B;;;;OAIG;IACH,UAAU,CAAC,EAAE,GAAG,EAAE,GAAG,SAAS,CAAA;IAC9B,mJAAmJ;IACnJ,uBAAuB,CAAC,EAAE,MAAM,CAAA;IAChC,gEAAgE;IAChE,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,2FAA2F;IAC3F,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,qBAAqB;IACrB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,2BAA2B;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,gDAAgD;IAChD,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B;;;OAGG;IACH,QAAQ,EAAE,CACN,SAAS,EAAE,SAAS,EACpB,iBAAiB,EAAE,iBAAiB,EACpC,OAAO,EAAE,OAAO,EAChB,OAAO,CAAC,EAAE,OAAO,KAChB,IAAI,CAAA;IACT,qDAAqD;IACrD,uBAAuB,CAAC,EAAE,CAAC,iBAAiB,EAAE,iBAAiB,KAAK,IAAI,CAAA;CAC3E;AAED,eAAO,MAAM,gBAAgB,GAAI,8LAY9B,qBAAqB,gCA4GvB,CAAA"}
|