import { getAccountCurrency } from "@ledgerhq/coin-framework/account/helpers";
import { useMemo } from "react";
import { useFetchCurrencyFrom } from "./v5";
export function useSwapableAccounts({ accounts }) {
    const { data: currenciesFrom } = useFetchCurrencyFrom();
    return useMemo(() => accounts.map(account => {
        return {
            ...account,
            disabled: !currenciesFrom?.includes(getAccountCurrency(account).id),
        };
    }), [currenciesFrom, accounts]);
}
//# sourceMappingURL=useSwapableAccounts.js.map