refactor: separate elements logic into a standalone package (#9285)
This commit is contained in:
@@ -1,15 +1,20 @@
|
||||
import React, { useEffect, useRef } from "react";
|
||||
|
||||
import { CURSOR_TYPE } from "../../constants";
|
||||
import { t } from "../../i18n";
|
||||
import { isRenderThrottlingEnabled } from "../../reactUtils";
|
||||
import { renderInteractiveScene } from "../../renderer/interactiveScene";
|
||||
import { isShallowEqual, sceneCoordsToViewportCoords } from "../../utils";
|
||||
import {
|
||||
CURSOR_TYPE,
|
||||
isShallowEqual,
|
||||
sceneCoordsToViewportCoords,
|
||||
} from "@excalidraw/common";
|
||||
|
||||
import type {
|
||||
NonDeletedExcalidrawElement,
|
||||
NonDeletedSceneElementsMap,
|
||||
} from "../../element/types";
|
||||
} from "@excalidraw/element/types";
|
||||
|
||||
import { t } from "../../i18n";
|
||||
import { isRenderThrottlingEnabled } from "../../reactUtils";
|
||||
import { renderInteractiveScene } from "../../renderer/interactiveScene";
|
||||
|
||||
import type {
|
||||
InteractiveCanvasRenderConfig,
|
||||
RenderableElementsMap,
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import { useEffect, useRef } from "react";
|
||||
|
||||
import type { NonDeletedSceneElementsMap } from "@excalidraw/element/types";
|
||||
|
||||
import { isRenderThrottlingEnabled } from "../../reactUtils";
|
||||
import { renderNewElementScene } from "../../renderer/renderNewElementScene";
|
||||
|
||||
import type { NonDeletedSceneElementsMap } from "../../element/types";
|
||||
import type {
|
||||
RenderableElementsMap,
|
||||
StaticCanvasRenderConfig,
|
||||
|
||||
@@ -1,13 +1,15 @@
|
||||
import React, { useEffect, useRef } from "react";
|
||||
|
||||
import { isRenderThrottlingEnabled } from "../../reactUtils";
|
||||
import { renderStaticScene } from "../../renderer/staticScene";
|
||||
import { isShallowEqual } from "../../utils";
|
||||
import { isShallowEqual } from "@excalidraw/common";
|
||||
|
||||
import type {
|
||||
NonDeletedExcalidrawElement,
|
||||
NonDeletedSceneElementsMap,
|
||||
} from "../../element/types";
|
||||
} from "@excalidraw/element/types";
|
||||
|
||||
import { isRenderThrottlingEnabled } from "../../reactUtils";
|
||||
import { renderStaticScene } from "../../renderer/staticScene";
|
||||
|
||||
import type {
|
||||
RenderableElementsMap,
|
||||
StaticCanvasRenderConfig,
|
||||
|
||||
Reference in New Issue
Block a user