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

@imperosoft/ch5-typescript

v1.0.0

Published

TypeScript declarations for Crestron CH5 Web Components with React JSX support

Readme

ch5-typescript

TypeScript declarations for Crestron CH5 Web Components with React JSX support.

Installation

npm install @imperosoft/ch5-typescript

Usage

After installation, CH5 elements are automatically available in JSX:

import React from 'react';

function App() {
  return (
    <div>
      {/* Simple click button */}
      <ch5-button sendeventonclick="101" label="Power" />

      {/* Toggle button with feedback */}
      <ch5-button
        sendeventonclick="101"
        receivestateselected="101"
        mode="toggle"
        label="Mute"
      />

      {/* Slider with analog join */}
      <ch5-slider
        sendeventonchange="1"
        receivestatevalue="1"
        orientation="vertical"
      />

      {/* Text display from serial join */}
      <ch5-text receivestatelabel="5" label="Default" />
    </div>
  );
}

Join Communication

Send Events (UI → Processor)

| Attribute | Description | |-----------|-------------| | sendeventonclick | Sends a pulse (true→false) on click/tap | | sendeventontouch | Sends true every 200ms while touched, false on release | | sendeventonchange | Sends value changes (analog/serial joins) |

Receive States (Processor → UI)

| Attribute | Description | |-----------|-------------| | receivestateselected | Digital join: true = selected/pressed state | | receivestatevalue | Analog join: numeric value (0-65535) | | receivestatelabel | Serial join: text content | | receivestateshow | Digital join: true = visible, false = hidden | | receivestateenable | Digital join: true = enabled, false = disabled |

Event Behavior

sendeventonclick (Press Mode)

Sends a momentary pulse when clicked:

  1. User presses → sends true
  2. Immediately sends false (pulse)

sendeventontouch (Touch Mode)

For hold-to-repeat functionality:

  1. User presses → sends true
  2. While held → sends true every 200ms
  3. User releases → sends false

Included Components

  • ch5-animation - Animation object
  • ch5-background - Background with video support
  • ch5-button - Interactive button
  • ch5-button-list - Button collection
  • ch5-color-chip - RGB color display
  • ch5-color-picker - Color selection
  • ch5-datetime - Date/time display
  • ch5-dpad - Directional pad
  • ch5-form - Form container
  • ch5-image - Image display
  • ch5-import-htmlsnippet - HTML snippet loader
  • ch5-jointotext-boolean - Digital to text
  • ch5-jointotext-numeric - Analog to text
  • ch5-jointotext-string - Serial to text
  • ch5-keypad - Numeric keypad
  • ch5-list - Dynamic list
  • ch5-media-player - Audio player (Beta)
  • ch5-modal-dialog - Modal dialog
  • ch5-overlay-panel - Overlay container
  • ch5-qrcode - QR code generator
  • ch5-segmented-gauge - LED gauge
  • ch5-select - Selection list
  • ch5-select-option - Select option
  • ch5-signal-level-gauge - Signal level display
  • ch5-slider - Analog slider
  • ch5-spinner - Loading spinner
  • ch5-subpage-reference-list - Subpage list
  • ch5-tab-button - Tabbed buttons
  • ch5-template - Template instantiation
  • ch5-text - Text display
  • ch5-textinput - Text input
  • ch5-toggle - Toggle switch
  • ch5-triggerview - View switcher
  • ch5-video - Video player
  • ch5-video-switcher - Video switching
  • ch5-wifi-signal-level-gauge - WiFi signal display

Exported Types

import type {
  JoinType,
  CrComLibInterface,
  WebXPanelInterface,
  Ch5Size,
  Ch5Stretch,
  Ch5Type,
  Ch5Orientation,
  Ch5ButtonShape,
  Ch5ButtonMode,
  Ch5IconPosition,
  Ch5HandleShape,
  Ch5CommonAttributes,
  // ... and more
} from '@imperosoft/ch5-typescript';

Documentation

License

MIT