@txnlab/use-wallet 0.1.23 → 1.0.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/README.md +252 -94
- package/dist/cjs/algod/index.d.ts +3 -2
- package/dist/cjs/clients/algosigner/client.d.ts +35 -0
- package/dist/cjs/clients/algosigner/constants.d.ts +2 -0
- package/dist/cjs/clients/algosigner/index.d.ts +2 -0
- package/dist/cjs/clients/algosigner/types.d.ts +40 -0
- package/dist/{esm/clients → cjs/clients/base}/base.d.ts +12 -25
- package/dist/cjs/clients/base/index.d.ts +2 -0
- package/dist/cjs/clients/defly/client.d.ts +37 -0
- package/dist/cjs/clients/defly/constants.d.ts +1 -0
- package/dist/cjs/clients/defly/index.d.ts +2 -0
- package/dist/cjs/clients/defly/types.d.ts +36 -0
- package/dist/cjs/clients/exodus/client.d.ts +33 -0
- package/dist/cjs/clients/exodus/constants.d.ts +1 -0
- package/dist/cjs/clients/exodus/index.d.ts +2 -0
- package/dist/cjs/clients/exodus/types.d.ts +40 -0
- package/dist/cjs/clients/index.d.ts +11 -15
- package/dist/cjs/clients/kmd/client.d.ts +29 -0
- package/dist/cjs/clients/kmd/constants.d.ts +1 -0
- package/dist/cjs/clients/kmd/index.d.ts +2 -0
- package/dist/cjs/clients/kmd/types.d.ts +38 -0
- package/dist/cjs/clients/{myalgowallet.d.ts → myalgo/client.d.ts} +14 -17
- package/dist/cjs/clients/myalgo/constants.d.ts +1 -0
- package/dist/cjs/clients/myalgo/index.d.ts +2 -0
- package/dist/cjs/clients/myalgo/types.d.ts +23 -0
- package/dist/cjs/clients/pera/client.d.ts +35 -0
- package/dist/cjs/clients/pera/constants.d.ts +1 -0
- package/dist/cjs/clients/pera/index.d.ts +2 -0
- package/dist/cjs/clients/pera/types.d.ts +36 -0
- package/dist/cjs/clients/walletconnect/client.d.ts +37 -0
- package/dist/cjs/clients/walletconnect/constants.d.ts +2 -0
- package/dist/cjs/clients/walletconnect/index.d.ts +2 -0
- package/dist/cjs/clients/walletconnect/types.d.ts +54 -0
- package/dist/cjs/constants/constants.d.ts +12 -16
- package/dist/cjs/hooks/index.d.ts +0 -1
- package/dist/cjs/hooks/useWallet.d.ts +140 -8
- package/dist/cjs/index.d.ts +4 -2
- package/dist/cjs/index.js +736 -739
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/store/index.d.ts +1 -0
- package/dist/cjs/store/state/clientStore.d.ts +22 -0
- package/dist/cjs/types/node.d.ts +3 -0
- package/dist/cjs/types/wallet.d.ts +2 -2
- package/dist/cjs/utils/index.d.ts +2 -2
- package/dist/cjs/utils/initializeProviders.d.ts +13 -0
- package/dist/cjs/utils/reconnectProviders.d.ts +6 -0
- package/dist/esm/algod/index.d.ts +3 -2
- package/dist/esm/clients/algosigner/client.d.ts +35 -0
- package/dist/esm/clients/algosigner/constants.d.ts +2 -0
- package/dist/esm/clients/algosigner/index.d.ts +2 -0
- package/dist/esm/clients/algosigner/types.d.ts +40 -0
- package/dist/{cjs/clients → esm/clients/base}/base.d.ts +12 -25
- package/dist/esm/clients/base/index.d.ts +2 -0
- package/dist/esm/clients/defly/client.d.ts +37 -0
- package/dist/esm/clients/defly/constants.d.ts +1 -0
- package/dist/esm/clients/defly/index.d.ts +2 -0
- package/dist/esm/clients/defly/types.d.ts +36 -0
- package/dist/esm/clients/exodus/client.d.ts +33 -0
- package/dist/esm/clients/exodus/constants.d.ts +1 -0
- package/dist/esm/clients/exodus/index.d.ts +2 -0
- package/dist/esm/clients/exodus/types.d.ts +40 -0
- package/dist/esm/clients/index.d.ts +11 -15
- package/dist/esm/clients/kmd/client.d.ts +29 -0
- package/dist/esm/clients/kmd/constants.d.ts +1 -0
- package/dist/esm/clients/kmd/index.d.ts +2 -0
- package/dist/esm/clients/kmd/types.d.ts +38 -0
- package/dist/esm/clients/{myalgowallet.d.ts → myalgo/client.d.ts} +14 -17
- package/dist/esm/clients/myalgo/constants.d.ts +1 -0
- package/dist/esm/clients/myalgo/index.d.ts +2 -0
- package/dist/esm/clients/myalgo/types.d.ts +23 -0
- package/dist/esm/clients/pera/client.d.ts +35 -0
- package/dist/esm/clients/pera/constants.d.ts +1 -0
- package/dist/esm/clients/pera/index.d.ts +2 -0
- package/dist/esm/clients/pera/types.d.ts +36 -0
- package/dist/esm/clients/walletconnect/client.d.ts +37 -0
- package/dist/esm/clients/walletconnect/constants.d.ts +2 -0
- package/dist/esm/clients/walletconnect/index.d.ts +2 -0
- package/dist/esm/clients/walletconnect/types.d.ts +54 -0
- package/dist/esm/constants/constants.d.ts +12 -16
- package/dist/esm/hooks/index.d.ts +0 -1
- package/dist/esm/hooks/useWallet.d.ts +140 -8
- package/dist/esm/index.d.ts +4 -2
- package/dist/esm/index.js +724 -730
- package/dist/esm/store/index.d.ts +1 -0
- package/dist/esm/store/state/clientStore.d.ts +22 -0
- package/dist/esm/types/node.d.ts +3 -0
- package/dist/esm/types/wallet.d.ts +2 -2
- package/dist/esm/utils/index.d.ts +2 -2
- package/dist/esm/utils/initializeProviders.d.ts +13 -0
- package/dist/esm/utils/reconnectProviders.d.ts +6 -0
- package/dist/index.d.ts +669 -66
- package/package.json +2 -2
- package/dist/cjs/clients/algosigner.d.ts +0 -62
- package/dist/cjs/clients/defly.d.ts +0 -51
- package/dist/cjs/clients/exodus.d.ts +0 -52
- package/dist/cjs/clients/kmd.d.ts +0 -31
- package/dist/cjs/clients/perawallet.d.ts +0 -47
- package/dist/cjs/clients/walletconnect.d.ts +0 -47
- package/dist/cjs/hooks/useConnectWallet.d.ts +0 -30
- package/dist/cjs/providers/algosigner.d.ts +0 -2
- package/dist/cjs/providers/defly.d.ts +0 -2
- package/dist/cjs/providers/exodus.d.ts +0 -2
- package/dist/cjs/providers/index.d.ts +0 -9
- package/dist/cjs/providers/kmd.d.ts +0 -2
- package/dist/cjs/providers/myalgowallet.d.ts +0 -2
- package/dist/cjs/providers/perawallet.d.ts +0 -2
- package/dist/cjs/providers/walletconnect.d.ts +0 -2
- package/dist/esm/clients/algosigner.d.ts +0 -62
- package/dist/esm/clients/defly.d.ts +0 -51
- package/dist/esm/clients/exodus.d.ts +0 -52
- package/dist/esm/clients/kmd.d.ts +0 -31
- package/dist/esm/clients/perawallet.d.ts +0 -47
- package/dist/esm/clients/walletconnect.d.ts +0 -47
- package/dist/esm/hooks/useConnectWallet.d.ts +0 -30
- package/dist/esm/providers/algosigner.d.ts +0 -2
- package/dist/esm/providers/defly.d.ts +0 -2
- package/dist/esm/providers/exodus.d.ts +0 -2
- package/dist/esm/providers/index.d.ts +0 -9
- package/dist/esm/providers/kmd.d.ts +0 -2
- package/dist/esm/providers/myalgowallet.d.ts +0 -2
- package/dist/esm/providers/perawallet.d.ts +0 -2
- package/dist/esm/providers/walletconnect.d.ts +0 -2
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type _algosdk from "algosdk";
|
|
2
|
+
import type { PeraWalletConnect } from "@perawallet/connect";
|
|
3
|
+
import type { Transaction } from "algosdk";
|
|
4
|
+
import type { AlgodClientOptions, Network } from "../../types";
|
|
5
|
+
export declare type ClientOptions = {
|
|
6
|
+
bridge?: string;
|
|
7
|
+
deep_link?: string;
|
|
8
|
+
app_meta?: {
|
|
9
|
+
logo: string;
|
|
10
|
+
name: string;
|
|
11
|
+
main_color: string;
|
|
12
|
+
};
|
|
13
|
+
shouldShowSignTxnToast?: boolean;
|
|
14
|
+
};
|
|
15
|
+
export interface PeraTransaction {
|
|
16
|
+
txn: Transaction;
|
|
17
|
+
/**
|
|
18
|
+
* Optional list of addresses that must sign the transactions.
|
|
19
|
+
* Wallet skips to sign this txn if signers is empty array.
|
|
20
|
+
* If undefined, wallet tries to sign it.
|
|
21
|
+
*/
|
|
22
|
+
signers?: string[];
|
|
23
|
+
}
|
|
24
|
+
export declare type PeraWalletClientConstructor = {
|
|
25
|
+
client: PeraWalletConnect;
|
|
26
|
+
algosdk: typeof _algosdk;
|
|
27
|
+
algodClient: _algosdk.Algodv2;
|
|
28
|
+
network: Network;
|
|
29
|
+
};
|
|
30
|
+
export declare type InitParams = {
|
|
31
|
+
clientOptions?: ClientOptions;
|
|
32
|
+
algodOptions?: AlgodClientOptions;
|
|
33
|
+
clientStatic?: typeof PeraWalletConnect;
|
|
34
|
+
algosdkStatic?: typeof _algosdk;
|
|
35
|
+
network?: Network;
|
|
36
|
+
};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { Wallet } from "../../types";
|
|
2
|
+
import { PROVIDER_ID } from "../../constants";
|
|
3
|
+
import BaseWallet from "../base";
|
|
4
|
+
import { TransactionsArray, Network } from "../../types";
|
|
5
|
+
import { WalletConnectClientConstructor, InitParams, WalletConnectTransaction } from "./types";
|
|
6
|
+
declare class WalletConnectClient extends BaseWallet {
|
|
7
|
+
#private;
|
|
8
|
+
network: Network;
|
|
9
|
+
constructor({ client, algosdk, algodClient, network, }: WalletConnectClientConstructor);
|
|
10
|
+
static metadata: {
|
|
11
|
+
id: PROVIDER_ID;
|
|
12
|
+
name: string;
|
|
13
|
+
icon: string;
|
|
14
|
+
isWalletConnect: boolean;
|
|
15
|
+
};
|
|
16
|
+
static init({ clientOptions, algodOptions, clientStatic, modalStatic, algosdkStatic, network, }: InitParams): Promise<WalletConnectClient | null>;
|
|
17
|
+
connect(): Promise<Wallet>;
|
|
18
|
+
reconnect(): Promise<{
|
|
19
|
+
accounts: {
|
|
20
|
+
name: string;
|
|
21
|
+
address: string;
|
|
22
|
+
providerId: PROVIDER_ID;
|
|
23
|
+
}[];
|
|
24
|
+
id: PROVIDER_ID;
|
|
25
|
+
name: string;
|
|
26
|
+
icon: string;
|
|
27
|
+
isWalletConnect: boolean;
|
|
28
|
+
} | null>;
|
|
29
|
+
check(): boolean;
|
|
30
|
+
disconnect(): Promise<void>;
|
|
31
|
+
signTransactions(connectedAccounts: string[], transactions: Uint8Array[]): Promise<Uint8Array[]>;
|
|
32
|
+
/** @deprecarted */
|
|
33
|
+
formatTransactionsArray(transactions: TransactionsArray): WalletConnectTransaction[];
|
|
34
|
+
/** @deprecated */
|
|
35
|
+
signEncodedTransactions(transactions: TransactionsArray): Promise<Uint8Array[]>;
|
|
36
|
+
}
|
|
37
|
+
export default WalletConnectClient;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type _algosdk from "algosdk";
|
|
2
|
+
import type WalletConnect from "@walletconnect/client";
|
|
3
|
+
import QRCodeModal from "algorand-walletconnect-qrcode-modal";
|
|
4
|
+
import type { AlgodClientOptions, Network } from "../../types";
|
|
5
|
+
export interface IClientMeta {
|
|
6
|
+
description: string;
|
|
7
|
+
url: string;
|
|
8
|
+
icons: string[];
|
|
9
|
+
name: string;
|
|
10
|
+
}
|
|
11
|
+
export interface IWalletConnectSession {
|
|
12
|
+
connected: boolean;
|
|
13
|
+
accounts: string[];
|
|
14
|
+
chainId: number;
|
|
15
|
+
bridge: string;
|
|
16
|
+
key: string;
|
|
17
|
+
clientId: string;
|
|
18
|
+
clientMeta: IClientMeta | null;
|
|
19
|
+
peerId: string;
|
|
20
|
+
peerMeta: IClientMeta | null;
|
|
21
|
+
handshakeId: number;
|
|
22
|
+
handshakeTopic: string;
|
|
23
|
+
qrcodeModal: {
|
|
24
|
+
open: (uri: string, cb: any, qrcodeModalOptions?: any) => void;
|
|
25
|
+
close: () => void;
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export declare type ClientOptions = {
|
|
29
|
+
bridge?: string;
|
|
30
|
+
uri?: string;
|
|
31
|
+
storageId?: string;
|
|
32
|
+
signingMethods?: string[];
|
|
33
|
+
session?: IWalletConnectSession;
|
|
34
|
+
clientMeta?: IClientMeta;
|
|
35
|
+
};
|
|
36
|
+
export declare type WalletConnectTransaction = {
|
|
37
|
+
txn: string;
|
|
38
|
+
message?: string;
|
|
39
|
+
signers?: string[] | [];
|
|
40
|
+
};
|
|
41
|
+
export declare type InitParams = {
|
|
42
|
+
clientOptions?: ClientOptions;
|
|
43
|
+
algodOptions?: AlgodClientOptions;
|
|
44
|
+
clientStatic?: typeof WalletConnect;
|
|
45
|
+
modalStatic?: typeof QRCodeModal;
|
|
46
|
+
algosdkStatic?: typeof _algosdk;
|
|
47
|
+
network?: Network;
|
|
48
|
+
};
|
|
49
|
+
export declare type WalletConnectClientConstructor = {
|
|
50
|
+
client: WalletConnect;
|
|
51
|
+
algosdk: typeof _algosdk;
|
|
52
|
+
algodClient: _algosdk.Algodv2;
|
|
53
|
+
network: Network;
|
|
54
|
+
};
|
|
@@ -1,18 +1,14 @@
|
|
|
1
|
+
import { Network } from "../types";
|
|
1
2
|
export declare enum PROVIDER_ID {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
DEFLY = "
|
|
7
|
-
EXODUS = "
|
|
8
|
-
|
|
3
|
+
KMD = "kmd",
|
|
4
|
+
PERA = "pera",
|
|
5
|
+
MYALGO = "myalgo",
|
|
6
|
+
ALGOSIGNER = "algosigner",
|
|
7
|
+
DEFLY = "defly",
|
|
8
|
+
EXODUS = "exodus",
|
|
9
|
+
WALLETCONNECT = "walletconnect"
|
|
9
10
|
}
|
|
10
|
-
export declare const
|
|
11
|
-
export declare const
|
|
12
|
-
export declare const
|
|
13
|
-
export declare const
|
|
14
|
-
export declare const KMD_HOST: string;
|
|
15
|
-
export declare const KMD_TOKEN: string;
|
|
16
|
-
export declare const KMD_PORT: string;
|
|
17
|
-
export declare const KMD_WALLET: string;
|
|
18
|
-
export declare const KMD_PASSWORD: string;
|
|
11
|
+
export declare const DEFAULT_NETWORK: Network;
|
|
12
|
+
export declare const DEFAULT_NODE_BASEURL = "https://mainnet-api.algonode.cloud";
|
|
13
|
+
export declare const DEFAULT_NODE_TOKEN = "";
|
|
14
|
+
export declare const DEFAULT_NODE_PORT = "";
|
|
@@ -1,21 +1,153 @@
|
|
|
1
1
|
import type algosdk from "algosdk";
|
|
2
|
-
import { PROVIDER_ID } from "../types";
|
|
3
|
-
import { TransactionsArray } from "../types";
|
|
2
|
+
import { PROVIDER_ID, TransactionsArray } from "../types";
|
|
4
3
|
export { PROVIDER_ID };
|
|
5
4
|
export default function useWallet(): {
|
|
6
|
-
|
|
5
|
+
clients: Partial<{
|
|
6
|
+
kmd: Promise<import("../clients/base/base").default | null>;
|
|
7
|
+
pera: Promise<import("../clients/base/base").default | null>;
|
|
8
|
+
myalgo: Promise<import("../clients/base/base").default | null>;
|
|
9
|
+
algosigner: Promise<import("../clients/base/base").default | null>;
|
|
10
|
+
defly: Promise<import("../clients/base/base").default | null>;
|
|
11
|
+
exodus: Promise<import("../clients/base/base").default | null>;
|
|
12
|
+
walletconnect: Promise<import("../clients/base/base").default | null>;
|
|
13
|
+
}> | null;
|
|
14
|
+
providers: ({
|
|
15
|
+
accounts: import("../types").Account[];
|
|
16
|
+
isActive: boolean;
|
|
17
|
+
isConnected: boolean;
|
|
18
|
+
connect: () => Promise<void>;
|
|
19
|
+
disconnect: () => Promise<void>;
|
|
20
|
+
reconnect: () => Promise<void>;
|
|
21
|
+
setActiveProvider: () => Promise<void>;
|
|
22
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
23
|
+
metadata: {
|
|
24
|
+
id: PROVIDER_ID;
|
|
25
|
+
name: string;
|
|
26
|
+
icon: string;
|
|
27
|
+
isWalletConnect: boolean;
|
|
28
|
+
};
|
|
29
|
+
} | {
|
|
30
|
+
accounts: import("../types").Account[];
|
|
31
|
+
isActive: boolean;
|
|
32
|
+
isConnected: boolean;
|
|
33
|
+
connect: () => Promise<void>;
|
|
34
|
+
disconnect: () => Promise<void>;
|
|
35
|
+
reconnect: () => Promise<void>;
|
|
36
|
+
setActiveProvider: () => Promise<void>;
|
|
37
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
38
|
+
metadata: {
|
|
39
|
+
id: PROVIDER_ID;
|
|
40
|
+
name: string;
|
|
41
|
+
icon: string;
|
|
42
|
+
isWalletConnect: boolean;
|
|
43
|
+
};
|
|
44
|
+
} | {
|
|
45
|
+
accounts: import("../types").Account[];
|
|
46
|
+
isActive: boolean;
|
|
47
|
+
isConnected: boolean;
|
|
48
|
+
connect: () => Promise<void>;
|
|
49
|
+
disconnect: () => Promise<void>;
|
|
50
|
+
reconnect: () => Promise<void>;
|
|
51
|
+
setActiveProvider: () => Promise<void>;
|
|
52
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
53
|
+
metadata: {
|
|
54
|
+
id: PROVIDER_ID;
|
|
55
|
+
name: string;
|
|
56
|
+
icon: string;
|
|
57
|
+
isWalletConnect: boolean;
|
|
58
|
+
};
|
|
59
|
+
} | {
|
|
60
|
+
accounts: import("../types").Account[];
|
|
61
|
+
isActive: boolean;
|
|
62
|
+
isConnected: boolean;
|
|
63
|
+
connect: () => Promise<void>;
|
|
64
|
+
disconnect: () => Promise<void>;
|
|
65
|
+
reconnect: () => Promise<void>;
|
|
66
|
+
setActiveProvider: () => Promise<void>;
|
|
67
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
68
|
+
metadata: {
|
|
69
|
+
id: PROVIDER_ID;
|
|
70
|
+
name: string;
|
|
71
|
+
icon: string;
|
|
72
|
+
isWalletConnect: boolean;
|
|
73
|
+
};
|
|
74
|
+
} | {
|
|
75
|
+
accounts: import("../types").Account[];
|
|
76
|
+
isActive: boolean;
|
|
77
|
+
isConnected: boolean;
|
|
78
|
+
connect: () => Promise<void>;
|
|
79
|
+
disconnect: () => Promise<void>;
|
|
80
|
+
reconnect: () => Promise<void>;
|
|
81
|
+
setActiveProvider: () => Promise<void>;
|
|
82
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
83
|
+
metadata: {
|
|
84
|
+
id: PROVIDER_ID;
|
|
85
|
+
name: string;
|
|
86
|
+
icon: string;
|
|
87
|
+
isWalletConnect: boolean;
|
|
88
|
+
};
|
|
89
|
+
} | {
|
|
90
|
+
accounts: import("../types").Account[];
|
|
91
|
+
isActive: boolean;
|
|
92
|
+
isConnected: boolean;
|
|
93
|
+
connect: () => Promise<void>;
|
|
94
|
+
disconnect: () => Promise<void>;
|
|
95
|
+
reconnect: () => Promise<void>;
|
|
96
|
+
setActiveProvider: () => Promise<void>;
|
|
97
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
98
|
+
metadata: {
|
|
99
|
+
id: PROVIDER_ID;
|
|
100
|
+
name: string;
|
|
101
|
+
icon: string;
|
|
102
|
+
isWalletConnect: boolean;
|
|
103
|
+
};
|
|
104
|
+
} | {
|
|
105
|
+
accounts: import("../types").Account[];
|
|
106
|
+
isActive: boolean;
|
|
107
|
+
isConnected: boolean;
|
|
108
|
+
connect: () => Promise<void>;
|
|
109
|
+
disconnect: () => Promise<void>;
|
|
110
|
+
reconnect: () => Promise<void>;
|
|
111
|
+
setActiveProvider: () => Promise<void>;
|
|
112
|
+
setActiveAccount: (account: string) => Promise<void>;
|
|
113
|
+
metadata: {
|
|
114
|
+
id: PROVIDER_ID;
|
|
115
|
+
name: string;
|
|
116
|
+
icon: string;
|
|
117
|
+
isWalletConnect: boolean;
|
|
118
|
+
};
|
|
119
|
+
})[] | null;
|
|
120
|
+
connectedAccounts: import("../types").Account[];
|
|
121
|
+
connectedActiveAccounts: import("../types").Account[];
|
|
7
122
|
activeAccount: import("../types").Account | null;
|
|
123
|
+
activeAddress: string | undefined;
|
|
8
124
|
signer: algosdk.TransactionSigner;
|
|
9
125
|
signTransactions: (transactions: Array<Uint8Array>) => Promise<Uint8Array[]>;
|
|
10
|
-
sendTransactions: (transactions: Uint8Array[], waitRoundsToConfirm?: number) => Promise<
|
|
11
|
-
|
|
126
|
+
sendTransactions: (transactions: Uint8Array[], waitRoundsToConfirm?: number) => Promise<{
|
|
127
|
+
"confirmed-round": number;
|
|
128
|
+
"global-state-delta": Record<string, unknown>[];
|
|
129
|
+
"pool-error": string;
|
|
130
|
+
txn: {
|
|
131
|
+
sig: Uint8Array;
|
|
132
|
+
txn: import("../types").Txn;
|
|
133
|
+
};
|
|
134
|
+
txId: string;
|
|
135
|
+
id: any;
|
|
12
136
|
}>;
|
|
13
137
|
getAddress: () => string | undefined;
|
|
14
|
-
groupTransactionsBySender: (transactions: TransactionsArray) => Promise<Record<string,
|
|
138
|
+
groupTransactionsBySender: (transactions: TransactionsArray) => Promise<Record<string, any>>;
|
|
15
139
|
getAccountInfo: () => Promise<import("../types").AccountInfo>;
|
|
16
140
|
getAssets: () => Promise<import("../types").Asset[]>;
|
|
17
141
|
signEncodedTransactions: (transactions: TransactionsArray) => Promise<Uint8Array[]>;
|
|
18
|
-
sendRawTransactions: (transactions: Uint8Array[], waitRoundsToConfirm?: number) => Promise<
|
|
19
|
-
|
|
142
|
+
sendRawTransactions: (transactions: Uint8Array[], waitRoundsToConfirm?: number) => Promise<{
|
|
143
|
+
"confirmed-round": number;
|
|
144
|
+
"global-state-delta": Record<string, unknown>[];
|
|
145
|
+
"pool-error": string;
|
|
146
|
+
txn: {
|
|
147
|
+
sig: Uint8Array;
|
|
148
|
+
txn: import("../types").Txn;
|
|
149
|
+
};
|
|
150
|
+
txId: string;
|
|
151
|
+
id: any;
|
|
20
152
|
}>;
|
|
21
153
|
};
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
export { useWallet } from "./hooks";
|
|
2
|
+
export { initializeProviders, reconnectProviders } from "./utils";
|
|
3
|
+
export { WalletProvider } from "./store";
|
|
1
4
|
export * from "./constants";
|
|
2
5
|
export * from "./types";
|
|
3
|
-
export * from "./
|
|
4
|
-
export * from "./utils";
|
|
6
|
+
export * from "./clients";
|