2016-08-10 11:39:01 +02:00
|
|
|
import React from 'react'
|
2017-03-02 16:31:24 +01:00
|
|
|
import { Route, IndexRoute, Link } from 'react-router'
|
2016-08-10 11:39:01 +02:00
|
|
|
import Layout from './containers/Layout'
|
2016-11-15 19:46:17 +01:00
|
|
|
import Home from './containers/Home'
|
2016-11-16 11:22:28 +01:00
|
|
|
import Rule from './components/Rule'
|
2017-04-10 15:55:18 +02:00
|
|
|
import SimulationCDD from './components/SimulationCDD'
|
|
|
|
import SimulationNet from './components/SimulationNet'
|
2017-03-09 19:10:28 +01:00
|
|
|
import CDDIntro from './components/CDDIntro'
|
2016-08-10 11:39:01 +02:00
|
|
|
|
2017-03-02 16:31:24 +01:00
|
|
|
|
|
|
|
let RouteNotFound = () =>
|
|
|
|
<div style={{color: '#333350', margin: '15% auto', width: '15em', textAlign: 'center'}}>
|
|
|
|
<h2>
|
|
|
|
On peut facilement se perdre dans la législation...
|
|
|
|
</h2>
|
|
|
|
<Link to="/">
|
|
|
|
{/* TODO: credits for the image to add: https://thenounproject.com/term/treasure-map/96666/ */}
|
|
|
|
<img style={{margin: '3%'}} width="250px" src={require('./images/map-directions.png')} />
|
|
|
|
Revenir en lieu sûr
|
|
|
|
</Link>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
2016-08-10 11:39:01 +02:00
|
|
|
export default (
|
|
|
|
<Route path="/" component={Layout}>
|
2016-12-07 19:08:10 +01:00
|
|
|
<Route path="regle/:name" component={Rule} />
|
2017-03-09 19:10:28 +01:00
|
|
|
<Route path="cdd-intro" component={CDDIntro} />
|
2017-04-10 15:55:18 +02:00
|
|
|
<Route path="cdd" component={SimulationCDD} />
|
|
|
|
<Route path="net" component={SimulationNet} />
|
2016-11-15 19:46:17 +01:00
|
|
|
<IndexRoute component={Home} />
|
2017-03-02 16:31:24 +01:00
|
|
|
<Route path="*" component={RouteNotFound} />
|
2016-08-10 11:39:01 +02:00
|
|
|
</Route>
|
|
|
|
)
|