From 97e8b9b6806634bbf66c8da51599e6396a35d443 Mon Sep 17 00:00:00 2001 From: Vito Sansevero Date: Tue, 27 Oct 2026 19:09:21 -0700 Subject: [PATCH] test(admin): open Page options after the saved default is read Drops the leftover LoraManager section comment above the Page options save. --- tests/browser/legacy-system-links.spec.mjs | 2 ++ web/js/admin.js | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/browser/legacy-system-links.spec.mjs b/tests/browser/legacy-system-links.spec.mjs index 192265ea..21b2cb83 100644 --- a/tests/browser/legacy-system-links.spec.mjs +++ b/tests/browser/legacy-system-links.spec.mjs @@ -188,6 +188,8 @@ test('Page options keeps the page-only settings admin', async ({ page, request } const after = (await (await request.get('/prompt_manager/settings')).json()).settings; expect(after).toEqual({ ...before, infinite_scroll: true }); await page.reload(); + // The dialog shows the saved default once the page has read it (the header follows it first). + await expect(page.locator('#infiniteScrollSession')).toBeChecked(); await page.locator('#pageOptionsBtn').click(); await expect(page.locator('#infiniteScrollDefault')).toBeChecked(); }); diff --git a/web/js/admin.js b/web/js/admin.js index b5489394..d0fb25fb 100644 --- a/web/js/admin.js +++ b/web/js/admin.js @@ -973,8 +973,6 @@ this.showModal("settingsModal"); } - // ── LoraManager integration ────────────────────────────── - /** Saves Page options: only `infinite_scroll`, so a stale page never overwrites what System saved (#330 S13-9). */ async saveSettings() { const infiniteScroll = document.getElementById("infiniteScrollDefault").checked;