npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@agentxjs/ui

v1.9.0

Published

AgentX UI Components - React component library for building AI agent interfaces

Readme

@agentxjs/ui

React component library for building AI agent interfaces.

Features

  • 🎨 React components optimized for AI agent UIs
  • 📘 TypeScript support with full type definitions
  • 🎯 Tailwind CSS design system with AgentX branding
  • 📦 Two usage modes: Tailwind Preset (recommended) or Precompiled CSS
  • 🌳 Tree-shakeable ESM exports
  • 📚 Storybook for component development

Installation

bun add @agentxjs/ui

Usage Modes

You can use this library in two ways:

✅ Mode 1: Tailwind Preset (Recommended)

Best for: Production apps that need optimal performance and customization.

Pros:

  • ⚡ Smallest bundle size (only includes classes you use)
  • 🎨 Full theme customization
  • 🔄 Inherits AgentX design system

Setup:

  1. Install Tailwind CSS dependencies:
bun add -D tailwindcss @tailwindcss/postcss postcss postcss-cli
  1. Create tailwind.config.js:
import agentxPreset from "@agentxjs/ui/tailwind-preset";

/** @type {import('tailwindcss').Config} */
export default {
  presets: [agentxPreset],
  content: ["./src/**/*.{ts,tsx}", "./node_modules/@agentxjs/ui/dist/**/*.js"],
};
  1. Create postcss.config.js:
export default {
  plugins: {
    "@tailwindcss/postcss": {},
  },
};
  1. Create src/styles.css:
@import "@agentxjs/ui/globals.css";
  1. Build CSS and use components:
import { Button } from "@agentxjs/ui";
import "./styles.css"; // Generated by PostCSS

function App() {
  return <Button>Click me</Button>;
}

Mode 2: Precompiled CSS (Zero Config)

Best for: Quick prototypes, demos, or non-Tailwind projects.

Pros:

  • 🚀 Zero configuration
  • ⚡ Quick setup

Cons:

  • 📦 Larger bundle size (~40KB, includes all UI component classes)

Setup:

import { Button } from "@agentxjs/ui";
import "@agentxjs/ui/dist/agentx-ui.css"; // Precompiled CSS

function App() {
  return <Button>Click me</Button>;
}

Available Components

  • Layout: Header, Sidebar, Panel, MainContent, ActivityBar, StatusBar
  • Chat: Chat, ChatHeader, MessagePane, InputPane
  • Mobile: MobileStudio, MobileMessagePane, MobileInputPane
  • Elements: Button, Input, Badge, Avatar, EmptyState, LoadingState
  • Typography: MarkdownText, JSONRenderer, DiffViewer
  • Containers: AgentList, ToolCard

See Storybook for interactive examples (run from repository root: bun --filter @agentx/dev-storybook dev).

Exports

// Components
import { Button, Input, Chat } from "@agentxjs/ui";

// Tailwind Preset (Mode 1)
import agentxPreset from "@agentxjs/ui/tailwind-preset";

// Styles (Mode 2)
import "@agentxjs/ui/globals.css"; // Base styles + CSS variables
import "@agentxjs/ui/dist/agentx-ui.css"; // Precompiled CSS (zero-config)

Design System

The component library uses a semantic token system:

| Token | Purpose | Default Color | | --------------- | -------------------------- | ------------------ | | Primary | Computational intelligence | Blue (#0284c7) | | Secondary | Generative creativity | Amber (#f59e0b) | | Accent | Interactive highlights | Orange (#f97316) | | Success | Positive feedback | Green (#22c55e) | | Warning | Caution states | Yellow (#eab308) | | Destructive | Error states | Red (#ef4444) |

Theme Support:

  • ✅ Dark mode via CSS custom properties
  • ✅ All colors map to CSS variables (hsl(var(--primary)))
  • ✅ Override in your app's globals.css

Development

Note: This package is part of the AgentX monorepo. Development tools (Storybook) are in the dev/ directory.

# From repository root:
# Install dependencies
bun install

# Run Storybook (port 6006)
bun --filter @agentx/dev-storybook dev

# From packages/ui directory:
# Build the library
bun build

# Type checking
bun typecheck

# Linting
bun lint

Architecture

Package Structure:

  • src/components/ - React components (Button, Chat, Studio, etc.)
  • src/styles/ - Global styles and CSS variables
  • src/utils/ - Utility functions (cn, eventBus)
  • tailwind-preset.js - Tailwind configuration preset
  • dist/ - Built outputs (ESM + CSS)

Build Outputs:

  • dist/index.js - ESM bundle (React components)
  • dist/index.d.ts - TypeScript definitions
  • dist/globals.css - Base styles + CSS variables
  • dist/agentx-ui.css - Precompiled Tailwind CSS (zero-config mode)

Related Packages

License

MIT