mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 20:52:56 +01:00
Merge pull request #3896 from microsoft/hediet/b/vicarious-sloth
Playground improvements
This commit is contained in:
commit
af0106a971
2 changed files with 11 additions and 5 deletions
|
|
@ -140,7 +140,7 @@ export class PlaygroundModel {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private readonly debouncer = new Debouncer(250);
|
private readonly debouncer = new Debouncer(700);
|
||||||
|
|
||||||
@observable
|
@observable
|
||||||
public isDirty = false;
|
public isDirty = false;
|
||||||
|
|
|
||||||
|
|
@ -133,10 +133,16 @@ export class PlaygroundPageContent extends React.Component<
|
||||||
checked={
|
checked={
|
||||||
model.settings.autoReload
|
model.settings.autoReload
|
||||||
}
|
}
|
||||||
onChange={(e) =>
|
onChange={(e) => {
|
||||||
(model.settings.autoReload =
|
model.settings.autoReload =
|
||||||
e.target.checked)
|
e.target.checked;
|
||||||
}
|
if (
|
||||||
|
e.target.checked &&
|
||||||
|
model.isDirty
|
||||||
|
) {
|
||||||
|
model.reload();
|
||||||
|
}
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
<Button
|
<Button
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue