demarches-normaliennes/app/views/layouts/_locale_dropdown.html.haml
Paul Chavard 3b6528decf feat(i18n): enable localization by query param
Providing a query param ("locale") will enable localization. A language picker will be shown once
localization is activated. Locale is stored in a cookie "locale".
2021-08-24 12:42:40 +02:00

11 lines
612 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

.dropdown.locale-dropdown.header-menu-opener
%button.button.dropdown-button.icon-only.header-menu-button{ title: "Translate", aria: { expanded: 'false', controls: 'locale_menu' } }
.hidden Translate
= image_tag "icons/translate-icon.svg", alt: 'Translate', width: 24, height: 24, lazy: true, aria: { hidden: true }
%ul.header-menu.dropdown-content
%li
= link_to save_locale_path(locale: :en), method: :post, class: "menu-item menu-link" do
EN English
%li
= link_to save_locale_path(locale: :fr), method: :post, class: "menu-item menu-link" do
FR français