Sentiment trackPro
Caller sentiment along a call as one quiet line, with the dips labeled by what happened.
On this page
ProA billing call with two labeled dips and the lift when the refund lands.
Installation
Usage
import { SentimentTrack } from "@/components/ui/chatcn/pro/sentiment-track"
<SentimentTrack points={sentiment} events={moments} time={player.time} onSeek={seek} />Most of a call is neutral and should look it: the line is gray and only the stretches below dipBelow turn red. Events inside a dip get a label at that point; click one to seek. Time runs left to right in every language.
Examples
States
ProA calm call, a stricter dip line and a compact row.
Props
| Prop | Type | Notes |
|---|---|---|
points | { t, value }[] | Seconds and -1 to 1 |
events | { t, label }[] | Labeled when they fall in a dip |
time, onSeek | number, (t) => void | Playback cursor and seeking |
dipBelow | number | Default -0.3 |
height | number | Default 96 |
Accessibility
- The chart is a named image described by a table of the dips with their times.