@tuwaio/nova-connect 0.1.10 → 0.2.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.
Files changed (106) hide show
  1. package/README.md +5 -15
  2. package/dist/{ToastError-CaoiEVOK.d.cts → ToastError-C3LvnSma.d.cts} +322 -113
  3. package/dist/{ToastError-BLFMIzVb.d.ts → ToastError-CVhCoryf.d.ts} +322 -113
  4. package/dist/chunk-3BMX6JWH.js +2 -0
  5. package/dist/chunk-3BMX6JWH.js.map +1 -0
  6. package/dist/chunk-4FB4UCVM.js +6 -0
  7. package/dist/chunk-4FB4UCVM.js.map +1 -0
  8. package/dist/chunk-B2NRY4JV.js +2 -0
  9. package/dist/chunk-B2NRY4JV.js.map +1 -0
  10. package/dist/chunk-F2VSTHQ4.js +2 -0
  11. package/dist/chunk-F2VSTHQ4.js.map +1 -0
  12. package/dist/{chunk-OA6MB7CZ.cjs → chunk-FK4AEST5.cjs} +2 -2
  13. package/dist/{chunk-OA6MB7CZ.cjs.map → chunk-FK4AEST5.cjs.map} +1 -1
  14. package/dist/chunk-IMKRWFCZ.cjs +3 -0
  15. package/dist/chunk-IMKRWFCZ.cjs.map +1 -0
  16. package/dist/chunk-L5MEEHVK.cjs +2 -0
  17. package/dist/chunk-L5MEEHVK.cjs.map +1 -0
  18. package/dist/chunk-P5ZBSLGK.js +2 -0
  19. package/dist/{chunk-MPEJHQKC.js.map → chunk-P5ZBSLGK.js.map} +1 -1
  20. package/dist/chunk-PTHXIVB5.cjs +2 -0
  21. package/dist/chunk-PTHXIVB5.cjs.map +1 -0
  22. package/dist/chunk-S6WXKVYP.js +3 -0
  23. package/dist/chunk-S6WXKVYP.js.map +1 -0
  24. package/dist/chunk-UDTWMOQ2.cjs +6 -0
  25. package/dist/chunk-UDTWMOQ2.cjs.map +1 -0
  26. package/dist/chunk-YI7RYSN6.cjs +2 -0
  27. package/dist/chunk-YI7RYSN6.cjs.map +1 -0
  28. package/dist/components/index.cjs +1 -1
  29. package/dist/components/index.d.cts +3 -3
  30. package/dist/components/index.d.ts +3 -3
  31. package/dist/components/index.js +1 -1
  32. package/dist/evm-BVE2G4MP.js +2 -0
  33. package/dist/evm-BVE2G4MP.js.map +1 -0
  34. package/dist/evm-DU3VGIPD.cjs +2 -0
  35. package/dist/evm-DU3VGIPD.cjs.map +1 -0
  36. package/dist/getChainsListByConnectorType-7W3NDNRC.cjs +2 -0
  37. package/dist/{getChainsListByWalletType-VMQ4BO2B.js.map → getChainsListByConnectorType-7W3NDNRC.cjs.map} +1 -1
  38. package/dist/getChainsListByConnectorType-FGTS3CWJ.js +2 -0
  39. package/dist/{getChainsListByWalletType-CDPECVNS.cjs.map → getChainsListByConnectorType-FGTS3CWJ.js.map} +1 -1
  40. package/dist/hooks/index.cjs +1 -1
  41. package/dist/hooks/index.d.cts +23 -4
  42. package/dist/hooks/index.d.ts +23 -4
  43. package/dist/hooks/index.js +1 -1
  44. package/dist/i18n/index.cjs +1 -1
  45. package/dist/i18n/index.d.cts +1 -1
  46. package/dist/i18n/index.d.ts +1 -1
  47. package/dist/i18n/index.js +1 -1
  48. package/dist/index.cjs +1 -1
  49. package/dist/index.cjs.map +1 -1
  50. package/dist/index.css +112 -8
  51. package/dist/index.d.cts +23 -23
  52. package/dist/index.d.ts +23 -23
  53. package/dist/index.js +1 -1
  54. package/dist/index.js.map +1 -1
  55. package/dist/satellite/index.cjs +1 -1
  56. package/dist/satellite/index.d.cts +1 -1
  57. package/dist/satellite/index.d.ts +1 -1
  58. package/dist/satellite/index.js +1 -1
  59. package/dist/solana/index.cjs +1 -1
  60. package/dist/solana/index.js +1 -1
  61. package/dist/solana-CDGGMN74.cjs +2 -0
  62. package/dist/solana-CDGGMN74.cjs.map +1 -0
  63. package/dist/solana-DHXEV2TG.js +2 -0
  64. package/dist/solana-DHXEV2TG.js.map +1 -0
  65. package/dist/{types-D4Vti05g.d.cts → types-eao2UQcC.d.cts} +7 -1
  66. package/dist/{types-D4Vti05g.d.ts → types-eao2UQcC.d.ts} +7 -1
  67. package/dist/{useWalletNativeBalance-CEASeZ6Z.d.ts → useWalletNativeBalance-Cv8QQLQv.d.ts} +2 -2
  68. package/dist/{useWalletNativeBalance-DSt1VUWC.d.cts → useWalletNativeBalance-D49yGzRi.d.cts} +2 -2
  69. package/dist/utils-TF3RVHPT.cjs +2 -0
  70. package/dist/{utils-H5O25MTI.cjs.map → utils-TF3RVHPT.cjs.map} +1 -1
  71. package/dist/utils-YYMTL3XH.js +2 -0
  72. package/dist/{utils-SUIRQJIA.js.map → utils-YYMTL3XH.js.map} +1 -1
  73. package/package.json +38 -43
  74. package/dist/chunk-7F5QM2LC.js +0 -6
  75. package/dist/chunk-7F5QM2LC.js.map +0 -1
  76. package/dist/chunk-7FTV55DQ.cjs +0 -2
  77. package/dist/chunk-7FTV55DQ.cjs.map +0 -1
  78. package/dist/chunk-B26D6OI7.cjs +0 -6
  79. package/dist/chunk-B26D6OI7.cjs.map +0 -1
  80. package/dist/chunk-DYDY3FCT.cjs +0 -2
  81. package/dist/chunk-DYDY3FCT.cjs.map +0 -1
  82. package/dist/chunk-J4TY3CJF.js +0 -2
  83. package/dist/chunk-J4TY3CJF.js.map +0 -1
  84. package/dist/chunk-MPEJHQKC.js +0 -2
  85. package/dist/chunk-MQGDTFY7.js +0 -2
  86. package/dist/chunk-MQGDTFY7.js.map +0 -1
  87. package/dist/chunk-NMQZA377.cjs +0 -2
  88. package/dist/chunk-NMQZA377.cjs.map +0 -1
  89. package/dist/chunk-QERPNHKX.cjs +0 -2
  90. package/dist/chunk-QERPNHKX.cjs.map +0 -1
  91. package/dist/chunk-S5WT3DLF.js +0 -2
  92. package/dist/chunk-S5WT3DLF.js.map +0 -1
  93. package/dist/chunk-TAV7EL23.js +0 -2
  94. package/dist/chunk-TAV7EL23.js.map +0 -1
  95. package/dist/evm-7NHOTSAK.cjs +0 -2
  96. package/dist/evm-7NHOTSAK.cjs.map +0 -1
  97. package/dist/evm-RBGEX4L3.js +0 -2
  98. package/dist/evm-RBGEX4L3.js.map +0 -1
  99. package/dist/getChainsListByWalletType-CDPECVNS.cjs +0 -2
  100. package/dist/getChainsListByWalletType-VMQ4BO2B.js +0 -2
  101. package/dist/solana-GLHHYZDQ.js +0 -2
  102. package/dist/solana-GLHHYZDQ.js.map +0 -1
  103. package/dist/solana-JUU54KQ3.cjs +0 -2
  104. package/dist/solana-JUU54KQ3.cjs.map +0 -1
  105. package/dist/utils-H5O25MTI.cjs +0 -2
  106. package/dist/utils-SUIRQJIA.js +0 -2
