@0xsquid/react-hooks 8.8.1-beta-wallet-verification.0 → 8.8.1-beta-canton-sigilry.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/dist/core/canton/cantonConnector.d.ts +39 -0
- package/dist/core/canton/cip103Client.d.ts +31 -0
- package/dist/core/client/index.d.ts +1 -0
- package/dist/core/connectors/bitcoin/wallets/keplr.d.ts +1 -2
- package/dist/core/connectors/bitcoin/wallets/unisat.d.ts +0 -3
- package/dist/core/connectors/xrpl/CrossMark.d.ts +0 -12
- package/dist/core/connectors/xrpl/Xaman.d.ts +0 -14
- package/dist/core/connectors/xrpl/XamanQr.d.ts +0 -20
- package/dist/core/connectors/xrpl/XrplMetamaskSnap.d.ts +0 -12
- package/dist/core/constants.d.ts +10 -0
- package/dist/core/providers/CantonProvider.d.ts +19 -0
- package/dist/core/types/bitcoin.d.ts +0 -1
- package/dist/core/types/canton.d.ts +74 -0
- package/dist/core/types/config.d.ts +0 -1
- package/dist/core/types/cosmos.d.ts +5 -0
- package/dist/core/types/event.d.ts +1 -4
- package/dist/core/types/index.d.ts +2 -3
- package/dist/core/types/solana.d.ts +1 -11
- package/dist/core/types/sui.d.ts +1 -2
- package/dist/core/types/wallet.d.ts +9 -6
- package/dist/core/types/xrpl.d.ts +0 -14
- package/dist/hooks/canton/useCanton.d.ts +2 -0
- package/dist/hooks/canton/useCantonWallets.d.ts +11 -0
- package/dist/hooks/chains/useSquidChains.d.ts +1 -0
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/store/useDepositAddressStore.d.ts +23 -5
- package/dist/hooks/store/useWalletStore.d.ts +0 -1
- package/dist/hooks/swap/useDepositAddress.d.ts +6 -7
- package/dist/hooks/tokens/useBalance.d.ts +8 -0
- package/dist/hooks/tokens/useNativeBalance.d.ts +1 -0
- package/dist/hooks/tokens/useSquidTokens.d.ts +1 -0
- package/dist/hooks/transaction/useDepositTransactionStatus.d.ts +25 -0
- package/dist/hooks/transaction/useSwapStatusQuery.d.ts +26 -0
- package/dist/hooks/wallet/useMultiChainWallet.d.ts +44 -18
- package/dist/hooks/wallet/useSigner.d.ts +2 -1
- package/dist/hooks/wallet/useWallet.d.ts +48 -18
- package/dist/{index-CtXS5uny.js → index-BZ1ZxK8k.js} +1508 -1459
- package/dist/index-BZ1ZxK8k.js.map +1 -0
- package/dist/{index-z1nGQX9p.js → index-eQxIgL4x.js} +1488 -1455
- package/dist/index-eQxIgL4x.js.map +1 -0
- package/dist/{index.es-D8CAnRf1.js → index.es-CZc85nJZ.js} +4 -3
- package/dist/index.es-CZc85nJZ.js.map +1 -0
- package/dist/{index.es-CBWh71yD.js → index.es-DiFxhvhE.js} +4 -3
- package/dist/index.es-DiFxhvhE.js.map +1 -0
- package/dist/index.esm.js +3 -2
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +8 -31
- package/dist/index.js.map +1 -1
- package/dist/{secretService-B2i6U8uo.js → secretService-CwlIAnvR.js} +4 -3
- package/dist/{secretService-B2i6U8uo.js.map → secretService-CwlIAnvR.js.map} +1 -1
- package/dist/{secretService-BFehLMb_.js → secretService-TBn1d8BS.js} +4 -3
- package/dist/{secretService-BFehLMb_.js.map → secretService-TBn1d8BS.js.map} +1 -1
- package/dist/server.d.ts +1 -1
- package/dist/server.esm.js +8 -1
- package/dist/server.esm.js.map +1 -1
- package/dist/server.js +8 -0
- package/dist/server.js.map +1 -1
- package/dist/services/external/index.d.ts +1 -1
- package/dist/services/external/xaman.d.ts +11 -31
- package/dist/services/index.d.ts +0 -2
- package/dist/services/internal/assetsService.d.ts +10 -1
- package/dist/services/internal/cantonService.d.ts +84 -0
- package/dist/services/internal/cantonTransferService.d.ts +115 -0
- package/dist/services/internal/eventService.d.ts +3 -3
- package/dist/services/internal/evmService.d.ts +0 -1
- package/dist/services/internal/transactionService.d.ts +5 -1
- package/dist/services/internal/walletService.d.ts +2 -0
- package/dist/{stellarService.client-yWCDuq6S.js → stellarService.client-C3sipgbj.js} +4 -3
- package/dist/{stellarService.client-D20h9JPG.js.map → stellarService.client-C3sipgbj.js.map} +1 -1
- package/dist/{stellarService.client-D20h9JPG.js → stellarService.client-C9xbRMTR.js} +4 -3
- package/dist/{stellarService.client-yWCDuq6S.js.map → stellarService.client-C9xbRMTR.js.map} +1 -1
- package/package.json +3 -2
- package/dist/core/connectors/xrpl/walletVerification.d.ts +0 -2
- package/dist/core/types/walletVerificationSignature/bitcoin.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/chainTypes.d.ts +0 -19
- package/dist/core/types/walletVerificationSignature/cosmos.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/evm.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/index.d.ts +0 -18
- package/dist/core/types/walletVerificationSignature/request.d.ts +0 -3
- package/dist/core/types/walletVerificationSignature/sharedResult.d.ts +0 -20
- package/dist/core/types/walletVerificationSignature/solana.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/stellar.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/sui.d.ts +0 -10
- package/dist/core/types/walletVerificationSignature/types.d.ts +0 -69
- package/dist/core/types/walletVerificationSignature/xrpl.d.ts +0 -12
- package/dist/core/types/walletVerificationSignature.d.ts +0 -1
- package/dist/hooks/wallet/useWalletVerificationSignature.d.ts +0 -22
- package/dist/hooks/wallet/walletVerification/signers/bitcoin.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/cosmos.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/evm.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/index.d.ts +0 -3
- package/dist/hooks/wallet/walletVerification/signers/solana.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/stellar.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/sui.d.ts +0 -2
- package/dist/hooks/wallet/walletVerification/signers/types.d.ts +0 -33
- package/dist/hooks/wallet/walletVerification/signers/xrpl.d.ts +0 -2
- package/dist/index-CtXS5uny.js.map +0 -1
- package/dist/index-z1nGQX9p.js.map +0 -1
- package/dist/index.es-CBWh71yD.js.map +0 -1
- package/dist/index.es-D8CAnRf1.js.map +0 -1
- package/dist/services/internal/encodingService.d.ts +0 -8
- package/dist/services/internal/encodingService.test.d.ts +0 -1
- /package/dist/{hooks/wallet/useWalletVerificationSignature.test.d.ts → tests/cantonTransferService.test.d.ts} +0 -0
- /package/dist/{services/external/xaman.test.d.ts → tests/cip103Client.test.d.ts} +0 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { CantonAccount, CantonConnectResult, CantonConnector, CantonConnectorEvent, CantonLedgerApiParams, CantonPrepareExecuteAndWaitResult, CantonPrepareExecuteParams } from "../types/canton";
|
|
2
|
+
import { AnnouncedCantonProvider } from "./cip103Client";
|
|
3
|
+
type Handler = (...args: unknown[]) => void;
|
|
4
|
+
/**
|
|
5
|
+
* Browser-extension Canton connector: wraps one discovered CIP-103 provider
|
|
6
|
+
* (bound to its announce `target`) and exposes the lifecycle the per-chain
|
|
7
|
+
* hooks expect. The JSON-RPC transport and typed client come from
|
|
8
|
+
* `@sigilry/dapp`; Sigilry's generated types are kept internal to this file via
|
|
9
|
+
* boundary casts so {@link CantonConnector} stays the stable integration
|
|
10
|
+
* contract for the store/hooks. Browser event streaming is not part of phase 1,
|
|
11
|
+
* so `connect` and `disconnect` are emitted locally after the corresponding RPC.
|
|
12
|
+
*/
|
|
13
|
+
export declare class CantonBrowserConnector implements CantonConnector {
|
|
14
|
+
readonly providerId: string;
|
|
15
|
+
readonly name: string;
|
|
16
|
+
readonly target: string | undefined;
|
|
17
|
+
private readonly client;
|
|
18
|
+
private readonly listeners;
|
|
19
|
+
private _accounts;
|
|
20
|
+
constructor(provider: AnnouncedCantonProvider, win?: Window);
|
|
21
|
+
get accounts(): CantonAccount[];
|
|
22
|
+
get address(): string | undefined;
|
|
23
|
+
connect(): Promise<CantonConnectResult>;
|
|
24
|
+
/** Silent connect: read accounts without prompting; throws if not connected. */
|
|
25
|
+
autoConnect(): Promise<CantonConnectResult>;
|
|
26
|
+
disconnect(): Promise<void>;
|
|
27
|
+
signMessage(message: string): Promise<{
|
|
28
|
+
signature: string;
|
|
29
|
+
}>;
|
|
30
|
+
ledgerApi<T = unknown>(params: CantonLedgerApiParams): Promise<T>;
|
|
31
|
+
prepareExecute(params: CantonPrepareExecuteParams): Promise<null>;
|
|
32
|
+
prepareExecuteAndWait(params: CantonPrepareExecuteParams): Promise<CantonPrepareExecuteAndWaitResult>;
|
|
33
|
+
getAccounts(): Promise<CantonAccount[]>;
|
|
34
|
+
on(event: CantonConnectorEvent, handler: Handler): void;
|
|
35
|
+
off(event: CantonConnectorEvent, handler: Handler): void;
|
|
36
|
+
private emit;
|
|
37
|
+
private refreshAccounts;
|
|
38
|
+
}
|
|
39
|
+
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CIP-103 browser-wallet discovery.
|
|
3
|
+
*
|
|
4
|
+
* The JSON-RPC transport and typed client are provided by `@sigilry/dapp`
|
|
5
|
+
* (`WindowTransport` + `createCantonClient`). What lives here is the
|
|
6
|
+
* EIP-6963-style multi-wallet discovery layer, which `@sigilry/dapp` does not
|
|
7
|
+
* ship a helper for: the wallet dispatches `canton:announceProvider` and dApps
|
|
8
|
+
* dispatch `canton:requestProvider` to ask installed wallets to re-announce.
|
|
9
|
+
* Each announcement carries a `target` we route per-wallet through Sigilry's
|
|
10
|
+
* `WindowTransport`, so multiple extensions coexist without contending on the
|
|
11
|
+
* `window.canton` global (which is only a backward-compat surface).
|
|
12
|
+
*/
|
|
13
|
+
export declare const CANTON_REQUEST_PROVIDER_EVENT = "canton:requestProvider";
|
|
14
|
+
export declare const CANTON_ANNOUNCE_PROVIDER_EVENT = "canton:announceProvider";
|
|
15
|
+
export interface AnnouncedCantonProvider {
|
|
16
|
+
/** Stable identifier for the wallet/extension. */
|
|
17
|
+
id: string;
|
|
18
|
+
/** Display name for pickers. */
|
|
19
|
+
name: string;
|
|
20
|
+
/** Optional icon (data URL or https URL). */
|
|
21
|
+
icon?: string;
|
|
22
|
+
/** Routing key for the postMessage transport (defaults to `id`). */
|
|
23
|
+
target?: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Broadcast a provider request and collect the wallets that announce
|
|
27
|
+
* themselves within `timeoutMs`. Each compliant extension answers with a
|
|
28
|
+
* separate `canton:announceProvider` event, so this disambiguates multiple
|
|
29
|
+
* installed wallets (unlike reading `window.canton`).
|
|
30
|
+
*/
|
|
31
|
+
export declare function discoverCantonProviders(timeoutMs?: number, win?: Window): Promise<AnnouncedCantonProvider[]>;
|
|
@@ -13,6 +13,7 @@ type ChainTypeToClient = {
|
|
|
13
13
|
[ChainType.SUI]: SuiClient;
|
|
14
14
|
[ChainType.XRPL]: XrplRpcClient;
|
|
15
15
|
[ChainType.STELLAR]: StellarRpcClient;
|
|
16
|
+
[ChainType.CANTON]: null;
|
|
16
17
|
};
|
|
17
18
|
export declare function getClient<T extends ChainType>(chain: ChainData): Promise<ChainTypeToClient[T]>;
|
|
18
19
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { IBitcoinProvider as KeplrBitcoinProvider } from "@keplr-wallet/types";
|
|
2
2
|
import { BitcoinConnector } from "../../../../core/types/bitcoin";
|
|
3
3
|
export declare class KeplrConnector implements BitcoinConnector {
|
|
4
4
|
get getProvider(): KeplrBitcoinProvider;
|
|
@@ -8,5 +8,4 @@ export declare class KeplrConnector implements BitcoinConnector {
|
|
|
8
8
|
requestAccount(): Promise<{
|
|
9
9
|
address: string;
|
|
10
10
|
}>;
|
|
11
|
-
signMessage(message: string): Promise<string>;
|
|
12
11
|
}
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { BitcoinConnector } from "../../../../core/types/bitcoin";
|
|
2
|
-
declare const UNISAT_BIP322_SIMPLE_SIGNATURE_TYPE: "bip322-simple";
|
|
3
2
|
interface UnisatProvider {
|
|
4
3
|
sendBitcoin: (to: string, amount: number) => Promise<string>;
|
|
5
4
|
requestAccounts: () => Promise<string[]>;
|
|
6
|
-
signMessage?: (message: string, type?: typeof UNISAT_BIP322_SIMPLE_SIGNATURE_TYPE) => Promise<string>;
|
|
7
5
|
}
|
|
8
6
|
export declare class UnisatConnector implements BitcoinConnector {
|
|
9
7
|
get getProvider(): UnisatProvider;
|
|
@@ -13,6 +11,5 @@ export declare class UnisatConnector implements BitcoinConnector {
|
|
|
13
11
|
requestAccount(): Promise<{
|
|
14
12
|
address: string;
|
|
15
13
|
}>;
|
|
16
|
-
signMessage(message: string): Promise<string>;
|
|
17
14
|
}
|
|
18
15
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { WalletVerificationSignatureType } from "../../types/walletVerificationSignature";
|
|
2
1
|
import { XrplConnector, XrplNetwork, XrplTransaction } from "../../types/xrpl";
|
|
3
2
|
export declare class CrossmarkConnector implements XrplConnector {
|
|
4
3
|
private getProvider;
|
|
@@ -10,16 +9,5 @@ export declare class CrossmarkConnector implements XrplConnector {
|
|
|
10
9
|
hash: string;
|
|
11
10
|
status: string;
|
|
12
11
|
}>;
|
|
13
|
-
signOwnershipMessage({ address, message, }: {
|
|
14
|
-
address: string;
|
|
15
|
-
message: string;
|
|
16
|
-
}): Promise<{
|
|
17
|
-
signedPayload: string;
|
|
18
|
-
signedPayloadEncoding: "utf8-hex";
|
|
19
|
-
signature: string;
|
|
20
|
-
publicKey: string;
|
|
21
|
-
publicKeyEncoding: "hex";
|
|
22
|
-
signatureType: WalletVerificationSignatureType.XRPL;
|
|
23
|
-
}>;
|
|
24
12
|
private getActiveNetwork;
|
|
25
13
|
}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import type { Xumm } from "xumm";
|
|
2
|
-
import { WalletVerificationSignatureType } from "../../types/walletVerificationSignature";
|
|
3
2
|
import { XrplConnector, XrplNetwork, XrplTransaction } from "../../types/xrpl";
|
|
4
3
|
export declare class XamanConnector implements XrplConnector {
|
|
5
4
|
xumm: Xumm | null;
|
|
6
5
|
private validateXummInitialized;
|
|
7
6
|
private initializeXumm;
|
|
8
|
-
private runPayloadFlow;
|
|
9
7
|
connect(): Promise<string>;
|
|
10
8
|
signAndSubmit({ network, tx, }: {
|
|
11
9
|
tx: XrplTransaction;
|
|
@@ -14,16 +12,4 @@ export declare class XamanConnector implements XrplConnector {
|
|
|
14
12
|
hash: string;
|
|
15
13
|
status: string;
|
|
16
14
|
}>;
|
|
17
|
-
signOwnershipMessage({ address, message, }: {
|
|
18
|
-
address: string;
|
|
19
|
-
message: string;
|
|
20
|
-
}): Promise<{
|
|
21
|
-
signedPayload: string;
|
|
22
|
-
signedPayloadEncoding: "utf8-hex" | "xrpl-tx-hex";
|
|
23
|
-
signature?: string | undefined;
|
|
24
|
-
publicKey?: string | undefined;
|
|
25
|
-
publicKeyEncoding?: "hex" | undefined;
|
|
26
|
-
signatureType: WalletVerificationSignatureType.XRPL | WalletVerificationSignatureType.XAMAN;
|
|
27
|
-
signerAddress?: string | undefined;
|
|
28
|
-
}>;
|
|
29
15
|
}
|
|
@@ -1,17 +1,9 @@
|
|
|
1
|
-
import { XamanClient } from "../../../services/external/xaman";
|
|
2
|
-
import { WalletVerificationSignatureType } from "../../types/walletVerificationSignature";
|
|
3
1
|
import { XrplConnector, XrplNetwork, XrplTransaction } from "../../types/xrpl";
|
|
4
2
|
export declare class XamanQrConnector implements XrplConnector {
|
|
5
|
-
private readonly xamanClient;
|
|
6
3
|
cancelConnectQr: (() => void) | null;
|
|
7
4
|
cancelSignAndSubmitQr: (() => void) | null;
|
|
8
|
-
cancelSignOwnershipQr: (() => void) | null;
|
|
9
|
-
constructor(xamanClient?: XamanClient);
|
|
10
5
|
cancelConnect(): void;
|
|
11
6
|
cancelSignAndSubmit(): void;
|
|
12
|
-
cancelSignOwnershipMessage(): void;
|
|
13
|
-
private getPayloadId;
|
|
14
|
-
private runQrFlow;
|
|
15
7
|
connect(): Promise<string>;
|
|
16
8
|
signAndSubmit({ tx, network, }: {
|
|
17
9
|
tx: XrplTransaction;
|
|
@@ -20,16 +12,4 @@ export declare class XamanQrConnector implements XrplConnector {
|
|
|
20
12
|
hash: string;
|
|
21
13
|
status: string;
|
|
22
14
|
}>;
|
|
23
|
-
signOwnershipMessage({ address, message, }: {
|
|
24
|
-
address: string;
|
|
25
|
-
message: string;
|
|
26
|
-
}): Promise<{
|
|
27
|
-
signedPayload: string;
|
|
28
|
-
signedPayloadEncoding: "utf8-hex" | "xrpl-tx-hex";
|
|
29
|
-
signature?: string | undefined;
|
|
30
|
-
publicKey?: string | undefined;
|
|
31
|
-
publicKeyEncoding?: "hex" | undefined;
|
|
32
|
-
signatureType: WalletVerificationSignatureType.XRPL | WalletVerificationSignatureType.XAMAN;
|
|
33
|
-
signerAddress?: string | undefined;
|
|
34
|
-
}>;
|
|
35
15
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { EIP6963AnnounceProviderEvent, EIP6963RequestProviderEvent } from "@metamask/providers";
|
|
2
|
-
import { WalletVerificationSignatureType } from "../../types/walletVerificationSignature";
|
|
3
2
|
import { XrplConnector, XrplNetwork, XrplTransaction } from "../../types/xrpl";
|
|
4
3
|
declare enum EIP6963EventNames {
|
|
5
4
|
Announce = "eip6963:announceProvider",
|
|
@@ -21,17 +20,6 @@ export declare class XrplMetamaskSnapConnector implements XrplConnector {
|
|
|
21
20
|
hash: string;
|
|
22
21
|
status: string;
|
|
23
22
|
}>;
|
|
24
|
-
signOwnershipMessage({ address, message, }: {
|
|
25
|
-
address: string;
|
|
26
|
-
message: string;
|
|
27
|
-
}): Promise<{
|
|
28
|
-
signedPayload: string;
|
|
29
|
-
signedPayloadEncoding: "utf8-hex";
|
|
30
|
-
signature: string;
|
|
31
|
-
publicKey: string;
|
|
32
|
-
publicKeyEncoding: "hex";
|
|
33
|
-
signatureType: WalletVerificationSignatureType.XRPL;
|
|
34
|
-
}>;
|
|
35
23
|
private initialize;
|
|
36
24
|
private requestSnap;
|
|
37
25
|
private getAccount;
|
package/dist/core/constants.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ export declare const nativeBitcoinTokenAddress = "satoshi";
|
|
|
21
21
|
export declare const nativeSuiTokenAddress = "0x0000000000000000000000000000000000000000000000000000000000000002::sui::SUI";
|
|
22
22
|
export declare const nativeXrplTokenAddress = "xrp";
|
|
23
23
|
export declare const nativeStellarTokenAddress = "CAS3J7GYLGXMF6TDJBBYYSE3HQ6BBSMLNUQ34T6TZMYMW2EVH34XOWMA";
|
|
24
|
+
export declare const nativeCantonTokenAddress = "DSO::1220b1431ef217342db44d516bb9befde802be7d8899637d290895fa58880f19accc";
|
|
24
25
|
export declare const defaultSlippage: SlippageOption;
|
|
25
26
|
export declare const destinationAddressResetValue = "null";
|
|
26
27
|
export declare const fallbackAddressResetValue = "null";
|
|
@@ -32,6 +33,14 @@ export declare const DEFAULT_ROUTE_REFETCH_INTERVAL = 30000;
|
|
|
32
33
|
export declare const SOLANA_RPC_URL = "https://meredith-ute2ko-fast-mainnet.helius-rpc.com";
|
|
33
34
|
export declare const INTEGRATOR_ID = "squid-widget-playground-local-cd33cba6-7e12-4fcc-8d5d-35e286f655ea";
|
|
34
35
|
export declare const DEFAULT_COUNTRY_CODE = "US";
|
|
36
|
+
/**
|
|
37
|
+
* Default Canton Coin (Amulet) token-standard registry base — Squid's public
|
|
38
|
+
* validator scan-proxy. CIP-056 tokens (e.g. USDCx/CBTC) resolve their
|
|
39
|
+
* registrar from the admin party.
|
|
40
|
+
*
|
|
41
|
+
* TODO: pointing at localhost for now — swap in the real registry URL once ready.
|
|
42
|
+
*/
|
|
43
|
+
export declare const CANTON_AMULET_REGISTRY_URL = "http://localhost:5000/api/validator/v0/scan-proxy";
|
|
35
44
|
export declare const CHAIN_IDS: {
|
|
36
45
|
readonly OSMOSIS: "osmosis-1";
|
|
37
46
|
readonly INJECTIVE: "injective-1";
|
|
@@ -80,6 +89,7 @@ export declare const CHAIN_IDS: {
|
|
|
80
89
|
readonly XRPL_TESTNET: "xrpl-testnet";
|
|
81
90
|
readonly STELLAR: "stellar-mainnet";
|
|
82
91
|
readonly STELLAR_TESTNET: "stellar-testnet";
|
|
92
|
+
readonly CANTON: "canton";
|
|
83
93
|
};
|
|
84
94
|
export declare const chainTypeToDefaultChainIdMap: Record<ChainType, string>;
|
|
85
95
|
export declare const chainTypeToNativeTokenAddressMap: Record<ChainType, string>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ChainType } from "@0xsquid/squid-types";
|
|
2
|
+
import { UseMutationResult } from "@tanstack/react-query";
|
|
3
|
+
import React, { ReactNode } from "react";
|
|
4
|
+
import { CantonConnector } from "../types/canton";
|
|
5
|
+
import { CantonWallet, ConnectWalletResult } from "../types/wallet";
|
|
6
|
+
export interface ICantonContextData {
|
|
7
|
+
connectCanton: UseMutationResult<ConnectWalletResult<ChainType.CANTON>, unknown, {
|
|
8
|
+
wallet: CantonWallet;
|
|
9
|
+
}, unknown>;
|
|
10
|
+
disconnectCanton: () => Promise<void>;
|
|
11
|
+
autoConnectCanton: () => Promise<void>;
|
|
12
|
+
signer: CantonConnector | undefined;
|
|
13
|
+
wallets: CantonWallet[];
|
|
14
|
+
}
|
|
15
|
+
export declare const CantonContext: React.Context<ICantonContextData | undefined>;
|
|
16
|
+
export declare const CantonProvider: React.FC<{
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
}>;
|
|
19
|
+
export declare const useCantonContext: () => ICantonContextData;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
export interface CantonLedgerApiParams {
|
|
2
|
+
requestMethod: "get" | "post" | "patch" | "put" | "delete";
|
|
3
|
+
resource: string;
|
|
4
|
+
body?: Record<string, unknown>;
|
|
5
|
+
query?: Record<string, unknown>;
|
|
6
|
+
path?: Record<string, unknown>;
|
|
7
|
+
}
|
|
8
|
+
export interface CantonAccount {
|
|
9
|
+
partyId: string;
|
|
10
|
+
primary?: boolean;
|
|
11
|
+
hint?: string;
|
|
12
|
+
namespace?: string;
|
|
13
|
+
networkId?: string;
|
|
14
|
+
}
|
|
15
|
+
/** A Daml command (CreateCommand or ExerciseCommand); shape is opaque to us. */
|
|
16
|
+
export type CantonCommand = Record<string, unknown>;
|
|
17
|
+
export interface CantonDisclosedContract {
|
|
18
|
+
templateId?: string;
|
|
19
|
+
contractId?: string;
|
|
20
|
+
createdEventBlob: string;
|
|
21
|
+
synchronizerId?: string;
|
|
22
|
+
}
|
|
23
|
+
/** Subset of the CIP-103 JsPrepareSubmissionRequest the dApp supplies. */
|
|
24
|
+
export interface CantonPrepareExecuteParams {
|
|
25
|
+
commandId?: string;
|
|
26
|
+
commands: CantonCommand[];
|
|
27
|
+
actAs?: string[];
|
|
28
|
+
readAs?: string[];
|
|
29
|
+
disclosedContracts?: CantonDisclosedContract[];
|
|
30
|
+
synchronizerId?: string;
|
|
31
|
+
}
|
|
32
|
+
export interface CantonPrepareExecuteAndWaitResult {
|
|
33
|
+
tx: {
|
|
34
|
+
status?: string;
|
|
35
|
+
commandId?: string;
|
|
36
|
+
payload?: {
|
|
37
|
+
updateId?: string;
|
|
38
|
+
completionOffset?: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
export interface CantonNetwork {
|
|
43
|
+
networkId?: string;
|
|
44
|
+
name?: string;
|
|
45
|
+
}
|
|
46
|
+
export type CantonConnectorEvent = "connect" | "disconnect";
|
|
47
|
+
export interface CantonConnectResult {
|
|
48
|
+
address: string;
|
|
49
|
+
accounts: CantonAccount[];
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* A connected Canton wallet, bound to a single discovered CIP-103 provider
|
|
53
|
+
* (identified by its announce `target`). Shaped to mirror the lifecycle the
|
|
54
|
+
* per-chain hooks expect (connect/autoConnect/disconnect/on/off + signer).
|
|
55
|
+
*/
|
|
56
|
+
export interface CantonConnector {
|
|
57
|
+
readonly providerId: string;
|
|
58
|
+
readonly name: string;
|
|
59
|
+
readonly target: string | undefined;
|
|
60
|
+
connect(): Promise<CantonConnectResult>;
|
|
61
|
+
autoConnect(): Promise<CantonConnectResult>;
|
|
62
|
+
disconnect(): Promise<void>;
|
|
63
|
+
signMessage(message: string): Promise<{
|
|
64
|
+
signature: string;
|
|
65
|
+
}>;
|
|
66
|
+
ledgerApi<T = unknown>(params: CantonLedgerApiParams): Promise<T>;
|
|
67
|
+
prepareExecute(params: CantonPrepareExecuteParams): Promise<null>;
|
|
68
|
+
prepareExecuteAndWait(params: CantonPrepareExecuteParams): Promise<CantonPrepareExecuteAndWaitResult>;
|
|
69
|
+
getAccounts(): Promise<CantonAccount[]>;
|
|
70
|
+
on(event: CantonConnectorEvent, handler: (...args: unknown[]) => void): void;
|
|
71
|
+
off(event: CantonConnectorEvent, handler: (...args: unknown[]) => void): void;
|
|
72
|
+
readonly accounts: CantonAccount[];
|
|
73
|
+
readonly address: string | undefined;
|
|
74
|
+
}
|
|
@@ -17,9 +17,6 @@ export interface QrCodeData {
|
|
|
17
17
|
matrix: Array<Array<boolean>>;
|
|
18
18
|
deepLinkUrl: string;
|
|
19
19
|
}
|
|
20
|
-
export type QrScannedAwaitingUserApprovalData = {
|
|
21
|
-
flow: "connect" | "sign";
|
|
22
|
-
};
|
|
23
20
|
export type SwapEventPayload = BaseSwapEventParams & {
|
|
24
21
|
quoteId: string;
|
|
25
22
|
txHash: string;
|
|
@@ -89,7 +86,7 @@ export interface WidgetEventMap {
|
|
|
89
86
|
qrCodeGeneratedForConnect: QrCodeData;
|
|
90
87
|
qrCodeGeneratedForSign: QrCodeData;
|
|
91
88
|
qrCodeGenerationFailedForSign: undefined;
|
|
92
|
-
|
|
89
|
+
qrTxScannedAwaitingUserApproval: undefined;
|
|
93
90
|
}
|
|
94
91
|
export type EventListenerFunction<T extends keyof WidgetEventMap> = (event: CustomEvent<WidgetEventMap[T]>) => void;
|
|
95
92
|
export {};
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
export type { AppConfig } from "./config";
|
|
2
2
|
export { SquidStatusErrorType, TransactionErrorType, type SquidRouteError, type SquidRouteErrorType, type SquidStatusError, } from "./error";
|
|
3
|
-
export type { QrCodeData
|
|
3
|
+
export type { QrCodeData } from "./event";
|
|
4
4
|
export * from "./history";
|
|
5
5
|
export type * from "./onramps/";
|
|
6
6
|
export type { SwapParams } from "./swap";
|
|
7
7
|
export type { Chain, Token, TrustLineAsset } from "./tokens";
|
|
8
8
|
export { AxelarStatusResponseType, SendTransactionStatus, TransactionStatus, type PatchedRouteActionResponse, type TransactionParams, } from "./transaction";
|
|
9
|
-
export type { AddressWithEns, BitcoinWallet, ConnectorID, CosmosWallet, EnsData, EnsSearchResult, FullAddressData, NetworkConfig, SolanaWallet, SupportedChain,
|
|
10
|
-
export * from "./walletVerificationSignature";
|
|
9
|
+
export type { AddressWithEns, BitcoinWallet, ConnectorID, CosmosWallet, EnsData, EnsSearchResult, FullAddressData, NetworkConfig, SolanaWallet, SupportedChain, Wallet, } from "./wallet";
|
|
11
10
|
export { XamanXrplNetwork } from "./xrpl";
|
|
@@ -1,12 +1,2 @@
|
|
|
1
|
-
import type { SolanaSignMessageMethod } from "@solana/wallet-standard-features";
|
|
2
1
|
import type { StandardWalletAdapter } from "@solana/wallet-standard-wallet-adapter-base";
|
|
3
|
-
|
|
4
|
-
export type SolanaConnector = StandardWalletAdapter & {
|
|
5
|
-
wallet: StandardWallet & {
|
|
6
|
-
features: StandardWallet["features"] & {
|
|
7
|
-
"solana:signMessage"?: {
|
|
8
|
-
signMessage: SolanaSignMessageMethod;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
};
|
|
2
|
+
export type SolanaConnector = StandardWalletAdapter;
|
package/dist/core/types/sui.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { StandardConnectInput, StandardEventsOnMethod,
|
|
1
|
+
import type { StandardConnectInput, StandardEventsOnMethod, SuiSignTransactionMethod, WalletAccount as SuiWalletAccount } from "@mysten/wallet-standard";
|
|
2
2
|
export interface SuiAccount {
|
|
3
3
|
account: SuiWalletAccount;
|
|
4
4
|
}
|
|
@@ -6,7 +6,6 @@ export type SuiConnector = {
|
|
|
6
6
|
connect: (params?: StandardConnectInput) => Promise<SuiAccount>;
|
|
7
7
|
on: StandardEventsOnMethod;
|
|
8
8
|
disconnect: () => Promise<void>;
|
|
9
|
-
signPersonalMessage?: SuiSignPersonalMessageMethod;
|
|
10
9
|
signTransaction: SuiSignTransactionMethod;
|
|
11
10
|
};
|
|
12
11
|
export interface SuiCoinBalance {
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { ChainType } from "@0xsquid/squid-types";
|
|
2
2
|
import { BitcoinConnector } from "./bitcoin";
|
|
3
|
+
import { CantonConnector } from "./canton";
|
|
4
|
+
import { CosmosConnector } from "./cosmos";
|
|
3
5
|
import { EvmConnector } from "./evm";
|
|
4
6
|
import { SolanaConnector } from "./solana";
|
|
5
7
|
import { StellarConnector } from "./stellar";
|
|
@@ -30,12 +32,7 @@ export declare enum WindowWalletFlag {
|
|
|
30
32
|
export type ConnectorID = "metamask" | "coinbase" | "walletConnect" | "keplr" | "cosmostation" | "leap" | "ctrl" | "bitget" | "rabby" | "okx" | "injected" | "trustwallet" | "exodus" | "rainbow" | "phantom" | "backpack" | "unisat" | "xrpl-metamask-snap" | "crossmark" | "xaman-xapp" | "xaman-qr" | "joey" | "girin" | "bifrost" | "brave" | "tokenpocket" | "nightly" | "cryptodotcom" | "freighter" | "xBull" | "lobstr" | "albedo" | "hanaWallet" | "hotWallet";
|
|
31
33
|
export type EvmWallet = Wallet & {
|
|
32
34
|
type: ChainType.EVM;
|
|
33
|
-
connector:
|
|
34
|
-
};
|
|
35
|
-
type CosmosConnector = () => {
|
|
36
|
-
id: string;
|
|
37
|
-
name: string;
|
|
38
|
-
provider: any;
|
|
35
|
+
connector: ConnectorByChainType[ChainType.EVM];
|
|
39
36
|
};
|
|
40
37
|
export type CosmosWallet = Wallet & {
|
|
41
38
|
type: ChainType.COSMOS;
|
|
@@ -61,6 +58,10 @@ export type StellarWallet = Wallet & {
|
|
|
61
58
|
type: ChainType.STELLAR;
|
|
62
59
|
connector: ConnectorByChainType[ChainType.STELLAR];
|
|
63
60
|
};
|
|
61
|
+
export type CantonWallet = Wallet & {
|
|
62
|
+
type: ChainType.CANTON;
|
|
63
|
+
connector: ConnectorByChainType[ChainType.CANTON];
|
|
64
|
+
};
|
|
64
65
|
export type SupportedChain = {
|
|
65
66
|
chainType: ChainType;
|
|
66
67
|
chains?: string[];
|
|
@@ -137,6 +138,7 @@ export interface ChainTypeToWalletState {
|
|
|
137
138
|
[ChainType.SUI]: BaseWalletState<SuiWallet> & SuiAccount;
|
|
138
139
|
[ChainType.XRPL]: BaseWalletState<XrplWallet>;
|
|
139
140
|
[ChainType.STELLAR]: BaseWalletState<StellarWallet>;
|
|
141
|
+
[ChainType.CANTON]: BaseWalletState<CantonWallet>;
|
|
140
142
|
}
|
|
141
143
|
interface ConnectorByChainType extends Record<ChainType, unknown> {
|
|
142
144
|
[ChainType.EVM]: EvmConnector;
|
|
@@ -146,5 +148,6 @@ interface ConnectorByChainType extends Record<ChainType, unknown> {
|
|
|
146
148
|
[ChainType.SUI]: SuiConnector;
|
|
147
149
|
[ChainType.XRPL]: XrplConnector;
|
|
148
150
|
[ChainType.STELLAR]: StellarConnector;
|
|
151
|
+
[ChainType.CANTON]: CantonConnector;
|
|
149
152
|
}
|
|
150
153
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { WalletVerificationSignatureType } from "./walletVerificationSignature";
|
|
2
1
|
interface IssuedCurrencyAmount {
|
|
3
2
|
currency: string;
|
|
4
3
|
issuer: string;
|
|
@@ -50,19 +49,6 @@ export type XrplEvents = {
|
|
|
50
49
|
export type XrplConnectorOnMethod = <E extends keyof XrplEvents>(event: E, listener: (event: XrplEvents[E]) => void) => () => void;
|
|
51
50
|
export interface XrplConnector {
|
|
52
51
|
connect: () => Promise<string>;
|
|
53
|
-
signOwnershipMessage?: (_: {
|
|
54
|
-
message: string;
|
|
55
|
-
address: string;
|
|
56
|
-
}) => Promise<{
|
|
57
|
-
signedPayload: string;
|
|
58
|
-
signedPayloadEncoding: "utf8-hex" | "xrpl-tx-hex";
|
|
59
|
-
signature?: string;
|
|
60
|
-
publicKey?: string;
|
|
61
|
-
publicKeyEncoding?: "hex";
|
|
62
|
-
signatureType: WalletVerificationSignatureType.XRPL | WalletVerificationSignatureType.XAMAN;
|
|
63
|
-
signerAddress?: string;
|
|
64
|
-
}>;
|
|
65
|
-
cancelSignOwnershipMessage?: () => void;
|
|
66
52
|
signAndSubmit: (_: {
|
|
67
53
|
tx: XrplTransaction;
|
|
68
54
|
network: XrplNetwork;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { CantonWallet } from "../../core/types/wallet";
|
|
2
|
+
/**
|
|
3
|
+
* Discovers Canton browser-extension wallets via the CIP-103 announce protocol
|
|
4
|
+
* (on mount and on window focus) and maps each to a {@link CantonWallet}.
|
|
5
|
+
*
|
|
6
|
+
* Connectors are cached by providerId so the same instance survives re-discovery
|
|
7
|
+
* — the wallet store holds a reference to the connector it connected with.
|
|
8
|
+
*/
|
|
9
|
+
export declare function useCantonWallets(): {
|
|
10
|
+
wallets: CantonWallet[];
|
|
11
|
+
};
|
|
@@ -12,6 +12,7 @@ export declare const useSquidChains: (direction?: SwapDirection) => {
|
|
|
12
12
|
suiChains: ChainData[];
|
|
13
13
|
xrplChains: ChainData[];
|
|
14
14
|
stellarChains: ChainData[];
|
|
15
|
+
cantonChains: ChainData[];
|
|
15
16
|
getChainType: (chainId?: string) => ChainType | undefined;
|
|
16
17
|
findChain: (chainId: string | undefined) => ChainData | undefined;
|
|
17
18
|
};
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -37,6 +37,7 @@ export { useSendTransaction } from "./transaction/send/useSendTransaction";
|
|
|
37
37
|
export { useSendTransactionGas } from "./transaction/send/useSendTransactionGas";
|
|
38
38
|
export { useAllTransactionsStatus } from "./transaction/useAllTransactionsStatus";
|
|
39
39
|
export { useApproval } from "./transaction/useApproval";
|
|
40
|
+
export { useDepositTransactionStatus } from "./transaction/useDepositTransactionStatus";
|
|
40
41
|
export { useEstimate } from "./transaction/useEstimate";
|
|
41
42
|
export { useEstimatePriceImpact } from "./transaction/useEstimatePriceImpact";
|
|
42
43
|
export { useExecuteTransaction } from "./transaction/useExecuteTransaction";
|
|
@@ -55,6 +56,5 @@ export { useIntegratorContext } from "./wallet/useIntegratorContext";
|
|
|
55
56
|
export { useMultiChainWallet } from "./wallet/useMultiChainWallet";
|
|
56
57
|
export { useSigner } from "./wallet/useSigner";
|
|
57
58
|
export { useWallet } from "./wallet/useWallet";
|
|
58
|
-
export { WalletVerificationSignatureError, WalletVerificationSignatureErrorCode, WalletVerificationSignatureType, buildBitcoinWalletVerificationSignatureResult, buildCosmosWalletVerificationSignatureResult, buildSolanaWalletVerificationSignatureResult, buildStellarWalletVerificationSignatureResult, buildSuiWalletVerificationSignatureResult, buildWalletVerificationSignatureResult, buildXrplWalletVerificationSignatureResult, useWalletVerificationSignature, type WalletVerificationSignatureRequest, type WalletVerificationSignatureResult, } from "./wallet/useWalletVerificationSignature";
|
|
59
59
|
export { useWallets } from "./wallet/useWallets";
|
|
60
60
|
export { useXrplTrustLine } from "./xrpl/useXrplTrustLine";
|
|
@@ -1,9 +1,27 @@
|
|
|
1
|
-
|
|
1
|
+
export interface DepositData {
|
|
2
|
+
depositAddress: string;
|
|
3
|
+
amount: string;
|
|
4
|
+
/**
|
|
5
|
+
* Identifier sent to backend to check for deposit status
|
|
6
|
+
*/
|
|
7
|
+
statusTrackingId: string;
|
|
8
|
+
/**
|
|
9
|
+
* Memo to be sent with the deposit transaction on-chain
|
|
10
|
+
* Used by backend to track and index deposits
|
|
11
|
+
*/
|
|
12
|
+
memo?: string;
|
|
13
|
+
}
|
|
14
|
+
export type PaymentMethod = "connectedWallet" | "depositAddress";
|
|
2
15
|
interface DepositAddressStore {
|
|
3
|
-
deposit:
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
16
|
+
deposit: DepositData | null;
|
|
17
|
+
/**
|
|
18
|
+
* Raw user intent — which payment method the user picked.
|
|
19
|
+
* NOT whether deposit is actually usable on the current source chain;
|
|
20
|
+
* that is derived in `useDepositAddress` via `isDepositAddressActive`.
|
|
21
|
+
*/
|
|
22
|
+
selectedPaymentMethod: PaymentMethod;
|
|
23
|
+
setDeposit(data: DepositData | null): void;
|
|
24
|
+
setPaymentMethod(method: PaymentMethod): void;
|
|
7
25
|
}
|
|
8
26
|
export declare const useDepositAddressStore: import("zustand").UseBoundStore<import("zustand").StoreApi<DepositAddressStore>>;
|
|
9
27
|
export {};
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import { RouteResponse } from "@0xsquid/squid-types";
|
|
2
|
+
import { PaymentMethod } from "../store/useDepositAddressStore";
|
|
2
3
|
export declare function useDepositAddress(squidRoute?: RouteResponse["route"]): {
|
|
3
|
-
|
|
4
|
+
paymentMethod: PaymentMethod;
|
|
5
|
+
isDepositAddressActive: boolean;
|
|
4
6
|
isAvailableAsPaymentMethod: boolean;
|
|
5
7
|
swapWillGenerateDepositAddress: boolean;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
getRouteWithDeposit: import("@tanstack/react-query").UseMutationResult<{
|
|
9
|
-
depositAddress: import("@0xsquid/squid-types").ChainflipDepositAddressResponse;
|
|
10
|
-
}, unknown, {
|
|
8
|
+
setPaymentMethod: (method: PaymentMethod) => void;
|
|
9
|
+
getRouteWithDeposit: import("@tanstack/react-query").UseMutationResult<void, unknown, {
|
|
11
10
|
route: RouteResponse["route"];
|
|
12
11
|
}, unknown>;
|
|
13
12
|
depositAddress: string | undefined;
|
|
14
13
|
closeDepositChannel: () => void;
|
|
15
|
-
depositData: import("
|
|
14
|
+
depositData: import("../store/useDepositAddressStore").DepositData | null;
|
|
16
15
|
};
|
|
@@ -12,6 +12,14 @@ interface UseBalanceOptions {
|
|
|
12
12
|
}
|
|
13
13
|
export declare const useEvmBalance: ({ chain, token, userAddress, enabled, refreshIntervalMs, }: UseBalanceOptions) => UseBalanceResult;
|
|
14
14
|
export declare const useCosmosBalance: ({ chain, token, userAddress, enabled, refreshIntervalMs, }: UseBalanceOptions) => UseBalanceResult;
|
|
15
|
+
/**
|
|
16
|
+
* Canton balances are private: they can only be read with a wallet-authorized
|
|
17
|
+
* `ledgerApi` session (the connected wallet supplies a JWT that can read as the
|
|
18
|
+
* party). So balance is fetchable only when a Canton wallet is connected, and
|
|
19
|
+
* only for that wallet's party — there's no address-only read, and the
|
|
20
|
+
* deposit-address flow (no wallet) cannot show a balance.
|
|
21
|
+
*/
|
|
22
|
+
export declare const useCantonBalance: ({ chain, token, userAddress, enabled, refreshIntervalMs, }: UseBalanceOptions) => UseBalanceResult;
|
|
15
23
|
export declare const useSolanaBalance: ({ chain, token, userAddress, enabled, refreshIntervalMs, }: UseBalanceOptions) => UseBalanceResult;
|
|
16
24
|
export declare const useBitcoinBalance: ({ userAddress, chain, }: UseBalanceOptions) => UseBalanceResult;
|
|
17
25
|
export declare const useSuiBalance: ({ chain, token, userAddress, enabled, refreshIntervalMs, }: UseBalanceOptions) => UseBalanceResult;
|
|
@@ -18,6 +18,7 @@ export declare const useSolanaNativeBalance: ({ chain, address, }: UseNativeBala
|
|
|
18
18
|
export declare const useSuiNativeBalance: ({ address, chain, }: UseNativeBalanceOptions) => UseNativeBalanceResult;
|
|
19
19
|
export declare const useXrplNativeBalance: ({ address, chain, }: UseNativeBalanceOptions) => UseNativeBalanceResult;
|
|
20
20
|
export declare const useStellarNativeBalance: ({ address, chain, }: UseNativeBalanceOptions) => UseNativeBalanceResult;
|
|
21
|
+
export declare const useCantonNativeBalance: ({ address, chain, }: UseNativeBalanceOptions) => UseNativeBalanceResult;
|
|
21
22
|
export declare const useNativeBalance: (chain?: ChainData) => {
|
|
22
23
|
nativeBalance: Balance | undefined;
|
|
23
24
|
nativeBalanceFormatted: string | undefined;
|