Orb Select

A compact chooser for an orb's colors: the kit Select, with each colorway shown as a small planet beside its name and the chosen one in the trigger. Lists the Orb Palettes by default; the dropdown sibling of Orb Picker.

Open the preview in a new tab

The source comes with full access.

One payment of $149 opens the source right here and lets the CLI install every paid component, with lifetime updates.

Installation

pnpm dlx shadcn add @01orbital/orb-select
npx shadcn add @01orbital/orb-select
yarn shadcn add @01orbital/orb-select
bunx --bun shadcn add @01orbital/orb-select

Part of the 01orbital library. With a license, put ORBITAL_TOKEN in .env.local and the same command installs it (licensed install, pricing).

It lands at components/select/orb-select.tsx, as source you own and edit.

The example also uses voice-orb. Install it too:

pnpm dlx shadcn add @01orbital/voice-orb
npx shadcn add @01orbital/voice-orb
yarn shadcn add @01orbital/voice-orb
bunx --bun shadcn add @01orbital/voice-orb

Usage

"use client"

import * as React from "react"

import {
  ORB_PALETTES,
  type OrbPaletteName,
} from "@/components/orbs/orb-palettes"
import { VoiceOrb } from "@/components/orbs/voice-orb"
import { OrbSelect } from "@/components/select/orb-select"

// Every word on the page. Change copy here, not in the markup.
const COPY = { label: "Assistant color" } as const

// The select choosing the assistant's orb: pick a color, the Voice Orb takes it.
export default function OrbSelectDemo() {
  const [value, setValue] = React.useState<string>("planet-14")
  const palette = (
    value in ORB_PALETTES ? value : "planet-14"
  ) as OrbPaletteName
  return (
    <div className="flex w-full max-w-xl flex-col items-center justify-center gap-8 p-6 sm:flex-row sm:gap-10">
      <VoiceOrb palette={palette} size={140} />
      <div className="flex flex-col gap-3">
        <p className="font-display text-xl">{COPY.label}</p>
        <OrbSelect
          aria-label={COPY.label}
          value={value}
          onValueChange={setValue}
        />
      </div>
    </div>
  )
}

API reference

Prop

Type

Dependencies

npm: cn. The CLI installs them for you.

Registry pieces it installs with it:

On this page