-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.js
75 lines (58 loc) · 1.69 KB
/
app.js
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
72
73
74
75
import PropTypes from 'prop-types';
import React from 'react';
import ReactDom from 'react-dom';
import $ from 'jquery';
import Header from './Components/header';
//import TreeContainer from './Components/treeContainer';
import json from './json';
import Store from './Reducers/store';
import { connect, Provider } from 'react-redux';
import { resize } from './Reducers/actions';
import './style.css';
import './selection_style.css';
import ReactTooltip from 'react-tooltip';
import TreeContainer from './Components/treeContainer';
//import Detail from './Components/detail';
$(window).on('resize', resize);
const propTypes = {
activeNode: PropTypes.string,
filter: PropTypes.string.isRequired,
height: PropTypes.number.isRequired,
width: PropTypes.number.isRequired
};
class App extends React.PureComponent {
render() {
return (
<div id="container">
<p id="header" className="mainHeader">Microscopy image type selection tree</p>
<TreeContainer
activeNode={this.props.activeNode}
data={json}
filter={this.props.filter}
height={this.props.height}
width={this.props.width}/>
<footer id="footer" className="mainFooter">Copyright (©) 2021 BIOMAG group. All rights reserved.</footer>
</div>
);
}
/*
// working version:
<div id="container">
<p>Microscopy image type selection tree</p>
<TreeContainer
activeNode={this.props.activeNode}
data={json}
filter={this.props.filter}
height={this.props.height}
width={this.props.width}/>
</div>
*/
}
App.propTypes = propTypes;
App = connect(state => state)(App);
ReactDom.render(
<Provider store={Store}>
<App/>
</Provider>,
document.getElementById('app')
);