import React from 'react' export default class extends React.Component { constructor(props) { super(props) this.handleChange = this.handleChange.bind(this) } handleChange(e) { this.props.onChange(`${e.target.value}${this.props.usePercentage ? '%' : 'px'}`) } render() { const minValue = this.props.minValue || 0 const maxValue = this.props.maxValue || 100 const step = 'step' in this.props ? this.props.step : 1; return (