color feedback on open popouts #40
+2
-2
@@ -13,7 +13,7 @@ CustomRect {
|
|||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
color: DynamicColors.tPalette.m3surfaceContainer
|
color: visibilities.dashboard ? DynamicColors.palette.m3primary : DynamicColors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
||||||
implicitWidth: timeText.contentWidth + Appearance.padding.normal * 2
|
implicitWidth: timeText.contentWidth + Appearance.padding.normal * 2
|
||||||
radius: Appearance.rounding.full
|
radius: Appearance.rounding.full
|
||||||
@@ -22,7 +22,7 @@ CustomRect {
|
|||||||
id: timeText
|
id: timeText
|
||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
color: DynamicColors.palette.m3onSurface
|
color: root.visibilities.dashboard ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
text: Time.dateStr
|
text: Time.dateStr
|
||||||
|
|
||||||
Behavior on color {
|
Behavior on color {
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ CustomRect {
|
|||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
color: DynamicColors.tPalette.m3surfaceContainer
|
color: visibilities.sidebar ? DynamicColors.palette.m3primary : DynamicColors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
radius: Appearance.rounding.full
|
radius: Appearance.rounding.full
|
||||||
@@ -19,10 +19,8 @@ CustomRect {
|
|||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: notificationCenterIcon
|
id: notificationCenterIcon
|
||||||
|
|
||||||
property color iconColor: DynamicColors.palette.m3onSurface
|
|
||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
color: iconColor
|
color: root.visibilities.sidebar ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
font.family: "Material Symbols Rounded"
|
font.family: "Material Symbols Rounded"
|
||||||
font.pointSize: Appearance.font.size.larger
|
font.pointSize: Appearance.font.size.larger
|
||||||
text: HasNotifications.hasNotifications ? "\uf4fe" : "\ue7f4"
|
text: HasNotifications.hasNotifications ? "\uf4fe" : "\ue7f4"
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ RowLayout {
|
|||||||
readonly property real arcStartAngle: 0.75 * Math.PI
|
readonly property real arcStartAngle: 0.75 * Math.PI
|
||||||
readonly property real arcSweep: 1.5 * Math.PI
|
readonly property real arcSweep: 1.5 * Math.PI
|
||||||
property string icon
|
property string icon
|
||||||
|
required property color iconColor
|
||||||
required property color mainColor
|
required property color mainColor
|
||||||
required property double percentage
|
required property double percentage
|
||||||
property bool shown: true
|
property bool shown: true
|
||||||
@@ -37,7 +38,7 @@ RowLayout {
|
|||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
color: DynamicColors.palette.m3onSurface
|
color: root.iconColor
|
||||||
font.pointSize: Appearance.font.size.larger
|
font.pointSize: Appearance.font.size.larger
|
||||||
text: root.icon
|
text: root.icon
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ CustomRect {
|
|||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
clip: true
|
clip: true
|
||||||
color: DynamicColors.tPalette.m3surfaceContainer
|
color: visibilities.resources ? DynamicColors.palette.m3primary : DynamicColors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
implicitHeight: Config.barConfig.height + Appearance.padding.smallest * 2
|
||||||
implicitWidth: rowLayout.implicitWidth + Appearance.padding.normal * 2
|
implicitWidth: rowLayout.implicitWidth + Appearance.padding.normal * 2
|
||||||
radius: height / 2
|
radius: height / 2
|
||||||
@@ -38,7 +38,8 @@ CustomRect {
|
|||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
icon: "memory"
|
icon: "memory"
|
||||||
mainColor: DynamicColors.palette.m3primary
|
iconColor: root.visibilities.resources ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
|
mainColor: root.visibilities.resources ? DynamicColors.palette.m3primaryContainer : DynamicColors.palette.m3primary
|
||||||
percentage: SystemUsage.cpuPerc
|
percentage: SystemUsage.cpuPerc
|
||||||
warningThreshold: 95
|
warningThreshold: 95
|
||||||
}
|
}
|
||||||
@@ -46,7 +47,8 @@ CustomRect {
|
|||||||
Resource {
|
Resource {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
icon: "memory_alt"
|
icon: "memory_alt"
|
||||||
mainColor: DynamicColors.palette.m3secondary
|
iconColor: root.visibilities.resources ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
|
mainColor: root.visibilities.resources ? DynamicColors.palette.m3secondaryContainer : DynamicColors.palette.m3secondary
|
||||||
percentage: SystemUsage.memPerc
|
percentage: SystemUsage.memPerc
|
||||||
warningThreshold: 80
|
warningThreshold: 80
|
||||||
}
|
}
|
||||||
@@ -54,14 +56,16 @@ CustomRect {
|
|||||||
Resource {
|
Resource {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
icon: "gamepad"
|
icon: "gamepad"
|
||||||
mainColor: DynamicColors.palette.m3tertiary
|
iconColor: root.visibilities.resources ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
|
mainColor: root.visibilities.resources ? DynamicColors.palette.m3tertiaryContainer : DynamicColors.palette.m3tertiary
|
||||||
percentage: SystemUsage.gpuPerc
|
percentage: SystemUsage.gpuPerc
|
||||||
}
|
}
|
||||||
|
|
||||||
Resource {
|
Resource {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
icon: "developer_board"
|
icon: "developer_board"
|
||||||
mainColor: DynamicColors.palette.m3primary
|
iconColor: root.visibilities.resources ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
|
mainColor: root.visibilities.resources ? DynamicColors.palette.m3primaryContainer : DynamicColors.palette.m3primary
|
||||||
percentage: SystemUsage.gpuMemUsed
|
percentage: SystemUsage.gpuMemUsed
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,17 +9,22 @@ import qs.Config
|
|||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
|
property bool current: popouts.currentName.startsWith(`traymenu${ind}`) && popouts.hasCurrent
|
||||||
property bool hasLoaded: false
|
property bool hasLoaded: false
|
||||||
required property int ind
|
required property int ind
|
||||||
required property SystemTrayItem item
|
required property SystemTrayItem item
|
||||||
required property RowLayout loader
|
required property RowLayout loader
|
||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
|
|
||||||
|
CustomRect {
|
||||||
|
anchors.fill: parent
|
||||||
|
anchors.margins: 3
|
||||||
|
color: root.current ? DynamicColors.palette.m3primary : "transparent"
|
||||||
|
radius: Appearance.rounding.full
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
acceptedButtons: Qt.LeftButton | Qt.RightButton
|
acceptedButtons: Qt.LeftButton | Qt.RightButton
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: 3
|
|
||||||
radius: 6
|
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
if (mouse.button === Qt.LeftButton) {
|
if (mouse.button === Qt.LeftButton) {
|
||||||
@@ -36,12 +41,13 @@ Item {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ColoredIcon {
|
ColoredIcon {
|
||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
color: DynamicColors.palette.m3onSurface
|
color: root.current ? DynamicColors.palette.m3onPrimary : DynamicColors.palette.m3onSurface
|
||||||
implicitSize: 22
|
implicitSize: 22
|
||||||
layer.enabled: Config.general.color.smart || Config.general.color.scheduleDark
|
layer.enabled: Config.general.color.smart || Config.general.color.scheduleDark
|
||||||
source: root.item.icon
|
source: root.item.icon
|
||||||
|
|||||||
Reference in New Issue
Block a user