@0xsquid/react-hooks 8.0.7-hedera-beta.0 → 8.0.7-hedera-beta.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.
Files changed (27) hide show
  1. package/dist/core/connectors/evm/hederaWalletConnect.d.ts +30 -0
  2. package/dist/core/types/hedera.d.ts +26 -0
  3. package/dist/core/wagmiConfig.d.ts +2 -1
  4. package/dist/{index-C0H64ktj.js → index-B1UmFH6o.js} +456 -55
  5. package/dist/index-B1UmFH6o.js.map +1 -0
  6. package/dist/{index-DFAgGls6.js → index-Dhrvhjd5.js} +454 -57
  7. package/dist/index-Dhrvhjd5.js.map +1 -0
  8. package/dist/index.es-DdiQVjv_.js +43 -0
  9. package/dist/index.es-DdiQVjv_.js.map +1 -0
  10. package/dist/index.es-cLBJjjrp.js +50 -0
  11. package/dist/index.es-cLBJjjrp.js.map +1 -0
  12. package/dist/index.esm.js +1 -1
  13. package/dist/index.js +2 -1
  14. package/dist/index.js.map +1 -1
  15. package/dist/{secretService-DX3NE6Of.js → secretService-BtCjIhQz.js} +2 -2
  16. package/dist/{secretService-DX3NE6Of.js.map → secretService-BtCjIhQz.js.map} +1 -1
  17. package/dist/{secretService-D7gPw0fs.js → secretService-DIqBnH3p.js} +2 -2
  18. package/dist/{secretService-D7gPw0fs.js.map → secretService-DIqBnH3p.js.map} +1 -1
  19. package/dist/services/external/hederaApiClient.d.ts +18 -0
  20. package/dist/services/internal/hederaService.d.ts +44 -0
  21. package/dist/{stellarService.client-peMOjG49.js → stellarService.client-CM5m8Px4.js} +2 -2
  22. package/dist/{stellarService.client-peMOjG49.js.map → stellarService.client-CM5m8Px4.js.map} +1 -1
  23. package/dist/{stellarService.client-Cr3lD8Iw.js → stellarService.client-DSH90-FO.js} +2 -2
  24. package/dist/{stellarService.client-Cr3lD8Iw.js.map → stellarService.client-DSH90-FO.js.map} +1 -1
  25. package/package.json +2 -1
  26. package/dist/index-C0H64ktj.js.map +0 -1
  27. package/dist/index-DFAgGls6.js.map +0 -1
@@ -0,0 +1,30 @@
1
+ import { type Address, type ProviderConnectInfo } from "viem";
2
+ import { WalletConnectParameters } from "wagmi/connectors";
3
+ import { HederaExtensionData } from "../../../services/internal/hederaService";
4
+ export type HederaWalletConnectParameters = WalletConnectParameters & {
5
+ extension: HederaExtensionData;
6
+ };
7
+ /**
8
+ * Wagmi connector to interact with the Hedera EVM network via the WalletConnect protocol.
9
+ *
10
+ * The connector removes the need for a WalletConnect modal, and instead
11
+ * communicates with the provided `extension` by opening the extension popup
12
+ * for user interaction upon request.
13
+ */
14
+ export declare function hederaWalletConnect(parameters: HederaWalletConnectParameters): import("@wagmi/core").CreateConnectorFn<import("@walletconnect/ethereum-provider").default, {
15
+ connect(parameters?: {
16
+ chainId?: number;
17
+ pairingTopic?: string;
18
+ }): Promise<{
19
+ accounts: readonly Address[];
20
+ chainId: number;
21
+ }>;
22
+ onConnect(connectInfo: ProviderConnectInfo): void;
23
+ onDisplayUri(uri: string): void;
24
+ onSessionDelete(data: {
25
+ topic: string;
26
+ }): void;
27
+ }, Record<string, unknown>>;
28
+ export declare namespace hederaWalletConnect {
29
+ var type: "hederaWalletConnect";
30
+ }
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Account info from the Hedera Mirrornode API
3
+ */
4
+ export interface AccountInfo {
5
+ balance: {
6
+ balance: number;
7
+ tokens: {
8
+ token_id: string;
9
+ balance: number;
10
+ }[];
11
+ };
12
+ max_automatic_token_associations: number;
13
+ }
14
+ /**
15
+ * Account tokens info from the Hedera Mirrornode API
16
+ */
17
+ export interface AccountTokens {
18
+ tokens: {
19
+ /**
20
+ * When true, indicates the token was automatically associated,
21
+ * using one of the account's available auto-association slots.
22
+ */
23
+ automatic_association: boolean;
24
+ token_id: string;
25
+ }[];
26
+ }
@@ -2,5 +2,6 @@ import { ChainData } from "@0xsquid/squid-types";
2
2
  import { JsonRpcSigner } from "ethers";
3
3
  import { type Account, type Chain, type Client, type Transport } from "viem";
4
4
  import { Config } from "wagmi";
5
- export declare const createWagmiConfig: (squidChains: ChainData[]) => Config;
5
+ import { HederaExtensionData } from "../services/internal/hederaService";
6
+ export declare const createWagmiConfig: (squidChains: ChainData[], hederaExtensions: HederaExtensionData[]) => Config;
6
7
  export declare function clientToSigner(client: Client<Transport, Chain, Account>): JsonRpcSigner | undefined;