add traductions
This commit is contained in:
19
app/views/layouts/_locales.html.erb
Normal file
19
app/views/layouts/_locales.html.erb
Normal file
@@ -0,0 +1,19 @@
|
||||
<li class="nav-item dropdown">
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-bs-toggle="dropdown" aria-expanded="false">
|
||||
<i class="fas fa-globe-europe"></i>
|
||||
</a>
|
||||
<ul class="dropdown-menu dropdown-menu-end" aria-labelledby="navbarDropdown">
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-de"></span>'.html_safe, root_path(locale: 'de-de') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-gb"></span>'.html_safe, root_path(locale: 'en-gb') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-us"></span>'.html_safe, root_path(locale: 'en-us') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-mx"></span>'.html_safe, root_path(locale: 'es-mx') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-br"></span>'.html_safe, root_path(locale: 'pt-br') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-es"></span>'.html_safe, root_path(locale: 'es-es') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-fr"></span>'.html_safe, root_path(locale: 'fr-fr') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-it"></span>'.html_safe, root_path(locale: 'it') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-ru"></span>'.html_safe, root_path(locale: 'ru-ru') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-kr"></span>'.html_safe, root_path(locale: 'ko') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-tw"></span>'.html_safe, root_path(locale: 'zh-tw') %></li>
|
||||
<li class="dropdown-item"><%= link_to '<span class="flag-icon flag-icon-cn"></span>'.html_safe, root_path(locale: 'zh-cn') %></li>
|
||||
</ul>
|
||||
</li>
|
||||
@@ -5,16 +5,19 @@
|
||||
<% if user_signed_in? %>
|
||||
<ul class="navbar-nav mb-2 mb-lg-0">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_characters_path %>">Characters</a>
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_characters_path %>"><%= t('layouts.navbar.characters') %></a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_mounts_path %>">Mounts</a>
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_mounts_path %>"><%= t('layouts.navbar.mounts') %></a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_pets_path %>">Pets</a>
|
||||
<a class="nav-link active" aria-current="page" href="<%= wow_pets_path %>"><%= t('layouts.navbar.pets') %></a>
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="navbar-nav ms-auto mb-2 mb-lg-0">
|
||||
<%= render 'layouts/locales' %>
|
||||
</ul>
|
||||
<ul class="navbar-nav mb-2 mb-lg-0">
|
||||
<li class="nav-item dropdown">
|
||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-bs-toggle="dropdown" aria-expanded="false">
|
||||
Menu
|
||||
@@ -26,7 +29,10 @@
|
||||
</ul>
|
||||
</li>
|
||||
<% else %>
|
||||
<%= link_to 'Sign in with <i class="fab fa-battle-net"></i>'.html_safe, user_bnet_omniauth_authorize_path, method: :post, class: "btn btn-primary nav-item" %>
|
||||
<ul class="navbar-nav ms-auto mb-2 mb-lg-0">
|
||||
<%= render 'layouts/locales' %>
|
||||
<%= link_to 'Sign in with <i class="fab fa-battle-net"></i>'.html_safe, user_bnet_omniauth_authorize_path, method: :post, class: "btn btn-primary nav-item" %>
|
||||
</ul>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -4,13 +4,13 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col"></th>
|
||||
<th scope="col"><%= t('character_list.name') %></th>
|
||||
<th scope="col"><%= t('character_list.gender') %></th>
|
||||
<th scope="col"><%= t('character_list.realm') %></th>
|
||||
<th scope="col"><%= t('character_list.race') %></th>
|
||||
<th scope="col"><%= t('character_list.class') %></th>
|
||||
<th scope="col"><%= t('character_list.faction') %></th>
|
||||
<th scope="col"><%= t('character_list.level') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.name') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.gender') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.realm') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.race') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.class') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.faction') %></th>
|
||||
<th scope="col"><%= t('wow_characters.character_list.level') %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
<table class="table table-hover table-dark table-image">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col"><%= t('mount_list.name') %></th>
|
||||
<th scope="col"><%= t('mount_list.description') %></th>
|
||||
<th scope="col"><%= t('mount_list.owned') %></th>
|
||||
<th scope="col"><%= t('wow_mounts.mount_list.name') %></th>
|
||||
<th scope="col"><%= t('wow_mounts.mount_list.description') %></th>
|
||||
<th scope="col"><%= t('wow_mounts.mount_list.owned') %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
<table class="table table-hover table-dark table-image">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col"><%= t('pet_list.name') %></th>
|
||||
<th scope="col"><%= t('pet_list.description') %></th>
|
||||
<th scope="col"><%= t('pet_list.owned') %></th>
|
||||
<th scope="col"><%= t('wow_pets.pet_list.name') %></th>
|
||||
<th scope="col"><%= t('wow_pets.pet_list.description') %></th>
|
||||
<th scope="col"><%= t('wow_pets.pet_list.owned') %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
Reference in New Issue
Block a user