Create MatugenService, add toggles per template
Matugen: Created Matugen.qml for users to add templates to, add MatugenService to generate .toml Notification: possible fix for children null warning Merge branch 'main' of https://github.com/noctalia-dev/noctalia-shell
This commit is contained in:
commit
a6848be4c2
13 changed files with 31 additions and 27 deletions
|
|
@ -7,6 +7,8 @@ import qs.Commons
|
||||||
import qs.Services
|
import qs.Services
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
property real localVolume: AudioService.volume
|
property real localVolume: AudioService.volume
|
||||||
|
|
||||||
Connections {
|
Connections {
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,8 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
readonly property real scaling: ScalingService.scale(screen)
|
id: root
|
||||||
readonly property string tabIcon: "brightness_6"
|
|
||||||
readonly property string tabLabel: "Brightness"
|
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
||||||
// Brightness Step Section
|
// Brightness Step Section
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,13 @@ import qs.Widgets
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
|
// Cache for scheme JSON (can be flat or {dark, light})
|
||||||
|
property var schemeColorsCache: ({})
|
||||||
|
|
||||||
|
// Scale properties for card animations
|
||||||
|
property real cardScaleLow: 0.95
|
||||||
|
property real cardScaleHigh: 1.0
|
||||||
|
|
||||||
// Helper function to get color from scheme file (supports dark/light variants)
|
// Helper function to get color from scheme file (supports dark/light variants)
|
||||||
function getSchemeColor(schemePath, colorKey) {
|
function getSchemeColor(schemePath, colorKey) {
|
||||||
// Extract scheme name from path
|
// Extract scheme name from path
|
||||||
|
|
@ -29,13 +36,6 @@ ColumnLayout {
|
||||||
return "#000000"
|
return "#000000"
|
||||||
}
|
}
|
||||||
|
|
||||||
// Cache for scheme JSON (can be flat or {dark, light})
|
|
||||||
property var schemeColorsCache: ({})
|
|
||||||
|
|
||||||
// Scale properties for card animations
|
|
||||||
property real cardScaleLow: 0.95
|
|
||||||
property real cardScaleHigh: 1.0
|
|
||||||
|
|
||||||
// This function is called by the FileView Repeater when a scheme file is loaded
|
// This function is called by the FileView Repeater when a scheme file is loaded
|
||||||
function schemeLoaded(schemeName, jsonData) {
|
function schemeLoaded(schemeName, jsonData) {
|
||||||
var value = jsonData || {}
|
var value = jsonData || {}
|
||||||
|
|
|
||||||
|
|
@ -7,10 +7,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
readonly property real scaling: ScalingService.scale(screen)
|
id: root
|
||||||
readonly property string tabIcon: "monitor"
|
|
||||||
readonly property string tabLabel: "Display"
|
|
||||||
readonly property int tabIndex: 5
|
|
||||||
|
|
||||||
// Time dropdown options (00:00 .. 23:30)
|
// Time dropdown options (00:00 .. 23:30)
|
||||||
ListModel {
|
ListModel {
|
||||||
|
|
@ -245,15 +242,9 @@ ColumnLayout {
|
||||||
onToggled: checked => Settings.data.nightLight.enabled = checked
|
onToggled: checked => Settings.data.nightLight.enabled = checked
|
||||||
}
|
}
|
||||||
|
|
||||||
NToggle {
|
|
||||||
label: "Auto Schedule"
|
|
||||||
description: "Automatically enable night light based on time schedule."
|
|
||||||
checked: Settings.data.nightLight.autoSchedule
|
|
||||||
onToggled: checked => Settings.data.nightLight.autoSchedule = checked
|
|
||||||
}
|
|
||||||
|
|
||||||
// Intensity settings
|
// Intensity settings
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
visible: Settings.data.nightLight.enabled
|
||||||
NLabel {
|
NLabel {
|
||||||
label: "Intensity"
|
label: "Intensity"
|
||||||
description: "Higher values create warmer light."
|
description: "Higher values create warmer light."
|
||||||
|
|
@ -280,9 +271,18 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
NToggle {
|
||||||
|
label: "Auto Schedule"
|
||||||
|
description: "Automatically enable night light based on time schedule."
|
||||||
|
checked: Settings.data.nightLight.autoSchedule
|
||||||
|
onToggled: checked => Settings.data.nightLight.autoSchedule = checked
|
||||||
|
visible: Settings.data.nightLight.enabled
|
||||||
|
}
|
||||||
|
|
||||||
// Schedule settings
|
// Schedule settings
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Style.marginXS * scaling
|
spacing: Style.marginXS * scaling
|
||||||
|
visible: Settings.data.nightLight.enabled && Settings.data.nightLight.autoSchedule
|
||||||
|
|
||||||
NLabel {
|
NLabel {
|
||||||
label: "Schedule"
|
label: "Schedule"
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
// Profile section
|
// Profile section
|
||||||
RowLayout {
|
RowLayout {
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
||||||
NToggle {
|
NToggle {
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,8 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
||||||
// Output Directory
|
// Output Directory
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
// Location section
|
// Location section
|
||||||
NTextInput {
|
NTextInput {
|
||||||
|
|
|
||||||
|
|
@ -7,10 +7,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
readonly property real scaling: ScalingService.scale(screen)
|
id: root
|
||||||
readonly property string tabIcon: "photo_library"
|
|
||||||
readonly property string tabLabel: "Wallpaper Selector"
|
|
||||||
readonly property int tabIndex: 7
|
|
||||||
|
|
||||||
spacing: Style.marginL * scaling
|
spacing: Style.marginL * scaling
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@ import qs.Services
|
||||||
import qs.Widgets
|
import qs.Widgets
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
id: root
|
||||||
|
|
||||||
// Process to check if swww is installed
|
// Process to check if swww is installed
|
||||||
Process {
|
Process {
|
||||||
|
|
|
||||||
|
|
@ -137,6 +137,4 @@ Singleton {
|
||||||
colorsWriter.path = colorsJsonFilePath
|
colorsWriter.path = colorsJsonFilePath
|
||||||
colorsWriter.writeAdapter()
|
colorsWriter.writeAdapter()
|
||||||
}
|
}
|
||||||
|
|
||||||
// Matugen generation moved to MatugenService
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue