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

growquest-ui

v0.2.0

Published

A gamification UI kit for React — missions, rewards, leaderboards, and interactive experiences.

Downloads

390

Readme

growquest-ui

A gamification UI kit for React — missions, rewards, leaderboards, and interactive experiences.

TypeScript React Storybook License


Install

npm install growquest-ui

Then import the styles once in your app entry:

import 'growquest-ui/styles.css'

Quick start

import { MissionTile, RewardCard, XPBar } from 'growquest-ui'
import 'growquest-ui/styles'

export default function App() {
  return (
    <>
      <XPBar value={72} label="Level 4" />

      <MissionTile
        mission={{
          id: 'm1',
          type: 'quiz',
          title: 'Brand Knowledge Quiz',
          desc: 'Test what you know',
          xp: 150,
          progress: [0, 1],
          tone: 'accent',
        }}
        onLaunch={(m) => console.log('launch', m)}
      />

      <RewardCard
        reward={{
          id: 'r1',
          title: 'Branded T-Shirt',
          cost: 500,
          stock: 'In stock',
          tone: 'accent',
          kind: 'merch',
        }}
        onClaim={(r) => console.log('claim', r)}
      />
    </>
  )
}

Usage in Next.js

Import the stylesheet in your root layout:

// app/layout.tsx
import 'growquest-ui/styles.css'

Interactive components (MissionModal, *Experience, Countdown, FilterTabs, MissionTile, RewardCard) use React hooks and must run on the client. Wrap them in a 'use client' boundary — this is the standard Next.js pattern for third-party UI libraries:

// components/MissionModalWrapper.tsx
'use client'
export { MissionModal } from 'growquest-ui'

Or just add 'use client' to the file where you use them directly.

Purely presentational components (HeroBanner, Podium, ProfileSnapshot, StatCard, TierLadder, BadgeGrid, LeaderboardTable, Logo, BrandLockup, Chip, Tag, XPPill, Eyebrow, Divider, Sparkline) work in Server Components with no extra setup.


API

Primitives

| Export | Description | |--------|-------------| | Button | Primary action button with tone, size, variant, disabled props | | Chip | Compact label/badge with optional icon | | Input | Single-line text input | | Textarea | Multi-line text input | | Field | Label + input wrapper | | XPBar | Horizontal progress bar for XP / level progress | | Logo | Wordmark logo | | BrandLockup | Logo + tagline lockup | | Tag | Small inline tag | | XPPill | XP value pill badge | | Eyebrow | Small uppercase label | | Countdown | Live countdown timer | | Sparkline | Mini trend line chart | | Divider | Section separator |

Components

| Export | Description | |--------|-------------| | BadgeGrid | Grid of achievement badge cards | | FilterTabs | Horizontal tab bar for filtering content | | HeroBanner | Full-width hero section with persona stats | | LeaderboardTable | Ranked user table with streak and tier columns | | MissionModal | Full-screen modal for launching a mission | | MissionTile | Card for a single mission with progress indicator | | Podium | Top-3 leaderboard podium | | ProfileSnapshot | Compact user stats header | | RewardCard | Reward card with claim CTA and stock indicator | | StatCard | Single metric card with icon | | TierLadder | Visual XP tier progression ladder |

Experiences

Interactive mini-games — tree-shake away if unused.

| Export | Description | |--------|-------------| | QuizExperience | Multiple-choice quiz with scoring | | SurveyExperience | Single/multi-select survey | | HangmanExperience | Word-guessing game | | TriviaExperience | Timed trivia question set |

Screens

Full-page route-level layouts.

| Export | Description | |--------|-------------| | (screens are excluded from the library entry point) | Import directly from src/screens/ if building the full app |

Types

import type {
  Mission,        // mission card data
  Reward,         // reward card data
  Badge,          // achievement badge
  Tier,           // XP tier definition
  Persona,        // user profile data
  LeaderboardEntry,
  Tone,           // 'accent' | 'lime' | 'magenta' | 'amber'
  MissionType,    // 'quiz' | 'survey' | 'social' | ...
  RewardKind,     // 'merch' | 'digital' | 'access' | 'experience'
} from 'growquest-ui'

Theming

The library uses CSS custom properties. Override them on :root or a container:

:root {
  --accent-cyan: #06b6d4;
  --accent-lime: #84cc16;
  --accent-magenta: #d946ef;
  --accent-amber: #f59e0b;
}

Both light and dark themes are supported via the data-theme attribute on the root element.


Development

git clone https://github.com/faisal212/growquest-ui.git
cd growquest-ui
npm install

npm run dev        # React app at http://localhost:5173
npm run storybook  # Component explorer at http://localhost:6006
npm test           # Vitest unit tests
npm run lint       # ESLint
npm run build:lib  # Build dist/index.js + dist/index.d.ts

Contributing

  1. Fork and create a feature branch
  2. Add or update the component + co-located .stories.tsx + .test.tsx
  3. Run npm test && npm run lint — both must pass
  4. Open a pull request

Publishing

This package is currently distributed via GitHub install. npm publish is planned for v1.0.0 when the API stabilises.


License

MIT