Reply quote
import { ReplyQuote, firstLine } from "@arcadia/ui";In the composer
ReplyQuote
author- Actor | OutsideActor | undefined
- Who wrote what is answered. Every quote has one; only
askedstands without. asked- Actor | OutsideActor | "you" | undefined
- In the quote's seat over a message that puts an
Askand answers none: "Asked" and the person asked, one quiet line that every reader sees,"you"for the person asked. The ask then leaves out its ownaskedOf, so it is said once. Not withcomposerornested, and with noauthor, words or jump. text- string | undefined
- What is answered, as written: its first line shows, fading where it is cut, and a saved quote above its bubble shows all of it. A message of pictures alone passes the words for them ("Photo"). Optional when
previewis provided. preview- ReactNode
- Rendered excerpt shown in place of the raw text. Pass inline phrasing content only, so a quote that jumps stays valid interactive HTML.
picture- ReactNode
- The quoted image's thumbnail, before the words: a 20px square, clipped, with a hairline inside. Drawn for the eye only, so a reader hears the words passed for it ("Photo").
band- boolean
onJump- (() => void) | undefined
- Jumps to the message answered: the product scrolls it into view, focuses it and holds it (
flash). Given, the quote is a button; left out, it is saved: the sender and excerpt as text, and nothing takes focus. Not withcomposer. onCancel- (() => void) | undefined
- With
composer, and only there: drops the reply. The product takes the quote down and gives focus back to its field. Cancel reply runs it, and Escape inside the quote; the product runs it on Escape in its field too. cancelLabel- string | undefined
- Default:
"Cancel reply" - With
composer: Cancel reply's name. side- BubbleSide | undefined
- Default:
start - The reply's side: above its bubble, the quote stands on the bubble's text edge. Not with
composer. bare- boolean | undefined
- Over words with no bubble round them, such as a list of messages: the line takes no inline inset, so its first letter stands on the words' own edge, and a jump's ring stands just outside it. Over a bubble, leave it out: the line stands on the bubble's text edge. Not with
composerornested. placement- ReplyQuotePlacement | undefined
- Default:
above - Where the quote stands:
aboveis one quiet line over its bubble;nestedis a two-row inner container inside the bubble with concentric corners;composeris the strip over the composer's field while the reply is written, "Replying to" with Cancel reply. rootStyle- RootStyle | undefined
- Typed StyleX override: layout.
ref- Ref<HTMLElement> | undefined
- The quote's root: the button, the saved quote or the composer's group.
Rest props go to HTMLAttributes<HTMLElement>.