1
0
mirror of https://github.com/oceanprotocol/commons.git synced 2023-03-15 18:03:00 +01:00

add route description

This commit is contained in:
Matthias Kretschmann 2019-02-08 14:47:23 +01:00
parent 1f28021568
commit 1bf015ea26
Signed by: m
GPG Key ID: 606EEEF3C479A91F
4 changed files with 14 additions and 5 deletions

View File

@ -7,4 +7,9 @@
h1 {
margin: 0;
}
p {
margin-top: $spacer / 2;
font-size: $font-size-large;
}
}

View File

@ -6,11 +6,13 @@ import meta from '../../data/meta.json'
const Route = ({
title,
description,
wide,
children,
className
}: {
title: string
description?: string
children: any
wide?: boolean
className?: string
@ -18,11 +20,13 @@ const Route = ({
<div className={className}>
<Helmet defaultTitle={meta.title} titleTemplate={`%s - ${meta.title}`}>
<title>{title}</title>
{description && <meta name="description" content={description} />}
</Helmet>
<Content wide={wide}>
<header className={styles.header}>
<h1>{title}</h1>
{description && <p>{description}</p>}
</header>
{children}

View File

@ -1,8 +1,4 @@
[
{
"title": "Home",
"link": "/"
},
{
"title": "Publish",
"link": "/publish"

View File

@ -18,7 +18,11 @@ class Home extends Component<HomeProps, HomeState> {
public render() {
return (
<Route title="Home" className={styles.home}>
<Route
title="Commons"
description="A marketplace to find and publish open data sets."
className={styles.home}
>
<Form onSubmit={this.searchAssets}>
<Input
type="search"