|
|
|
@ -99,14 +99,21 @@ class CompileTab extends CompilerApi { |
|
|
|
|
|
|
|
|
|
this.fileManager.events.on('currentFileChanged', (name) => { |
|
|
|
|
this.compilerContainer.currentFile = name |
|
|
|
|
cleanupErrors() |
|
|
|
|
onContentChanged() |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
this.fileManager.events.on('noFileSelected', () => { |
|
|
|
|
this.compilerContainer.currentFile = '' |
|
|
|
|
cleanupErrors() |
|
|
|
|
onContentChanged() |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
const cleanupErrors = () => { |
|
|
|
|
this._view.errorContainer.innerHTML = '' |
|
|
|
|
this.events.emit('statusChanged', {key: '', title: '', type: ''}) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
this.compiler.event.register('compilationFinished', (success, data, source) => { |
|
|
|
|
if (success) { |
|
|
|
|
// forwarding the event to the appManager infra
|
|
|
|
@ -259,7 +266,7 @@ class CompileTab extends CompilerApi { |
|
|
|
|
var result = yo`<div>${uploaded.map((value) => { |
|
|
|
|
return yo`<div><b>${value.filename}</b> : <pre>${value.output.url}</pre></div>` |
|
|
|
|
})}</div>` |
|
|
|
|
modalDialogCustom.alert(yo`<span>Metadata published successfully.<br> <pre>${result}</pre> </span>`) |
|
|
|
|
modalDialogCustom.alert(yo`<span>Metadata published successfully.<br> <span>${result}</span> </span>`) |
|
|
|
|
} |
|
|
|
|
}, (item) => { // triggered each time there's a new verified publish (means hash correspond)
|
|
|
|
|
this.swarmfileProvider.addReadOnly(item.hash, item.content) |
|
|
|
|