Skip to content

Chat Tokenized Text

@astryxdesign/core v0.7.1 · ChatTokenizedText

Props ​

PropTypeDefaultDescription
tokensChatComposerToken[]—Token definitions using the same type as the composer input. Each non-empty value is matched literally. A structured token renders a Badge, a token with render renders that markup.
textstring—Same as the default slot: message text that may contain serialized token values. Anything that does not match a token stays as it is. The prop wins when both it and the default slot are set.

Slots ​

  • default: the message text. Plain text only, because token content comes from the tokens prop. Everything that does not match a token is rendered as-is.