mirror of
https://github.com/oceanprotocol/market.git
synced 2024-06-29 00:57:50 +02:00
96296008c9
* add custom network * created announcement banner * add custom network from banner * show ADD CUSTOM NETWORK on MetaMask provider * show add ocean to wallet action * removed warningPolygon from alert * removed customNetwork component * remove Add custom network on asset details page * Details use function from web3 to add token * changed available on Polygon link, refactoring * show Switch to Polygon when no wallet connected * banner content for no provider and Polygon network * change message when not provider and eth network * changed warning and added announcement in site.json * moved network logic inside Announcement, moved Announcement component * added switch to ETH button, refactoring * removed add mOcean action button * moved location verification to App.tsx * styling & copy updates Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
66 lines
1.2 KiB
TypeScript
66 lines
1.2 KiB
TypeScript
import { useStaticQuery, graphql } from 'gatsby'
|
|
|
|
const query = graphql`
|
|
query {
|
|
site {
|
|
siteMetadata {
|
|
siteTitle
|
|
siteTagline
|
|
siteUrl
|
|
siteIcon
|
|
copyright
|
|
menu {
|
|
name
|
|
link
|
|
}
|
|
warning {
|
|
main
|
|
polygonPublish
|
|
}
|
|
announcement {
|
|
main
|
|
polygon
|
|
}
|
|
appConfig {
|
|
infuraProjectId
|
|
network
|
|
marketFeeAddress
|
|
currencies
|
|
portisId
|
|
allowFixedPricing
|
|
allowDynamicPricing
|
|
}
|
|
}
|
|
}
|
|
|
|
siteImage: allFile(filter: { relativePath: { eq: "site.json" } }) {
|
|
edges {
|
|
node {
|
|
childContentJson {
|
|
site {
|
|
siteImage {
|
|
childImageSharp {
|
|
original {
|
|
src
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
`
|
|
|
|
export function useSiteMetadata() {
|
|
const data = useStaticQuery(query)
|
|
|
|
const siteMeta = {
|
|
...data.siteImage.edges[0].node.childContentJson.site,
|
|
...data.site.siteMetadata
|
|
}
|
|
|
|
return siteMeta
|
|
}
|