From 8b1a0f1226da31fe5209c06ebe70337eae667074 Mon Sep 17 00:00:00 2001 From: dakkar Date: Thu, 17 Jul 2025 16:36:50 +0100 Subject: [PATCH] replace URL path for inlined SearchMarkers - fixes #1154 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The search index looks like: ```ts [ { id: 'foo', label: 'security', path: '/settings/security', inlining: ['2fa'], }, { id: '2fa', label: 'two-factor auth', path: '/settings/2fa', // guessed wrong by the index generation }, { id: 'aaaa', parentId: '2fa', label: 'totp', }, … ] ``` This file post-processes that index and re-parents the inlined sections. Problem was, it left the (wrong) `path` untouched. Replacing the `path` makes the search work fine. --- packages/frontend/src/utility/settings-search-index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/frontend/src/utility/settings-search-index.ts b/packages/frontend/src/utility/settings-search-index.ts index 7ed97ed34f..8506e4fe2f 100644 --- a/packages/frontend/src/utility/settings-search-index.ts +++ b/packages/frontend/src/utility/settings-search-index.ts @@ -24,6 +24,7 @@ for (const item of generated) { const inline = rootMods.get(id); if (inline) { inline.parentId = item.id; + inline.path = item.path; } else { console.log('[Settings Search Index] Failed to inline', id); }