Add Sonic Pi theme

This commit is contained in:
Stephen Jianu 2026-01-25 15:34:07 -06:00
commit 74cced0d4a
3 changed files with 15 additions and 0 deletions

View file

@ -436,6 +436,17 @@ function Donsol () {
b_low: '#fdf6e3', b_low: '#fdf6e3',
b_inv: '#cb4b16' b_inv: '#cb4b16'
} }
this.sonicPiTheme = {
background: '#ffffff',
f_high: '#000000',
f_med: '#ed1e92',
f_low: '#aaaaaa',
f_inv: '#ffffff',
b_high: '#444444',
b_med: '#555555',
b_low: '#ced0ce',
b_inv: '#ed1e92'
}
this.tapeTheme = { this.tapeTheme = {
background: '#dad7cd', background: '#dad7cd',
f_high: '#696861', f_high: '#696861',

View file

@ -266,6 +266,9 @@ function Player () {
if (theme_value.localeCompare('solarizedLight') === 0) { if (theme_value.localeCompare('solarizedLight') === 0) {
new_theme = donsol.solarizedLightTheme new_theme = donsol.solarizedLightTheme
} }
if (theme_value.localeCompare('sonicPi') === 0) {
new_theme = donsol.sonicPiTheme
}
if (theme_value.localeCompare('tape') === 0) { if (theme_value.localeCompare('tape') === 0) {
new_theme = donsol.tapeTheme new_theme = donsol.tapeTheme
} }

View file

@ -49,6 +49,7 @@ function Settings () {
this.theme_button.innerHTML += '<option value=\"snow\">Snow</option>' this.theme_button.innerHTML += '<option value=\"snow\">Snow</option>'
this.theme_button.innerHTML += '<option value=\"solarizedDark\">Solarized Dark</option>' this.theme_button.innerHTML += '<option value=\"solarizedDark\">Solarized Dark</option>'
this.theme_button.innerHTML += '<option value=\"solarizedLight\">Solarized Light</option>' this.theme_button.innerHTML += '<option value=\"solarizedLight\">Solarized Light</option>'
this.theme_button.innerHTML += '<option value=\"sonicPi\">Sonic Pi</option>'
this.theme_button.innerHTML += '<option value=\"tape\">Tape</option>' this.theme_button.innerHTML += '<option value=\"tape\">Tape</option>'
this.theme_button.addEventListener('mousedown', () => { donsol.player.change_theme(this.theme_button.value) }) this.theme_button.addEventListener('mousedown', () => { donsol.player.change_theme(this.theme_button.value) })
this.theme_button.addEventListener('change', () => { donsol.player.change_theme(this.theme_button.value) }) this.theme_button.addEventListener('change', () => { donsol.player.change_theme(this.theme_button.value) })