forked from TNRIS/flood
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Disclaimer.jsx
71 lines (64 loc) · 2.38 KB
/
Disclaimer.jsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import React from 'react'
import ReactDOM from 'react-dom'
import {
Button, Dialog, DialogTitle, DialogContent, DialogActions
} from 'react-mdl'
import * as dialogPolyfill from 'dialog-polyfill'
class Disclaimer extends React.Component {
constructor(props) {
super(props);
this.state = {};
this.handleOpenDialog = this.handleOpenDialog.bind(this);
this.handleCloseDialog = this.handleCloseDialog.bind(this);
}
componentDidMount() {
this.handleOpenDialog()
const dialog = ReactDOM.findDOMNode(this.refs.disclaimer)
if (!dialog.showModal) {
dialogPolyfill.registerDialog(dialog)
}
}
handleOpenDialog() {
this.setState({
openDialog: true
});
}
handleCloseDialog() {
this.setState({
openDialog: false
});
}
render() {
return (
<div className='disclaimer__wrapper'>
<Dialog ref='disclaimer' className='disclaimer' open={this.state.openDialog}>
<DialogTitle>Legal Review and Disclaimer</DialogTitle>
<DialogContent>
<p>
The intent of the TexasFlood.org flood viewer is to assist
individuals in quickly assessing the potential flood risk during a
flooding event and to provide basic flood information before,
during and after a flood event. The data in the flood viewer
represents the best available information provided to the Texas
Water Development Board (TWDB) by its data contributors. The
information on this viewer may not be displayed in real-time and
should not be considered an "exact" representation of conditions in
your area. Neither the State of Texas nor the TWDB assumes any
legal liability or responsibility or makes any guarantees or
warranties as to the accuracy, completeness or suitability of the
information for any particular purpose. If you have any questions,
please contact us at
<a href="https://tnris.org/contact/"> https://tnris.org/contact/</a>
</p>
</DialogContent>
<DialogActions fullWidth>
<Button raised colored type='button' onClick={this.handleCloseDialog}>
I have read and agree to these terms
</Button>
</DialogActions>
</Dialog>
</div>
);
}
}
export default Disclaimer