plugin: rust-side modules + theme services with serde-typed config
This commit is contained in:
parent
a86e90e927
commit
f34f3f2f4e
95 changed files with 2477 additions and 1011 deletions
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
// Action bar for applet-level controls (power toggles, DND, clear-all, etc.)
|
||||
// Place at the top of an applet Column. Children are right-aligned action buttons.
|
||||
|
|
@ -26,6 +27,6 @@ Item {
|
|||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: S.Theme.base03
|
||||
color: NS.ThemeService.base03
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
|
@ -18,8 +19,8 @@ Item {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "\uF185"
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize + 2
|
||||
font.family: S.Theme.iconFontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize + 2
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
Item {
|
||||
|
|
@ -33,7 +34,7 @@ Item {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
|
||||
|
|
@ -71,9 +72,9 @@ Item {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.percent + "%"
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 30
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -8,7 +9,7 @@ Column {
|
|||
|
||||
property bool active: true
|
||||
|
||||
readonly property color _stateColor: S.BatteryService.charging ? S.Theme.base0B : S.BatteryService.critical ? S.Theme.base09 : S.BatteryService.percent < S.BatteryService.warnThresh ? S.Theme.base0A : root.accentColor
|
||||
readonly property color _stateColor: S.BatteryService.charging ? NS.ThemeService.base0B : S.BatteryService.critical ? NS.ThemeService.base09 : S.BatteryService.percent < S.BatteryService.warnThresh ? NS.ThemeService.base0A : root.accentColor
|
||||
|
||||
// Header - pct + time
|
||||
Item {
|
||||
|
|
@ -25,8 +26,8 @@ Column {
|
|||
return Math.round(S.BatteryService.percent) + "%" + (ts ? " " + ts : "");
|
||||
}
|
||||
color: root._stateColor
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
}
|
||||
|
|
@ -46,7 +47,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
|
||||
|
|
@ -70,7 +71,7 @@ Column {
|
|||
width: 1
|
||||
height: parent.height + 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: S.Theme.base0A
|
||||
color: NS.ThemeService.base0A
|
||||
opacity: 0.6
|
||||
}
|
||||
|
||||
|
|
@ -80,7 +81,7 @@ Column {
|
|||
width: 1
|
||||
height: parent.height + 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: S.Theme.base08
|
||||
color: NS.ThemeService.base08
|
||||
opacity: 0.6
|
||||
}
|
||||
}
|
||||
|
|
@ -99,11 +100,11 @@ Column {
|
|||
thresholds: [
|
||||
{
|
||||
value: S.BatteryService.warnThresh,
|
||||
color: S.Theme.base0A
|
||||
color: NS.ThemeService.base0A
|
||||
},
|
||||
{
|
||||
value: S.BatteryService.critThresh,
|
||||
color: S.Theme.base08
|
||||
color: NS.ThemeService.base08
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -118,9 +119,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "warn " + S.BatteryService.warnThresh + "% crit " + S.BatteryService.critThresh + "%"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 0.5
|
||||
}
|
||||
|
||||
|
|
@ -129,9 +130,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "24h"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -159,7 +160,7 @@ Column {
|
|||
height: 24
|
||||
history: S.BatteryService.rateHistory
|
||||
strokeColor: root._stateColor
|
||||
colorAt: v => v >= 0 ? S.Theme.base0B : root._stateColor
|
||||
colorAt: v => v >= 0 ? NS.ThemeService.base0B : root._stateColor
|
||||
active: root.active
|
||||
maxValue: null
|
||||
minValue: null
|
||||
|
|
@ -173,7 +174,7 @@ Column {
|
|||
value: Math.round(S.BatteryService.healthPercent) + "%"
|
||||
valueColor: {
|
||||
const h = S.BatteryService.healthPercent;
|
||||
return h < 50 ? S.Theme.base08 : h < 75 ? S.Theme.base0A : S.Theme.base0B;
|
||||
return h < 50 ? NS.ThemeService.base08 : h < 75 ? NS.ThemeService.base0A : NS.ThemeService.base0B;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
// NOT safe for lock screen - can toggle bluetooth power and connect/disconnect devices
|
||||
Column {
|
||||
|
|
@ -20,9 +21,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "\uF011"
|
||||
color: S.BluetoothService.enabled ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: S.BluetoothService.enabled ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
|
|
@ -57,9 +58,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "\uF294"
|
||||
color: entry._pending || entry.modelData.connected ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize + 1
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: entry._pending || entry.modelData.connected ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize + 1
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
Text {
|
||||
|
|
@ -69,9 +70,9 @@ Column {
|
|||
anchors.rightMargin: 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: entry.modelData.name
|
||||
color: entry._pending || entry.modelData.connected ? root.accentColor : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: entry._pending || entry.modelData.connected ? root.accentColor : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: entry.modelData.connected || entry._pending
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
@ -82,9 +83,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: entry._pending ? (entry.modelData.connected ? "disconnecting..." : "connecting...") : (entry.modelData.battery >= 0 ? entry.modelData.battery + "%" : "")
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.italic: entry._pending
|
||||
width: text ? implicitWidth : 0
|
||||
}
|
||||
|
|
@ -92,7 +93,7 @@ Column {
|
|||
// Pulse animation while pending
|
||||
SequentialAnimation on opacity {
|
||||
loops: Animation.Infinite
|
||||
running: entry._pending && !S.Theme.reducedMotion
|
||||
running: entry._pending && !S.ThemeUtil.reducedMotion
|
||||
NumberAnimation {
|
||||
to: 0.5
|
||||
duration: 400
|
||||
|
|
@ -121,8 +122,8 @@ Column {
|
|||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: S.BluetoothService.enabled ? "No paired devices" : "Bluetooth is off"
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -64,8 +65,8 @@ Column {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root._locale.standaloneMonthName(root._month, Locale.LongFormat) + " " + root._year
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
|
||||
|
|
@ -74,9 +75,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "W" + root._weekNumber(root.currentDate)
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -91,9 +92,9 @@ Column {
|
|||
height: 18
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
text: modelData
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
}
|
||||
|
|
@ -121,9 +122,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: modelData.day
|
||||
color: modelData.isToday ? S.Theme.base00 : modelData.isCurrentMonth ? S.Theme.base05 : S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: modelData.isToday ? NS.ThemeService.base00 : modelData.isCurrentMonth ? NS.ThemeService.base05 : NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: modelData.isToday
|
||||
}
|
||||
}
|
||||
|
|
@ -136,9 +137,9 @@ Column {
|
|||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
text: root.currentDate.toLocaleDateString(root._locale, Locale.LongFormat)
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Item {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -32,7 +33,7 @@ Column {
|
|||
|
||||
readonly property int _u: S.CpuService.cores[index]?.usage ?? 0
|
||||
readonly property real _f: S.CpuService.cores[index]?.freq_ghz ?? 0
|
||||
readonly property color _barColor: S.Theme.loadColor(_u)
|
||||
readonly property color _barColor: S.ThemeUtil.loadColor(_u)
|
||||
readonly property bool _throttled: {
|
||||
const maxF = S.CpuService.coreMaxFreq[index] ?? 0;
|
||||
return maxF > 0 && _f < maxF * 0.85 && _u >= 60;
|
||||
|
|
@ -56,7 +57,7 @@ Column {
|
|||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
width: parent.width - 16
|
||||
height: 1
|
||||
color: S.Theme.base03
|
||||
color: NS.ThemeService.base03
|
||||
}
|
||||
|
||||
// Row content pinned to bottom of delegate
|
||||
|
|
@ -71,9 +72,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: index
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 16
|
||||
}
|
||||
|
||||
|
|
@ -88,7 +89,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 2
|
||||
}
|
||||
|
||||
|
|
@ -115,7 +116,7 @@ Column {
|
|||
height: 10
|
||||
history: S.CpuService.cores[parent.parent.index]?.history ?? []
|
||||
strokeColor: parent.parent._barColor
|
||||
colorAt: v => S.Theme.loadColor(v)
|
||||
colorAt: v => S.ThemeUtil.loadColor(v)
|
||||
active: root.active
|
||||
}
|
||||
|
||||
|
|
@ -125,9 +126,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: parent.parent._f.toFixed(2)
|
||||
color: parent.parent._throttled ? S.Theme.base08 : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: parent.parent._throttled ? NS.ThemeService.base08 : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 34
|
||||
horizontalAlignment: Text.AlignRight
|
||||
}
|
||||
|
|
@ -141,7 +142,7 @@ Column {
|
|||
InfoRow {
|
||||
label: "Total"
|
||||
value: S.CpuService.usage + "% @ " + S.CpuService.freqGhz.toFixed(2) + " GHz"
|
||||
valueColor: S.Theme.loadColor(S.CpuService.usage)
|
||||
valueColor: S.ThemeUtil.loadColor(S.CpuService.usage)
|
||||
}
|
||||
|
||||
SparklineCanvas {
|
||||
|
|
@ -152,7 +153,7 @@ Column {
|
|||
height: 32
|
||||
history: S.CpuService.history
|
||||
strokeColor: root.accentColor
|
||||
colorAt: v => S.Theme.loadColor(v)
|
||||
colorAt: v => S.ThemeUtil.loadColor(v)
|
||||
active: root.active
|
||||
}
|
||||
|
||||
|
|
@ -172,9 +173,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "PROCESS"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -183,9 +184,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "CPU"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
}
|
||||
|
|
@ -203,9 +204,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.cmd
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: parent.width - 80
|
||||
}
|
||||
|
|
@ -215,9 +216,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.cpu.toFixed(1) + "%"
|
||||
color: S.Theme.loadColor(modelData.cpu)
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: S.ThemeUtil.loadColor(modelData.cpu)
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 36
|
||||
horizontalAlignment: Text.AlignRight
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -31,9 +32,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.target
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: 72
|
||||
}
|
||||
|
|
@ -49,14 +50,14 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 2
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
width: parent.width * (modelData.pct / 100)
|
||||
height: parent.height
|
||||
color: S.Theme.loadColor(modelData.pct)
|
||||
color: S.ThemeUtil.loadColor(modelData.pct)
|
||||
radius: 2
|
||||
Behavior on width {
|
||||
NumberAnimation {
|
||||
|
|
@ -72,9 +73,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root._fmt(modelData.usedBytes) + "/" + root._fmt(modelData.totalBytes)
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 72
|
||||
horizontalAlignment: Text.AlignRight
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -22,9 +23,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: S.SystemStats.gpuVendor.toUpperCase()
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -33,9 +34,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: S.SystemStats.gpuUsage + "%"
|
||||
color: S.Theme.loadColor(S.SystemStats.gpuUsage)
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: S.ThemeUtil.loadColor(S.SystemStats.gpuUsage)
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
}
|
||||
|
|
@ -55,14 +56,14 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
width: parent.width * Math.min(1, S.SystemStats.gpuUsage / 100)
|
||||
height: parent.height
|
||||
color: S.Theme.loadColor(S.SystemStats.gpuUsage)
|
||||
color: S.ThemeUtil.loadColor(S.SystemStats.gpuUsage)
|
||||
radius: 3
|
||||
Behavior on width {
|
||||
enabled: root.active
|
||||
|
|
@ -84,7 +85,7 @@ Column {
|
|||
height: 32
|
||||
history: S.SystemStats.gpuHistory
|
||||
strokeColor: root.accentColor
|
||||
colorAt: v => S.Theme.loadColor(v)
|
||||
colorAt: v => S.ThemeUtil.loadColor(v)
|
||||
active: root.active
|
||||
}
|
||||
|
||||
|
|
@ -100,9 +101,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "VRAM"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -112,8 +113,8 @@ Column {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root._fmt(S.SystemStats.gpuVramUsedGb) + " / " + root._fmt(S.SystemStats.gpuVramTotalGb)
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
}
|
||||
|
|
@ -132,7 +133,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 2
|
||||
}
|
||||
|
||||
|
|
@ -158,7 +159,7 @@ Column {
|
|||
height: 22
|
||||
label: "Temp"
|
||||
value: S.SystemStats.gpuTempC + "\u00B0C"
|
||||
valueColor: S.SystemStats.gpuTempC > S.Modules.gpu.hot ? S.Theme.base08 : S.SystemStats.gpuTempC > S.Modules.gpu.warm ? S.Theme.base0A : S.Theme.base05
|
||||
valueColor: S.SystemStats.gpuTempC > NS.ModulesService.gpuHot ? NS.ThemeService.base08 : S.SystemStats.gpuTempC > NS.ModulesService.gpuWarm ? NS.ThemeService.base0A : NS.ThemeService.base05
|
||||
}
|
||||
|
||||
Item {
|
||||
|
|
|
|||
|
|
@ -1,12 +1,13 @@
|
|||
import QtQuick
|
||||
import Quickshell
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
||||
property bool running: false
|
||||
property bool reducedMotion: S.Theme.reducedMotion
|
||||
property bool reducedMotion: S.ThemeUtil.reducedMotion
|
||||
readonly property real wavePhase: fx.uWavePhase
|
||||
|
||||
ShaderEffect {
|
||||
|
|
@ -22,9 +23,9 @@ Item {
|
|||
property real uGlitch: 0
|
||||
property real uGlitchSeed: 0.0
|
||||
property vector4d uResolution: Qt.vector4d(width, height, 0, 0)
|
||||
property color uC0: S.Theme.base0C
|
||||
property color uC1: S.Theme.base0E
|
||||
property color uC2: S.Theme.base09
|
||||
property color uC0: NS.ThemeService.base0C
|
||||
property color uC1: NS.ThemeService.base0E
|
||||
property color uC2: NS.ThemeService.base09
|
||||
|
||||
Connections {
|
||||
target: root
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
|
@ -14,8 +15,8 @@ Item {
|
|||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 4
|
||||
color: root.hovered ? S.Theme.base02 : "transparent"
|
||||
radius: S.Theme.radius
|
||||
color: root.hovered ? NS.ThemeService.base02 : "transparent"
|
||||
radius: NS.ThemeService.radius
|
||||
z: -1
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,12 +1,13 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
||||
required property string label
|
||||
required property string value
|
||||
property color valueColor: S.Theme.base05
|
||||
property color valueColor: NS.ThemeService.base05
|
||||
|
||||
width: parent?.width ?? 0
|
||||
height: 18
|
||||
|
|
@ -16,9 +17,9 @@ Item {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.label
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Text {
|
||||
|
|
@ -27,7 +28,7 @@ Item {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.value
|
||||
color: root.valueColor
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ pragma ComponentBehavior: Bound
|
|||
|
||||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -20,8 +21,8 @@ Column {
|
|||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 4
|
||||
color: _localHdrHover.hovered ? S.Theme.base02 : "transparent"
|
||||
radius: S.Theme.radius
|
||||
color: _localHdrHover.hovered ? NS.ThemeService.base02 : "transparent"
|
||||
radius: NS.ThemeService.radius
|
||||
z: -1
|
||||
}
|
||||
|
||||
|
|
@ -34,9 +35,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: " localhost"
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
|
|
@ -48,10 +49,10 @@ Column {
|
|||
color: {
|
||||
const st = S.SystemdService.systemState;
|
||||
if (st === "running")
|
||||
return S.Theme.base0B;
|
||||
return NS.ThemeService.base0B;
|
||||
if (st === "degraded")
|
||||
return S.Theme.base0A;
|
||||
return S.Theme.base08;
|
||||
return NS.ThemeService.base0A;
|
||||
return NS.ThemeService.base08;
|
||||
}
|
||||
opacity: 0.85
|
||||
radius: 3
|
||||
|
|
@ -62,9 +63,9 @@ Column {
|
|||
id: _localStateLbl
|
||||
anchors.centerIn: parent
|
||||
text: S.SystemdService.systemState
|
||||
color: S.Theme.base00
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base00
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -74,9 +75,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root._localExpanded ? "" : ""
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
TapHandler {
|
||||
|
|
@ -99,9 +100,9 @@ Column {
|
|||
anchors.leftMargin: 24
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "SYSTEM"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
}
|
||||
|
|
@ -126,9 +127,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "no failures"
|
||||
color: S.Theme.base0B
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base0B
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -142,9 +143,9 @@ Column {
|
|||
anchors.leftMargin: 24
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "USER"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
}
|
||||
|
|
@ -169,9 +170,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "no failures"
|
||||
color: S.Theme.base0B
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base0B
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -209,8 +210,8 @@ Column {
|
|||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 4
|
||||
color: _mHdrHover.hovered ? S.Theme.base02 : "transparent"
|
||||
radius: S.Theme.radius
|
||||
color: _mHdrHover.hovered ? NS.ThemeService.base02 : "transparent"
|
||||
radius: NS.ThemeService.radius
|
||||
z: -1
|
||||
}
|
||||
|
||||
|
|
@ -223,9 +224,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: " " + _machineSection.modelData.name
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: parent.width - 100
|
||||
}
|
||||
|
|
@ -239,10 +240,10 @@ Column {
|
|||
color: {
|
||||
const st = S.MachinectlService.machineState(_machineSection.modelData.name);
|
||||
if (st === "running")
|
||||
return S.Theme.base0B;
|
||||
return NS.ThemeService.base0B;
|
||||
if (st === "degraded")
|
||||
return S.Theme.base0A;
|
||||
return st === "unknown" ? "transparent" : S.Theme.base08;
|
||||
return NS.ThemeService.base0A;
|
||||
return st === "unknown" ? "transparent" : NS.ThemeService.base08;
|
||||
}
|
||||
opacity: 0.85
|
||||
radius: 3
|
||||
|
|
@ -253,9 +254,9 @@ Column {
|
|||
id: _mStateLbl
|
||||
anchors.centerIn: parent
|
||||
text: S.MachinectlService.machineState(_machineSection.modelData.name)
|
||||
color: S.Theme.base00
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base00
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -265,9 +266,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: _machineSection._expanded ? "" : ""
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
TapHandler {
|
||||
|
|
@ -293,9 +294,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "loading..."
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -310,9 +311,9 @@ Column {
|
|||
anchors.leftMargin: 24
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "SYSTEM"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
}
|
||||
|
|
@ -337,9 +338,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "no failures"
|
||||
color: S.Theme.base0B
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base0B
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -35,7 +36,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
|
||||
|
|
@ -43,7 +44,7 @@ Column {
|
|||
Rectangle {
|
||||
width: parent.width * Math.min(1, (root.usedGb + root.cachedGb) / Math.max(root.totalGb, 0.001))
|
||||
height: parent.height
|
||||
color: S.Theme.base0D
|
||||
color: NS.ThemeService.base0D
|
||||
opacity: 0.4
|
||||
radius: 3
|
||||
Behavior on width {
|
||||
|
|
@ -97,7 +98,7 @@ Column {
|
|||
height: 32
|
||||
history: S.SystemStats.memHistory
|
||||
strokeColor: root.accentColor
|
||||
colorAt: v => S.Theme.loadColor(v)
|
||||
colorAt: v => S.ThemeUtil.loadColor(v)
|
||||
active: root.active
|
||||
}
|
||||
|
||||
|
|
@ -117,9 +118,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "PROCESS"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -128,9 +129,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "MEM"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
}
|
||||
|
|
@ -148,9 +149,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.cmd
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: parent.width - 80
|
||||
}
|
||||
|
|
@ -160,9 +161,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.mem.toFixed(1) + "%"
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 36
|
||||
horizontalAlignment: Text.AlignRight
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -15,7 +16,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
}
|
||||
|
||||
// Outgoing art - snaps to current opacity, then fades out
|
||||
|
|
@ -132,7 +133,7 @@ Column {
|
|||
}
|
||||
GradientStop {
|
||||
position: 1
|
||||
color: S.Theme.base01
|
||||
color: NS.ThemeService.base01
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -140,9 +141,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "\uF001"
|
||||
color: S.Theme.base04
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: 28
|
||||
font.family: S.Theme.iconFontFamily
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
visible: !_artImg._hasArt
|
||||
}
|
||||
}
|
||||
|
|
@ -164,9 +165,9 @@ Column {
|
|||
Text {
|
||||
width: parent.width
|
||||
text: S.MprisService.player?.trackTitle || "No track"
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize + 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize + 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
@ -180,9 +181,9 @@ Column {
|
|||
const artist = Array.isArray(p.trackArtists) ? p.trackArtists.join(", ") : (p.trackArtists || "");
|
||||
return [artist, p.trackAlbum].filter(s => s).join(" \u2014 ");
|
||||
}
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
visible: text !== ""
|
||||
}
|
||||
|
|
@ -209,18 +210,18 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: parent._fmtTime(parent.pos)
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
Text {
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: parent._fmtTime(parent.dur)
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Item {
|
||||
|
|
@ -231,7 +232,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 2
|
||||
}
|
||||
Rectangle {
|
||||
|
|
@ -254,9 +255,9 @@ Column {
|
|||
|
||||
Text {
|
||||
text: "\uF048"
|
||||
color: S.MprisService.player?.canGoPrevious ? S.Theme.base05 : S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize + 4
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: S.MprisService.player?.canGoPrevious ? NS.ThemeService.base05 : NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize + 4
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -270,8 +271,8 @@ Column {
|
|||
Text {
|
||||
text: S.MprisService.playing ? "\uF04C" : "\uF04B"
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize + 8
|
||||
font.family: S.Theme.iconFontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize + 8
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -283,9 +284,9 @@ Column {
|
|||
|
||||
Text {
|
||||
text: "\uF051"
|
||||
color: S.MprisService.player?.canGoNext ? S.Theme.base05 : S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize + 4
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: S.MprisService.player?.canGoNext ? NS.ThemeService.base05 : NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize + 4
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -323,17 +324,17 @@ Column {
|
|||
width: _pLabel.implicitWidth + 12
|
||||
height: 18
|
||||
radius: 9
|
||||
color: _active ? S.Theme.base02 : (pHover.hovered ? S.Theme.base02 : "transparent")
|
||||
border.color: _active ? root.accentColor : S.Theme.base03
|
||||
color: _active ? NS.ThemeService.base02 : (pHover.hovered ? NS.ThemeService.base02 : "transparent")
|
||||
border.color: _active ? root.accentColor : NS.ThemeService.base03
|
||||
border.width: _active ? 1 : 0
|
||||
|
||||
Text {
|
||||
id: _pLabel
|
||||
anchors.centerIn: parent
|
||||
text: modelData.identity ?? "Player"
|
||||
color: _active ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: _active ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: _active
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
// NOT safe for lock screen - can toggle wifi and connect/disconnect networks
|
||||
Column {
|
||||
|
|
@ -20,9 +21,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "\uF011"
|
||||
color: S.NetworkService.wifiEnabled ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: S.NetworkService.wifiEnabled ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
|
|
@ -55,9 +56,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: entry.modelData.isWifi ? "\uF1EB" : "\uDB80\uDE00"
|
||||
color: entry.modelData.active ? root.accentColor : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize + 1
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: entry.modelData.active ? root.accentColor : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize + 1
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
Text {
|
||||
|
|
@ -67,9 +68,9 @@ Column {
|
|||
anchors.rightMargin: 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: entry.modelData.name
|
||||
color: entry.modelData.active ? root.accentColor : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: entry.modelData.active ? root.accentColor : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: entry.modelData.active
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
@ -80,9 +81,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: entry.modelData.signal >= 0 ? entry.modelData.signal + "%" : ""
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: entry.modelData.signal >= 0 ? implicitWidth : 0
|
||||
}
|
||||
|
||||
|
|
@ -102,8 +103,8 @@ Column {
|
|||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: S.NetworkService.wifiEnabled ? "No networks available" : "Wi-Fi is off"
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import "../modules" as M
|
||||
import NovaStats as NS
|
||||
|
||||
// NOT safe for lock screen - notification contents may be sensitive,
|
||||
// can dismiss/clear notifications and toggle DND
|
||||
|
|
@ -21,9 +22,9 @@ Column {
|
|||
// Clear all
|
||||
Text {
|
||||
text: "\uF1F8"
|
||||
color: _clearHover.hovered ? S.Theme.base08 : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: _clearHover.hovered ? NS.ThemeService.base08 : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
visible: S.NotifService.count > 0
|
||||
|
||||
HoverHandler {
|
||||
|
|
@ -38,9 +39,9 @@ Column {
|
|||
// DND toggle
|
||||
Text {
|
||||
text: S.NotifService.dnd ? "\uDB82\uDE93" : "\uDB80\uDC9C"
|
||||
color: S.NotifService.dnd ? S.Theme.base09 : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: S.NotifService.dnd ? NS.ThemeService.base09 : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -201,7 +202,7 @@ Column {
|
|||
ListView {
|
||||
id: _notifList
|
||||
width: root.contentWidth
|
||||
height: Math.min(contentHeight, 60 * (S.Modules.notifications.maxVisible || 10))
|
||||
height: Math.min(contentHeight, 60 * (NS.ModulesService.notificationsMaxVisible || 10))
|
||||
clip: true
|
||||
boundsBehavior: Flickable.StopAtBounds
|
||||
model: root._flatModel
|
||||
|
|
@ -228,7 +229,7 @@ Column {
|
|||
|
||||
readonly property real _targetHeight: {
|
||||
if (_type === "header")
|
||||
return modelData.collapsed ? (28 + modelData.count * (S.Theme.fontSize + 4)) : 28;
|
||||
return modelData.collapsed ? (28 + modelData.count * (NS.ThemeService.fontSize + 4)) : 28;
|
||||
return _notifCard.implicitHeight;
|
||||
}
|
||||
|
||||
|
|
@ -298,12 +299,12 @@ Column {
|
|||
anchors.leftMargin: 10
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: (28 - height) / 2
|
||||
width: S.Theme.fontSize + 2
|
||||
height: S.Theme.fontSize + 2
|
||||
width: NS.ThemeService.fontSize + 2
|
||||
height: NS.ThemeService.fontSize + 2
|
||||
source: notifDelegate._type === "header" ? (notifDelegate.modelData.resolvedIcon || "") : ""
|
||||
visible: status === Image.Ready
|
||||
fillMode: Image.PreserveAspectFit
|
||||
sourceSize: Qt.size(S.Theme.fontSize + 2, S.Theme.fontSize + 2)
|
||||
sourceSize: Qt.size(NS.ThemeService.fontSize + 2, NS.ThemeService.fontSize + 2)
|
||||
asynchronous: true
|
||||
}
|
||||
|
||||
|
|
@ -315,9 +316,9 @@ Column {
|
|||
height: 28
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: notifDelegate._type === "header" && notifDelegate.modelData.collapsed ? "\u25B8" : "\u25BE"
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
opacity: _headerHover.hovered ? 1 : 0
|
||||
}
|
||||
|
||||
|
|
@ -330,9 +331,9 @@ Column {
|
|||
height: 28
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: notifDelegate._type === "header" ? (notifDelegate.modelData.appName || "Unknown") : ""
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
@ -345,9 +346,9 @@ Column {
|
|||
height: 28
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: "\uF1F8"
|
||||
color: _groupDismissHover.hovered ? S.Theme.base08 : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: _groupDismissHover.hovered ? NS.ThemeService.base08 : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
opacity: _headerHover.hovered ? 1 : 0
|
||||
|
||||
HoverHandler {
|
||||
|
|
@ -373,14 +374,14 @@ Column {
|
|||
anchors.leftMargin: 10
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 10
|
||||
y: 28 + index * (S.Theme.fontSize + 4)
|
||||
height: S.Theme.fontSize + 4
|
||||
y: 28 + index * (NS.ThemeService.fontSize + 4)
|
||||
height: NS.ThemeService.fontSize + 4
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: modelData
|
||||
elide: Text.ElideRight
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -442,8 +443,8 @@ Column {
|
|||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
text: "No notifications"
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import QtQuick
|
||||
import Quickshell
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
// NOT safe for lock screen - executes system commands (shutdown, reboot, logout, suspend)
|
||||
Column {
|
||||
|
|
@ -42,35 +43,35 @@ Column {
|
|||
label: "Lock",
|
||||
icon: "\uF023",
|
||||
cmd: ["loginctl", "lock-session"],
|
||||
color: S.Theme.base0D,
|
||||
color: NS.ThemeService.base0D,
|
||||
confirm: false
|
||||
},
|
||||
{
|
||||
label: "Suspend",
|
||||
icon: "\uF186",
|
||||
cmd: ["systemctl", "suspend"],
|
||||
color: S.Theme.base0E,
|
||||
color: NS.ThemeService.base0E,
|
||||
confirm: false
|
||||
},
|
||||
{
|
||||
label: "Logout",
|
||||
icon: "\uF2F5",
|
||||
cmd: root._isNiri ? ["niri", "msg", "action", "quit"] : ["loginctl", "terminate-user", ""],
|
||||
color: S.Theme.base0A,
|
||||
color: NS.ThemeService.base0A,
|
||||
confirm: false
|
||||
},
|
||||
{
|
||||
label: "Reboot",
|
||||
icon: "\uF021",
|
||||
cmd: ["systemctl", "reboot"],
|
||||
color: S.Theme.base09,
|
||||
color: NS.ThemeService.base09,
|
||||
confirm: true
|
||||
},
|
||||
{
|
||||
label: "Shutdown",
|
||||
icon: "\uF011",
|
||||
cmd: ["systemctl", "poweroff"],
|
||||
color: S.Theme.base08,
|
||||
color: NS.ThemeService.base08,
|
||||
confirm: true
|
||||
}
|
||||
]
|
||||
|
|
@ -88,8 +89,8 @@ Column {
|
|||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 4
|
||||
color: entryHover.hovered ? S.Theme.base02 : "transparent"
|
||||
radius: S.Theme.radius
|
||||
color: entryHover.hovered ? NS.ThemeService.base02 : "transparent"
|
||||
radius: NS.ThemeService.radius
|
||||
}
|
||||
|
||||
Text {
|
||||
|
|
@ -99,8 +100,8 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
text: entry.modelData.icon
|
||||
color: entry.modelData.color
|
||||
font.pixelSize: S.Theme.fontSize + 1
|
||||
font.family: S.Theme.iconFontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize + 1
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
}
|
||||
|
||||
Text {
|
||||
|
|
@ -108,9 +109,9 @@ Column {
|
|||
anchors.left: entryIcon.right
|
||||
anchors.leftMargin: 10
|
||||
text: entry.modelData.label
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
HoverHandler {
|
||||
|
|
@ -138,9 +139,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: root._confirmItem ? root._confirmItem.label + "?" : ""
|
||||
color: root._confirmItem ? root._confirmItem.color : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: root._confirmItem ? root._confirmItem.color : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
}
|
||||
|
|
@ -155,18 +156,18 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: cancelHover.hovered ? S.Theme.base02 : S.Theme.base01
|
||||
radius: S.Theme.radius
|
||||
color: cancelHover.hovered ? NS.ThemeService.base02 : NS.ThemeService.base01
|
||||
radius: NS.ThemeService.radius
|
||||
border.width: 1
|
||||
border.color: S.Theme.base03
|
||||
border.color: NS.ThemeService.base03
|
||||
}
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "Cancel"
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
HoverHandler {
|
||||
|
|
@ -187,21 +188,21 @@ Column {
|
|||
anchors.fill: parent
|
||||
color: {
|
||||
if (!root._confirmItem)
|
||||
return S.Theme.base02;
|
||||
return NS.ThemeService.base02;
|
||||
const c = root._confirmItem.color;
|
||||
return confirmHover.hovered ? Qt.rgba(c.r, c.g, c.b, 0.3) : Qt.rgba(c.r, c.g, c.b, 0.15);
|
||||
}
|
||||
radius: S.Theme.radius
|
||||
radius: NS.ThemeService.radius
|
||||
border.width: 1
|
||||
border.color: root._confirmItem ? root._confirmItem.color : S.Theme.base03
|
||||
border.color: root._confirmItem ? root._confirmItem.color : NS.ThemeService.base03
|
||||
}
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "Confirm"
|
||||
color: root._confirmItem ? root._confirmItem.color : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: root._confirmItem ? root._confirmItem.color : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,10 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Rectangle {
|
||||
width: (parent?.width ?? 16) - 16
|
||||
height: 1
|
||||
anchors.horizontalCenter: parent?.horizontalCenter
|
||||
color: S.Theme.base03
|
||||
color: NS.ThemeService.base03
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ pragma ComponentBehavior: Bound
|
|||
|
||||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -21,9 +22,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "SYSTEM"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -35,10 +36,10 @@ Column {
|
|||
color: {
|
||||
const st = S.SystemdService.systemState;
|
||||
if (st === "running")
|
||||
return S.Theme.base0B;
|
||||
return NS.ThemeService.base0B;
|
||||
if (st === "degraded")
|
||||
return S.Theme.base0A;
|
||||
return S.Theme.base08;
|
||||
return NS.ThemeService.base0A;
|
||||
return NS.ThemeService.base08;
|
||||
}
|
||||
opacity: 0.85
|
||||
radius: 3
|
||||
|
|
@ -49,9 +50,9 @@ Column {
|
|||
id: _sysStateLbl
|
||||
anchors.centerIn: parent
|
||||
text: S.SystemdService.systemState
|
||||
color: S.Theme.base00
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base00
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -79,9 +80,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "no failed system units"
|
||||
color: S.Theme.base0B
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base0B
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -97,9 +98,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "USER"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 1
|
||||
}
|
||||
|
||||
|
|
@ -111,10 +112,10 @@ Column {
|
|||
color: {
|
||||
const st = S.SystemdService.userState;
|
||||
if (st === "running")
|
||||
return S.Theme.base0B;
|
||||
return NS.ThemeService.base0B;
|
||||
if (st === "degraded")
|
||||
return S.Theme.base0A;
|
||||
return S.Theme.base08;
|
||||
return NS.ThemeService.base0A;
|
||||
return NS.ThemeService.base08;
|
||||
}
|
||||
opacity: 0.85
|
||||
radius: 3
|
||||
|
|
@ -125,9 +126,9 @@ Column {
|
|||
id: _userStateLbl
|
||||
anchors.centerIn: parent
|
||||
text: S.SystemdService.userState
|
||||
color: S.Theme.base00
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base00
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -155,9 +156,9 @@ Column {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: "no failed user units"
|
||||
color: S.Theme.base0B
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base0B
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
|
@ -72,8 +73,8 @@ Item {
|
|||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 4
|
||||
color: _rowHover.hovered ? S.Theme.base02 : "transparent"
|
||||
radius: S.Theme.radius
|
||||
color: _rowHover.hovered ? NS.ThemeService.base02 : "transparent"
|
||||
radius: NS.ThemeService.radius
|
||||
z: -1
|
||||
}
|
||||
|
||||
|
|
@ -88,9 +89,9 @@ Item {
|
|||
anchors.rightMargin: 6
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.unitName
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
||||
|
|
@ -99,7 +100,7 @@ Item {
|
|||
anchors.right: _restartBtn.left
|
||||
anchors.rightMargin: 6
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: S.Theme.base08
|
||||
color: NS.ThemeService.base08
|
||||
opacity: 0.85
|
||||
radius: 3
|
||||
width: _subStateLbl.width + 8
|
||||
|
|
@ -109,9 +110,9 @@ Item {
|
|||
id: _subStateLbl
|
||||
anchors.centerIn: parent
|
||||
text: root.subState
|
||||
color: S.Theme.base00
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base00
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -127,9 +128,9 @@ Item {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: ""
|
||||
color: _rHover.hovered ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: _rHover.hovered ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: 80
|
||||
|
|
@ -164,9 +165,9 @@ Item {
|
|||
Text {
|
||||
anchors.centerIn: parent
|
||||
text: root._expanded ? "" : ""
|
||||
color: _expHover.hovered ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: _expHover.hovered ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: 80
|
||||
|
|
@ -202,16 +203,16 @@ Item {
|
|||
anchors.leftMargin: 8
|
||||
anchors.rightMargin: 8
|
||||
anchors.bottomMargin: 4
|
||||
color: S.Theme.base01
|
||||
radius: S.Theme.radius
|
||||
color: NS.ThemeService.base01
|
||||
radius: NS.ThemeService.radius
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
visible: root._loading
|
||||
text: "loading..."
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Flickable {
|
||||
|
|
@ -226,9 +227,9 @@ Item {
|
|||
id: _jContent
|
||||
width: _flick.width
|
||||
text: root._jText
|
||||
color: S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
wrapMode: Text.WrapAnywhere
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -14,7 +15,7 @@ Column {
|
|||
property bool active: true
|
||||
property string deviceFilter: ""
|
||||
|
||||
property color stateColor: temp > hot ? S.Theme.base08 : temp > warm ? S.Theme.base0A : root.accentColor
|
||||
property color stateColor: temp > hot ? NS.ThemeService.base08 : temp > warm ? NS.ThemeService.base0A : root.accentColor
|
||||
Behavior on stateColor {
|
||||
ColorAnimation {
|
||||
duration: 300
|
||||
|
|
@ -32,8 +33,8 @@ Column {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.temp + "\u00B0C"
|
||||
color: root.stateColor
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: true
|
||||
width: _tempSizer.implicitWidth
|
||||
horizontalAlignment: Text.AlignRight
|
||||
|
|
@ -63,7 +64,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
|
||||
|
|
@ -87,7 +88,7 @@ Column {
|
|||
width: 1
|
||||
height: parent.height + 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: S.Theme.base0A
|
||||
color: NS.ThemeService.base0A
|
||||
opacity: 0.6
|
||||
}
|
||||
|
||||
|
|
@ -97,7 +98,7 @@ Column {
|
|||
width: 1
|
||||
height: parent.height + 4
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: S.Theme.base08
|
||||
color: NS.ThemeService.base08
|
||||
opacity: 0.6
|
||||
}
|
||||
}
|
||||
|
|
@ -116,11 +117,11 @@ Column {
|
|||
thresholds: [
|
||||
{
|
||||
value: root.warm,
|
||||
color: S.Theme.base0A
|
||||
color: NS.ThemeService.base0A
|
||||
},
|
||||
{
|
||||
value: root.hot,
|
||||
color: S.Theme.base08
|
||||
color: NS.ThemeService.base08
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -135,9 +136,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "warm " + root.warm + "\u00B0 hot " + root.hot + "\u00B0"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.letterSpacing: 0.5
|
||||
}
|
||||
|
||||
|
|
@ -146,9 +147,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "10 min"
|
||||
color: S.Theme.base03
|
||||
font.pixelSize: S.Theme.fontSize - 3
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base03
|
||||
font.pixelSize: NS.ThemeService.fontSize - 3
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -179,9 +180,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.name
|
||||
color: _isActive ? root.accentColor : S.Theme.base04
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: _isActive ? root.accentColor : NS.ThemeService.base04
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: parent.width - 80
|
||||
}
|
||||
|
|
@ -191,9 +192,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.celsius + "\u00B0C"
|
||||
color: S.Theme.loadColor(modelData.celsius)
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: S.ThemeUtil.loadColor(modelData.celsius)
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: _isActive
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import QtQuick
|
||||
import Quickshell.Services.Pipewire
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -11,7 +12,7 @@ Column {
|
|||
property real volume: sink?.audio?.volume ?? 0
|
||||
property bool muted: sink?.audio?.muted ?? false
|
||||
readonly property string volumeIcon: muted ? "\uF026" : (volume > 0.5 ? "\uF028" : (volume > 0 ? "\uF027" : "\uF026"))
|
||||
readonly property color volumeColor: muted ? S.Theme.base04 : root.accentColor
|
||||
readonly property color volumeColor: muted ? NS.ThemeService.base04 : root.accentColor
|
||||
|
||||
// Slider row
|
||||
Item {
|
||||
|
|
@ -25,8 +26,8 @@ Column {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: root.volumeIcon
|
||||
color: root.volumeColor
|
||||
font.pixelSize: S.Theme.fontSize + 2
|
||||
font.family: S.Theme.iconFontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize + 2
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -48,7 +49,7 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 3
|
||||
}
|
||||
Rectangle {
|
||||
|
|
@ -86,9 +87,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: Math.round(root.volume * 100) + "%"
|
||||
color: root.muted ? S.Theme.base04 : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: root.muted ? NS.ThemeService.base04 : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 30
|
||||
}
|
||||
}
|
||||
|
|
@ -113,8 +114,8 @@ Column {
|
|||
leftPadding: 12
|
||||
text: "Output Devices"
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -134,9 +135,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: modelData.description || modelData.name || "Unknown"
|
||||
color: parent._active ? root.accentColor : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.fontFamily
|
||||
color: parent._active ? root.accentColor : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
font.bold: parent._active
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
@ -159,8 +160,8 @@ Column {
|
|||
leftPadding: 12
|
||||
text: "Applications"
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -183,9 +184,9 @@ Column {
|
|||
anchors.leftMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: streamEntry._muted ? "\uF026" : "\uF028"
|
||||
color: streamEntry._muted ? S.Theme.base04 : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize
|
||||
font.family: S.Theme.iconFontFamily
|
||||
color: streamEntry._muted ? NS.ThemeService.base04 : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize
|
||||
font.family: NS.ThemeService.iconFontFamily
|
||||
|
||||
HoverHandler {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
|
@ -202,9 +203,9 @@ Column {
|
|||
anchors.leftMargin: 6
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: streamEntry._appName
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
elide: Text.ElideRight
|
||||
width: 70
|
||||
}
|
||||
|
|
@ -220,13 +221,13 @@ Column {
|
|||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: S.Theme.base02
|
||||
color: NS.ThemeService.base02
|
||||
radius: 2
|
||||
}
|
||||
Rectangle {
|
||||
width: parent.width * Math.min(1, Math.max(0, streamEntry._vol))
|
||||
height: parent.height
|
||||
color: streamEntry._muted ? S.Theme.base04 : root.accentColor
|
||||
color: streamEntry._muted ? NS.ThemeService.base04 : root.accentColor
|
||||
radius: 2
|
||||
}
|
||||
|
||||
|
|
@ -253,9 +254,9 @@ Column {
|
|||
anchors.rightMargin: 12
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: Math.round(streamEntry._vol * 100) + "%"
|
||||
color: streamEntry._muted ? S.Theme.base04 : S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 1
|
||||
font.family: S.Theme.fontFamily
|
||||
color: streamEntry._muted ? NS.ThemeService.base04 : NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 1
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
width: 28
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import QtQuick
|
||||
import "../services" as S
|
||||
import NovaStats as NS
|
||||
|
||||
Column {
|
||||
id: root
|
||||
|
|
@ -17,8 +18,8 @@ Column {
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: S.WeatherService.icon
|
||||
color: root.accentColor
|
||||
font.pixelSize: S.Theme.fontSize + 2
|
||||
font.family: S.Theme.fontFamily
|
||||
font.pixelSize: NS.ThemeService.fontSize + 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -28,9 +29,9 @@ Column {
|
|||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
text: S.WeatherService.tooltip.replace(/\n/g, "<br>")
|
||||
textFormat: Text.RichText
|
||||
color: S.Theme.base05
|
||||
font.pixelSize: S.Theme.fontSize - 2
|
||||
font.family: S.Theme.fontFamily
|
||||
color: NS.ThemeService.base05
|
||||
font.pixelSize: NS.ThemeService.fontSize - 2
|
||||
font.family: NS.ThemeService.fontFamily
|
||||
wrapMode: Text.WordWrap
|
||||
lineHeight: 1.3
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue