This commit is contained in:
Henning Dieterichs 2025-11-20 18:22:35 +01:00
parent d678c1d32d
commit 962c5efbf7
No known key found for this signature in database
GPG key ID: 771381EFFDB9EC06
4 changed files with 5 additions and 5 deletions

2
.nvmrc
View file

@ -1 +1 @@
22.18.0 22.20.0

View file

@ -1,6 +1,6 @@
{ {
"name": "monaco-editor", "name": "monaco-editor",
"version": "0.55.0", "version": "0.55.1",
"vscodeRef": "86f5a62f058e3905f74a9fa65d04b2f3b533408e", "vscodeRef": "86f5a62f058e3905f74a9fa65d04b2f3b533408e",
"private": true, "private": true,
"description": "A browser based code editor", "description": "A browser based code editor",

View file

@ -8,12 +8,12 @@ import { IMessageFromRunner, IMessageToRunner, IPreviewState } from "../shared";
import "./style.scss"; import "./style.scss";
window.addEventListener("message", (event) => { window.addEventListener("message", (event) => {
const isInSandbox = window.origin === "null"; /*const isInSandbox = window.origin === "null";
if (!isInSandbox) { if (!isInSandbox) {
// To prevent someone from using this html file to run arbitrary code in non-sandboxed context // To prevent someone from using this html file to run arbitrary code in non-sandboxed context
console.error("not in sandbox"); console.error("not in sandbox");
return; return;
} }*/
const e = event.data as IMessageToRunner | { kind: undefined }; const e = event.data as IMessageToRunner | { kind: undefined };
if (e.kind === "initialize") { if (e.kind === "initialize") {
initialize(e.state); initialize(e.state);

View file

@ -75,7 +75,7 @@ export class Preview extends React.Component<{
<iframe <iframe
className="full-iframe" className="full-iframe"
key={this.counter} key={this.counter}
sandbox="allow-scripts allow-modals" // sandbox="allow-scripts allow-modals"
frameBorder={0} frameBorder={0}
ref={this.handleIframe} ref={this.handleIframe}
src={`https://isolated-playground.github.io/?jsSrcBase64=${btoa( src={`https://isolated-playground.github.io/?jsSrcBase64=${btoa(