feature #1996 - navigation from status author name or profile image to profile screen
This commit is contained in:
parent
8886bfd5d0
commit
feed287457
|
@ -69,15 +69,17 @@
|
||||||
:style styles/discover-item-status-text
|
:style styles/discover-item-status-text
|
||||||
:status status}]
|
:status status}]
|
||||||
[react/view styles/discover-list-item-second-row
|
[react/view styles/discover-list-item-second-row
|
||||||
|
[react/touchable-highlight {:on-press #(re-frame/dispatch [:show-status-author-profile whisper-id])}
|
||||||
[react/view styles/discover-list-item-name-container
|
[react/view styles/discover-list-item-name-container
|
||||||
[react/view styles/discover-list-item-avatar-container
|
[react/view styles/discover-list-item-avatar-container
|
||||||
[chat-icon/chat-icon
|
[chat-icon/chat-icon
|
||||||
(display-image me? account-photo-path contact-photo-path photo-path whisper-id)
|
(display-image me? account-photo-path contact-photo-path photo-path whisper-id)
|
||||||
{:size 24}]]
|
{:size 24}]]
|
||||||
|
[react/view
|
||||||
[react/text {:style styles/discover-list-item-name
|
[react/text {:style styles/discover-list-item-name
|
||||||
:font :medium
|
:font :medium
|
||||||
:number-of-lines 1}
|
:number-of-lines 1}
|
||||||
(display-name me? account-name contact-name name whisper-id)]]
|
(display-name me? account-name contact-name name whisper-id)]]]]
|
||||||
|
|
||||||
(when-not me?
|
(when-not me?
|
||||||
(chat-button whisper-id))]
|
(chat-button whisper-id))]
|
||||||
|
@ -101,15 +103,17 @@
|
||||||
:style styles/discover-item-status-text
|
:style styles/discover-item-status-text
|
||||||
:status status}]
|
:status status}]
|
||||||
[react/view styles/discover-list-item-second-row
|
[react/view styles/discover-list-item-second-row
|
||||||
|
[react/touchable-highlight {:on-press #(re-frame/dispatch [:show-status-author-profile whisper-id])}
|
||||||
[react/view styles/discover-list-item-name-container
|
[react/view styles/discover-list-item-name-container
|
||||||
[react/view styles/discover-list-item-avatar-container
|
[react/view styles/discover-list-item-avatar-container
|
||||||
[chat-icon/chat-icon
|
[chat-icon/chat-icon
|
||||||
(display-image me? account-photo-path contact-photo-path photo-path whisper-id)
|
(display-image me? account-photo-path contact-photo-path photo-path whisper-id)
|
||||||
{:size 24}]]
|
{:size 24}]]
|
||||||
|
[react/view
|
||||||
[react/text {:style styles/discover-list-item-name
|
[react/text {:style styles/discover-list-item-name
|
||||||
:font :medium
|
:font :medium
|
||||||
:number-of-lines 1}
|
:number-of-lines 1}
|
||||||
(display-name me? account-name contact-name name whisper-id)]]
|
(display-name me? account-name contact-name name whisper-id)]]]]
|
||||||
|
|
||||||
(when-not me?
|
(when-not me?
|
||||||
(chat-button whisper-id))]]
|
(chat-button whisper-id))]]
|
||||||
|
|
|
@ -146,3 +146,9 @@
|
||||||
(u/side-effect!
|
(u/side-effect!
|
||||||
(fn [_ _]
|
(fn [_ _]
|
||||||
(discoveries/delete :created-at :asc 1000 200))))
|
(discoveries/delete :created-at :asc 1000 200))))
|
||||||
|
|
||||||
|
(handlers/register-handler-fx
|
||||||
|
:show-status-author-profile
|
||||||
|
(fn [{db :db} [_ identity]]
|
||||||
|
{:db (assoc db :contacts/identity identity)
|
||||||
|
:dispatch [:navigate-to :profile]}))
|
||||||
|
|
Loading…
Reference in New Issue