Feedback

chime

Plays a short alert, three soft tones, for something that just finished: a timer at zero. It resolves true once the tones are scheduled and false when the browser has no Web Audio or keeps the page silent (no interaction yet), so the caller can rely on what shows on screen instead. It settles within about 300 ms even when the browser never lets sound start, and a context it made for itself is always closed. It never throws. Pair it with buzz() for phones on silent.

import { chime } from "@/lib/ouro/feedback";

Example

const played = await chime({ context });

Use instead when

  • Use toast() instead to tell the person something in words; a chime only draws their attention back to the screen.

Parameters

{ context }
Type: ChimeOptions
{}

Returns

Promise<boolean>