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

@clappit/chat-element

v0.1.1

Published

Customizable chat interface web component for Clappit's agentic workflow engine

Readme

Clappit Chat Element

A customizable chat interface web component for Clappit's agentic workflow engine. This component can be used with any web framework or vanilla JavaScript.

Installation

npm install @clappit/chat-element

Usage

Vanilla JavaScript/HTML

<script src="node_modules/@clappit/chat-element/dist/clappit-element/clappit-chat.js"></script>
<link rel="stylesheet" href="node_modules/@clappit/chat-element/dist/clappit-element/clappit-chat.css">

<clappit-chat
  title="Chat with Agent"
  primary-color="#007bff"
  secondary-color="#6c757d"
  accent-color="#28a745"
  background-color="#ffffff"
  text-color="#212529"
  font-family="Arial"
  api-endpoint="https://your-api-endpoint.com"
></clappit-chat>

React

import { ClappitChat } from '@clappit/chat-element/react';
import '@clappit/chat-element/dist/clappit-element/clappit-chat.css';

function App() {
  return (
    <ClappitChat
      title="Chat with Agent"
      primaryColor="#007bff"
      secondaryColor="#6c757d"
      accentColor="#28a745"
      backgroundColor="#ffffff"
      textColor="#212529"
      fontFamily="Arial"
      apiEndpoint="https://your-api-endpoint.com"
      onMessageSent={(message) => console.log('Message sent:', message)}
      onMessageReceived={(message) => console.log('Message received:', message)}
      onError={(error) => console.error('Error:', error)}
    />
  );
}

Angular

// app.module.ts
import '@clappit/chat-element';
import '@clappit/chat-element/dist/clappit-element/clappit-chat.css';

@NgModule({
  schemas: [CUSTOM_ELEMENTS_SCHEMA],
  // ...
})
export class AppModule { }

// app.component.html
<clappit-chat
  [title]="'Chat with Agent'"
  [primary-color]="'#007bff'"
  [secondary-color]="'#6c757d'"
  [accent-color]="'#28a745'"
  [background-color]="'#ffffff'"
  [text-color]="'#212529'"
  [font-family]="'Arial'"
  [api-endpoint]="'https://your-api-endpoint.com'"
  (message-sent)="onMessageSent($event)"
  (message-received)="onMessageReceived($event)"
  (error)="onError($event)"
></clappit-chat>

Properties

| Property | Type | Description | |----------|------|-------------| | title | string | The title displayed in the chat window header | | primary-color | string | Primary color for the chat interface | | secondary-color | string | Secondary color for the chat interface | | accent-color | string | Accent color for highlights and buttons | | background-color | string | Background color of the chat window | | text-color | string | Color of the text content | | font-family | string | Font family for the chat interface | | api-endpoint | string | API endpoint for the chat service |

Events

| Event | Detail Type | Description | |-------|-------------|-------------| | message-sent | string | Fired when a message is sent by the user | | message-received | string | Fired when a message is received from the agent | | error | any | Fired when an error occurs |

Browser Support

This component uses Web Components and requires the following browser features:

  • Custom Elements v1
  • Shadow DOM v1
  • ES2015 (ES6)

For older browsers, you may need to include polyfills.

Development

  1. Clone the repository
  2. Install dependencies: npm install
  3. Start development server: npm start
  4. Build: npm run build:element

License

MIT