Skip to content
caliper ui pro docs

Object viewer

A physical thing you can turn, with notes pinned to its faces. It is a true six-faced cube; each face is whatever you pass, and a pin is a child of its face, so it turns with it and disappears when the face turns away.

Pro
SU-4Sensor unit1
5 901234 123457✓
⚠FRAGILEHandle with care3
Width 120 mm↔Height 86 mm
↑↑THIS SIDE UP
Made in PortugalLot 2026-10

Select a note to turn the object to it.

When to use

  • Packaging proofs, product reviews and hardware documentation.
  • Pinning feedback to a place on a physical object.

When not to use

  • Photographs or product models with real 3D geometry; use a model viewer.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/object-viewer

Adds its 6 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.

API reference

ObjectViewer

10 props
PropTypeDefaultDescription
label *string—Names the object for screen readers, for example "Sensor unit packaging proof".
faces *Partial<Record<ObjectFace, ReactNode>>—
notesreadonly ObjectNote[][]
onResolvedChange((id: string, resolved: boolean) => void)—
sizenumber160Edge of the cube in pixels.
statusDepthStatus"ready"
messagesDepthMessages—
onRetry(() => void)—
disabledboolean—
classNamestring—

Keyboard

  • No custom key handling; Tab and the native activation keys do the work.

Accessibility

It exposes group and img semantics, with aria-roledescription, aria-label, aria-pressed and aria-live kept in step with state. Changes that matter are announced through a live region.

Notes for AI

Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.

/docs/components/object-viewer.md

The index of every part is at /llms.txt.

More in Media viewers