Compare commits
No commits in common. "9d6a88aa4376033788dee756730094e704928e53" and "f687e17c944b20bef1cbcb25b134568a2d5190fc" have entirely different histories.
9d6a88aa43
...
f687e17c94
3 changed files with 20 additions and 35 deletions
|
|
@ -1,23 +1,18 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls.Basic
|
||||||
|
|
||||||
TabBar {
|
TabBar {
|
||||||
id: control
|
id: control
|
||||||
|
|
||||||
property alias orientation: view.orientation
|
property alias orientation: view.orientation
|
||||||
|
|
||||||
contentItem: Item {
|
contentItem: ListView {
|
||||||
ListView {
|
id: view
|
||||||
id: view
|
model: control.contentModel
|
||||||
anchors.centerIn: parent
|
currentIndex: control.currentIndex
|
||||||
implicitWidth: parent.width - 20
|
spacing: control.spacing
|
||||||
implicitHeight: parent.height - 20
|
orientation: ListView.Horizontal
|
||||||
model: control.contentModel
|
boundsBehavior: Flickable.StopAtBounds
|
||||||
currentIndex: control.currentIndex
|
|
||||||
spacing: control.spacing
|
|
||||||
orientation: ListView.Horizontal
|
|
||||||
boundsBehavior: Flickable.StopAtBounds
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Item {}
|
background: Item {}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import qs.config
|
import qs.config
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls.Basic
|
||||||
|
|
||||||
TabButton {
|
TabButton {
|
||||||
id: control
|
id: control
|
||||||
|
|
@ -14,28 +14,31 @@ TabButton {
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
padding: 6
|
padding: 6
|
||||||
color: control.hovered ? Styling.theme.primarycontent : Styling.theme.basecontent
|
color: control.hovered ? Styling.theme.primarycontent : control.checked ? Styling.theme.accent : Styling.theme.basecontent
|
||||||
Behavior on color {
|
Behavior on color {
|
||||||
ColorAnimation {
|
ColorAnimation {
|
||||||
duration: Styling.animations.speed.normal
|
duration: Styling.animations.speed.normal
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
rotation: control.rotation
|
||||||
|
Behavior on rotation {
|
||||||
|
RotationAnimation {
|
||||||
|
duration: Styling.animations.speed.slow
|
||||||
|
easing.type: Easing.OutQuad
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
id: rectangle
|
id: rectangle
|
||||||
color: control.hovered ? Styling.theme.primary : Styling.theme.base100
|
color: control.hovered ? Styling.theme.primary : Styling.theme.base200
|
||||||
Behavior on color {
|
Behavior on color {
|
||||||
ColorAnimation {
|
ColorAnimation {
|
||||||
duration: Styling.animations.speed.normal
|
duration: Styling.animations.speed.normal
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
opacity: control.checked || control.hovered ? 1.0 : 0.0
|
border.width: 2
|
||||||
Behavior on opacity {
|
border.color: control.checked ? Styling.theme.accent : "transparent"
|
||||||
NumberAnimation {
|
|
||||||
duration: Styling.animations.speed.normal
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,6 @@ import qs.components
|
||||||
import qs.services
|
import qs.services
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import Quickshell.Hyprland
|
|
||||||
import Quickshell.Wayland
|
|
||||||
|
|
||||||
StyledPanelWindow {
|
StyledPanelWindow {
|
||||||
id: window
|
id: window
|
||||||
|
|
@ -14,17 +12,6 @@ StyledPanelWindow {
|
||||||
implicitWidth: 800
|
implicitWidth: 800
|
||||||
implicitHeight: 400
|
implicitHeight: 400
|
||||||
|
|
||||||
WlrLayershell.layer: WlrLayer.Top
|
|
||||||
WlrLayershell.keyboardFocus: window.visible ? WlrKeyboardFocus.OnDemand : WlrKeyboardFocus.None
|
|
||||||
|
|
||||||
HyprlandFocusGrab {
|
|
||||||
active: Visibility.configuration
|
|
||||||
windows: [window]
|
|
||||||
onCleared: {
|
|
||||||
Visibility.configuration = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
StyledTabBar {
|
StyledTabBar {
|
||||||
id: tabs
|
id: tabs
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue