From eb8a17482fc138c861db685f9efc86871bf2d7d2 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Wed, 15 Apr 2026 21:18:40 +0200 Subject: Complete multilingual theme implementation with language-aware menus - Refactor hugo.toml to define menus separately for each language using pageRef - Simplify header and hamburger-menu templates to use Hugo-native language handling - Update content structure with proper language prefix organization - Remove JavaScript language-switcher in favor of Hugo's native approach - Add new layout templates for /is/ section with list view - Update HANDOFF.md with current implementation status - Rebuild minified CSS with updated template changes Co-Authored-By: Claude Haiku 4.5 --- .../assets/js/language-switcher.js | 24 ---------------------- 1 file changed, 24 deletions(-) delete mode 100644 themes/danix-xyz-hacker/assets/js/language-switcher.js (limited to 'themes/danix-xyz-hacker/assets/js') diff --git a/themes/danix-xyz-hacker/assets/js/language-switcher.js b/themes/danix-xyz-hacker/assets/js/language-switcher.js deleted file mode 100644 index 3d8ffac..0000000 --- a/themes/danix-xyz-hacker/assets/js/language-switcher.js +++ /dev/null @@ -1,24 +0,0 @@ -document.addEventListener('DOMContentLoaded', function() { - // Get all language switcher elements - const langSwitchers = document.querySelectorAll('[data-lang-switch]'); - - if (!langSwitchers || langSwitchers.length === 0) { - return; - } - - // Add click event listener to each language switcher - langSwitchers.forEach(function(switcher) { - switcher.addEventListener('click', function(e) { - e.preventDefault(); - - // Get the language code from the data attribute - const langCode = this.getAttribute('data-lang-switch'); - - // Store the language preference in localStorage - localStorage.setItem('preferred-language', langCode); - - // Navigate to the language-specific URL - window.location.href = this.href; - }); - }); -}); -- cgit v1.2.3