Using `flex` instead of a fixed width for the navigation, the elements take all the available space when the search form isn't present. That wasn't the case before and produced a strange effect on medium-sized screens. This way we also align the search to the right.
65 lines
2.3 KiB
Plaintext
65 lines
2.3 KiB
Plaintext
<nav>
|
|
<ul>
|
|
<%= raw content_block("subnavigation_left") %>
|
|
|
|
<% if feature?(:debates) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.debates"),
|
|
debates_path,
|
|
controller_name == "debates",
|
|
accesskey: "1" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:proposals) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.proposals"),
|
|
proposals_path,
|
|
controller.class == ProposalsController,
|
|
accesskey: "2" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:polls) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.poll_questions"),
|
|
polls_path,
|
|
controller_name == "polls" || (controller_name == "questions" && controller.class.parent == Polls),
|
|
accesskey: "3" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:legislation) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.collaborative_legislation"),
|
|
legislation_processes_path,
|
|
controller.class.parent == Legislation,
|
|
accesskey: "4" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:budgets) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.budgets"),
|
|
budgets_path,
|
|
controller_name == "budgets" || controller_name == "investments",
|
|
accesskey: "5" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:sdg) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.sdg"),
|
|
sdg_goals_path,
|
|
controller_path == "sdg/goals" && action_name != "help",
|
|
accesskey: "6" %>
|
|
</li>
|
|
<% end %>
|
|
<% if feature?(:help_page) %>
|
|
<li>
|
|
<%= layout_menu_link_to t("layouts.header.help"),
|
|
help_path,
|
|
current_page?(help_path),
|
|
accesskey: "7" %>
|
|
</li>
|
|
<% end %>
|
|
|
|
<%= raw content_block("subnavigation_right") %>
|
|
</ul>
|
|
</nav>
|