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

@hanzo/booker

v0.1.0

Published

Universal (web + native) scheduling UI for the Hanzo Calendar — a Booker, Confirmation, and compact CalendarEmbed built with hanzogui primitives.

Downloads

157

Readme

@hanzo/calendar

Universal (web + native) scheduling UI for the Hanzo Calendar, built with hanzogui primitives.

One booking flow — event header → month grid → time slots → details → confirmation — that runs unchanged on the web (DOM) and React Native (iOS / Android). No raw HTML, no ad-hoc CSS: every surface is a hanzogui/Tamagui component styled with theme tokens, so it inherits the host app's theme, dark mode, and design system.

Install

bun add @hanzo/calendar
# peer deps: hanzogui, react (and react-native for native targets)

Render inside a GuiProvider (from hanzogui) so tokens and themes resolve.

Usage

import { GuiProvider } from 'hanzogui'
import { Booker } from '@hanzo/calendar'
import config from './gui.config' // your createGui(...) config

export function BookMeeting() {
  return (
    <GuiProvider config={config} defaultTheme="light">
      <Booker
        host="hanzo"
        eventSlug="intro"
        onBooked={(booking) => console.log('booked', booking.uid)}
      />
    </GuiProvider>
  )
}

That's the whole integration. Booker fetches the public event type, renders a navigable month calendar, loads availability for the visible range, converts UTC slots into the visitor's time zone (Intl.DateTimeFormat().resolvedOptions().timeZone), collects attendee details, and posts the booking — with loading, error, empty, and "slot just taken" (HTTP 409) states handled throughout.

Components

| Component | Purpose | | ---------------- | ----------------------------------------------------------------------- | | Booker | Full scheduling flow: event → month → times → details → confirmation. | | CalendarEmbed | Compact card for a marketing hero — soonest availability inline. | | Confirmation | Booking confirmation card; pass a booking or a uid to fetch one. | | EventHeader, MonthCalendar, TimeSlots, BookingForm | Composable sub-views for a custom flow. |

Props

Booker and CalendarEmbed:

  • host — calendar owner's username, e.g. "hanzo".
  • eventSlug — event-type slug, e.g. "intro".
  • apiUrl? — API base; defaults to https://api.hanzo.ai/v1/calendar.
  • timeZone? — visitor IANA zone; defaults to the browser/device zone.
  • weekStartsOn?0 (Sunday, default) or 1 (Monday).
  • onBooked?(booking) — called with the created booking.

Confirmation:

  • booking? — a booking object, or
  • uid? — a booking id to fetch (with apiUrl?, timeZone?, onDone?).

Data & time helpers

The pure, framework-free data plane (fetchEventType, fetchSlots, createBooking, fetchBooking, cancelBooking) and time plane (visitorTimeZone, formatSlotTime, monthMatrix, …) are exported for building a bespoke flow or a headless integration. The useBooker hook exposes the entire state machine.

Backend

Speaks the Hanzo Calendar API (Cal API-v2 shapes):

  • GET /atoms/event-types/{slug}/public?username={host}
  • GET /slots/available?eventTypeSlug=&usernameList=&startTime=&endTime=&timeZone=
  • POST /bookings (cal-api-version: 2024-08-13)
  • GET /bookings/{uid} · POST /bookings/{uid}/cancel

License

BSD-3-Clause © Hanzo AI