Change header based on page
This commit is contained in:
parent
04cd56daa8
commit
307e8349f3
|
@ -56,7 +56,21 @@ class App extends React.Component {
|
||||||
<Router>
|
<Router>
|
||||||
<div className='container menu'>
|
<div className='container menu'>
|
||||||
<p>
|
<p>
|
||||||
|
<Switch>
|
||||||
|
<Route path='/' exact>
|
||||||
<Link to='/'>QotNews - Feed</Link>
|
<Link to='/'>QotNews - Feed</Link>
|
||||||
|
</Route>
|
||||||
|
<Route path='/search'>
|
||||||
|
<Link to='/'>QotNews - Search</Link>
|
||||||
|
</Route>
|
||||||
|
<Route path='/:id' exact>
|
||||||
|
<Link to='/'>QotNews - Article</Link>
|
||||||
|
</Route>
|
||||||
|
<Route path='/:id/c'>
|
||||||
|
<Link to='/'>QotNews - Comments</Link>
|
||||||
|
</Route>
|
||||||
|
</Switch>
|
||||||
|
|
||||||
<span className='theme'>Theme: <a href='#' onClick={() => this.light()}>Light</a> - <a href='#' onClick={() => this.dark()}>Dark</a></span>
|
<span className='theme'>Theme: <a href='#' onClick={() => this.light()}>Light</a> - <a href='#' onClick={() => this.dark()}>Dark</a></span>
|
||||||
<br />
|
<br />
|
||||||
<span className='slogan'>Hacker News, Reddit, Lobsters, and Tildes articles rendered in reader mode.</span>
|
<span className='slogan'>Hacker News, Reddit, Lobsters, and Tildes articles rendered in reader mode.</span>
|
||||||
|
|
|
@ -68,7 +68,7 @@ class Article extends React.Component {
|
||||||
<div className='article'>
|
<div className='article'>
|
||||||
<Helmet>
|
<Helmet>
|
||||||
<title>{story.title} - QotNews</title>
|
<title>{story.title} - QotNews</title>
|
||||||
<meta name="robots" content="noindex">
|
<meta name="robots" content="noindex" />
|
||||||
</Helmet>
|
</Helmet>
|
||||||
|
|
||||||
<h1>{story.title}</h1>
|
<h1>{story.title}</h1>
|
||||||
|
|
|
@ -116,6 +116,7 @@ class Article extends React.Component {
|
||||||
<div className='article'>
|
<div className='article'>
|
||||||
<Helmet>
|
<Helmet>
|
||||||
<title>{story.title} - QotNews Comments</title>
|
<title>{story.title} - QotNews Comments</title>
|
||||||
|
<meta name="robots" content="noindex" />
|
||||||
</Helmet>
|
</Helmet>
|
||||||
|
|
||||||
<h1>{story.title}</h1>
|
<h1>{story.title}</h1>
|
||||||
|
|
|
@ -53,7 +53,7 @@ class Feed extends React.Component {
|
||||||
<div className='container'>
|
<div className='container'>
|
||||||
<Helmet>
|
<Helmet>
|
||||||
<title>Feed - QotNews</title>
|
<title>Feed - QotNews</title>
|
||||||
<meta name="robots" content="index">
|
<meta name="robots" content="index" />
|
||||||
</Helmet>
|
</Helmet>
|
||||||
{error && <p>Connection error?</p>}
|
{error && <p>Connection error?</p>}
|
||||||
{stories ?
|
{stories ?
|
||||||
|
|
Loading…
Reference in New Issue
Block a user