Make it so clicking Close unmounts the error component

This commit is contained in:
Joe Haddad
2016-12-02 22:20:51 -05:00
parent b05762f7fb
commit 2ec79cab67

View File

@@ -179,6 +179,9 @@ function sourceCodePre(sourceLines, lineNum, columnNum, main = false) {
function hintsDiv() {
const hints = document.createElement('div')
hints.appendChild(document.createTextNode('[escape] Close'))
hints.addEventListener('click', e => {
unmount()
})
applyStyles(hints, hintsStyle)
return hints
}