diff --git a/storybook/pages/StatusGroupBoxPage.qml b/storybook/pages/StatusGroupBoxPage.qml index 96c4a5d2d3..1cd7220061 100644 --- a/storybook/pages/StatusGroupBoxPage.qml +++ b/storybook/pages/StatusGroupBoxPage.qml @@ -44,6 +44,8 @@ SplitView { icon: Style.png("tokens/SNT") iconSize: iconSizeSlider.value + label.enabled: labelEnabledCheckBox.checked + width: undefinedSizeCheckBox.checked ? undefined : widthSlider.value height: undefinedSizeCheckBox.checked ? undefined @@ -110,10 +112,19 @@ SplitView { text: "iconSize:" } - TextField { - id: titleTextEdit + RowLayout { + TextField { + id: titleTextEdit - text: "Some title goes here" + text: "Some title goes here" + } + + CheckBox { + id: labelEnabledCheckBox + + checked: true + text: "label enabled" + } } } } diff --git a/ui/StatusQ/src/StatusQ/Components/StatusGroupBox.qml b/ui/StatusQ/src/StatusQ/Components/StatusGroupBox.qml index 04b27861ef..8a902c8b99 100644 --- a/ui/StatusQ/src/StatusQ/Components/StatusGroupBox.qml +++ b/ui/StatusQ/src/StatusQ/Components/StatusGroupBox.qml @@ -41,15 +41,15 @@ GroupBox { contentItem: RowLayout { spacing: 8 - Image { + StatusIcon { sourceSize.width: width || undefined sourceSize.height: height || undefined - fillMode: Image.PreserveAspectFit mipmap: true antialiasing: true width: root.iconSize height: width source: root.icon + color: enabled ? "transparent" : Theme.palette.baseColor1 } StatusBaseText { @@ -57,7 +57,7 @@ GroupBox { Layout.fillWidth: true text: root.title - color: Theme.palette.directColor1 + color: enabled ? Theme.palette.directColor1 : Theme.palette.baseColor1 font.pixelSize: 17 elide: Text.ElideRight