Initial commit

This commit is contained in:
ly-sec 2025-07-11 14:14:28 +02:00
commit a8c2f88654
53 changed files with 9269 additions and 0 deletions

48
Settings/Settings.qml Normal file
View file

@ -0,0 +1,48 @@
pragma Singleton
import QtQuick
import QtCore
QtObject {
property string weatherCity: "Dinslaken"
property string profileImage: "https://cdn.discordapp.com/avatars/158005126638993408/de403f05fd7f74bb17e01a9b066a30fa?size=64"
property bool useFahrenheit
property string wallpaperFolder: "/home/lysec/nixos/assets/wallpapers" // Default path, make persistent
property string currentWallpaper: ""
property string videoPath: "~/Videos/" // Default path, make persistent
// Settings persistence
property var settings: Qt.createQmlObject('import QtCore; Settings { category: "Quickshell" }', this, "settings")
Component.onCompleted: {
loadSettings()
}
function loadSettings() {
let wc = settings.value("weatherCity", "Dinslaken");
weatherCity = (wc !== undefined && wc !== null) ? wc : "Dinslaken";
let pi = settings.value("profileImage", "https://cdn.discordapp.com/avatars/158005126638993408/de403f05fd7f74bb17e01a9b066a30fa?size=64");
profileImage = (pi !== undefined && pi !== null) ? pi : "https://cdn.discordapp.com/avatars/158005126638993408/de403f05fd7f74bb17e01a9b066a30fa?size=64";
let tempUnit = settings.value("weatherTempUnit", "celsius")
useFahrenheit = (tempUnit === "fahrenheit")
wallpaperFolder = settings.value("wallpaperFolder", "/home/lysec/nixos/assets/wallpapers")
currentWallpaper = settings.value("currentWallpaper", "")
videoPath = settings.value("videoPath", "/home/lysec/Videos")
console.log("Loaded profileImage:", profileImage)
}
function saveSettings() {
settings.setValue("weatherCity", weatherCity)
settings.setValue("profileImage", profileImage)
settings.setValue("weatherTempUnit", useFahrenheit ? "fahrenheit" : "celsius")
settings.setValue("wallpaperFolder", wallpaperFolder)
settings.setValue("currentWallpaper", currentWallpaper)
settings.setValue("videoPath", videoPath)
settings.sync()
console.log("Saving profileImage:", profileImage)
}
// Property change handlers to auto-save (all commented out for explicit save only)
// onWeatherCityChanged: saveSettings()
// onProfileImageChanged: saveSettings()
// onUseFahrenheitChanged: saveSettings()
}

40
Settings/Theme.qml Normal file
View file

@ -0,0 +1,40 @@
// Theme.qml
pragma Singleton
import QtQuick
QtObject {
// Backgrounds
readonly property color backgroundPrimary: "#0C0D11" // Deep indigo-black
readonly property color backgroundSecondary: "#151720" // Slightly lifted dark
readonly property color backgroundTertiary: "#1D202B" // Soft contrast surface
// Surfaces & Elevation
readonly property color surface: "#1A1C26" // Material-like base layer
readonly property color surfaceVariant: "#2A2D3A" // Lightly elevated
// Text Colors
readonly property color textPrimary: "#CACEE2" // Gentle off-white
readonly property color textSecondary: "#B7BBD0" // Muted lavender-blue
readonly property color textDisabled: "#6B718A" // Dimmed blue-gray
// Accent Colors (lavender-gold theme)
readonly property color accentPrimary: "#A8AEFF" // Light enchanted lavender
readonly property color accentSecondary: "#9EA0FF" // Softer lavender hue
readonly property color accentTertiary: "#8EABFF" // Warm golden glow (from lantern)
// Error/Warning
readonly property color error: "#FF6B81" // Soft rose red
readonly property color warning: "#FFBB66" // Candlelight amber-orange
// Highlights & Focus
readonly property color highlight: "#E3C2FF" // Bright magical lavender
readonly property color rippleEffect: "#F3DEFF" // Gentle soft splash
// Additional Theme Properties
readonly property color onAccent: "#1A1A1A" // Text on accent background
readonly property color outline: "#44485A" // Subtle bluish-gray line
// Shadows & Overlays
readonly property color shadow: "#000000B3" // Standard soft black shadow
readonly property color overlay: "#11121ACC" // Deep bluish overlay
}