diff --git a/src/components/EditorCanvas/Area.jsx b/src/components/EditorCanvas/Area.jsx index 533d37c..0e1c88c 100644 --- a/src/components/EditorCanvas/Area.jsx +++ b/src/components/EditorCanvas/Area.jsx @@ -231,7 +231,7 @@ function EditPopoverContent({ data }) { e.element === ObjectType.AREA && e.aid === data.id && e.action === Action.EDIT && - e.redo.color, + e.redo?.color, ); if (lastColorChange) { undoColor = lastColorChange.redo.color; diff --git a/src/components/EditorCanvas/Note.jsx b/src/components/EditorCanvas/Note.jsx index 31664c5..070b0c2 100644 --- a/src/components/EditorCanvas/Note.jsx +++ b/src/components/EditorCanvas/Note.jsx @@ -42,7 +42,7 @@ export default function Note({ data, onPointerDown }) { e.element === ObjectType.NOTE && e.nid === data.id && e.action === Action.EDIT && - e.redo.color, + e.redo?.color, ); if (lastColorChange) { undoColor = lastColorChange.redo.color; diff --git a/src/components/EditorSidePanel/AreasTab/AreaDetails.jsx b/src/components/EditorSidePanel/AreasTab/AreaDetails.jsx index 0a62a31..7686263 100644 --- a/src/components/EditorSidePanel/AreasTab/AreaDetails.jsx +++ b/src/components/EditorSidePanel/AreasTab/AreaDetails.jsx @@ -21,7 +21,7 @@ export default function AreaInfo({ data, i }) { e.element === ObjectType.AREA && e.aid === data.id && e.action === Action.EDIT && - e.redo.color, + e.redo?.color, ); if (lastColorChange) { undoColor = lastColorChange.redo.color; diff --git a/src/components/EditorSidePanel/NotesTab/NoteInfo.jsx b/src/components/EditorSidePanel/NotesTab/NoteInfo.jsx index 98cd193..d03289a 100644 --- a/src/components/EditorSidePanel/NotesTab/NoteInfo.jsx +++ b/src/components/EditorSidePanel/NotesTab/NoteInfo.jsx @@ -21,7 +21,7 @@ export default function NoteInfo({ data, nid }) { e.element === ObjectType.NOTE && e.nid === data.id && e.action === Action.EDIT && - e.redo.color, + e.redo?.color, ); if (lastColorChange) { undoColor = lastColorChange.redo.color; diff --git a/src/components/EditorSidePanel/TablesTab/TableInfo.jsx b/src/components/EditorSidePanel/TablesTab/TableInfo.jsx index b9f3706..c3c2b6c 100644 --- a/src/components/EditorSidePanel/TablesTab/TableInfo.jsx +++ b/src/components/EditorSidePanel/TablesTab/TableInfo.jsx @@ -35,7 +35,7 @@ export default function TableInfo({ data }) { e.element === ObjectType.TABLE && e.tid === data.id && e.action === Action.EDIT && - e.redo.color, + e.redo?.color, ); if (lastColorChange) { undoColor = lastColorChange.redo.color;