From 854e2006b6be22e82dd76fd8efd70238f8dc3354 Mon Sep 17 00:00:00 2001 From: Mimi <1119186082@qq.com> Date: Tue, 4 Aug 2026 17:26:12 +0800 Subject: [PATCH] Disable Fancybox hash handling with PJAX (#983) --- source/js/third-party/fancybox.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/source/js/third-party/fancybox.js b/source/js/third-party/fancybox.js index 178db4b..85ab4ae 100644 --- a/source/js/third-party/fancybox.js +++ b/source/js/third-party/fancybox.js @@ -31,5 +31,8 @@ document.addEventListener('page:loaded', () => { image.wrap(imageWrapLink); }); - Fancybox.bind('[data-fancybox]'); + // Disable hash handling to avoid conflicts with PJAX navigation. + Fancybox.bind('[data-fancybox]', { + Hash: false + }); });