Added privacy policy

This commit is contained in:
2019-06-14 15:11:15 +10:00
parent 862867e1a6
commit 53be16399a
6 changed files with 80 additions and 3 deletions
+1
View File
@@ -80,6 +80,7 @@ export default class App extends React.Component {
<LazyRoute path='/news' component={() => import('./pages/news_index.jsx')} />
<LazyRoute path='/rules' component={() => import('./pages/rules.jsx')} />
<LazyRoute path='/statistics' component={() => import('./pages/statistics.jsx')} />
<LazyRoute path='/privacypolicy' component={() => import('./pages/privacy_policy.jsx')} />
<LazyRoute path='*' component={() => import('./pages/page_not_found.jsx')} />
</Switch>
+44
View File
@@ -0,0 +1,44 @@
import React from 'react';
//panels
import CommonLinks from '../panels/common_links.jsx';
import MarkdownPanel from '../panels/markdown.jsx';
class PrivacyPolicy extends React.Component { //NOTE: react isn't liking the generic markdown_page.jsx class
constructor(props) {
super(props);
this.state = {
warning: '' //TODO: unified warning?
};
}
render() {
let warningStyle = {
display: this.state.warning.length > 0 ? 'flex' : 'none'
};
return (
<div className='page'>
<div className='sidePanelPage'>
<div className='sidePanel'>
<CommonLinks />
</div>
<div className='mainPanel'>
<div className='warning' style={warningStyle}>
<p>{this.state.warning}</p>
</div>
<MarkdownPanel url={'/content/privacy_policy.md'} />
</div>
</div>
</div>
);
}
setWarning(s) {
this.setState({ warning: s });
}
};
export default PrivacyPolicy;
+1 -1
View File
@@ -4,7 +4,7 @@ class Footer extends React.Component {
render() {
return (
<footer>
<p>Copyright <a href='https://krgamestudios.com'>KR Game Studios</a> 2019</p>
<p>Copyright <a href='https://krgamestudios.com'>KR Game Studios</a> 2019 - <a href='/privacypolicy'>Privacy Policy</a></p>
</footer>
);
}