@gluwa/connect-kit 0.1.0-next.0 → 0.1.0-next.1
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/CHANGELOG.md +6 -0
- package/dist/index.d.ts +8 -3
- package/dist/index.js +333 -298
- package/dist/package.json +3 -1
- package/package.json +3 -1
- package/src/ConnectModal.tsx +79 -173
- package/src/components/QRFrame.tsx +43 -0
- package/src/creditConnectConnector.ts +61 -13
- package/src/hooks/useWCState.ts +150 -0
- package/src/hooks/useWagmiConnect.ts +68 -45
- package/src/index.ts +9 -1
- package/src/types.ts +8 -4
- package/src/views/CreditWalletView.tsx +4 -17
- package/src/views/MetaMaskView.tsx +5 -30
- package/src/views/WalletConnectView.tsx +10 -70
- package/tsup.config.ts +12 -1
- package/dist/_esm-PE6HOEBI.js +0 -3909
- package/dist/ccip-UBX2BH3T.js +0 -15
- package/dist/chunk-6KUZ225H.js +0 -5259
- package/dist/chunk-EVEWD66F.js +0 -447
- package/dist/chunk-U2IU7TQD.js +0 -45
- package/dist/secp256k1-FYSVLDVL.js +0 -2311
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -5,7 +5,12 @@ import { E2EEProvider } from '@gluwa/credit-connect-sdk/e2ee';
|
|
|
5
5
|
import { HubFactoryProvider } from '@gluwa/credit-connect-sdk/hub';
|
|
6
6
|
|
|
7
7
|
type ConnectorId = 'CREDIT_WALLET' | 'CREDIT_CONNECT' | 'METAMASK' | 'WALLET_CONNECT';
|
|
8
|
-
type
|
|
8
|
+
type CreditWalletStrategy = 'walletConnect' | 'creditConnect';
|
|
9
|
+
interface Connectors {
|
|
10
|
+
creditWallet?: CreditWalletStrategy | false;
|
|
11
|
+
metamask?: boolean;
|
|
12
|
+
walletConnect?: boolean;
|
|
13
|
+
}
|
|
9
14
|
interface WCWallet {
|
|
10
15
|
id: string;
|
|
11
16
|
name: string;
|
|
@@ -25,7 +30,7 @@ interface ConnectResult {
|
|
|
25
30
|
}
|
|
26
31
|
interface ConnectModalProps {
|
|
27
32
|
open: boolean;
|
|
28
|
-
connectors:
|
|
33
|
+
connectors: Connectors;
|
|
29
34
|
onConnect: (result: ConnectResult) => void;
|
|
30
35
|
onClose: () => void;
|
|
31
36
|
onLog?: (message: string, error?: Error) => void;
|
|
@@ -44,4 +49,4 @@ type CreditConnectConnectorOptions = {
|
|
|
44
49
|
};
|
|
45
50
|
declare const creditConnectConnector: (options: CreditConnectConnectorOptions) => ReturnType<typeof createConnector>;
|
|
46
51
|
|
|
47
|
-
export { ConnectModal, type ConnectModalProps, type ConnectResult, type ConnectorId, type CreditConnectConnectorOptions, type WCSubView, type WCWallet, creditConnectConnector };
|
|
52
|
+
export { ConnectModal, type ConnectModalProps, type ConnectResult, type ConnectorId, type Connectors, type CreditConnectConnectorOptions, type CreditWalletStrategy, type WCSubView, type WCWallet, creditConnectConnector };
|