|
14 | 14 | <% end %> |
15 | 15 |
|
16 | 16 | <nav class="l-ui-header__navigation" aria-label="Header navigation"> |
17 | | - <button |
18 | | - type="button" |
19 | | - data-controller="l-ui--theme" |
20 | | - data-action="click->l-ui--theme#toggle" |
21 | | - data-l-ui--theme-target="button" |
22 | | - class="l-ui-button l-ui-button--icon l-ui-theme-toggle" |
23 | | - aria-label="Toggle dark mode" |
24 | | - aria-pressed="false" |
25 | | - > |
26 | | - <%= image_tag "layered_ui/icon_moon.svg", alt: "", class: "l-ui-icon l-ui-icon--sm l-ui-theme-toggle__icon l-ui-theme-toggle__icon--light", aria: { hidden: true } %> |
27 | | - <%= image_tag "layered_ui/icon_sun.svg", alt: "", class: "l-ui-icon l-ui-icon--sm l-ui-theme-toggle__icon l-ui-theme-toggle__icon--dark", aria: { hidden: true } %> |
28 | | - </button> |
29 | | - |
30 | | - <% unless l_ui_user_signed_in? %> |
31 | | - <% if respond_to?(:new_user_registration_path) %> |
32 | | - <%= link_to "Register", main_app.new_user_registration_path, class: "l-ui-button l-ui-button--outline l-ui-button--small" %> |
33 | | - <% end %> |
34 | | - |
35 | | - <% if respond_to?(:new_user_session_path) %> |
36 | | - <%= link_to "Login", main_app.new_user_session_path, class: "l-ui-button l-ui-button--primary l-ui-button--small" %> |
37 | | - <% end %> |
38 | | - <% end %> |
39 | | - |
40 | | - <% if yield(:l_ui_navigation_items).present? || l_ui_user_signed_in? %> |
41 | | - <button |
42 | | - type="button" |
43 | | - class="l-ui-button l-ui-button--navigation-toggle" |
44 | | - data-action="click->l-ui--navigation#toggle" |
45 | | - data-l-ui--navigation-target="toggleButton" |
46 | | - aria-label="Toggle navigation menu" |
47 | | - aria-expanded="false" |
48 | | - aria-controls="l-ui-navigation" |
49 | | - > |
50 | | - <%= image_tag "layered_ui/icon_hamburger.svg", alt: "", class: "l-ui-icon l-ui-icon--md", data: { "l-ui--navigation-target": "openIcon" }, aria: { hidden: true } %> |
51 | | - <%= image_tag "layered_ui/icon_close.svg", alt: "", class: "l-ui-icon l-ui-icon--md", style: "display: none;", data: { "l-ui--navigation-target": "closeIcon" }, aria: { hidden: true } %> |
52 | | - </button> |
| 17 | + <% if content_for?(:l_ui_header_actions) %> |
| 18 | + <%= yield(:l_ui_header_actions) %> |
| 19 | + <% else %> |
| 20 | + <%= yield(:l_ui_header_actions_start) %> |
| 21 | + <%= l_ui_theme_toggle %> |
| 22 | + <%= l_ui_authentication %> |
| 23 | + <%= l_ui_navigation_toggle %> |
| 24 | + <%= yield(:l_ui_header_actions_end) %> |
53 | 25 | <% end %> |
54 | 26 | </nav> |
55 | 27 | </div> |
|
0 commit comments