From 25110672b89bd6308ba6dc4608c232c3a260f212 Mon Sep 17 00:00:00 2001 From: Mikael Finstad Date: Thu, 6 Nov 2025 21:25:36 +0800 Subject: [PATCH] simplify --- src/renderer/src/BottomBar.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/renderer/src/BottomBar.tsx b/src/renderer/src/BottomBar.tsx index d6205e6e..3670cd92 100644 --- a/src/renderer/src/BottomBar.tsx +++ b/src/renderer/src/BottomBar.tsx @@ -42,8 +42,11 @@ const InvertCutModeButton = memo(({ invertCutSegments, setInvertCutSegments }: { const onYinYangClick = useCallback(() => { setInvertCutSegments((v) => { const newVal = !v; - if (newVal) getSwal().toast.fire({ title: t('When you export, selected segments on the timeline will be REMOVED - the surrounding areas will be KEPT') }); - else getSwal().toast.fire({ title: t('When you export, selected segments on the timeline will be KEPT - the surrounding areas will be REMOVED.') }); + getSwal().toast.fire({ + title: newVal + ? t('When you export, selected segments on the timeline will be REMOVED - the surrounding areas will be KEPT') + : t('When you export, selected segments on the timeline will be KEPT - the surrounding areas will be REMOVED.'), + }); return newVal; }); }, [setInvertCutSegments, t]);