Use linear interpolation in bookability history charts

Remove shape:'hv' step interpolation from rate and occupancy traces —
defaults to diagonal lines matching the market view history graphs.
Also fixes CSS var() used as a Plotly colour (invalid, replaced with hex).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
jtricerolph 2026-07-12 13:42:36 +00:00
parent 808fa6f8b2
commit 60fdda8129

View file

@ -1180,7 +1180,7 @@ function OccHistoryModal({ target, onClose }: { target: HistoryTarget; onClose:
type: 'scatter' as const, type: 'scatter' as const,
mode: 'lines+markers' as const, mode: 'lines+markers' as const,
name, name,
line: { color: TRACE_COLORS[i % TRACE_COLORS.length], shape: 'hv' as const, width: 2 }, line: { color: TRACE_COLORS[i % TRACE_COLORS.length], width: 2 },
marker: { marker: {
size: 8, size: 8,
color: pts.map(p => p.t!.available ? '#16a34a' : '#dc2626'), color: pts.map(p => p.t!.available ? '#16a34a' : '#dc2626'),
@ -1202,7 +1202,7 @@ function OccHistoryModal({ target, onClose }: { target: HistoryTarget; onClose:
name: 'Occupancy %', name: 'Occupancy %',
fill: 'tozeroy' as const, fill: 'tozeroy' as const,
fillcolor: 'rgba(201,168,76,0.12)', fillcolor: 'rgba(201,168,76,0.12)',
line: { color: 'var(--gold, #c9a84c)', shape: 'hv' as const, width: 2 }, line: { color: '#c9a84c', width: 2 },
marker: { size: 5, color: '#c9a84c' }, marker: { size: 5, color: '#c9a84c' },
} }
}, [occData]) }, [occData])