import type { Locale } from "@/types/sections";

/**
 * UI strings (chrome): nav labels, footer, buttons. Page content lives in src/content/*.
 */
export const UI = {
  nav: {
    home:             { fr: "Accueil",                       en: "Home" },
    municipality:     { fr: "Municipalité",                  en: "Municipality" },
    mayor:            { fr: "Mot du maire",                  en: "A Word from the Mayor" },
    council:          { fr: "Conseil municipal",             en: "Our Council" },
    services:         { fr: "Services municipaux et publics",en: "Our Services" },
    documents:        { fr: "Documents importants",          en: "Important Documents" },
    community:        { fr: "Notre communauté",              en: "Our Community" },
    communityPhotos:  { fr: "Album photos communauté",       en: "Community Photo Album" },
    activitiesPhotos: { fr: "Album photos activités",        en: "Activities Photo Album" },
    developmentPlan:  { fr: "Plan de développement",         en: "Development Plan" },
    townMap:          { fr: "Carte de la ville",             en: "Town Map" },
    businesses:       { fr: "Entreprises locales",           en: "Local Businesses" },
    events:           { fr: "Événements",                    en: "Events" },
    publicNotices:    { fr: "Avis publics",                  en: "Public Notices" },
    minutes:          { fr: "Procès-verbaux",                en: "Minutes" },
    newsletters:      { fr: "Bulletins",                     en: "Newsletters" },
  },
  topbar: {
    home:    { fr: "Accueil",                  en: "Home" },
    hours:   { fr: "Mar. - Ven. 8 h à 16 h",   en: "Tues. - Fri. 8:00 a.m. to 4:00 p.m." },
  },
  cta: {
    learnMore: { fr: "En savoir plus",       en: "Learn more" },
    contact:   { fr: "Nous contacter",       en: "Contact us" },
    viewAll:   { fr: "Tout voir",            en: "View all" },
    send:      { fr: "Envoyer",              en: "Send" },
    download:  { fr: "Télécharger",          en: "Download" },
    openPdf:   { fr: "Ouvrir le PDF",        en: "Open PDF" },
    backHome:  { fr: "Retour à l'accueil",   en: "Back to home" },
  },
  form: {
    name:    { fr: "Nom",                en: "Name" },
    email:   { fr: "Courriel",           en: "Email" },
    subject: { fr: "Sujet",              en: "Subject" },
    message: { fr: "Message",            en: "Message" },
    soon:    { fr: "L’envoi du formulaire sera activé prochainement. Vous pouvez nous joindre par courriel ou téléphone.",
               en: "Form submission will be enabled soon. You can reach us by email or phone in the meantime." },
  },
  footer: {
    address:  { fr: "Adresse",            en: "Address" },
    contact:  { fr: "Coordonnées",        en: "Contact" },
    hours:    { fr: "Heures d’ouverture", en: "Office hours" },
    quick:    { fr: "Liens rapides",      en: "Quick links" },
    rights:   { fr: "Tous droits réservés.", en: "All rights reserved." },
  },
  events: {
    upcoming: { fr: "À venir",   en: "Upcoming" },
  },
  documents: {
    pdf:       { fr: "Document PDF",          en: "PDF document" },
    requestOnDemand: {
      fr: "Document disponible sur demande à la municipalité.",
      en: "Document available on request from the municipality.",
    },
  },
} as const;

export function t<T extends { fr: string; en: string }>(value: T, locale: Locale): string {
  return value[locale];
}