`;
}
export function renderSeasonalCardExpanded(task: MaintenanceTask, lang: string) {
return renderSeasonalChart(task, lang);
}
// Module-private — only the `renderSeasonalCardExpanded` wrapper above is part
// of the renderers/ public surface. Drop the keyword so esbuild sees the
// symbol as internal and tree-shakes it cleanly when the wrapper changes.
function renderSeasonalChart(task: MaintenanceTask, lang: string) {
const factors = task.seasonal_factors
?? task.interval_analysis?.seasonal_factors;
if (!factors || factors.length !== 12) return nothing;
const reason = task.interval_analysis?.seasonal_reason;
const currentMonth = new Date().getMonth();
const W = 300, H = 100;
const PAD_T = 8, PAD_B = 4;
const chartH = H - PAD_T - PAD_B;
const maxFactor = Math.max(...factors, 1.5);
const barW = W / 12;
const barInner = barW * 0.65;
const baselineY = PAD_T + chartH - (1.0 / maxFactor) * chartH;
return html`