2022-06-15 00:44:44 +02:00
|
|
|
import './MenuComponent.scss';
|
2020-12-11 00:35:35 +01:00
|
|
|
|
2022-06-15 00:44:44 +02:00
|
|
|
import { FormattedMessage, injectIntl } from 'react-intl';
|
2020-12-31 17:38:30 +01:00
|
|
|
|
2023-01-20 09:33:32 +00:00
|
|
|
import React, { Component } from 'react';
|
2022-06-15 00:47:13 +02:00
|
|
|
import { URL_add_parameter } from '../../services/parameters.service';
|
2022-06-15 00:44:44 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class MenuComponent extends Component {
|
|
|
|
|
// constructor(props) {
|
|
|
|
|
// super(props);
|
|
|
|
|
// this.state = {};
|
|
|
|
|
// }
|
|
|
|
|
honhonhon() {
|
|
|
|
|
window.location.href = URL_add_parameter(window.location.href, "lang", "fr");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
heygovna() {
|
|
|
|
|
window.location.href = URL_add_parameter(window.location.href, "lang", "en");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
const buttonsLanguagesMessage = this.props.intl.messages.global.buttons.languages;
|
2022-10-31 00:37:52 +01:00
|
|
|
return <section id="menu" class="hero is-primary dontPrint">
|
2022-06-15 00:44:44 +02:00
|
|
|
<div class="hero-body">
|
|
|
|
|
<div class="container">
|
|
|
|
|
<div class="columns">
|
|
|
|
|
<div class="column">
|
|
|
|
|
<h1 class="title">
|
|
|
|
|
<FormattedMessage id="title" />
|
|
|
|
|
</h1>
|
|
|
|
|
<h2 class="subtitle">
|
|
|
|
|
<FormattedMessage id="subtitle" />
|
|
|
|
|
</h2>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="column is-hidden-touch">
|
|
|
|
|
<div id="langButtons">
|
|
|
|
|
<div class="buttons">
|
2022-07-30 14:24:33 +02:00
|
|
|
<span className="button is-light" onClick={this.honhonhon} aria-label="Visiter le site en Français">
|
2022-06-15 00:44:44 +02:00
|
|
|
{buttonsLanguagesMessage.fr}
|
|
|
|
|
</span>
|
2022-07-30 14:24:33 +02:00
|
|
|
<span className="button is-light" onClick={this.heygovna} aria-label="Visit the website in English">
|
2022-06-15 00:44:44 +02:00
|
|
|
{buttonsLanguagesMessage.en}
|
|
|
|
|
</span>
|
2020-12-31 18:22:46 +01:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2022-06-15 00:44:44 +02:00
|
|
|
</div>
|
2020-12-11 00:35:35 +01:00
|
|
|
</div>
|
2022-06-15 00:44:44 +02:00
|
|
|
|
|
|
|
|
</div>
|
2020-12-11 00:35:35 +01:00
|
|
|
</section>;
|
|
|
|
|
}
|
2022-06-15 00:44:44 +02:00
|
|
|
}
|
2020-12-11 00:35:35 +01:00
|
|
|
// export default connect(
|
|
|
|
|
// ({ MenuComponent }) => ({ ...MenuComponent }),
|
|
|
|
|
// dispatch => bindActionCreators({ ...MenuComponentActions }, dispatch)
|
2020-12-18 22:34:21 +01:00
|
|
|
// )( MenuComponent );
|
2022-06-15 00:44:44 +02:00
|
|
|
|
|
|
|
|
export default injectIntl(MenuComponent)
|