                    (fn []
                      (modal/show!
                       confirm-dialog
-                      {:on-accept #(st/emit! (dlib/delete-item :images library-id id))
+                      {:on-accept #(do
+                                     (st/emit! (dlib/delete-item :images library-id id))
+                                     (on-delete id))
                        :message "Are you sure you want to delete this image?"
                        :accept-text "Delete"}))]]}]]]))
 
 (mf/defc library-color-card
-  [{:keys [item on-select on-unselect]}]
-  (let [{:keys [ id content library-id modified-at]} item
+  [{:keys [item on-select on-unselect on-delete]}]
+  (let [{:keys [id content library-id modified-at]} item
         locale (i18n/use-locale)
-        state (mf/use-state {:is-open false})
+        state (mf/use-state {:is-open false :selected false})
         handle-change (fn []
                         (swap! state update :selected not)
                         (if (:selected @state)

          :library-id library-id
          :team-id team-id
          :on-delete-selected
          (fn []
            (when (-> @state :selected count (> 0))
              (modal/show!
               confirm-dialog
               {:on-accept #(st/emit! (dlib/batch-delete-item section library-id (:selected @state)))
                :message (str "Are you sure you want to delete " (-> @state :selected count) " items?")
                :accept-text "Delete"})
              )
            )
          }]
        [:*
         (if (> (count items) 0)
           [:div.library-page-cards-container

                    props {:item item
                           :key (:id item)
                           :on-select #(swap! state update :selected conj %)
                           :on-unselect #(swap! state update :selected disj %)
                           :on-delete #(swap! state update :selected disj %)}]
                (case section
                  :icons [:& library-icon-card props]
                  :images [:& library-image-card props]
