Ajout d'un message de mise à jour du site

pull/138/head
mama 2017-12-21 16:44:15 +01:00
parent 4823127b0e
commit fd1b23919a
5 changed files with 37 additions and 12 deletions

View File

@ -1,5 +1,5 @@
#targetSelection {
height: 40em;
height: 35em;
display: flex;
justify-content: space-around;
align-items: center;

View File

@ -1,4 +1,20 @@
#updateMessage {
display: flex;
align-items: center;
max-width: 30em;
margin: 0 auto;
}
#updateMessage p {
color: #4b4b66;
font-size: 85%;
transition: 0.8s opacity;
transition-delay: 0.2s;
}
#updateMessage i {
color: #2975d1;
margin-right: 1em;
transition: 0.8s opacity;
}
#home > #content {
display: flex;

View File

@ -1,21 +1,34 @@
import React, { Component } from 'react'
import './Pages.css'
import './Home.css'
import ReactPiwik from 'Components/Tracker' //TODO réintégrer Piwik
import TargetSelection from '../TargetSelection'
export default class Home extends Component {
state = {
updateMessage: false
}
componentDidMount() {
setTimeout(() => this.setState({ showUpdateMessage: true }), 1000)
}
render() {
let opacityStyle = { opacity: this.state.showUpdateMessage ? 1 : 0 }
return (
<div id="home" className="page">
<div id="updateMessage">
<i
className="fa fa-newspaper-o"
aria-hidden="true"
style={opacityStyle}
/>
<p style={opacityStyle}>
Cette nouvelle version du site vous permet de simuler un CDD ou un
CDI dans la même interface. Joyeuses fêtes !
</p>
</div>
<div id="content">
<TargetSelection />
</div>
</div>
)
}
}

View File

@ -12,11 +12,6 @@ body {
height: 100%
}
#content {
margin-top: 1.5em;
}
a {
color: inherit;
text-decoration: none;

View File

@ -78,6 +78,7 @@ let buildPossibleInversion = (rule, flatRules, targetNames) => {
),
yo = R.reject(({ name }) => targetNames.includes(name))([rule].concat(inversionObjects))
console.log('yo', yo)
return {
inversions: yo,
question: rule.formule.inversion.question