gamedaoco / gamedao-haiku

GameDAO Apps
https://gamedao.co
12 stars 3 forks source link

add transaction status modal component #122

Closed 2075 closed 2 years ago

2075 commented 2 years ago

User Story

As user I want to understand what my transaction is for, how much it costs and if it was successful or not so I am always in control of my funds.

Acceptance Criteria

  1. have a modal which pops up when I want to perform a transaction
  2. modal consists of 2.1 a TITLE which describes what action I do (see additional information for different actions) 2.2 subtitle "Transaction overview" 2.3 "Your current balance" in network token 2.4 Transaction fee
  3. If the action contains a deposit of utility token (GAME) or stable coin (eg. aUSD): 3.1 a 2nd ACTION SUBTITLE describing the sub-action (see additional information for different sub-actions) 3.2 a linked hint "What is this used for" --> when clicking an info text shows up providing more information 3.2 "Your current balance" in corresponding action token (GAME/aUSD) 3.3 ACTION SUBLINE
  4. Submit button 4.1 When clicking the submit button the snack bar appears with loading icon (circling) 4.2 additionally the wallet appears to sign the transaction 4.3 when transaction is signed and was successful the success snackbar appears including the trx hash 4.4 when the transaction failed the error snackbar appears including the error message the network provides
  5. A "Get Zero/GAME or aUSD here" text (depending on the action either GAME or aUSD - always ZERO) 5.1 links to discord faucet as long as we dont have a live liquidity pool
  6. all texts are localized

Additional Information

Transaction and deposit Deposit Currency TITLE ACTION SUBTITLE What is this used for ACTION SUBLINE
create organisation GAME Create Organisation Organisation deposit You need to deposit the amount so you can create an organisation. You will receive your deposit back when you close the organisation. Deposit
join organisation (if with fee - transfer) GAME Join Organisation Pay Organisation fee The organisation collects an entry fee which will be transferred to the organisation treasury. Transfer fee
join organisation (if with fee - reserve) GAME Join Organisation Reserve Organisation fee The fee is reserved in your wallet as long you are member of the organisation. Reserve fee
leave organistion (if reserve) GAME Leave Organisation Leave and unreserve fee The reserved fee will be unreserved in your wallet. Unreserve fee
create campaign GAME Create Campaign Campaign deposit You need to deposit the amount so you can create a campaign. Deposit
create proposal GAME Create Proposal Proposal deposit You need to deposit the amount so you can create a proposal. Deposit
contribute to a campaign PLAY/aUSD Fund Campaign Contribute PLAY/aUSD Your funds will be reserved until the campaign is either successful or fails Contribute
create onchain identity ZERO Set ZERO chain identity Deposit You need to deposit the amount so you can create an on-chain identity. Deposit
join organisation (if without fee) none Join Organisation none This organisation does not require any fee. Free
leave organisation (if without fee) none Leave Organisation none
vote none Submit Vote none

screenshots

image

How to test

  1. create transaction which might fail
  2. see loading message & see error notification
  3. create transaction which may succeed
  4. see loading message & success notification
  5. create trx with deposit and see deposit listed as designed in figma
2075 commented 2 years ago

gamedaoco/gamedao-beta#261

2075 commented 2 years ago

gamedaoco/gamedao-beta#251