From e521fd8e5833e4a3a04ba3ce8dc33767d6ced438 Mon Sep 17 00:00:00 2001 From: Paul Huliganga Date: Tue, 21 Apr 2026 14:21:50 -0400 Subject: [PATCH] fix(router): correct parseHash slice indices for detail routes parts.slice(0,3) was returning the full path as base; should be slice(0,2) so '#/templates/abc123' yields base='#/templates', param='abc123'. Co-Authored-By: Claude Sonnet 4.6 --- web/static/js/router.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/static/js/router.js b/web/static/js/router.js index 8c9773a..2569d22 100644 --- a/web/static/js/router.js +++ b/web/static/js/router.js @@ -34,7 +34,7 @@ function parseHash(hash) { const clean = hash || '#/templates'; const parts = clean.split('/'); if (parts.length >= 3) { - return { base: parts.slice(0, 3).join('/'), param: parts[3] || null }; + return { base: parts.slice(0, 2).join('/'), param: parts.slice(2).join('/') }; } return { base: clean, param: null }; }