From f6199cfd9784a1e47d3fe4f45d3e6ad4d335bd2e Mon Sep 17 00:00:00 2001 From: 1ilit Date: Tue, 28 Nov 2023 23:08:45 +0200 Subject: [PATCH] Make `New window` a duplicate of the parent window --- src/components/ControlPanel.jsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/ControlPanel.jsx b/src/components/ControlPanel.jsx index 246b215..5e6de52 100644 --- a/src/components/ControlPanel.jsx +++ b/src/components/ControlPanel.jsx @@ -713,7 +713,10 @@ export default function ControlPanel({ function: () => setVisible(MODAL.NEW), }, "New window": { - function: () => window.open("/editor", "_blank"), + function: () => { + const newWindow = window.open("/editor", "_blank"); + newWindow.name = window.name; + }, }, Open: { function: open,