init: working version
This commit is contained in:
commit
7d8d7dacae
109 changed files with 15066 additions and 0 deletions
49
custom/ExtraIndicator.qml
Normal file
49
custom/ExtraIndicator.qml
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
import qs.services
|
||||
import qs.config
|
||||
import QtQuick
|
||||
|
||||
CustomRect {
|
||||
required property int extra
|
||||
|
||||
anchors.right: parent.right
|
||||
anchors.margins: 12
|
||||
|
||||
color: Config.colors.inactive
|
||||
radius: 12
|
||||
|
||||
implicitWidth: count.implicitWidth + 20
|
||||
implicitHeight: count.implicitHeight + 10
|
||||
|
||||
opacity: extra > 0 ? 1 : 0
|
||||
scale: extra > 0 ? 1 : 0.5
|
||||
|
||||
Elevation {
|
||||
anchors.fill: parent
|
||||
radius: parent.radius
|
||||
opacity: parent.opacity
|
||||
z: -1
|
||||
level: 2
|
||||
}
|
||||
|
||||
CustomText {
|
||||
id: count
|
||||
|
||||
anchors.centerIn: parent
|
||||
animate: false
|
||||
text: qsTr("+%1").arg(parent.extra)
|
||||
color: Config.colors.secondary
|
||||
}
|
||||
|
||||
Behavior on opacity {
|
||||
Anim {
|
||||
duration: Config.anim.durations.expressiveFastSpatial
|
||||
}
|
||||
}
|
||||
|
||||
Behavior on scale {
|
||||
Anim {
|
||||
duration: Config.anim.durations.expressiveFastSpatial
|
||||
easing.bezierCurve: Config.anim.curves.expressiveFastSpatial
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue