                     :icon :remove
                     :title "Click here to cancel this transaction"})]]))
 
+(defn- account-header
+  [{:keys [account]}]
+  [:h1 (:name @account)])
+
 (defn- show-account
   [id]
-  (let [context {:account (r/atom nil)
-                 :transaction (r/atom nil)
-                 :items (r/atom nil)}]
+  (let [{:keys [account] :as context} {:account (r/atom nil)
+                                       :transaction (r/atom nil)
+                                       :items (r/atom nil)}]
     (load-accounts)
     (accounts/get-one id
                       (fn [a]

       "Simple Entry"]
      [:a {:href "#"
           :on-click #(new-transaction context :full)}
       "Full Entry"]]]
    (util/space)
    (util/link-to "Back"
                  "/accounts"
                  {:icon :hand-left
                   :class "btn btn-info"
                   :title "Click here to return to the account list."})]
   [:h1 (:name @account)]])

(defn- item-row
  [item]

  (with-retry
    (.focus (.getElementById js/document "transaction-date"))))

(defn- account-buttons
  [{:keys [transaction] :as context}]
  [:div
   [:div.btn-group.dropup
    [:button {:type :button
              :class ["btn"
                      "btn-primary"
                      "dropdown-toggle"]
              :data-toggle :dropdown
              :aria-haspopup true
              :aria-expanded false
              :disabled (not (nil? @transaction))}
     [:span.glyphicon.glyphicon-plus]
     (util/space)
     "New"
