wire up settings and theming
This commit is contained in:
parent
7dac1e275d
commit
e19f799046
5 changed files with 80 additions and 10 deletions
|
|
@ -186,6 +186,10 @@ export class StrudelMirror {
|
|||
this.root.style.backgroundColor = 'var(--background)';
|
||||
cmEditor.style.backgroundColor = 'transparent';
|
||||
}
|
||||
const settings = codemirrorSettings.get();
|
||||
this.setFontSize(settings.fontSize);
|
||||
this.setFontFamily(settings.fontFamily);
|
||||
|
||||
// stop this repl when another repl is started
|
||||
this.onStartRepl = (e) => {
|
||||
if (e.detail !== this.id) {
|
||||
|
|
|
|||
|
|
@ -62,10 +62,6 @@ export function repl({
|
|||
};
|
||||
setTime(() => scheduler.now()); // TODO: refactor?
|
||||
const evaluate = async (code, autostart = true, shouldHush = true) => {
|
||||
if (code === state.activeCode && state.started) {
|
||||
logger('[eval] skip: not dirty')
|
||||
return;
|
||||
}
|
||||
if (!code) {
|
||||
throw new Error('no code to evaluate');
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue