                (dom/button #js {:onClick #(dequeue-track index)}
                            "-")))))
 
-(defn minimised-queue-view [app owner]
+(defn audio-el [app owner]
   (reify
     om/IDidMount
     (did-mount [this]

         (if (:viewing-queue? state)
           (om/build queue-view state)
           (om/build minimised-queue-view state))]
        [:audio {:ref "player"}]]))))

(defn init []
  (add-watch app-state :transport sync-transport)

        ;; http://stackoverflow.com/questions/11291651/why-dont-audio-and-video-events-bubble
        (.addEventListener el "ended" player-next true)
        (.addEventListener el "timeupdate" player-playing true)))
    om/IRender
    (render [this]
      (html [:audio {:ref "player"}]))))

(defn minimised-queue-view [app owner]
  (reify
    om/IRender
    (render [this]
      (let [queue (om/observe owner (player-queue))]
