From ed373107c26d5f90ea01428c27882f501746d708 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sun, 23 Nov 2025 21:46:04 +0200 Subject: [PATCH] fix(client/attachments): full-height attachment not displayed correctly (closes #7847) --- apps/client/src/widgets/scroll_padding.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/client/src/widgets/scroll_padding.tsx b/apps/client/src/widgets/scroll_padding.tsx index d8452e301..4ebb7f42d 100644 --- a/apps/client/src/widgets/scroll_padding.tsx +++ b/apps/client/src/widgets/scroll_padding.tsx @@ -2,10 +2,10 @@ import { useEffect, useRef, useState } from "preact/hooks"; import { useNoteContext } from "./react/hooks"; export default function ScrollPadding() { - const { note, parentComponent, ntxId } = useNoteContext(); + const { note, parentComponent, ntxId, viewScope } = useNoteContext(); const ref = useRef(null); const [height, setHeight] = useState(10); - const isEnabled = ["text", "code"].includes(note?.type ?? ""); + const isEnabled = ["text", "code"].includes(note?.type ?? "") && viewScope?.viewMode === "default"; const refreshHeight = () => { if (!ref.current) return;