diff --git a/src/containers/paper-canvas.jsx b/src/containers/paper-canvas.jsx index b0b3216a..254e730a 100644 --- a/src/containers/paper-canvas.jsx +++ b/src/containers/paper-canvas.jsx @@ -19,6 +19,7 @@ import {ensureClockwise} from '../helper/math'; import {clearHoveredItem} from '../reducers/hover'; import {clearPasteOffset} from '../reducers/clipboard'; import {updateViewBounds} from '../reducers/view-bounds'; +import {changeFormat} from '../reducers/format'; import {isVector, isBitmap} from '../lib/format'; @@ -114,6 +115,7 @@ class PaperCanvas extends React.Component { this.props.clearHoveredItem(); this.props.clearPasteOffset(); if (svg) { + this.props.changeFormat(Formats.VECTOR); // Store the zoom/pan and restore it after importing a new SVG const oldZoom = paper.project.view.zoom; const oldCenter = paper.project.view.center.clone(); @@ -290,6 +292,9 @@ const mapDispatchToProps = dispatch => ({ clearPasteOffset: () => { dispatch(clearPasteOffset()); }, + changeFormat: format => { + dispatch(changeFormat(format)); + }, updateViewBounds: matrix => { dispatch(updateViewBounds(matrix)); }