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

@qualabs/c2pa-live-videojs-ui

v1.0.0

Published

Video.js UI components for C2PA validation: colored progress bar, content credentials menu, friction modal

Readme

@qualabs/c2pa-live-videojs-ui

npm version license

Video.js UI components for real-time C2PA validation: colored progress bar showing per-segment status, content credentials menu, and friction modal for invalid streams.

Installation

npm install @qualabs/c2pa-live-videojs-ui

video.js must be installed separately as a peer dependency:

npm install video.js

Prerequisites

This package requires a C2paController instance to receive validation events. In practice, this comes from calling attachC2pa(dashPlayer) in @qualabs/c2pa-live-dashjs-plugin. However, videojs-ui is framework-agnostic — any object implementing on('segmentValidated', handler) and off('segmentValidated', handler) is compatible.

Quick Start

import { C2paPlayerUI } from '@qualabs/c2pa-live-videojs-ui';
import '@qualabs/c2pa-live-videojs-ui/styles';

// c2paController comes from @qualabs/c2pa-live-dashjs-plugin
const ui = C2paPlayerUI(videoPlayer, c2paController);

// Later, when tearing down:
ui.destroy();

Full Integration Example

import dashjs from 'dashjs';
import videojs from 'video.js';
import { attachC2pa } from '@qualabs/c2pa-live-dashjs-plugin';
import { C2paPlayerUI } from '@qualabs/c2pa-live-videojs-ui';
import '@qualabs/c2pa-live-videojs-ui/styles';

// 1. Create players
const dashPlayer = dashjs.MediaPlayer().create();
const vjsPlayer = videojs('my-video');

// 2. Attach C2PA validation (must be before dashPlayer.initialize)
const c2pa = attachC2pa(dashPlayer);

// 3. Initialize dash.js
dashPlayer.initialize(document.querySelector('video'), 'stream.mpd', true);

// 4. Wire up the UI
vjsPlayer.ready(() => {
  const ui = C2paPlayerUI(vjsPlayer, c2pa);
});

API

C2paPlayerUI(videoPlayer, c2paController, options?): C2paPlayerInstance

Attaches C2PA UI overlays to a video.js player and wires them to a C2paController.

| Parameter | Type | Description | |---|---|---| | videoPlayer | VideoJsPlayer | A video.js player instance | | c2paController | C2paControllerEvents | Any object with on/off for 'segmentValidated' events | | options | C2paPlayerOptions | Optional configuration |

C2paPlayerOptions

type C2paPlayerOptions = {
  isMonolithic?: boolean;       // Affects timeline seek logic. Default: false
  showFrictionModal?: boolean;  // Show friction modal on invalid manifest. Default: true
};

C2paPlayerInstance

type C2paPlayerInstance = {
  destroy(): void;  // Unsubscribes from all events and cleans up DOM elements
};

Components

| Component | Description | |---|---| | C2paTimeline | Colored progress bar overlaid on the video.js seek bar. Each segment is colored by validation status (valid, invalid, warning, unknown) | | C2paMenu | Dropdown menu in the control bar showing content credentials, provider info, and per-segment validation details | | C2paFrictionModal | Modal shown before playback when the stream manifest is invalid. Displayed once per session, dismissible by the user |

Styles

Import the CSS file to apply the default component styles:

import '@qualabs/c2pa-live-videojs-ui/styles';