internal: better shadow
This commit is contained in:
parent
365b993221
commit
fe4e72eab3
6 changed files with 20 additions and 33 deletions
|
|
@ -9,7 +9,6 @@ import Quickshell.Widgets
|
||||||
import Quickshell.Services.Mpris
|
import Quickshell.Services.Mpris
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import QtQuick.Effects
|
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Shapes
|
import QtQuick.Shapes
|
||||||
|
|
||||||
|
|
@ -425,13 +424,11 @@ Item {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
RectangularShadow {
|
Elevation {
|
||||||
anchors.fill: playerSelectorBg
|
anchors.fill: playerSelectorBg
|
||||||
radius: playerSelectorBg.radius
|
radius: playerSelectorBg.radius
|
||||||
color: Qt.alpha(Colours.palette.m3shadow, 0.7)
|
|
||||||
opacity: playerSelector.expanded ? 1 : 0
|
opacity: playerSelector.expanded ? 1 : 0
|
||||||
blur: 5
|
level: 2
|
||||||
spread: 0
|
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {
|
Anim {
|
||||||
|
|
|
||||||
|
|
@ -304,10 +304,6 @@ Item {
|
||||||
font.pointSize: Appearance.font.size.large
|
font.pointSize: Appearance.font.size.large
|
||||||
fill: 1
|
fill: 1
|
||||||
}
|
}
|
||||||
|
|
||||||
Behavior on radius {
|
|
||||||
Anim {}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ import qs.config
|
||||||
import Quickshell.Bluetooth
|
import Quickshell.Bluetooth
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Effects
|
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: root
|
id: root
|
||||||
|
|
@ -154,14 +153,12 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
RectangularShadow {
|
Elevation {
|
||||||
anchors.fill: adapterListBg
|
anchors.fill: adapterListBg
|
||||||
radius: adapterListBg.radius
|
radius: adapterListBg.radius
|
||||||
color: Qt.alpha(Colours.palette.m3shadow, 0.7)
|
|
||||||
opacity: adapterPickerButton.expanded ? 1 : 0
|
opacity: adapterPickerButton.expanded ? 1 : 0
|
||||||
scale: adapterPickerButton.expanded ? 1 : 0.7
|
scale: adapterPickerButton.expanded ? 1 : 0.7
|
||||||
blur: 5
|
level: 2
|
||||||
spread: 0
|
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {}
|
Anim {}
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,6 @@ import qs.config
|
||||||
import Quickshell
|
import Quickshell
|
||||||
import Quickshell.Widgets
|
import Quickshell.Widgets
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Effects
|
|
||||||
|
|
||||||
StyledRect {
|
StyledRect {
|
||||||
id: root
|
id: root
|
||||||
|
|
@ -33,13 +32,11 @@ StyledRect {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
RectangularShadow {
|
Elevation {
|
||||||
opacity: root.PathView.isCurrentItem ? 0.7 : 0
|
|
||||||
anchors.fill: image
|
anchors.fill: image
|
||||||
radius: image.radius
|
radius: image.radius
|
||||||
color: Colours.palette.m3shadow
|
opacity: root.PathView.isCurrentItem ? 1 : 0
|
||||||
blur: 10
|
level: 4
|
||||||
spread: 3
|
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {}
|
Anim {}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
import qs.services
|
import qs.services
|
||||||
import qs.config
|
import qs.config
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Effects
|
|
||||||
|
|
||||||
StyledRect {
|
StyledRect {
|
||||||
required property int extra
|
required property int extra
|
||||||
|
|
@ -15,16 +14,17 @@ StyledRect {
|
||||||
implicitWidth: count.implicitWidth + Appearance.padding.normal * 2
|
implicitWidth: count.implicitWidth + Appearance.padding.normal * 2
|
||||||
implicitHeight: count.implicitHeight + Appearance.padding.small * 2
|
implicitHeight: count.implicitHeight + Appearance.padding.small * 2
|
||||||
|
|
||||||
layer.enabled: opacity > 0
|
|
||||||
layer.effect: MultiEffect {
|
|
||||||
shadowEnabled: true
|
|
||||||
blurMax: 10
|
|
||||||
shadowColor: Colours.palette.m3shadow
|
|
||||||
}
|
|
||||||
|
|
||||||
opacity: extra > 0 ? 1 : 0
|
opacity: extra > 0 ? 1 : 0
|
||||||
scale: extra > 0 ? 1 : 0.5
|
scale: extra > 0 ? 1 : 0.5
|
||||||
|
|
||||||
|
Elevation {
|
||||||
|
anchors.fill: parent
|
||||||
|
radius: parent.radius
|
||||||
|
opacity: parent.opacity
|
||||||
|
z: -1
|
||||||
|
level: 2
|
||||||
|
}
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
id: count
|
id: count
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ import qs.services
|
||||||
import qs.config
|
import qs.config
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import QtQuick.Effects
|
|
||||||
|
|
||||||
Slider {
|
Slider {
|
||||||
id: root
|
id: root
|
||||||
|
|
@ -38,12 +37,10 @@ Slider {
|
||||||
implicitWidth: root.width
|
implicitWidth: root.width
|
||||||
implicitHeight: root.width
|
implicitHeight: root.width
|
||||||
|
|
||||||
RectangularShadow {
|
Elevation {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: rect.radius
|
radius: rect.radius
|
||||||
color: Colours.palette.m3shadow
|
level: handleInteraction.containsMouse ? 2 : 1
|
||||||
blur: 5
|
|
||||||
spread: 0
|
|
||||||
}
|
}
|
||||||
|
|
||||||
StyledRect {
|
StyledRect {
|
||||||
|
|
@ -55,7 +52,10 @@ Slider {
|
||||||
radius: Appearance.rounding.full
|
radius: Appearance.rounding.full
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
|
id: handleInteraction
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
hoverEnabled: true
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
acceptedButtons: Qt.NoButton
|
acceptedButtons: Qt.NoButton
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue