-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introduce Send pages for singlesig, single input/output send #445
Merged
+836
−14
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
qml: Introduce Send pages for singlesig, sigle input/output send
commit 727aa52e0576810947e34e2e0dda6ab72c3e4570
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
// Copyright (c) 2025 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#include <qml/models/sendrecipient.h> | ||
#include <qobjectdefs.h> | ||
|
||
SendRecipient::SendRecipient(QObject* parent) | ||
: QObject(parent), m_address(""), m_label(""), m_amount(""), m_message("") | ||
{ | ||
} | ||
|
||
QString SendRecipient::address() const | ||
{ | ||
return m_address; | ||
} | ||
|
||
void SendRecipient::setAddress(const QString& address) | ||
{ | ||
if (m_address != address) { | ||
m_address = address; | ||
Q_EMIT addressChanged(); | ||
} | ||
} | ||
|
||
QString SendRecipient::label() const | ||
{ | ||
return m_label; | ||
} | ||
|
||
void SendRecipient::setLabel(const QString& label) | ||
{ | ||
if (m_label != label) { | ||
m_label = label; | ||
Q_EMIT labelChanged(); | ||
} | ||
} | ||
|
||
QString SendRecipient::amount() const | ||
{ | ||
return m_amount; | ||
} | ||
|
||
void SendRecipient::setAmount(const QString& amount) | ||
{ | ||
if (m_amount != amount) { | ||
m_amount = amount; | ||
Q_EMIT amountChanged(); | ||
} | ||
} | ||
|
||
QString SendRecipient::message() const | ||
{ | ||
return m_message; | ||
} | ||
|
||
void SendRecipient::setMessage(const QString& message) | ||
{ | ||
if (m_message != message) { | ||
m_message = message; | ||
Q_EMIT messageChanged(); | ||
} | ||
} | ||
|
||
bool SendRecipient::subtractFeeFromAmount() const | ||
{ | ||
return m_subtractFeeFromAmount; | ||
} | ||
|
||
CAmount SendRecipient::cAmount() const | ||
{ | ||
// TODO: Figure out who owns the parsing of SendRecipient::amount to CAmount | ||
return m_amount.toLongLong(); | ||
} | ||
|
||
void SendRecipient::clear() | ||
{ | ||
m_address = ""; | ||
m_label = ""; | ||
m_amount = ""; | ||
m_message = ""; | ||
m_subtractFeeFromAmount = false; | ||
Q_EMIT addressChanged(); | ||
Q_EMIT labelChanged(); | ||
Q_EMIT amountChanged(); | ||
Q_EMIT messageChanged(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
// Copyright (c) 2025 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#ifndef BITCOIN_QML_MODELS_SENDRECIPIENT_H | ||
#define BITCOIN_QML_MODELS_SENDRECIPIENT_H | ||
|
||
#include <QObject> | ||
#include <QString> | ||
#include <qml/bitcoinamount.h> | ||
|
||
class SendRecipient : public QObject | ||
{ | ||
Q_OBJECT | ||
Q_PROPERTY(QString address READ address WRITE setAddress NOTIFY addressChanged) | ||
Q_PROPERTY(QString label READ label WRITE setLabel NOTIFY labelChanged) | ||
Q_PROPERTY(QString amount READ amount WRITE setAmount NOTIFY amountChanged) | ||
Q_PROPERTY(QString message READ message WRITE setMessage NOTIFY messageChanged) | ||
|
||
public: | ||
explicit SendRecipient(QObject* parent = nullptr); | ||
|
||
QString address() const; | ||
void setAddress(const QString& address); | ||
|
||
QString label() const; | ||
void setLabel(const QString& label); | ||
|
||
QString amount() const; | ||
void setAmount(const QString& amount); | ||
|
||
QString message() const; | ||
void setMessage(const QString& message); | ||
|
||
CAmount cAmount() const; | ||
|
||
bool subtractFeeFromAmount() const; | ||
|
||
Q_INVOKABLE void clear(); | ||
|
||
Q_SIGNALS: | ||
void addressChanged(); | ||
void labelChanged(); | ||
void amountChanged(); | ||
void messageChanged(); | ||
|
||
private: | ||
QString m_address; | ||
QString m_label; | ||
QString m_amount; | ||
QString m_message; | ||
bool m_subtractFeeFromAmount{false}; | ||
}; | ||
|
||
#endif // BITCOIN_QML_MODELS_SENDRECIPIENT_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
// Copyright (c) 2011-2025 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#include <qml/models/walletqmlmodeltransaction.h> | ||
|
||
#include <policy/policy.h> | ||
#include <qobject.h> | ||
|
||
WalletQmlModelTransaction::WalletQmlModelTransaction(const SendRecipient* recipient, QObject* parent) | ||
: QObject(parent), m_address(recipient->address()), m_amount(recipient->cAmount()), m_fee(0), m_label(recipient->label()), m_wtx(nullptr) | ||
{ | ||
} | ||
|
||
QString WalletQmlModelTransaction::amount() const | ||
{ | ||
return QString::number(m_amount); | ||
} | ||
|
||
QString WalletQmlModelTransaction::address() const | ||
{ | ||
return m_address; | ||
} | ||
|
||
QString WalletQmlModelTransaction::fee() const | ||
{ | ||
return QString::number(m_fee); | ||
} | ||
|
||
QString WalletQmlModelTransaction::total() const | ||
{ | ||
return QString::number(m_amount + m_fee); | ||
} | ||
|
||
QString WalletQmlModelTransaction::label() const | ||
{ | ||
return m_label; | ||
} | ||
|
||
CTransactionRef& WalletQmlModelTransaction::getWtx() | ||
{ | ||
return m_wtx; | ||
} | ||
|
||
void WalletQmlModelTransaction::setWtx(const CTransactionRef& newTx) | ||
{ | ||
m_wtx = newTx; | ||
} | ||
|
||
CAmount WalletQmlModelTransaction::getTransactionFee() const | ||
{ | ||
return m_fee; | ||
} | ||
|
||
void WalletQmlModelTransaction::setTransactionFee(const CAmount& newFee) | ||
{ | ||
if (m_fee != newFee) { | ||
m_fee = newFee; | ||
Q_EMIT feeChanged(); | ||
} | ||
} | ||
|
||
CAmount WalletQmlModelTransaction::getTotalTransactionAmount() const | ||
{ | ||
return m_amount + m_fee; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
// Copyright (c) 2011-2025 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#ifndef BITCOIN_QML_MODELS_WALLETQMLMODELTRANSACTION_H | ||
#define BITCOIN_QML_MODELS_WALLETQMLMODELTRANSACTION_H | ||
|
||
#include <primitives/transaction.h> | ||
#include <qml/models/sendrecipient.h> | ||
|
||
#include <consensus/amount.h> | ||
|
||
#include <QObject> | ||
|
||
|
||
class WalletQmlModelTransaction : public QObject | ||
{ | ||
Q_OBJECT | ||
Q_PROPERTY(QString address READ address CONSTANT) | ||
Q_PROPERTY(QString amount READ amount NOTIFY amountChanged) | ||
Q_PROPERTY(QString label READ label CONSTANT) | ||
Q_PROPERTY(QString fee READ fee NOTIFY feeChanged) | ||
Q_PROPERTY(QString total READ total NOTIFY totalChanged) | ||
public: | ||
explicit WalletQmlModelTransaction(const SendRecipient* recipient, QObject* parent = nullptr); | ||
|
||
QString address() const; | ||
QString amount() const; | ||
QString fee() const; | ||
QString label() const; | ||
QString total() const; | ||
|
||
QList<SendRecipient> getRecipients() const; | ||
|
||
CTransactionRef& getWtx(); | ||
void setWtx(const CTransactionRef&); | ||
|
||
unsigned int getTransactionSize(); | ||
|
||
void setTransactionFee(const CAmount& newFee); | ||
CAmount getTransactionFee() const; | ||
|
||
CAmount getTotalTransactionAmount() const; | ||
|
||
void reassignAmounts(int nChangePosRet); // needed for the subtract-fee-from-amount feature | ||
|
||
Q_SIGNALS: | ||
void addressChanged(); | ||
void labelChanged(); | ||
void amountChanged(); | ||
void feeChanged(); | ||
void totalChanged(); | ||
|
||
private: | ||
QString m_address; | ||
CAmount m_amount; | ||
CAmount m_fee; | ||
QString m_label; | ||
CTransactionRef m_wtx; | ||
}; | ||
|
||
#endif // BITCOIN_QML_MODELS_WALLETQMLMODELTRANSACTION_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,180 @@ | ||
// Copyright (c) 2024 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
import QtQuick 2.15 | ||
import QtQuick.Controls 2.15 | ||
import QtQuick.Layouts 1.15 | ||
import org.bitcoincore.qt 1.0 | ||
|
||
import "../../controls" | ||
import "../../components" | ||
|
||
Page { | ||
id: root | ||
background: null | ||
|
||
property WalletQmlModel wallet: walletController.selectedWallet | ||
property SendRecipient recipient: wallet.sendRecipient | ||
|
||
signal transactionPrepared() | ||
|
||
ScrollView { | ||
clip: true | ||
width: parent.width | ||
height: parent.height | ||
contentWidth: width | ||
|
||
ColumnLayout { | ||
id: columnLayout | ||
width: 450 | ||
anchors.horizontalCenter: parent.horizontalCenter | ||
|
||
spacing: 10 | ||
|
||
CoreText { | ||
id: title | ||
Layout.topMargin: 30 | ||
Layout.bottomMargin: 20 | ||
text: qsTr("Send bitcoin") | ||
font.pixelSize: 21 | ||
bold: true | ||
} | ||
|
||
LabeledTextInput { | ||
id: address | ||
Layout.fillWidth: true | ||
labelText: qsTr("Send to") | ||
placeholderText: qsTr("Enter address...") | ||
text: root.recipient.address | ||
onTextEdited: root.recipient.address = address.text | ||
} | ||
|
||
Separator { | ||
Layout.fillWidth: true | ||
} | ||
|
||
Item { | ||
BitcoinAmount { | ||
id: bitcoinAmount | ||
} | ||
|
||
height: amountInput.height | ||
Layout.fillWidth: true | ||
CoreText { | ||
id: amountLabel | ||
width: 110 | ||
anchors.left: parent.left | ||
anchors.verticalCenter: parent.verticalCenter | ||
horizontalAlignment: Text.AlignLeft | ||
color: Theme.color.neutral9 | ||
text: "Amount" | ||
font.pixelSize: 18 | ||
} | ||
|
||
TextField { | ||
id: amountInput | ||
anchors.left: amountLabel.right | ||
anchors.verticalCenter: parent.verticalCenter | ||
leftPadding: 0 | ||
font.family: "Inter" | ||
font.styleName: "Regular" | ||
font.pixelSize: 18 | ||
color: Theme.color.neutral9 | ||
placeholderTextColor: Theme.color.neutral7 | ||
background: Item {} | ||
placeholderText: "0.00000000" | ||
selectByMouse: true | ||
onTextEdited: { | ||
amountInput.text = bitcoinAmount.amount = bitcoinAmount.sanitize(amountInput.text) | ||
root.recipient.amount = bitcoinAmount.satoshiAmount | ||
} | ||
} | ||
Item { | ||
width: unitLabel.width + flipIcon.width | ||
height: Math.max(unitLabel.height, flipIcon.height) | ||
anchors.right: parent.right | ||
anchors.verticalCenter: parent.verticalCenter | ||
MouseArea { | ||
anchors.fill: parent | ||
onClicked: { | ||
if (bitcoinAmount.unit == BitcoinAmount.BTC) { | ||
amountInput.text = bitcoinAmount.convert(amountInput.text, BitcoinAmount.BTC) | ||
bitcoinAmount.unit = BitcoinAmount.SAT | ||
} else { | ||
amountInput.text = bitcoinAmount.convert(amountInput.text, BitcoinAmount.SAT) | ||
bitcoinAmount.unit = BitcoinAmount.BTC | ||
} | ||
} | ||
} | ||
CoreText { | ||
id: unitLabel | ||
anchors.right: flipIcon.left | ||
anchors.verticalCenter: parent.verticalCenter | ||
text: bitcoinAmount.unitLabel | ||
font.pixelSize: 18 | ||
color: Theme.color.neutral7 | ||
} | ||
Icon { | ||
id: flipIcon | ||
anchors.right: parent.right | ||
anchors.verticalCenter: parent.verticalCenter | ||
source: "image://images/flip-vertical" | ||
color: Theme.color.neutral8 | ||
size: 30 | ||
} | ||
} | ||
} | ||
|
||
Separator { | ||
Layout.fillWidth: true | ||
} | ||
|
||
LabeledTextInput { | ||
id: label | ||
Layout.fillWidth: true | ||
labelText: qsTr("Note to self") | ||
placeholderText: qsTr("Enter ...") | ||
onTextEdited: root.recipient.label = label.text | ||
} | ||
|
||
Separator { | ||
Layout.fillWidth: true | ||
} | ||
|
||
Item { | ||
height: feeLabel.height + feeValue.height | ||
Layout.fillWidth: true | ||
CoreText { | ||
id: feeLabel | ||
anchors.left: parent.left | ||
anchors.top: parent.top | ||
color: Theme.color.neutral9 | ||
text: "Fee" | ||
font.pixelSize: 15 | ||
} | ||
|
||
CoreText { | ||
id: feeValue | ||
anchors.right: parent.right | ||
anchors.top: parent.top | ||
color: Theme.color.neutral9 | ||
text: qsTr("Default (~2,000 sats)") | ||
font.pixelSize: 15 | ||
} | ||
} | ||
|
||
ContinueButton { | ||
id: continueButton | ||
Layout.fillWidth: true | ||
Layout.topMargin: 30 | ||
text: qsTr("Review") | ||
onClicked: { | ||
if (root.wallet.prepareTransaction()) { | ||
root.transactionPrepared() | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
// Copyright (c) 2024 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
import QtQuick 2.15 | ||
import QtQuick.Controls 2.15 | ||
import QtQuick.Layouts 1.15 | ||
import QtQuick.Dialogs 1.2 | ||
import org.bitcoincore.qt 1.0 | ||
|
||
import "../../controls" | ||
import "../../components" | ||
|
||
Popup { | ||
id: root | ||
modal: true | ||
anchors.centerIn: parent | ||
|
||
background: Rectangle { | ||
anchors.centerIn: parent | ||
width: columnLayout.width + 40 | ||
height: columnLayout.height + 40 | ||
color: Theme.color.neutral0 | ||
border.color: Theme.color.neutral4 | ||
border.width: 1 | ||
radius: 5 | ||
} | ||
|
||
ColumnLayout { | ||
id: columnLayout | ||
anchors.centerIn: parent | ||
spacing: 20 | ||
|
||
Item { | ||
width: 60 | ||
height: 60 | ||
Layout.alignment: Qt.AlignHCenter | ||
Rectangle { | ||
anchors.fill: parent | ||
Layout.alignment: Qt.AlignHCenter | ||
radius: 30 | ||
color: Theme.color.green | ||
opacity: 0.2 | ||
} | ||
Icon { | ||
anchors.centerIn: parent | ||
source: "qrc:/icons/check" | ||
color: Theme.color.green | ||
size: 30 | ||
opacity: 1.0 | ||
} | ||
} | ||
|
||
CoreText { | ||
Layout.alignment: Qt.AlignHCenter | ||
text: qsTr("Transaction sent") | ||
font.pixelSize: 28 | ||
bold: true | ||
} | ||
|
||
CoreText { | ||
Layout.alignment: Qt.AlignHCenter | ||
Layout.maximumWidth: 350 | ||
color: Theme.color.neutral7 | ||
text: qsTr("Based on your selected fee, it should be confirmed within the next 10 minutes.") | ||
font.pixelSize: 18 | ||
} | ||
|
||
ContinueButton { | ||
Layout.preferredWidth: Math.min(200, parent.width - 2 * Layout.leftMargin) | ||
Layout.leftMargin: 20 | ||
Layout.rightMargin: Layout.leftMargin | ||
Layout.alignment: Qt.AlignCenter | ||
text: qsTr("Close window") | ||
borderColor: Theme.color.neutral6 | ||
borderHoverColor: Theme.color.neutral9 | ||
borderPressedColor: Theme.color.neutral9 | ||
textColor: Theme.color.neutral9 | ||
backgroundColor: "transparent" | ||
backgroundHoverColor: "transparent" | ||
backgroundPressedColor: "transparent" | ||
onClicked: { | ||
root.close() | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,139 @@ | ||
// Copyright (c) 2024 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
import QtQuick 2.15 | ||
import QtQuick.Controls 2.15 | ||
import QtQuick.Layouts 1.15 | ||
import org.bitcoincore.qt 1.0 | ||
|
||
import "../../controls" | ||
import "../../components" | ||
|
||
Page { | ||
id: root | ||
background: null | ||
|
||
property WalletQmlModel wallet: walletController.selectedWallet | ||
property WalletQmlModelTransaction transaction: walletController.selectedWallet.currentTransaction | ||
|
||
signal finished() | ||
signal back() | ||
signal transactionSent() | ||
|
||
header: NavigationBar2 { | ||
id: navbar | ||
leftItem: NavButton { | ||
iconSource: "image://images/caret-left" | ||
text: qsTr("Back") | ||
onClicked: { | ||
root.back() | ||
} | ||
} | ||
} | ||
|
||
ScrollView { | ||
clip: true | ||
width: parent.width | ||
height: parent.height | ||
contentWidth: width | ||
|
||
ColumnLayout { | ||
id: columnLayout | ||
width: 450 | ||
anchors.horizontalCenter: parent.horizontalCenter | ||
|
||
spacing: 20 | ||
|
||
CoreText { | ||
id: title | ||
Layout.topMargin: 30 | ||
Layout.bottomMargin: 20 | ||
text: qsTr("Transaction details") | ||
font.pixelSize: 21 | ||
bold: true | ||
} | ||
|
||
RowLayout { | ||
CoreText { | ||
text: qsTr("Send to") | ||
font.pixelSize: 15 | ||
Layout.preferredWidth: 110 | ||
color: Theme.color.neutral7 | ||
} | ||
CoreText { | ||
text: root.transaction.address | ||
font.pixelSize: 15 | ||
color: Theme.color.neutral9 | ||
} | ||
} | ||
|
||
RowLayout { | ||
CoreText { | ||
text: qsTr("Note") | ||
font.pixelSize: 15 | ||
Layout.preferredWidth: 110 | ||
color: Theme.color.neutral7 | ||
} | ||
CoreText { | ||
text: root.transaction.label | ||
font.pixelSize: 15 | ||
color: Theme.color.neutral9 | ||
} | ||
} | ||
|
||
RowLayout { | ||
CoreText { | ||
text: qsTr("Amount") | ||
font.pixelSize: 15 | ||
Layout.preferredWidth: 110 | ||
color: Theme.color.neutral7 | ||
} | ||
CoreText { | ||
text: root.transaction.amount | ||
font.pixelSize: 15 | ||
color: Theme.color.neutral9 | ||
} | ||
} | ||
|
||
RowLayout { | ||
CoreText { | ||
text: qsTr("Fee") | ||
font.pixelSize: 15 | ||
Layout.preferredWidth: 110 | ||
color: Theme.color.neutral7 | ||
} | ||
CoreText { | ||
text: root.transaction.fee | ||
font.pixelSize: 15 | ||
color: Theme.color.neutral9 | ||
} | ||
} | ||
|
||
RowLayout { | ||
CoreText { | ||
text: qsTr("Total") | ||
font.pixelSize: 15 | ||
Layout.preferredWidth: 110 | ||
color: Theme.color.neutral7 | ||
} | ||
CoreText { | ||
text: root.transaction.total | ||
font.pixelSize: 15 | ||
color: Theme.color.neutral9 | ||
} | ||
} | ||
|
||
ContinueButton { | ||
id: confimationButton | ||
Layout.fillWidth: true | ||
Layout.topMargin: 30 | ||
text: qsTr("Send") | ||
onClicked: { | ||
root.wallet.sendTransaction() | ||
root.transactionSent() | ||
} | ||
} | ||
} | ||
} | ||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe
make the button only click-able / highlighted on hover when there is a valid input?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do. I will be coming back to this as a Validation PR.