-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dApp staking v3 #1023
Merged
+10,384
−147
Merged
dApp staking v3 #1023
Changes from 1 commit
Commits
Show all changes
77 commits
Select commit
Hold shift + click to select a range
2faa522
Defined v3 project structure
bobo-k2 05ca294
Stake, unstake skeletons
bobo-k2 3165911
Code organization improvements
bobo-k2 bd72bd2
Get protocol state
bobo-k2 c97a82c
Protocol change notification message
bobo-k2 cf82b2c
Merge branch 'main' into feat/dapp-staking-v3
bobo-k2 602f2bb
Lock and stake
bobo-k2 8be2738
Read account ledger
bobo-k2 80f9cea
Unstake call
bobo-k2 69fd2c1
unstake and unlock, claim staker
bobo-k2 02e3569
Staker info
bobo-k2 cd96a18
Started with can stake logic
bobo-k2 981a64d
Updated node types
bobo-k2 d79acdc
Staker reward calculation part 1
bobo-k2 eccface
Staker rewards calculation part 2
bobo-k2 2eeb12d
dApp rewards calculation and claim
bobo-k2 4300015
Calculate and claim bonus rewards
bobo-k2 dafbeef
Merge branch 'main' of github.com-impelcrypto:AstarNetwork/astar-apps…
impelcrypto f9e37cf
Calculate claim staker batch size fix
bobo-k2 c484606
Merge branch 'feat/dapp-staking-v3' of github.com:AstarNetwork/astar-…
bobo-k2 39f2723
Rewards fetch fix
bobo-k2 92b2575
can claim methods
bobo-k2 2d10a35
Can Claim bug fix
bobo-k2 6a5cbb9
fix: conflicts
impelcrypto 08a4123
feat: Prevents Errors from Occuring (#1026)
gluneau 879705a
feat: added top page (#1033)
impelcrypto 1d72212
Vote mobile page and logic (#1036)
bobo-k2 d138309
Vote batch bug fixes
bobo-k2 bd3d882
vote and dictionary changes (#1037)
gluneau 493e7a2
Vote on multiple dApps (#1046)
bobo-k2 e5a82f4
feat: link to the project page (#1049)
impelcrypto fafa2bd
styles: added 'current tier' and 'total earned' (#1053)
impelcrypto e3be666
pulled latest main branch (#1057)
impelcrypto 988912e
Staking panels and leaderboard (#1056)
bobo-k2 b529b3a
feat: added owner section on the assets page (#1059)
impelcrypto 809538f
Staking v3 data (#1064)
bobo-k2 364c344
Compatibility issues fix (#1075)
bobo-k2 246f020
feat: maxUnlockingChunks (#1071)
gluneau d66ada2
Merge branch 'main' into feat/dapp-staking-v3
bobo-k2 0310cc2
Remove commented
bobo-k2 6b3337e
feat: added owner section (#1079)
impelcrypto 0cd3444
fix: copy the project page components to the staking-v3 folder (#1085)
impelcrypto 3608a6a
Owner page logic and unstake from unregistered (#1088)
bobo-k2 ade332b
Feat/staking v3 improvements4 (#1089)
bobo-k2 727639b
Merge branch 'main' into feat/dapp-staking-v3
bobo-k2 caaaf72
Add Shibuya Scope Style (#1078)
ayumitk 30743f4
Show success messages and tier rewards (#1097)
bobo-k2 3899ceb
dApp search bug fix, amount to be locked fix
bobo-k2 783d75d
Build error fix
bobo-k2 a0a4f7b
Nomination transfer
bobo-k2 e90bcd0
Disable Vote button if no stakes.
bobo-k2 af705b2
Reward calculation fix, unlock
bobo-k2 ae8db28
v3 vote period style (#1098)
ayumitk 75cb4ad
Show nomination transfer info on Voting page
bobo-k2 dc84ab8
Merge branch 'main' into feat/dapp-staking-v3
bobo-k2 0141319
feat: added EVM supports (#1102)
impelcrypto ff40d60
EVM unlock fix
bobo-k2 43a3b32
fix: added todo comment
impelcrypto 60f1f95
GetTier bug fix and removed some comments
bobo-k2 51ef615
Merge branch 'feat/dapp-staking-v3' of github.com:AstarNetwork/astar-…
bobo-k2 13f5be1
fix: removed unused files
impelcrypto ab5fa57
Comments cleanup
bobo-k2 e36c1f2
Merge branch 'feat/dapp-staking-v3' of github.com:AstarNetwork/astar-…
bobo-k2 fa15821
Gas price provider fix
bobo-k2 71b7f60
Message subscriptions, check value before assignment.
bobo-k2 9f15773
Nomination transfer bug fix, styling and translations
bobo-k2 8721679
Nomination transfer amount, total stake
bobo-k2 c82e7ab
Leaderboard fix, multiplier removed
bobo-k2 db8e201
Staker reward calculation optimisation
bobo-k2 c242ae2
Merge branch 'main' into feat/dapp-staking-v3
bobo-k2 3a7af62
Clam banner text update for Shibuya
bobo-k2 de005f5
Voting period countdown
bobo-k2 9576d94
Current period day and canConfirm fixes
bobo-k2 ea3f67b
feat: update project page styles (#1109)
ayumitk 79306d9
feat: add migrate support style (#1114)
ayumitk 535b58f
Hide migration support for now
bobo-k2 2e6263e
feat: added staker and bonus rewards APR (#1113)
impelcrypto File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
feat: added owner section (#1079)
* feat: added rewards section * feat: added edit section * fix: refactor * fix: i18
commit 6b3337e498fb53d329de8c48d08a38a1599a0c75
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
<template> | ||
<div class="wrapper--edit"> | ||
<div class="row--title"> | ||
<span> {{ $t('stakingV3.edit') }} </span> | ||
</div> | ||
<div class="box--links"> | ||
<!-- Todo: add links --> | ||
<div class="box--link"> | ||
<div class="box__top" /> | ||
<div class="box__middle"> | ||
<span>{{ $t('stakingV3.editProjectPage.title') }}</span> | ||
</div> | ||
<div class="box__bottom"> | ||
<span>{{ $t('stakingV3.editProjectPage.text') }}</span> | ||
</div> | ||
</div> | ||
<div class="box--link"> | ||
<div class="box__top" /> | ||
<div class="box__middle"> | ||
<span>{{ $t('stakingV3.editYourInfo.title') }}</span> | ||
</div> | ||
<div class="box__bottom"> | ||
<span>{{ $t('stakingV3.editYourInfo.text') }}</span> | ||
</div> | ||
</div> | ||
<div class="box--link"> | ||
<div class="box__top" /> | ||
<div class="box__middle"> | ||
<span>{{ $t('stakingV3.addPromotion.title') }}</span> | ||
</div> | ||
<div class="box__bottom"> | ||
<span>{{ $t('stakingV3.addPromotion.text') }}</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script lang="ts"> | ||
import { defineComponent } from 'vue'; | ||
|
||
export default defineComponent({ | ||
components: {}, | ||
setup() { | ||
return {}; | ||
}, | ||
}); | ||
</script> | ||
|
||
<style lang="scss" scoped> | ||
@use './styles/edit.scss'; | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,185 @@ | ||
<template> | ||
<div class="wrapper--your-rewards"> | ||
<div class="row--title"> | ||
<span> {{ $t('stakingV3.yourRewards') }} </span> | ||
</div> | ||
<!-- Memo: Temporary UI --> | ||
<div class="row--claim-temporary"> | ||
<div> | ||
<span class="text--lg">Unclaimed Eras: </span> | ||
<span class="text--lg">20</span> | ||
</div> | ||
<div> | ||
<span class="text--lg">Claimable Amount: </span> | ||
<span class="text--lg"> | ||
{{ $t('amountToken', { amount: 100, token: nativeTokenSymbol }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<astar-button class="button--claim"> | ||
{{ $t('stakingV3.claim') }} | ||
</astar-button> | ||
</div> | ||
</div> | ||
<!-- Memo: mocked UI --> | ||
<div class="container--rewards"> | ||
<div class="box--rewards"> | ||
<div class="box__row"> | ||
<div> | ||
<span class="text--title"> | ||
{{ $t('stakingV3.period', { period: '006' }) }} | ||
</span> | ||
</div> | ||
<div class="row--claim-info"> | ||
<div> | ||
<span class="text--vivid"> | ||
{{ $t('stakingV3.availableToClaim') }} | ||
</span> | ||
</div> | ||
<div> | ||
<div> | ||
<span class="text--vivid"> | ||
{{ $t('stakingV3.days', { day: 10 }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--vivid-bond"> | ||
<token-balance :balance="'1000'" :symbol="nativeTokenSymbol" /> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="box__row"> | ||
<div> | ||
<span class="text--title"> | ||
{{ $t('stakingV3.period', { period: '005' }) }} | ||
</span> | ||
</div> | ||
<div class="row--claim-info"> | ||
<div> | ||
<span class="text--info"> {{ $t('stakingV3.alreadyClaimed') }}</span> | ||
</div> | ||
<div> | ||
<div> | ||
<span class="text--info"> | ||
{{ $t('stakingV3.days', { day: 10 }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--info-bond"> | ||
<token-balance :balance="'1000'" :symbol="nativeTokenSymbol" /> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="row--claim-info"> | ||
<div> | ||
<span class="text--vivid"> {{ $t('stakingV3.availableToClaim') }}</span> | ||
</div> | ||
<div> | ||
<div> | ||
<span class="text--vivid"> | ||
{{ $t('stakingV3.days', { day: 10 }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--vivid-bond"> | ||
<token-balance :balance="'1000'" :symbol="nativeTokenSymbol" /> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="row--attention"> | ||
<span> {{ $t('stakingV3.claimNow') }}</span> | ||
</div> | ||
</div> | ||
<div> | ||
<astar-button class="button--claim"> | ||
{{ $t('stakingV3.claim') }} | ||
</astar-button> | ||
</div> | ||
</div> | ||
|
||
<div> | ||
<div class="box--rewards"> | ||
<div class="box__row"> | ||
<div class="row--claim-info"> | ||
<div class="box__column"> | ||
<div> | ||
<span class="text--title"> | ||
{{ $t('stakingV3.period', { period: '004' }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--info"> | ||
{{ $t('stakingV3.days', { day: 123 }) }} | ||
</span> | ||
</div> | ||
</div> | ||
<div class="box__column"> | ||
<div class="column--status-claimed"> | ||
<span> | ||
{{ $t('stakingV3.claimed') }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--info-bond"> | ||
<token-balance :balance="'1000'" :symbol="nativeTokenSymbol" /> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="box__row"> | ||
<div class="row--claim-info"> | ||
<div class="box__column"> | ||
<div> | ||
<span class="text--title"> | ||
{{ $t('stakingV3.period', { period: '003' }) }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--info"> | ||
{{ $t('stakingV3.days', { day: 123 }) }} | ||
</span> | ||
</div> | ||
</div> | ||
<div class="box__column"> | ||
<div class="column--status-claimed"> | ||
<span> | ||
{{ $t('stakingV3.claimed') }} | ||
</span> | ||
</div> | ||
<div> | ||
<span class="text--info-bond"> | ||
<token-balance :balance="'1000'" :symbol="nativeTokenSymbol" /> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script lang="ts"> | ||
import { useNetworkInfo } from 'src/hooks'; | ||
import { defineComponent } from 'vue'; | ||
import TokenBalance from 'src/components/common/TokenBalance.vue'; | ||
|
||
export default defineComponent({ | ||
components: { TokenBalance }, | ||
setup() { | ||
const { nativeTokenSymbol } = useNetworkInfo(); | ||
|
||
return { nativeTokenSymbol }; | ||
}, | ||
}); | ||
</script> | ||
|
||
<style lang="scss" scoped> | ||
@use './styles/your-rewards.scss'; | ||
</style> |
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add the logic for owner page in this PR? If so, let's add the links
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's leave this for the future PR