mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-10 14:26:34 +00:00
feat: add ToastMessage when transaction becomes pending
This commit is contained in:
parent
7fe2d8696f
commit
797da0a962
@ -20,16 +20,6 @@ ModalPopup {
|
||||
icon: StandardIcon.Critical
|
||||
standardButtons: StandardButton.Ok
|
||||
}
|
||||
property MessageDialog sendingSuccess: MessageDialog {
|
||||
id: sendingSuccess
|
||||
//% "Success sending the transaction"
|
||||
title: qsTrId("success-sending-the-transaction")
|
||||
icon: StandardIcon.NoIcon
|
||||
standardButtons: StandardButton.Ok
|
||||
onAccepted: {
|
||||
root.close()
|
||||
}
|
||||
}
|
||||
|
||||
onClosed: {
|
||||
stack.reset()
|
||||
@ -274,10 +264,12 @@ ModalPopup {
|
||||
return sendingError.open()
|
||||
}
|
||||
|
||||
sendingSuccess.text = qsTr("Transaction sent to the blockchain. You can watch the progress on Etherscan: %2/%1").arg(response.result).arg(walletModel.etherscanLink)
|
||||
sendingSuccess.open()
|
||||
toastMessage.title = qsTr("Transaction pending...")
|
||||
toastMessage.link = `${walletModel.etherscanLink}/${response.result}`
|
||||
toastMessage.open()
|
||||
root.close()
|
||||
} catch (e) {
|
||||
console.error('WOW', e)
|
||||
console.error('Error parsing the response', e)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,6 +12,10 @@ RowLayout {
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
|
||||
ToastMessage {
|
||||
id: toastMessage
|
||||
}
|
||||
|
||||
TabBar {
|
||||
id: tabBar
|
||||
width: 78
|
||||
|
Loading…
x
Reference in New Issue
Block a user