diff --git a/.config/quickshell/ii/modules/common/NoticeBox.qml b/.config/quickshell/ii/modules/common/NoticeBox.qml new file mode 100644 index 000000000..6b110a9ae --- /dev/null +++ b/.config/quickshell/ii/modules/common/NoticeBox.qml @@ -0,0 +1,40 @@ +import qs.modules.common +import qs.modules.common.widgets +import QtQuick +import QtQuick.Layouts + +Rectangle { + id: root + property alias materialIcon: icon.text + property alias text: noticeText.text + + radius: Appearance.rounding.normal + color: Appearance.colors.colPrimaryContainer + implicitWidth: mainRowLayout.implicitWidth + mainRowLayout.anchors.margins * 2 + implicitHeight: mainRowLayout.implicitHeight + mainRowLayout.anchors.margins * 2 + + RowLayout { + id: mainRowLayout + anchors.fill: parent + anchors.margins: 8 + spacing: 8 + + MaterialSymbol { + id: icon + Layout.fillWidth: false + Layout.alignment: Qt.AlignTop + text: "info" + iconSize: Appearance.font.pixelSize.huge + color: Appearance.colors.colOnPrimaryContainer + } + + StyledText { + id: noticeText + Layout.fillWidth: true + Layout.alignment: Qt.AlignVCenter + text: "Notice message" + color: Appearance.colors.colOnPrimaryContainer + wrapMode: Text.WordWrap + } + } +} diff --git a/.config/quickshell/ii/modules/settings/InterfaceConfig.qml b/.config/quickshell/ii/modules/settings/InterfaceConfig.qml index 233d6dad9..65945cefc 100644 --- a/.config/quickshell/ii/modules/settings/InterfaceConfig.qml +++ b/.config/quickshell/ii/modules/settings/InterfaceConfig.qml @@ -600,39 +600,13 @@ ContentPage { } } - Rectangle { + NoticeBox { id: reloadNotice visible: false Layout.topMargin: 8 - radius: Appearance.rounding.normal - color: Appearance.colors.colPrimaryContainer Layout.fillWidth: true - implicitWidth: languageRowLayout.implicitWidth + languageRowLayout.anchors.margins * 2 - implicitHeight: languageRowLayout.implicitHeight + languageRowLayout.anchors.margins * 2 - RowLayout { - id: languageRowLayout - anchors.fill: parent - anchors.margins: 8 - spacing: 8 - - MaterialSymbol { - Layout.fillWidth: false - Layout.alignment: Qt.AlignVCenter - text: "info" - iconSize: Appearance.font.pixelSize.larger - color: Appearance.colors.colOnPrimaryContainer - } - - StyledText { - id: noticeText - Layout.fillWidth: true - Layout.alignment: Qt.AlignVCenter - text: Translation.tr("Language setting saved. Please restart Quickshell (Ctrl+Super+R) to apply the new language.") - color: Appearance.colors.colOnPrimaryContainer - wrapMode: Text.WordWrap - } - } + text: Translation.tr("Language setting saved. Please restart Quickshell (Ctrl+Super+R) to apply the new language.") } } } diff --git a/.config/quickshell/ii/welcome.qml b/.config/quickshell/ii/welcome.qml index b353b77cc..4d51e030a 100644 --- a/.config/quickshell/ii/welcome.qml +++ b/.config/quickshell/ii/welcome.qml @@ -267,11 +267,9 @@ ApplicationWindow { } } - StyledText { - Layout.alignment: Qt.AlignHCenter - text: Translation.tr("Change any time later with /dark, /light, /img in the launcher") - font.pixelSize: Appearance.font.pixelSize.smaller - color: Appearance.colors.colSubtext + NoticeBox { + Layout.fillWidth: true + text: Translation.tr("Change any time later with /dark, /light, /wallpaper in the launcher\nIf the shell's colors aren't changing:\n 1. Open the right sidebar with Super+N\n 2. Click \"Reload Hyprland & Quickshell\" in the top-right corner") } }