@ledgerhq/live-common
Version:
Common ground for the Ledger Live apps
11 lines • 434 B
JavaScript
export const createUseLeftAccountsModule = ({ useAccountData, accountsCount, }) => {
return function useLeftAccountsModule(params) {
const accountData = useAccountData(params);
return accountData.map(({ asset, label, count }) => ({
...asset,
leftElement: count > 0 ? accountsCount({ label }) : undefined,
count,
}));
};
};
//# sourceMappingURL=useLeftAccounts.js.map