move theme to styling
This commit is contained in:
parent
467c9bc0e3
commit
4375f6e13d
36 changed files with 68 additions and 67 deletions
|
|
@ -32,11 +32,11 @@ PanelWindow {
|
|||
Rectangle {
|
||||
id: background
|
||||
anchors.fill: parent
|
||||
color: Theme.palette.base100
|
||||
color: Styling.theme.base100
|
||||
radius: Dimensions.radius
|
||||
|
||||
border {
|
||||
color: Theme.palette.base200
|
||||
color: Styling.theme.base200
|
||||
width: Dimensions.bar.border
|
||||
pixelAligned: true
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ StyledIconButton {
|
|||
id: root
|
||||
|
||||
border.width: 2
|
||||
border.color: Caffeine.enabled ? Theme.palette.secondary : root.hovered ? Theme.palette.primary : Theme.palette.base300
|
||||
border.color: Caffeine.enabled ? Styling.theme.secondary : root.hovered ? Styling.theme.primary : Styling.theme.base300
|
||||
text: Styling.lucide.icons.coffee
|
||||
|
||||
onClicked: {
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ StyledButton {
|
|||
}
|
||||
LucideIcon {
|
||||
text: Styling.lucide.icons.cpu
|
||||
color: root.hovered ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.hovered ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
}
|
||||
|
||||
StyledText {
|
||||
|
|
@ -32,7 +32,7 @@ StyledButton {
|
|||
|
||||
font.pixelSize: Dimensions.cpu.fontSize
|
||||
text: ` ${(SystemInfo.cpuPerc * 100).toFixed().toString().padStart(2, "_")}%`
|
||||
color: root.hovered ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.hovered ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
|
||||
states: [
|
||||
State {
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ StyledButton {
|
|||
}
|
||||
LucideIcon {
|
||||
text: Styling.lucide.icons.gpu
|
||||
color: root.hovered ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.hovered ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
}
|
||||
|
||||
StyledText {
|
||||
|
|
@ -32,7 +32,7 @@ StyledButton {
|
|||
|
||||
font.pixelSize: Dimensions.gpu.fontSize
|
||||
text: ` ${(SystemInfo.gpuPerc * 100).toFixed().toString().padStart(2, "_")}%`
|
||||
color: root.hovered ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.hovered ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
|
||||
states: [
|
||||
State {
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ StyledButton {
|
|||
when: Pipewire.muted
|
||||
PropertyChanges {
|
||||
root {
|
||||
palette.button: Theme.palette.error
|
||||
palette.button: Styling.theme.error
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,12 +15,12 @@ StyledButton {
|
|||
Layout.alignment: Qt.AlignVCenter
|
||||
color: {
|
||||
if (root.isCritical) {
|
||||
return Theme.palette.error;
|
||||
return Styling.theme.error;
|
||||
}
|
||||
if (root.hovered) {
|
||||
return Theme.palette.primarycontent;
|
||||
return Styling.theme.primarycontent;
|
||||
}
|
||||
return Theme.palette.basecontent;
|
||||
return Styling.theme.basecontent;
|
||||
}
|
||||
font.pixelSize: 16
|
||||
text: {
|
||||
|
|
@ -44,12 +44,12 @@ StyledButton {
|
|||
Layout.alignment: Qt.AlignVCenter
|
||||
color: {
|
||||
if (root.isCritical) {
|
||||
return Theme.palette.error;
|
||||
return Styling.theme.error;
|
||||
}
|
||||
if (root.hovered) {
|
||||
return Theme.palette.primarycontent;
|
||||
return Styling.theme.primarycontent;
|
||||
}
|
||||
return Theme.palette.basecontent;
|
||||
return Styling.theme.basecontent;
|
||||
}
|
||||
text: `${(root.laptopBattery?.percentage.toFixed(2) * 100)}%`
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import Quickshell.Bluetooth
|
|||
StyledPopupWindow {
|
||||
id: root
|
||||
|
||||
backgroundColor: Theme.palette.base300
|
||||
backgroundColor: Styling.theme.base300
|
||||
margins: 16
|
||||
radius: 8
|
||||
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ StyledLabel {
|
|||
PropertyChanges {
|
||||
icon {
|
||||
text: Styling.lucide.icons.batteryWarning
|
||||
color: Theme.palette.error
|
||||
color: Styling.theme.error
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -76,7 +76,7 @@ StyledLabel {
|
|||
StyledButton {
|
||||
Layout.alignment: Qt.AlignRight
|
||||
text: 'Disconnect'
|
||||
palette.button: hovered ? Theme.palette.error : Theme.palette.base200
|
||||
palette.button: hovered ? Styling.theme.error : Styling.theme.base200
|
||||
|
||||
onClicked: {
|
||||
if (root.modelData.state != BluetoothDeviceState.Connected) {
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ StyledLabel {
|
|||
hoverEnabled: root.modelData.state == BluetoothDeviceState.Disconnected
|
||||
text: 'Unpair'
|
||||
|
||||
palette.button: hovered ? Theme.palette.error : Theme.palette.base100
|
||||
palette.button: hovered ? Styling.theme.error : Styling.theme.base100
|
||||
|
||||
onClicked: {
|
||||
if (!hoverEnabled) {
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ StyledIconButton {
|
|||
PropertyChanges {
|
||||
root {
|
||||
rotation: 180
|
||||
color: root.hovered ? Theme.palette.basecontent : Theme.palette.primary
|
||||
color: root.hovered ? Styling.theme.basecontent : Styling.theme.primary
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
@ -33,7 +33,7 @@ StyledIconButton {
|
|||
root {
|
||||
text: Styling.lucide.icons.triangleDashed
|
||||
rotation: 180
|
||||
color: root.hovered ? Theme.palette.basecontent : Theme.palette.primary
|
||||
color: root.hovered ? Styling.theme.basecontent : Styling.theme.primary
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import QtQuick.Layouts
|
|||
StyledPopupWindow {
|
||||
id: root
|
||||
|
||||
backgroundColor: Theme.palette.base300
|
||||
backgroundColor: Styling.theme.base300
|
||||
margins: 16
|
||||
radius: 8
|
||||
|
||||
|
|
@ -32,7 +32,7 @@ StyledPopupWindow {
|
|||
|
||||
StyledLabel {
|
||||
Layout.columnSpan: 2
|
||||
color: Theme.palette.base200
|
||||
color: Styling.theme.base200
|
||||
StyledListView {
|
||||
id: notifications
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import Quickshell
|
|||
StyledPopupWindow {
|
||||
id: window
|
||||
|
||||
backgroundColor: Theme.palette.base300
|
||||
backgroundColor: Styling.theme.base300
|
||||
margins: 14
|
||||
radius: 8
|
||||
|
||||
|
|
@ -32,7 +32,7 @@ StyledPopupWindow {
|
|||
property Component menuSeperator: Rectangle {
|
||||
implicitHeight: 2
|
||||
|
||||
color: Theme.palette.base100
|
||||
color: Styling.theme.base100
|
||||
}
|
||||
property Component menuItem: MenuItem {
|
||||
menuEntry: loader.modelData
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ StyledListView {
|
|||
highlightResizeDuration: 0
|
||||
highlight: Rectangle {
|
||||
radius: 8
|
||||
color: Theme.palette.primary
|
||||
color: Styling.theme.primary
|
||||
}
|
||||
|
||||
header: StyledText {
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ StyledWindow {
|
|||
Layout.alignment: Qt.AlignTop
|
||||
margin: 4
|
||||
|
||||
color: Theme.palette.base200
|
||||
color: Styling.theme.base200
|
||||
|
||||
RowLayout {
|
||||
LucideIcon {
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ Item {
|
|||
|
||||
Layout.alignment: Qt.AlignBottom
|
||||
Layout.fillWidth: true
|
||||
color: root.active ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.active ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
font.pixelSize: 14
|
||||
font.bold: true
|
||||
}
|
||||
|
|
@ -52,7 +52,7 @@ Item {
|
|||
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.fillWidth: true
|
||||
color: root.active ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: root.active ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
font.pixelSize: 10
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,10 +53,10 @@ StyledWindow {
|
|||
Circle {
|
||||
id: circle
|
||||
radius: 150
|
||||
borderColor: Theme.palette.base100
|
||||
strokeColor: Pomodoro.state == "timer" ? Theme.palette.primary : Theme.palette.warning
|
||||
borderColor: Styling.theme.base100
|
||||
strokeColor: Pomodoro.state == "timer" ? Styling.theme.primary : Styling.theme.warning
|
||||
strokeWidth: 12
|
||||
fillColor: button.hovered ? Theme.palette.primary : "transparent"
|
||||
fillColor: button.hovered ? Styling.theme.primary : "transparent"
|
||||
percentage: (Pomodoro.state == "timer" ? (Pomodoro.initialTime - Pomodoro.remainingTime) : Pomodoro.remainingTime) / Pomodoro.initialTime % 1
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ StyledWindow {
|
|||
highlightResizeDuration: 0
|
||||
highlight: Rectangle {
|
||||
radius: 8
|
||||
color: Theme.palette.primary
|
||||
color: Styling.theme.primary
|
||||
}
|
||||
|
||||
onCurrentItemChanged: {
|
||||
|
|
@ -103,7 +103,7 @@ StyledWindow {
|
|||
}
|
||||
|
||||
padding: 16
|
||||
color: list.currentIndex == index ? Theme.palette.primarycontent : Theme.palette.basecontent
|
||||
color: list.currentIndex == index ? Styling.theme.primarycontent : Styling.theme.basecontent
|
||||
text: modelData.text
|
||||
font.pixelSize: 18
|
||||
font.bold: true
|
||||
|
|
|
|||
|
|
@ -137,7 +137,7 @@ StyledWindow {
|
|||
font.pixelSize: 18
|
||||
}
|
||||
StyledWrapperRectangle {
|
||||
border.color: Theme.palette.base100
|
||||
border.color: Styling.theme.base100
|
||||
border.width: 2
|
||||
StyledListView {
|
||||
implicitWidth: 200
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue