1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-12-02 05:57:29 +01:00

Merge pull request #1670 from oceanprotocol/remove_v3_link

Remove v3 link
This commit is contained in:
Ana 2022-09-02 14:10:31 +03:00 committed by GitHub
commit e29b153589
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,7 +1,6 @@
import React, { ReactElement } from 'react' import React, { ReactElement } from 'react'
import Link from 'next/link' import Link from 'next/link'
import loadable from '@loadable/component' import loadable from '@loadable/component'
import Badge from '@shared/atoms/Badge'
import Logo from '@shared/atoms/Logo' import Logo from '@shared/atoms/Logo'
import UserPreferences from './UserPreferences' import UserPreferences from './UserPreferences'
import Networks from './UserPreferences/Networks' import Networks from './UserPreferences/Networks'
@ -9,8 +8,6 @@ import SearchBar from './SearchBar'
import styles from './Menu.module.css' import styles from './Menu.module.css'
import { useRouter } from 'next/router' import { useRouter } from 'next/router'
import { useMarketMetadata } from '@context/MarketMetadata' import { useMarketMetadata } from '@context/MarketMetadata'
import Tooltip from '@shared/atoms/Tooltip'
import Caret from '@images/caret.svg'
const Wallet = loadable(() => import('./Wallet')) const Wallet = loadable(() => import('./Wallet'))
declare type MenuItem = { declare type MenuItem = {
@ -34,7 +31,7 @@ function MenuLink({ item }: { item: MenuItem }) {
} }
export default function Menu(): ReactElement { export default function Menu(): ReactElement {
const { appConfig, siteContent } = useMarketMetadata() const { siteContent } = useMarketMetadata()
return ( return (
<nav className={styles.menu}> <nav className={styles.menu}>
@ -45,31 +42,6 @@ export default function Menu(): ReactElement {
</a> </a>
</Link> </Link>
<Tooltip
className={styles.badgeWrap}
content={
<div className={styles.versions}>
<a className={styles.link} href={appConfig.v3MarketUri}>
v3
</a>
<a className={styles.link} href="" aria-current aria-disabled>
v4
</a>
</div>
}
trigger="click focus"
placement="bottom"
>
<Badge
className={styles.badge}
label={
<>
v4 <Caret aria-hidden="true" className={styles.caret} />
</>
}
/>
</Tooltip>
<ul className={styles.navigation}> <ul className={styles.navigation}>
{siteContent?.menu.map((item: MenuItem) => ( {siteContent?.menu.map((item: MenuItem) => (
<li key={item.name}> <li key={item.name}>