This repository was archived by the owner on Jun 24, 2022. It is now read-only.
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.
Summary
This 1st PR wants just to create a few elements that would allow us to reiterate and divide a bit the work.
It re-enables the original claiming functionality from Uniswap, and adapts the minimum necessary to set a starting point.
Note that this PR will merge to
claim
which can be a standing base branch until this is mergeable in develop.Included in this PR
Hooks to get the claimable data
It created the mod from the original Uniswap claiming related hooks. This hooks are responsible of fetching data and creating the transaction.
See
src/custom/state/claim/hooks/hooksMod.ts
❗️One big difference between UNI and vCOW claiming, is that they have a single claiming per address, while we might have many. I changed the signatures to reflect this, and did the minimal changes to reduce the collections of claimings into something similar to what Uniswap had.
The PR does the minimal changes, but we will need to reiterate to implement the real thing.
It adapts it so we add the claiming information to the "enhanced transaction"
We would need to check this for both xDAI and Mainnet, but for now it has some mock data.
Add Claim button to header
This button will be shown if the connected wallet has some unclaimed options/airdrops.
Open Claim modal
For now the modal is not "Moded", but I added it to the app. Future PRs should change it.
Menu Claim for an arbitrary account
This button will be shown even if you don't have claimigns. So you can claim for someone else.
Claim for an arbitrary account modal
Added the modal to claim for someone else:
This modal hasn't been moded in the PR yet. It should be done in a different one.
Claim and Invest page
The idea (although I haven't reflected it in the wireframes yet) is to try to only send the user to this new page if there's some investment to be done.
This PR just creates the Route Paths. It added some content copied from the pools, which will dissapear. However, there's a nice component we can use (the countdown shown below):
The countdown can be used to inform about the time left to claim the Airdrop and/or invest