This commit is contained in:
James Stuckey Weber 2023-07-02 12:42:05 -04:00
parent 8853f9e5b4
commit 2f6dedd414
3 changed files with 9 additions and 9 deletions

View File

@ -47,7 +47,7 @@ function setupPlayground() {
},
});
// Setup input sass view
// Setup input Sass view
const editor = new EditorView({
doc: playgroundState.inputValue,
extensions: [
@ -58,7 +58,7 @@ function setupPlayground() {
}
}),
],
parent: document.querySelector('.sl-code-is-precompiled') || undefined,
parent: document.querySelector('.sl-code-is-source') || undefined,
});
// Setup CSS view

View File

@ -141,13 +141,13 @@
overflow: hidden auto;
}
// Precompiled and Compiled code container
// Source and Compiled code container
.sl-c-playground__code-editor-wrapper {
background-color: var(--sl-background--editor);
border: var(--sl-border--small) solid var(--sl-color--code-background-darker);
}
[data-code='precompiled'] {
[data-code='source'] {
--sl-background--editor: var(--sl-color--white);
grid-area: sass;
@ -198,7 +198,7 @@
}
&.cm-focused {
[data-code='precompiled'] & {
[data-code='source'] & {
outline: 1px solid var(--sl-color--warning-light);
}
@ -228,7 +228,7 @@
color: var(--sl-color--code-bright);
}
.sl-code-is-precompiled & {
.sl-code-is-source & {
cursor: text;
}
}
@ -287,7 +287,7 @@
--sl-color--button: var(--sl-color--pale-sky);
}
[data-code='precompiled'] & {
[data-code='source'] & {
[data-active='true'] {
--sl-background--button: var(--sl-color--white);
--sl-background--button-state: var(--sl-color--white);

View File

@ -5,7 +5,7 @@ is_playground: true
---
<div class="sl-c-playground" data-compiler-has-error="false">
<div class="sl-c-playground__code-editor-wrapper sl-c-playground__panel" data-code="precompiled">
<div class="sl-c-playground__code-editor-wrapper sl-c-playground__panel" data-code="source">
<div class="sl-c-playground__editor-tabbar" data-setting="inputFormat">
<button
type="button"
@ -23,7 +23,7 @@ is_playground: true
data-setting="inputFormat">Sass</button>
<span data-tabbar="item" class="sl-c-playground__tabbar-title tabbar-title sl-c-playground__tabbar-version"></span>
</div>
<div class="sl-c-playground__panel-content sl-code-is-precompiled"></div>
<div class="sl-c-playground__panel-content sl-code-is-source"></div>
</div>
<div class="sl-c-playground__code-editor-wrapper sl-c-playground__panel" data-code="compiled">
<div class="sl-c-playground__editor-tabbar" data-setting="outputFormat">