 (ns one.sample.view.editor
-  (:use [query  :only [$]]
-        [domina :only [append! destroy-children! detach! nodes single-node]])
+  (:use [query            :only [$]]
+        [domina           :only [append! destroy-children! detach! nodes
+                                 single-node]]
+        [one.sample.model :only [docs]])
   (:require [goog.events               :as event]
             [goog.editor.Field         :as editor-iframe]
             [goog.editor.SeamlessField :as editor-div]

        redo      ($ "button#redo")
        set-html! (fn [content] (. field (setHtml false content true)))]
    (do
      (if content (set-html! content))
      (. field (makeEditable))
      (. element (focus)))

       (goog.editor/Field. element)
       (goog.editor/SeamlessField. element))))

(declare list-documents)

(defn launch [element doc-session]
  (let [field     (spawn-editor element)
        content   (doc-session :get :content)
