dashboard: fix media cover art
This commit is contained in:
parent
55d5bc7f37
commit
a4bd60c907
1 changed files with 10 additions and 20 deletions
|
|
@ -1,8 +1,8 @@
|
|||
import "root:/widgets"
|
||||
import "root:/services"
|
||||
import "root:/config"
|
||||
import Quickshell.Widgets
|
||||
import QtQuick
|
||||
import QtQuick.Effects
|
||||
import QtQuick.Shapes
|
||||
|
||||
Item {
|
||||
|
|
@ -83,7 +83,7 @@ Item {
|
|||
}
|
||||
}
|
||||
|
||||
StyledRect {
|
||||
ClippingRectangle {
|
||||
id: cover
|
||||
|
||||
anchors.top: parent.top
|
||||
|
|
@ -108,29 +108,19 @@ Item {
|
|||
|
||||
anchors.fill: parent
|
||||
|
||||
visible: false
|
||||
source: Players.active?.trackArtUrl ?? ""
|
||||
asynchronous: true
|
||||
fillMode: Image.PreserveAspectCrop
|
||||
sourceSize.width: width
|
||||
sourceSize.height: height
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: mask
|
||||
|
||||
layer.enabled: true
|
||||
layer.smooth: true
|
||||
visible: false
|
||||
anchors.fill: image
|
||||
radius: parent.radius
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Appearance.anim.durations.normal
|
||||
easing.type: Easing.BezierSpline
|
||||
easing.bezierCurve: Appearance.anim.curves.standard
|
||||
}
|
||||
|
||||
MultiEffect {
|
||||
anchors.fill: image
|
||||
source: image
|
||||
maskEnabled: true
|
||||
maskSource: mask
|
||||
maskSpreadAtMin: 1
|
||||
maskThresholdMin: 0.5
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue