Skip to content

Commit 0e4fb86

Browse files
committed
Use UI::TitleComponent in Page::CardSectionComponent
1 parent 46c4eaa commit 0e4fb86

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

app/components/page/card_section_component.html.erb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<% if @title %>
2-
<h2 class="text-2xl font-bold mt-12 mb-6">
3-
<% if @all_url %>
2+
<% if @all_url %>
3+
<h2 class="text-2xl font-bold mt-12 mb-6">
44
<%= link_to @title, @all_url %>
5-
<% else %>
6-
<%= @title %>
7-
<% end %>
8-
</h2>
5+
</h2>
6+
<% else %>
7+
<%= render UI::TitleComponent.new(title: @title) %>
8+
<% end %>
99
<% end %>
1010

1111
<div class="grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-4 mb-4">

app/content/pages/ecosystem/core.html.erb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@ order: 1
44
---
55

66
<%= render Page::ContainerComponent.new(page: current_page) do |page| %>
7-
<% page.with_title(title: current_page.data.fetch("title")) %>
8-
97
<%= render Page::CardSectionComponent.new(
108
title: current_page.data.fetch("title"),
119
resources: site.resources.glob("#{current_page.request_path}/*.html.erb".delete_prefix("/")).sort_by { |site| site.data.fetch("title") },

0 commit comments

Comments
 (0)