From e8bf1552d01130bfbb36b5d4910244a933ef6887 Mon Sep 17 00:00:00 2001 From: icarus Date: Fri, 29 Aug 2025 23:01:50 +0800 Subject: [PATCH] =?UTF-8?q?feat(mini=E7=AA=97=E5=8F=A3):=20=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0ErrorBoundary=E7=BB=84=E4=BB=B6=E5=8C=85=E8=A3=B9?= =?UTF-8?q?=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 为mini窗口内容添加错误边界组件,防止未捕获错误导致整个应用崩溃 --- src/renderer/src/windows/mini/MiniWindowApp.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/renderer/src/windows/mini/MiniWindowApp.tsx b/src/renderer/src/windows/mini/MiniWindowApp.tsx index 5d19bb16cc..7b7753dba2 100644 --- a/src/renderer/src/windows/mini/MiniWindowApp.tsx +++ b/src/renderer/src/windows/mini/MiniWindowApp.tsx @@ -1,5 +1,6 @@ import '@renderer/databases' +import { ErrorBoundary } from '@renderer/components/ErrorBoundary' import { useSettings } from '@renderer/hooks/useSettings' import store, { persistor } from '@renderer/store' import { message } from 'antd' @@ -44,8 +45,10 @@ function MiniWindow(): React.ReactElement { - {messageContextHolder} - + + {messageContextHolder} + +