From 911661930ac7a5f8057bae0c436bbf762bf247ca Mon Sep 17 00:00:00 2001 From: Brian Holmes <120223836+briangregoryholmes@users.noreply.github.com> Date: Thu, 16 May 2024 11:08:12 -0400 Subject: [PATCH] Fix: Model editor revert button (#4916) --- .../src/features/models/workspace/ModelEditor.svelte | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/web-common/src/features/models/workspace/ModelEditor.svelte b/web-common/src/features/models/workspace/ModelEditor.svelte index 9192d1fb76c..4ac90180c92 100644 --- a/web-common/src/features/models/workspace/ModelEditor.svelte +++ b/web-common/src/features/models/workspace/ModelEditor.svelte @@ -292,6 +292,13 @@ } function revertContent() { + editor?.dispatch({ + changes: { + from: 0, + to: editor.state.doc.length, + insert: blob, + }, + }); dispatch("revert"); }