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

@oztix/roadie-widgets

v3.6.2

Published

Roadie Design System widgets (core + React + Vue skins) — currently the shared cart drawer

Downloads

1,133

Readme

@oztix/roadie-widgets

Widget components for the Roadie Design System. Framework-agnostic UI building blocks shared between React and Vue consumers.

Versioning. This package follows semver. Pin a major (^3 for compatible updates, or ~3.0 to stay on a minor) and read the changelog before taking a major bump.

Widgets

Cart drawer

A shared cart drawer extracted from the Oztix website so it can also run inside Vue 3 / Webpack consumers. Framework-agnostic core (BYOF transport, drag math, urgency state machine, formatting, URL validation) with React 19 and Vue 3 skins on top.

See docs/plans/2026-05-26-shared-cart-drawer-design.md for the full design and integration contract.

Install

pnpm add @oztix/roadie-widgets

Quick start

React (Next.js / Vite / CRA)

import { createCartClient } from '@oztix/roadie-widgets/cart-drawer/core'
import { CartDrawer } from '@oztix/roadie-widgets/cart-drawer/react'

const cart = createCartClient({
  host: process.env.NEXT_PUBLIC_OUTLET_HOST,
  fetch: (url, init) => fetch(url, { ...init, credentials: 'include' }),
})

<CartDrawer
  cart={cart}
  collectionId={collectionId}
  onNavigate={(href) => router.push(href)}
  browseHref="/events"
  locale="en-AU"
  currency="AUD"
/>

Vue 3 (Options API, Webpack)

Breaking in 3.0.0. The Vue skin now emits raw Roadie/Tailwind utility classes (like the React skin) instead of a self-contained rc- stylesheet. The host must run Tailwind CSS v4, import @oztix/roadie-core/css, and @source-scan the widget dist so those utilities compile. A host that does neither renders the drawer unstyled. Hosts that cannot adopt Tailwind v4 stay on 2.x.

/* host global CSS (compiled by the host's Tailwind v4 build) */
@import '@oztix/roadie-core/css';
@source '../node_modules/@oztix/roadie-widgets/dist/cart-drawer/vue';
import { createCartClient } from '@oztix/roadie-widgets/cart-drawer/core'
import { CartDrawer } from '@oztix/roadie-widgets/cart-drawer/vue'

// All styling — colours, spacing, animation — comes from the host's
// Tailwind v4 + Roadie core build. No widget stylesheet to import.

app.component('cart-drawer', CartDrawer)

// Outlet is same-origin — no host injection needed.
const cart = createCartClient({ host: '' })
<cart-drawer
  :cart="cart"
  :collection-id="collectionId"
  :on-navigate="navigate"
  :refresh-key="cartRefreshKey"
  browse-href="/events"
  locale="en-NZ"
  currency="NZD"
></cart-drawer>

Architecture

Each widget is internally organised as three layers under src/<widget>/:

  • core/ — Framework-agnostic logic. No React, no Vue, no secrets. Pure functions plus a small client factory consumers wire to their own transport.
  • react/ — React 19 skin.
  • vue/ — Vue 3 SFC skin. Like the React skin, it emits raw Roadie/Tailwind utility classes compiled by the host's Tailwind v4 + @oztix/roadie-core build (single source of truth — core/React/Vue stay in sync), including animation (animate-nudge, animate-pop, animate-pop-in). The package ships no stylesheet of its own.

Subpath exports mean consumers pay only for what they import:

// React-only consumer never resolves Vue's peers, and vice-versa.
import { CartDrawer } from '@oztix/roadie-widgets/cart-drawer/react'

No secrets in this package

Hosts, auth tokens, and any environment-specific value are injected by the consuming app — never hardcoded. A test in src/cart-drawer/core/secret-guard.test.ts guards the package source against shaped secrets and hardcoded http(s):// hostnames.

License

ISC — see LICENSE.