feat: async bar

This commit is contained in:
2 * r + 2 * t 2026-03-20 01:18:45 +11:00
parent 80b34c8c7c
commit 473e4456b0
13 changed files with 26 additions and 0 deletions

View file

@ -194,6 +194,7 @@ ColumnLayout {
return null;
}
asynchronous: true
Layout.alignment: Qt.AlignHCenter
// Cursed ahh thing to add padding to first and last enabled components

View file

@ -39,6 +39,7 @@ Item {
implicitHeight: icon.implicitHeight + current.implicitWidth + current.anchors.topMargin
Loader {
asynchronous: true
anchors.fill: parent
active: !Config.bar.activeWindow.showOnHover

View file

@ -23,6 +23,7 @@ StyledRect {
spacing: Appearance.spacing.small
Loader {
asynchronous: true
anchors.horizontalCenter: parent.horizontalCenter
active: Config.bar.clock.showIcon

View file

@ -21,6 +21,7 @@ Item {
}
Loader {
asynchronous: true
anchors.centerIn: parent
sourceComponent: SysInfo.isDefaultLogo ? caelestiaLogo : distroIcon
}

View file

@ -264,6 +264,7 @@ StyledRect {
component WrappedLoader: Loader {
required property string name
asynchronous: true
Layout.alignment: Qt.AlignHCenter
visible: active
}

View file

@ -82,6 +82,8 @@ StyledRect {
Loader {
id: expandIcon
asynchronous: true
anchors.horizontalCenter: parent.horizontalCenter
anchors.bottom: parent.bottom

View file

@ -164,6 +164,8 @@ Item {
Loader {
id: label
asynchronous: true
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
Layout.preferredHeight: Config.bar.sizes.innerWidth - Appearance.padding.small * 2
@ -192,6 +194,8 @@ Item {
Loader {
id: windows
asynchronous: true
Layout.alignment: Qt.AlignHCenter
Layout.fillHeight: true
Layout.preferredHeight: implicitHeight
@ -293,6 +297,7 @@ Item {
}
Loader {
asynchronous: true
active: Config.bar.workspaces.activeIndicator
anchors.fill: parent

View file

@ -55,6 +55,8 @@ ColumnLayout {
Loader {
id: windows
asynchronous: true
Layout.alignment: Qt.AlignHCenter
Layout.fillHeight: true
Layout.topMargin: -Config.bar.sizes.innerWidth / 10

View file

@ -45,6 +45,7 @@ StyledClippingRect {
}
Loader {
asynchronous: true
active: Config.bar.workspaces.occupiedBg
anchors.fill: parent
@ -77,6 +78,7 @@ StyledClippingRect {
}
Loader {
asynchronous: true
anchors.horizontalCenter: parent.horizontalCenter
active: Config.bar.workspaces.activeIndicator
@ -110,6 +112,8 @@ StyledClippingRect {
Loader {
id: specialWs
asynchronous: true
anchors.fill: parent
anchors.margins: Appearance.padding.small

View file

@ -31,6 +31,7 @@ Item {
IconImage {
id: icon
asynchronous: true
Layout.alignment: Qt.AlignVCenter
implicitSize: details.implicitHeight
source: Icons.getAppIcon(Hypr.activeToplevel?.lastIpcObject.class ?? "", "image-missing")

View file

@ -37,6 +37,7 @@ Column {
}
Loader {
asynchronous: true
anchors.horizontalCenter: parent.horizontalCenter
active: PowerProfiles.degradationReason !== PerformanceDegradationReason.None

View file

@ -142,6 +142,7 @@ ColumnLayout {
}
Loader {
asynchronous: true
active: device.modelData.bonded
sourceComponent: Item {
implicitWidth: connectBtn.implicitWidth

View file

@ -81,6 +81,7 @@ StackView {
Loader {
id: children
asynchronous: true
anchors.left: parent.left
anchors.right: parent.right
@ -114,11 +115,13 @@ StackView {
Loader {
id: icon
asynchronous: true
anchors.left: parent.left
active: item.modelData.icon !== ""
sourceComponent: IconImage {
asynchronous: true
implicitSize: label.implicitHeight
source: item.modelData.icon
@ -149,6 +152,7 @@ StackView {
Loader {
id: expand
asynchronous: true
anchors.verticalCenter: parent.verticalCenter
anchors.right: parent.right
@ -165,6 +169,7 @@ StackView {
}
Loader {
asynchronous: true
active: menu.isSubMenu
sourceComponent: Item {