updateCanvas after import (#771)
* updateCanvas after import * remove test causing a race condition with Cypress on CI * fix indentmaster
parent
d5c129ee78
commit
29103ddf86
|
@ -1,14 +0,0 @@
|
|||
import {
|
||||
visitAndApproveStorage
|
||||
} from '../../../support/ui-test-helper.js'
|
||||
|
||||
// See https://github.com/SVG-Edit/svgedit/issues/364
|
||||
describe('Key commands', function () {
|
||||
beforeEach(() => {
|
||||
visitAndApproveStorage()
|
||||
})
|
||||
|
||||
it('cmd-A on empty canvas should not cause an error', function () {
|
||||
cy.get('body').type('{cmd}a')
|
||||
})
|
||||
})
|
|
@ -134,7 +134,10 @@ class Editor extends EditorStartup {
|
|||
*/
|
||||
loadSvgString (str, { noAlert } = {}) {
|
||||
const success = this.svgCanvas.setSvgString(str) !== false
|
||||
if (success) return
|
||||
if (success) {
|
||||
this.updateCanvas()
|
||||
return
|
||||
}
|
||||
if (!noAlert) seAlert(this.i18next.t('notification.errorLoadingSVG'))
|
||||
throw new Error('Error loading SVG')
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue