F1b: user fixes

Use the existing Plotly card and registered Sankey trace. Build transition totals from the remaining stages and omit zero-flow links. Build the prevalence donut from the report counts, with a grey slice for missing sex and controls to highlight each recorded sex. Use grouped bars for M23 and separate age and sex stacks for M24. Use the existing stacked history style for M31 and put the M30 figure behind one page flag. Cover the builders and the existing TEA page case.
This commit is contained in:
2026-12-01 11:33:06 -06:00
parent 7c98566579
commit c4920ed7eb
7 changed files with 451 additions and 57 deletions
+23 -3
View File
@@ -10,11 +10,25 @@ test('tea indicators: every tab loads, and the follow-up list exports to Excel',
);
await page.goto('/indicadores/tea');
const measures = (await (await listed).json()).entry.length;
expect(measures).toBe(11);
await expect(page.getByRole('tab', { name: 'Resumen' })).toBeVisible();
await expect(page.locator('app-tab-indicadores [data-measure]').first()).toBeVisible();
const indicators = page.locator('app-tab-indicadores');
await expect(indicators.locator('[data-measure]')).toHaveCount(10);
await expect(indicators.locator('[data-figure="sankey"] .sankey')).toBeVisible();
await expect(indicators.locator('[data-figure="sex-donut"] .pielayer')).toBeVisible();
await expect(
indicators.getByRole('heading', { name: 'Porcentaje de EEG normal y anormal' }),
).toHaveCount(0);
await page.getByRole('tab', { name: 'Trazabilidad' }).click();
await expect(page.getByText('Progresión del proceso diagnóstico')).toBeVisible();
const history = page.locator('app-tab-trazabilidad');
await expect(history.locator('[data-measure]')).toHaveCount(11);
await expect(
history.getByRole('heading', { name: 'Prevalencia registrada de TEA' }),
).toBeVisible();
await expect(
history.getByRole('heading', { name: 'Porcentaje de EEG normal y anormal' }),
).toBeVisible();
await expect(page.locator('app-tab-trazabilidad app-plot').first()).toBeVisible();
await page.getByRole('tab', { name: 'Seguimiento' }).click();
@@ -40,7 +54,13 @@ test('tea indicators: every tab loads, and the follow-up list exports to Excel',
await expect(risk.getByText('No hay registros para los filtros aplicados.')).toBeVisible();
await page.getByRole('tab', { name: 'Datos y definiciones' }).click();
await expect(page.locator('app-tab-definiciones details')).toHaveCount(measures);
const definitions = page.locator('app-tab-definiciones');
await expect(definitions.locator('details')).toHaveCount(measures);
await expect(
definitions.getByText('Porcentaje de EEG normal y anormal', { exact: true }),
).toBeVisible();
await definitions.getByText('Prevalencia registrada de TEA', { exact: true }).click();
await expect(definitions.getByText(/Every child loaded on the platform/)).toBeVisible();
expect(problems).toEqual([]);
});