Giveth/liquidity-mining-dapp

Generic farm cards

Closed this issue · 2 comments

As a user, I want to be able to manage my staked position and rewards. As giveth devs, we want to be able to easily deploy new farm cards.

Mockup

Note: most of this is already done for the GIVfarms and just needs to be recycled ♻️ see asterisks for new functionality

AC:
Prior to a new farm launching, a card is added to the RegenFarms section that includes the following information:

  • a. Staking token symbol, name, subtitle, icon, and contract address (ie. FOX/HNY, 50% FOX / 50% HNY, 0x8a0bee989c591142414ad67fb604539d917889df)
  • b. Reward token symbol, name, icon, and contract address (ie. FOX)
  • c. DEX or staking protocol (ie. Honeyswap)
  • d. Info tooltip to to learn more about the project and project information (@markoprljic any idea what character limit should be?)*
  • e. Project description (ShapeShift is the free and open-source one-stop-shop for cross-chain DeFi. Buy, sell, send, receive, trade, and earn yield on your crypto across a growing number of protocols and chains with no added fees ever. FOX is the governance token of the ShapeShift DAO.)
  • f. link to Project Website (ie. https://shapeshift.com)*
  • g. APR - Users can see APR for rewards
  • g. APR Tooltip - If a user clicks the toolip next to APR, they see a modal with the respective Current Distribution and Stream End date
    Copy:
    IMPORTANT
    A percentage of the [Reward Token Symbol (ie. FOX)] you earn from staking is claimable immediately, and the remaining percent goes into increasing your [Reward Token Symbol]stream flowrate. Over time, a greater percentage of your total earnings will be claimable immediately.
    Current Distribution:
    Claimable immediately: [Immediately claimable %]
    Increasing your GIVstream: [Streaming %]
    Read More
    image
    g. Claimable - Users can see the amount of rewards immediately claimable
    h. Streaming - Users can see the amount of rewards that will be added to their stream
    i. Harvest Rewards - If a user has rewards available to harvest, the Harvest Rewards CTA is activated
    j. Stake - Users can see their balance of unstaked tokens. If users have unstaked tokens, the Stake button/flow is activated
    k. Unstake - Users can see their balance of staked tokens. If users have staked tokens, the Unstake button/flow is activated
    l. Provide Liquidity or Buy [token] - if staked token is an LP token, users see a ‘Provide Liquidity’ CTA that routes them to add the respective pair on the respective DEX. If staked token is a single asset, users see a ‘Buy [Asset]’ CTA that routes them to buy the asset on a DEX.

*New addition to current farm cards

Countdown timer is a separate ticket and stretch goal

image

Info tooltip suggested character limit: 500.

The backend is almost ready and is deployed using test smart contracts (TestFOX and TestHNY tokens and etc.)
The frontend is under construction by this PR #183 and the latest state can be seen by the preview link available there.