@orderly.network/hooks 0.0.59 → 0.0.61
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/index.d.mts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -5
package/dist/index.d.mts
CHANGED
|
@@ -5,9 +5,9 @@ import * as _orderly_network_core from '@orderly.network/core';
|
|
|
5
5
|
import { Account, AccountState, ConfigStore, OrderlyKeyStore, getWalletAdapterFunc, IContract, EventEmitter } from '@orderly.network/core';
|
|
6
6
|
import * as react from 'react';
|
|
7
7
|
import react__default, { FC, PropsWithChildren } from 'react';
|
|
8
|
+
import { NetworkId, OrderSide, OrderEntity, API, WSMessage } from '@orderly.network/types';
|
|
8
9
|
export { default as useConstant } from 'use-constant';
|
|
9
10
|
import { WS } from '@orderly.network/net';
|
|
10
|
-
import { OrderSide, OrderEntity, API, WSMessage } from '@orderly.network/types';
|
|
11
11
|
import * as swr__internal from 'swr/_internal';
|
|
12
12
|
import * as swr_subscription from 'swr/subscription';
|
|
13
13
|
export * from 'use-debounce';
|
|
@@ -92,7 +92,7 @@ interface OrderlyContextState extends OrderlyAppConfig {
|
|
|
92
92
|
keyStore: OrderlyKeyStore;
|
|
93
93
|
getWalletAdapter: getWalletAdapterFunc;
|
|
94
94
|
contractManager: IContract;
|
|
95
|
-
networkId:
|
|
95
|
+
networkId: NetworkId;
|
|
96
96
|
brokerId: string;
|
|
97
97
|
onWalletConnect?: () => Promise<any>;
|
|
98
98
|
onWalletDisconnect?: () => Promise<any>;
|
|
@@ -285,7 +285,7 @@ type inputOptions = {
|
|
|
285
285
|
crossEnabled?: boolean;
|
|
286
286
|
wooSwapEnabled?: boolean;
|
|
287
287
|
};
|
|
288
|
-
declare const useChains: (networkId?:
|
|
288
|
+
declare const useChains: (networkId?: NetworkId, options?: inputOptions & SWRConfiguration) => any[];
|
|
289
289
|
|
|
290
290
|
declare const useChain: (token: string) => {
|
|
291
291
|
chains: API.Chain | null;
|
|
@@ -421,16 +421,16 @@ declare const useCrossSwap: () => {
|
|
|
421
421
|
address: string;
|
|
422
422
|
src: {
|
|
423
423
|
fromToken: string;
|
|
424
|
-
fromAmount:
|
|
424
|
+
fromAmount: bigint;
|
|
425
425
|
bridgeToken: string;
|
|
426
|
-
minBridgeAmount:
|
|
426
|
+
minBridgeAmount: bigint;
|
|
427
427
|
};
|
|
428
428
|
dst: {
|
|
429
429
|
chainId: string;
|
|
430
430
|
bridgedToken: string;
|
|
431
431
|
toToken: string;
|
|
432
|
-
minToAmount:
|
|
433
|
-
airdropNativeAmount:
|
|
432
|
+
minToAmount: bigint;
|
|
433
|
+
airdropNativeAmount: bigint;
|
|
434
434
|
};
|
|
435
435
|
}) => Promise<{} | undefined>;
|
|
436
436
|
loading: boolean;
|
package/dist/index.d.ts
CHANGED
|
@@ -5,9 +5,9 @@ import * as _orderly_network_core from '@orderly.network/core';
|
|
|
5
5
|
import { Account, AccountState, ConfigStore, OrderlyKeyStore, getWalletAdapterFunc, IContract, EventEmitter } from '@orderly.network/core';
|
|
6
6
|
import * as react from 'react';
|
|
7
7
|
import react__default, { FC, PropsWithChildren } from 'react';
|
|
8
|
+
import { NetworkId, OrderSide, OrderEntity, API, WSMessage } from '@orderly.network/types';
|
|
8
9
|
export { default as useConstant } from 'use-constant';
|
|
9
10
|
import { WS } from '@orderly.network/net';
|
|
10
|
-
import { OrderSide, OrderEntity, API, WSMessage } from '@orderly.network/types';
|
|
11
11
|
import * as swr__internal from 'swr/_internal';
|
|
12
12
|
import * as swr_subscription from 'swr/subscription';
|
|
13
13
|
export * from 'use-debounce';
|
|
@@ -92,7 +92,7 @@ interface OrderlyContextState extends OrderlyAppConfig {
|
|
|
92
92
|
keyStore: OrderlyKeyStore;
|
|
93
93
|
getWalletAdapter: getWalletAdapterFunc;
|
|
94
94
|
contractManager: IContract;
|
|
95
|
-
networkId:
|
|
95
|
+
networkId: NetworkId;
|
|
96
96
|
brokerId: string;
|
|
97
97
|
onWalletConnect?: () => Promise<any>;
|
|
98
98
|
onWalletDisconnect?: () => Promise<any>;
|
|
@@ -285,7 +285,7 @@ type inputOptions = {
|
|
|
285
285
|
crossEnabled?: boolean;
|
|
286
286
|
wooSwapEnabled?: boolean;
|
|
287
287
|
};
|
|
288
|
-
declare const useChains: (networkId?:
|
|
288
|
+
declare const useChains: (networkId?: NetworkId, options?: inputOptions & SWRConfiguration) => any[];
|
|
289
289
|
|
|
290
290
|
declare const useChain: (token: string) => {
|
|
291
291
|
chains: API.Chain | null;
|
|
@@ -421,16 +421,16 @@ declare const useCrossSwap: () => {
|
|
|
421
421
|
address: string;
|
|
422
422
|
src: {
|
|
423
423
|
fromToken: string;
|
|
424
|
-
fromAmount:
|
|
424
|
+
fromAmount: bigint;
|
|
425
425
|
bridgeToken: string;
|
|
426
|
-
minBridgeAmount:
|
|
426
|
+
minBridgeAmount: bigint;
|
|
427
427
|
};
|
|
428
428
|
dst: {
|
|
429
429
|
chainId: string;
|
|
430
430
|
bridgedToken: string;
|
|
431
431
|
toToken: string;
|
|
432
|
-
minToAmount:
|
|
433
|
-
airdropNativeAmount:
|
|
432
|
+
minToAmount: bigint;
|
|
433
|
+
airdropNativeAmount: bigint;
|
|
434
434
|
};
|
|
435
435
|
}) => Promise<{} | undefined>;
|
|
436
436
|
loading: boolean;
|