- User Since
- Jul 13 2022, 2:18 AM (62 w, 3 d)
Important context in D9007 - we just want to use the alt text for now
You could remove the text field and just do textPrefix + mentionText
Wed, Sep 20
@michal my idea is that every action will take care of the merging inside
Use constant. Move logic to ConnectedTextMessage, where other conditions for whether a message can be edited are checked, and a canEditMessage value used to create visibleEntryIDs which are used by TooltipContext to determine whether the item should be rendered, is created.
Tue, Sep 19
Mon, Sep 18
Memoize boundCallServerEndpointSelector per keserverID
I created a followup task to update the types: ENG-4968
Fri, Sep 15
Did you test whether the animation still works when user opens tooltip and presses "thread", even if the message has a link?
Thu, Sep 14
Wed, Sep 13
Remove unused veriable
We already pass all actions to a hook (even in class components, we use useServerCall) so I imagine there is some way to do it. But I won't insist
Now the memoization works in a slightly different way, but achieves the same effect - memoizes the function.
We create a selector, that returns a _memoized function. This function remembers the last action returned for every KeyserverCall. This selector remembers the _memoized function, so it can be used in all components calling useKeyserverCall. If this selector's dependencies change, all actions would have to be recalculated anyway, so it fine that the memoized function is created anew.
This way, we have to memoize less things, because we memoize one function, and actions for all ActionFuncs, instead of a selector and an action for every ActionFunc
Clean up - inline getCallKeyserverEndpoint and invert memoization
@ashoat This selector is called inside of actions. I don't think I can use selectors inside of actions, especially that they are called in class components.
Tue, Sep 12
What happens if this action fails?
Is it possible that a user with this id will not be in our store?
Mon, Sep 11
I remove copy paste between search on web and native. I will create a followup task to use this function in pinned messages, because it seems to me that this logic wan be used there as well.
Requesting review, because I ended up extracting a lot of common code to lib. This is code that takes messages returned from messageListData and filters them to just include the messages we initaily fetched from the search endpoint
Extract common code to lib
Found one more plance. Don't know why it wasn't showing errors before...
Fri, Sep 8
Thu, Sep 7
You are probably right, there isn't much more data in the keyserverInfos than we are fetching here, so this is probably unnecessary.
Wed, Sep 6
What is the default text?
Can you add some tests please?
D8903 will introduce new regex for detecting when typeahead should be shown (it will catch spaces too). Because of that change, the tooltip would never close.
This solution is a bit overengineered, but I think there is no point in reverting it
Tue, Sep 5
Need to add migrations
Fix lastCommunicatedPlatformDetails default validator