in_el = document.getElementById 'in'
button = document.getElementById 'button'
-editor = null
-button.onclick = in_el.onchange = in_el.onkeyup = ->
- #button.value="Reload"
- if editor?
- editor.load_html in_el.value
- else
- # first run
- button.parentNode.removeChild button
- editor = peach.wysiwyg in_el
- return false
-button.value="Load"
-button.removeAttribute 'disabled'
-button.click()
+button.parentNode.removeChild button
+window.editor = peach_html5_editor in_el, css_file: 'page_dark.css'