diff --git a/Modules/LockScreen/LockScreen.qml b/Modules/LockScreen/LockScreen.qml index 1b5e7dc..b980fa3 100644 --- a/Modules/LockScreen/LockScreen.qml +++ b/Modules/LockScreen/LockScreen.qml @@ -294,13 +294,14 @@ Loader { // Animated avatar with glow effect or audio visualizer Rectangle { - width: 120 * scaling - height: 120 * scaling + width: 108 * scaling + height: 108 * scaling radius: width * 0.5 color: Color.transparent border.color: Color.mPrimary border.width: Math.max(1, Style.borderL * scaling) anchors.horizontalCenter: parent.horizontalCenter + z: 10 // Circular audio visualizer when music is playing Loader { diff --git a/Widgets/NImageRounded.qml b/Widgets/NImageRounded.qml index bd6daf0..56f0692 100644 --- a/Widgets/NImageRounded.qml +++ b/Widgets/NImageRounded.qml @@ -20,6 +20,51 @@ Rectangle { radius: scaledRadius anchors.margins: Style.marginXXS * scaling + Rectangle { + color: Color.transparent + anchors.fill: parent + anchors.margins: borderWidth + + Image { + id: img + anchors.fill: parent + source: imagePath + visible: false + mipmap: true + smooth: true + asynchronous: true + fillMode: Image.PreserveAspectCrop + } + + MultiEffect { + anchors.fill: parent + source: img + maskEnabled: true + maskSource: mask + visible: imagePath !== "" + } + + Item { + id: mask + anchors.fill: parent + layer.enabled: true + visible: false + Rectangle { + anchors.fill: parent + radius: scaledRadius + } + } + + // Fallback icon + NIcon { + anchors.centerIn: parent + text: fallbackIcon + font.pointSize: Style.fontSizeXXL * scaling + visible: fallbackIcon !== undefined && fallbackIcon !== "" && (imagePath === undefined || imagePath === "") + z: 0 + } + } + // Border Rectangle { anchors.fill: parent @@ -29,43 +74,4 @@ Rectangle { border.width: parent.borderWidth z: 10 } - - Image { - id: img - anchors.fill: parent - source: imagePath - visible: false - mipmap: true - smooth: true - asynchronous: true - fillMode: Image.PreserveAspectCrop - } - - MultiEffect { - anchors.fill: parent - source: img - maskEnabled: true - maskSource: mask - visible: imagePath !== "" - } - - Item { - id: mask - anchors.fill: parent - layer.enabled: true - visible: false - Rectangle { - anchors.fill: parent - radius: scaledRadius - } - } - - // Fallback icon - NIcon { - anchors.centerIn: parent - text: fallbackIcon - font.pointSize: Style.fontSizeXXL * scaling - visible: fallbackIcon !== undefined && fallbackIcon !== "" && (imagePath === undefined || imagePath === "") - z: 0 - } }