From 9114d5b2fe0534af353aa58fc444748ea46d02e1 Mon Sep 17 00:00:00 2001 From: end-4 <97237370+end-4@users.noreply.github.com> Date: Fri, 5 Sep 2025 23:34:40 +0200 Subject: [PATCH] NavigationTabArray: fix undefined warning --- .../ii/modules/common/widgets/NavigationRailTabArray.qml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.config/quickshell/ii/modules/common/widgets/NavigationRailTabArray.qml b/.config/quickshell/ii/modules/common/widgets/NavigationRailTabArray.qml index 6596141db..01d27ba73 100644 --- a/.config/quickshell/ii/modules/common/widgets/NavigationRailTabArray.qml +++ b/.config/quickshell/ii/modules/common/widgets/NavigationRailTabArray.qml @@ -11,9 +11,10 @@ Item { implicitHeight: tabBarColumn.implicitHeight implicitWidth: tabBarColumn.implicitWidth Layout.topMargin: 25 + Rectangle { - property real itemHeight: tabBarColumn.children[0].baseSize - property real baseHighlightHeight: tabBarColumn.children[0].baseHighlightHeight + property real itemHeight: tabBarColumn.children[0]?.baseSize ?? 56 + property real baseHighlightHeight: tabBarColumn.children[0]?.baseHighlightHeight ?? 56 anchors { top: tabBarColumn.top left: tabBarColumn.left @@ -22,7 +23,7 @@ Item { radius: Appearance.rounding.full color: Appearance.colors.colSecondaryContainer implicitHeight: root.expanded ? itemHeight : baseHighlightHeight - implicitWidth: tabBarColumn.children[root.currentIndex].visualWidth + implicitWidth: tabBarColumn?.children[root.currentIndex]?.visualWidth ?? 100 Behavior on anchors.topMargin { NumberAnimation { @@ -32,10 +33,10 @@ Item { } } } + ColumnLayout { id: tabBarColumn anchors.fill: parent spacing: 0 - } }