mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-06-22 02:01:08 +07:00
minor ui fixes
This commit is contained in:
@@ -23,6 +23,9 @@ Item {
|
||||
image: backButtonImage
|
||||
imageColor: "#D7D8DB"
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
onClicked: {
|
||||
if (backButtonFunction && typeof backButtonFunction === "function") {
|
||||
backButtonFunction()
|
||||
|
||||
@@ -24,6 +24,8 @@ Item {
|
||||
property string rootButtonImage: "qrc:/images/controls/chevron-down.svg"
|
||||
property string rootButtonImageColor: "#D7D8DB"
|
||||
property string rootButtonBackgroundColor: "#1C1D21"
|
||||
property string rootButtonBackgroundHoveredColor: "#1C1D21"
|
||||
property string rootButtonBackgroundPressedColor: "#1C1D21"
|
||||
|
||||
property string rootButtonHoveredBorderColor: "#494B50"
|
||||
property string rootButtonDefaultBorderColor: "#2C2D30"
|
||||
@@ -71,6 +73,10 @@ Item {
|
||||
Behavior on border.color {
|
||||
PropertyAnimation { duration: 200 }
|
||||
}
|
||||
|
||||
Behavior on color {
|
||||
PropertyAnimation { duration: 200 }
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
@@ -112,6 +118,9 @@ Item {
|
||||
ImageButtonType {
|
||||
Layout.rightMargin: 16
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
hoverEnabled: false
|
||||
image: rootButtonImage
|
||||
imageColor: rootButtonImageColor
|
||||
@@ -126,12 +135,20 @@ Item {
|
||||
onEntered: {
|
||||
if (menu.visible === false) {
|
||||
rootButtonBackground.border.color = rootButtonHoveredBorderColor
|
||||
rootButtonBackground.color = rootButtonBackgroundHoveredColor
|
||||
}
|
||||
}
|
||||
|
||||
onExited: {
|
||||
if (menu.visible === false) {
|
||||
rootButtonBackground.border.color = rootButtonDefaultBorderColor
|
||||
rootButtonBackground.color = rootButtonBackgroundColor
|
||||
}
|
||||
}
|
||||
|
||||
onPressed: {
|
||||
if (menu.visible === false) {
|
||||
rootButtonBackground.color = pressed ? rootButtonBackgroundPressedColor : entered ? rootButtonHoveredBorderColor : rootButtonDefaultBorderColor
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,9 @@ Item {
|
||||
ImageButtonType {
|
||||
id: headerActionButton
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
image: root.actionButtonImage
|
||||
imageColor: "#D7D8DB"
|
||||
|
||||
|
||||
@@ -36,6 +36,9 @@ Item {
|
||||
ImageButtonType {
|
||||
id: headerActionButton
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
Layout.alignment: Qt.AlignRight
|
||||
|
||||
image: root.actionButtonImage
|
||||
|
||||
@@ -15,11 +15,8 @@ Button {
|
||||
property string imageColor: "#878B91"
|
||||
property string disableImageColor: "#2C2D30"
|
||||
|
||||
property int backGroudRadius: 12
|
||||
property int implicitSize: 40
|
||||
|
||||
implicitWidth: implicitSize
|
||||
implicitHeight: implicitSize
|
||||
property alias backgroundColor: background.color
|
||||
property alias backgroundRadius: background.radius
|
||||
|
||||
hoverEnabled: true
|
||||
|
||||
@@ -34,16 +31,16 @@ Button {
|
||||
id: background
|
||||
|
||||
anchors.fill: parent
|
||||
radius: backGroudRadius
|
||||
color: {
|
||||
if (root.enabled) {
|
||||
if(root.pressed) {
|
||||
if (root.pressed) {
|
||||
return pressedColor
|
||||
}
|
||||
return hovered ? hoveredColor : defaultColor
|
||||
}
|
||||
return defaultColor
|
||||
}
|
||||
radius: 12
|
||||
Behavior on color {
|
||||
PropertyAnimation { duration: 200 }
|
||||
}
|
||||
|
||||
@@ -119,6 +119,9 @@ Item {
|
||||
ImageButtonType {
|
||||
id: rightImage
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
hoverEnabled: false
|
||||
image: rightImageSource
|
||||
imageColor: rightImageColor
|
||||
|
||||
@@ -167,7 +167,7 @@ Item {
|
||||
}
|
||||
|
||||
onEntered: {
|
||||
backgroud.border.color = getBackgroundBorderColor(bgBorderHoveredColor)
|
||||
backgroud.border.color = getBackgroundBorderColor(bgBorderHoveredColor)
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -23,6 +23,9 @@ Popup {
|
||||
image: "qrc:/images/svg/close_black_24dp.svg"
|
||||
imageColor: "#D7D8DB"
|
||||
|
||||
implicitWidth: 40
|
||||
implicitHeight: 40
|
||||
|
||||
onClicked: {
|
||||
PageController.goToDrawerRootPage()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user