scratch-paint/src/containers/stroke-width-indicator.jsx

18 lines
525 B
React
Raw Normal View History

2017-09-08 11:52:36 -04:00
import {connect} from 'react-redux';
import {changeStrokeWidth} from '../reducers/stroke-width';
import StrokeWidthIndicatorComponent from '../components/stroke-width-indicator.jsx';
const mapStateToProps = state => ({
strokeWidth: state.scratchPaint.color.strokeWidth
});
const mapDispatchToProps = dispatch => ({
2017-09-11 13:54:48 -04:00
onChangeStrokeWidth: strokeWidth => {
2017-09-08 11:52:36 -04:00
dispatch(changeStrokeWidth(strokeWidth));
}
});
export default connect(
mapStateToProps,
mapDispatchToProps
2017-09-11 13:54:48 -04:00
)(StrokeWidthIndicatorComponent);