From a3d81d5a1a57a905758b26d9abc1e918eaa39237 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Fri, 17 Apr 2026 12:03:21 +0200 Subject: Revert "fix: use language-specific 404 layouts for proper i18n support" This reverts commit 94a11324999f07feff138364633e8442947b628a. --- .../danix-xyz-hacker/assets/js/not-found-page.js | 23 ++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'themes/danix-xyz-hacker/assets') diff --git a/themes/danix-xyz-hacker/assets/js/not-found-page.js b/themes/danix-xyz-hacker/assets/js/not-found-page.js index e86af02..cec60bd 100644 --- a/themes/danix-xyz-hacker/assets/js/not-found-page.js +++ b/themes/danix-xyz-hacker/assets/js/not-found-page.js @@ -31,6 +31,29 @@ document.addEventListener('alpine:init', () => { } })); + Alpine.data('notFoundNav', () => { + const isItalian = window.location.pathname.startsWith('/it/'); + return { + get homeLink() { + return isItalian ? '/it/' : '/'; + }, + get articlesLink() { + return isItalian ? '/it/articles/' : '/articles/'; + }, + get contactLink() { + return isItalian ? '/it/is/here/' : '/is/here/'; + }, + goHome() { + window.location.href = this.homeLink; + }, + goArticles() { + window.location.href = this.articlesLink; + }, + goContact() { + window.location.href = this.contactLink; + } + }; + }); console.log('notFoundPage Alpine component registered'); }); -- cgit v1.2.3