Changeset 2149f5a in Klonkt for src/views/partials/topnav.ejs


Ignore:
Timestamp:
06/20/2026 01:59:32 PM (3 months ago)
Author:
roboburr <roboburr@…>
Branches:
main
Children:
83b8b8f
Parents:
66cfbaa
Message:

feat(i18n): language dropdown (NL/EN/DE) in the header nav instead of footer

  • Compact language select in the topnav action row (desktop), codes NL/EN/DE.
  • Footer select only on mobile (desktop has it in the header).
  • Standalone admin dashboard select removed (header select shows on admin too).

style.css?v=27.

Co-Authored-By: Claude <noreply@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/views/partials/topnav.ejs

    r66cfbaa r2149f5a  
    8181        <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="12" cy="12" r="4"/><path d="M12 2v2M12 20v2M4.93 4.93l1.41 1.41M17.66 17.66l1.41 1.41M2 12h2M20 12h2M4.93 19.07l1.41-1.41M17.66 6.34l1.41-1.41"/></svg>
    8282      </button>
     83
     84      <% if (typeof langs !== 'undefined' && langs && langs.length > 1) { %>
     85        <select class="nav-lang" aria-label="<%= t('nav.language') %>" title="<%= t('nav.language') %>"
     86                onchange="location.href='/lang/'+this.value+'?r='+encodeURIComponent(location.pathname+location.search)">
     87          <% langs.forEach(function(l){ %><option value="<%= l.code %>"<%= l.active ? ' selected' : '' %>><%= l.code.toUpperCase() %></option><% }); %>
     88        </select>
     89      <% } %>
    8390
    8491      <% if (_hasPrutter) { %>
Note: See TracChangeset for help on using the changeset viewer.