Open gizemcakil opened 4 years ago
Issue Status: 1. Open 2. Started 3. Submitted 4. Done
This issue now has a funding of 0.001 ETH (0.17 USD @ $170.32/ETH) attached to it as part of the harmony-one fund.
Hello @vikramide! The repo is here https://github.com/harmony-one/staking-dashboard and you can find available api information here https://apitest.harmony.one/?version=latest Some is still wip, but most should work already. Please let us know if you have any questions.
Hello Hacker!
We are aware there is no way to send multiple delegations at once using the JS SDK right now, so this bounty should be viewed as a "frontend only" update.
Make the necessary changes to UI / UX so the user can create a queue of delegations.
When it comes to sending the transactions to the chrome extension, the user will need to confirm each transaction separately (with a new nonce per tx) in order for them to succeed.
For more information about the JS SDK, see here: https://github.com/harmony-one/sdk
Please comment here if you have any further questions.
@mattlockyer Thanks. Thats what I was wondering . Like usually we can make a list of transactions and sign the whole packet and submit to network. I could not find that functionality.
So perhaps as you suggested. I can create a list of delegation and then figure out a way to sign each of them in the browser SDK.
Maybe a watcher can come handy here. Once my list of signed tx is ready I could submit it to the network as multiple transactions
@mattlockyer Just leaving here my latest update on the UI design .
https://www.loom.com/share/92de51fc0cef4a6886ff0e365b21572f
Store DelegationQue.js Select Component . ValidatorSelect.vue Modal MultiDeligationModal.vue
Apart from this added MultiDeligationModal in the PageValidator.vue component.
Let me know if this what you guys wnated. Or I need to make any other changes
@mattlockyer Just leaving here my latest update on the UI design .
https://www.loom.com/share/92de51fc0cef4a6886ff0e365b21572f
Code changes
Store DelegationQue.js Select Component. ValidatorSelect.vue Modal MultiDeligationModal.vue
Apart from this added MultiDeligationModal in the PageValidator.vue component.
Let me know if this what you guys wnated. Or I need to make any other changes
this looks really nice!
Hey guys I have created special extension version with multi-delegate support
You need to extend harmony-sdk/MsgDelegate event with 2 params to send multi-delegate
Then you will see all your delegations in extension
After password entering - they will be sign and sent
As Yuriy request, i built an new extension just for testing this extension_gitcoin_test.zip
Guys latest update .
Based on audience demand from Open Staking Pangea group
I added the toggle either to assign or divide
Next I am gonna hook the sign functionality of the browser wallet and Boom its ready
https://www.loom.com/share/3e7356d70e8d4fd58ef5a2349f8c5251
@daywednes @potvik , Once I am done with the functionality which is asked in this hackathon.
Ill fix the code to submit Multiple Tx at once.
@mattlockyer @gizemcakil
So here is a video of complete feature based on the current scope .
https://www.loom.com/share/b936829cd89749019180004990df82e7
If it looks fine for you guys . I can go ahead and do a submission which I need to figure out .
Perhaps some help would be appreciated .
Thanks @vikramIde this already looks great.
Just one comment: I believe we can batch the transactions and enter the password only once in the chrome extension. This would significantly improve the user flow.
@mikedoan @potvik Is it possible to batch tx more than what @vikramIde demonstrated above?
@gizemcakil waiting 💭
@vikramIde I think the flow should be like following
Yuriy has written a PR https://github.com/harmony-one/wallet-extension/pull/40/files
and i generated the chrome extension based on that PR - can you use the attached extension above.
@mikedoan Thanks for the link but
The PR you pointed takes me to 404.
So If i have to change my design to previous design . Then literally will need to change lot of files almost doubling the work. That is why I was asking here if I am on the right track.
But what I can do is figure out the batch transaction functionality once I get the working version of the extension . And add a one click sign all feature.
Also the transaction fee will be added in the end Like how we have FeeTotal and SUbTotal
why are you using the link? you need to grab the extension I built for you.
The extension is the main work but we already helped you with that.
@daywednes Thank you its clear now.
Aye! Aye! captain consider it done.
Will share a video with the batch TX. Post to acceptance will put a PR
@daywednes So in our modal we have function called
setMaxAmount() {
this.amount = Math.min(
atoms(this.balance),
ones(this.validator.remainder)
)
},
Now this function works for single validator, In our case we have multiple validator
What do you think the logic of the setmax() button should be ?
Should I set maximum amount left in delegator's account ?
@daywednes @gizemcakil PR added kindly review
Is there work here already done? Or may I submit my solution as well?
We will review all submissions together and then decide on the winners. Please submit your work as well!
hey @fragmnt we started reviewing the submissions. Will you make a submission for this bounty?
hey @fragmnt we started reviewing the submissions. Will you make a submission for this bounty?
hi @gizemcakil, i won’t be submitting for this bounty. the submissions already awesome enough and similar to what i was going to implement 😁 best of luck everyone !!
p.s. i worked on the alert mechanism bounty instead 👍
@gizemcakil would be great if you could please get the PR reviewed this week.
Regards
About The Bounty
Please carefully review the competition terms and submission process before starting. https://github.com/harmony-one/harmony-open/blob/master/README.md
Description
Proposal: Build a multi-delegation feature on Harmony Staking Dashboard that allows the users to delegate to multiple validators with a single click.
This project requires a good understanding of staking dashboard codebase.
Pain point:
An average delegator is expected to diversify his stake as a general rule of thumb in investing. Especially, when a delegator is not very informed about validator profiles (or don’t wanna understand in general), the natural user behavior is to spread your stake across as many validators as possible
Currently, delegating to a single validator takes: 9 clicks to complete, 1 entry (amount),1 password entry (Chrome ext.)
Nudging users to delegate to as many validators as possible from our own staking explorer UX is the most direct and immediate way to promote decentralization
Suggested user flow:
Useful readings:
Prizes
This bounty is eligible for Tier 2 prize. The final prize will be decided by the Harmony engineering team. The judging criteria for the prizes are:
IMPORTANT NOTE: The prizes will be paid in native ONE tokens, the fiat value of prizes will change with token prices.
Explore All Bounties
https://gitcoin.co/profile/harmony-one