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

@abhi21121211/project-pa-runtime

v1.1.22

Published

Runtime widget for Project PA guided tours

Readme

@abhi21121211/project-pa-runtime

npm version License: MIT

The lightweight runtime widget for Project PA (Project Personal Assistant). This zero-dependency library injects a floating "Start Tour" widget, a guided tour popup, and an element highlighter into any web application.

Features

  • 🎯 Smart Highlighting: Visually focuses on elements using CSS selectors.
  • 💬 Guided Tour: Step-by-step popup with professional narration.
  • 🗣️ Text-to-Speech: Built-in voice narration for accessibility and engagement.
  • Auto-Advance: Seamlessly moves to the next step after a set duration.
  • 🔄 State Persistence: Remembers the current step across page reloads and redirects.
  • 📱 Responsive: Fully optimized for desktop and mobile devices.
  • 🎭 Two Modes: Full project tour OR current page explanation only.

Installation & Usage

Option 1: CDN (Recommended)

Simply add this script tag to your index.html <body>. This is the easiest way to integrate Project PA.

<script 
  type="module" 
  src="https://unpkg.com/@abhi21121211/project-pa-runtime@latest/dist/project-pa.min.js"
  data-project-id="YOUR_PROJECT_ID">
</script>
  • Replace YOUR_PROJECT_ID with the ID you received from pa deploy.
  • If testing locally with a presentation.json file, you can omit data-project-id.

Option 2: NPM

If you prefer to bundle it with your application:

npm install @abhi21121211/project-pa-runtime

Then import it in your entry file (e.g., main.js, App.tsx):

import '@abhi21121211/project-pa-runtime';

Tour Modes

The widget provides two modes accessible via the floating button:

| Mode | Description | |------|-------------| | Start Full Tour | Navigates to home page and shows ALL steps across all pages | | Explain This Page | Shows only steps for the CURRENT page (no navigation) |

Configuration

The runtime is driven by a presentation.json file (fetched from the cloud via data-project-id or locally).

Structure

{
  "meta": {
    "project": "My Awesome App",
    "author": "Developer",
    "description": "Brief project description",
    "techStack": ["React", "Node.js"],
    "entryUrl": "/"
  },
  "steps": [
    {
      "id": "intro",
      "type": "popup",
      "page": "/",
      "target": "body",
      "content": "Welcome to the app! Built with React and Node.js.",
      "duration": 8000
    },
    {
      "id": "login-btn",
      "type": "highlight", 
      "page": "/",
      "target": "#login-btn",
      "content": "Click here to sign in securely with JWT authentication.",
      "duration": 7000
    },
    {
      "id": "dashboard",
      "type": "popup",
      "page": "/dashboard",
      "target": "body",
      "content": "This is the main dashboard where you can see your stats.",
      "duration": 8000
    }
  ]
}

Step Properties

| Property | Type | Required | Description | |----------|------|----------|-------------| | id | string | ✅ | Unique identifier for the step | | type | string | ✅ | popup, highlight, click, or navigate | | page | string | ✅ | URL path this step belongs to (e.g., /, /about) | | target | string | ✅ | CSS selector (e.g., #my-id, .my-class). Use body for popups. | | content | string | ✅ | Text to display and narrate (15-25 words recommended) | | duration | number | ❌ | Time in ms before auto-advancing (default: 5000) | | actions | array | ❌ | Actions to perform, e.g., [{"do": "click", "selector": "#btn"}] |

Step Types

| Type | Description | Target | |------|-------------|--------| | popup | Shows a message popup | Use body | | highlight | Highlights a UI element with overlay | Specific selector | | click | Simulates a click action | Specific selector | | navigate | Navigates to another page | Specific selector + page |

Links

License

MIT