Skip to content

Conversation

@manny-uncharted
Copy link

closes: #237

Summary:

  • Adds visibility into re-up potential for each receipt on the Unlock page.
  • Displays:
    • Additional cyToken per 1 underlying (based on current lock price vs original lock price at mint).
    • Total additional cyToken per receipt (scaled by underlying locked in the receipt).
    • A grand total across all receipts.
  • UI includes a toggle to show/hide re-up details and tooltips explaining the math.

Details:

  • Source of truth:
    • Original lock price from receipt.tokenId.
    • Current lock price from $balancesStore.stats[token.name].lockPrice.
  • Formulas:
    • addlPerUnderlying = max(0, currentLockPrice − tokenId)
    • totalsFlr = (balance × 10^18) / tokenId
    • addlTotal = (totalsFlr × addlPerUnderlying) / 10^18
  • Reactivity:
    • All values recompute when $balancesStore.stats updates (prices refresh).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

show when a position could be reupped for more cytoken

1 participant