Add variable color option

This commit is contained in:
Thomas Weber committed 2022-03-27 20:31:27 -05:00
1 parent 2c2fff6f8d
commit 738e49def2
3 files changed
+13 -1

No files matched your search

+3
View File
@@ -242,6 +242,9 @@
"editableLists": {
"string": "Editable lists"
},
"variableColor": {
"string": "Variable color"
},
"interaction": {
"string": "Input",
"context": "Input settings header"
+5
View File
@@ -429,6 +429,11 @@
<input type="checkbox" bind:checked={$options.monitors.editableLists}>
{$_('options.editableLists')}
</label>
<!-- svelte-ignore a11y-label-has-associated-control -->
<label class="option">
<ColorPicker bind:value={$options.monitors.variableColor} />
{$_('options.variableColor')}
</label>
</div>
</Section>
+5 -1
View File
@@ -917,6 +917,9 @@ cd "$(dirname "$0")"
.sc-canvas {
cursor: ${await this.generateCursor()};
}
.sc-monitor-root[opcode^="data_"] .sc-monitor-value-color {
background-color: ${this.options.monitors.variableColor} !important;
}
${this.options.custom.css}
</style>
<meta name="theme-color" content="${this.options.appearance.background}">
@@ -1286,7 +1289,8 @@ Packager.DEFAULT_OPTIONS = () => ({
}
},
monitors: {
editableLists: false
editableLists: false,
variableColor: '#ff8c1a'
},
compiler: {
enabled: true,