Page MenuHomePhabricator

[native] community joiner modal
Needs RevisionPublic

Authored by varun on Thu, Nov 21, 7:58 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 22, 9:16 AM
Unknown Object (File)
Thu, Nov 21, 9:05 PM
Unknown Object (File)
Thu, Nov 21, 9:05 PM
Unknown Object (File)
Thu, Nov 21, 9:05 PM
Subscribers

Details

Reviewers
ashoat
Summary

Depends on D13995

we'll navigate to this modal from the community drawer button in D13987 and from the bottom sheet in D13986

Test Plan

tested that the tabs work as expected and all the community threads display in the right tab. tested the join/leave behavior in previous diff, which also has a video with the modal

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

native/components/community-joiner-modal.react.js
134

this is obviously wrong, but was having some trouble adding a libdef for react-native-tab-view. i couldn't figure out how to import the Animated type from 'react-native' in my libdef

figured I'd put this diff up before spending too much time on this, since @ashoat might have some ideas here

134

by wrong, I mean not how we usually resolve flow issues

native/components/community-joiner-modal.react.js
19

we don't want to display an empty modal so we make sure we have the list of communities first before we navigate to this modal

30
varun requested review of this revision.Thu, Nov 21, 8:18 PM

btw, this diff replaces D13493, which I plan on abandoning. i think i've applied all the feedback from there, but referencing here just in case

ashoat requested changes to this revision.Sat, Nov 23, 6:16 AM
ashoat added inline comments.
native/components/community-joiner-modal.react.js
46

Is this the best way to check which communities belong where? What happens if a community gets renamed? I feel like IDs might be better

87–101

Should these be in useCallbacks?

109–112

Should this be in a useMemo?

134

Talked through this offline yesterday, but yeah we should improve this from mixed

134–142

Shouldn't this be in a useCallback?

150

Shouldn't this be in a useMemo?

153

Shouldn't this be in a useMemo?

This revision now requires changes to proceed.Sat, Nov 23, 6:16 AM