%# locals: (account:) %>
<% currency = Money::Currency.new(account.currency) %>
<%= render DS::FilledIcon.new(
variant: :text,
text: currency.symbol,
rounded: true,
size: "lg"
) %>
<%= tag.p t(".brokerage_cash"), class: "text-primary" %>
<%= tag.p account.currency, class: "text-secondary text-xs uppercase" %>
<% cash_weight = account.balance.zero? ? 0 : account.cash_balance / account.balance * 100 %>
<%= render "shared/progress_circle", progress: cash_weight %>
<%= tag.p number_to_percentage(cash_weight, precision: 1) %>
<%= tag.p "--", class: "text-secondary" %>
<%= tag.p format_money account.cash_balance_money %>
<%= tag.p "--", class: "text-secondary" %>