@@ -28,36 +28,53 @@ class TimerView extends React.Component<{appState: AppState}, {}> {
2828 this . props . appState . resetTimer ( ) ;
2929 }
3030}
31- ;
3231
33- var PanZoom = React . createClass ( {
34- render : function ( ) {
32+ class Toolbar extends React . Component < { } , { } > {
33+ render ( ) {
3534 return (
36-
3735 < div className = "cy-panzoom" style = { { position : 'absolute' } } >
36+ < Pan />
37+ < Slider />
38+ </ div >
39+ ) ;
40+ }
41+ }
42+
43+ class Slider extends React . Component < { } , { } > {
44+ render ( ) {
45+ return (
46+ < div >
47+ < div className = "cy-panzoom-reset cy-panzoom-zoom-button" > < span className = "icon fa fa-expand" /> </ div >
3848 < div className = "cy-panzoom-zoom-in cy-panzoom-zoom-button" > < span className = "icon fa fa-plus" /> </ div >
3949 < div className = "cy-panzoom-zoom-out cy-panzoom-zoom-button" > < span className = "icon fa fa-minus" /> </ div >
40- < div className = "cy-panzoom-reset cy-panzoom-zoom-button" > < span className = "icon fa fa-expand" /> </ div >
4150 < div className = "cy-panzoom-slider" >
4251 < div className = "cy-panzoom-slider-background" />
4352 < div className = "cy-panzoom-slider-handle" style = { { top : '32.2203px' } } > < span className = "icon fa fa-minus" />
4453 </ div >
4554 < div className = "cy-panzoom-no-zoom-tick" style = { { top : 43 } } />
4655 </ div >
47- < div className = "cy-panzoom-panner" >
48- < div className = "cy-panzoom-panner-handle" />
49- < div className = "cy-panzoom-pan-up cy-panzoom-pan-button" />
50- < div className = "cy-panzoom-pan-down cy-panzoom-pan-button" />
51- < div className = "cy-panzoom-pan-left cy-panzoom-pan-button" />
52- < div className = "cy-panzoom-pan-right cy-panzoom-pan-button" />
53- < div className = "cy-panzoom-pan-indicator" style = { { display : 'none' } } />
54- </ div >
5556 </ div >
56- ) ;
57+ )
58+ }
59+ }
60+
61+ class Pan extends React . Component < { } , { } > {
62+ render ( ) {
63+ return (
64+ < div className = "cy-panzoom-panner" >
65+ < div className = "cy-panzoom-panner-handle" />
66+ < div className = "cy-panzoom-pan-up cy-panzoom-pan-button" />
67+ < div className = "cy-panzoom-pan-down cy-panzoom-pan-button" />
68+ < div className = "cy-panzoom-pan-left cy-panzoom-pan-button" />
69+ < div className = "cy-panzoom-pan-right cy-panzoom-pan-button" />
70+ < div className = "cy-panzoom-pan-indicator" style = { { display : 'none' } } />
71+ </ div >
72+ )
5773 }
58- } ) ;
74+ }
75+
5976
60- ReactDOM . render ( < PanZoom /> , document . getElementById ( 'root' ) ) ;
77+ ReactDOM . render ( < Toolbar /> , document . getElementById ( 'root' ) ) ;
6178
6279// const appState = new AppState();
6380// ReactDOM.render(<TimerView appState={appState}/>, document.getElementById('root'));
0 commit comments