修复画布图片备注面板不弹出问题

This commit is contained in:
Your Name 2026-02-08 12:11:20 +08:00
parent 4e0c0d9cd0
commit 23b48884a9

View File

@ -273,7 +273,6 @@ export function ImageNode({ node, isSelected }: ImageNodeProps) {
setTextEditPanelOpen(false);
setIsEditingTitle(false);
setPromptDialogOpen(false);
setNotePanelOpen(false);
}
}, [isSelected]);
@ -1814,9 +1813,9 @@ export function ImageNode({ node, isSelected }: ImageNodeProps) {
)}
{/* 图片备注面板 */}
{isSelected && notePanelOpen && typeof document !== "undefined" && createPortal(
{notePanelOpen && typeof document !== "undefined" && createPortal(
<div
className="fixed z-[9999] w-[300px] rounded-xl border border-amber-200 bg-amber-50/95 shadow-2xl backdrop-blur"
className="fixed z-[10001] w-[300px] rounded-xl border border-amber-200 bg-amber-50/95 shadow-2xl backdrop-blur"
style={{
top: getNotePanelPosition().top,
left: getNotePanelPosition().left,