From 797e63f86ff8f6493e65328f66cd834f40cffdfe Mon Sep 17 00:00:00 2001 From: L-Sun Date: Thu, 6 Mar 2025 09:26:00 +0000 Subject: [PATCH] chore(editor): remove unexpected bottom padding of code block (#10660) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Close [BS-2765](https://linear.app/affine-design/issue/BS-2765/代码块在字数超出宽度时,下巴变大) https://github.com/user-attachments/assets/1dc53528-6d36-4b2a-861c-9ca06381c681 --- blocksuite/affine/block-code/src/styles.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/blocksuite/affine/block-code/src/styles.ts b/blocksuite/affine/block-code/src/styles.ts index c527612e2d..118f88fc57 100644 --- a/blocksuite/affine/block-code/src/styles.ts +++ b/blocksuite/affine/block-code/src/styles.ts @@ -15,6 +15,10 @@ export const codeBlockStyles = css` padding: 12px; } + .affine-code-block-container rich-text { + overflow-x: hidden; + } + .affine-code-block-container .inline-editor { font-family: var(--affine-font-code-family); font-variant-ligatures: none;