diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2025-08-17 20:22:31 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2025-08-19 20:15:21 +0800 |
| commit | 1e35e91fce74a8dcfb68b6a65b31d8610b4dc8c1 (patch) | |
| tree | 78bae57268b133d568e6420a1bcce9d4bb99a60e /launcher/components/Spell.qml | |
| parent | 4259defbfdc524a97e45e7e49eaf6ab8984dd9e9 (diff) | |
style(Launcher): components to make it looks more dynamic
including contrasting coloring, scales
Diffstat (limited to 'launcher/components/Spell.qml')
| -rw-r--r-- | launcher/components/Spell.qml | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/launcher/components/Spell.qml b/launcher/components/Spell.qml index 6cd847c..52f32b1 100644 --- a/launcher/components/Spell.qml +++ b/launcher/components/Spell.qml @@ -145,8 +145,6 @@ IComponent { flow: GridView.FlowLeftToRight snapMode: GridView.NoSnap - // Compute a reasonable cell width based on font size, keeping - // roughly the same behavior as before. cellWidth: Math.floor(width / Math.max(1, Math.floor(width / Math.max(1, Math.round(Launcher.widgetFontSize * 6))))) cellHeight: Math.ceil(Launcher.widgetFontSize * 1.6) + Launcher.innerMargin * 2 @@ -156,6 +154,7 @@ IComponent { width: grid.cellWidth height: chipContent.implicitHeight + Launcher.innerMargin * 2 + scale: index === selectedIndex ? 1.03 : 0.97 IRect { anchors.fill: parent @@ -168,6 +167,7 @@ IComponent { text: modelData font.pixelSize: Launcher.widgetFontSize elide: Text.ElideRight + color: index === selectedIndex ? Colors.foreground1 : Colors.foreground2 } MouseArea { @@ -181,6 +181,10 @@ IComponent { } } } + + Behavior on scale { + ISpringAnimation {} + } } Component.onCompleted: { |
