mirror of
https://github.com/AmanTahiliani/box-box.git
synced 2026-08-07 19:56:18 -04:00
Consolidate the Race Story section into a cohesive timeline surface: custom chapter-strip scrolling with active-card sync, unified segmented playback controls, chapter bands on the position graph with decimated axes and de-collided labels, map toggle gated by an on-mount replay/outline probe, and shared empty-state cards. Adds vitest coverage and visual snapshots. Note: replay/outline queries now probe on mount (not only when Map opens) so the toggle can be hidden before users hit a dead panel. Co-authored-by: Cursor <cursoragent@cursor.com>
21 lines
580 B
TypeScript
21 lines
580 B
TypeScript
import type { LucideIcon } from 'lucide-react'
|
|
import type { ReactNode } from 'react'
|
|
|
|
interface Props {
|
|
icon: LucideIcon
|
|
title: string
|
|
hint: ReactNode
|
|
testId?: string
|
|
className?: string
|
|
}
|
|
|
|
export function EmptyStateCard({ icon: Icon, title, hint, testId, className = '' }: Props) {
|
|
return (
|
|
<div className={`empty-state ui-card ${className}`.trim()} data-testid={testId}>
|
|
<Icon size={32} className="empty-state-icon" aria-hidden />
|
|
<div className="empty-state-title">{title}</div>
|
|
<div className="empty-state-desc">{hint}</div>
|
|
</div>
|
|
)
|
|
}
|