From 47ebc55f808f34c18a3b455d523c8e9b9736d8fb Mon Sep 17 00:00:00 2001 From: N-Pex Date: Mon, 22 Dec 2025 13:23:43 +0100 Subject: [PATCH] Build 94 Preserve the path name for mirror links --- package.json | 2 +- package.json.bak | 2 +- public/offline.html | 4 ++-- public/sw.js | 1 + 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 6ff2945..af6d380 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "keanuapp-weblite", - "version": "0.1.93", + "version": "0.1.94", "private": true, "scripts": { "dev": "vite", diff --git a/package.json.bak b/package.json.bak index 61c66de..6ff2945 100644 --- a/package.json.bak +++ b/package.json.bak @@ -1,6 +1,6 @@ { "name": "keanuapp-weblite", - "version": "0.1.92", + "version": "0.1.93", "private": true, "scripts": { "dev": "vite", diff --git a/public/offline.html b/public/offline.html index 02fefda..66e64d4 100644 --- a/public/offline.html +++ b/public/offline.html @@ -34,7 +34,7 @@ function go() { if (navigator.onLine) { - let url = "/#/?migrate=1"; + let url = "" + window.location.pathname + "#/?migrate=1"; if (!url.includes("://")) { url = window.location.protocol + "//" + url; } @@ -72,7 +72,7 @@ } else if (data !== null && data.cmd == "migrationDone") { if (windowProxy) { windowProxy.close(); - let url = "/#/"; + let url = "" + window.location.pathname + "#/"; if (!url.includes("://")) { url = window.location.protocol + "//" + url; } diff --git a/public/sw.js b/public/sw.js index bece099..233a802 100644 --- a/public/sw.js +++ b/public/sw.js @@ -126,6 +126,7 @@ async function serveOfflinePage() { }; } }); + if (title) { text = text.replaceAll(/(.*?)/g, title); }