Skip to content

Commit

Permalink
Merge pull request #115 from mstable/fix/links
Browse files Browse the repository at this point in the history
fix: mstable apps links
  • Loading branch information
dimlbc committed Aug 22, 2023
2 parents 7e3cf24 + 6ab64d9 commit efa345c
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 8 deletions.
5 changes: 3 additions & 2 deletions src/components/home/Adverts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import React from 'react'

import styled from 'styled-components'

import { MTA_BURN_APP_LINK, YIELD_APP_LINK } from '../../constants'
import { Card, CardActions, CardContent, CardHeader } from '../Card'
import { LinkButton } from '../CTA'

Expand Down Expand Up @@ -33,7 +34,7 @@ export const Adverts: FC = () => (
<p>Unlock maximum returns with Meta Harvester, the vault that redefines DeFi yield farming. </p>
</CardContent>
<CardActions>
<LinkButton href="https://yield.mstable.app/vault/0x9c6de13d4648a6789017641f6b1a025816e66228" highlight external={false}>
<LinkButton href={`${YIELD_APP_LINK}/vault/0x9c6de13d4648a6789017641f6b1a025816e66228`} highlight external={false}>
Meta Harvester
</LinkButton>
</CardActions>
Expand Down Expand Up @@ -69,7 +70,7 @@ export const Adverts: FC = () => (
<p>Burn MTA to receive stablecoin yield on Optimism. Swap fixed at $0.0318 USD / MTA.</p>
</CardContent>
<CardActions>
<LinkButton href="https://withdraw.mstable.app/burn" external={false}>
<LinkButton href={MTA_BURN_APP_LINK} external={false}>
MTA Buyback
</LinkButton>
</CardActions>
Expand Down
5 changes: 3 additions & 2 deletions src/components/home/Products.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React from 'react'

import styled from 'styled-components'

import { WITHDRAW_APP_LINK, YIELD_APP_LINK } from '../../constants'
import { Card, CardActions, CardContent, CardHeader } from '../Card'
import { LinkButton } from '../CTA'

Expand All @@ -28,7 +29,7 @@ export const Products: FC = () => {
<p>New yield products to earn best in market yields.</p>
</CardContent>
<CardActions>
<LinkButton href="https://yield.mstable.app" highlight external={false}>
<LinkButton href={YIELD_APP_LINK} highlight external={false}>
mStable Yield App
</LinkButton>
</CardActions>
Expand All @@ -41,7 +42,7 @@ export const Products: FC = () => {
<p>Withdraw from your legacy mStable product positions.</p>
</CardContent>
<CardActions>
<LinkButton href="https://withdraw.mstable.app" external={false}>
<LinkButton href={WITHDRAW_APP_LINK} external={false}>
Legacy Support
</LinkButton>
</CardActions>
Expand Down
4 changes: 2 additions & 2 deletions src/components/layout/Footer.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import styled, { css } from 'styled-components'

import { MTA_BUY_LINK } from '../../constants'
import { MTA_BUY_LINK, YIELD_APP_LINK } from '../../constants'
import DefiPulse from '../../images/social/defi-pulse.svg'
import Discord from '../../images/social/discord.svg'
import Email from '../../images/social/email.svg'
Expand Down Expand Up @@ -238,7 +238,7 @@ export const Footer: FC = () => {
<Top>
<div>
<Header>Protocol</Header>
<ExternalLinkChevron href="https://yield.mstable.app/">App</ExternalLinkChevron>
<ExternalLinkChevron href={YIELD_APP_LINK}>App</ExternalLinkChevron>
<ExternalLinkChevron href="https://docs.mstable.org/">Documentation</ExternalLinkChevron>
<ExternalLinkChevron href="https://developers.mstable.org/">Developers</ExternalLinkChevron>
<LinkChevron href="/save">About Save</LinkChevron>
Expand Down
5 changes: 3 additions & 2 deletions src/components/layout/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { useToggle, useWindowScroll } from 'react-use'
import useMeasure from 'react-use/lib/useMeasure'
import styled from 'styled-components'

import { WITHDRAW_APP_LINK, YIELD_APP_LINK } from '../../constants'
import { ReactComponent as LogoSvg } from '../../images/mstable-logo.svg'
import { Colors, Constants } from '../../theme'
import { LinkButton } from '../CTA'
Expand Down Expand Up @@ -95,13 +96,13 @@ const urls: {
}[] = [
{
title: 'Open App',
href: 'https://yield.mstable.app/',
href: YIELD_APP_LINK,
isButton: true,
highlight: true,
},
{
title: 'Legacy Support',
href: 'https://withdraw.mstable.app',
href: WITHDRAW_APP_LINK,
isButton: true,
},
]
Expand Down
4 changes: 4 additions & 0 deletions src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,7 @@ export const STATS_API_ENDPOINT = 'https://api.mstable.org'

export const MTA_BUY_LINK =
'https://app.bancor.network/eth/swap?from=0x1F573D6Fb3F13d689FF844B4cE37794d79a7FF1C&to=0xa3BeD4E1c75D00fa6f4E5E6922DB7261B5E9AcD2'

export const WITHDRAW_APP_LINK = 'https://withdraw.mstable.org'
export const MTA_BURN_APP_LINK = `${WITHDRAW_APP_LINK}/burn`
export const YIELD_APP_LINK = 'https://yield.mstable.org'

0 comments on commit efa345c

Please sign in to comment.