UNPKG

@ledgerhq/live-common

Version:
22 lines 759 B
// TODO: to remove once live-app-sdk is depreciated and removed from LL const CAN_EDIT_FEES = true; const areFeesProvided = (tx) => !!tx.feePerByte; const convertToLiveTransaction = (tx) => { const hasFeesProvided = areFeesProvided(tx); const liveTx = { ...tx, amount: tx.amount, recipient: tx.recipient, feePerByte: tx.feePerByte, }; return hasFeesProvided ? { ...liveTx, feesStrategy: null } : liveTx; }; const getPlatformTransactionSignFlowInfos = (tx) => { return { canEditFees: CAN_EDIT_FEES, liveTx: convertToLiveTransaction(tx), hasFeesProvided: areFeesProvided(tx), }; }; export default { getPlatformTransactionSignFlowInfos }; //# sourceMappingURL=platformAdapter.js.map