import bindAll from 'lodash.bindall'; import React from 'react'; import PaperCanvas from '../containers/paper-canvas.jsx'; import BrushMode from '../containers/brush-mode.jsx'; import EraserMode from '../containers/eraser-mode.jsx'; import PropTypes from 'prop-types'; import LineMode from '../containers/line-mode.jsx'; import {defineMessages, injectIntl, intlShape} from 'react-intl'; import BufferedInputHOC from './forms/buffered-input-hoc.jsx'; import Label from './forms/label.jsx'; import Input from './forms/input.jsx'; import styles from './paint-editor.css'; const BufferedInput = BufferedInputHOC(Input); const messages = defineMessages({ costume: { id: 'paint.paintEditor.costume', description: 'Label for the name of a sound', defaultMessage: 'Costume' }, fill: { id: 'paint.paintEditor.fill', description: 'Label for the color picker for the fill color', defaultMessage: 'Fill' }, outline: { id: 'paint.paintEditor.outline', description: 'Label for the color picker for the outline color', defaultMessage: 'Outline' } }); class PaintEditorComponent extends React.Component { constructor (props) { super(props); bindAll(this, [ 'setCanvas' ]); this.state = {}; } setCanvas (canvas) { this.setState({canvas: canvas}); } render () { return (
{/* First row */}
{/* Name field */}
{/* Undo/Redo */}
{/* To be Front/back */}
{/* To be Group/Ungroup */}
{/* Second Row */}
{/* To be fill */}
{/* To be stroke */}
Mode tools
{/* Modes */} {this.state.canvas ? (
) : null} {/* Canvas */}
); } } PaintEditorComponent.propTypes = { intl: intlShape, onUpdateSvg: PropTypes.func.isRequired, rotationCenterX: PropTypes.number, rotationCenterY: PropTypes.number, svg: PropTypes.string }; export default injectIntl(PaintEditorComponent);