Skip to content

Commit

Permalink
Make roasters edit and delete buttons have same style as shot
Browse files Browse the repository at this point in the history
  • Loading branch information
miharekar committed Dec 20, 2024
1 parent da44246 commit 6287d0f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/views/roasters/_roaster.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="flex border-l border-neutral-200 dark:border-neutral-700">
<div class="flex flex-col w-full -mt-px divide-y divide-neutral-200 dark:divide-neutral-700">
<div class="relative flex flex-1 dark:hover:bg-neutral-800/25 hover:bg-neutral-100/25">
<div class="relative flex grow dark:hover:bg-neutral-800/25 hover:bg-neutral-100/25">
<%= link_to edit_roaster_path(roaster), class: "flex items-center p-4 text-sm border border-transparent gap-x-3" do %>
<span class="absolute inset-x-0 bottom-0 -top-px"></span>
<svg class="w-4 h-4 text-neutral-500 dark:text-neutral-300" fill="currentColor" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
Expand All @@ -52,10 +52,10 @@
Edit
<% end %>
</div>
<div class="relative flex flex-1 dark:hover:bg-red-900/25 hover:bg-red-100/25">
<%= link_to roaster_path(roaster), class: "flex items-center p-4 text-sm border border-transparent gap-x-3", data: {turbo_method: :delete, action: "click->modal#confirm", title: "Delete #{roaster.name}", text: "Are you sure you want to permanently delete this roaster with #{pluralize(roaster.coffee_bags.count, "coffee bag")}? This action cannot be undone."} do %>
<div class="relative flex hover:bg-red-500/10">
<%= link_to roaster_path(roaster), class: "flex items-center px-4 py-3 text-sm border border-transparent gap-x-3 text-neutral-400 dark:text-neutral-500", data: {turbo_method: :delete, action: "click->modal#confirm", title: "Delete #{roaster.name}", text: "Are you sure you want to permanently delete this roaster with #{pluralize(roaster.coffee_bags.count, "coffee bag")}? This action cannot be undone."} do %>
<span class="absolute inset-x-0 bottom-0 -top-px"></span>
<svg class="w-4 h-4 text-neutral-500 dark:text-neutral-300" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="currentColor">
<svg class="w-4 h-4 text-neutral-400 dark:text-neutral-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="currentColor">
<path fill-rule="evenodd" d="M5 3.25V4H2.75a.75.75 0 0 0 0 1.5h.3l.815 8.15A1.5 1.5 0 0 0 5.357 15h5.285a1.5 1.5 0 0 0 1.493-1.35l.815-8.15h.3a.75.75 0 0 0 0-1.5H11v-.75A2.25 2.25 0 0 0 8.75 1h-1.5A2.25 2.25 0 0 0 5 3.25Zm2.25-.75a.75.75 0 0 0-.75.75V4h3v-.75a.75.75 0 0 0-.75-.75h-1.5ZM6.05 6a.75.75 0 0 1 .787.713l.275 5.5a.75.75 0 0 1-1.498.075l-.275-5.5A.75.75 0 0 1 6.05 6Zm3.9 0a.75.75 0 0 1 .712.787l-.275 5.5a.75.75 0 0 1-1.498-.075l.275-5.5a.75.75 0 0 1 .786-.711Z" clip-rule="evenodd" />
</svg>
Delete
Expand Down

0 comments on commit 6287d0f

Please sign in to comment.