mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-12 23:35:32 +00:00
ea0db55361
- Updated enumerators that were defining `tokens` instead of `assets`. - Updated property names and labels. - Updated signals and components names. - Updated storybook. Fixes #8816
48 lines
994 B
QML
48 lines
994 B
QML
import QtQuick 2.14
|
|
import QtQuick.Layouts 1.14
|
|
|
|
import StatusQ.Core 0.1
|
|
import StatusQ.Core.Theme 0.1
|
|
import StatusQ.Controls 0.1
|
|
|
|
import shared.controls 1.0
|
|
|
|
ColumnLayout {
|
|
id: root
|
|
|
|
property alias assetName: pickerButton.text
|
|
property url assetImage
|
|
property alias amountText: amountInput.text
|
|
property alias amount: amountInput.amount
|
|
readonly property bool amountValid: amountInput.valid && amountInput.text.length > 0
|
|
|
|
signal pickerClicked
|
|
|
|
function setAmount(amount) {
|
|
amountInput.setAmount(amount)
|
|
}
|
|
|
|
spacing: 0
|
|
|
|
StatusPickerButton {
|
|
id: pickerButton
|
|
|
|
Layout.fillWidth: true
|
|
Layout.preferredHeight: 36
|
|
|
|
bgColor: Theme.palette.baseColor5
|
|
contentColor: Theme.palette.directColor1
|
|
font.pixelSize: 13
|
|
asset.name: root.assetImage
|
|
|
|
onClicked: pickerClicked()
|
|
}
|
|
|
|
AmountInput {
|
|
id: amountInput
|
|
|
|
Layout.fillWidth: true
|
|
Layout.topMargin: 8
|
|
}
|
|
}
|