<%= t(".accounts") %>

<%= icon( "refresh-cw", as_button: true, size: "sm", href: sync_all_accounts_path, disabled: Current.family.syncing?, frame: :_top ) %> <%= render DS::Link.new( text: "New account", href: new_account_path(return_to: accounts_path), variant: "primary", icon: "plus", frame: :modal ) %>
<% if @manual_accounts.empty? && @plaid_items.empty? && @simplefin_items.empty? && @lunchflow_items.empty? && @enable_banking_items.empty? && @coinstats_items.empty? %> <%= render "empty" %> <% else %>
<% if @plaid_items.any? %> <%= render @plaid_items.sort_by(&:created_at) %> <% end %> <% if @simplefin_items.any? %> <%= render @simplefin_items.sort_by(&:created_at) %> <% end %> <% if @lunchflow_items.any? %> <%= render @lunchflow_items.sort_by(&:created_at) %> <% end %> <% if @enable_banking_items.any? %> <%= render @enable_banking_items.sort_by(&:created_at) %> <% end %> <% if @coinstats_items.any? %> <%= render @coinstats_items.sort_by(&:created_at) %> <% end %> <% if @manual_accounts.any? %>
<%= render "accounts/index/manual_accounts", accounts: @manual_accounts %>
<% else %>
<% end %>
<% end %>