A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
editor: fix multiple link hover popups from opening (#10233)
01zulfi20b458536179
diff --git a/packages/editor/src/toolbar/floating-menus/hover-popup/index.tsx b/packages/editor/src/toolbar/floating-menus/hover-popup/index.tsxindex 94c3741d7..679bdc474 100644--- a/packages/editor/src/toolbar/floating-menus/hover-popup/index.tsx+++ b/packages/editor/src/toolbar/floating-menus/hover-popup/index.tsx@@ -70,16 +70,12 @@ export function HoverPopupHandler(props: FloatingMenuProps) {const element = e.target;if (activePopup.current) {- const isOutsideEditor = !element.closest(".ProseMirror");const isInsidePopup = element.closest(".popup-presenter-portal");const isActiveElement = activePopup.current.element === element;- if (isInsidePopup) return;+ if (isInsidePopup || isActiveElement) return;- if (isOutsideEditor || !isActiveElement) {- activePopup.current.hide();- activePopup.current = undefined;- return;- }+ activePopup.current.hide();+ activePopup.current = undefined;}clearTimeout(hoverTimeoutId.current);