mirror of
https://github.com/haiwen/seahub.git
synced 2025-08-21 00:15:26 +00:00
30 lines
838 B
JavaScript
30 lines
838 B
JavaScript
|
import React from 'react';
|
||
|
import PropTypes from 'prop-types';
|
||
|
import './index.css';
|
||
|
|
||
|
function ResizeBar(props) {
|
||
|
return (
|
||
|
<div
|
||
|
className="resize-bar"
|
||
|
ref={props.resizeBarRef}
|
||
|
style={props.resizeBarStyle}
|
||
|
onMouseDown={props.onResizeMouseDown}
|
||
|
onMouseOver={props.onResizeMouseOver}
|
||
|
>
|
||
|
<div className="resize-bar-line"></div>
|
||
|
<div className="resize-bar-drag-handler" ref={props.dragHandlerRef} style={props.dragHandlerStyle}></div>
|
||
|
</div>
|
||
|
);
|
||
|
}
|
||
|
|
||
|
ResizeBar.propTypes = {
|
||
|
resizeBarRef: PropTypes.object.isRequired,
|
||
|
resizeBarStyle: PropTypes.object.isRequired,
|
||
|
dragHandlerRef: PropTypes.object.isRequired,
|
||
|
dragHandlerStyle: PropTypes.object.isRequired,
|
||
|
onResizeMouseDown: PropTypes.func.isRequired,
|
||
|
onResizeMouseOver: PropTypes.func.isRequired,
|
||
|
};
|
||
|
|
||
|
export default ResizeBar;
|