T17: sweep of the WebApp after the feature-parity work
Removed the legacy indicator layout, unused chart helpers, styles and exports, the card-actions component, fetch-all and explanatory comments; one pager shared by the four worklists, shared filter-row styles, one FHIR name and CURP reader, downloads through export/, the concept-map editor on Material controls.
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
import type { PdfContent } from '../export/pdf';
|
||||
import { downloadPdf } from '../export/pdf';
|
||||
import { safeName } from '../export/safe-name';
|
||||
import { downloadPdf, safeName, type PdfContent } from '../export';
|
||||
import type { Figure } from '../plot';
|
||||
import plotly from '../plotly-bundle';
|
||||
import { adosItems, adosSummary, alteration, Pair, percent, shown, TeaPatient } from './tea-data';
|
||||
@@ -8,7 +6,7 @@ import { forest, headMap, probabilityCurve, zBars } from './tea-figures';
|
||||
|
||||
type Table = { headers: string[]; rows: string[][] };
|
||||
type Chart = { title: string; figure: Figure; height?: number };
|
||||
export type Block = {
|
||||
type Block = {
|
||||
title?: string;
|
||||
fields?: string[][];
|
||||
table?: Table;
|
||||
@@ -20,9 +18,9 @@ export type Section = { title: string; blocks: Block[] };
|
||||
export const forestTitle = 'Razones de momios por par';
|
||||
export const probabilityTitle = 'Probabilidad según z';
|
||||
|
||||
export const calculation =
|
||||
const calculation =
|
||||
'El modelo estima, para cada par de métrica o zona del EEG y resultado del ADOS-2, la probabilidad de un puntaje elevado de severidad calibrada (CSS) o de un ítem alterado. La razón de momios corresponde al cambio asociado con una unidad de z. La probabilidad de referencia corresponde a z = 0, la edad media y el módulo más frecuente de la cohorte.';
|
||||
export const limitations =
|
||||
const limitations =
|
||||
'Las estimaciones dependen de la cohorte de referencia, de la calidad del EEG y de la disponibilidad de mediciones y pares. Las asociaciones no establecen causalidad. Las probabilidades no sustituyen la evaluación clínica ni establecen un diagnóstico.';
|
||||
|
||||
function associationRows(pairs: Pair[]): string[][] {
|
||||
@@ -150,7 +148,7 @@ export function riskSections(patient: TeaPatient, alteredOnly: boolean, pair?: P
|
||||
];
|
||||
}
|
||||
|
||||
export function probabilityRows(pairs: Pair[]): Table {
|
||||
function probabilityRows(pairs: Pair[]): Table {
|
||||
return {
|
||||
headers: ['Par', 'Probabilidad', 'Referencia'],
|
||||
rows: pairs.map((p) => [
|
||||
@@ -165,7 +163,11 @@ export function teaPdfName(page: 'seguimiento' | 'riesgos', day = new Date()): s
|
||||
return safeName(['tea', page, day.toISOString().slice(0, 10)]);
|
||||
}
|
||||
|
||||
export function teaPdfContent(title: string, sections: Section[], images: (string | undefined)[]): PdfContent[] {
|
||||
export function teaPdfContent(
|
||||
title: string,
|
||||
sections: Section[],
|
||||
images: (string | undefined)[],
|
||||
): PdfContent[] {
|
||||
const charts = images[Symbol.iterator]();
|
||||
const content: PdfContent[] = [{ text: title, fontSize: 18, bold: true }];
|
||||
for (const section of sections) {
|
||||
|
||||
Reference in New Issue
Block a user