From a63ab283ad2f1a465f525b793776852d18185670 Mon Sep 17 00:00:00 2001 From: ameotoko Date: Tue, 2 Aug 2022 21:55:38 +0200 Subject: [PATCH] fix: do not corrupt location.href when changing deep-linked tabs --- js/foundation.tabs.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/foundation.tabs.js b/js/foundation.tabs.js index 55a0b7f5e..c44c1e435 100644 --- a/js/foundation.tabs.js +++ b/js/foundation.tabs.js @@ -269,9 +269,9 @@ class Tabs extends Plugin { //either replace or update browser history if (this.options.deepLink && !historyHandled) { if (this.options.updateHistory) { - history.pushState({}, '', anchor); + history.pushState({}, '', location.pathname + location.search + anchor); } else { - history.replaceState({}, '', anchor); + history.replaceState({}, '', location.pathname + location.search + anchor); } } -- 2.47.3