@tuwaio/nova-connect 1.0.0-fix-test-alpha.1.1de2063 → 1.0.0-fix-test-alpha.2.3c61c83
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/ToastError-D24J0PWb.d.cts +586 -0
- package/dist/ToastError-ixUdnzTl.d.ts +586 -0
- package/dist/chunk-CEGEQMI2.cjs +2 -0
- package/dist/chunk-CEGEQMI2.cjs.map +1 -0
- package/dist/chunk-EKIVAPR5.cjs +2 -0
- package/dist/chunk-EKIVAPR5.cjs.map +1 -0
- package/dist/chunk-PA5HVUML.cjs +6 -0
- package/dist/chunk-PA5HVUML.cjs.map +1 -0
- package/dist/chunk-QEDV2DL5.js +6 -0
- package/dist/chunk-QEDV2DL5.js.map +1 -0
- package/dist/chunk-RHHLGHTV.cjs +2 -0
- package/dist/chunk-RHHLGHTV.cjs.map +1 -0
- package/dist/evm/index.cjs +1 -1
- package/dist/evm/index.cjs.map +1 -1
- package/dist/evm/index.js +1 -1
- package/dist/evm/index.js.map +1 -1
- package/dist/evm-7NHOTSAK.cjs +2 -0
- package/dist/evm-7NHOTSAK.cjs.map +1 -0
- package/dist/getChainsListByWalletType-PPNS2YMZ.cjs +2 -0
- package/dist/getChainsListByWalletType-PPNS2YMZ.cjs.map +1 -0
- package/dist/index.cjs +1 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +16 -566
- package/dist/index.d.ts +16 -566
- package/dist/index.js +1 -5
- package/dist/index.js.map +1 -1
- package/dist/providers/index.cjs +1 -5
- package/dist/providers/index.cjs.map +1 -1
- package/dist/providers/index.d.cts +9 -590
- package/dist/providers/index.d.ts +9 -590
- package/dist/providers/index.js +1 -5
- package/dist/providers/index.js.map +1 -1
- package/dist/solana/index.cjs +1 -1
- package/dist/solana/index.cjs.map +1 -1
- package/dist/solana/index.d.cts +40 -0
- package/dist/solana/index.d.ts +40 -0
- package/dist/solana/index.js +1 -1
- package/dist/solana/index.js.map +1 -1
- package/dist/solana-MTTFU3UW.cjs +2 -0
- package/dist/solana-MTTFU3UW.cjs.map +1 -0
- package/dist/types-yzbOGSEA.d.cts +75 -0
- package/dist/types-yzbOGSEA.d.ts +75 -0
- package/dist/utils-DKLQEIST.cjs +2 -0
- package/dist/utils-DKLQEIST.cjs.map +1 -0
- package/dist/utils-DZB4ZTS4.cjs +2 -0
- package/dist/utils-DZB4ZTS4.cjs.map +1 -0
- package/package.json +4 -4
- package/dist/evm-F7OJEDX3.js +0 -2
- package/dist/evm-F7OJEDX3.js.map +0 -1
- package/dist/providers/evm-5323YCLC.js +0 -2
- package/dist/providers/evm-5323YCLC.js.map +0 -1
- package/dist/providers/solana-WHT5KTOF.js +0 -2
- package/dist/providers/solana-WHT5KTOF.js.map +0 -1
- package/dist/providers/utils-FHHKXQ5Z.js +0 -2
- package/dist/providers/utils-FHHKXQ5Z.js.map +0 -1
- package/dist/providers/utils-L6CFHW4B.js +0 -2
- package/dist/providers/utils-L6CFHW4B.js.map +0 -1
- package/dist/solana-EV65GS7Q.js +0 -2
- package/dist/solana-EV65GS7Q.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -4,11 +4,15 @@ import * as React$1 from 'react';
|
|
|
4
4
|
import React__default, { ComponentType, ReactNode, ComponentPropsWithoutRef } from 'react';
|
|
5
5
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
6
6
|
import * as Select from '@radix-ui/react-select';
|
|
7
|
+
import { I as InitialChains, C as ChainIdentifierArray, a as Connector } from './types-yzbOGSEA.js';
|
|
8
|
+
export { A as AllChainConfigs, b as AllConnectors, c as AllWallets, W as Wallet } from './types-yzbOGSEA.js';
|
|
7
9
|
import { Transaction, TransactionPool, TxAdapter } from '@tuwaio/pulsar-core';
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
+
import { N as NovaConnectLabels, u as useNovaConnect, a as NativeBalanceResult, b as NovaConnectProviderType, C as ConnectContentType, B as ButtonTxStatus, c as NovaConnectProviderProps, d as NovaConnectProvider, e as NovaConnectProviderCustomization } from './ToastError-ixUdnzTl.js';
|
|
11
|
+
export { g as ToastError, T as ToastErrorCustomization, f as ToastErrorProps } from './ToastError-ixUdnzTl.js';
|
|
10
12
|
import { Dialog, DialogContent, StarsBackground } from '@tuwaio/nova-core';
|
|
11
|
-
import
|
|
13
|
+
import '@tuwaio/satellite-core';
|
|
14
|
+
import 'zustand/index';
|
|
15
|
+
import 'react-toastify';
|
|
12
16
|
|
|
13
17
|
/**
|
|
14
18
|
* @file Highly customizable chain list renderer with comprehensive styling and behavior control.
|
|
@@ -183,244 +187,6 @@ interface ChainListRendererProps {
|
|
|
183
187
|
*/
|
|
184
188
|
declare const ChainListRenderer: React__default.FC<ChainListRendererProps>;
|
|
185
189
|
|
|
186
|
-
/**
|
|
187
|
-
* @description
|
|
188
|
-
* This interface provides default fallback types for chain configurations.
|
|
189
|
-
* Chain-specific packages will use module augmentation to override these
|
|
190
|
-
* with more specific types while maintaining backward compatibility.
|
|
191
|
-
*
|
|
192
|
-
* Default values are `any` to ensure the system works without specific
|
|
193
|
-
* chain packages, but gets enhanced type safety when they are installed.
|
|
194
|
-
*/
|
|
195
|
-
interface AllChainConfigs {
|
|
196
|
-
/**
|
|
197
|
-
* App chains configuration - defaults to any, gets enhanced by chain-specific packages
|
|
198
|
-
* @default any - Will be typed as `readonly [Chain, ...Chain[]]` when viem is available
|
|
199
|
-
*/
|
|
200
|
-
appChains?: any;
|
|
201
|
-
/**
|
|
202
|
-
* Solana RPC URLs configuration - defaults to any, gets enhanced by Solana packages
|
|
203
|
-
* @default any - Will be typed as `Partial<Record<SolanaClusterMoniker, string>>` when gill is available
|
|
204
|
-
*/
|
|
205
|
-
solanaRPCUrls?: any;
|
|
206
|
-
}
|
|
207
|
-
/**
|
|
208
|
-
* Union type for all supported chain configurations.
|
|
209
|
-
* Gets automatically extended when packages augment AllChainConfigs.
|
|
210
|
-
*
|
|
211
|
-
* @example
|
|
212
|
-
* ```typescript
|
|
213
|
-
* // Without specific packages - uses any types
|
|
214
|
-
* const config: InitialChains = {
|
|
215
|
-
* appChains: [], // any
|
|
216
|
-
* solanaRPCUrls: {} // any
|
|
217
|
-
* }
|
|
218
|
-
*
|
|
219
|
-
* // With viem package installed - gets proper Chain[] typing
|
|
220
|
-
* // With gill package installed - gets proper SolanaClusterMoniker typing
|
|
221
|
-
* ```
|
|
222
|
-
*/
|
|
223
|
-
type InitialChains = AllChainConfigs;
|
|
224
|
-
/**
|
|
225
|
-
* Array of chain identifiers (replaces IdentifierArray from @wallet-standard/base)
|
|
226
|
-
* Can contain strings, numbers, or other primitive types
|
|
227
|
-
*
|
|
228
|
-
* @example
|
|
229
|
-
* ```typescript
|
|
230
|
-
* const chainIds: ChainIdentifierArray = ['ethereum', 1, 'solana:mainnet-beta'];
|
|
231
|
-
* ```
|
|
232
|
-
*/
|
|
233
|
-
type ChainIdentifierArray = readonly (string | number)[];
|
|
234
|
-
/**
|
|
235
|
-
* @description
|
|
236
|
-
* This interface is intentionally left empty.
|
|
237
|
-
* Other packages (@tuwaio/satellite-*) will use module
|
|
238
|
-
* augmentation to add their specific wallet types here.
|
|
239
|
-
*/
|
|
240
|
-
interface AllWallets {
|
|
241
|
-
}
|
|
242
|
-
/**
|
|
243
|
-
* @description
|
|
244
|
-
* This interface is intentionally left empty.
|
|
245
|
-
* It will be augmented by satellite packages.
|
|
246
|
-
*/
|
|
247
|
-
interface AllConnectors {
|
|
248
|
-
}
|
|
249
|
-
/**
|
|
250
|
-
* Union type for all supported wallet types.
|
|
251
|
-
* It's created from the values of the AllWallets interface.
|
|
252
|
-
* e.g., { evm: EVMWallet, solana: SolanaWallet } -> EVMWallet | SolanaWallet
|
|
253
|
-
*/
|
|
254
|
-
type Wallet = AllWallets[keyof AllWallets];
|
|
255
|
-
/**
|
|
256
|
-
* Union type for all supported connector types.
|
|
257
|
-
*/
|
|
258
|
-
type Connector = AllConnectors[keyof AllConnectors];
|
|
259
|
-
|
|
260
|
-
/**
|
|
261
|
-
* Type definitions for NovaConnect component translations
|
|
262
|
-
* Contains all text strings for multi-language support
|
|
263
|
-
*/
|
|
264
|
-
type NovaConnectLabels = {
|
|
265
|
-
connectWallet: string;
|
|
266
|
-
disconnect: string;
|
|
267
|
-
connecting: string;
|
|
268
|
-
connected: string;
|
|
269
|
-
tryAgain: string;
|
|
270
|
-
back: string;
|
|
271
|
-
connect: string;
|
|
272
|
-
close: string;
|
|
273
|
-
all: string;
|
|
274
|
-
connectionError: string;
|
|
275
|
-
connectedSuccessfully: string;
|
|
276
|
-
connectingTo: string;
|
|
277
|
-
walletConnectionError: string;
|
|
278
|
-
errorWhenChainSwitching: string;
|
|
279
|
-
cannotConnectWallet: string;
|
|
280
|
-
success: string;
|
|
281
|
-
error: string;
|
|
282
|
-
replaced: string;
|
|
283
|
-
recent: string;
|
|
284
|
-
transactionLoading: string;
|
|
285
|
-
transactionSuccess: string;
|
|
286
|
-
transactionError: string;
|
|
287
|
-
transactionReplaced: string;
|
|
288
|
-
aboutWallets: string;
|
|
289
|
-
getWallet: string;
|
|
290
|
-
connectImpersonatedWallet: string;
|
|
291
|
-
transactionsInApp: string;
|
|
292
|
-
switchNetwork: string;
|
|
293
|
-
switchNetworks: string;
|
|
294
|
-
connectingEllipsis: string;
|
|
295
|
-
installed: string;
|
|
296
|
-
popular: string;
|
|
297
|
-
impersonate: string;
|
|
298
|
-
readOnlyMode: string;
|
|
299
|
-
whatIsWallet: string;
|
|
300
|
-
walletDescription: string;
|
|
301
|
-
whatIsNetwork: string;
|
|
302
|
-
networkDescription: string;
|
|
303
|
-
learnMore: string;
|
|
304
|
-
listOfNetworks: string;
|
|
305
|
-
viewOnExplorer: string;
|
|
306
|
-
viewTransactions: string;
|
|
307
|
-
enterWalletAddress: string;
|
|
308
|
-
walletAddressPlaceholder: string;
|
|
309
|
-
noConnectorsFound: string;
|
|
310
|
-
noConnectorsDescription: string;
|
|
311
|
-
somethingWentWrong: string;
|
|
312
|
-
networkPickingError: string;
|
|
313
|
-
pulsarAdapterRequired: string;
|
|
314
|
-
pulsarAdapterDescription: string;
|
|
315
|
-
selectAvailableNetwork: string;
|
|
316
|
-
startExploringWeb3: string;
|
|
317
|
-
walletKeyToDigitalWorld: string;
|
|
318
|
-
iDontHaveWallet: string;
|
|
319
|
-
choseWallet: string;
|
|
320
|
-
keyToNewInternet: string;
|
|
321
|
-
keyToNewInternetDescription: string;
|
|
322
|
-
logInWithoutHassle: string;
|
|
323
|
-
logInWithoutHassleDescription: string;
|
|
324
|
-
copyRawError: string;
|
|
325
|
-
copied: string;
|
|
326
|
-
chainSelector: string;
|
|
327
|
-
closeModal: string;
|
|
328
|
-
selectChain: string;
|
|
329
|
-
chainOption: string;
|
|
330
|
-
openChainSelector: string;
|
|
331
|
-
currentChain: string;
|
|
332
|
-
scrollToTop: string;
|
|
333
|
-
scrollToBottom: string;
|
|
334
|
-
chainListContainer: string;
|
|
335
|
-
walletControls: string;
|
|
336
|
-
openWalletModal: string;
|
|
337
|
-
walletConnected: string;
|
|
338
|
-
walletNotConnected: string;
|
|
339
|
-
walletBalance: string;
|
|
340
|
-
walletAddress: string;
|
|
341
|
-
transactionStatus: string;
|
|
342
|
-
successIcon: string;
|
|
343
|
-
errorIcon: string;
|
|
344
|
-
replacedIcon: string;
|
|
345
|
-
statusIcon: string;
|
|
346
|
-
loading: string;
|
|
347
|
-
idle: string;
|
|
348
|
-
unknownWallet: string;
|
|
349
|
-
walletAvatar: string;
|
|
350
|
-
ensAvatar: string;
|
|
351
|
-
walletIcon: string;
|
|
352
|
-
impersonateAddressEmpty: string;
|
|
353
|
-
impersonateAddressNotCorrect: string;
|
|
354
|
-
impersonateAddressConnected: string;
|
|
355
|
-
};
|
|
356
|
-
|
|
357
|
-
type ButtonTxStatus = 'idle' | 'loading' | 'succeed' | 'failed' | 'replaced';
|
|
358
|
-
type ConnectContentType = 'network' | 'connectors' | 'about' | 'getWallet' | 'connecting' | 'impersonate';
|
|
359
|
-
type ConnectedContentType = 'main' | 'transactions' | 'chains';
|
|
360
|
-
interface NovaConnectProviderProps {
|
|
361
|
-
store: StoreApi<ISatelliteConnectStore<Connector, Wallet>>;
|
|
362
|
-
children: React.ReactNode;
|
|
363
|
-
labels?: Partial<NovaConnectLabels>;
|
|
364
|
-
}
|
|
365
|
-
interface NovaConnectProviderType {
|
|
366
|
-
activeWallet: BaseWallet | undefined;
|
|
367
|
-
walletConnectionError: string | undefined;
|
|
368
|
-
isConnectModalOpen: boolean;
|
|
369
|
-
setIsConnectModalOpen: (value: boolean) => void;
|
|
370
|
-
isConnectedModalOpen: boolean;
|
|
371
|
-
setIsConnectedModalOpen: (value: boolean) => void;
|
|
372
|
-
isChainsListOpen: boolean;
|
|
373
|
-
setIsChainsListOpen: (value: boolean) => void;
|
|
374
|
-
isChainsListOpenMobile: boolean;
|
|
375
|
-
setIsChainsListOpenMobile: (value: boolean) => void;
|
|
376
|
-
connectedButtonStatus: ButtonTxStatus;
|
|
377
|
-
setConnectedButtonStatus: (value: ButtonTxStatus) => void;
|
|
378
|
-
isConnected: boolean;
|
|
379
|
-
setIsConnected: (value: boolean) => void;
|
|
380
|
-
connectedModalContentType: ConnectedContentType;
|
|
381
|
-
setConnectedModalContentType: (value: ConnectedContentType) => void;
|
|
382
|
-
connectModalContentType: ConnectContentType;
|
|
383
|
-
setConnectModalContentType: (value: ConnectContentType) => void;
|
|
384
|
-
selectedAdapter: OrbitAdapter | undefined;
|
|
385
|
-
setSelectedAdapter: (value: OrbitAdapter | undefined) => void;
|
|
386
|
-
activeConnector: string | undefined;
|
|
387
|
-
setActiveConnector: (value: string | undefined) => void;
|
|
388
|
-
impersonatedAddress: string;
|
|
389
|
-
setImpersonatedAddress: (value: string) => void;
|
|
390
|
-
}
|
|
391
|
-
/**
|
|
392
|
-
* Hook to access NovaConnect context
|
|
393
|
-
*
|
|
394
|
-
* @throws {NovaConnectProviderError} When used outside of NovaConnectProvider
|
|
395
|
-
* @returns {NovaConnectProviderType} The NovaConnect context value
|
|
396
|
-
*
|
|
397
|
-
* @example
|
|
398
|
-
* ```typescript
|
|
399
|
-
* function MyComponent() {
|
|
400
|
-
* const { isConnected, handleConnectButtonClick } = useNovaConnect();
|
|
401
|
-
*
|
|
402
|
-
* return (
|
|
403
|
-
* <button onClick={handleConnectButtonClick}>
|
|
404
|
-
* {isConnected ? 'Connected' : 'Connect Wallet'}
|
|
405
|
-
* </button>
|
|
406
|
-
* );
|
|
407
|
-
* }
|
|
408
|
-
* ```
|
|
409
|
-
*/
|
|
410
|
-
declare const useNovaConnect: () => NovaConnectProviderType;
|
|
411
|
-
|
|
412
|
-
/**
|
|
413
|
-
* @interface NativeBalanceResult
|
|
414
|
-
* Represents the native token balance returned by the adapter.
|
|
415
|
-
* The value is already formatted for human readability.
|
|
416
|
-
* @property {string} value The native token balance formatted to standard decimals (e.g., "1.5").
|
|
417
|
-
* @property {string} symbol The symbol of the native token (e.g., "ETH").
|
|
418
|
-
*/
|
|
419
|
-
interface NativeBalanceResult {
|
|
420
|
-
value: string;
|
|
421
|
-
symbol: string;
|
|
422
|
-
}
|
|
423
|
-
|
|
424
190
|
/**
|
|
425
191
|
* A custom hook to easily access the i18n labels from any component
|
|
426
192
|
* within the `NovaConnectLabelsProvider` tree.
|
|
@@ -463,7 +229,7 @@ interface NativeBalanceResult {
|
|
|
463
229
|
*/
|
|
464
230
|
declare const useNovaConnectLabels: () => NovaConnectLabels;
|
|
465
231
|
|
|
466
|
-
type CustomIconProps$
|
|
232
|
+
type CustomIconProps$2 = {
|
|
467
233
|
disabled: boolean;
|
|
468
234
|
className?: string;
|
|
469
235
|
'aria-hidden'?: boolean;
|
|
@@ -482,7 +248,7 @@ type ToBottomButtonCustomization = {
|
|
|
482
248
|
/** Custom components */
|
|
483
249
|
components?: {
|
|
484
250
|
/** Custom icon component */
|
|
485
|
-
Icon?: ComponentType<CustomIconProps$
|
|
251
|
+
Icon?: ComponentType<CustomIconProps$2>;
|
|
486
252
|
/** Custom button content component (wraps the icon) */
|
|
487
253
|
Content?: ComponentType<CustomContentProps$3>;
|
|
488
254
|
};
|
|
@@ -524,7 +290,7 @@ interface ToBottomButtonProps extends Omit<ComponentPropsWithoutRef<'button'>, '
|
|
|
524
290
|
*/
|
|
525
291
|
declare const ToBottomButton: React$1.ForwardRefExoticComponent<ToBottomButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
526
292
|
|
|
527
|
-
type CustomIconProps$
|
|
293
|
+
type CustomIconProps$1 = {
|
|
528
294
|
disabled: boolean;
|
|
529
295
|
className?: string;
|
|
530
296
|
'aria-hidden'?: boolean;
|
|
@@ -543,7 +309,7 @@ type ToTopButtonCustomization = {
|
|
|
543
309
|
/** Custom components */
|
|
544
310
|
components?: {
|
|
545
311
|
/** Custom icon component */
|
|
546
|
-
Icon?: ComponentType<CustomIconProps$
|
|
312
|
+
Icon?: ComponentType<CustomIconProps$1>;
|
|
547
313
|
/** Custom button content component (wraps the icon) */
|
|
548
314
|
Content?: ComponentType<CustomContentProps$2>;
|
|
549
315
|
};
|
|
@@ -1474,7 +1240,7 @@ type CustomLoadingOverlayProps = {
|
|
|
1474
1240
|
loading: boolean;
|
|
1475
1241
|
className?: string;
|
|
1476
1242
|
};
|
|
1477
|
-
type CustomButtonContentProps
|
|
1243
|
+
type CustomButtonContentProps = {
|
|
1478
1244
|
walletIconContainer: ReactNode;
|
|
1479
1245
|
chainIconContainer: ReactNode;
|
|
1480
1246
|
chevronContainer: ReactNode;
|
|
@@ -1503,7 +1269,7 @@ type IconButtonCustomization = {
|
|
|
1503
1269
|
/** Custom loading overlay component */
|
|
1504
1270
|
LoadingOverlay?: ComponentType<CustomLoadingOverlayProps>;
|
|
1505
1271
|
/** Custom button content wrapper component */
|
|
1506
|
-
ButtonContent?: ComponentType<CustomButtonContentProps
|
|
1272
|
+
ButtonContent?: ComponentType<CustomButtonContentProps>;
|
|
1507
1273
|
};
|
|
1508
1274
|
/** Custom class name generators */
|
|
1509
1275
|
classNames?: {
|
|
@@ -6485,7 +6251,7 @@ interface ConnectedContentProps extends Pick<ConnectButtonProps, 'transactionPoo
|
|
|
6485
6251
|
*/
|
|
6486
6252
|
declare const ConnectedContent: React__default.ForwardRefExoticComponent<ConnectedContentProps & React__default.RefAttributes<HTMLDivElement>>;
|
|
6487
6253
|
|
|
6488
|
-
type CustomIconProps
|
|
6254
|
+
type CustomIconProps = {
|
|
6489
6255
|
pathData: string;
|
|
6490
6256
|
className?: string;
|
|
6491
6257
|
'aria-hidden'?: boolean;
|
|
@@ -6520,7 +6286,7 @@ type WaitForConnectionContentCustomization = {
|
|
|
6520
6286
|
/** Custom components */
|
|
6521
6287
|
components?: {
|
|
6522
6288
|
/** Custom icon SVG component */
|
|
6523
|
-
Icon?: ComponentType<CustomIconProps
|
|
6289
|
+
Icon?: ComponentType<CustomIconProps>;
|
|
6524
6290
|
/** Custom path component */
|
|
6525
6291
|
Path?: ComponentType<CustomPathProps>;
|
|
6526
6292
|
/** Custom text component */
|
|
@@ -7210,229 +6976,6 @@ interface ChainSelectorProps extends InitialChains, Pick<ConnectButtonProps, 'st
|
|
|
7210
6976
|
*/
|
|
7211
6977
|
declare function ChainSelector({ appChains, solanaRPCUrls, store, customization, className, 'aria-label': ariaLabel, }: ChainSelectorProps): react_jsx_runtime.JSX.Element | null;
|
|
7212
6978
|
|
|
7213
|
-
type CustomToastErrorProps = {
|
|
7214
|
-
title: string;
|
|
7215
|
-
rawError: string;
|
|
7216
|
-
onCopyComplete?: (success: boolean) => void;
|
|
7217
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7218
|
-
isConnected: boolean;
|
|
7219
|
-
};
|
|
7220
|
-
type CustomContainerProps = ComponentPropsWithoutRef<typeof ToastContainer>;
|
|
7221
|
-
/**
|
|
7222
|
-
* Customization options for ErrorsProvider component
|
|
7223
|
-
*/
|
|
7224
|
-
type ErrorsProviderCustomization = {
|
|
7225
|
-
/** Override ToastContainer element props */
|
|
7226
|
-
containerProps?: Partial<ComponentPropsWithoutRef<typeof ToastContainer>>;
|
|
7227
|
-
/** Custom components */
|
|
7228
|
-
components?: {
|
|
7229
|
-
/** Custom ToastError component */
|
|
7230
|
-
ToastError?: ComponentType<CustomToastErrorProps>;
|
|
7231
|
-
/** Custom ToastContainer component */
|
|
7232
|
-
Container?: ComponentType<CustomContainerProps>;
|
|
7233
|
-
};
|
|
7234
|
-
/** Default ToastError customization (only used with default ToastError component) */
|
|
7235
|
-
toastErrorCustomization?: ToastErrorCustomization;
|
|
7236
|
-
/** Custom class name generators */
|
|
7237
|
-
classNames?: {
|
|
7238
|
-
/** Function to generate container classes */
|
|
7239
|
-
container?: (params: {
|
|
7240
|
-
hasErrors: boolean;
|
|
7241
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7242
|
-
}) => string;
|
|
7243
|
-
};
|
|
7244
|
-
/** Custom toast options generators */
|
|
7245
|
-
toastOptions?: {
|
|
7246
|
-
/** Function to generate toast options */
|
|
7247
|
-
error?: (params: {
|
|
7248
|
-
title: string;
|
|
7249
|
-
rawError: string;
|
|
7250
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7251
|
-
isConnected: boolean;
|
|
7252
|
-
}) => Partial<Parameters<typeof toast.error>[1]>;
|
|
7253
|
-
};
|
|
7254
|
-
/** Custom logic handlers */
|
|
7255
|
-
handlers?: {
|
|
7256
|
-
/** Custom error display logic */
|
|
7257
|
-
showError?: (originalHandler: (title: string, rawError: string, errorKey: string) => void, params: {
|
|
7258
|
-
title: string;
|
|
7259
|
-
rawError: string;
|
|
7260
|
-
errorKey: string;
|
|
7261
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7262
|
-
}) => void;
|
|
7263
|
-
/** Custom error dismissal logic */
|
|
7264
|
-
dismissError?: (originalHandler: () => void) => void;
|
|
7265
|
-
/** Custom copy complete handler */
|
|
7266
|
-
onCopyComplete?: (success: boolean, rawError: string, errorType: 'wallet' | 'switch' | null) => void;
|
|
7267
|
-
};
|
|
7268
|
-
/** Custom error title generator - does NOT customize labels, just allows title modification */
|
|
7269
|
-
errorTitle?: (defaultTitle: string, params: {
|
|
7270
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7271
|
-
}) => string;
|
|
7272
|
-
/** Custom error hash generator for deduplication */
|
|
7273
|
-
errorHash?: (defaultHash: string | null, params: {
|
|
7274
|
-
primaryError: string | null;
|
|
7275
|
-
errorType: 'wallet' | 'switch' | null;
|
|
7276
|
-
}) => string | null;
|
|
7277
|
-
};
|
|
7278
|
-
interface ErrorsProviderProps extends Pick<NovaConnectProviderProps, 'store'> {
|
|
7279
|
-
/** Custom container ID for toast notifications */
|
|
7280
|
-
containerId?: string;
|
|
7281
|
-
/** Custom position for toast notifications */
|
|
7282
|
-
position?: ToastPosition;
|
|
7283
|
-
/** Auto close delay in milliseconds */
|
|
7284
|
-
autoClose?: number | false;
|
|
7285
|
-
/** Whether to enable drag to dismiss */
|
|
7286
|
-
draggable?: boolean;
|
|
7287
|
-
/** Customization options */
|
|
7288
|
-
customization?: ErrorsProviderCustomization;
|
|
7289
|
-
}
|
|
7290
|
-
|
|
7291
|
-
/**
|
|
7292
|
-
* Props for custom NovaConnectLabelsProvider component
|
|
7293
|
-
*/
|
|
7294
|
-
type CustomLabelsProviderProps = {
|
|
7295
|
-
labels?: Partial<NovaConnectLabels>;
|
|
7296
|
-
children: ReactNode;
|
|
7297
|
-
};
|
|
7298
|
-
/**
|
|
7299
|
-
* Props for custom ErrorsProvider component
|
|
7300
|
-
*/
|
|
7301
|
-
type CustomErrorsProviderProps = Pick<ErrorsProviderProps, 'store'> & {
|
|
7302
|
-
customization?: ErrorsProviderCustomization;
|
|
7303
|
-
};
|
|
7304
|
-
/**
|
|
7305
|
-
* Context data passed to custom provider components
|
|
7306
|
-
*/
|
|
7307
|
-
type ProviderContext = {
|
|
7308
|
-
/** Current wallet connection state */
|
|
7309
|
-
isConnected: boolean;
|
|
7310
|
-
/** Active wallet instance */
|
|
7311
|
-
activeWallet: BaseWallet | undefined;
|
|
7312
|
-
/** Current wallet connection error */
|
|
7313
|
-
walletConnectionError: string | undefined;
|
|
7314
|
-
/** All modal and UI states */
|
|
7315
|
-
modalStates: {
|
|
7316
|
-
isConnectModalOpen: boolean;
|
|
7317
|
-
isConnectedModalOpen: boolean;
|
|
7318
|
-
isChainsListOpen: boolean;
|
|
7319
|
-
isChainsListOpenMobile: boolean;
|
|
7320
|
-
};
|
|
7321
|
-
/** Current content types for modals */
|
|
7322
|
-
contentTypes: {
|
|
7323
|
-
connectModal: ConnectContentType;
|
|
7324
|
-
connectedModal: ConnectedContentType;
|
|
7325
|
-
};
|
|
7326
|
-
/** Button and transaction statuses */
|
|
7327
|
-
statuses: {
|
|
7328
|
-
connectedButton: ButtonTxStatus;
|
|
7329
|
-
};
|
|
7330
|
-
};
|
|
7331
|
-
/**
|
|
7332
|
-
* Comprehensive customization options for NovaConnectProvider
|
|
7333
|
-
*/
|
|
7334
|
-
type NovaConnectProviderCustomization = {
|
|
7335
|
-
/** Custom components */
|
|
7336
|
-
components?: {
|
|
7337
|
-
/** Custom labels provider component */
|
|
7338
|
-
LabelsProvider?: ComponentType<CustomLabelsProviderProps>;
|
|
7339
|
-
/** Custom errors provider component */
|
|
7340
|
-
ErrorsProvider?: ComponentType<CustomErrorsProviderProps>;
|
|
7341
|
-
};
|
|
7342
|
-
/** Labels customization and merging strategy */
|
|
7343
|
-
labels?: {
|
|
7344
|
-
/** Custom labels merging function */
|
|
7345
|
-
merge?: (defaultLabels: NovaConnectLabels, userLabels: Partial<NovaConnectLabels>) => NovaConnectLabels;
|
|
7346
|
-
/** Transform final merged labels before use */
|
|
7347
|
-
transform?: (mergedLabels: NovaConnectLabels, context: ProviderContext) => NovaConnectLabels;
|
|
7348
|
-
};
|
|
7349
|
-
/** ErrorsProvider customization - passed through to ErrorsProvider */
|
|
7350
|
-
errors?: ErrorsProviderCustomization;
|
|
7351
|
-
/** Custom initialization logic */
|
|
7352
|
-
initialization?: {
|
|
7353
|
-
/** Custom logic after store subscription setup */
|
|
7354
|
-
onStoreSubscribed?: (context: ProviderContext) => void;
|
|
7355
|
-
/** Custom logic when connection state changes */
|
|
7356
|
-
onConnectionStateChange?: (isConnected: boolean, activeWallet: BaseWallet | undefined, context: ProviderContext) => void;
|
|
7357
|
-
/** Custom logic when error state changes */
|
|
7358
|
-
onErrorStateChange?: (error: string | undefined, context: ProviderContext) => void;
|
|
7359
|
-
};
|
|
7360
|
-
/** Custom context value transformation */
|
|
7361
|
-
contextValue?: {
|
|
7362
|
-
/** Transform context value before providing to children */
|
|
7363
|
-
transform?: (defaultValue: NovaConnectProviderType, context: ProviderContext) => NovaConnectProviderType;
|
|
7364
|
-
};
|
|
7365
|
-
/** Custom rendering logic */
|
|
7366
|
-
rendering?: {
|
|
7367
|
-
/** Custom provider tree structure */
|
|
7368
|
-
providerTree?: (defaultTree: ReactNode, components: {
|
|
7369
|
-
ErrorsProvider: ReactNode;
|
|
7370
|
-
LabelsProvider: ReactNode;
|
|
7371
|
-
MainContent: ReactNode;
|
|
7372
|
-
}, context: ProviderContext) => ReactNode;
|
|
7373
|
-
};
|
|
7374
|
-
};
|
|
7375
|
-
/**
|
|
7376
|
-
* Extended props for NovaConnectProvider with full customization capabilities
|
|
7377
|
-
*/
|
|
7378
|
-
interface NovaConnectProviderPropsWithCustomization extends NovaConnectProviderProps {
|
|
7379
|
-
/** Comprehensive customization options for the provider and its sub-components */
|
|
7380
|
-
customization?: NovaConnectProviderCustomization;
|
|
7381
|
-
}
|
|
7382
|
-
/**
|
|
7383
|
-
* Main NovaConnect provider component with comprehensive customization capabilities.
|
|
7384
|
-
*
|
|
7385
|
-
* This provider manages wallet connection state, error handling, internationalization,
|
|
7386
|
-
* and modal states while offering extensive customization options for all sub-components
|
|
7387
|
-
* and behaviors.
|
|
7388
|
-
*
|
|
7389
|
-
* Features:
|
|
7390
|
-
* - Complete wallet connection state management
|
|
7391
|
-
* - Customizable error handling through ErrorsProvider
|
|
7392
|
-
* - Flexible internationalization system
|
|
7393
|
-
* - Modal and UI state coordination
|
|
7394
|
-
* - Extensive customization API for all aspects
|
|
7395
|
-
* - Custom component replacement capabilities
|
|
7396
|
-
* - Advanced initialization and lifecycle hooks
|
|
7397
|
-
*
|
|
7398
|
-
* @example Basic usage
|
|
7399
|
-
* ```tsx
|
|
7400
|
-
* <NovaConnectProvider store={store}>
|
|
7401
|
-
* <App />
|
|
7402
|
-
* </NovaConnectProvider>
|
|
7403
|
-
* ```
|
|
7404
|
-
*
|
|
7405
|
-
* @example With customization
|
|
7406
|
-
* ```tsx
|
|
7407
|
-
* <NovaConnectProvider
|
|
7408
|
-
* store={store}
|
|
7409
|
-
* labels={customLabels}
|
|
7410
|
-
* customization={{
|
|
7411
|
-
* errors: {
|
|
7412
|
-
* position: 'bottom-right',
|
|
7413
|
-
* autoClose: 5000,
|
|
7414
|
-
* components: {
|
|
7415
|
-
* ToastError: CustomToastError
|
|
7416
|
-
* }
|
|
7417
|
-
* },
|
|
7418
|
-
* initialization: {
|
|
7419
|
-
* onConnectionStateChange: (isConnected, wallet) => {
|
|
7420
|
-
* console.log('Connection state:', isConnected, wallet);
|
|
7421
|
-
* }
|
|
7422
|
-
* }
|
|
7423
|
-
* }}
|
|
7424
|
-
* >
|
|
7425
|
-
* <App />
|
|
7426
|
-
* </NovaConnectProvider>
|
|
7427
|
-
* ```
|
|
7428
|
-
*
|
|
7429
|
-
* @param props - Provider configuration and customization options
|
|
7430
|
-
*/
|
|
7431
|
-
declare function NovaConnectProvider({ labels, store, children, customization, }: NovaConnectProviderPropsWithCustomization): react_jsx_runtime.JSX.Element;
|
|
7432
|
-
declare namespace NovaConnectProvider {
|
|
7433
|
-
var displayName: string;
|
|
7434
|
-
}
|
|
7435
|
-
|
|
7436
6979
|
/**
|
|
7437
6980
|
* Root customization data for the complete NovaConnectButton with provider
|
|
7438
6981
|
*/
|
|
@@ -7879,99 +7422,6 @@ interface RecentBadgeProps {
|
|
|
7879
7422
|
*/
|
|
7880
7423
|
declare const RecentBadge: React__default.NamedExoticComponent<RecentBadgeProps & React__default.RefAttributes<HTMLSpanElement>>;
|
|
7881
7424
|
|
|
7882
|
-
type CustomIconProps = {
|
|
7883
|
-
isCopied: boolean;
|
|
7884
|
-
className?: string;
|
|
7885
|
-
'aria-hidden'?: boolean;
|
|
7886
|
-
};
|
|
7887
|
-
type CustomTitleProps = {
|
|
7888
|
-
title: string;
|
|
7889
|
-
titleId: string;
|
|
7890
|
-
className?: string;
|
|
7891
|
-
};
|
|
7892
|
-
type CustomDescriptionProps = {
|
|
7893
|
-
rawError: string;
|
|
7894
|
-
descriptionId: string;
|
|
7895
|
-
className?: string;
|
|
7896
|
-
};
|
|
7897
|
-
type CustomButtonContentProps = {
|
|
7898
|
-
icon: ReactNode;
|
|
7899
|
-
isCopied: boolean;
|
|
7900
|
-
copyLabel: string;
|
|
7901
|
-
copiedLabel: string;
|
|
7902
|
-
};
|
|
7903
|
-
/**
|
|
7904
|
-
* Customization options for ToastError component
|
|
7905
|
-
*/
|
|
7906
|
-
type ToastErrorCustomization = {
|
|
7907
|
-
/** Override container element props */
|
|
7908
|
-
containerProps?: Partial<Omit<ComponentPropsWithoutRef<'div'>, 'style'>>;
|
|
7909
|
-
/** Override button element props */
|
|
7910
|
-
buttonProps?: Partial<Omit<ComponentPropsWithoutRef<'button'>, 'style'>>;
|
|
7911
|
-
/** Custom components */
|
|
7912
|
-
components?: {
|
|
7913
|
-
/** Custom icon component */
|
|
7914
|
-
Icon?: ComponentType<CustomIconProps>;
|
|
7915
|
-
/** Custom title component */
|
|
7916
|
-
Title?: ComponentType<CustomTitleProps>;
|
|
7917
|
-
/** Custom description component */
|
|
7918
|
-
Description?: ComponentType<CustomDescriptionProps>;
|
|
7919
|
-
/** Custom button content component */
|
|
7920
|
-
ButtonContent?: ComponentType<CustomButtonContentProps>;
|
|
7921
|
-
};
|
|
7922
|
-
/** Custom class name generators */
|
|
7923
|
-
classNames?: {
|
|
7924
|
-
/** Function to generate container classes */
|
|
7925
|
-
container?: (params: {
|
|
7926
|
-
hasTitle: boolean;
|
|
7927
|
-
hasError: boolean;
|
|
7928
|
-
}) => string;
|
|
7929
|
-
/** Function to generate title classes */
|
|
7930
|
-
title?: (params: {
|
|
7931
|
-
title: string;
|
|
7932
|
-
}) => string;
|
|
7933
|
-
/** Function to generate description classes */
|
|
7934
|
-
description?: (params: {
|
|
7935
|
-
rawError: string;
|
|
7936
|
-
}) => string;
|
|
7937
|
-
/** Function to generate button classes */
|
|
7938
|
-
button?: (params: {
|
|
7939
|
-
isCopied: boolean;
|
|
7940
|
-
disabled: boolean;
|
|
7941
|
-
}) => string;
|
|
7942
|
-
/** Function to generate icon classes */
|
|
7943
|
-
icon?: (params: {
|
|
7944
|
-
isCopied: boolean;
|
|
7945
|
-
}) => string;
|
|
7946
|
-
};
|
|
7947
|
-
/** Custom event handlers */
|
|
7948
|
-
handlers?: {
|
|
7949
|
-
/** Custom click handler wrapper */
|
|
7950
|
-
onClick?: (originalHandler: (event: React.MouseEvent<HTMLButtonElement>) => void, event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
7951
|
-
/** Custom keydown handler wrapper */
|
|
7952
|
-
onKeyDown?: (originalHandler: (event: React.KeyboardEvent<HTMLButtonElement>) => void, event: React.KeyboardEvent<HTMLButtonElement>) => void;
|
|
7953
|
-
};
|
|
7954
|
-
};
|
|
7955
|
-
interface ToastErrorProps extends Omit<ComponentPropsWithoutRef<'div'>, 'role' | 'aria-live' | 'style'> {
|
|
7956
|
-
/** Error title to display */
|
|
7957
|
-
title: string;
|
|
7958
|
-
/** Raw error message to display and copy */
|
|
7959
|
-
rawError: string;
|
|
7960
|
-
/** Custom CSS classes for the container */
|
|
7961
|
-
className?: string;
|
|
7962
|
-
/** Custom ARIA label for the error container */
|
|
7963
|
-
'aria-label'?: string;
|
|
7964
|
-
/** Callback fired when copy operation completes */
|
|
7965
|
-
onCopyComplete?: (success: boolean) => void;
|
|
7966
|
-
/** Customization options */
|
|
7967
|
-
customization?: ToastErrorCustomization;
|
|
7968
|
-
}
|
|
7969
|
-
/**
|
|
7970
|
-
* A highly customizable error toast component with copy functionality and extensive styling options.
|
|
7971
|
-
* Provides comprehensive customization for appearance, behavior, and event handling while maintaining accessibility.
|
|
7972
|
-
*/
|
|
7973
|
-
declare const ToastError: React$1.ForwardRefExoticComponent<ToastErrorProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
7974
|
-
|
|
7975
7425
|
/**
|
|
7976
7426
|
* Default English translations for NovaConnect component
|
|
7977
7427
|
* All text strings extracted from component files
|
|
@@ -8151,4 +7601,4 @@ declare function initializeBlockchainSupport(): Promise<InitializationResult>;
|
|
|
8151
7601
|
*/
|
|
8152
7602
|
declare function isAdapterSupported(adapter: OrbitAdapter): Promise<boolean>;
|
|
8153
7603
|
|
|
8154
|
-
export { AboutWallets, type AboutWalletsCustomization, type AboutWalletsProps, type AdapterInfo, type AdapterLoadStatus, type
|
|
7604
|
+
export { AboutWallets, type AboutWalletsCustomization, type AboutWalletsProps, type AdapterInfo, type AdapterLoadStatus, type AnimationConfig, type BadgeAnimationConfig, type BadgeGradientConfig, type BlockchainUtilities, type BlockchainUtilityResult, type ChainAdapter, ChainIdentifierArray, ChainListRenderer, type ChainListRendererCustomization, type ChainListRendererProps, ChainSelector, type ChainSelectorCustomization, type ChainSelectorProps, type ChainTriggerButtonCustomization, type ConnectButtonCustomization, type ConnectButtonData, type ConnectButtonProps, ConnectCard, type ConnectCardCustomization, type ConnectCardData, ConnectedContent, type ConnectedContentCustomization, type ConnectedContentProps, ConnectedModal, type ConnectedModalCustomization, ConnectedModalFooter, type ConnectedModalFooterCustomization, type ConnectedModalFooterProps, ConnectedModalMainContent, type ConnectedModalMainContentCustomization, type ConnectedModalMainContentProps, ConnectedModalNameAndBalance, type ConnectedModalNameAndBalanceCustomization, type ConnectedModalNameAndBalanceProps, type ConnectedModalProps, ConnectedModalTxHistory, type ConnectedModalTxHistoryCustomization, type ConnectedModalTxHistoryProps, Connecting, type ConnectingCustomization, type ConnectingProps, type ConnectingStatusData, type ConnectionState, Connector, type ConnectorItemData, ConnectorsBlock, type ConnectorsBlockCustomization, type ConnectorsBlockData, ConnectorsSelections, type ConnectorsSelectionsCustomization, type ConnectorsSelectionsData, type ConnectorsSelectionsProps, Disclaimer, type DisclaimerCustomization, type DisclaimerProps, GetWallet, type GetWalletCustomization, type GetWalletProps, type GroupedConnector$1 as GroupedConnector, IconButton, type IconButtonCustomization, type IconButtonProps, ImpersonateForm, type ImpersonateFormCustomization, type ImpersonateFormProps, type ImpersonateSectionData, InitialChains, type InitializationResult, type NetworkIconsCustomization, NetworkSelections, type NetworkSelectionsCustomization, type NetworkSelectionsData, type NetworkTabData, NetworkTabs, type NetworkTabsCustomization, type NetworkTabsProps, NovaConnectButton, type NovaConnectButtonProps, type NovaConnectButtonWithProviderCustomization, type NovaConnectButtonWithProviderData, NovaConnectLabels, NovaConnectProviderCustomization, RecentBadge, type RecentBadgeCustomization, type RecentBadgeProps, ScrollableChainList, type ScrollableChainListCustomization, type ScrollableChainListProps, SelectContentAnimated, type SelectContentAnimatedProps, StatusIcon, type StatusIconCustomization, type StatusIconProps, ToBottomButton, type ToBottomButtonCustomization, type ToBottomButtonProps, ToTopButton, type ToTopButtonCustomization, type ToTopButtonProps, type ValidationConfig, WaitForConnectionContent, type WaitForConnectionContentCustomization, type WaitForConnectionContentProps, WalletAvatar, type WalletAvatarCustomization, type WalletAvatarProps, type WalletAvatarSize, WalletIcon, type WalletIconConfig, type WalletIconCustomization, type WalletIconProps$1 as WalletIconProps, defaultLabels, getAdapterStatus, getAllAdaptersStatus, getAvailableChainIds, getAvailableSolanaClusters, getAvailableSolanaClusters$1 as getAvailableSolanaClustersAsync, getBlockchainUtilities, getChainsListByWalletTypeSync as getChainsListByWalletType, getChainsListByWalletType as getChainsListByWalletTypeAsync, getChainsListByWalletTypeSync, getConnectChainId, getEvmUtils, getFilteredConnectors, getGroupedConnectors, getNetworkIcon, getSolanaUtils, getWalletChains, hasAvailableConnectors, hasConnectorsForAdapter, initializeBlockchainSupport, isAdapterSupported, isEvmChainListSync as isEvmChainList, isEvmChainList as isEvmChainListAsync, isEvmChainListSync, isSolanaChainListSync as isSolanaChainList, isSolanaChainList as isSolanaChainListAsync, isSolanaChainListSync, isValidSolanaCluster, isValidSolanaCluster$1 as isValidSolanaClusterAsync, networksLinks, preloadChainAdapters, ukrainianLabels };
|