summaryrefslogtreecommitdiff
path: root/app/views/custom/partials/_chapter.html.erb
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-07-13 23:33:11 +0200
committererdgeist <erdgeist@erdgeist.org>2026-07-13 23:33:11 +0200
commit8eab68f2c5a3c126e2fec2ecdfa7ace87ce0937b (patch)
treef446ebc26a7707c7b64a937aa51a155df146c80a /app/views/custom/partials/_chapter.html.erb
parent42714c697273a7117c6b355fab26c8c35e336ad1 (diff)
parentcdf5d9941ca866d437612d2f863eac6eb0b3db12 (diff)
Merge branch 'erdgeist-revive-events'
Diffstat (limited to 'app/views/custom/partials/_chapter.html.erb')
-rw-r--r--app/views/custom/partials/_chapter.html.erb19
1 files changed, 19 insertions, 0 deletions
diff --git a/app/views/custom/partials/_chapter.html.erb b/app/views/custom/partials/_chapter.html.erb
new file mode 100644
index 0000000..805559b
--- /dev/null
+++ b/app/views/custom/partials/_chapter.html.erb
@@ -0,0 +1,19 @@
1<div class="article_partial chapter_partial" lang="<%= page.effective_lang %>">
2 <h2 class="headline"><%= link_to_path page.title, page.node.unique_name %></h2>
3 <% if page.abstract.present? %>
4 <div class="chapter_location"><%= page.abstract %></div>
5 <% end %>
6 <% if page.node.external_url.present? %>
7 <div class="chapter_url"><%= link_to page.node.external_url, page.node.external_url, target: '_blank', rel: 'noopener' %></div>
8 <% end %>
9 <% open_days = page.node.events.tagged_with('open-day').order(:start_time) %>
10 <% if open_days.any? %>
11 <div class="chapter_open_days">
12 <span class="open_days_label"><%= t(:open_days_label) %>: </span>
13 <% open_days.each do |event| %>
14 <span class="event_schedule"><%= event_schedule_text(event) %></span>
15 <% end %>
16 </div>
17 <% end %>
18 <p class="excerpt"><%= sanitize page.body %></p>
19</div>