From 5cc6bba04023ad46f0d5121a428ef69ad6e7f54f Mon Sep 17 00:00:00 2001 From: Justin Starner Date: Thu, 4 Dec 2025 22:23:21 -0500 Subject: [PATCH] Move card deletion button to partial. --- app/views/cards/_delete.html.erb | 16 ++++++++++++++++ app/views/cards/_messages.html.erb | 17 +---------------- 2 files changed, 17 insertions(+), 16 deletions(-) create mode 100644 app/views/cards/_delete.html.erb diff --git a/app/views/cards/_delete.html.erb b/app/views/cards/_delete.html.erb new file mode 100644 index 000000000..5e6279478 --- /dev/null +++ b/app/views/cards/_delete.html.erb @@ -0,0 +1,16 @@ +
+ + +

Delete this card?

+

Are you sure you want to permanently delete this card?

+
+ + <%= button_to card_path(card), method: :delete, class: "btn txt-negative", data: { turbo_frame: "_top" } do %> + Delete card + <% end %> +
+
+
diff --git a/app/views/cards/_messages.html.erb b/app/views/cards/_messages.html.erb index d4f6a6400..a2784e72a 100644 --- a/app/views/cards/_messages.html.erb +++ b/app/views/cards/_messages.html.erb @@ -9,22 +9,7 @@ <% if Current.user.can_administer_card?(card) %> <% end %> <% end %>