pragma Singleton pragma ComponentBehavior: Bound import QtQuick import Quickshell import Quickshell.Io Singleton { id: root property string filePath: Directories.shellColorConfigPath property alias options: colorConfigOptionsJsonAdpater property bool ready: false FileView { path: root.filePath watchChanges: true onFileChanged: reload() onLoaded: root.ready = true onLoadFailed: error => { if (error == FileViewError.FileNotFound) { writeAdapter(); } } JsonAdapter { id: colorConfigOptionsJsonAdpater property JsonObject m3colors: JsonObject { property color m3primary_paletteKeyColor: "#a3c9ff" property color m3secondary_paletteKeyColor: "#b2c8ea" property color m3tertiary_paletteKeyColor: "#ffb783" property color m3neutral_paletteKeyColor: "#c7c6c6" property color m3neutral_variant_paletteKeyColor: "#cbc4ce" property color m3background: "#111418" property color m3onBackground: "#e1e2e9" property color m3surface: "#111318" property color m3surfaceDim: "#111318" property color m3surfaceBright: "#37393e" property color m3surfaceContainerLowest: "#0c0e13" property color m3surfaceContainerLow: "#191c20" property color m3surfaceContainer: "#1d2024" property color m3surfaceContainerHigh: "#272a2f" property color m3surfaceContainerHighest: "#32353a" property color m3onSurface: "#e1e2e9" property color m3surfaceVariant: "#414751" property color m3onSurfaceVariant: "#c1c7d2" property color m3inverseSurface: "#e1e2e9" property color m3inverseOnSurface: "#2e3036" property color m3outline: "#8b919c" property color m3outlineVariant: "#414751" property color m3shadow: "#000000" property color m3scrim: "#000000" property color m3surfaceTint: "#e0e0e1" property color m3primary: "#a3c9ff" property color m3onPrimary: "#00315c" property color m3primaryContainer: "#1563ab" property color m3onPrimaryContainer: "#ffffff" property color m3inversePrimary: "#0e60a8" property color m3secondary: "#b2c8ea" property color m3onSecondary: "#1b314c" property color m3secondaryContainer: "#354a66" property color m3onSecondaryContainer: "#d6e5ff" property color m3tertiary: "#ffb783" property color m3onTertiary: "#4f2500" property color m3tertiaryContainer: "#984d00" property color m3onTertiaryContainer: "#ffffff" property color m3error: "#ffb4ab" property color m3onError: "#e1e2e9" property color m3errorContainer: "#93000a" property color m3onErrorContainer: "#ffdad6" property color m3primaryFixed: "#d3e3ff" property color m3primaryFixedDim: "#a3c9ff" property color m3onPrimaryFixed: "#001c39" property color m3onPrimaryFixedVariant: "#004882" property color m3secondaryFixed: "#d3e3ff" property color m3secondaryFixedDim: "#b2c8ea" property color m3onSecondaryFixed: "#031c36" property color m3onSecondaryFixedVariant: "#334864" property color m3tertiaryFixed: "#ffdcc5" property color m3tertiaryFixedDim: "#ffb783" property color m3onTertiaryFixed: "#301400" property color m3onTertiaryFixedVariant: "#703700" property color m3success: "#cee8dd" property color m3onSuccess: "#b1cdc1" property color m3successContainer: "#b2ccc2" property color m3onSuccessContainer: "#ffffff" } } } }