 
         ;(delete-markers owner to-delete)
         (add-markers data owner to-add)
+        (reset-markers owner)
         (when (re-matches #"/collections/(\d+)/points/(\d+)" (:route-name next-props))
           (let [point-id (get-in next-props [:route-opts :point-id])]
             (activate-marker owner point-id)))))


    (.on marker "click"
      (fn []
        (.log js/console (path-to-route (om/path point)))
        (om/update! data [:drawer :open] true)
        (put! (om/get-shared owner :nav)
          [:route (path-to-route (om/path point))])))

  (-> icon .-options .-icon (set! "ion-ios-circle-filled"))
  icon)

(defn reset-markers [owner]
  (let [markers (om/get-state owner :markers)]
    (dorun
      (map #(.setIcon (:marker %) (reset-ico (:icon %))) markers))))

(defn activate-marker
  [owner id]
  (let [l-map (om/get-state owner :map)
        active (om/get-state owner [:markers id])]
    (when active
      (do (.setIcon (:marker active) (activate-ico (:icon active)))
          (.panTo l-map (.getLatLng (:marker active)))))))
