Render components instead of partials in headers

We were using partials to render components in order to ease the
transition of custom code from earlier versions of Consul. However,
that was back in Consul 1.4, and now these views looked a bit messy
since they sometimes rendered components and sometimes they
rendered partials.
This commit is contained in:
Javi Martín
2023-01-29 04:19:04 +01:00
parent 2ac338f51a
commit bbd4d3e62d
4 changed files with 4 additions and 6 deletions

View File

@@ -1,6 +1,6 @@
<header class="header">
<div class="top-links">
<%= render "shared/locale_switcher" %>
<%= render Layout::LocaleSwitcherComponent.new %>
<%= link_to root_path do %>
<%= t("admin.dashboard.index.back", org: setting["org_name"]) %>

View File

@@ -4,9 +4,9 @@
<% end %>
<div class="top-links">
<%= render "shared/locale_switcher" %>
<%= render Layout::LocaleSwitcherComponent.new %>
<div class="hide-for-small-only">
<%= render "shared/top_links" %>
<%= render Layout::TopLinksComponent.new %>
</div>
</div>
@@ -23,7 +23,7 @@
<div class="show-for-small-only">
<div class="subnavigation subnavigation-with-top-links">
<%= render Layout::SubnavigationComponent.new %>
<%= render "shared/top_links" %>
<%= render Layout::TopLinksComponent.new %>
</div>
</div>
<% end %>

View File

@@ -1 +0,0 @@
<%= render Layout::LocaleSwitcherComponent.new %>

View File

@@ -1 +0,0 @@
<%= render Layout::TopLinksComponent.new %>