@ledgerhq/coin-filecoin
Version:
Ledger Filecoin Coin integration
22 lines • 1.33 kB
TypeScript
import { Account, Operation } from "@ledgerhq/types-live";
import type { Unit } from "@ledgerhq/types-cryptoassets";
import { BigNumber } from "bignumber.js";
import { BroadcastTransactionRequest, TransactionResponse, Transaction } from "../types";
import { GetAccountShape, AccountShapeInfo } from "@ledgerhq/coin-framework/bridge/jsHelpers";
export declare const getUnit: () => Unit;
export declare const processTxs: (txs: TransactionResponse[]) => TransactionResponse[];
export declare const mapTxToOps: (accountId: string, { address }: AccountShapeInfo) => (tx: TransactionResponse) => Operation[];
export declare const getAddress: (a: Account) => {
address: string;
derivationPath: string;
};
export declare const getTxToBroadcast: (operation: Operation, signature: string, rawData: Record<string, any>) => BroadcastTransactionRequest;
export declare const getAccountShape: GetAccountShape;
export declare const getSubAccount: (account: Account, tx: Transaction) => import("@ledgerhq/types-live").TokenAccount | null | undefined;
/**
* convert a value in a given unit to a normalized value
* For instance, for 1 BTC, valueFromUnit(1, btcUnit) returns 100000000
* @memberof countervalue
*/
export declare const valueFromUnit: (valueInUnit: BigNumber, unit: Unit) => BigNumber;
//# sourceMappingURL=utils.d.ts.map