@@ -2,13 +2,13 @@ import { Dialog, DialogContent, StarsBackground } from '@tuwaio/nova-core';
2
2
  import { TargetAndTransition, VariantLabels, LegacyAnimationControls, Transition, AnyResolvedKeyframe, HTMLMotionProps, Variants, Easing, motion } from 'framer-motion';
3
3
  import * as React$1 from 'react';
4
4
  import React__default, { ComponentType, ReactNode, ComponentPropsWithoutRef } from 'react';
5
- import { B as ButtonTxStatus, b as NovaConnectProviderProps, h as useNovaConnectLabels, p as NativeBalanceResult, C as ConnectContentType } from './useWalletNativeBalance-DSt1VUWC.cjs';
6
- import { BaseWallet } from '@tuwaio/satellite-core';
5
+ import { B as ButtonTxStatus, b as NovaConnectProviderProps, h as useNovaConnectLabels, p as NativeBalanceResult, a as ConnectedContentType, C as ConnectContentType } from './useWalletNativeBalance-D49yGzRi.cjs';
6
+ import { BaseConnector } from '@tuwaio/satellite-core';
7
7
  import * as react_jsx_runtime from 'react/jsx-runtime';
8
8
  import * as Select from '@radix-ui/react-select';
9
9
  import { I as InitialChains } from './types-DGsiEwne.cjs';
10
10
  import { Transaction } from '@tuwaio/pulsar-core';
11
- import { OrbitAdapter, WalletType } from '@tuwaio/orbit-core';
11
+ import { ConnectorType, OrbitAdapter, RecentlyConnectedConnectorData } from '@tuwaio/orbit-core';
12
12
  import { Connector } from '@tuwaio/satellite-react';
13
13
 
14
14
  /**
@@ -609,15 +609,6 @@ type CustomTriggerArrowProps = {
609
609
  /** Whether hidden from screen readers */
610
610
  'aria-hidden'?: boolean;
611
611
  };
612
- /**
613
- * Props for a custom loading state display.
614
- */
615
- type CustomLoadingStateProps = {
616
- /** CSS class */
617
- className?: string;
618
- /** ARIA label */
619
- 'aria-label': string;
620
- };
621
612
  /**
622
613
  * Props for a custom display for a single chain (when no selector is needed).
623
614
  */
