fix(chats): Navigation after opening a profile link
This commit is contained in:
parent
babcd96fb6
commit
30fe558302
|
@ -212,6 +212,11 @@
|
|||
#(when (group-chat? cofx chat-id)
|
||||
(loading/load-chat % chat-id))))
|
||||
|
||||
(rf/reg-event-fx
|
||||
:chat/clear-current-chat-id
|
||||
(fn [{:keys [db]}]
|
||||
{:db (dissoc db :current-chat-id)}))
|
||||
|
||||
(rf/defn pop-to-root-and-navigate-to-chat
|
||||
{:events [:chat/pop-to-root-and-navigate-to-chat]}
|
||||
[cofx chat-id animation]
|
||||
|
|
|
@ -57,6 +57,7 @@
|
|||
chat-screen-layout-calculations-complete?}]
|
||||
(when *screen-loaded?*
|
||||
(rn/use-mount #(reset! *screen-loaded?* true)))
|
||||
(rn/use-unmount #(rf/dispatch [:chat/clear-current-chat-id]))
|
||||
(when-not (if *screen-loaded?* @*screen-loaded?* screen-loaded?)
|
||||
(reanimated/set-shared-value chat-screen-layout-calculations-complete? false)
|
||||
(reanimated/set-shared-value distance-from-list-top 0)
|
||||
|
|
Loading…
Reference in New Issue