1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-10 19:29:56 +00:00
Files
seahub/frontend/src/components/main-panel.js

36 lines
946 B
JavaScript
Raw Normal View History

2018-08-30 15:10:52 +08:00
import React, { Component } from 'react';
2018-10-16 18:19:51 +08:00
import PropTypes from 'prop-types';
2018-09-21 14:16:15 +08:00
import CommonToolbar from './toolbar/common-toolbar';
2018-08-30 15:10:52 +08:00
2018-10-16 18:19:51 +08:00
const propTypes = {
children: PropTypes.object.isRequired,
onShowSidePanel: PropTypes.func.isRequired,
};
2018-08-30 15:10:52 +08:00
class MainPanel extends Component {
onSearchedClick = () => {
//todos;
}
2018-08-30 15:10:52 +08:00
render() {
return (
<div className="main-panel o-hidden">
<div className="main-panel-north">
<div className="cur-view-toolbar">
<span className="sf2-icon-menu side-nav-toggle hidden-md-up d-md-none" title="Side Nav Menu" onClick={this.props.onShowSidePanel}></span>
</div>
<CommonToolbar onSearchedClick={this.onSearchedClick} searchPlaceholder={'Search Files'}/>
</div>
<div className="main-panel-center">
2018-09-21 14:16:15 +08:00
{this.props.children}
2018-08-30 15:10:52 +08:00
</div>
</div>
);
2018-08-30 15:10:52 +08:00
}
}
2018-10-16 18:19:51 +08:00
MainPanel.propTypes = propTypes;
2018-08-30 15:10:52 +08:00
export default MainPanel;