add theme switcher

This commit is contained in:
lucy 2026-09-10 21:37:33 +02:00
commit d69ec48728
9 changed files with 126 additions and 68 deletions

View file

@ -0,0 +1,29 @@
pragma Singleton
import Quickshell
import Quickshell.Io
import QtQuick
Singleton {
id: root
property alias s: stateAdapter
property alias v: state
FileView {
id: state
path: Qt.resolvedUrl(Quickshell.shellDir + "/settings/state.json")
watchChanges: true
onLoadFailed: {
writeAdapter()
}
onAdapterUpdated: writeAdapter()
onFileChanged: reload()
adapter: JsonAdapter {
id: stateAdapter
property bool themeSwitcherVisible: false
}
}
Component.onCompleted: console.log("say gex")
}