From f27b43ef45279466d3a45fe90f06eec0a5822e78 Mon Sep 17 00:00:00 2001 From: sto Date: Sat, 21 Jun 2025 10:07:42 +0200 Subject: [PATCH] Improve top buttons --- app/views/layouts/authenticated.html.slim | 8 ++++---- config/locales/en.yml | 8 ++++---- config/locales/fr.yml | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/app/views/layouts/authenticated.html.slim b/app/views/layouts/authenticated.html.slim index a24c54a..2b12753 100644 --- a/app/views/layouts/authenticated.html.slim +++ b/app/views/layouts/authenticated.html.slim @@ -8,13 +8,13 @@ html .float-end style="margin-top: -8px;" nav.navbar.bg-body-primary - if @current_user.admin - a.navbar-brand href=users_path + a.navbar-brand href=users_path class="btn btn-light" style="margin-right: 0" = t("nav.users") - a.navbar-brand href=contests_path + a.navbar-brand href=contests_path class="btn btn-light" style="margin-right: 0" = t("nav.home") - a.navbar-brand href=user_path(@current_user) + a.navbar-brand href=user_path(@current_user) class="btn btn-light" = t("nav.settings") - = button_to t("nav.log_out"), session_path, method: :delete + = button_to t("nav.log_out"), session_path, method: :delete, class: "btn btn-danger" css: .toast { diff --git a/config/locales/en.yml b/config/locales/en.yml index 0c839f6..e9820b3 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -199,10 +199,10 @@ en: singular: "message" warning: "You first need to add a puzzle before converting messages to completions." nav: - users: "Users" - home: "Home" - settings: "Settings" - log_out: "Log out" + users: Users + home: My contests + settings: Settings + log_out: Log out puzzles: destroy: notice: Puzzle deleted diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 2ec305b..6566895 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -170,10 +170,10 @@ fr: singular: "message" warning: "Au moins un puzzle doit être ajouté avant de pouvoir convertir des messages en complétions." nav: - users: "Utilisateur.ices" - home: "Accueil" - settings: "Paramètres" - log_out: "Déconnexion" + users: Utilisateur.ices + home: Mes concours + settings: Paramètres + log_out: Déconnexion puzzles: destroy: notice: Puzzle supprimé