fix(web): keep desktop note gutters even when a scrollbar is present

Reserve matching left and right scrollbar lanes so the outline no longer sits under the scroller.
This commit is contained in:
tianma-if committed 2026-09-14 23:25:39 +08:00
1 parent adb4fcd4b1
commit 5c0c186446
2 files changed
+2 -1

No files matched your search

+1 -1
View File
@@ -4229,7 +4229,7 @@ const RichEditorPane = ({
: useMarkdownSourceEditor
// Source mode: fill the pane and scroll inside the textarea (not a 300px card).
? "flex flex-col overflow-hidden"
: "overflow-y-auto"
: "overflow-y-auto lg:[scrollbar-gutter:stable_both-edges]"
)}
>
{!isNamedEditorTheme(editorTheme) && customEditorTheme.customCss && (
@@ -74,5 +74,6 @@ describe("shared memo editor header actions", () => {
test("keeps Evernote-like desktop reading gutters aligned with the title", () => {
expect(editorSource).toContain("min-h-full items-start px-4 py-2 sm:px-7 lg:px-10");
expect(densitySource).toContain("sm:px-7 sm:pb-4 sm:pt-4 lg:space-y-0 lg:px-10 lg:py-0");
expect(editorSource).toContain("overflow-y-auto lg:[scrollbar-gutter:stable_both-edges]");
});
});