Fix import into editor

This commit is contained in:
Rob Garrison 2017-08-20 19:25:27 -05:00
parent afc38b0bc8
commit 4e502e57eb

View File

@ -1504,8 +1504,14 @@ function fromMozillaFormat() {
}, 100);
});
function doImport() {
const replaceOldStyle = this.name === 'import-replace';
function doImport(event) {
// parserlib contained in CSSLint-worker.js
onDOMscripted(['vendor-overwrites/csslint/csslint-worker.js'])
.then(() => doImportWhenReady(event.target));
}
function doImportWhenReady(target) {
const replaceOldStyle = target.name === 'import-replace';
$('.dismiss', popup).onclick();
const mozStyle = trimNewLines(popup.codebox.getValue());
const parser = new parserlib.css.Parser();