From 981a174e9f55dcb7bb6f3f9b50b8ef450d471f20 Mon Sep 17 00:00:00 2001 From: mesalogo Date: Mon, 24 Aug 2026 08:30:51 +0800 Subject: [PATCH] fix: keep Platform Features tabs visible MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Platform Features tab strip could shrink to zero height inside the scrollable Settings layout, leaving the Magic Notes tab present in the DOM but invisible and unusable. Prevent the strip from shrinking and add a CSS regression guard. Release note: 修复设置中心“平台功能”中的“魔法笔记”页签不可见、无法点击的问题。 --- src/renderer/src/WorkspacePrimitives.test.tsx | 9 +++++++++ src/renderer/src/styles.css | 1 + 2 files changed, 10 insertions(+) diff --git a/src/renderer/src/WorkspacePrimitives.test.tsx b/src/renderer/src/WorkspacePrimitives.test.tsx index 8bb6e5d2..2dbed46e 100644 --- a/src/renderer/src/WorkspacePrimitives.test.tsx +++ b/src/renderer/src/WorkspacePrimitives.test.tsx @@ -91,6 +91,15 @@ describe('WorkspacePrimitives', () => { expect(toggleRowStyles).not.toMatch(/padding-top:/u) }) + it('keeps Platform Features tabs visible in scrollable Settings', () => { + const platformFeaturesTabs = stylesheet.match( + /\.platform-features-tabs\s*\{(?[^}]*)\}/u + )?.groups?.rules + + expect(platformFeaturesTabs).toBeDefined() + expect(platformFeaturesTabs).toMatch(/flex:\s*0 0 auto;/u) + }) + it('uses bundled variable fonts and readable shared type tokens', () => { expect(rendererEntry).toContain( "@fontsource-variable/noto-sans-sc/wght.css" diff --git a/src/renderer/src/styles.css b/src/renderer/src/styles.css index a0ead0f2..76fdc6f2 100644 --- a/src/renderer/src/styles.css +++ b/src/renderer/src/styles.css @@ -6245,6 +6245,7 @@ button > svg { width: fit-content; max-width: 100%; overflow-x: auto; + flex: 0 0 auto; } .platform-features-tabs + .settings-section,