From f6a18c366db082b730ac7b013e35b20ea1ee140b Mon Sep 17 00:00:00 2001 From: Leopoldadmin Date: Mon, 22 Jun 2026 23:23:10 +0000 Subject: [PATCH] T21: Fix RefObject type error in RibbonBar.tsx (guard yjsDoc with && check) --- frontend/src/components/RibbonBar.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/RibbonBar.tsx b/frontend/src/components/RibbonBar.tsx index a928b9c..f106d3a 100644 --- a/frontend/src/components/RibbonBar.tsx +++ b/frontend/src/components/RibbonBar.tsx @@ -162,8 +162,8 @@ const RibbonBar: React.FC = ({ onTabChange, yjsDoc }) => { onChange={handleFileSelected} /> - {showPrintPreview && ( - setShowPrintPreview(false)} /> + {showPrintPreview && yjsDoc && ( + setShowPrintPreview(false)} /> )} );