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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@onlive.ai/common-121

v0.2.70

Published

A shared utility package containing common services, utilities, types, and themes used across the Onlive 121 ecosystem. This package provides the foundational components for building interactive chat, flow, and video meeting applications.

Readme

Onlive Common 121

A shared utility package containing common services, utilities, types, and themes used across the Onlive 121 ecosystem. This package provides the foundational components for building interactive chat, flow, and video meeting applications.

📦 Installation

npm install @onlive.ai/common-121

📂 Package Structure

🛠️ Services

  • AudioService: Handles audio notifications and sound management for incoming calls and interactions
  • FirebaseService: Manages real-time Firebase connections for chat requests and agent presence
  • LivekitService: Provides WebRTC functionality for video/audio communication using LiveKit

🔧 Utilities

  • adopt-styles: Utility for adopting CSS styles in web components
  • browser-preferences: Browser preference detection and management
  • classify-media: Media file classification and type detection
  • decorators: Custom element decorators and helpers
  • detected-lang: Language detection utilities
  • fullscreen: Fullscreen API helpers
  • markdown: Markdown parsing with sanitization
  • merge: Deep object merging utilities
  • sanitize: HTML content sanitization
  • watch: Reactive property watching utilities
  • And more...

🎨 Themes

  • Light Theme: Default light mode styling
  • Dark Theme: Dark mode color scheme
  • Custom Themes: Brand-specific themes (Audi, Cupra, Hyundai, Magimix, Onlive)

📋 Types

  • TrackingOptions: Configuration types for analytics tracking
  • WindowContext: Global window context definitions

🚀 Usage

Basic Import

import { AudioService } from "@onlive.ai/common-121/services/audio.service";
import { markdown } from "@onlive.ai/common-121/utils/markdown";
import { merge } from "@onlive.ai/common-121/utils/merge";

Audio Service

import { AudioService } from "@onlive.ai/common-121/services/audio.service";

const audioService = AudioService.getInstance();

// Play incoming call sound
audioService.playIncoming();

// Stop current sound
audioService.stopCurrentSound();

Firebase Service

import { FirebaseService } from "@onlive.ai/common-121/services/firebase/firebase.service";

const firebaseService = new FirebaseService(firebaseConfig, organizationId);

// Listen for new requests
firebaseService.onNewRequest((id, request) => {
  console.log("New request:", request);
});

LiveKit Service

import { LivekitService } from "@onlive.ai/common-121/services/livekit.service";

const livekitService = new LivekitService();

// Join a room
await livekitService.joinRoom(roomId, timezone, language);

Utilities

import { markdown } from "@onlive.ai/common-121/utils/markdown";
import { merge } from "@onlive.ai/common-121/utils/merge";
import { sanitize } from "@onlive.ai/common-121/utils/sanitize";

// Parse markdown safely
const htmlContent = markdown("# Hello **World**");

// Merge objects deeply
const merged = merge(defaultOptions, userOptions);

// Sanitize HTML content
const cleanHtml = sanitize(userInput);

Themes

import { styles as lightTheme } from '@onlive.ai/common-121/themes/light';
import { styles as darkTheme } from '@onlive.ai/common-121/themes/dark';

// Apply theme to a Lit component
static styles = [lightTheme];

🏗️ Architecture

This package is designed to be used as a foundation for the Onlive 121 ecosystem, providing:

  • Modular Design: Each service and utility can be imported independently
  • Type Safety: Full TypeScript support with comprehensive type definitions
  • Performance: Optimized for production use with efficient caching and lazy loading
  • Extensibility: Easy to extend and customize for specific use cases

🔗 Dependencies

This package integrates with several key technologies:

  • Firebase: Real-time database and authentication
  • LiveKit: WebRTC infrastructure for video/audio
  • Lit: Web components framework
  • RxJS: Reactive programming utilities
  • Marked: Markdown parsing
  • DOMPurify: HTML sanitization

📱 Compatibility

  • Frameworks: Lit, Web Components
  • Browsers: Modern browsers with ES2020+ support
  • Node.js: 18.x or higher
  • TypeScript: 5.7.x

🤝 Related Packages

📄 License

This package is part of the Onlive 121 ecosystem and follows the project's licensing terms.