From 56c82d7f0fc255cc3015b39183ff90de6fcab48e Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sat, 22 Nov 2025 21:20:24 +0200 Subject: [PATCH] chore(quick_edit): address requested changes --- apps/client/src/widgets/dialogs/PopupEditor.tsx | 4 ++-- apps/client/src/widgets/react/hooks.tsx | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/apps/client/src/widgets/dialogs/PopupEditor.tsx b/apps/client/src/widgets/dialogs/PopupEditor.tsx index 0d84e5ba5..4950a4103 100644 --- a/apps/client/src/widgets/dialogs/PopupEditor.tsx +++ b/apps/client/src/widgets/dialogs/PopupEditor.tsx @@ -62,10 +62,10 @@ export function DialogWrapper({ children }: { children: ComponentChildren }) { if (!wrapperRef.current) return; const customHue = getComputedStyle(wrapperRef.current).getPropertyValue("--custom-color-hue"); setHasTint(!!customHue); - }, [ note, colorClass ]); + }, [ note ]); return ( -
+
{children}
) diff --git a/apps/client/src/widgets/react/hooks.tsx b/apps/client/src/widgets/react/hooks.tsx index 82d01750c..f30957bef 100644 --- a/apps/client/src/widgets/react/hooks.tsx +++ b/apps/client/src/widgets/react/hooks.tsx @@ -271,6 +271,7 @@ export function useNoteContext() { setNote(noteContextContext.note); setNotePath(noteContextContext.notePath); setViewScope(noteContextContext.viewScope); + setIsReadOnlyTemporarilyDisabled(noteContextContext?.viewScope?.readOnlyTemporarilyDisabled); }, [ noteContextContext ]); useEffect(() => { @@ -292,6 +293,7 @@ export function useNoteContext() { } }); useTriliumEvent("readOnlyTemporarilyDisabled", ({ noteContext: eventNoteContext }) => { + if (noteContextContext) return; if (eventNoteContext.ntxId === noteContext?.ntxId) { setIsReadOnlyTemporarilyDisabled(eventNoteContext?.viewScope?.readOnlyTemporarilyDisabled); }