@btc-vision/walletconnect 1.0.1 → 1.0.3

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.
@@ -1,17 +1,20 @@
1
1
  import { Network } from '@btc-vision/bitcoin';
2
2
  import { Address, Unisat, UnisatSigner } from '@btc-vision/transaction';
3
- import { JSONRpcProvider } from 'opnet';
3
+ import { AbstractRpcProvider } from 'opnet';
4
4
  export declare enum SupportedWallets {
5
- OP_WALLET = "op_wallet"
5
+ OP_WALLET = "op_wallet",
6
+ UNISAT = "unisat"
6
7
  }
7
8
  export type Signers = UnisatSigner;
8
9
  export type Wallets = Unisat;
9
10
  export declare class WalletConnection {
10
11
  signer: Signers | null;
12
+ walletType: SupportedWallets | null;
13
+ walletWindowInstance: Wallets | null;
11
14
  connect(walletType: SupportedWallets): Promise<void>;
12
15
  disconnect(): void;
13
16
  getAddress(): Promise<Address>;
14
17
  getNetwork(): Promise<Network>;
15
- getProvider(): Promise<JSONRpcProvider>;
18
+ getProvider(): Promise<AbstractRpcProvider>;
16
19
  }
17
20
  export default WalletConnection;
@@ -1,16 +1,18 @@
1
1
  import { Network } from '@btc-vision/bitcoin';
2
2
  import { Address } from '@btc-vision/transaction';
3
- import { JSONRpcProvider } from 'opnet';
3
+ import { AbstractRpcProvider } from 'opnet';
4
4
  import React from 'react';
5
- import { Signers, SupportedWallets } from './WalletConnection';
5
+ import { Signers, SupportedWallets, Wallets } from './WalletConnection';
6
6
  interface WalletContextType {
7
7
  connect: (walletType: SupportedWallets) => Promise<void>;
8
8
  disconnect: () => void;
9
- address: Address | null;
9
+ isConnected: boolean;
10
10
  signer: Signers | null;
11
+ walletType: SupportedWallets | null;
12
+ walletWindowInstance: Wallets | null;
13
+ address: Address | null;
11
14
  network: Network | null;
12
- provider: JSONRpcProvider | null;
13
- isConnected: boolean;
15
+ provider: AbstractRpcProvider | null;
14
16
  }
15
17
  export declare const WalletProvider: React.FC<{
16
18
  children: React.ReactNode;