better hot reloading for themes
This commit is contained in:
parent
558b35f4fd
commit
919fed493b
2 changed files with 74 additions and 30 deletions
|
@ -779,6 +779,10 @@ const app = new Vue({
|
|||
|
||||
MusicKit.getInstance().videoContainerElement = document.getElementById("apple-music-video-player")
|
||||
|
||||
ipcRenderer.on('theme-update', (event, arg) => {
|
||||
less.refresh(true, true, true)
|
||||
})
|
||||
|
||||
ipcRenderer.on('SoundCheckTag', (event, tag) => {
|
||||
let replaygain = self.parseSCTagToRG(tag)
|
||||
try {
|
||||
|
@ -906,6 +910,7 @@ const app = new Vue({
|
|||
if (theme == "") {
|
||||
theme = this.cfg.visual.theme
|
||||
} else {
|
||||
this.cfg.visual.theme = ""
|
||||
this.cfg.visual.theme = theme
|
||||
}
|
||||
this.chrome.appliedTheme.info = await (await fetch("themes/" + app.cfg.visual.theme.replace("index.less", "theme.json"))).json()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue