mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
- Add "elements" argument to all scene functions to break reliance on global vars - Move all scene functions under scene directory encapsulated by `index.ts` - Move all element functions under `element` directory encapsulated by index.ts - Create a SceneHistory class to store scene history state - Add `createScene` function to create scene object
7 lines
203 B
TypeScript
7 lines
203 B
TypeScript
import { ExcalidrawElement, ExcalidrawTextElement } from "./types";
|
|
|
|
export function isTextElement(
|
|
element: ExcalidrawElement
|
|
): element is ExcalidrawTextElement {
|
|
return element.type === "text";
|
|
}
|