@@ -743,8 +734,6 @@ type ChainTriggerButtonCustomization = {
743
734
  type ChainSelectorCustomization = {
744
735
  /** Custom component overrides */
745
736
  components?: {
746
- /** Custom loading state component */
747
- LoadingState?: ComponentType<CustomLoadingStateProps>;
748
737
  /** Custom component for displaying a single chain */
749
738
  SingleChainDisplay?: ComponentType<CustomSingleChainDisplayProps>;
750
739
  /** Custom wrapper for the desktop selector */
@@ -1459,7 +1448,7 @@ interface ConnectButtonData {
1459
1448
  /** Current labels from i18n */
1460
1449
  labels: ReturnType<typeof useNovaConnectLabels>;
1461
1450
  /** Active wallet information */
1462
- activeWallet: BaseWallet | undefined;
1451
+ activeConnection: BaseConnector | undefined;
1463
1452
  }
1464
1453
  type NavigationProps$1 = {
1465
1454
  className?: string;
@@ -1621,6 +1610,7 @@ type CustomDisconnectButtonProps = {
1621
1610
  'data-testid'?: string;
1622
1611
  'aria-describedby'?: string;
1623
1612
  disabled?: boolean;
1613
+ connectionsCount: number;
1624
1614
  };
1625
1615
  type CustomExplorerLinkProps = {
1626
1616
  href: string;
@@ -1910,14 +1900,14 @@ declare const ConnectedModalFooter: React$1.ForwardRefExoticComponent<ConnectedM
1910
1900
 
1911
1901
  type WalletNameDisplayProps = {
1912
1902
  ensNameAbbreviated?: string;
1913
- activeWallet: BaseWallet;
1903
+ activeConnection: BaseConnector;
1914
1904
  labels: Record<string, string>;
1915
1905
  className?: string;
1916
1906
  };
1917
1907
  type CopyButtonProps = {
1918
1908
  isCopied: boolean;
1919
1909
  onCopy: () => Promise<void>;
1920
- activeWallet: BaseWallet;
1910
+ activeConnection: BaseConnector;
1921
1911
  labels: Record<string, string>;
1922
1912
  className?: string;
1923
1913
  disabled?: boolean;
@@ -1925,12 +1915,13 @@ type CopyButtonProps = {
1925
1915
  type BalanceDisplayProps = {
1926
1916
  balance?: ConnectedModalMainContentProps['balance'];
1927
1917
  balanceLoading: boolean;
1918
+ refetch: () => void;
1928
1919
  labels: Record<string, string>;
1929
1920
  className?: string;
1930
1921
  };
1931
1922
  type ScreenReaderFeedbackProps = {
1932
1923
  isCopied: boolean;
1933
- activeWallet: BaseWallet;
1924
+ activeConnection: BaseConnector;
1934
1925
  labels: Record<string, string>;
1935
1926
  className?: string;
1936
1927
  };
@@ -2079,6 +2070,8 @@ type ConnectedModalNameAndBalanceCustomization = {
2079
2070
  * Props for the ConnectedModalNameAndBalance component
2080
2071
  */
2081
2072
  interface ConnectedModalNameAndBalanceProps extends Pick<ConnectedModalMainContentProps, 'balanceLoading' | 'ensNameAbbreviated' | 'balance'> {
2073
+ /** Function to manually trigger a balance refresh */
2074
+ refetch: () => void;
2082
2075
  /** Additional CSS classes for the container */
2083
2076
  className?: string;
2084
2077
  /** Custom aria-label for the container */
@@ -2109,6 +2102,7 @@ interface ConnectedModalNameAndBalanceProps extends Pick<ConnectedModalMainConte
2109
2102
  * ensNameAbbreviated="wallet.eth"
2110
2103
  * balanceLoading={false}
2111
2104
  * balance={{ value: "1.23", symbol: "ETH" }}
2105
+ * refetch={() => {}}
2112
2106
  * />
2113
2107
  * ```
2114
2108
  *
@@ -2118,6 +2112,7 @@ interface ConnectedModalNameAndBalanceProps extends Pick<ConnectedModalMainConte
2118
2112
  * ensNameAbbreviated="wallet.eth"
2119
2113
  * balanceLoading={false}
2120
2114
  * balance={{ value: "1.23", symbol: "ETH" }}
2115
+ * refetch={() => {}}
2121
2116
  * customization={{
2122
2117
  * classNames: {
2123
2118
  * container: ({ hasActiveWallet }) =>
@@ -2493,7 +2488,7 @@ type LoadingIndicatorProps = {
2493
2488
  className?: string;
2494
2489
  };
2495
2490
  type AvatarSectionProps = {
2496
- activeWallet: BaseWallet;
2491
+ activeConnection: BaseConnector;
2497
2492
  ensAvatar: string | null;
2498
2493
  walletName: string;
2499
2494
  connectorsCount: number;
@@ -2506,6 +2501,7 @@ type AvatarSectionProps = {
2506
2501
  type InfoSectionProps = {
2507
2502
  balanceLoading: boolean;
2508
2503
  balance: NativeBalanceResult | null;
2504
+ refetch: () => void;
2509
2505
  ensNameAbbreviated: string | undefined;
2510
2506
  labels: Record<string, string>;
2511
2507
  className?: string;
@@ -2694,6 +2690,7 @@ interface ConnectedModalMainContentProps extends Pick<NovaConnectProviderProps,
2694
2690
  balanceLoading: boolean;
2695
2691
  ensNameAbbreviated: string | undefined;
2696
2692
  balance: NativeBalanceResult | null;
2693
+ refetch: () => void;
2697
2694
  /** Additional CSS classes for the container */
2698
2695
  className?: string;
2699
2696
  /** Custom aria-label for the container */
@@ -2755,8 +2752,8 @@ interface ConnectedModalMainContentProps extends Pick<NovaConnectProviderProps,
2755
2752
  * components: {
2756
2753
  * LoadingIndicator: ({ isLoading }) =>
2757
2754
  * isLoading ? <div className="custom-spinner" /> : null,
2758
- * AvatarSection: ({ activeWallet, onSwitchWallet }) => (
2759
- * <div onClick={onSwitchWallet}>Custom Avatar: {activeWallet.address}</div>
2755
+ * AvatarSection: ({ activeConnection, onSwitchWallet }) => (
2756
+ * <div onClick={onSwitchWallet}>Custom Avatar: {activeConnection.address}</div>
2760
2757
  * ),
2761
2758
  * },
2762
2759
  * childCustomizations: {
@@ -2808,7 +2805,7 @@ type CustomNoWalletContainerProps = {
2808
2805
  };
2809
2806
  type CustomTransactionsHistoryWrapperProps = {
2810
2807
  children: ReactNode;
2811
- activeWalletAddress: string;
2808
+ activeConnectionAddress: string;
2812
2809
  transactionPool: NonNullable<NovaConnectProviderProps['transactionPool']>;
2813
2810
  pulsarAdapter: NonNullable<NovaConnectProviderProps['pulsarAdapter']>;
2814
2811
  labels: Record<string, string>;
@@ -3013,13 +3010,290 @@ interface ConnectedModalTxHistoryProps extends Pick<NovaConnectProviderProps, 't
3013
3010
  */
3014
3011
  declare const ConnectedModalTxHistory: React__default.ForwardRefExoticComponent<ConnectedModalTxHistoryProps & React__default.RefAttributes<HTMLDivElement>>;
3015
3012
 
3013
+ /**
3014
+ * @file ConnectionsContent component for managing multiple wallet connections.
3015
+ */
3016
+
3017
+ type CustomContainerProps = {
3018
+ className?: string;
3019
+ children: ReactNode;
3020
+ isEmpty?: boolean;
3021
+ connectionsCount?: number;
3022
+ recentCount?: number;
3023
+ role?: string;
3024
+ 'aria-label'?: string;
3025
+ 'data-testid'?: string;
3026
+ };
3027
+ type CustomSectionHeaderProps = {
3028
+ title: string;
3029
+ count?: number;
3030
+ className?: string;
3031
+ 'aria-level'?: number;
3032
+ };
3033
+ type CustomActiveSectionProps = {
3034
+ className?: string;
3035
+ children: ReactNode;
3036
+ count: number;
3037
+ labels?: Record<string, string>;
3038
+ };
3039
+ type CustomRecentSectionProps = {
3040
+ className?: string;
3041
+ children: ReactNode;
3042
+ labels?: Record<string, string>;
3043
+ };
3044
+ type CustomActiveRowProps = {
3045
+ connectorType: ConnectorType;
3046
+ address: string;
3047
+ fullAddress?: string;
3048
+ chainId?: number | string;
3049
+ onDisconnect: (e: React.MouseEvent) => void;
3050
+ className?: string;
3051
+ explorerLink?: string;
3052
+ icon?: string;
3053
+ labels?: Record<string, string>;
3054
+ isCopied?: boolean;
3055
+ onCopy?: () => void;
3056
+ onExplorer?: () => void;
3057
+ };
3058
+ type CustomConnectedRowProps = {
3059
+ connectorType: ConnectorType;
3060
+ address: string;
3061
+ chainId?: number | string;
3062
+ onSwitch: () => void;
3063
+ onDisconnect: (e: React.MouseEvent) => void;
3064
+ className?: string;
3065
+ icon?: string;
3066
+ labels?: Record<string, string>;
3067
+ isHovered?: boolean;
3068
+ };
3069
+ type CustomRecentRowProps = {
3070
+ connectorType: ConnectorType;
3071
+ address: string;
3072
+ timestamp: number;
3073
+ onConnect?: () => void;
3074
+ onRemove: (e: React.MouseEvent) => void;
3075
+ className?: string;
3076
+ icon?: string;
3077
+ isConnecting?: boolean;
3078
+ labels?: Record<string, string>;
3079
+ };
3080
+ type CustomActionButtonProps = {
3081
+ onClick: (e: React.MouseEvent) => void;
3082
+ label: string;
3083
+ icon?: ReactNode;
3084
+ disabled?: boolean;
3085
+ loading?: boolean;
3086
+ className?: string;
3087
+ 'aria-label'?: string;
3088
+ 'aria-describedby'?: string;
3089
+ variant?: 'primary' | 'secondary' | 'danger';
3090
+ };
3091
+ type CustomAddWalletButtonProps = {
3092
+ onClick: () => void;
3093
+ label: string;
3094
+ className?: string;
3095
+ disabled?: boolean;
3096
+ };
3097
+ type CustomEmptyStateProps = {
3098
+ message: string;
3099
+ className?: string;
3100
+ };
3101
+ /**
3102
+ * Customization options for ConnectionsContent component
3103
+ */
3104
+ type ConnectionsContentCustomization = {
3105
+ /** Override container element props */
3106
+ containerProps?: Partial<ComponentPropsWithoutRef<'div'>>;
3107
+ /** Custom components */
3108
+ components?: {
3109
+ /** Custom container component */
3110
+ Container?: ComponentType<CustomContainerProps>;
3111
+ /** Custom section header component */
3112
+ SectionHeader?: ComponentType<CustomSectionHeaderProps>;
3113
+ /** Custom active connectors section */
3114
+ ActiveConnectorsSection?: ComponentType<CustomActiveSectionProps>;
3115
+ /** Custom recently connected section */
3116
+ RecentlyConnectedSection?: ComponentType<CustomRecentSectionProps>;
3117
+ /** Custom active connector row */
3118
+ ActiveConnectorRow?: ComponentType<CustomActiveRowProps>;
3119
+ /** Custom connected connector row */
3120
+ ConnectedConnectorRow?: ComponentType<CustomConnectedRowProps>;
3121
+ /** Custom recently connected row */
3122
+ RecentlyConnectedRow?: ComponentType<CustomRecentRowProps>;
3123
+ /** Custom action button */
3124
+ ActionButton?: ComponentType<CustomActionButtonProps>;
3125
+ /** Custom add wallet button */
3126
+ AddWalletButton?: ComponentType<CustomAddWalletButtonProps>;
3127
+ /** Custom empty state */
3128
+ EmptyState?: ComponentType<CustomEmptyStateProps>;
3129
+ };
3130
+ /** Custom class name generators */
3131
+ classNames?: {
3132
+ /** Function to generate container classes */
3133
+ container?: (params: {
3134
+ isEmpty: boolean;
3135
+ connectionsCount: number;
3136
+ recentCount: number;
3137
+ }) => string;
3138
+ /** Function to generate section header classes */
3139
+ sectionHeader?: (params: {
3140
+ sectionType: 'active' | 'recent';
3141
+ }) => string;
3142
+ /** Function to generate active section classes */
3143
+ activeSection?: (params: {
3144
+ count: number;
3145
+ }) => string;
3146
+ /** Function to generate recent section classes */
3147
+ recentSection?: (params: {
3148
+ count: number;
3149
+ }) => string;
3150
+ /** Function to generate active row classes */
3151
+ activeRow?: (params: {
3152
+ connectorType: ConnectorType;
3153
+ hasExplorer: boolean;
3154
+ }) => string;
3155
+ /** Function to generate connected row classes */
3156
+ connectedRow?: (params: {
3157
+ connectorType: ConnectorType;
3158
+ isHovered: boolean;
3159
+ }) => string;
3160
+ /** Function to generate recent row classes */
3161
+ recentRow?: (params: {
3162
+ connectorType: ConnectorType;
3163
+ isConnecting: boolean;
3164
+ }) => string;
3165
+ /** Function to generate action button classes */
3166
+ actionButton?: (params: {
3167
+ variant?: 'primary' | 'secondary' | 'danger';
3168
+ disabled?: boolean;
3169
+ loading?: boolean;
3170
+ }) => string;
3171
+ /** Function to generate add wallet button classes */
3172
+ addWalletButton?: (params: {
3173
+ disabled?: boolean;
3174
+ }) => string;
3175
+ /** Function to generate empty state classes */
3176
+ emptyState?: () => string;
3177
+ };
3178
+ /** Custom event handlers */
3179
+ handlers?: {
3180
+ /** Custom handler before switching connection */
3181
+ onBeforeSwitch?: (connectorType: ConnectorType) => boolean | Promise<boolean>;
3182
+ /** Custom handler after switching connection */
3183
+ onAfterSwitch?: (connectorType: ConnectorType) => void;
3184
+ /** Custom handler when switch fails */
3185
+ onSwitchError?: (connectorType: ConnectorType, error: Error) => void;
3186
+ /** Custom handler before disconnect */
3187
+ onBeforeDisconnect?: (connectorType: ConnectorType) => boolean | Promise<boolean>;
3188
+ /** Custom handler after disconnect */
3189
+ onAfterDisconnect?: (connectorType: ConnectorType) => void;
3190
+ /** Custom handler when disconnect fails */
3191
+ onDisconnectError?: (connectorType: ConnectorType, error: Error) => void;
3192
+ /** Custom handler before connecting recent */
3193
+ onBeforeConnect?: (connectorType: ConnectorType) => boolean | Promise<boolean>;
3194
+ /** Custom handler after connecting recent */
3195
+ onAfterConnect?: (connectorType: ConnectorType) => void;
3196
+ /** Custom handler when connect fails */
3197
+ onConnectError?: (connectorType: ConnectorType, error: Error) => void;
3198
+ /** Custom handler before removing recent */
3199
+ onBeforeRemove?: (connectorType: ConnectorType) => boolean | Promise<boolean>;
3200
+ /** Custom handler after removing recent */
3201
+ onAfterRemove?: (connectorType: ConnectorType) => void;
3202
+ /** Custom handler for copy address */
3203
+ onCopyAddress?: (address: string, connectorType: ConnectorType) => void;
3204
+ /** Custom handler for explorer click */
3205
+ onExplorerClick?: (url: string, address: string, connectorType: ConnectorType) => void;
3206
+ /** Custom handler for add wallet click */
3207
+ onAddWalletClick?: () => void;
3208
+ };
3209
+ /** Custom text and ARIA labels */
3210
+ labels?: {
3211
+ /** Custom empty state message */
3212
+ emptyStateMessage?: string;
3213
+ /** Custom active section title */
3214
+ activeSectionTitle?: string;
3215
+ /** Custom recent section title */
3216
+ recentSectionTitle?: string;
3217
+ /** Custom disconnect button label */
3218
+ disconnectLabel?: string;
3219
+ /** Custom switch button label */
3220
+ switchLabel?: string;
3221
+ /** Custom connect button label */
3222
+ connectLabel?: string;
3223
+ /** Custom remove button label */
3224
+ removeLabel?: string;
3225
+ /** Custom copy button label */
3226
+ copyLabel?: string;
3227
+ /** Custom copied success label */
3228
+ copiedLabel?: string;
3229
+ /** Custom explorer button label */
3230
+ explorerLabel?: string;
3231
+ /** Custom add wallet button label */
3232
+ addWalletLabel?: string;
3233
+ /** Custom ARIA label for container */
3234
+ containerAriaLabel?: string;
3235
+ /** Custom ARIA label for active section */
3236
+ activeSectionAriaLabel?: string;
3237
+ /** Custom ARIA label for recent section */
3238
+ recentSectionAriaLabel?: string;
3239
+ /** Custom ARIA description for switch action */
3240
+ switchAriaDescription?: string;
3241
+ /** Custom ARIA description for disconnect action */
3242
+ disconnectAriaDescription?: string;
3243
+ /** Custom ARIA description for connect action */
3244
+ connectAriaDescription?: string;
3245
+ /** Custom ARIA description for remove action */
3246
+ removeAriaDescription?: string;
3247
+ /** Custom ARIA live region announcement for switch */
3248
+ switchAnnouncement?: (walletName: string) => string;
3249
+ /** Custom ARIA live region announcement for disconnect */
3250
+ disconnectAnnouncement?: (walletName: string) => string;
3251
+ /** Custom ARIA live region announcement for connect */
3252
+ connectAnnouncement?: (walletName: string) => string;
3253
+ };
3254
+ /** Configuration options */
3255
+ config?: {
3256
+ /** Whether to disable animations */
3257
+ disableAnimation?: boolean;
3258
+ /** Whether to reduce motion for accessibility */
3259
+ reduceMotion?: boolean;
3260
+ /** Whether to show empty state */
3261
+ showEmptyState?: boolean;
3262
+ /** Whether to show add wallet button */
3263
+ showAddWalletButton?: boolean;
3264
+ /** Whether to show recently connected section */
3265
+ showRecentSection?: boolean;
3266
+ /** Whether to enable keyboard shortcuts */
3267
+ enableKeyboardShortcuts?: boolean;
3268
+ /** Custom keyboard shortcuts map */
3269
+ keyboardShortcuts?: {
3270
+ /** Key for switching to next connection */
3271
+ nextConnection?: string;
3272
+ /** Key for switching to previous connection */
3273
+ prevConnection?: string;
3274
+ /** Key for disconnecting active wallet */
3275
+ disconnect?: string;
3276
+ };
3277
+ /** Maximum recent connections to show */
3278
+ maxRecentConnections?: number;
3279
+ /** Whether to auto-focus first interactive element */
3280
+ autoFocus?: boolean;
3281
+ /** Custom test IDs */
3282
+ testIds?: {
3283
+ container?: string;
3284
+ activeSection?: string;
3285
+ recentSection?: string;
3286
+ addWalletButton?: string;
3287
+ };
3288
+ };
3289
+ };
3290
+
3016
3291
  /**
3017
3292
  * @file ConnectedModal component with comprehensive customization options for all child components.
3018
3293
  */
3019
3294
 
3020
- type ConnectedModalContentType = 'main' | 'transactions' | 'chains';
3021
3295
  type HeaderProps = {
3022
- contentType: ConnectedModalContentType;
3296
+ contentType: ConnectedContentType;
3023
3297
  title: string;
3024
3298
  onBack: () => void;
3025
3299
  onClose: () => void;
@@ -3041,8 +3315,9 @@ type CloseButtonProps$1 = {
3041
3315
  className?: string;
3042
3316
  };
3043
3317
  type MainContentProps$1 = Pick<NovaConnectProviderProps, 'transactionPool' | 'pulsarAdapter'> & {
3044
- contentType: ConnectedModalContentType;
3318
+ contentType: ConnectedContentType;
3045
3319
  balance: NativeBalanceResult | null;
3320
+ refetch: () => void;
3046
3321
  ensNameAbbreviated: string | undefined;
3047
3322
  avatarIsLoading: boolean;
3048
3323
  balanceLoading: boolean;
@@ -3055,6 +3330,7 @@ type MainContentProps$1 = Pick<NovaConnectProviderProps, 'transactionPool' | 'pu
3055
3330
  chain: string | number;
3056
3331
  };
3057
3332
  className?: string;
3333
+ childCustomizations?: ConnectedModalCustomization['childCustomizations'];
3058
3334
  };
3059
3335
  type WalletNameConfig = {
3060
3336
  abbreviateSymbols?: number;
@@ -3107,30 +3383,30 @@ type ConnectedModalCustomization = {
3107
3383
  dialog?: () => string;
3108
3384
  /** Function to generate dialog content classes */
3109
3385
  dialogContent?: (params: {
3110
- contentType: ConnectedModalContentType;
3386
+ contentType: ConnectedContentType;
3111
3387
  hasActiveWallet: boolean;
3112
3388
  }) => string;
3113
3389
  /** Function to generate motion container classes */
3114
3390
  motionContainer?: () => string;
3115
3391
  /** Function to generate content container classes */
3116
3392
  contentContainer?: (params: {
3117
- contentType: ConnectedModalContentType;
3393
+ contentType: ConnectedContentType;
3118
3394
  }) => string;
3119
3395
  /** Function to generate header classes */
3120
3396
  header?: (params: {
3121
- contentType: ConnectedModalContentType;
3397
+ contentType: ConnectedContentType;
3122
3398
  }) => string;
3123
3399
  /** Function to generate back button classes */
3124
3400
  backButton?: () => string;
3125
3401
  /** Function to generate title classes */
3126
3402
  title?: (params: {
3127
- contentType: ConnectedModalContentType;
3403
+ contentType: ConnectedContentType;
3128
3404
  }) => string;
3129
3405
  /** Function to generate close button classes */
3130
3406
  closeButton?: () => string;
3131
3407
  /** Function to generate main content classes */
3132
3408
  mainContent?: (params: {
3133
- contentType: ConnectedModalContentType;
3409
+ contentType: ConnectedContentType;
3134
3410
  }) => string;
3135
3411
  /** Function to generate footer classes */
3136
3412
  footer?: () => string;
@@ -3181,12 +3457,14 @@ type ConnectedModalCustomization = {
3181
3457
  /** Custom handler for chain change */
3182
3458
  onChainChange?: (chainId: string) => void;
3183
3459
  /** Custom handler for content type change */
3184
- onContentTypeChange?: (type: ConnectedModalContentType) => void;
3460
+ onContentTypeChange?: (type: ConnectedContentType) => void;
3185
3461
  };
3186
3462
  /** Child component customizations */
3187
3463
  childCustomizations?: {
3188
3464
  /** Customization for ConnectedModalMainContent component */
3189
3465
  mainContent?: ConnectedModalMainContentCustomization;
3466
+ /** Customization for ConnectionsContent component */
3467
+ connections?: ConnectionsContentCustomization;
3190
3468
  /** Customization for ConnectedModalTxHistory component */
3191
3469
  txHistory?: Record<string, unknown>;
3192
3470
  /** Customization for ScrollableChainList component */
@@ -3854,7 +4132,7 @@ interface ConnectorsBlockData {
3854
4132
  /** Whether there are connectors to display */
3855
4133
  hasConnectors: boolean;
3856
4134
  /** Recent wallets data */
3857
- recentWallets: Record<string, Record<string, boolean>> | null;
4135
+ recentWallets: [string, RecentlyConnectedConnectorData][] | null;
3858
4136
  /** Section ID for accessibility */
3859
4137
  sectionId: string;
3860
4138
  }
@@ -4707,6 +4985,7 @@ type InputProps = {
4707
4985
  value: string;
4708
4986
  onChange: (event: React__default.ChangeEvent<HTMLInputElement>) => void;
4709
4987
  onBlur: () => void;
4988
+ onPaste?: (event: React__default.ClipboardEvent<HTMLInputElement>) => void;
4710
4989
  placeholder?: string;
4711
4990
  'aria-describedby'?: string;
4712
4991
  'aria-invalid'?: 'true' | 'false';
@@ -4753,13 +5032,17 @@ type ImpersonateFormCustomization = {
4753
5032
  /** Custom event handlers */
4754
5033
  handlers?: {
4755
5034
  /** Custom handler for input change (called after default logic) */
4756
- onInputChange?: (value: string) => void;
5035
+ onInputChange?: (displayValue: string, resolvedAddress: string | null) => void;
4757
5036
  /** Custom handler for input blur (called after default logic) */
4758
- onInputBlur?: (value: string) => void;
5037
+ onInputBlur?: (displayValue: string, resolvedAddress: string | null) => void;
5038
+ /** Custom handler for paste events */
5039
+ onInputPaste?: (displayValue: string, resolvedAddress: string | null) => void;
4759
5040
  /** Custom handler for validation start */
4760
5041
  onValidationStart?: (value: string) => void;
4761
5042
  /** Custom handler for validation complete */
4762
5043
  onValidationComplete?: (value: string, error: string | null) => void;
5044
+ /** Custom handler for resolved address */
5045
+ onAddressResolved?: (originalValue: string, resolvedAddress: string) => void;
4763
5046
  /** Custom handler for component mount */
4764
5047
  onMount?: () => void;
4765
5048
  /** Custom handler for component unmount */
@@ -4786,6 +5069,8 @@ type ImpersonateFormCustomization = {
4786
5069
  * Props for the ImpersonateForm component
4787
5070
  */
4788
5071
  interface ImpersonateFormProps {
5072
+ /** Currently selected adapter **/
5073
+ selectedAdapter?: OrbitAdapter;
4789
5074
  /** Current impersonated wallet address value */
4790
5075
  impersonatedAddress: string;
4791
5076
  /** Callback to update the impersonated address */
@@ -4797,82 +5082,6 @@ interface ImpersonateFormProps {
4797
5082
  }
4798
5083
  /**
4799
5084
  * Form component for entering wallet address to impersonate with comprehensive customization
4800
- *
4801
- * This component provides a validated form input with:
4802
- * - Debounced validation with configurable timing
4803
- * - Real-time address format validation using viem's isAddress
4804
- * - Full accessibility support with proper ARIA labeling
4805
- * - Error state management with immediate visual feedback
4806
- * - Touch-friendly design with proper focus states
4807
- * - Full customization of all child components
4808
- * - Comprehensive validation with custom validation support
4809
- *
4810
- * Validation features:
4811
- * - Empty address detection
4812
- * - Invalid address format detection using viem
4813
- * - Connected wallet conflict detection
4814
- * - Custom validation function support
4815
- * - Debounced validation to prevent excessive API calls
4816
- * - Immediate validation on blur for better UX
4817
- *
4818
- * Accessibility features:
4819
- * - Proper form labeling with htmlFor association
4820
- * - ARIA invalid and describedby attributes
4821
- * - Live region for error announcements
4822
- * - Screen reader friendly error messages
4823
- * - Proper focus management
4824
- *
4825
- * @example Basic usage
4826
- * ```tsx
4827
- * <ImpersonateForm
4828
- * impersonatedAddress={address}
4829
- * setImpersonatedAddress={setAddress}
4830
- * store={novaConnectStore}
4831
- * />
4832
- * ```
4833
- *
4834
- * @example With custom validation
4835
- * ```tsx
4836
- * <ImpersonateForm
4837
- * impersonatedAddress={address}
4838
- * setImpersonatedAddress={setAddress}
4839
- * store={novaConnectStore}
4840
- * customization={{
4841
- * config: {
4842
- * validation: {
4843
- * debounceDelay: 300,
4844
- * customValidator: (addr) => {
4845
- * if (addr === '0x...') return 'This address is not allowed';
4846
- * return null;
4847
- * }
4848
- * }
4849
- * }
4850
- * }}
4851
- * />
4852
- * ```
4853
- *
4854
- * @example With full customization
4855
- * ```tsx
4856
- * <ImpersonateForm
4857
- * impersonatedAddress={address}
4858
- * setImpersonatedAddress={setAddress}
4859
- * store={novaConnectStore}
4860
- * customization={{
4861
- * components: {
4862
- * Input: CustomInput,
4863
- * ErrorMessage: CustomErrorMessage
4864
- * },
4865
- * classNames: {
4866
- * input: ({ hasError }) => hasError ? 'custom-error' : 'custom-normal'
4867
- * },
4868
- * handlers: {
4869
- * onValidationComplete: (value, error) => {
4870
- * console.log('Validation result:', { value, error });
4871
- * }
4872
- * }
4873
- * }}
4874
- * />
4875
- * ```
4876
5085
  */
4877
5086
  declare const ImpersonateForm: React__default.ForwardRefExoticComponent<ImpersonateFormProps & React__default.RefAttributes<HTMLDivElement>>;
4878
5087
 
@@ -5301,7 +5510,7 @@ interface NetworkSelectionsProps {
5301
5510
  /** Array of grouped wallet connectors with their supported networks */
5302
5511
  connectors: GroupedConnector[];
5303
5512
  /** Click handler for network selection */
5304
- onClick: (adapter: OrbitAdapter, walletType: WalletType) => Promise<void>;
5513
+ onClick: (adapter: OrbitAdapter, connectorType: ConnectorType) => Promise<void>;
5305
5514
  /** Customization options */
5306
5515
  customization?: NetworkSelectionsCustomization;
5307
5516
  }
@@ -5347,8 +5556,8 @@ interface NetworkSelectionsProps {
5347
5556
  * <NetworkSelections
5348
5557
  * activeConnector="metamask"
5349
5558
  * connectors={multiNetworkConnectors}
5350
- * onClick={async (adapter, walletType) => {
5351
- * await connectToNetwork(adapter, walletType);
5559
+ * onClick={async (adapter, connectorType) => {
5560
+ * await connectToNetwork(adapter, connectorType);
5352
5561
  * }}
5353
5562
  * />
5354
5563
  * ```