[web] Display a pin icon next to pinned messages in chat
Summary:
Next to each pinned message, we want to display a pin icon in the color of the thread. To do this, one main change that was made is we need to determine whether the ComposedMessage (Message -> TextMessage or MultimediaMessage -> ComposedMessage) is rendered within a modal, or just in chat. This is because we consider two scenarios:
- The message is displayed in the toggle pin modal or the thread pinned messages modal - here, we want to avoid displaying the pin icon next to messages
- The message is rendered in the chat view, and there we want to display the pin icon next to messages.
As opposed to using a Context, I figured that that propagating the props through the three components in the rendering hierarchy would be the most efficient, so that's what this diff does.
Linear: https://linear.app/comm/issue/ENG-3455/show-a-pin-icon-next-to-pinned-messages
Depends on D7382
Test Plan:
Test video will be attached to demonstrate that the icon is not shown in modals, and the icon is correctly positioned / colored.
Reviewers: ginsu, tomek, atul
Reviewed By: tomek
Subscribers: ashoat
Differential Revision: https://phab.comm.dev/D7505