gui/tray: Do not add custom styling to status message text field in user status

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2025-02-27 17:22:31 +08:00 committed by backportbot[bot]
parent 6719461318
commit 284a403037

View File

@ -145,33 +145,11 @@ ColumnLayout {
property color borderColor: showBorder ? Style.ncBlue : palette.dark
// We create the square with only the top-left and bottom-left rounded corners
// by overlaying different rectangles on top of each other
background: Rectangle {
radius: Style.slightlyRoundedButtonRadius
color: palette.button
border.color: fieldButton.borderColor
border.width: Style.normalBorderWidth
Rectangle {
anchors.fill: parent
anchors.leftMargin: parent.width / 2
anchors.rightMargin: -1
z: 1
color: palette.button
border.color: fieldButton.borderColor
border.width: Style.normalBorderWidth
}
Rectangle { // We need to cover the blue border of the non-radiused rectangle
anchors.fill: parent
anchors.leftMargin: parent.width / 4
anchors.rightMargin: parent.width / 4
anchors.topMargin: Style.normalBorderWidth
anchors.bottomMargin: Style.normalBorderWidth
z: 2
color: palette.button
}
}
contentItem: Label {
@ -212,43 +190,11 @@ ColumnLayout {
TextField {
id: userStatusMessageTextField
property color borderColor: activeFocus ? Style.ncBlue : palette.dark
Layout.fillWidth: true
Layout.preferredHeight: contentHeight + (Style.smallSpacing * 2)
placeholderText: qsTr("What is your status?")
placeholderTextColor: palette.dark
text: userStatusSelectorModel.userStatusMessage
verticalAlignment: TextInput.AlignVCenter
selectByMouse: true
onEditingFinished: userStatusSelectorModel.userStatusMessage = text
background: Rectangle {
radius: Style.slightlyRoundedButtonRadius
color: palette.base
border.color: userStatusMessageTextField.borderColor
border.width: Style.normalBorderWidth
Rectangle {
anchors.fill: parent
anchors.rightMargin: parent.width / 2
z: 1
color: palette.base
border.color: userStatusMessageTextField.borderColor
border.width: Style.normalBorderWidth
}
Rectangle { // We need to cover the blue border of the non-radiused rectangle
anchors.fill: parent
anchors.leftMargin: parent.width / 4
anchors.rightMargin: parent.width / 4
anchors.topMargin: Style.normalBorderWidth
anchors.bottomMargin: Style.normalBorderWidth
z: 2
color: palette.base
}
}
}
}