C++ / fmt (pull_request) Successful in 3s
JS/TS / fmt (pull_request) Successful in 14s
JS/TS / lint (pull_request) Successful in 19s
Python / lint (pull_request) Successful in 30s
Python / fmt (pull_request) Successful in 34s
Python / test (pull_request) Successful in 1m0s
Python / typecheck (pull_request) Failing after 1m18s
C++ / build (pull_request) Successful in 1m49s
Rust / fmt (pull_request) Successful in 33s
Rust / build (pull_request) Successful in 1m33s
Rust / clippy (pull_request) Successful in 1m17s
Python / buildcheck (pull_request) Successful in 2m40s
C++ / clang-tidy (pull_request) Successful in 3m25s
59 lines
1.5 KiB
QML
59 lines
1.5 KiB
QML
pragma ComponentBehavior: Bound
|
|
|
|
import QtQuick
|
|
import QtQuick.Layouts
|
|
import Quickshell.Services.SystemTray
|
|
import qs.Components
|
|
import qs.Config
|
|
import qs.Modules.SysTray.Widgets
|
|
import qs.Modules
|
|
|
|
CustomClippingRect {
|
|
id: root
|
|
|
|
required property bool horizontal
|
|
readonly property alias items: repeater
|
|
readonly property alias layout: sysGrid
|
|
required property GridLayout loader
|
|
readonly property int padding: Appearance.padding.small
|
|
required property Wrapper popouts
|
|
readonly property real shortSize: Config.bar.height
|
|
readonly property real size: horizontal ? sysGrid.implicitWidth + Appearance.padding.small : sysGrid.implicitHeight + Appearance.padding.small
|
|
|
|
bottomLeftRadius: horizontal ? Appearance.rounding.full : Appearance.rounding.smallest / 2
|
|
bottomRightRadius: Appearance.rounding.smallest / 2
|
|
color: DynamicColors.tPalette.m3surfaceContainer
|
|
implicitHeight: horizontal ? shortSize : size
|
|
implicitWidth: horizontal ? size : shortSize
|
|
radius: Appearance.rounding.full
|
|
topRightRadius: horizontal ? Appearance.rounding.smallest / 2 : Appearance.rounding.full
|
|
|
|
GridLayout {
|
|
id: sysGrid
|
|
|
|
anchors.centerIn: parent
|
|
columns: root.horizontal ? -1 : 1
|
|
rowSpacing: -2
|
|
|
|
Repeater {
|
|
id: repeater
|
|
|
|
model: SystemTray.items
|
|
|
|
TrayItem {
|
|
id: trayItem
|
|
|
|
required property int index
|
|
required property SystemTrayItem modelData
|
|
|
|
implicitHeight: 34
|
|
implicitWidth: 34
|
|
ind: index
|
|
item: modelData
|
|
loader: root.loader
|
|
popouts: root.popouts
|
|
}
|
|
}
|
|
}
|
|
}
|