 (defn header [app owner]
   (reify
     om/IRenderState
-    (render-state [_ {:keys [comm]}]
+    (render-state [_ {:keys [comm show-new-button]}]
       (dom/header nil
         (dom/div nil
           (dom/button #js {:id "home-button"

        (dom/div nil
          (dom/div #js {:id "header-title"} "Chat"))
        (dom/div nil
          (dom/button #js {:id "new-button"
                           :className "transparent-button"
                           :onClick #(put! comm [:navigate :new])}
                      "New"))))))

(defn leaf-chat [chat owner {:keys [chat-id]}]
  (reify

                    nil)))))))
    om/IRenderState
    (render-state [_ {:keys [comm page-id]}]
      (let [m {:init-state {:comm comm}}]
        (dom/div nil
          (dom/div #js {:id "header"}
            (om/build header app (assoc m :state {:show-new-button (= page-id nil)})))
          (dom/div #js {:id "content"}
            (case page-id
              :new (om/build new-chat app m)
              nil (om/build chat-root app m)
