Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

feat: transaction notifications #218

Merged
merged 7 commits into from
Jun 19, 2023
Merged

feat: transaction notifications #218

merged 7 commits into from
Jun 19, 2023

Conversation

statictype
Copy link
Contributor

@statictype statictype commented Jun 16, 2023

Makes use of the custom Notification component we have, showing toast notifications for transaction status and block inclusion events.

Changed from running .finalized() on the Runes to inBlockEvents().
Usually apps display events on block inclusion, because waiting for finalization adds an extra 6 seconds and the app and network are perceived as slow. Because most blocks get finalized, showing the notifications once the tx is included makes sense. We do want to notify when the status changes to finalized as well, but couldn't find a way to do that in capi. paritytech/capi#1090

@netlify
Copy link

netlify bot commented Jun 16, 2023

Deploy Preview for capi-multisig ready!

Name Link
🔨 Latest commit 278cc86
🔍 Latest deploy log https://app.netlify.com/sites/capi-multisig/deploys/64903d52dde45a00080df0bb
😎 Deploy Preview https://deploy-preview-218--capi-multisig.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@statictype statictype marked this pull request as draft June 16, 2023 17:43
@statictype statictype marked this pull request as ready for review June 19, 2023 08:11
@statictype statictype marked this pull request as draft June 19, 2023 08:57
@statictype statictype marked this pull request as ready for review June 19, 2023 12:12
@statictype statictype requested a review from peetzweg June 19, 2023 12:12
Copy link
Member

@peetzweg peetzweg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Although waiting for an extrinsic to be finalized is actually crucial for ux, otherwise ui data will be inconsistent and users expect their extrinsic was successful, which still could fail.

Should not block merging this, however we need a follow up ticket to wait for finalized extrinsics imho.

@statictype
Copy link
Contributor Author

we should ideally show "finalized" or "reverted" once that happens, but we don't need to wait 6 more seconds to display the events.

all dapps i know of display them on block inclusion.

@statictype statictype merged commit 4b7fc35 into main Jun 19, 2023
@statictype statictype deleted the feat/notifications branch June 19, 2023 14:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants