From 8dfb9c8763633fb4039141621ac74b910ada58ff Mon Sep 17 00:00:00 2001 From: Fredrik Jonsson Date: Tue, 25 Jul 2017 11:18:16 +0200 Subject: [PATCH] Add the mobile menu directly in baseof template instead of via js. Translate menu terms. --- i18n/en.toml | 6 +++ i18n/sv.toml | 7 +++- layouts/_default/baseof.html | 6 ++- layouts/partials/menu.html | 2 +- sass/_zen.scss | 77 ++++++++++++++++++++---------------- sass/init/_variables.scss | 3 +- static/css/styles.css | 2 +- static/js/script.js | 18 ++++----- 8 files changed, 72 insertions(+), 49 deletions(-) diff --git a/i18n/en.toml b/i18n/en.toml index 139b076..17a1c4c 100644 --- a/i18n/en.toml +++ b/i18n/en.toml @@ -1,6 +1,12 @@ +[menu_title] +other = "Main menu" + [menu_home] other = "Home" +[menu_mobile] +other = "Menu" + [pager_next] other = "Next" diff --git a/i18n/sv.toml b/i18n/sv.toml index d77bfac..081a848 100644 --- a/i18n/sv.toml +++ b/i18n/sv.toml @@ -1,6 +1,12 @@ +[menu_title] +other = "Huvudmeny" + [menu_home] other = "Hem" +[menu_mobile] +other = "Meny" + [pager_next] other = "Nästa" @@ -15,4 +21,3 @@ other = "Sök" [search_title] other = "Ange de villkor du vill söka efter." - diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 5be93cd..07cf75d 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -33,7 +33,11 @@ - + {{ partial "scripts.html" . -}} {{ partialCached "scripts_cache.html" . -}} diff --git a/layouts/partials/menu.html b/layouts/partials/menu.html index 7803146..b7de526 100644 --- a/layouts/partials/menu.html +++ b/layouts/partials/menu.html @@ -1,7 +1,7 @@ {{ $currentSection := .Section }} {{ $currentID := .UniqueID }}