fix: update delete modal

this fixes the text color in dark mode and the StyledButton is replaced with a StatusButton
For the StatusButton to support the color red, I added the color property that can be overridden
This commit is contained in:
hydr063n 2020-10-03 21:00:07 +02:00 committed by Iuri Matias
parent 2b7e66d4e5
commit 80cd040bcd
2 changed files with 7 additions and 7 deletions

View File

@ -2,6 +2,7 @@ import QtQuick 2.13
import QtQuick.Controls 2.13
import QtQuick.Layouts 1.13
import "../imports"
import "../shared/status"
import "./"
ModalPopup {
@ -26,6 +27,7 @@ ModalPopup {
Text {
text: confirmationDialog.confirmationText
color: Style.current.textColor
font.pixelSize: 15
anchors.left: parent.left
anchors.right: parent.right
@ -37,14 +39,11 @@ ModalPopup {
width: parent.width
height: children[0].height
StyledButton {
StatusButton {
anchors.right: parent.right
anchors.rightMargin: Style.current.smallPadding
btnColor: Style.current.lightRed
btnBorderWidth: 1
btnBorderColor: Style.current.grey
textColor: Style.current.red
label: confirmationDialog.confirmButtonLabel
color: Style.current.red
text: confirmationDialog.confirmButtonLabel
anchors.bottom: parent.bottom
onClicked: confirmationDialog.confirmButtonClicked()
}

View File

@ -8,6 +8,7 @@ Button {
property string type: "primary"
property string size: "large"
property string state: "default"
property string color: Style.current.buttonForegroundColor
id: control
font.pixelSize: size === "small" ? 13 : 15
@ -25,7 +26,7 @@ Button {
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
anchors.fill: parent
color: !enabled ? Style.current.buttonDisabledForegroundColor : Style.current.buttonForegroundColor
color: !enabled ? Style.current.buttonDisabledForegroundColor : control.color
visible: !loadingIndicator.active
}