Skip to content

Library page title is hardcoded Spanish ("Canciones") in every UI language #1

Description

@ollijunes

Bug

internal/web/library.go hardcodes the library page title in Spanish:

title := "Canciones"
if raw != "" {
    title = "Buscar: " + raw
}
s.render(w, r, http.StatusOK, "library.html", s.page(r, title, body))

Every other handler passes an i18n key instead, e.g. s.page(r, "nav.artists", artists) in handleArtists and s.page(r, "nav.genres", genres) in handleGenres.

Effect

With TABERNACLE_LANG=en (or any non-Spanish choice in Ajustes), the whole library page renders in the chosen language except the browser-tab title, which always reads Canciones · Tabernacle (and Buscar: ... when searching).

The hardcoded Spanish title also makes browsers misdetect the page language, which invites auto-translation of song sheets — and browser translation rewrites chord symbols (Am → A.M, A → TO), corrupting the one thing on the page that must survive verbatim.

Suggested fix

Pass the catalog key like the other handlers do:

s.render(w, r, http.StatusOK, "library.html", s.page(r, "nav.songs", body))

and add a library.search.title key (e.g. Search: %s) for the search case.

Seen on v0.6.0 (ghcr.io/jalmena/tabernacle:latest, amd64).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions