build: correct incorrect imports for excalidraw-app build

This commit is contained in:
Deepen Timalsina 2025-04-15 21:37:40 +05:45
parent 81b70e221f
commit b8b6e67559
10 changed files with 21 additions and 20 deletions

View file

@ -18,7 +18,7 @@ import {
} from "@excalidraw/math";
import { isCurve } from "@excalidraw/math/curve";
import type { DebugElement } from "@excalidraw/excalidraw/visualdebug";
import type { DebugElement } from "@excalidraw/excalidraw/src/visualdebug";
import type { Curve } from "@excalidraw/math";

View file

@ -1,9 +1,10 @@
import { API } from ".././tests/helpers/api";
import {
createPasteEvent,
parseClipboard,
serializeAsClipboardJSON,
} from "./clipboard";
import { API } from "./tests/helpers/api";
describe("parseClipboard()", () => {
it("should parse JSON as plaintext if not excalidraw-api/clipboard data", async () => {

View file

@ -2,12 +2,12 @@ import React from "react";
import { DEFAULT_SIDEBAR } from "@excalidraw/common";
import { DefaultSidebar } from "../src/index";
import { DefaultSidebar } from "../index";
import {
fireEvent,
waitFor,
withExcalidrawDimensions,
} from "../tests/test-utils";
} from "../../tests/test-utils";
import {
assertExcalidrawWithSidebar,

View file

@ -3,7 +3,7 @@ import { vi } from "vitest";
import { DEFAULT_SIDEBAR } from "@excalidraw/common";
import { Excalidraw, Sidebar } from "../../src/index";
import { Excalidraw, Sidebar } from "../../index";
import {
act,
fireEvent,
@ -12,7 +12,7 @@ import {
render,
waitFor,
withExcalidrawDimensions,
} from "../../tests/test-utils";
} from "../../../tests/test-utils";
import {
assertExcalidrawWithSidebar,

View file

@ -6,7 +6,7 @@ import {
queryByTestId,
render,
withExcalidrawDimensions,
} from "../../tests/test-utils";
} from "../../../tests/test-utils";
export const assertSidebarDockButton = async <T extends boolean>(
hasDockButton: T,

View file

@ -18,18 +18,18 @@ import type {
} from "@excalidraw/element/types";
import { Excalidraw, getCommonBounds, mutateElement } from "../..";
import { actionGroup } from "../../src/actions";
import { actionGroup } from "../../../src/actions";
import { t } from "../../i18n";
import * as StaticScene from "../../src/renderer/staticScene";
import { API } from "../../tests/helpers/api";
import { Keyboard, Pointer, UI } from "../../tests/helpers/ui";
import { getTextEditor, updateTextEditor } from "../../tests/queries/dom";
import * as StaticScene from "../../../src/renderer/staticScene";
import { API } from "../../../tests/helpers/api";
import { Keyboard, Pointer, UI } from "../../../tests/helpers/ui";
import { getTextEditor, updateTextEditor } from "../../../tests/queries/dom";
import {
GlobalTestState,
mockBoundingClientRect,
render,
restoreOriginalGetBoundingClientRect,
} from "../../tests/test-utils";
} from "../../../tests/test-utils";
import { getStepSizedValue } from "./utils";

View file

@ -1,7 +1,7 @@
import { render } from "@testing-library/react";
import { EditorJotaiProvider } from "../editor-jotai";
import fallbackLangData from "../src/locales/en.json";
import fallbackLangData from "../../src/locales/en.json";
import Trans from "./Trans";

View file

@ -2,14 +2,14 @@ import React from "react";
import { KEYS } from "@excalidraw/common";
import { Excalidraw } from "../../src/index";
import { Keyboard } from "../../tests/helpers/ui";
import { Excalidraw } from "../../index";
import { Keyboard } from "../../../tests/helpers/ui";
import {
render,
waitFor,
getByTestId,
fireEvent,
} from "../../tests/test-utils";
} from "../../../tests/test-utils";
describe("Test <DropdownMenu/>", () => {
it("should", async () => {

View file

@ -1,7 +1,7 @@
import React from "react";
import { Excalidraw, MainMenu } from "../../src/index";
import { render, queryAllByTestId } from "../../tests/test-utils";
import { Excalidraw, MainMenu } from "../../../src/index";
import { render, queryAllByTestId } from "../../../tests/test-utils";
describe("Test internal component fallback rendering", () => {
it("should render only one menu per excalidraw instance (custom menu first scenario)", async () => {

View file

@ -10,7 +10,7 @@ import type {
ImageCrop,
} from "@excalidraw/element/types";
import { Excalidraw, exportToCanvas, exportToSvg } from "..";
import { Excalidraw, exportToCanvas, exportToSvg } from "../src";
import { actionFlipHorizontal, actionFlipVertical } from "../src/actions";
import { API } from "./helpers/api";