-
Notifications
You must be signed in to change notification settings - Fork 301
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
feat: cross chain boost sync support #3377
Conversation
Deploying with Cloudflare Pages
|
…v2 into feat/cross-chain-boost
src/components/contextual/pages/vebal/cross-chain-boost/CrossChainBoostCards.vue
Outdated
Show resolved
Hide resolved
src/components/contextual/pages/vebal/cross-chain-boost/SyncNetworkAction.vue
Outdated
Show resolved
Hide resolved
} | ||
|
||
// veBAL_balance = bias - slope * (now() - timestamp) | ||
function calculateVeBAlBalance() { |
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.
Which veBAL balance are we calculating here? Do we not do this calculation already somewhere else for the veBAL page?
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.
it is calculation of synced veBal balance of certain network
const timestamp = votingEscrowLocks.value?.timestamp; | ||
|
||
if (!bias || !slope || !timestamp) | ||
return new BigNumber(0).toFixed(4).toString(); |
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.
Again, please use bnum
.
@@ -26,5 +26,5 @@ test('Does not calculate boosts when user does not have gauge shares', async () | |||
|
|||
const data = await waitForQueryData(result); | |||
|
|||
expect(data).toEqual({ 'test pool id': '1.00000000833325' }); | |||
expect(data).toEqual({ 'test pool id': '1.0854950634314737561' }); |
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.
Why did this test change? Is it now correct or was the previous value correct?
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.
@agualis wonder if it was changed bc of some of your tests changes?
} | ||
|
||
let disposeRefetchOnInterval: NodeJS.Timeout; | ||
function refetchOnInterval() { |
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.
Can you not use a useIntervalFn
from vueuse
?
https://github.com/balancer/frontend-v2/blob/develop/src/pages/pool/add-liquidity.vue#L45
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.
I think it's better not to use hooks in functions?
* feat: add gauge balancer helper contract * feat: add alerts in staking card * wip * feat: add check balances * feat: add alerts on pool page * wip * feat: add user checkpoint actions * remove logs * feat: add networks tooltips * feat: change sync process warning * feat: change unstake btn style * UI updates * feat: change unsynced arr * fix: unstake btn style * feat: fix trigger update fn * feat: open staking incentives card by default * feat: add sync tips * feat: opening staking incentives card * feat: change texts * feat: add info message * fixes after review --------- Co-authored-by: pkattera <[email protected]>
* chore: Update wording * chore: Update wording
* feat: add layer zero tx links * feat: add timeout on l0 tx hashes set * feat: hide text if no l0 link * feat: remove test code * feat: add padding if no link * feat: implement fetch l0 messages on interval
setSyncTxHashes(network, tx.hash); | ||
}, | ||
onTxFailed: () => { | ||
// |
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.
We should display an error message in this case, right? Could you check what is done in the join/exit flows here and see what we might need to add.
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.
not sure if we need to add smth here. error message is handled in BalActionSteps
component and in other flows here confirming
field in state is set to false. e.g
Line 135 in 7cdfe61
txState.confirming = false; |
Description
See title
Type of change
How should this be tested?
Please provide instructions so we can test. Please also list any relevant details for your test configuration.
Visual context
Please provide any relevant visual context for UI changes or additions. This could be static screenshots or a loom screencast.
Checklist:
master
if hotfix,develop
if not