works
This commit is contained in:
@@ -15,7 +15,7 @@ ClippingWrapperRectangle {
|
|||||||
radius: 10
|
radius: 10
|
||||||
|
|
||||||
color: "black"
|
color: "black"
|
||||||
//color: Pywal.special.background
|
//color: Settings.special.background
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
@@ -23,31 +23,31 @@ ClippingWrapperRectangle {
|
|||||||
id: error
|
id: error
|
||||||
text: ""
|
text: ""
|
||||||
color: "red"
|
color: "red"
|
||||||
//color: Pywal.colors.color13
|
//color: Settings.colors.color13
|
||||||
visible: false
|
visible: false
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: "User"
|
text: "User"
|
||||||
color: "white"
|
color: "white"
|
||||||
//color: Pywal.special.foreground
|
//color: Settings.special.foreground
|
||||||
}
|
}
|
||||||
TextInput {
|
TextInput {
|
||||||
id: username
|
id: username
|
||||||
text: "guest"
|
text: "guest"
|
||||||
color: "white"
|
color: "white"
|
||||||
//color: Pywal.special.foreground
|
//color: Settings.special.foreground
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: "Password"
|
text: "Password"
|
||||||
color: "white"
|
color: "white"
|
||||||
//color: Pywal.special.foreground
|
//color: Settings.special.foreground
|
||||||
}
|
}
|
||||||
TextInput {
|
TextInput {
|
||||||
id: password
|
id: password
|
||||||
text: "test"
|
text: "test"
|
||||||
echoMode: TextInput.Password
|
echoMode: TextInput.Password
|
||||||
color: "white"
|
color: "white"
|
||||||
//color: Pywal.special.foreground
|
//color: Settings.special.foreground
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
|
|||||||
@@ -1,62 +0,0 @@
|
|||||||
pragma Singleton
|
|
||||||
|
|
||||||
import Quickshell
|
|
||||||
import Quickshell.Io
|
|
||||||
|
|
||||||
Singleton {
|
|
||||||
|
|
||||||
property string wallpaper: json.wallpaper
|
|
||||||
|
|
||||||
property string alpha: Math.round(parseInt(json.alpha, 10) * 0xFF / 100).toString(16)
|
|
||||||
|
|
||||||
property JsonObject special: json.special
|
|
||||||
property JsonObject colors: json.colors
|
|
||||||
|
|
||||||
function argb(c) {
|
|
||||||
return c.slice(0, 1) + Pywal.alpha + c.slice(1)
|
|
||||||
}
|
|
||||||
|
|
||||||
FileView {
|
|
||||||
|
|
||||||
path: "/home/nathan/.cache/wal/colors.json"
|
|
||||||
|
|
||||||
watchChanges: true
|
|
||||||
|
|
||||||
onFileChanged: reload()
|
|
||||||
|
|
||||||
JsonAdapter {
|
|
||||||
id: json
|
|
||||||
property string wallpaper: "/home/nathan/Pictures/Wallpaper/bluescape.jpg"
|
|
||||||
|
|
||||||
property string alpha: "100"
|
|
||||||
|
|
||||||
property JsonObject special: JsonObject {
|
|
||||||
property string background: "transparent"
|
|
||||||
property string foreground: "transparent"
|
|
||||||
property string cursor: "transparent"
|
|
||||||
}
|
|
||||||
|
|
||||||
property JsonObject colors: JsonObject {
|
|
||||||
property string color0: "transparent"
|
|
||||||
property string color1: "transparent"
|
|
||||||
property string color2: "transparent"
|
|
||||||
property string color3: "transparent"
|
|
||||||
|
|
||||||
property string color4: "transparent"
|
|
||||||
property string color5: "transparent"
|
|
||||||
property string color6: "transparent"
|
|
||||||
property string color7: "transparent"
|
|
||||||
|
|
||||||
property string color8: "transparent"
|
|
||||||
property string color9: "transparent"
|
|
||||||
property string color10: "transparent"
|
|
||||||
property string color11: "transparent"
|
|
||||||
|
|
||||||
property string color12: "transparent"
|
|
||||||
property string color13: "transparent"
|
|
||||||
property string color14: "transparent"
|
|
||||||
property string color15: "transparent"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
109
config/aurora-greeter/modules/Settings.qml
Normal file
109
config/aurora-greeter/modules/Settings.qml
Normal file
@@ -0,0 +1,109 @@
|
|||||||
|
pragma Singleton
|
||||||
|
|
||||||
|
import Quickshell // for PanelWindow
|
||||||
|
import QtQuick // for Text
|
||||||
|
import QtQuick.Shapes
|
||||||
|
import QtQuick.Controls
|
||||||
|
import QtQuick.Layouts
|
||||||
|
import Quickshell.Io
|
||||||
|
import Quickshell.Widgets
|
||||||
|
import Quickshell.Wayland
|
||||||
|
import Quickshell.Hyprland
|
||||||
|
|
||||||
|
|
||||||
|
Singleton {
|
||||||
|
|
||||||
|
property bool launcherOpen: false
|
||||||
|
|
||||||
|
property string colorsDir: s_json.colorsDir
|
||||||
|
|
||||||
|
property string wallpaperDir: s_json.wallpaperDir
|
||||||
|
|
||||||
|
property string settingsDir: "/home/" + Quickshell.env("USER") + "/.config/aurora"
|
||||||
|
onSettingsDirChanged: reload()
|
||||||
|
|
||||||
|
function reload() {
|
||||||
|
settings.reload()
|
||||||
|
root.wallpaperDir = Qt.binding(() => s_json.wallpaperDir)
|
||||||
|
root.colorsDir = Qt.binding(() => s_json.colorsDir)
|
||||||
|
root.wallpaper = Qt.binding(() => c_json.wallpaper)
|
||||||
|
root.colors = Qt.binding(() => c_json.colors)
|
||||||
|
}
|
||||||
|
|
||||||
|
id: root
|
||||||
|
|
||||||
|
FileView {
|
||||||
|
|
||||||
|
id: settings
|
||||||
|
|
||||||
|
path: root.settingsDir + "/settings.json"
|
||||||
|
|
||||||
|
watchChanges: true
|
||||||
|
|
||||||
|
onFileChanged: reload()
|
||||||
|
|
||||||
|
JsonAdapter {
|
||||||
|
id: s_json
|
||||||
|
property string wallpaperDir
|
||||||
|
|
||||||
|
property string colorsDir
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
property string wallpaper: c_json.wallpaper
|
||||||
|
|
||||||
|
property string alpha: Math.round(parseInt(c_json.alpha, 10) * 0xFF / 100).toString(16)
|
||||||
|
|
||||||
|
property JsonObject special: c_json.special
|
||||||
|
property JsonObject colors: c_json.colors
|
||||||
|
|
||||||
|
function argb(c) {
|
||||||
|
return c.slice(0, 1) + Settings.alpha + c.slice(1)
|
||||||
|
}
|
||||||
|
|
||||||
|
FileView {
|
||||||
|
|
||||||
|
id: pywal
|
||||||
|
|
||||||
|
path: root.colorsDir
|
||||||
|
|
||||||
|
watchChanges: true
|
||||||
|
|
||||||
|
onFileChanged: reload()
|
||||||
|
|
||||||
|
JsonAdapter {
|
||||||
|
id: c_json
|
||||||
|
property string wallpaper
|
||||||
|
|
||||||
|
property string alpha: "100"
|
||||||
|
|
||||||
|
property JsonObject special: JsonObject {
|
||||||
|
property string background: "transparent"
|
||||||
|
property string foreground: "transparent"
|
||||||
|
property string cursor: "transparent"
|
||||||
|
}
|
||||||
|
|
||||||
|
property JsonObject colors: JsonObject {
|
||||||
|
property string color0: "transparent"
|
||||||
|
property string color1: "transparent"
|
||||||
|
property string color2: "transparent"
|
||||||
|
property string color3: "transparent"
|
||||||
|
|
||||||
|
property string color4: "transparent"
|
||||||
|
property string color5: "transparent"
|
||||||
|
property string color6: "transparent"
|
||||||
|
property string color7: "transparent"
|
||||||
|
|
||||||
|
property string color8: "transparent"
|
||||||
|
property string color9: "transparent"
|
||||||
|
property string color10: "transparent"
|
||||||
|
property string color11: "transparent"
|
||||||
|
|
||||||
|
property string color12: "transparent"
|
||||||
|
property string color13: "transparent"
|
||||||
|
property string color14: "transparent"
|
||||||
|
property string color15: "transparent"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user