Skip to content

Commit

Permalink
remove unstable react ID
Browse files Browse the repository at this point in the history
  • Loading branch information
Kah0ona committed Aug 31, 2020
1 parent c8ecc86 commit 1435d75
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion project.clj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(defproject re-dnd "0.1.16"
(defproject re-dnd "0.1.17"

:description "A configurable drag/drop widget + API for re-frame apps"
:url "https://github.com/Kah0ona/re-dnd.git"
Expand Down
6 changes: 3 additions & 3 deletions src/cljs/re_dnd/views.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
:on-mouse-up (partial reorder-fn id (:id de))})
(when (:three-part-drag-handle @options)
[:i.zmdi.zmdi-caret-up
{:on-click #(rf/dispatch [:dnd/move-up dz-id id])}])
{:on-click #(rf/dispatch [:dnd/move-up id (:id de)])}])
(when (:three-part-drag-handle @options)
[:i.zmdi.zmdi-menu
{:on-mouse-over (partial hover-fn (:id de) id true)
Expand All @@ -96,10 +96,10 @@
:on-mouse-up (partial reorder-fn (:id de) id)}])
(when (:three-part-drag-handle @options)
[:i.zmdi.zmdi-caret-down
{:on-click #(rf/dispatch [:dnd/move-down dz-id id])}])
{:on-click #(rf/dispatch [:dnd/move-down id (:id de)])}])
[drag-handle de]]
[:div.dropped-element-body.col-md-11
^{:key (hash de)} ;;force rerender everytime `de` changes. since it's an multimethods, this might otherwise fail sometimes.
^{:key (:id de)#_(hash de)} ;;force rerender everytime `de` changes. since it's an multimethod, this might otherwise fail sometimes.
[dropped-widget de]]
[:div {:style {:clear :both}}]])))

Expand Down

0 comments on commit 1435d75

Please sign in to comment.