add styling with animation speed

This commit is contained in:
Benjamin Palko 2025-09-05 15:48:24 -04:00
parent f7e8fb7720
commit 9fc91a92f7
14 changed files with 74 additions and 37 deletions

View file

@ -28,26 +28,34 @@ RoundButton {
font: control.font
text: control.text
color: control.color
ColorAnimation on color {
duration: 100
Behavior on color {
ColorAnimation {
duration: Styling.animations.speed.normal
}
}
rotation: control.rotation
RotationAnimation on rotation {
duration: 200
easing.type: Easing.InOutCubic
Behavior on rotation {
RotationAnimation {
duration: Styling.animations.speed.slow
easing.type: Easing.InOutCubic
}
}
}
background: Rectangle {
id: rect
border.color: control.hovered ? Theme.palette.base300 : Theme.palette.base200
ColorAnimation on border.color {
duration: 100
Behavior on border.color {
ColorAnimation {
duration: Styling.animations.speed.normal
}
}
border.width: 0
color: control.hovered ? Theme.palette.primary : Theme.palette.base200
ColorAnimation on color {
duration: 100
Behavior on color {
ColorAnimation {
duration: Styling.animations.speed.normal
}
}
radius: control.radius
}