forked from Shinonome/dots-hyprland
background: fix clock position
This commit is contained in:
@@ -69,7 +69,7 @@ Variants {
|
|||||||
property bool shouldBlur: (GlobalStates.screenLocked && Config.options.background.lockBlur.enable)
|
property bool shouldBlur: (GlobalStates.screenLocked && Config.options.background.lockBlur.enable)
|
||||||
property color dominantColor: Appearance.colors.colPrimary
|
property color dominantColor: Appearance.colors.colPrimary
|
||||||
property bool dominantColorIsDark: dominantColor.hslLightness < 0.5
|
property bool dominantColorIsDark: dominantColor.hslLightness < 0.5
|
||||||
property color colText: (GlobalStates.screenLocked && shouldBlur) ? Appearance.colors.colSecondary : CF.ColorUtils.colorWithLightness(Appearance.colors.colPrimary, (dominantColorIsDark ? 0.8 : 0.12))
|
property color colText: (GlobalStates.screenLocked && shouldBlur) ? Appearance.colors.colOnLayer0 : CF.ColorUtils.colorWithLightness(Appearance.colors.colPrimary, (dominantColorIsDark ? 0.8 : 0.12))
|
||||||
Behavior on colText {
|
Behavior on colText {
|
||||||
animation: Appearance.animation.elementMoveFast.colorAnimation.createObject(this)
|
animation: Appearance.animation.elementMoveFast.colorAnimation.createObject(this)
|
||||||
}
|
}
|
||||||
@@ -262,6 +262,7 @@ Variants {
|
|||||||
left: wallpaper.left
|
left: wallpaper.left
|
||||||
top: wallpaper.top
|
top: wallpaper.top
|
||||||
horizontalCenter: undefined
|
horizontalCenter: undefined
|
||||||
|
verticalCenter: undefined
|
||||||
leftMargin: bgRoot.movableXSpace + ((root.fixedClockPosition ? root.fixedClockX : bgRoot.clockX * bgRoot.effectiveWallpaperScale) - implicitWidth / 2)
|
leftMargin: bgRoot.movableXSpace + ((root.fixedClockPosition ? root.fixedClockX : bgRoot.clockX * bgRoot.effectiveWallpaperScale) - implicitWidth / 2)
|
||||||
topMargin: {
|
topMargin: {
|
||||||
if (bgRoot.shouldBlur)
|
if (bgRoot.shouldBlur)
|
||||||
@@ -282,8 +283,9 @@ Variants {
|
|||||||
target: clockLoader
|
target: clockLoader
|
||||||
anchors {
|
anchors {
|
||||||
left: undefined
|
left: undefined
|
||||||
horizontalCenter: wallpaper.horizontalCenter
|
|
||||||
right: undefined
|
right: undefined
|
||||||
|
top: parent.top
|
||||||
|
horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user