Astryx

Astryx Chat Composer Token Element

Component

About

Renders an Astryx token chip outside the contentEditable input while preserving correct serialization and visual consistency.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Astryx Chat Composer Token Element to your project and fits it to your theme.

Code

How Astryx Chat Composer Token Element is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

'use client';

import {ChatComposerTokenElement} from '@/components/ui/astryx-chat-composer-token-element';

export default function ChatComposerTokenElementShowcase() {
  return (
    <div
      data-astryx-theme="neutral"
      data-theme="light"
      style={{colorScheme: 'light', display: 'contents'}}>
      <ChatComposerTokenElement
        token={{value: '@astryx', label: '@astryx', variant: 'blue'}}
      />
    </div>
  );
}

Dependencies

More by Astryx

View all
  • Astryx Banner

    Astryx Banner

    61
  • Astryx Avatar

    Astryx Avatar

    32
  • Astryx Aspect Ratio

    Astryx Aspect Ratio

    32
  • Astryx Badge

    Astryx Badge

    29
  • Astryx Button Group

    Astryx Button Group

    28
  • Astryx Chat Composer Drawer

    Astryx Chat Composer Drawer

    25
  • Astryx Toggle Button

    Astryx Toggle Button

    17
  • Astryx Chat Tokenized Text

    Astryx Chat Tokenized Text

    9