@ledgerhq/live-common
Version:
Common ground for the Ledger Live apps
47 lines • 1.92 kB
TypeScript
import { AccountLike } from "@ledgerhq/types-live";
type Props = {
accounts: AccountLike[];
};
export declare function useSwapableAccounts({ accounts }: Props): ({
disabled: boolean;
type: "Account";
id: string;
seedIdentifier: string;
xpub?: string;
derivationMode: import("@ledgerhq/types-live").DerivationMode;
index: number;
freshAddress: string;
freshAddressPath: string;
used: boolean;
balance: import("bignumber.js").BigNumber;
spendableBalance: import("bignumber.js").BigNumber;
creationDate: Date;
blockHeight: number;
currency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
feesCurrency?: import("@ledgerhq/types-cryptoassets").CryptoCurrency | import("@ledgerhq/types-cryptoassets").TokenCurrency | undefined;
operationsCount: number;
operations: import("@ledgerhq/types-live").Operation[];
pendingOperations: import("@ledgerhq/types-live").Operation[];
lastSyncDate: Date;
subAccounts?: import("@ledgerhq/types-live").TokenAccount[];
balanceHistoryCache: import("@ledgerhq/types-live").BalanceHistoryCache;
swapHistory: import("@ledgerhq/types-live").SwapOperation[];
syncHash?: string | undefined;
nfts?: import("@ledgerhq/types-live").ProtoNFT[];
} | {
disabled: boolean;
type: "TokenAccount";
id: string;
parentId: string;
token: import("@ledgerhq/types-cryptoassets").TokenCurrency;
balance: import("bignumber.js").BigNumber;
spendableBalance: import("bignumber.js").BigNumber;
creationDate: Date;
operationsCount: number;
operations: import("@ledgerhq/types-live").Operation[];
pendingOperations: import("@ledgerhq/types-live").Operation[];
balanceHistoryCache: import("@ledgerhq/types-live").BalanceHistoryCache;
swapHistory: import("@ledgerhq/types-live").SwapOperation[];
})[];
export {};
//# sourceMappingURL=useSwapableAccounts.d.ts.map