Page MenuHomePhabricator

[native] Forward `searchInputRef` from `ChatThreadList` to `ChatThreadListSearch`
ClosedPublic

Authored by atul on Sep 14 2023, 2:05 PM.
Tags
None
Referenced Files
F2207256: D9209.id31223.diff
Sun, Jul 7, 6:51 AM
Unknown Object (File)
Thu, Jul 4, 3:50 PM
Unknown Object (File)
Tue, Jul 2, 10:54 PM
Unknown Object (File)
Tue, Jul 2, 1:30 PM
Unknown Object (File)
Tue, Jul 2, 9:13 AM
Unknown Object (File)
Mon, Jul 1, 8:17 PM
Unknown Object (File)
Thu, Jun 20, 3:06 AM
Unknown Object (File)
Tue, Jun 18, 7:18 AM
Subscribers

Details

Summary

Forward ref from ChatThreadList to ChatThreadListSearch... which will in turn forward it to the inner Search component.


Depends on D9208

Test Plan

Search experience continues to look and work as expected. Set logs in all expected callbacks to ensure that they fired as expected. Made sure that x-icon and "Cancel" button continue to look and behave as before.

Diff Detail

Repository
rCOMM Comm
Branch
master
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

atul published this revision for review.Sep 14 2023, 2:06 PM
tomek added inline comments.
native/chat/chat-thread-list-search.react.js
81

Why this ref was defined here and used only as a prop?

native/chat/chat-thread-list.react.js
356

Are we sure that we're rendering at most one instance of this component? I'm wondering if using the same ref for two instances can cause some issues.

This revision is now accepted and ready to land.Sep 18 2023, 4:13 AM
native/chat/chat-thread-list-search.react.js
81

This was temporary to appease flow, etc. What we really want to do (and do in this diff) is forward ref from ChatThreadList down to the inner Search component.

native/chat/chat-thread-list.react.js
356

I believe it should be fine. This matches how things were previously.