Skip to content
caliper ui pro docs

Media player

An audio or video player with accessible controls and a progress bar.

Pro

When to use

  • Playing a recording inside the product.
  • Captions or chapters are available.

When not to use

  • The media is background decoration.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/media-player

Adds its 3 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

MediaPlayer

6 props
PropTypeDefaultDescription
src *string—
kind"audio" | "video""audio"
title *string—
artworkReactNode—Shown behind the controls for audio.
chaptersreadonly Chapter[][]
classNamestring—

Keyboard

  • Keyboard and focus come from Radix popover: arrow keys move through items, Enter and Space select, and Escape closes and returns focus.

Accessibility

It exposes group, alert and status semantics, with aria-label, aria-hidden and aria-valuetext 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/media-player.md

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

More in Calendar & media