SplitLine.js 893 Bytes
import React,{PropTypes} from 'react';
import ReactDOM from 'react-dom';  
import cx from 'classnames';
import s from './breadline.scss'; 


class SplitLine extends React.Component {
    constructor(props) {
        super(props); 
    }
    static propTypes = {     
        style:PropTypes.object,
        width:PropTypes.number
    } 
    static defaultProps={    
  
    }  
    componentDidMount(){  
    }  
    componentWillReceiveProps(nextProps){   
    }
    componentDidUpdate(prevProps,prevState){  
    }
    componentWillUnmount() {  
        
    }  
    render(){     
        const {width,style}=this.props;  
        const maxWidth=`${width}px`;  
        return (
            <div  className={cx(s.split_line_wrap)}>
                <div className={cx(s.split_line)} style={{...style,width:maxWidth}}></div>
            </div>
        ) 
    }
}



export default SplitLine;