From 9a060c14dd57bf2c391fd9147b6354350fcb1b84 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 7 Nov 2025 12:30:22 +0000 Subject: [PATCH] UI: Move sharing controls to DaisyUI modal - Add Share Trip button under trip dates - Button displays 'Share Trip' or 'Manage Sharing' based on state - Convert sharing partial to use DaisyUI 4 modal dialog - Modal can be closed via X button, backdrop click, or ESC key - All sharing functionality remains intact within modal --- app/views/trips/_sharing.html.erb | 18 +++++++++++++----- app/views/trips/show.html.erb | 15 +++++++++++++-- 2 files changed, 26 insertions(+), 7 deletions(-) diff --git a/app/views/trips/_sharing.html.erb b/app/views/trips/_sharing.html.erb index 69437e5a..da6f0ccc 100644 --- a/app/views/trips/_sharing.html.erb +++ b/app/views/trips/_sharing.html.erb @@ -1,6 +1,10 @@ -
-
-

Share This Trip

+ + -
+ + diff --git a/app/views/trips/show.html.erb b/app/views/trips/show.html.erb index 07f45639..80aae143 100644 --- a/app/views/trips/show.html.erb +++ b/app/views/trips/show.html.erb @@ -11,10 +11,21 @@

<%= @trip.name %>

-

+

<%= human_date(@trip.started_at) %> - <%= human_date(@trip.ended_at) %>

+ + <%= render "trips/countries", trip: @trip, current_user: current_user, distance_unit: current_user.safe_settings.distance_unit %>
@@ -65,6 +76,6 @@
- + <%= render "trips/sharing", trip: @trip %>