From bf3a1781d12271a7edb9ead26eb59740f87877fd Mon Sep 17 00:00:00 2001 From: ATMDA Date: Wed, 19 Nov 2025 22:18:10 -0500 Subject: refactor: reorganized AppearancePane sections into dedicated components --- .../appearance/sections/ThemeModeSection.qml | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 modules/controlcenter/appearance/sections/ThemeModeSection.qml (limited to 'modules/controlcenter/appearance/sections/ThemeModeSection.qml') diff --git a/modules/controlcenter/appearance/sections/ThemeModeSection.qml b/modules/controlcenter/appearance/sections/ThemeModeSection.qml new file mode 100644 index 0000000..c136437 --- /dev/null +++ b/modules/controlcenter/appearance/sections/ThemeModeSection.qml @@ -0,0 +1,24 @@ +pragma ComponentBehavior: Bound + +import ".." +import qs.components +import qs.components.controls +import qs.components.containers +import qs.services +import qs.config +import QtQuick + +CollapsibleSection { + title: qsTr("Theme mode") + description: qsTr("Light or dark theme") + showBackground: true + + SwitchRow { + label: qsTr("Dark mode") + checked: !Colours.currentLight + onToggled: checked => { + Colours.setMode(checked ? "dark" : "light"); + } + } +} + -- cgit v1.2.3-freya