qml: create wallet details drawer
This commit is contained in:
@@ -4,9 +4,10 @@ import QtQuick.Controls 2.3
|
||||
import QtQuick.Controls.Material 2.0
|
||||
|
||||
Rectangle {
|
||||
radius: constants.paddingXSmall
|
||||
width: layout.width
|
||||
height: layout.height
|
||||
id: root
|
||||
radius: height/2
|
||||
implicitWidth: layout.implicitWidth
|
||||
implicitHeight: layout.implicitHeight
|
||||
color: 'transparent'
|
||||
border.color: Material.accentColor
|
||||
|
||||
@@ -14,8 +15,40 @@ Rectangle {
|
||||
property alias font: label.font
|
||||
property alias labelcolor: label.color
|
||||
|
||||
property string iconSource
|
||||
|
||||
RowLayout {
|
||||
id: layout
|
||||
spacing: 0
|
||||
|
||||
Item {
|
||||
// spacer
|
||||
visible: iconSource
|
||||
Layout.preferredWidth: constants.paddingSmall
|
||||
Layout.preferredHeight: 1
|
||||
}
|
||||
|
||||
Image {
|
||||
visible: iconSource
|
||||
Layout.preferredWidth: constants.iconSizeSmall
|
||||
Layout.preferredHeight: constants.iconSizeSmall
|
||||
source: iconSource
|
||||
}
|
||||
|
||||
Item {
|
||||
// spacer
|
||||
visible: iconSource
|
||||
Layout.preferredWidth: constants.paddingXXSmall
|
||||
Layout.preferredHeight: 1
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
visible: iconSource
|
||||
Layout.preferredHeight: root.height
|
||||
Layout.preferredWidth: 1
|
||||
color: root.color
|
||||
border.color: root.border.color
|
||||
}
|
||||
|
||||
Label {
|
||||
id: label
|
||||
@@ -24,6 +57,7 @@ Rectangle {
|
||||
Layout.topMargin: constants.paddingXXSmall
|
||||
Layout.bottomMargin: constants.paddingXXSmall
|
||||
font.pixelSize: constants.fontSizeXSmall
|
||||
color: root.border.color
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user