5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-06-02 05:54:17 +00:00

Merge branch 'issue-12925' into 'rails'
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

feat: establecer los metadatos para cambiar el idioma #12925

See merge request sutty/sutty!152
This commit is contained in:
fauno 2023-05-13 14:48:54 +00:00
commit e7634cc91d
2 changed files with 9 additions and 1 deletions

View file

@ -0,0 +1,7 @@
- unless current_usuarie
- params.permit!
- I18n.available_locales.each do |locale|
- url = url_for(**params.to_h.merge(change_locale_to: locale), only_path: false)
- if locale == I18n.default_locale
%link{ rel: 'alternate', hreflang: 'x-default', href: url }
%link{ rel: 'alternate', hreflang: locale, href: url }

View file

@ -4,7 +4,7 @@
%meta{ charset: 'UTF-8' }/
%meta{ content: 'text/html; charset=UTF-8',
'http-equiv': 'Content-Type' }/
%meta{ name: 'color-scheme', content: 'light dark' }/
%meta{ name: 'color-scheme', content: 'light' }/
%meta{ name: 'viewport',
content: 'width=device-width, initial-scale=1.0' }/
%meta{ name: 'referrer', content: 'same-origin' }/
@ -17,6 +17,7 @@
= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload'
= stylesheet_pack_tag 'application', 'data-turbolinks-track': 'reload'
= favicon_link_tag 'sutty_cuadrada.png', rel: 'apple-touch-icon', type: 'image/png'
= render 'layouts/link_rel_alternate'
%body{ class: yield(:body) }
.container-fluid#sutty