fix navigation to community from discover communities screen (#16702)
This commit is contained in:
parent
0067468d57
commit
bb3b3061c6
|
@ -28,12 +28,12 @@
|
||||||
cover {:uri (get-in (:images item) [:banner :uri])}]
|
cover {:uri (get-in (:images item) [:banner :uri])}]
|
||||||
(if (= view-type :card-view)
|
(if (= view-type :card-view)
|
||||||
[quo/community-card-view-item (assoc item :width width :cover cover)
|
[quo/community-card-view-item (assoc item :width width :cover cover)
|
||||||
#(rf/dispatch [:navigate-to :community-overview (:id item)])]
|
#(rf/dispatch [:communities/navigate-to-community (:id item)])]
|
||||||
[quo/community-list-item
|
[quo/community-list-item
|
||||||
{:on-press (fn []
|
{:on-press (fn []
|
||||||
(rf/dispatch [:communities/load-category-states (:id item)])
|
(rf/dispatch [:communities/load-category-states (:id item)])
|
||||||
(rf/dispatch [:dismiss-keyboard])
|
(rf/dispatch [:dismiss-keyboard])
|
||||||
(rf/dispatch [:navigate-to :community-overview (:id item)]))
|
(rf/dispatch [:communities/navigate-to-community (:id item)]))
|
||||||
:on-long-press #(rf/dispatch
|
:on-long-press #(rf/dispatch
|
||||||
[:show-bottom-sheet
|
[:show-bottom-sheet
|
||||||
{:content (fn []
|
{:content (fn []
|
||||||
|
@ -141,12 +141,12 @@
|
||||||
(merge community
|
(merge community
|
||||||
(get mock-community-item-data :data)
|
(get mock-community-item-data :data)
|
||||||
{:cover cover})
|
{:cover cover})
|
||||||
#(rf/dispatch [:navigate-to :community-overview (:id community)])]
|
#(rf/dispatch [:communities/navigate-to-community (:id community)])]
|
||||||
[quo/community-list-item
|
[quo/community-list-item
|
||||||
{:on-press (fn []
|
{:on-press (fn []
|
||||||
(rf/dispatch [:communities/load-category-states (:id community)])
|
(rf/dispatch [:communities/load-category-states (:id community)])
|
||||||
(rf/dispatch [:dismiss-keyboard])
|
(rf/dispatch [:dismiss-keyboard])
|
||||||
(rf/dispatch [:navigate-to :community-overview (:id community)]))
|
(rf/dispatch [:communities/navigate-to-community (:id community)]))
|
||||||
:on-long-press #(js/alert "TODO: to be implemented")}
|
:on-long-press #(js/alert "TODO: to be implemented")}
|
||||||
(merge community
|
(merge community
|
||||||
(get mock-community-item-data :data))])]))
|
(get mock-community-item-data :data))])]))
|
||||||
|
|
Loading…
Reference in New Issue