1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-06 14:05:20 +02:00

Move categories to top-level namespace (#894)

This commit is contained in:
Zach Gollwitzer 2024-06-20 08:15:09 -04:00 committed by GitHub
parent a947db92b2
commit 2681dd96b1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
48 changed files with 229 additions and 223 deletions

View file

@ -0,0 +1,28 @@
<% content_for :sidebar do %>
<%= render "settings/nav" %>
<% end %>
<section class="space-y-4">
<header class="flex items-center justify-between">
<h1 class="text-gray-900 text-xl font-medium"><%= t(".categories") %></h1>
<%= link_to new_category_path, class: "rounded-lg bg-gray-900 text-white flex items-center gap-1 justify-center hover:bg-gray-700 px-3 py-2", data: { turbo_frame: :modal } do %>
<%= lucide_icon "plus", class: "w-5 h-5" %>
<p><%= t(".new") %></p>
<% end %>
</header>
<div class="bg-white shadow-xs border border-alpha-black-25 rounded-xl p-4">
<div class="rounded-xl bg-gray-25 p-1">
<h2 class="uppercase px-4 py-2 text-gray-500 text-xs"><%= t(".categories") %> · <%= @categories.size %></h2>
<div class="border border-alpha-gray-100 rounded-lg bg-white shadow-xs">
<%= render collection: @categories, partial: "categories/row" %>
</div>
</div>
</div>
<footer class="flex justify-between gap-4">
<%= previous_setting("Tags", tags_path) %>
<%= next_setting("Merchants", transaction_merchants_path) %>
</footer>
</section>