From f4275119ad75aa535af1bdff6be1ffd1039edd87 Mon Sep 17 00:00:00 2001 From: seaHi Date: Wed, 23 Sep 2026 11:32:58 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E6=94=B9=E8=BF=9B=20Markdown=20?= =?UTF-8?q?=E7=BC=96=E8=BE=91=E5=99=A8=E9=AB=98=E5=BA=A6=E4=B8=8E=E5=B8=83?= =?UTF-8?q?=E5=B1=80=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lib/components/admin/MarkdownEditor.svelte | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/lib/components/admin/MarkdownEditor.svelte b/src/lib/components/admin/MarkdownEditor.svelte index 17be3ac..dc0babb 100644 --- a/src/lib/components/admin/MarkdownEditor.svelte +++ b/src/lib/components/admin/MarkdownEditor.svelte @@ -91,18 +91,15 @@ boxShadow: '0 0 0 3px rgba(65, 155, 56, 0.08)' }, '.cm-content': { - minHeight: '400px', padding: '12px 14px', lineHeight: '1.8' }, '.cm-scroller': { - overflow: 'auto', - minHeight: '400px' + overflow: 'auto' }, '.cm-gutters': { backgroundColor: 'rgba(0, 0, 0, 0.03)', color: 'rgba(0, 0, 0, 0.4)', - minHeight: '400px', borderRight: '1px solid rgba(0, 0, 0, 0.12)', borderTopLeftRadius: '0', borderBottomLeftRadius: '0' @@ -377,6 +374,14 @@ .editor-container { width: 100%; + min-height: 400px; + display: flex; + flex-direction: column; + } + + .editor-container :global(.cm-editor) { + flex: 1; + height: 100%; } .md-toolbar {