Skip to content

Commit 9ad6c31

Browse files
authored
Remove blob URL dead code and clean up more frontend code (#2199)
1 parent 1e62af8 commit 9ad6c31

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+107
-247
lines changed

editor/src/messages/frontend/frontend_message.rs

-17
Original file line numberDiff line numberDiff line change
@@ -58,17 +58,7 @@ pub enum FrontendMessage {
5858
#[serde(rename = "commitDate")]
5959
commit_date: String,
6060
},
61-
TriggerCopyToClipboardBlobUrl {
62-
#[serde(rename = "blobUrl")]
63-
blob_url: String,
64-
},
6561
TriggerDelayedZoomCanvasToFitAll,
66-
TriggerDownloadBlobUrl {
67-
#[serde(rename = "layerName")]
68-
layer_name: String,
69-
#[serde(rename = "blobUrl")]
70-
blob_url: String,
71-
},
7262
TriggerDownloadImage {
7363
svg: String,
7464
name: String,
@@ -99,9 +89,6 @@ pub enum FrontendMessage {
9989
TriggerLoadPreferences,
10090
TriggerOpenDocument,
10191
TriggerPaste,
102-
TriggerRevokeBlobUrl {
103-
url: String,
104-
},
10592
TriggerSavePreferences {
10693
preferences: PreferencesMessageHandler,
10794
},
@@ -294,8 +281,4 @@ pub enum FrontendMessage {
294281
layout_target: LayoutTarget,
295282
diff: Vec<WidgetDiff>,
296283
},
297-
UpdateZoomWithScroll {
298-
#[serde(rename = "zoomWithScroll")]
299-
zoom_with_scroll: bool,
300-
},
301284
}

editor/src/messages/portfolio/document/document_message_handler.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1695,7 +1695,7 @@ impl DocumentMessageHandler {
16951695
.unwrap_or(0)
16961696
}
16971697

1698-
/// Loads layer resources such as creating the blob URLs for the images and loading all of the fonts in the document.
1698+
/// Loads all of the fonts in the document.
16991699
pub fn load_layer_resources(&self, responses: &mut VecDeque<Message>) {
17001700
let mut fonts = HashSet::new();
17011701
for (_node_id, node) in self.document_network().recursive_nodes() {

editor/src/messages/portfolio/portfolio_message_handler.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ impl MessageHandler<PortfolioMessage, PortfolioMessageData<'_>> for PortfolioMes
304304
let () = fut.await;
305305
use wasm_bindgen::prelude::*;
306306

307-
#[wasm_bindgen(module = "/../frontend/src/wasm-communication/editor.ts")]
307+
#[wasm_bindgen(module = "/../frontend/src/editor.ts")]
308308
extern "C" {
309309
#[wasm_bindgen(js_name = injectImaginatePollServerStatus)]
310310
fn inject();

editor/src/messages/preferences/preferences_message_handler.rs

-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ impl MessageHandler<PreferencesMessage, ()> for PreferencesMessageHandler {
9696
true => MappingVariant::ZoomWithScroll,
9797
};
9898
responses.add(KeyMappingMessage::ModifyMapping(variant));
99-
responses.add(FrontendMessage::UpdateZoomWithScroll { zoom_with_scroll });
10099
}
101100
}
102101

frontend/src/App.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
import { onMount, onDestroy } from "svelte";
33
4-
import { type Editor as GraphiteEditor, initWasm, createEditor } from "@graphite/wasm-communication/editor";
4+
import { type Editor as GraphiteEditor, initWasm, createEditor } from "@graphite/editor";
55
66
import Editor from "@graphite/components/Editor.svelte";
77

frontend/src/README.md

+3-7
Original file line numberDiff line numberDiff line change
@@ -26,21 +26,17 @@ _Some state providers, similarly to I/O managers, may subscribe to backend event
2626

2727
TypeScript files which define and `export` individual helper functions for use elsewhere in the codebase. These files should not persist state outside each function.
2828

29-
## WASM communication: `wasm-communication/`
30-
31-
TypeScript files which serve as the JS interface to the WASM bindings for the editor backend.
32-
33-
### WASM editor: `editor.ts`
29+
## WASM editor: `editor.ts`
3430

3531
Instantiates the WASM and editor backend instances. The function `initWasm()` asynchronously constructs and initializes an instance of the WASM bindings JS module provided by wasm-bindgen/wasm-pack. The function `createEditor()` constructs an instance of the editor backend. In theory there could be multiple editor instances sharing the same WASM module instance. The function returns an object where `raw` is the WASM module, `instance` is the editor, and `subscriptions` is the subscription router (described below).
3632

3733
`initWasm()` occurs in `main.ts` right before the Svelte application exists, then `createEditor()` is run in `Editor.svelte` during the Svelte app's creation. Similarly to the state providers described above, the editor is given via `setContext()` so other components can get it via `getContext` and call functions on `editor.raw`, `editor.handle`, or `editor.subscriptions`.
3834

39-
### Message definitions: `messages.ts`
35+
## Message definitions: `messages.ts`
4036

4137
Defines the message formats and data types received from the backend. Since Rust and JS support different styles of data representation, this bridges the gap from Rust into JS land. Messages (and the data contained within) are serialized in Rust by `serde` into JSON, and these definitions are manually kept up-to-date to parallel the message structs and their data types. (However, directives like `#[serde(skip)]` or `#[serde(rename = "someOtherName")]` may cause the TypeScript format to look slightly different from the Rust structs.) These definitions are basically just for the sake of TypeScript to understand the format, although in some cases we may perform data conversion here using translation functions that we can provide.
4238

43-
### Subscription router: `subscription-router.ts`
39+
## Subscription router: `subscription-router.ts`
4440

4541
Associates messages from the backend with subscribers in the frontend, and routes messages to subscriber callbacks. This module provides a `subscribeJsMessage(messageType, callback)` function which JS code throughout the frontend can call to be registered as the exclusive handler for a chosen message type. This file's other exported function, `handleJsMessage(messageType, messageData, wasm, instance)`, is called in `editor.ts` by the associated editor instance when the backend sends a `FrontendMessage`. When this occurs, the subscription router delivers the message to the subscriber for given `messageType` by executing its registered `callback` function. As an argument to the function, it provides the `messageData` payload transformed into its TypeScript-friendly format defined in `messages.ts`.
4642

frontend/src/components/Editor.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<script lang="ts">
22
import { onMount, onDestroy, setContext } from "svelte";
33
4+
import { type Editor } from "@graphite/editor";
45
import { createClipboardManager } from "@graphite/io-managers/clipboard";
56
import { createDragManager } from "@graphite/io-managers/drag";
67
import { createHyperlinkManager } from "@graphite/io-managers/hyperlinks";
@@ -15,7 +16,6 @@
1516
import { createNodeGraphState } from "@graphite/state-providers/node-graph";
1617
import { createPortfolioState } from "@graphite/state-providers/portfolio";
1718
import { operatingSystem } from "@graphite/utility-functions/platform";
18-
import { type Editor } from "@graphite/wasm-communication/editor";
1919
2020
import MainWindow from "@graphite/components/window/MainWindow.svelte";
2121

frontend/src/components/floating-menus/ColorPicker.svelte

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<script lang="ts">
22
import { onDestroy, createEventDispatcher, getContext } from "svelte";
33
4+
import type { Editor } from "@graphite/editor";
5+
import type { HSV, RGB, FillChoice } from "@graphite/messages";
6+
import { Color, Gradient } from "@graphite/messages";
47
import { clamp } from "@graphite/utility-functions/math";
5-
import type { Editor } from "@graphite/wasm-communication/editor";
6-
import type { HSV, RGB, FillChoice } from "@graphite/wasm-communication/messages";
7-
import { Color, Gradient } from "@graphite/wasm-communication/messages";
88
99
import FloatingMenu, { type MenuDirection } from "@graphite/components/layout/FloatingMenu.svelte";
1010
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";

frontend/src/components/floating-menus/MenuList.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<script lang="ts">
44
import { createEventDispatcher, tick, onDestroy, onMount } from "svelte";
55
6-
import type { MenuListEntry } from "@graphite/wasm-communication/messages";
6+
import type { MenuListEntry } from "@graphite/messages";
77
88
import MenuList from "@graphite/components/floating-menus/MenuList.svelte";
99
import FloatingMenu, { type MenuDirection } from "@graphite/components/layout/FloatingMenu.svelte";

frontend/src/components/floating-menus/NodeCatalog.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { createEventDispatcher, getContext, onMount } from "svelte";
33
4+
import type { FrontendNodeType } from "@graphite/messages";
45
import type { NodeGraphState } from "@graphite/state-providers/node-graph";
5-
import type { FrontendNodeType } from "@graphite/wasm-communication/messages";
66
77
import TextButton from "@graphite/components/widgets/buttons/TextButton.svelte";
88
import TextInput from "@graphite/components/widgets/inputs/TextInput.svelte";

frontend/src/components/panels/Document.svelte

+17-17
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
<script lang="ts">
22
import { getContext, onMount, tick } from "svelte";
33
4-
import type { DocumentState } from "@graphite/state-providers/document";
5-
import { textInputCleanup } from "@graphite/utility-functions/keyboard-entry";
6-
import { extractPixelData, rasterizeSVGCanvas } from "@graphite/utility-functions/rasterization";
7-
import { updateBoundsOfViewports } from "@graphite/utility-functions/viewports";
8-
import type { Editor } from "@graphite/wasm-communication/editor";
4+
import type { Editor } from "@graphite/editor";
95
import {
106
type MouseCursorIcon,
117
type XY,
@@ -19,7 +15,11 @@
1915
UpdateEyedropperSamplingState,
2016
UpdateMouseCursor,
2117
isWidgetSpanRow,
22-
} from "@graphite/wasm-communication/messages";
18+
} from "@graphite/messages";
19+
import type { DocumentState } from "@graphite/state-providers/document";
20+
import { textInputCleanup } from "@graphite/utility-functions/keyboard-entry";
21+
import { extractPixelData, rasterizeSVGCanvas } from "@graphite/utility-functions/rasterization";
22+
import { updateBoundsOfViewports } from "@graphite/utility-functions/viewports";
2323
2424
import EyedropperPreview, { ZOOM_WINDOW_DIMENSIONS } from "@graphite/components/floating-menus/EyedropperPreview.svelte";
2525
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";
@@ -275,17 +275,17 @@
275275
// This isn't very clean but it's good enough for now until we need more icons, then we can build something more robust (consider blob URLs)
276276
if (cursor === "custom-rotate") {
277277
const svg = `
278-
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" width="20" height="20">
279-
<path transform="translate(2 2)" fill="black" stroke="black" stroke-width="2px" d="
280-
M8,15.2C4,15.2,0.8,12,0.8,8C0.8,4,4,0.8,8,0.8c2,0,3.9,0.8,5.3,2.3l-1,1C11.2,2.9,9.6,2.2,8,2.2C4.8,2.2,2.2,4.8,2.2,8s2.6,5.8,5.8,5.8s5.8-2.6,5.8-5.8h1.4C15.2,12,12,15.2,8,15.2z
281-
" />
282-
<polygon transform="translate(2 2)" fill="black" stroke="black" stroke-width="2px" points="12.6,0 15.5,5 9.7,5" />
283-
<path transform="translate(2 2)" fill="white" d="
284-
M8,15.2C4,15.2,0.8,12,0.8,8C0.8,4,4,0.8,8,0.8c2,0,3.9,0.8,5.3,2.3l-1,1C11.2,2.9,9.6,2.2,8,2.2C4.8,2.2,2.2,4.8,2.2,8s2.6,5.8,5.8,5.8s5.8-2.6,5.8-5.8h1.4C15.2,12,12,15.2,8,15.2z
285-
" />
286-
<polygon transform="translate(2 2)" fill="white" points="12.6,0 15.5,5 9.7,5" />
287-
</svg>
288-
`
278+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" width="20" height="20">
279+
<path transform="translate(2 2)" fill="black" stroke="black" stroke-width="2px" d="
280+
M8,15.2C4,15.2,0.8,12,0.8,8C0.8,4,4,0.8,8,0.8c2,0,3.9,0.8,5.3,2.3l-1,1C11.2,2.9,9.6,2.2,8,2.2C4.8,2.2,2.2,4.8,2.2,8s2.6,5.8,5.8,5.8s5.8-2.6,5.8-5.8h1.4C15.2,12,12,15.2,8,15.2z
281+
" />
282+
<polygon transform="translate(2 2)" fill="black" stroke="black" stroke-width="2px" points="12.6,0 15.5,5 9.7,5" />
283+
<path transform="translate(2 2)" fill="white" d="
284+
M8,15.2C4,15.2,0.8,12,0.8,8C0.8,4,4,0.8,8,0.8c2,0,3.9,0.8,5.3,2.3l-1,1C11.2,2.9,9.6,2.2,8,2.2C4.8,2.2,2.2,4.8,2.2,8s2.6,5.8,5.8,5.8s5.8-2.6,5.8-5.8h1.4C15.2,12,12,15.2,8,15.2z
285+
" />
286+
<polygon transform="translate(2 2)" fill="white" points="12.6,0 15.5,5 9.7,5" />
287+
</svg>
288+
`
289289
.split("\n")
290290
.map((line) => line.trim())
291291
.join("");

frontend/src/components/panels/Layers.svelte

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
<script lang="ts">
22
import { getContext, onMount, tick } from "svelte";
33
4+
import type { Editor } from "@graphite/editor";
45
import { beginDraggingElement } from "@graphite/io-managers/drag";
6+
import { defaultWidgetLayout, patchWidgetLayout, UpdateDocumentLayerDetails, UpdateDocumentLayerStructureJs, UpdateLayersPanelControlBarLayout } from "@graphite/messages";
7+
import type { DataBuffer, LayerPanelEntry } from "@graphite/messages";
58
import type { NodeGraphState } from "@graphite/state-providers/node-graph";
69
import { platformIsMac } from "@graphite/utility-functions/platform";
710
import { extractPixelData } from "@graphite/utility-functions/rasterization";
8-
import type { Editor } from "@graphite/wasm-communication/editor";
9-
import { defaultWidgetLayout, patchWidgetLayout, UpdateDocumentLayerDetails, UpdateDocumentLayerStructureJs, UpdateLayersPanelControlBarLayout } from "@graphite/wasm-communication/messages";
10-
import type { DataBuffer, LayerPanelEntry } from "@graphite/wasm-communication/messages";
1111
1212
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";
1313
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";

frontend/src/components/panels/Properties.svelte

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { getContext, onMount } from "svelte";
33
4-
import type { Editor } from "@graphite/wasm-communication/editor";
5-
import { defaultWidgetLayout, patchWidgetLayout, UpdatePropertyPanelSectionsLayout } from "@graphite/wasm-communication/messages";
4+
import type { Editor } from "@graphite/editor";
5+
import { defaultWidgetLayout, patchWidgetLayout, UpdatePropertyPanelSectionsLayout } from "@graphite/messages";
66
77
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";
88
import WidgetLayout from "@graphite/components/widgets/WidgetLayout.svelte";

frontend/src/components/views/Graph.svelte

+6-4
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
<script lang="ts">
22
import { getContext, onMount, tick } from "svelte";
3+
import { cubicInOut } from "svelte/easing";
34
import { fade } from "svelte/transition";
45
5-
import { FADE_TRANSITION } from "@graphite/consts";
6+
import type { Editor } from "@graphite/editor";
7+
import type { Node } from "@graphite/messages";
8+
import type { FrontendNodeWire, FrontendNode, FrontendGraphInput, FrontendGraphOutput, FrontendGraphDataType, WirePath } from "@graphite/messages";
69
import type { NodeGraphState } from "@graphite/state-providers/node-graph";
710
import type { IconName } from "@graphite/utility-functions/icons";
8-
import type { Editor } from "@graphite/wasm-communication/editor";
9-
import type { Node } from "@graphite/wasm-communication/messages";
10-
import type { FrontendNodeWire, FrontendNode, FrontendGraphInput, FrontendGraphOutput, FrontendGraphDataType, WirePath } from "@graphite/wasm-communication/messages";
1111
1212
import NodeCatalog from "@graphite/components/floating-menus/NodeCatalog.svelte";
1313
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";
@@ -18,8 +18,10 @@
1818
import IconLabel from "@graphite/components/widgets/labels/IconLabel.svelte";
1919
import Separator from "@graphite/components/widgets/labels/Separator.svelte";
2020
import TextLabel from "@graphite/components/widgets/labels/TextLabel.svelte";
21+
2122
const GRID_COLLAPSE_SPACING = 10;
2223
const GRID_SIZE = 24;
24+
const FADE_TRANSITION = { duration: 200, easing: cubicInOut };
2325
2426
const editor = getContext<Editor>("editor");
2527
const nodeGraph = getContext<NodeGraphState>("nodeGraph");

frontend/src/components/widgets/WidgetLayout.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { isWidgetSpanColumn, isWidgetSpanRow, isWidgetSection, type WidgetLayout } from "@graphite/wasm-communication/messages";
2+
import { isWidgetSpanColumn, isWidgetSpanRow, isWidgetSection, type WidgetLayout } from "@graphite/messages";
33
44
import WidgetSection from "@graphite/components/widgets/WidgetSection.svelte";
55
import WidgetSpan from "@graphite/components/widgets/WidgetSpan.svelte";

frontend/src/components/widgets/WidgetSection.svelte

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { getContext } from "svelte";
33
4-
import type { Editor } from "@graphite/wasm-communication/editor";
5-
import { isWidgetSpanRow, isWidgetSpanColumn, isWidgetSection, type WidgetSection as WidgetSectionFromJsMessages } from "@graphite/wasm-communication/messages";
4+
import type { Editor } from "@graphite/editor";
5+
import { isWidgetSpanRow, isWidgetSpanColumn, isWidgetSection, type WidgetSection as WidgetSectionFromJsMessages } from "@graphite/messages";
66
77
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";
88
import IconButton from "@graphite/components/widgets/buttons/IconButton.svelte";

frontend/src/components/widgets/WidgetSpan.svelte

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<script lang="ts">
22
import { getContext } from "svelte";
33
4+
import type { Editor } from "@graphite/editor";
5+
import type { Widget, WidgetSpanColumn, WidgetSpanRow } from "@graphite/messages";
6+
import { narrowWidgetProps, isWidgetSpanColumn, isWidgetSpanRow } from "@graphite/messages";
47
import { debouncer } from "@graphite/utility-functions/debounce";
5-
import type { Editor } from "@graphite/wasm-communication/editor";
6-
import type { Widget, WidgetSpanColumn, WidgetSpanRow } from "@graphite/wasm-communication/messages";
7-
import { narrowWidgetProps, isWidgetSpanColumn, isWidgetSpanRow } from "@graphite/wasm-communication/messages";
88
99
import NodeCatalog from "@graphite/components/floating-menus/NodeCatalog.svelte";
1010
import BreadcrumbTrailButtons from "@graphite/components/widgets/buttons/BreadcrumbTrailButtons.svelte";

frontend/src/components/widgets/buttons/ColorButton.svelte

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { createEventDispatcher } from "svelte";
33
4-
import type { FillChoice } from "@graphite/wasm-communication/messages";
5-
import { Color, Gradient } from "@graphite/wasm-communication/messages";
4+
import type { FillChoice } from "@graphite/messages";
5+
import { Color, Gradient } from "@graphite/messages";
66
77
import ColorPicker from "@graphite/components/floating-menus/ColorPicker.svelte";
88
import LayoutCol from "@graphite/components/layout/LayoutCol.svelte";

frontend/src/components/widgets/buttons/ParameterExposeButton.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import type { FrontendGraphDataType } from "@graphite/wasm-communication/messages";
2+
import type { FrontendGraphDataType } from "@graphite/messages";
33
44
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";
55

frontend/src/components/widgets/buttons/TextButton.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<script lang="ts">
2+
import type { MenuListEntry } from "@graphite/messages";
23
import type { IconName } from "@graphite/utility-functions/icons";
3-
import type { MenuListEntry } from "@graphite/wasm-communication/messages";
44
55
import MenuList from "@graphite/components/floating-menus/MenuList.svelte";
66
import ConditionalWrapper from "@graphite/components/layout/ConditionalWrapper.svelte";

frontend/src/components/widgets/inputs/CurveInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { createEventDispatcher } from "svelte";
33
4+
import type { Curve, CurveManipulatorGroup } from "@graphite/messages";
45
import { clamp } from "@graphite/utility-functions/math";
5-
import type { Curve, CurveManipulatorGroup } from "@graphite/wasm-communication/messages";
66
77
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";
88

frontend/src/components/widgets/inputs/DropdownInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
import { createEventDispatcher } from "svelte";
33
4-
import type { MenuListEntry } from "@graphite/wasm-communication/messages";
4+
import type { MenuListEntry } from "@graphite/messages";
55
66
import MenuList from "@graphite/components/floating-menus/MenuList.svelte";
77
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";

frontend/src/components/widgets/inputs/FontInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<script lang="ts">
22
import { createEventDispatcher, getContext, onMount, tick } from "svelte";
33
4+
import type { MenuListEntry } from "@graphite/messages";
45
import type { FontsState } from "@graphite/state-providers/fonts";
5-
import type { MenuListEntry } from "@graphite/wasm-communication/messages";
66
77
import MenuList from "@graphite/components/floating-menus/MenuList.svelte";
88
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";

frontend/src/components/widgets/inputs/NumberInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
import { createEventDispatcher, onMount, onDestroy } from "svelte";
33
4-
import { type NumberInputMode, type NumberInputIncrementBehavior } from "@graphite/wasm-communication/messages";
4+
import { type NumberInputMode, type NumberInputIncrementBehavior } from "@graphite/messages";
55
import { evaluateMathExpression } from "@graphite-frontend/wasm/pkg/graphite_wasm.js";
66
77
import FieldInput from "@graphite/components/widgets/inputs/FieldInput.svelte";

frontend/src/components/widgets/inputs/PivotInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
import { createEventDispatcher } from "svelte";
33
4-
import type { PivotPosition } from "@graphite/wasm-communication/messages";
4+
import type { PivotPosition } from "@graphite/messages";
55
66
const dispatch = createEventDispatcher<{ position: PivotPosition }>();
77

frontend/src/components/widgets/inputs/RadioInput.svelte

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
import { createEventDispatcher } from "svelte";
33
4-
import { type RadioEntries, type RadioEntryData } from "@graphite/wasm-communication/messages";
4+
import { type RadioEntries, type RadioEntryData } from "@graphite/messages";
55
66
import LayoutRow from "@graphite/components/layout/LayoutRow.svelte";
77
import IconLabel from "@graphite/components/widgets/labels/IconLabel.svelte";

0 commit comments

Comments
 (0)