From 7cea13501d02093c5991159c6bd6611cd1e6e042 Mon Sep 17 00:00:00 2001 From: Imran Farhat Date: Tue, 16 Jun 2026 12:50:39 +0530 Subject: [PATCH] fix: replace backslashes with forward slashes in homeURL construction (Bug 14) Save-and-navigate dialogs shown when leaving the editor via Dashboard, Gallery, or Simulator nav links built homeURL as: ${window.location.protocol}\\${window.location.host}/... Browsers do not treat backslashes as a protocol separator, so window.open()/window.location navigation with this malformed URL fails silently instead of navigating to the intended destination, leaving the dialog appearing stuck even after a successful save. Fix: use // instead of \\ in all 4 occurrences (HomeDialog and SchematicNameDialog, both the 'home' and routeVal branches). --- .../src/components/SchematicEditor/ToolbarExtension.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/eda-frontend/src/components/SchematicEditor/ToolbarExtension.js b/eda-frontend/src/components/SchematicEditor/ToolbarExtension.js index 7a8e5d1fa..102168df7 100644 --- a/eda-frontend/src/components/SchematicEditor/ToolbarExtension.js +++ b/eda-frontend/src/components/SchematicEditor/ToolbarExtension.js @@ -497,9 +497,9 @@ export function HomeDialog ({ open, gridRef, routeVal, onClose, schSave }) { }, [dispatch]) var homeURL = '' if (routeVal === 'home') { - homeURL = `${window.location.protocol}\\\\${window.location.host}/` + homeURL = `${window.location.protocol}//${window.location.host}/` } else { - homeURL = `${window.location.protocol}\\\\${window.location.host}/eda/#/${routeVal}` + homeURL = `${window.location.protocol}//${window.location.host}/eda/#/${routeVal}` } console.log(homeURL) @@ -584,9 +584,9 @@ export function SchematicNameDialog ({ open, gridRef, routeVal, onClose, schSave var homeURL = '' console.log(routeVal) if (routeVal === 'home') { - homeURL = `${window.location.protocol}\\\\${window.location.host}/` + homeURL = `${window.location.protocol}//${window.location.host}/` } else { - homeURL = `${window.location.protocol}\\\\${window.location.host}/eda/#/${routeVal}` + homeURL = `${window.location.protocol}//${window.location.host}/eda/#/${routeVal}` } console.log(homeURL)