fix: use correct size tokens in QML

This commit is contained in:
2 * r + 2 * t 2026-04-11 21:24:16 +10:00
parent 2b2d5a4873
commit b5dcd07ab8
46 changed files with 121 additions and 121 deletions

View file

@ -57,7 +57,7 @@ Variants {
active: Config.background.desktopClock.enabled active: Config.background.desktopClock.enabled
anchors.margins: Tokens.padding.large * 2 anchors.margins: Tokens.padding.large * 2
anchors.leftMargin: Tokens.padding.large * 2 + Config.bar.sizes.innerWidth + Math.max(Tokens.padding.smaller, Config.border.thickness) anchors.leftMargin: Tokens.padding.large * 2 + Tokens.sizes.bar.innerWidth + Math.max(Tokens.padding.smaller, Config.border.thickness)
state: Config.background.desktopClock.position state: Config.background.desktopClock.position
states: [ states: [

View file

@ -19,7 +19,7 @@ Item {
readonly property int clampedWidth: Math.max(Config.border.minThickness, implicitWidth) readonly property int clampedWidth: Math.max(Config.border.minThickness, implicitWidth)
readonly property int padding: Math.max(Tokens.padding.smaller, Config.border.thickness) readonly property int padding: Math.max(Tokens.padding.smaller, Config.border.thickness)
readonly property int contentWidth: Config.bar.sizes.innerWidth + padding * 2 readonly property int contentWidth: Tokens.sizes.bar.innerWidth + padding * 2
readonly property int exclusiveZone: !disabled && (Config.bar.persistent || visibilities.bar) ? contentWidth : Config.border.thickness readonly property int exclusiveZone: !disabled && (Config.bar.persistent || visibilities.bar) ? contentWidth : Config.border.thickness
readonly property bool shouldBeVisible: !fullscreen && !disabled && (Config.bar.persistent || visibilities.bar || isHovered) readonly property bool shouldBeVisible: !fullscreen && !disabled && (Config.bar.persistent || visibilities.bar || isHovered)
property bool isHovered property bool isHovered

View file

@ -11,7 +11,7 @@ StyledRect {
readonly property color colour: Colours.palette.m3tertiary readonly property color colour: Colours.palette.m3tertiary
readonly property int padding: Config.bar.clock.background ? Tokens.padding.normal : Tokens.padding.small readonly property int padding: Config.bar.clock.background ? Tokens.padding.normal : Tokens.padding.small
implicitWidth: Config.bar.sizes.innerWidth implicitWidth: Tokens.sizes.bar.innerWidth
implicitHeight: layout.implicitHeight + root.padding * 2 implicitHeight: layout.implicitHeight + root.padding * 2
color: Qt.alpha(Colours.tPalette.m3surfaceContainer, Config.bar.clock.background ? Colours.tPalette.m3surfaceContainer.a : 0) color: Qt.alpha(Colours.tPalette.m3surfaceContainer, Config.bar.clock.background ? Colours.tPalette.m3surfaceContainer.a : 0)

View file

@ -20,7 +20,7 @@ StyledRect {
radius: Tokens.rounding.full radius: Tokens.rounding.full
clip: true clip: true
implicitWidth: Config.bar.sizes.innerWidth implicitWidth: Tokens.sizes.bar.innerWidth
implicitHeight: iconColumn.implicitHeight + Tokens.padding.normal * 2 - (Config.bar.status.showLockStatus && !Hypr.capsLock && !Hypr.numLock ? iconColumn.spacing : 0) implicitHeight: iconColumn.implicitHeight + Tokens.padding.normal * 2 - (Config.bar.status.showLockStatus && !Hypr.capsLock && !Hypr.numLock ? iconColumn.spacing : 0)
ColumnLayout { ColumnLayout {

View file

@ -28,7 +28,7 @@ StyledRect {
clip: true clip: true
visible: height > 0 visible: height > 0
implicitWidth: Config.bar.sizes.innerWidth implicitWidth: Tokens.sizes.bar.innerWidth
implicitHeight: nonAnimHeight implicitHeight: nonAnimHeight
color: Qt.alpha(Colours.tPalette.m3surfaceContainer, (Config.bar.tray.background && items.count > 0) ? Colours.tPalette.m3surfaceContainer.a : 0) color: Qt.alpha(Colours.tPalette.m3surfaceContainer, (Config.bar.tray.background && items.count > 0) ? Colours.tPalette.m3surfaceContainer.a : 0)

View file

@ -42,7 +42,7 @@ StyledRect {
clip: true clip: true
y: offset + mask.y y: offset + mask.y
implicitWidth: Config.bar.sizes.innerWidth - Tokens.padding.small * 2 implicitWidth: Tokens.sizes.bar.innerWidth - Tokens.padding.small * 2
implicitHeight: size implicitHeight: size
radius: Tokens.rounding.full radius: Tokens.rounding.full
color: Colours.palette.m3primary color: Colours.palette.m3primary

View file

@ -65,7 +65,7 @@ Item {
anchors.horizontalCenter: root.horizontalCenter anchors.horizontalCenter: root.horizontalCenter
y: (start?.y ?? 0) - 1 y: (start?.y ?? 0) - 1
implicitWidth: Config.bar.sizes.innerWidth - Tokens.padding.small * 2 + 2 implicitWidth: Tokens.sizes.bar.innerWidth - Tokens.padding.small * 2 + 2
implicitHeight: start && end ? end.y + end.size - start.y + 2 : 0 implicitHeight: start && end ? end.y + end.size - start.y + 2 : 0
color: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2) color: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2)

View file

@ -284,7 +284,7 @@ Item {
asynchronous: true asynchronous: true
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
Layout.preferredHeight: Config.bar.sizes.innerWidth - Tokens.padding.small * 2 Layout.preferredHeight: Tokens.sizes.bar.innerWidth - Tokens.padding.small * 2
sourceComponent: ws.icon.length === 1 ? letterComp : iconComp sourceComponent: ws.icon.length === 1 ? letterComp : iconComp

View file

@ -33,7 +33,7 @@ ColumnLayout {
id: indicator id: indicator
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
Layout.preferredHeight: Config.bar.sizes.innerWidth - Tokens.padding.small * 2 Layout.preferredHeight: Tokens.sizes.bar.innerWidth - Tokens.padding.small * 2
animate: true animate: true
text: { text: {
@ -61,7 +61,7 @@ ColumnLayout {
Layout.alignment: Qt.AlignHCenter Layout.alignment: Qt.AlignHCenter
Layout.fillHeight: true Layout.fillHeight: true
Layout.topMargin: -Config.bar.sizes.innerWidth / 10 Layout.topMargin: -Tokens.sizes.bar.innerWidth / 10
visible: active visible: active
active: root.hasWindows active: root.hasWindows

View file

@ -27,7 +27,7 @@ StyledClippingRect {
property real blur: onSpecial ? 1 : 0 property real blur: onSpecial ? 1 : 0
implicitWidth: Config.bar.sizes.innerWidth implicitWidth: Tokens.sizes.bar.innerWidth
implicitHeight: layout.implicitHeight + Tokens.padding.small * 2 implicitHeight: layout.implicitHeight + Tokens.padding.small * 2
color: Colours.tPalette.m3surfaceContainer color: Colours.tPalette.m3surfaceContainer

View file

@ -95,8 +95,8 @@ Item {
captureSource: Hypr.activeToplevel?.wayland ?? null // qmllint disable unresolved-type captureSource: Hypr.activeToplevel?.wayland ?? null // qmllint disable unresolved-type
live: visible live: visible
constraintSize.width: Config.bar.sizes.windowPreviewSize constraintSize.width: Tokens.sizes.bar.windowPreviewSize
constraintSize.height: Config.bar.sizes.windowPreviewSize constraintSize.height: Tokens.sizes.bar.windowPreviewSize
} }
} }
} }

View file

@ -10,7 +10,7 @@ Column {
id: root id: root
spacing: Tokens.spacing.normal spacing: Tokens.spacing.normal
width: Config.bar.sizes.batteryWidth width: Tokens.sizes.bar.batteryWidth
StyledText { StyledText {
text: UPower.displayDevice.isLaptopBattery ? qsTr("Remaining: %1%").arg(Math.round(UPower.displayDevice.percentage * 100)) : qsTr("No battery detected") text: UPower.displayDevice.isLaptopBattery ? qsTr("Remaining: %1%").arg(Math.round(UPower.displayDevice.percentage * 100)) : qsTr("No battery detected")

View file

@ -20,7 +20,7 @@ ColumnLayout {
property bool showPasswordDialog: false property bool showPasswordDialog: false
spacing: Tokens.spacing.small spacing: Tokens.spacing.small
width: Config.bar.sizes.networkWidth width: Tokens.sizes.bar.networkWidth
// Wireless section // Wireless section
StyledText { StyledText {

View file

@ -78,7 +78,7 @@ StackView {
required property QsMenuEntry modelData required property QsMenuEntry modelData
implicitWidth: Config.bar.sizes.trayMenuWidth implicitWidth: Tokens.sizes.bar.trayMenuWidth
implicitHeight: modelData.isSeparator ? 1 : children.implicitHeight implicitHeight: modelData.isSeparator ? 1 : children.implicitHeight
radius: Tokens.rounding.full radius: Tokens.rounding.full
@ -152,7 +152,7 @@ StackView {
font.family: label.font.family font.family: label.font.family
elide: Text.ElideRight elide: Text.ElideRight
elideWidth: Config.bar.sizes.trayMenuWidth - (icon.active ? icon.implicitWidth + label.anchors.leftMargin : 0) - (expand.active ? expand.implicitWidth + Tokens.spacing.normal : 0) elideWidth: Tokens.sizes.bar.trayMenuWidth - (icon.active ? icon.implicitWidth + label.anchors.leftMargin : 0) - (expand.active ? expand.implicitWidth + Tokens.spacing.normal : 0)
} }
Loader { Loader {

View file

@ -15,7 +15,7 @@ ColumnLayout {
} }
spacing: Tokens.spacing.small spacing: Tokens.spacing.small
width: Config.bar.sizes.kbLayoutWidth width: Tokens.sizes.bar.kbLayoutWidth
Component.onCompleted: kb.start() Component.onCompleted: kb.start()

View file

@ -27,8 +27,8 @@ Item {
signal close signal close
implicitWidth: implicitHeight * Config.controlCenter.sizes.ratio implicitWidth: implicitHeight * Tokens.sizes.controlCenter.ratio
implicitHeight: screen.height * Config.controlCenter.sizes.heightMult implicitHeight: screen.height * Tokens.sizes.controlCenter.heightMult
GridLayout { GridLayout {
anchors.fill: parent anchors.fill: parent

View file

@ -178,25 +178,25 @@ ColumnLayout {
PropertyRow { PropertyRow {
label: qsTr("Item width") label: qsTr("Item width")
value: qsTr("%1 px").arg(Config.launcher.sizes.itemWidth) value: qsTr("%1 px").arg(Tokens.sizes.launcher.itemWidth)
} }
PropertyRow { PropertyRow {
showTopMargin: true showTopMargin: true
label: qsTr("Item height") label: qsTr("Item height")
value: qsTr("%1 px").arg(Config.launcher.sizes.itemHeight) value: qsTr("%1 px").arg(Tokens.sizes.launcher.itemHeight)
} }
PropertyRow { PropertyRow {
showTopMargin: true showTopMargin: true
label: qsTr("Wallpaper width") label: qsTr("Wallpaper width")
value: qsTr("%1 px").arg(Config.launcher.sizes.wallpaperWidth) value: qsTr("%1 px").arg(Tokens.sizes.launcher.wallpaperWidth)
} }
PropertyRow { PropertyRow {
showTopMargin: true showTopMargin: true
label: qsTr("Wallpaper height") label: qsTr("Wallpaper height")
value: qsTr("%1 px").arg(Config.launcher.sizes.wallpaperHeight) value: qsTr("%1 px").arg(Tokens.sizes.launcher.wallpaperHeight)
} }
} }

View file

@ -34,7 +34,7 @@ GridLayout {
Rect { Rect {
Layout.row: 0 Layout.row: 0
Layout.columnSpan: 2 Layout.columnSpan: 2
Layout.preferredWidth: Config.dashboard.sizes.weatherWidth Layout.preferredWidth: Tokens.sizes.dashboard.weatherWidth
Layout.fillHeight: true Layout.fillHeight: true
radius: Tokens.rounding.large * 1.5 radius: Tokens.rounding.large * 1.5

View file

@ -18,7 +18,7 @@ Item {
required property DrawerVisibilities visibilities required property DrawerVisibilities visibilities
readonly property bool needsKeyboard: lyricMenuOpen readonly property bool needsKeyboard: lyricMenuOpen
readonly property real nonAnimHeight: Math.max(cover.implicitHeight + Config.dashboard.sizes.mediaVisualiserSize * 2, lyricMenuOpen ? lyricMenu.implicitHeight : details.implicitHeight, bongocat.implicitHeight) + Tokens.padding.large * 2 readonly property real nonAnimHeight: Math.max(cover.implicitHeight + Tokens.sizes.dashboard.mediaVisualiserSize * 2, lyricMenuOpen ? lyricMenu.implicitHeight : details.implicitHeight, bongocat.implicitHeight) + Tokens.padding.large * 2
readonly property real detailsHeightWithoutLyrics: details.implicitHeight - lyricsViewInDetails.implicitHeight readonly property real detailsHeightWithoutLyrics: details.implicitHeight - lyricsViewInDetails.implicitHeight
property bool lyricMenuOpen: false property bool lyricMenuOpen: false
@ -52,7 +52,7 @@ Item {
} }
} }
implicitWidth: cover.implicitWidth + Config.dashboard.sizes.mediaVisualiserSize * 2 + details.implicitWidth + details.anchors.leftMargin + bongocat.implicitWidth + bongocat.anchors.leftMargin * 2 + Tokens.padding.large * 2 implicitWidth: cover.implicitWidth + Tokens.sizes.dashboard.mediaVisualiserSize * 2 + details.implicitWidth + details.anchors.leftMargin + bongocat.implicitWidth + bongocat.anchors.leftMargin * 2 + Tokens.padding.large * 2
implicitHeight: nonAnimHeight implicitHeight: nonAnimHeight
Behavior on implicitHeight { Behavior on implicitHeight {
@ -111,7 +111,7 @@ Item {
property color colour: Colours.palette.m3primary property color colour: Colours.palette.m3primary
anchors.fill: cover anchors.fill: cover
anchors.margins: -Config.dashboard.sizes.mediaVisualiserSize anchors.margins: -Tokens.sizes.dashboard.mediaVisualiserSize
asynchronous: true asynchronous: true
preferredRendererType: Shape.CurveRenderer preferredRendererType: Shape.CurveRenderer
@ -132,7 +132,7 @@ Item {
readonly property real value: Math.max(1e-3, Math.min(1, Audio.cava.values[modelData])) readonly property real value: Math.max(1e-3, Math.min(1, Audio.cava.values[modelData]))
readonly property real angle: modelData * 2 * Math.PI / Config.services.visualiserBars readonly property real angle: modelData * 2 * Math.PI / Config.services.visualiserBars
readonly property real magnitude: value * Config.dashboard.sizes.mediaVisualiserSize readonly property real magnitude: value * Tokens.sizes.dashboard.mediaVisualiserSize
readonly property real cos: Math.cos(angle) readonly property real cos: Math.cos(angle)
readonly property real sin: Math.sin(angle) readonly property real sin: Math.sin(angle)
@ -159,10 +159,10 @@ Item {
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.left: parent.left anchors.left: parent.left
anchors.leftMargin: Tokens.padding.large + Config.dashboard.sizes.mediaVisualiserSize anchors.leftMargin: Tokens.padding.large + Tokens.sizes.dashboard.mediaVisualiserSize
implicitWidth: Config.dashboard.sizes.mediaCoverArtSize implicitWidth: Tokens.sizes.dashboard.mediaCoverArtSize
implicitHeight: Config.dashboard.sizes.mediaCoverArtSize implicitHeight: Tokens.sizes.dashboard.mediaCoverArtSize
color: Colours.tPalette.m3surfaceContainerHigh color: Colours.tPalette.m3surfaceContainerHigh
radius: Infinity radius: Infinity

View file

@ -182,7 +182,7 @@ Item {
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
implicitHeight: parent.height + Config.dashboard.sizes.tabIndicatorSpacing * 2 implicitHeight: parent.height + Tokens.sizes.dashboard.tabIndicatorSpacing * 2
color: "transparent" color: "transparent"
radius: Tokens.rounding.small radius: Tokens.rounding.small

View file

@ -11,7 +11,7 @@ Item {
anchors.top: parent.top anchors.top: parent.top
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
implicitWidth: Config.dashboard.sizes.dateTimeWidth implicitWidth: Tokens.sizes.dashboard.dateTimeWidth
ColumnLayout { ColumnLayout {
anchors.left: parent.left anchors.left: parent.left

View file

@ -16,7 +16,7 @@ Item {
anchors.top: parent.top anchors.top: parent.top
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
implicitWidth: Config.dashboard.sizes.mediaWidth implicitWidth: Tokens.sizes.dashboard.mediaWidth
Behavior on playerProgress { Behavior on playerProgress {
Anim { Anim {
@ -42,16 +42,16 @@ Item {
ShapePath { ShapePath {
fillColor: "transparent" fillColor: "transparent"
strokeColor: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2) strokeColor: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2)
strokeWidth: Config.dashboard.sizes.mediaProgressThickness strokeWidth: Tokens.sizes.dashboard.mediaProgressThickness
capStyle: Tokens.rounding.scale === 0 ? ShapePath.SquareCap : ShapePath.RoundCap capStyle: Tokens.rounding.scale === 0 ? ShapePath.SquareCap : ShapePath.RoundCap
PathAngleArc { PathAngleArc {
centerX: cover.x + cover.width / 2 centerX: cover.x + cover.width / 2
centerY: cover.y + cover.height / 2 centerY: cover.y + cover.height / 2
radiusX: (cover.width + Config.dashboard.sizes.mediaProgressThickness) / 2 + Tokens.spacing.small radiusX: (cover.width + Tokens.sizes.dashboard.mediaProgressThickness) / 2 + Tokens.spacing.small
radiusY: (cover.height + Config.dashboard.sizes.mediaProgressThickness) / 2 + Tokens.spacing.small radiusY: (cover.height + Tokens.sizes.dashboard.mediaProgressThickness) / 2 + Tokens.spacing.small
startAngle: -90 - Config.dashboard.sizes.mediaProgressSweep / 2 startAngle: -90 - Tokens.sizes.dashboard.mediaProgressSweep / 2
sweepAngle: Config.dashboard.sizes.mediaProgressSweep sweepAngle: Tokens.sizes.dashboard.mediaProgressSweep
} }
Behavior on strokeColor { Behavior on strokeColor {
@ -62,16 +62,16 @@ Item {
ShapePath { ShapePath {
fillColor: "transparent" fillColor: "transparent"
strokeColor: Colours.palette.m3primary strokeColor: Colours.palette.m3primary
strokeWidth: Config.dashboard.sizes.mediaProgressThickness strokeWidth: Tokens.sizes.dashboard.mediaProgressThickness
capStyle: Tokens.rounding.scale === 0 ? ShapePath.SquareCap : ShapePath.RoundCap capStyle: Tokens.rounding.scale === 0 ? ShapePath.SquareCap : ShapePath.RoundCap
PathAngleArc { PathAngleArc {
centerX: cover.x + cover.width / 2 centerX: cover.x + cover.width / 2
centerY: cover.y + cover.height / 2 centerY: cover.y + cover.height / 2
radiusX: (cover.width + Config.dashboard.sizes.mediaProgressThickness) / 2 + Tokens.spacing.small radiusX: (cover.width + Tokens.sizes.dashboard.mediaProgressThickness) / 2 + Tokens.spacing.small
radiusY: (cover.height + Config.dashboard.sizes.mediaProgressThickness) / 2 + Tokens.spacing.small radiusY: (cover.height + Tokens.sizes.dashboard.mediaProgressThickness) / 2 + Tokens.spacing.small
startAngle: -90 - Config.dashboard.sizes.mediaProgressSweep / 2 startAngle: -90 - Tokens.sizes.dashboard.mediaProgressSweep / 2
sweepAngle: Config.dashboard.sizes.mediaProgressSweep * root.playerProgress sweepAngle: Tokens.sizes.dashboard.mediaProgressSweep * root.playerProgress
} }
Behavior on strokeColor { Behavior on strokeColor {
@ -86,7 +86,7 @@ Item {
anchors.top: parent.top anchors.top: parent.top
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
anchors.margins: Tokens.padding.large + Config.dashboard.sizes.mediaProgressThickness + Tokens.spacing.small anchors.margins: Tokens.padding.large + Tokens.sizes.dashboard.mediaProgressThickness + Tokens.spacing.small
implicitHeight: width implicitHeight: width
color: Colours.tPalette.m3surfaceContainerHigh color: Colours.tPalette.m3surfaceContainerHigh

View file

@ -53,7 +53,7 @@ Row {
anchors.bottom: icon.top anchors.bottom: icon.top
anchors.bottomMargin: Tokens.spacing.small anchors.bottomMargin: Tokens.spacing.small
implicitWidth: Config.dashboard.sizes.resourceProgessThickness implicitWidth: Tokens.sizes.dashboard.resourceProgessThickness
color: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2) color: Colours.layer(Colours.palette.m3surfaceContainerHigh, 2)
radius: Tokens.rounding.full radius: Tokens.rounding.full

View file

@ -120,7 +120,7 @@ Row {
id: icon id: icon
anchors.left: parent.left anchors.left: parent.left
anchors.leftMargin: (Config.dashboard.sizes.infoIconSize - implicitWidth) / 2 anchors.leftMargin: (Tokens.sizes.dashboard.infoIconSize - implicitWidth) / 2
source: SysInfo.osLogo source: SysInfo.osLogo
implicitSize: Math.floor(Tokens.font.size.normal * 1.34) implicitSize: Math.floor(Tokens.font.size.normal * 1.34)
@ -136,7 +136,7 @@ Row {
text: `: ${SysInfo.osPrettyName || SysInfo.osName}` text: `: ${SysInfo.osPrettyName || SysInfo.osName}`
font.pointSize: Tokens.font.size.normal font.pointSize: Tokens.font.size.normal
width: Config.dashboard.sizes.infoWidth width: Tokens.sizes.dashboard.infoWidth
elide: Text.ElideRight elide: Text.ElideRight
} }
} }
@ -170,7 +170,7 @@ Row {
id: icon id: icon
anchors.left: parent.left anchors.left: parent.left
anchors.leftMargin: (Config.dashboard.sizes.infoIconSize - implicitWidth) / 2 anchors.leftMargin: (Tokens.sizes.dashboard.infoIconSize - implicitWidth) / 2
fill: 1 fill: 1
text: line.icon text: line.icon
@ -187,7 +187,7 @@ Row {
text: `: ${line.text}` text: `: ${line.text}`
font.pointSize: Tokens.font.size.normal font.pointSize: Tokens.font.size.normal
width: Config.dashboard.sizes.infoWidth width: Tokens.sizes.dashboard.infoWidth
elide: Text.ElideRight elide: Text.ElideRight
} }
} }

View file

@ -24,7 +24,7 @@ StyledListView {
spacing: Tokens.spacing.small spacing: Tokens.spacing.small
orientation: Qt.Vertical orientation: Qt.Vertical
implicitHeight: (Config.launcher.sizes.itemHeight + spacing) * Math.min(Config.launcher.maxShown, count) - spacing implicitHeight: (Tokens.sizes.launcher.itemHeight + spacing) * Math.min(Config.launcher.maxShown, count) - spacing
preferredHighlightBegin: 0 preferredHighlightBegin: 0
preferredHighlightEnd: height preferredHighlightEnd: height

View file

@ -32,7 +32,7 @@ Item {
name: "apps" name: "apps"
PropertyChanges { PropertyChanges {
root.implicitWidth: Config.launcher.sizes.itemWidth root.implicitWidth: Tokens.sizes.launcher.itemWidth
root.implicitHeight: Math.min(root.maxHeight, appList.implicitHeight > 0 ? appList.implicitHeight : empty.implicitHeight) root.implicitHeight: Math.min(root.maxHeight, appList.implicitHeight > 0 ? appList.implicitHeight : empty.implicitHeight)
appList.active: true appList.active: true
} }
@ -46,8 +46,8 @@ Item {
name: "wallpapers" name: "wallpapers"
PropertyChanges { PropertyChanges {
root.implicitWidth: Math.max(Config.launcher.sizes.itemWidth * 1.2, wallpaperList.implicitWidth) root.implicitWidth: Math.max(Tokens.sizes.launcher.itemWidth * 1.2, wallpaperList.implicitWidth)
root.implicitHeight: Config.launcher.sizes.wallpaperHeight root.implicitHeight: Tokens.sizes.launcher.wallpaperHeight
wallpaperList.active: true wallpaperList.active: true
} }
} }

View file

@ -15,7 +15,7 @@ PathView {
required property var panels required property var panels
required property var content required property var content
readonly property int itemWidth: Config.launcher.sizes.wallpaperWidth * 0.8 + Tokens.padding.larger * 2 readonly property int itemWidth: Tokens.sizes.launcher.wallpaperWidth * 0.8 + Tokens.padding.larger * 2
readonly property int numItems: { readonly property int numItems: {
const screen = (QsWindow.window as QsWindow)?.screen; const screen = (QsWindow.window as QsWindow)?.screen;

View file

@ -9,7 +9,7 @@ Item {
required property var modelData required property var modelData
required property var list required property var list
implicitHeight: Config.launcher.sizes.itemHeight implicitHeight: Tokens.sizes.launcher.itemHeight
anchors.left: parent?.left anchors.left: parent?.left
anchors.right: parent?.right anchors.right: parent?.right

View file

@ -13,7 +13,7 @@ Item {
required property DesktopEntry modelData required property DesktopEntry modelData
required property DrawerVisibilities visibilities required property DrawerVisibilities visibilities
implicitHeight: Config.launcher.sizes.itemHeight implicitHeight: Tokens.sizes.launcher.itemHeight
anchors.left: parent?.left anchors.left: parent?.left
anchors.right: parent?.right anchors.right: parent?.right

View file

@ -22,7 +22,7 @@ Item {
Qalculator.evalAsync(math); Qalculator.evalAsync(math);
} }
implicitHeight: Config.launcher.sizes.itemHeight implicitHeight: Tokens.sizes.launcher.itemHeight
anchors.left: parent?.left anchors.left: parent?.left
anchors.right: parent?.right anchors.right: parent?.right

View file

@ -10,7 +10,7 @@ Item {
required property Schemes.Scheme modelData required property Schemes.Scheme modelData
required property var list required property var list
implicitHeight: Config.launcher.sizes.itemHeight implicitHeight: Tokens.sizes.launcher.itemHeight
anchors.left: parent?.left anchors.left: parent?.left
anchors.right: parent?.right anchors.right: parent?.right

View file

@ -10,7 +10,7 @@ Item {
required property M3Variants.Variant modelData required property M3Variants.Variant modelData
required property var list required property var list
implicitHeight: Config.launcher.sizes.itemHeight implicitHeight: Tokens.sizes.launcher.itemHeight
anchors.left: parent?.left anchors.left: parent?.left
anchors.right: parent?.right anchors.right: parent?.right

View file

@ -52,7 +52,7 @@ Item {
color: Colours.tPalette.m3surfaceContainer color: Colours.tPalette.m3surfaceContainer
radius: Tokens.rounding.normal radius: Tokens.rounding.normal
implicitWidth: Config.launcher.sizes.wallpaperWidth implicitWidth: Tokens.sizes.launcher.wallpaperWidth
implicitHeight: implicitWidth / 16 * 9 implicitHeight: implicitWidth / 16 * 9
MaterialIcon { MaterialIcon {

View file

@ -14,7 +14,7 @@ ColumnLayout {
required property var lock required property var lock
readonly property real centerScale: Math.min(1, (lock.screen?.height ?? 1440) / 1440) readonly property real centerScale: Math.min(1, (lock.screen?.height ?? 1440) / 1440)
readonly property int centerWidth: Config.lock.sizes.centerWidth * centerScale readonly property int centerWidth: Tokens.sizes.lock.centerWidth * centerScale
Layout.preferredWidth: centerWidth Layout.preferredWidth: centerWidth
Layout.fillWidth: false Layout.fillWidth: false

View file

@ -144,14 +144,14 @@ WlSessionLockSurface {
Anim { Anim {
target: lockContent target: lockContent
property: "implicitWidth" property: "implicitWidth"
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio to: (root.screen?.height ?? 0) * Tokens.sizes.lock.heightMult * Tokens.sizes.lock.ratio
duration: Tokens.anim.durations.expressiveDefaultSpatial duration: Tokens.anim.durations.expressiveDefaultSpatial
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
} }
Anim { Anim {
target: lockContent target: lockContent
property: "implicitHeight" property: "implicitHeight"
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult to: (root.screen?.height ?? 0) * Tokens.sizes.lock.heightMult
duration: Tokens.anim.durations.expressiveDefaultSpatial duration: Tokens.anim.durations.expressiveDefaultSpatial
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
} }
@ -219,8 +219,8 @@ WlSessionLockSurface {
id: content id: content
anchors.centerIn: parent anchors.centerIn: parent
width: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio - Tokens.padding.large * 2 width: (root.screen?.height ?? 0) * Tokens.sizes.lock.heightMult * Tokens.sizes.lock.ratio - Tokens.padding.large * 2
height: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult - Tokens.padding.large * 2 height: (root.screen?.height ?? 0) * Tokens.sizes.lock.heightMult - Tokens.padding.large * 2
lock: root lock: root
opacity: 0 opacity: 0

View file

@ -64,8 +64,8 @@ StyledRect {
Item { Item {
Layout.alignment: Qt.AlignLeft | Qt.AlignTop Layout.alignment: Qt.AlignLeft | Qt.AlignTop
implicitWidth: Config.notifs.sizes.image implicitWidth: Tokens.sizes.notifs.image
implicitHeight: Config.notifs.sizes.image implicitHeight: Tokens.sizes.notifs.image
Component { Component {
id: imageComp id: imageComp
@ -73,12 +73,12 @@ StyledRect {
Image { Image {
source: Qt.resolvedUrl(root.image) source: Qt.resolvedUrl(root.image)
fillMode: Image.PreserveAspectCrop fillMode: Image.PreserveAspectCrop
sourceSize.width: Config.notifs.sizes.image sourceSize.width: Tokens.sizes.notifs.image
sourceSize.height: Config.notifs.sizes.image sourceSize.height: Tokens.sizes.notifs.image
cache: false cache: false
asynchronous: true asynchronous: true
width: Config.notifs.sizes.image width: Tokens.sizes.notifs.image
height: Config.notifs.sizes.image height: Tokens.sizes.notifs.image
} }
} }
@ -86,7 +86,7 @@ StyledRect {
id: appIconComp id: appIconComp
ColouredIcon { ColouredIcon {
implicitSize: Math.round(Config.notifs.sizes.image * 0.6) implicitSize: Math.round(Tokens.sizes.notifs.image * 0.6)
source: Quickshell.iconPath(root.appIcon) source: Quickshell.iconPath(root.appIcon)
colour: root.urgency === "critical" ? Colours.palette.m3onError : root.urgency === "low" ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer colour: root.urgency === "critical" ? Colours.palette.m3onError : root.urgency === "low" ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer
layer.enabled: root.appIcon.endsWith("symbolic") layer.enabled: root.appIcon.endsWith("symbolic")
@ -122,15 +122,15 @@ StyledRect {
active: root.appIcon && root.image active: root.appIcon && root.image
sourceComponent: StyledRect { sourceComponent: StyledRect {
implicitWidth: Config.notifs.sizes.badge implicitWidth: Tokens.sizes.notifs.badge
implicitHeight: Config.notifs.sizes.badge implicitHeight: Tokens.sizes.notifs.badge
color: root.urgency === "critical" ? Colours.palette.m3error : root.urgency === "low" ? Colours.palette.m3surfaceContainerHighest : Colours.palette.m3secondaryContainer color: root.urgency === "critical" ? Colours.palette.m3error : root.urgency === "low" ? Colours.palette.m3surfaceContainerHighest : Colours.palette.m3secondaryContainer
radius: Tokens.rounding.full radius: Tokens.rounding.full
ColouredIcon { ColouredIcon {
anchors.centerIn: parent anchors.centerIn: parent
implicitSize: Math.round(Config.notifs.sizes.badge * 0.6) implicitSize: Math.round(Tokens.sizes.notifs.badge * 0.6)
source: Quickshell.iconPath(root.appIcon) source: Quickshell.iconPath(root.appIcon)
colour: root.urgency === "critical" ? Colours.palette.m3onError : root.urgency === "low" ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer colour: root.urgency === "critical" ? Colours.palette.m3onError : root.urgency === "low" ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer
layer.enabled: root.appIcon.endsWith("symbolic") layer.enabled: root.appIcon.endsWith("symbolic")

View file

@ -19,7 +19,7 @@ Item {
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.right: parent.right anchors.right: parent.right
implicitWidth: Config.notifs.sizes.width + padding * 2 implicitWidth: Tokens.sizes.notifs.width + padding * 2
implicitHeight: { implicitHeight: {
const count = list.count; const count = list.count;
if (count === 0) if (count === 0)
@ -170,7 +170,7 @@ Item {
Anim { Anim {
target: notif target: notif
property: "x" property: "x"
to: (notif.x >= 0 ? Config.notifs.sizes.width : -Config.notifs.sizes.width) * 2 to: (notif.x >= 0 ? Tokens.sizes.notifs.width : -Tokens.sizes.notifs.width) * 2
duration: Tokens.anim.durations.normal duration: Tokens.anim.durations.normal
easing.bezierCurve: Tokens.anim.curves.emphasized easing.bezierCurve: Tokens.anim.curves.emphasized
} }

View file

@ -24,10 +24,10 @@ StyledRect {
color: root.modelData.urgency === NotificationUrgency.Critical ? Colours.palette.m3secondaryContainer : Colours.tPalette.m3surfaceContainer color: root.modelData.urgency === NotificationUrgency.Critical ? Colours.palette.m3secondaryContainer : Colours.tPalette.m3surfaceContainer
radius: Tokens.rounding.normal radius: Tokens.rounding.normal
implicitWidth: Config.notifs.sizes.width implicitWidth: Tokens.sizes.notifs.width
implicitHeight: inner.implicitHeight implicitHeight: inner.implicitHeight
x: Config.notifs.sizes.width x: Tokens.sizes.notifs.width
Component.onCompleted: { Component.onCompleted: {
x = 0; x = 0;
modelData.lock(this); modelData.lock(this);
@ -68,7 +68,7 @@ StyledRect {
if (!containsMouse) if (!containsMouse)
root.modelData.timer.start(); root.modelData.timer.start();
if (Math.abs(root.x) < Config.notifs.sizes.width * Config.notifs.clearThreshold) if (Math.abs(root.x) < Tokens.sizes.notifs.width * Config.notifs.clearThreshold)
root.x = 0; root.x = 0;
else else
root.modelData.popup = false; root.modelData.popup = false;
@ -114,21 +114,21 @@ StyledRect {
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top
width: Config.notifs.sizes.image width: Tokens.sizes.notifs.image
height: Config.notifs.sizes.image height: Tokens.sizes.notifs.image
visible: root.hasImage || root.hasAppIcon visible: root.hasImage || root.hasAppIcon
sourceComponent: ClippingRectangle { sourceComponent: ClippingRectangle {
radius: Tokens.rounding.full radius: Tokens.rounding.full
implicitWidth: Config.notifs.sizes.image implicitWidth: Tokens.sizes.notifs.image
implicitHeight: Config.notifs.sizes.image implicitHeight: Tokens.sizes.notifs.image
Image { Image {
anchors.fill: parent anchors.fill: parent
source: Qt.resolvedUrl(root.modelData.image) source: Qt.resolvedUrl(root.modelData.image)
fillMode: Image.PreserveAspectCrop fillMode: Image.PreserveAspectCrop
sourceSize.width: Config.notifs.sizes.image sourceSize.width: Tokens.sizes.notifs.image
sourceSize.height: Config.notifs.sizes.image sourceSize.height: Tokens.sizes.notifs.image
cache: false cache: false
asynchronous: true asynchronous: true
} }
@ -149,8 +149,8 @@ StyledRect {
sourceComponent: StyledRect { sourceComponent: StyledRect {
radius: Tokens.rounding.full radius: Tokens.rounding.full
color: root.modelData.urgency === NotificationUrgency.Critical ? Colours.palette.m3error : root.modelData.urgency === NotificationUrgency.Low ? Colours.layer(Colours.palette.m3surfaceContainerHighest, 2) : Colours.palette.m3secondaryContainer color: root.modelData.urgency === NotificationUrgency.Critical ? Colours.palette.m3error : root.modelData.urgency === NotificationUrgency.Low ? Colours.layer(Colours.palette.m3surfaceContainerHighest, 2) : Colours.palette.m3secondaryContainer
implicitWidth: root.hasImage ? Config.notifs.sizes.badge : Config.notifs.sizes.image implicitWidth: root.hasImage ? Tokens.sizes.notifs.badge : Tokens.sizes.notifs.image
implicitHeight: root.hasImage ? Config.notifs.sizes.badge : Config.notifs.sizes.image implicitHeight: root.hasImage ? Tokens.sizes.notifs.badge : Tokens.sizes.notifs.image
Loader { Loader {
id: icon id: icon

View file

@ -38,8 +38,8 @@ Item {
Audio.decrementVolume(); Audio.decrementVolume();
} }
implicitWidth: Config.osd.sizes.sliderWidth implicitWidth: Tokens.sizes.osd.sliderWidth
implicitHeight: Config.osd.sizes.sliderHeight implicitHeight: Tokens.sizes.osd.sliderHeight
FilledSlider { FilledSlider {
anchors.fill: parent anchors.fill: parent
@ -63,8 +63,8 @@ Item {
Audio.decrementSourceVolume(); Audio.decrementSourceVolume();
} }
implicitWidth: Config.osd.sizes.sliderWidth implicitWidth: Tokens.sizes.osd.sliderWidth
implicitHeight: Config.osd.sizes.sliderHeight implicitHeight: Tokens.sizes.osd.sliderHeight
FilledSlider { FilledSlider {
anchors.fill: parent anchors.fill: parent
@ -92,8 +92,8 @@ Item {
monitor.setBrightness(monitor.brightness - Config.services.brightnessIncrement); monitor.setBrightness(monitor.brightness - Config.services.brightnessIncrement);
} }
implicitWidth: Config.osd.sizes.sliderWidth implicitWidth: Tokens.sizes.osd.sliderWidth
implicitHeight: Config.osd.sizes.sliderHeight implicitHeight: Tokens.sizes.osd.sliderHeight
FilledSlider { FilledSlider {
anchors.fill: parent anchors.fill: parent
@ -110,7 +110,7 @@ Item {
required property bool shouldBeActive required property bool shouldBeActive
asynchronous: true asynchronous: true
Layout.preferredHeight: shouldBeActive ? Config.osd.sizes.sliderHeight : 0 Layout.preferredHeight: shouldBeActive ? Tokens.sizes.osd.sliderHeight : 0
opacity: shouldBeActive ? 1 : 0 opacity: shouldBeActive ? 1 : 0
active: opacity > 0 active: opacity > 0
visible: active visible: active

View file

@ -46,8 +46,8 @@ Column {
} }
AnimatedImage { AnimatedImage {
width: Config.session.sizes.button width: Tokens.sizes.session.button
height: Config.session.sizes.button height: Tokens.sizes.session.button
sourceSize.width: width sourceSize.width: width
sourceSize.height: height sourceSize.height: height
@ -82,8 +82,8 @@ Column {
required property string icon required property string icon
required property list<string> command required property list<string> command
implicitWidth: Config.session.sizes.button implicitWidth: Tokens.sizes.session.button
implicitHeight: Config.session.sizes.button implicitHeight: Tokens.sizes.session.button
radius: Tokens.rounding.large radius: Tokens.rounding.large
color: button.activeFocus ? Colours.palette.m3secondaryContainer : Colours.tPalette.m3surfaceContainer color: button.activeFocus ? Colours.palette.m3secondaryContainer : Colours.tPalette.m3surfaceContainer

View file

@ -53,7 +53,7 @@ StyledRect {
readonly property int nonAnimHeight: { readonly property int nonAnimHeight: {
const headerHeight = header.implicitHeight + (root.expanded ? Math.round(Tokens.spacing.small / 2) : 0); const headerHeight = header.implicitHeight + (root.expanded ? Math.round(Tokens.spacing.small / 2) : 0);
const columnHeight = headerHeight + notifList.layoutHeight + column.Layout.topMargin + column.Layout.bottomMargin; const columnHeight = headerHeight + notifList.layoutHeight + column.Layout.topMargin + column.Layout.bottomMargin;
return Math.round(Math.max(Config.notifs.sizes.image, columnHeight) + Tokens.padding.normal * 2); return Math.round(Math.max(Tokens.sizes.notifs.image, columnHeight) + Tokens.padding.normal * 2);
} }
readonly property bool expanded: props.expandedNotifs.includes(modelData) readonly property bool expanded: props.expandedNotifs.includes(modelData)
@ -91,8 +91,8 @@ StyledRect {
Item { Item {
Layout.alignment: Qt.AlignLeft | Qt.AlignTop Layout.alignment: Qt.AlignLeft | Qt.AlignTop
implicitWidth: Config.notifs.sizes.image implicitWidth: Tokens.sizes.notifs.image
implicitHeight: Config.notifs.sizes.image implicitHeight: Tokens.sizes.notifs.image
Component { Component {
id: imageComp id: imageComp
@ -100,12 +100,12 @@ StyledRect {
Image { Image {
source: Qt.resolvedUrl(root.image) source: Qt.resolvedUrl(root.image)
fillMode: Image.PreserveAspectCrop fillMode: Image.PreserveAspectCrop
sourceSize.width: Config.notifs.sizes.image sourceSize.width: Tokens.sizes.notifs.image
sourceSize.height: Config.notifs.sizes.image sourceSize.height: Tokens.sizes.notifs.image
cache: false cache: false
asynchronous: true asynchronous: true
width: Config.notifs.sizes.image width: Tokens.sizes.notifs.image
height: Config.notifs.sizes.image height: Tokens.sizes.notifs.image
} }
} }
@ -113,7 +113,7 @@ StyledRect {
id: appIconComp id: appIconComp
ColouredIcon { ColouredIcon {
implicitSize: Math.round(Config.notifs.sizes.image * 0.6) implicitSize: Math.round(Tokens.sizes.notifs.image * 0.6)
source: Quickshell.iconPath(root.appIcon) source: Quickshell.iconPath(root.appIcon)
colour: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3onError : root.urgency === NotificationUrgency.Low ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer colour: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3onError : root.urgency === NotificationUrgency.Low ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer
layer.enabled: root.appIcon.endsWith("symbolic") layer.enabled: root.appIcon.endsWith("symbolic")
@ -149,15 +149,15 @@ StyledRect {
active: root.appIcon && root.image active: root.appIcon && root.image
sourceComponent: StyledRect { sourceComponent: StyledRect {
implicitWidth: Config.notifs.sizes.badge implicitWidth: Tokens.sizes.notifs.badge
implicitHeight: Config.notifs.sizes.badge implicitHeight: Tokens.sizes.notifs.badge
color: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3error : root.urgency === NotificationUrgency.Low ? Colours.palette.m3surfaceContainerHigh : Colours.palette.m3secondaryContainer color: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3error : root.urgency === NotificationUrgency.Low ? Colours.palette.m3surfaceContainerHigh : Colours.palette.m3secondaryContainer
radius: Tokens.rounding.full radius: Tokens.rounding.full
ColouredIcon { ColouredIcon {
anchors.centerIn: parent anchors.centerIn: parent
implicitSize: Math.round(Config.notifs.sizes.badge * 0.6) implicitSize: Math.round(Tokens.sizes.notifs.badge * 0.6)
source: Quickshell.iconPath(root.appIcon) source: Quickshell.iconPath(root.appIcon)
colour: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3onError : root.urgency === NotificationUrgency.Low ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer colour: root.urgency === NotificationUrgency.Critical ? Colours.palette.m3onError : root.urgency === NotificationUrgency.Low ? Colours.palette.m3onSurface : Colours.palette.m3onSecondaryContainer
layer.enabled: root.appIcon.endsWith("symbolic") layer.enabled: root.appIcon.endsWith("symbolic")

View file

@ -15,7 +15,7 @@ Item {
visible: offsetScale < 1 visible: offsetScale < 1
anchors.rightMargin: (-implicitWidth - 5) * offsetScale anchors.rightMargin: (-implicitWidth - 5) * offsetScale
implicitWidth: Config.sidebar.sizes.width implicitWidth: Tokens.sizes.sidebar.width
opacity: 1 - offsetScale opacity: 1 - offsetScale
Behavior on offsetScale { Behavior on offsetScale {
@ -37,7 +37,7 @@ Item {
active: root.shouldBeActive || root.visible active: root.shouldBeActive || root.visible
sourceComponent: Content { sourceComponent: Content {
implicitWidth: Config.sidebar.sizes.width - Tokens.padding.large * 2 implicitWidth: Tokens.sizes.sidebar.width - Tokens.padding.large * 2
props: root.props props: root.props
visibilities: root.visibilities visibilities: root.visibilities
} }

View file

@ -29,7 +29,7 @@ Item {
visible: offsetScale < 1 visible: offsetScale < 1
anchors.bottomMargin: (-implicitHeight - 5) * offsetScale anchors.bottomMargin: (-implicitHeight - 5) * offsetScale
implicitHeight: content.implicitHeight + content.anchors.margins * 2 implicitHeight: content.implicitHeight + content.anchors.margins * 2
implicitWidth: sidebar.width * (1 - sidebar.offsetScale) * horizontalStretch * sidebarLerp + Config.utilities.sizes.width * (1 - sidebarLerp) implicitWidth: sidebar.width * (1 - sidebar.offsetScale) * horizontalStretch * sidebarLerp + Tokens.sizes.utilities.width * (1 - sidebarLerp)
opacity: 1 - offsetScale opacity: 1 - offsetScale
states: State { states: State {

View file

@ -23,7 +23,7 @@ Item {
return false; return false;
} }
implicitWidth: Config.utilities.sizes.toastWidth - Tokens.padding.normal * 2 implicitWidth: Tokens.sizes.utilities.toastWidth - Tokens.padding.normal * 2
implicitHeight: { implicitHeight: {
let h = -spacing; let h = -spacing;
for (let i = 0; i < repeater.count; i++) { for (let i = 0; i < repeater.count; i++) {

View file

@ -13,7 +13,7 @@ Item {
required property HyprlandToplevel client required property HyprlandToplevel client
implicitWidth: child.implicitWidth implicitWidth: child.implicitWidth
implicitHeight: screen.height * Config.winfo.sizes.heightMult implicitHeight: screen.height * Tokens.sizes.winfo.heightMult
RowLayout { RowLayout {
id: child id: child
@ -31,7 +31,7 @@ Item {
ColumnLayout { ColumnLayout {
spacing: Tokens.spacing.normal spacing: Tokens.spacing.normal
Layout.preferredWidth: Config.winfo.sizes.detailsWidth Layout.preferredWidth: Tokens.sizes.winfo.detailsWidth
Layout.fillHeight: true Layout.fillHeight: true
StyledRect { StyledRect {

View file

@ -54,14 +54,14 @@ QtObject {
// qmllint disable uncreatable-type // qmllint disable uncreatable-type
PanelWindow { PanelWindow {
// qmllint enable uncreatable-type // qmllint enable uncreatable-type
implicitWidth: Config.notifs.sizes.image implicitWidth: Tokens.sizes.notifs.image
implicitHeight: Config.notifs.sizes.image implicitHeight: Tokens.sizes.notifs.image
color: "transparent" color: "transparent"
mask: Region {} mask: Region {}
Image { Image {
function tryCache(): void { function tryCache(): void {
if (status !== Image.Ready || width != Config.notifs.sizes.image || height != Config.notifs.sizes.image) if (status !== Image.Ready || width != Tokens.sizes.notifs.image || height != Tokens.sizes.notifs.image)
return; return;
const cacheKey = notif.appName + notif.summary + notif.id; const cacheKey = notif.appName + notif.summary + notif.id;