From 862edbf4d5fdb9a88f84bfa1d51ab8cc83896094 Mon Sep 17 00:00:00 2001 From: erdgeist Date: Thu, 13 Aug 2026 01:11:29 +0200 Subject: Give every admin page one horizontal gutter by many views inside. The inner ones are gone nodes#edit's becomes #body_field, which is what #edit_grid places in its full-width row. Rows now reach into the label band themselves rather than depending on a page wrapper to do it. The label column plus its gap equals the escape, so a row's content starts at the gutter on every page; #edit_grid's rows are exempt because the grid already steps back. share one left edge. #new_node's -118px was compensating for that 10px and left the page 7px out once it went. standalone_action_bar was overridden everywhere it appeared. page_translations#edit no longer uses #edit_grid: it has no metadata column, so the two-column template pushed its abstract into the empty half. nodes#edit's lower action bar was inside #edit_grid, so it was a grid item inheriting the escape and sat 125px left of the form above it. --- app/views/events/edit.html.erb | 24 ++++++++++++++++++++++-- app/views/events/new.html.erb | 24 +++++++++++++++++++++++- app/views/events/show.html.erb | 24 +++++++++++++++++++++--- 3 files changed, 66 insertions(+), 6 deletions(-) (limited to 'app/views/events') diff --git a/app/views/events/edit.html.erb b/app/views/events/edit.html.erb index f3bf5339..7c855760 100644 --- a/app/views/events/edit.html.erb +++ b/app/views/events/edit.html.erb @@ -1,6 +1,6 @@

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

-
+
<%= link_to t("admin.common.back"), safe_return_to(params[:return_to] || events_path) %> <%= button_to event_path(@event), method: :delete, form: { data: { confirm: t("events.confirm_delete") }, class: 'button_to destructive' } do %> @@ -13,7 +13,7 @@ <%= form_error_messages(f) %>
-
+
<%= Event.human_attribute_name(:node) %>
<% if @event.node %> @@ -31,39 +31,59 @@ <% end %> <%= f.hidden_field :node_id %>
+
+
<%= Event.human_attribute_name(:start_time) %>
<%= f.datetime_select :start_time %>
+
+
<%= Event.human_attribute_name(:end_time) %>
<%= f.datetime_select :end_time %>
+
+
<%= t("events.form.recurrence") %>
<%= render "rrule_builder", f: f %>
+
+
<%= Event.human_attribute_name(:title) %>
<%= f.text_field :title %> <%= t("events.form.title_hint") %>
+
+
<%= Event.human_attribute_name(:tags) %>
<%= f.text_field :tag_list %>
+
+
<%= Event.human_attribute_name(:allday) %>
<%= f.check_box :allday %>
+
+
<%= Event.human_attribute_name(:url) %>
<%= f.text_field :url %>
+
+
<%= Event.human_attribute_name(:latitude) %>
<%= f.text_field :latitude %>
+
+
<%= Event.human_attribute_name(:longitude) %>
<%= f.text_field :longitude %>
+
+
<%= f.submit t("admin.common.update") %>
diff --git a/app/views/events/new.html.erb b/app/views/events/new.html.erb index 3eaf7e7d..5cc47b69 100644 --- a/app/views/events/new.html.erb +++ b/app/views/events/new.html.erb @@ -6,7 +6,7 @@ <%= form_error_messages(f) %>
-
+
<%= Event.human_attribute_name(:node) %>
<%= text_field_tag :event_node_search_term %> @@ -14,40 +14,62 @@ <%= f.hidden_field :node_id %> <%= t("events.form.node_hint") %>
+
+
<%= Event.human_attribute_name(:start_time) %>
<%= f.datetime_select :start_time %>
+
+
<%= Event.human_attribute_name(:end_time) %>
<%= f.datetime_select :end_time %>
+
+
<%= t("events.form.recurrence") %>
<%= render "rrule_builder", f: f %>
+
+
<%= Event.human_attribute_name(:title) %>
<%= f.text_field :title %> <%= t("events.form.title_hint") %>
+
+
<%= Event.human_attribute_name(:tag_list) %>
<%= f.text_field :tag_list %>
+
+
<%= Event.human_attribute_name(:allday) %>
<%= f.check_box :allday %>
+
+
<%= Event.human_attribute_name(:url) %>
<%= f.text_field :url %>
+
+
<%= Event.human_attribute_name(:latitude) %>
<%= f.text_field :latitude %>
+
+
<%= Event.human_attribute_name(:longitude) %>
<%= f.text_field :longitude %>
+
+
<%= hidden_field_tag :return_to, params[:return_to] %>
+
+
<%= f.submit t("admin.common.create") %>
diff --git a/app/views/events/show.html.erb b/app/views/events/show.html.erb index d77f770e..2f3d315d 100644 --- a/app/views/events/show.html.erb +++ b/app/views/events/show.html.erb @@ -1,7 +1,7 @@

<%= @event.node ? t(".title_for_node", :path => @event.node.unique_name) : t(".title") %>

-
+
<%= t("admin.columns.actions") %>
@@ -22,33 +22,51 @@
+
+
<%= Event.human_attribute_name(:start_time) %>
<%= admin_datetime(@event.start_time) %>
+
+
<%= Event.human_attribute_name(:end_time) %>
<%= admin_datetime(@event.end_time) %>
+
+
<%= Event.human_attribute_name(:rrule) %>
<%=h @event.rrule %>
+
- <% if (human = @event.humanize_rrule(I18n.locale)) %> + <% if (human = @event.humanize_rrule(I18n.locale)) %> +
<%= t(".recurrence") %>
<%= human %>
- <% end %> +
+ <% end %> +
<%= Event.human_attribute_name(:tag_list) %>
<%=h @event.tag_list %>
+
+
<%= Event.human_attribute_name(:allday) %>
<%= @event.allday ? t("admin.common.yes") : t("admin.common.no") %>
+
+
<%= Event.human_attribute_name(:url) %>
<%=h @event.url %>
+
+
<%= Event.human_attribute_name(:latitude) %>
<%=h @event.latitude %>
+
+
<%= Event.human_attribute_name(:longitude) %>
<%=h @event.longitude %>
-- cgit v1.3