Page MenuHomePhabricator

[native] Fix reply not working in search results

Authored by inka on May 23 2023, 6:23 AM.
Referenced Files
Unknown Object (File)
Fri, Jun 14, 1:34 PM
Unknown Object (File)
Thu, Jun 13, 9:56 PM
Unknown Object (File)
Thu, Jun 13, 4:41 PM
Unknown Object (File)
Sun, Jun 9, 9:51 PM
Unknown Object (File)
Sun, Jun 9, 6:56 PM
Unknown Object (File)
Sat, Jun 8, 10:10 AM
Unknown Object (File)
Sat, Jun 8, 4:53 AM
Unknown Object (File)
Fri, Jun 7, 9:23 PM



Reply from within the search screen didn't work. We need to navigate back to the thread to be able to reply.
Adding MessageSearchRouteName to threadRoutes is necessary, because we don't want chat input bar to remove its listener for input state events, which happens if activeThreadSelector returns null or an id of a different thread (see isActive variable in chat-input-bar.react.js). activeThreadSelector returns null if threadRoutes doesn't contain the current route name.
ThreadSettingsRouteName is also in threadRoutes, and the search screen is used in a similar fashion to thread settings screen.

Test Plan

Pressed "reply" on the search screen. Checked that the correct thread was opened and the input bar message was prepended with the reply.

Diff Detail

rCOMM Comm
Lint Not Applicable
Tests Not Applicable

Event Timeline

inka requested review of this revision.May 23 2023, 6:41 AM
inka planned changes to this revision.May 23 2023, 8:15 AM
38 ↗(On Diff #26903)

We already have route variable, we can probably use it.

Thanks for explaining everything!

This revision is now accepted and ready to land.May 23 2023, 11:57 AM