|
@@ -5,3 +5,14 @@ export function isTextElement(
|
|
|
): element is ExcalidrawTextElement {
|
|
|
return element.type === "text";
|
|
|
}
|
|
|
+
|
|
|
+export function isExcalidrawElement(element: any): boolean {
|
|
|
+ return (
|
|
|
+ element?.type === "text" ||
|
|
|
+ element?.type === "diamond" ||
|
|
|
+ element?.type === "rectangle" ||
|
|
|
+ element?.type === "ellipse" ||
|
|
|
+ element?.type === "arrow" ||
|
|
|
+ element?.type === "line"
|
|
|
+ );
|
|
|
+}
|