Comment row
ProOne comment or message in a thread: avatar, bubble, what goes under it and a 48dp actions row that spaces the comments. Not an M3 component (@windmorph/react-pro).
import { CommentRow } from '@windmorph/react-pro';Part of Windmorph Pro, paid components on the free core, not on sale yet. See the Pro guide for what it includes and to register interest.
Purpose
One comment or message in a thread: the avatar, the bubble with the name and the words, what goes under it (a photo, a note) and a 48px row of actions. That row spaces one comment from the next, so a list of them needs no gaps, and every place that shows comments looks the same. It is not an M3 component, so it comes from @windmorph/react-pro.
Behaviour
- The bubble is static, a button (
onPress, e.g. opening the conversation) or a link (href), with the state layer and focus ring when pressable. variant="outlined"draws a dashed bubble, for a removed comment only its writer sees.pendingpaints the bubble in the opaquesurface-containerrole while it's being sent, keeping the words at full contrast, and setsaria-busy; say it in the actions row too ("Sending…"). The bubble fades to its sent colour on the effects spring, under reduced motion too.- What goes in
belowkeeps 4px off the bubble; the actions row sits right under it. - The words, the actions and what they do are the app's: pass a
ReactionPicker, Reply and a menu inactions.
When not to use
For rows of a settings list or a menu use a List.
See also
- Reaction picker: A reaction button that likes on tap, with a floating row of reactions on long press, hover or the keyboard; slide a finger along it to pick. Not an M3 component (@windmorph/react-pro).
- Reaction summary: The reactions so far: the top kinds’ icons and how many, stacked under a post or as a chip in a comment; pressable to see who reacted. Not an M3 component (@windmorph/react-pro).
- Collapse: Content that opens and folds on its height, as an accordion when two switch together: reply fields, answers, more filters. Not an M3 component (@windmorph/react-pro).
- Message field: A rounded field for writing something to send (a comment, a reply, a chat message) that grows from a pill into a box, with a send button, tools that open into their own row on focus, a reply banner, attachments and suggestions while typing (people after @, tags after #, emoji after :); plus its trigger. Not an M3 component (@windmorph/react-pro).