{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "range-area-chart",
  "title": "Range Area Chart",
  "description": "A min/max envelope chart with a nested core-range band, an actual-to-forecast line split, annotated risk zones, a reference line, and a live endpoint badge.",
  "dependencies": [
    "clsx",
    "tailwind-merge"
  ],
  "files": [
    {
      "path": "registry/new-york/range-area-chart/range-area-chart.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\nimport { clsx, type ClassValue } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nfunction cn(...inputs: ClassValue[]) {\n  return twMerge(clsx(inputs));\n}\n\nexport type RangeAreaChartTheme = \"light\" | \"dark\";\n\nexport interface RangeAreaChartPoint {\n  time: string;\n  min: number;\n  max: number;\n  coreMin: number;\n  coreMax: number;\n  value: number;\n}\n\nexport interface RangeAreaChartZone {\n  visible?: boolean;\n  label: string;\n  color: string;\n  startIndex: number;\n  endIndex: number;\n}\n\nexport interface RangeAreaChartReferenceLine {\n  visible?: boolean;\n  value: number;\n  label: string;\n  color: string;\n}\n\nexport interface RangeAreaChartAnnotation {\n  visible?: boolean;\n  title: string;\n  subtitle: string;\n  atIndex: number;\n  value: number;\n  color: string;\n}\n\nexport interface RangeAreaChartEndpoint {\n  visible?: boolean;\n  suffix: string;\n  color: string;\n}\n\nexport interface RangeAreaChartProps {\n  theme?: RangeAreaChartTheme;\n  title?: string;\n  subtitle?: string;\n  chartHeight?: number;\n  unit?: string;\n  yMin?: number;\n  yMax?: number;\n  yStep?: number;\n  actualColor?: string;\n  forecastColor?: string;\n  bandColor?: string;\n  coreBandColor?: string;\n  forecastStartIndex?: number;\n  dataPoints?: RangeAreaChartPoint[];\n  zones?: RangeAreaChartZone[];\n  referenceLine?: RangeAreaChartReferenceLine;\n  annotation?: RangeAreaChartAnnotation;\n  endpoint?: RangeAreaChartEndpoint;\n  enableHover?: boolean;\n  className?: string;\n}\n\ninterface Pt {\n  x: number;\n  y: number;\n}\n\nconst VB_W = 1200;\nconst VB_H = 560;\nconst PAD_LEFT = 72;\nconst PAD_RIGHT = 150;\nconst PAD_TOP = 26;\nconst PAD_BOTTOM = 58;\n\nfunction readableTextOn(hex: string): string {\n  const h = hex.replace(\"#\", \"\");\n  const full = h.length === 3 ? h.split(\"\").map((c) => c + c).join(\"\") : h;\n  const r = parseInt(full.slice(0, 2), 16);\n  const g = parseInt(full.slice(2, 4), 16);\n  const b = parseInt(full.slice(4, 6), 16);\n  return 0.299 * r + 0.587 * g + 0.114 * b > 150 ? \"#0A0A0A\" : \"#FFFFFF\";\n}\n\nfunction clamp(n: number, min: number, max: number) {\n  return Math.min(max, Math.max(min, n));\n}\n\nfunction buildTicks(yMin: number, yMax: number, step: number): number[] {\n  const ticks: number[] = [];\n  let v = Math.ceil(yMin / step) * step;\n  for (; v <= yMax; v += step) ticks.push(v);\n  return ticks;\n}\n\nfunction makeGeometry(count: number, plotTop: number, yMin: number, yMax: number, vbW: number, padLeft: number, padRight: number) {\n  const plotLeft = padLeft;\n  const plotRight = vbW - padRight;\n  const plotBottom = VB_H - PAD_BOTTOM;\n  const plotWidth = plotRight - plotLeft;\n  const plotHeight = plotBottom - plotTop;\n  const xAt = (i: number) => plotLeft + (count > 1 ? (i / (count - 1)) * plotWidth : plotWidth / 2);\n  const yAt = (v: number) => plotBottom - clamp((v - yMin) / (yMax - yMin), 0, 1) * plotHeight;\n  return { plotLeft, plotRight, plotTop, plotBottom, plotWidth, plotHeight, xAt, yAt };\n}\n\nfunction smoothLinePath(pts: Pt[]): string {\n  if (pts.length < 2) return \"\";\n  if (pts.length === 2) return `M ${pts[0].x} ${pts[0].y} L ${pts[1].x} ${pts[1].y}`;\n  let d = `M ${pts[0].x} ${pts[0].y} `;\n  for (let i = 0; i < pts.length - 1; i++) {\n    const p0 = pts[i - 1] ?? pts[i];\n    const p1 = pts[i];\n    const p2 = pts[i + 1];\n    const p3 = pts[i + 2] ?? p2;\n    const c1x = p1.x + (p2.x - p0.x) / 6;\n    const c1y = p1.y + (p2.y - p0.y) / 6;\n    const c2x = p2.x - (p3.x - p1.x) / 6;\n    const c2y = p2.y - (p3.y - p1.y) / 6;\n    d += `C ${c1x} ${c1y}, ${c2x} ${c2y}, ${p2.x} ${p2.y} `;\n  }\n  return d;\n}\n\nfunction smoothBandPath(topPts: Pt[], bottomPts: Pt[]): string {\n  if (topPts.length < 2 || bottomPts.length < 2) return \"\";\n  const bottomRev = [...bottomPts].reverse();\n  let d = smoothLinePath(topPts);\n  d += `L ${bottomRev[0].x} ${bottomRev[0].y} `;\n  for (let i = 0; i < bottomRev.length - 1; i++) {\n    const p0 = bottomRev[i - 1] ?? bottomRev[i];\n    const p1 = bottomRev[i];\n    const p2 = bottomRev[i + 1];\n    const p3 = bottomRev[i + 2] ?? p2;\n    const c1x = p1.x + (p2.x - p0.x) / 6;\n    const c1y = p1.y + (p2.y - p0.y) / 6;\n    const c2x = p2.x - (p3.x - p1.x) / 6;\n    const c2y = p2.y - (p3.y - p1.y) / 6;\n    d += `C ${c1x} ${c1y}, ${c2x} ${c2y}, ${p2.x} ${p2.y} `;\n  }\n  d += \"Z\";\n  return d;\n}\n\nconst DEFAULT_DATA: RangeAreaChartPoint[] = [\n  { time: \"06:00\", min: 85, max: 155, coreMin: 110, coreMax: 130, value: 120 },\n  { time: \"07:00\", min: 88, max: 150, coreMin: 110, coreMax: 128, value: 120 },\n  { time: \"08:00\", min: 100, max: 170, coreMin: 125, coreMax: 148, value: 138 },\n  { time: \"09:00\", min: 115, max: 195, coreMin: 138, coreMax: 165, value: 152 },\n  { time: \"10:00\", min: 140, max: 280, coreMin: 175, coreMax: 240, value: 208 },\n  { time: \"11:00\", min: 120, max: 220, coreMin: 150, coreMax: 200, value: 178 },\n  { time: \"12:00\", min: 110, max: 200, coreMin: 140, coreMax: 180, value: 163 },\n  { time: \"13:00\", min: 115, max: 230, coreMin: 145, coreMax: 190, value: 170 },\n  { time: \"14:00\", min: 130, max: 255, coreMin: 0, coreMax: 0, value: 196 },\n  { time: \"15:00\", min: 140, max: 291, coreMin: 0, coreMax: 0, value: 210 },\n  { time: \"16:00\", min: 135, max: 260, coreMin: 0, coreMax: 0, value: 196 },\n  { time: \"17:00\", min: 120, max: 235, coreMin: 0, coreMax: 0, value: 169 },\n];\n\nconst DEFAULT_ZONES: RangeAreaChartZone[] = [\n  { visible: true, label: \"Release train\", color: \"#B8A6FF\", startIndex: 3, endIndex: 5 },\n  { visible: true, label: \"Forecast\", color: \"#F2A841\", startIndex: 7, endIndex: 9 },\n];\n\nconst DEFAULT_REF_LINE: Required<RangeAreaChartReferenceLine> = { visible: true, value: 262, label: \"p95 SLO\", color: \"#FF7A6B\" };\nconst DEFAULT_ANNOTATION: Required<RangeAreaChartAnnotation> = { visible: true, title: \"Risk crest\", subtitle: \"291 ms p95 band\", atIndex: 9, value: 291, color: \"#FF7A6B\" };\nconst DEFAULT_ENDPOINT: Required<RangeAreaChartEndpoint> = { visible: true, suffix: \"now\", color: \"#87FFE3\" };\n\nconst LIGHT_ZONES: RangeAreaChartZone[] = DEFAULT_ZONES.map((z, i) => ({ ...z, color: [\"#7C5CE0\", \"#D9822B\"][i] ?? z.color }));\nconst LIGHT_REF_LINE: Required<RangeAreaChartReferenceLine> = { ...DEFAULT_REF_LINE, color: \"#E5484D\" };\nconst LIGHT_ANNOTATION: Required<RangeAreaChartAnnotation> = { ...DEFAULT_ANNOTATION, color: \"#E5484D\" };\nconst LIGHT_ENDPOINT: Required<RangeAreaChartEndpoint> = { ...DEFAULT_ENDPOINT, color: \"#0E9F80\" };\n\nexport function RangeAreaChart({\n  theme = \"dark\",\n  title = \"Latency envelope\",\n  subtitle = \"\",\n  chartHeight = 420,\n  unit = \"ms\",\n  yMin = 70,\n  yMax = 300,\n  yStep = 50,\n  actualColor = theme === \"light\" ? \"#0E9F80\" : \"#87FFE3\",\n  forecastColor = theme === \"light\" ? \"#D9822B\" : \"#F2A841\",\n  bandColor = theme === \"light\" ? \"#3B6FD8\" : \"#8FB8FF\",\n  coreBandColor = theme === \"light\" ? \"#0E9F80\" : \"#87FFE3\",\n  forecastStartIndex = 7,\n  dataPoints = DEFAULT_DATA,\n  zones = theme === \"light\" ? LIGHT_ZONES : DEFAULT_ZONES,\n  referenceLine = theme === \"light\" ? LIGHT_REF_LINE : DEFAULT_REF_LINE,\n  annotation = theme === \"light\" ? LIGHT_ANNOTATION : DEFAULT_ANNOTATION,\n  endpoint = theme === \"light\" ? LIGHT_ENDPOINT : DEFAULT_ENDPOINT,\n  enableHover = true,\n  className,\n}: RangeAreaChartProps) {\n  const isDark = theme === \"dark\";\n  const containerRef = React.useRef<HTMLDivElement>(null);\n  const [hoverIndex, setHoverIndex] = React.useState<number | null>(null);\n  const [containerWidth, setContainerWidth] = React.useState(0);\n\n  React.useEffect(() => {\n    const el = containerRef.current;\n    if (!el) return;\n    const ro = new ResizeObserver(([entry]) => setContainerWidth(entry.contentRect.width));\n    ro.observe(el);\n    return () => ro.disconnect();\n  }, []);\n\n  // preserveAspectRatio=\"none\" stretches the SVG to fill its box; on a narrow\n  // container that non-uniform scaling thins axis-label text to illegibility, so\n  // below the viewBox's natural aspect ratio we shrink the box to match it.\n  const compact = containerWidth > 0 && containerWidth < 560;\n  const vbW = compact ? 640 : VB_W;\n  const labelStep = compact ? 3 : 1;\n  const effectiveHeight = containerWidth > 0 ? Math.min(chartHeight, containerWidth * (VB_H / vbW)) : chartHeight;\n\n  // Keep axis labels a readable ~11px on screen regardless of how far the viewBox is scaled down.\n  const viewScale = containerWidth > 0 ? Math.min(containerWidth / vbW, effectiveHeight / VB_H) : 0.5;\n  const axisFontSize = Math.min(24, Math.max(11, 11 / viewScale));\n\n  const palette = {\n    cardBg: isDark ? \"#0E0E0E\" : \"#ffffff\",\n    cardBorder: isDark ? \"rgba(255,255,255,0.08)\" : \"rgba(0,0,0,0.06)\",\n    textPrimary: isDark ? \"#f4f5f7\" : \"#111317\",\n    textSub: isDark ? \"rgba(255,255,255,0.55)\" : \"rgba(17,19,23,0.55)\",\n    gridLine: isDark ? \"rgba(255,255,255,0.07)\" : \"rgba(17,19,23,0.08)\",\n    axisText: isDark ? \"rgba(255,255,255,0.7)\" : \"rgba(17,19,23,0.7)\",\n    badgeBorder: isDark ? \"rgba(255,255,255,0.12)\" : \"rgba(0,0,0,0.08)\",\n    hoverLine: isDark ? \"rgba(255,255,255,0.55)\" : \"rgba(17,19,23,0.45)\",\n    tooltipBg: isDark ? \"rgba(14,14,14,0.96)\" : \"rgba(255,255,255,0.97)\",\n    tooltipText: isDark ? \"#f4f5f7\" : \"#111317\",\n  };\n\n  const headerHeight = (title ? 30 : 0) + (subtitle ? 22 : 0);\n  const n = dataPoints.length;\n  const plotTop = PAD_TOP + headerHeight;\n  const geo = makeGeometry(n, plotTop, yMin, yMax, vbW, compact ? 96 : PAD_LEFT, compact ? 24 : PAD_RIGHT);\n\n  const yTicks = React.useMemo(() => buildTicks(yMin, yMax, yStep), [yMin, yMax, yStep]);\n\n  // eslint-disable-next-line react-hooks/exhaustive-deps\n  const outerTop = React.useMemo(() => dataPoints.map((d, i) => ({ x: geo.xAt(i), y: geo.yAt(d.max) })), [dataPoints, n, yMin, yMax, vbW, compact]);\n  // eslint-disable-next-line react-hooks/exhaustive-deps\n  const outerBottom = React.useMemo(() => dataPoints.map((d, i) => ({ x: geo.xAt(i), y: geo.yAt(d.min) })), [dataPoints, n, yMin, yMax, vbW, compact]);\n\n  const forecastIdx = clamp(forecastStartIndex, 0, n - 1);\n  const coreSlice = dataPoints.slice(0, forecastIdx + 1);\n  const coreTop = coreSlice.map((d, i) => ({ x: geo.xAt(i), y: geo.yAt(d.coreMax) }));\n  const coreBottom = coreSlice.map((d, i) => ({ x: geo.xAt(i), y: geo.yAt(d.coreMin) }));\n\n  const actualSlice = dataPoints.slice(0, forecastIdx + 1);\n  const forecastSlice = dataPoints.slice(forecastIdx);\n  const actualPts = actualSlice.map((d, i) => ({ x: geo.xAt(i), y: geo.yAt(d.value) }));\n  const forecastPts = forecastSlice.map((d, i) => ({ x: geo.xAt(i + forecastIdx), y: geo.yAt(d.value) }));\n\n  const lastIdx = n - 1;\n  const endpointValue = dataPoints[lastIdx]?.value ?? 0;\n  const annotationX = geo.xAt(clamp(annotation.atIndex, 0, n - 1));\n  const annotationY = geo.yAt(annotation.value) - 46;\n\n  const hover = React.useMemo(() => {\n    if (hoverIndex === null) return null;\n    const idx = clamp(hoverIndex, 0, n - 1);\n    const d = dataPoints[idx];\n    if (!d) return null;\n    const isForecast = idx > forecastIdx;\n    const valueColor = isForecast ? forecastColor : actualColor;\n    const items = [\n      { key: \"max\", label: \"Max\", value: d.max, y: geo.yAt(d.max), color: bandColor },\n      { key: \"value\", label: isForecast ? \"Forecast\" : \"Now\", value: d.value, y: geo.yAt(d.value), color: valueColor },\n      { key: \"min\", label: \"Min\", value: d.min, y: geo.yAt(d.min), color: bandColor },\n    ].sort((a, b) => a.y - b.y);\n    const minGap = 20;\n    for (let i = 1; i < items.length; i++) {\n      if (items[i].y - items[i - 1].y < minGap) items[i].y = items[i - 1].y + minGap;\n    }\n    return { time: d.time, items };\n    // eslint-disable-next-line react-hooks/exhaustive-deps\n  }, [hoverIndex, dataPoints, forecastIdx, bandColor, actualColor, forecastColor, yMin, yMax]);\n\n  const handleMove = (e: React.MouseEvent<HTMLDivElement>) => {\n    if (!enableHover || !containerRef.current) return;\n    const rect = containerRef.current.getBoundingClientRect();\n    const relX = clamp((e.clientX - rect.left) / rect.width, 0, 1);\n    const svgX = relX * vbW;\n    if (svgX < geo.plotLeft || svgX > geo.plotRight) {\n      setHoverIndex(null);\n      return;\n    }\n    const idx = Math.round(((svgX - geo.plotLeft) / geo.plotWidth) * (n - 1));\n    setHoverIndex(clamp(idx, 0, n - 1));\n  };\n\n  const handleLeave = () => setHoverIndex(null);\n\n  return (\n    <div\n      className={cn(\"box-border flex w-full flex-col gap-1 overflow-hidden rounded-[20px]\", className)}\n      style={{ backgroundColor: palette.cardBg, border: `1px solid ${palette.cardBorder}`, padding: \"28px 32px\", fontFamily: \"Inter, -apple-system, BlinkMacSystemFont, sans-serif\" }}\n    >\n      {title && <div className=\"text-center text-[17px] font-bold\" style={{ color: palette.textPrimary }}>{title}</div>}\n      {subtitle && (\n        <div className=\"mx-auto mt-0.5 max-w-[760px] text-center text-[12.5px] leading-[1.5]\" style={{ color: palette.textSub }}>\n          {subtitle}\n        </div>\n      )}\n\n      <div ref={containerRef} onMouseMove={handleMove} onMouseLeave={handleLeave} className=\"relative mt-3 w-full\" style={{ height: effectiveHeight }}>\n        <svg width=\"100%\" height=\"100%\" viewBox={`0 0 ${vbW} ${VB_H}`} preserveAspectRatio=\"none\" className=\"block overflow-visible\">\n          {zones.map(\n            (z, zi) =>\n              z.visible !== false && (\n                <g key={`zone-${zi}`}>\n                  <rect\n                    x={geo.xAt(clamp(z.startIndex, 0, n - 1))}\n                    y={geo.plotTop}\n                    width={geo.xAt(clamp(z.endIndex, 0, n - 1)) - geo.xAt(clamp(z.startIndex, 0, n - 1))}\n                    height={geo.plotHeight}\n                    fill={z.color}\n                    opacity={isDark ? 0.14 : 0.08}\n                  />\n                  <text\n                    x={(geo.xAt(clamp(z.startIndex, 0, n - 1)) + geo.xAt(clamp(z.endIndex, 0, n - 1))) / 2}\n                    y={geo.plotTop + axisFontSize + 8}\n                    textAnchor=\"middle\"\n                    fontSize={axisFontSize}\n                    fill={palette.axisText}\n                  >\n                    {compact ? \"\" : z.label}\n                  </text>\n                </g>\n              ),\n          )}\n\n          {yTicks.map((v) => (\n            <g key={v}>\n              <line x1={geo.plotLeft} x2={geo.plotRight} y1={geo.yAt(v)} y2={geo.yAt(v)} stroke={palette.gridLine} strokeWidth={1} />\n              <text x={geo.plotLeft - 14} y={geo.yAt(v) + axisFontSize * 0.35} textAnchor=\"end\" fontSize={axisFontSize} fill={palette.axisText}>\n                {v} {unit}\n              </text>\n            </g>\n          ))}\n\n          {dataPoints.map((d, i) =>\n            i % labelStep !== 0 ? null : (\n            <text key={i} x={geo.xAt(i)} y={geo.plotBottom + 12 + axisFontSize} textAnchor=\"middle\" fontSize={axisFontSize} fill={palette.axisText}>\n              {d.time}\n            </text>\n          ))}\n\n          <path d={smoothBandPath(outerTop, outerBottom)} fill={bandColor} opacity={isDark ? 0.22 : 0.14} stroke=\"none\" />\n          {coreTop.length > 1 && <path d={smoothBandPath(coreTop, coreBottom)} fill={coreBandColor} opacity={isDark ? 0.3 : 0.18} stroke=\"none\" />}\n\n          {referenceLine.visible && (\n            <>\n              <line x1={geo.plotLeft} x2={geo.plotRight} y1={geo.yAt(referenceLine.value)} y2={geo.yAt(referenceLine.value)} stroke={referenceLine.color} strokeWidth={1.3} strokeDasharray=\"6 5\" opacity={0.7} />\n              <text x={geo.plotLeft + 4} y={geo.yAt(referenceLine.value) - 8} fontSize={axisFontSize} fontWeight={700} fill={referenceLine.color}>\n                {referenceLine.label}\n              </text>\n            </>\n          )}\n\n          <path d={smoothLinePath(actualPts)} fill=\"none\" stroke={actualColor} strokeWidth={2.4} strokeLinecap=\"round\" strokeLinejoin=\"round\" />\n          <path d={smoothLinePath(forecastPts)} fill=\"none\" stroke={forecastColor} strokeWidth={2.4} strokeLinecap=\"round\" strokeLinejoin=\"round\" />\n\n          {dataPoints.map((d, i) => (\n            <circle key={`dot-${i}`} cx={geo.xAt(i)} cy={geo.yAt(d.value)} r={3.2} fill={i <= forecastIdx ? actualColor : forecastColor} />\n          ))}\n\n          {enableHover && hoverIndex !== null && (\n            <line\n              x1={geo.xAt(clamp(hoverIndex, 0, n - 1))}\n              x2={geo.xAt(clamp(hoverIndex, 0, n - 1))}\n              y1={geo.plotTop}\n              y2={geo.plotBottom}\n              stroke={palette.hoverLine}\n              strokeWidth={1.3}\n              strokeDasharray=\"5 5\"\n            />\n          )}\n        </svg>\n\n        {annotation.visible && !compact && (\n          <div\n            className=\"absolute min-w-[150px] max-w-[220px] rounded-[10px] px-3.5 py-2\"\n            style={{\n              left: `${(annotationX / vbW) * 100}%`,\n              top: `${(annotationY / VB_H) * 100}%`,\n              transform: \"translate(-30%, -100%)\",\n              backgroundColor: isDark ? \"rgba(14,14,14,0.94)\" : \"rgba(255,255,255,0.96)\",\n              border: `1px solid ${annotation.color}55`,\n              boxShadow: isDark ? \"0 10px 28px rgba(0,0,0,0.5)\" : \"0 6px 20px rgba(0,0,0,0.12)\",\n            }}\n          >\n            <div className=\"text-[10.5px] font-extrabold tracking-[0.6px] uppercase\" style={{ color: annotation.color }}>\n              {annotation.title}\n            </div>\n            <div className=\"mt-0.5 text-[12.5px] font-bold whitespace-nowrap\" style={{ color: palette.textPrimary }}>\n              {annotation.subtitle}\n            </div>\n          </div>\n        )}\n\n        {endpoint.visible && (\n          <div\n            className=\"absolute rounded-full px-3.5 py-1.5 text-[12px] font-extrabold whitespace-nowrap\"\n            style={{\n              left: `${(geo.xAt(lastIdx) / vbW) * 100}%`,\n              top: `${((compact ? geo.plotTop : geo.yAt(endpointValue)) / VB_H) * 100}%`,\n              transform: compact ? \"translate(-100%, calc(-100% - 8px))\" : \"translate(8px, -50%)\",\n              backgroundColor: endpoint.color,\n              color: readableTextOn(endpoint.color),\n              boxShadow: `0 0 16px ${endpoint.color}55`,\n            }}\n          >\n            {Math.round(endpointValue)} {unit} {endpoint.suffix}\n          </div>\n        )}\n\n        {enableHover &&\n          hover &&\n          hover.items.map((it) => (\n            <div\n              key={`hb-${it.key}`}\n              className=\"absolute flex items-center gap-1 rounded-[5px] px-[7px] py-0.5 text-[10.5px] font-bold whitespace-nowrap\"\n              style={{\n                left: `${(geo.plotLeft / vbW) * 100}%`,\n                top: `${(it.y / VB_H) * 100}%`,\n                transform: \"translate(-100%, -50%)\",\n                backgroundColor: it.key === \"value\" ? it.color : `${it.color}cc`,\n                color: readableTextOn(it.color),\n              }}\n            >\n              <span className=\"opacity-85\">{it.label}</span>\n              <span>{Math.round(it.value)}</span>\n            </div>\n          ))}\n\n        {enableHover && hoverIndex !== null && hover && (\n          <div\n            className=\"absolute rounded-[7px] px-[11px] py-[5px] text-[11.5px] font-semibold whitespace-nowrap pointer-events-none\"\n            style={{\n              left: `${(geo.xAt(clamp(hoverIndex, 0, n - 1)) / vbW) * 100}%`,\n              top: `${(geo.plotBottom / VB_H) * 100}%`,\n              transform: \"translate(-50%, 6px)\",\n              backgroundColor: palette.tooltipBg,\n              border: `1px solid ${palette.badgeBorder}`,\n              color: palette.tooltipText,\n              boxShadow: isDark ? \"0 8px 24px rgba(0,0,0,0.4)\" : \"0 4px 16px rgba(0,0,0,0.1)\",\n            }}\n          >\n            {hover.time}\n          </div>\n        )}\n      </div>\n    </div>\n  );\n}\n",
      "type": "registry:component"
    }
  ],
  "type": "registry:component"
}