Compare commits

..

194 Commits

Author SHA1 Message Date
Angel Capetillo Zavala fb54cfb188 Merge feature/tea-eeg-analysis into dev (TEA age norm and ADOS-2 relation) 2026-11-21 12:23:41 -06:00
alberto 4e9b25bd8f feat(tea): read the age-norm curve, the age at the EEG and the ADOS-2 relation from the WebApi's FHIR answer 2026-11-21 11:17:59 -06:00
alberto 68e2930e65 chore(tea): drop the local simulated-server mode; TEA follow-up reads only the WebApi 2026-11-21 01:30:45 -06:00
Angel Capetillo Zavala bb957ec6a4 fix(indicadores): format the hover text of CaCu's donuts per sector 2026-11-21 01:29:18 -06:00
Angel Capetillo Zavala 02e28e624b feat(indicadores): read CaCu category groups and stratified compositions from FHIR 2026-11-21 01:29:18 -06:00
Angel Capetillo Zavala 08161db1c4 feat(indicadores): map CaCu measures to the indicator ids the page reads 2026-11-21 01:27:59 -06:00
ulises fa029d69b8 Seguimiento TEA: gráfica de la norma por edad con el paciente
El panel de la derecha muestra el mapa de zonas o la norma por edad (bandas
5-95 y 25-75 %, mediana y el punto del paciente). Datos de ejemplo.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 00:50:10 -06:00
ulises 67ae7f482f TEA: el panel de relación con el ADOS-2 muestra solo las zonas alteradas del paciente
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 00:50:10 -06:00
ulises 304c563845 TEA: panel «Relación con el ADOS-2» en la ficha del paciente (prototipo) y modo simulado local
El panel muestra, por cada asociación clara de la cohorte (modelo de OR), la zona del EEG con el z del
paciente, el aspecto del ADOS-2, el OR con su intervalo, la probabilidad para el paciente y lo observado.
El campo relacion_ados2 es opcional. El modo simulado (servidor de prueba en Python y configuración
«simulado» de Angular) es solo para trabajar en local.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 00:50:10 -06:00
AlbertoPMDM ef4f606648 fix(tea): one card per EEG metric and the electrode map within its column
(cherry picked from commit b53322ed72)
2026-11-20 21:56:05 -06:00
AlbertoPMDM b53322ed72 fix(tea): one card per EEG metric and the electrode map within its column 2026-11-20 19:52:10 -06:00
Manuel Aurrecoechea Castillo c32d2b6012 feat(indicadores): show full domain names and share CaMa's summary
CaCu and TEA use the same menu labels and compact summary layout as cáncer de mama.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-20 19:28:27 -06:00
Angel Capetillo Zavala c2c6d9ef47 Merge feature/tea-eeg-analysis into dev (TEA candidate composition) 2026-11-20 14:44:48 -06:00
angel d4d3ea3837 Merge pull request 'Restore published CaMa histopathology and mammography counts' (#14) from fix/cama-reversion-selectiva into dev 2026-11-20 10:03:41 -06:00
Angel Capetillo Zavala 3385df4ba3 Merge current WebApp dev into the CaMa selective rollback 2026-11-20 09:57:32 -06:00
Manuel Aurrecoechea Castillo 96b1cabb5a feat(cama): space the opportunity strip, share its period and unify history lines
The section sat flush against its cards, each card repeated the period, the history selector was taller than the summary, and each CaMa line used a different color.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-20 09:49:32 -06:00
Angel Capetillo Zavala 366591f247 fix(cama): restore published histopathology and mammography counts 2026-11-20 09:07:38 -06:00
angel 241631b884 Merge pull request 'Finalize CaMa wording, demo mammography counts and histologic classification' (#13) from feature/cama-clasificacion-histologica into dev 2026-11-20 00:52:29 -06:00
Angel Capetillo Zavala 6c063344a3 feat(cama): adjust summary wording, double mastography counts and classify histologic types
Reword the histopathologic confirmation note, the BI-RADS 4, 5 or 6 titles and the
radiologic interpretation time title. Show twice the BI-RADS 4, 5 or 6 mastography
counts in the FHIR and base data services. Add the histologic type classification
and a follow-up table column that appears only when a row carries tipo_histologico.
2026-11-20 00:32:27 -06:00
angel 2f5b1ce1f2 Merge pull request 'Feature/cama audit histopathology demo' (#12) from feature/cama-audit-histopathology-demo into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/12
2026-11-19 19:45:53 -06:00
Angel Capetillo Zavala 56b3ac6b0c feat(cama): add synthetic histopathology breakdown for demo 2026-11-19 19:36:18 -06:00
Angel Capetillo Zavala f6603ae76e fix(cama): align BI-RADS labels and remove historical detection chart 2026-11-19 19:04:22 -06:00
Manuel Aurrecoechea Castillo 21ae95b5ed 20261119 CaMa: ayuda en cada dona de BI-RADS
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-19 18:11:20 -06:00
Manuel Aurrecoechea Castillo ce2e86c045 20261119 CaMa: cada dona de BI-RADS lleva su título y la categoría más alta
El resumen ya no repite el porcentaje publicado; pacientes y mastografías se leen en su propia gráfica.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-19 18:05:40 -06:00
angel 0f8eb0ec94 Merge pull request 'Add unavailable CaMa diagnosis-to-treatment card' (#11) from feature/cama-diagnosis-to-treatment-card into dev 2026-11-19 17:51:43 -06:00
Angel Capetillo Zavala 2f6d419453 Add unavailable CaMa diagnosis-to-treatment card 2026-11-19 17:48:13 -06:00
Manuel Aurrecoechea Castillo f34f9e1607 20261119 favico 2026-11-19 17:17:45 -06:00
Manuel Aurrecoechea Castillo c7dd134fce 20261119 CaMa titulos ayuda filtros
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-19 17:13:07 -06:00
Manuel Aurrecoechea Castillo 03cc9c9800 20261119 CaMa: donas de BI-RADS y etiquetas del resumen
La oportunidad dice confirmación histopatológica, la tarjeta de mastografías muestra dos donas y Cómo leer puede reintentar los metadatos.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-19 15:50:01 -06:00
AlbertoPMDM 04795a09cc feat(tea): read the EEG analysis's verdict, quality checks and age baselines 2026-11-19 15:43:27 -06:00
Manuel Aurrecoechea Castillo de3d247d0d 20261119 Favicon colores textos 2026-11-19 15:10:59 -06:00
Angel Capetillo Zavala ee87bcb8d0 test(webapp): seed the visual login session in indicadores specs
The indicadores navigation, sections and cancer-journey specs routed through
the real routes without a session, so authGuard redirected to LoginPage.
Add auth.testing helpers that seed and clear the sessionStorage session, use
them in those specs, and add a spec that /indicadores/<dominio> without a
session presents LoginPage with returnUrl.
2026-11-19 11:33:26 -06:00
Erick ivan aaeea7a7b0 refactor(auth): keep the session in the browser
The WebApi no longer authenticates, so the login validates against the accounts in auth.service.ts and the session lives in sessionStorage. The guard, the domain guard and the filtering of the import workspace and governance stay as they were; the interceptor and the /auth proxy entries go away because nothing answers 401.
2026-11-19 10:32:25 -06:00
Erick ivan 7f17681409 feat(auth): login screen and domain-scoped navigation
Session login against /auth/*, with a guard on every route and an interceptor that returns to the login on 401. The header, the import workspace and both governance panels only offer the account's own domains (auth/dominios.ts), and a batch opens on the account's database.

The sign-in screen follows the app's palette: logo above the title, the action button in the shared tokens, and no register or password-recovery rows.
2026-11-19 09:36:54 -06:00
angel d72c18756f Merge pull request 'test(indicadores): follow the published CAM-03 title and the Análisis tab' (#10) from fix/ci-spec-contracts into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/10
2026-11-19 00:09:54 -06:00
Angel Capetillo Zavala baf5edca42 test(indicadores): follow the published CAM-03 title and the Análisis tab
The history names CAM-03 «Resultado histopatológico»; the CAM-03 expectation in the F4C spec
now uses that title.

The CaMa page does not offer the Análisis tab while CAMA_ANALYSIS_ENABLED is off. The journey
specs that open it run only while the flag is on and are reported as skipped otherwise. The
domain-change spec selects patients through the page instead of through that tab, so it keeps
checking that the selection is cleared and that CaCu and TEA keep their sections.
2026-11-18 23:41:41 -06:00
Manuel Aurrecoechea Castillo fefa28ae7a 20261118 Pastilla Fix 2026-11-18 16:53:56 -06:00
Manuel Aurrecoechea Castillo a217ddae38 20261118 Color Fix 2026-11-18 16:10:11 -06:00
Manuel Aurrecoechea Castillo 97fcb37761 20261118 Sharts Colors 2026-11-18 15:43:23 -06:00
Manuel Aurrecoechea Castillo 58ff3870be 20261118 colorfix front
Cambio de los colores de las graficas para tener una mejor armonía de colores y evitar el uso de la unión de colores que interpreten ideas falsas
2026-11-18 15:16:13 -06:00
Angel Capetillo Zavala 439a039ff4 fix(cama): recuperar el tamaño responsivo de la dona BI-RADS 2026-11-18 14:58:54 -06:00
Angel Capetillo Zavala 049a9ca43c fix(cama): ocultar temporalmente la pestaña Análisis 2026-11-18 14:15:49 -06:00
Angel Capetillo Zavala f128f2e13a fix(cama): mostrar solo el conteo al pasar sobre la dona 2026-11-18 13:15:54 -06:00
Angel Capetillo Zavala 20b8c80aaf fix(cama): equilibrar centro y anillo de la dona 2026-11-18 12:56:27 -06:00
Angel Capetillo Zavala 8e85c91f15 fix(cama): completar ajustes visuales de indicadores 2026-11-18 12:23:17 -06:00
Angel Capetillo Zavala 1ac8d5c258 fix(cama): ajustar resumen y ocultar análisis 2026-11-18 09:25:38 -06:00
Angel Capetillo Zavala 23cd89e882 Adjust CaMa indicator labels 2026-11-17 12:44:25 -06:00
Angel Capetillo Zavala 47a0ab5f1b Connect CaMa dashboard to follow-up, analysis and L3 FHIR measures
Preserve dev governance and risk-batch UI. Validate cohort navigation, API contracts and shared summary/history measures. Production build passes; 1785 tests pass with the six known Node 26 localStorage failures.
2026-11-17 10:44:08 -06:00
Roberto Treviño Cervantes dc37c54938 wording fixes 2026-11-17 02:17:24 -06:00
roberto 2834fac85c Merge pull request 'Kit exit: TEA over FHIR, dashboard-test presentation merged in' (#9) from feature/kit-exit-integration into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/9
2026-11-16 21:09:07 -06:00
Roberto Treviño Cervantes be77c50b45 Merge dashboard-test: the CaMa dashboard's presentation over the FHIR measures, with TEA's history and summary kept 2026-11-15 05:37:15 -06:00
Roberto Treviño Cervantes 40d8c8655e Merge remote-tracking branch 'origin/feature/163-tea-redesign' into feature/kit-exit-integration 2026-11-15 00:43:27 -06:00
Angel Capetillo Zavala 7580319fc8 fix(cama): single vertical scroll in Análisis epidemiológico
The visually-hidden labels are absolutely positioned and had no positioned ancestor in the view, so they were laid out against the document and, with the table far down the page, gave the document its own vertical scroll next to the one of the page container. The view is now their containing block.
2026-11-14 07:56:33 -06:00
Angel Capetillo Zavala 7a2f0f42a9 feat(cama): Análisis epidemiológico frame with category cards, cut-off bar and the BI-RADS count 2026-11-14 00:14:53 -06:00
alberto 4ffd3797b6 Indicators: the history chart and the KPI card read the total when a measure publishes more groups 2026-11-13 21:15:47 -06:00
alberto b42428b068 TEA: the EEG result measure draws one bar per alteration 2026-11-13 19:38:36 -06:00
Angel Capetillo Zavala 01d6e71f07 Accept 64-bit patient identifiers 2026-11-13 18:23:45 -06:00
Angel Capetillo Zavala 3b246b4f1f Identify follow-up patients by pac_id
Rows name their patient with pac_id (a decimal string) or the legacy
id_seudonimo. pac_id wins; an invalid pac_id is never replaced by the
legacy field, and a page that repeats a patient or mixes both fields is
not drawn or exported. The table, patient record, PDF and spreadsheet
follow the announced identifier column and label. CaCu requests risk
only with a pac_id.
2026-11-13 18:19:27 -06:00
Angel Capetillo Zavala caf5f954b7 Proxy patient routes without the cohort access token 2026-11-13 18:19:26 -06:00
edgar edb868f372 Patient record reads its risk from GET /cacu/pacientes/<pac_id>/riesgo, by the id the follow-up list shows 2026-11-13 17:29:54 -06:00
rockdrigo d9009a2e1e Indicators read the WebApi's FHIR endpoint; TEA follow-up, period summary and patient views, history and highlight figures; side navigation removed 2026-11-13 17:03:23 -06:00
Angel Capetillo Zavala 2e0938628c Merge commit '0acee49de2098b2f9d06607f7d374091a5f4b764' into dashboard-test
# Conflicts:
#	src/app/features/indicadores/etiquetas-cohorte.ts
#	src/app/features/indicadores/indicadores-seguimiento-cohorte.spec.ts
2026-11-13 15:45:55 -06:00
Angel Capetillo Zavala 3783505dbd Use the regular window for breast follow-up 2026-11-13 15:44:01 -06:00
Angel Capetillo Zavala 0acee49de2 fix(cama): regular follow-up opens on the 3-month window and adopts the cohort the server returns
The follow-up list asks for the regular window without quoting a revision; when the answer
names a cohort the next pages and the files quote it. A new cut-off or a revision that changed
under the list is asked for again without the old revision (once, then reported). Leaving the
analysis' selection returns to the regular window. A server that does not answer from the cohort
keeps the plain list.

Histopathology codes are written with the catalog labels (Benigno, Carcinoma in situ, Carcinoma
invasor, Desconocido); other values stay as they arrive.
2026-11-13 15:43:02 -06:00
Angel Capetillo Zavala 18e9260705 Keep breast follow-up on the selected cohort 2026-11-13 15:32:39 -06:00
Angel Capetillo Zavala 3f4cf2217f Merge commit '7971a49dcda5f9759f6cf4693c1c725153172edb' into dashboard-test 2026-11-13 15:23:06 -06:00
edgar bb2f49be37 Measures read from /<domain>/indicadores 2026-11-13 15:19:01 -06:00
edgar b68af3a48a KPIs page draws durations as boxes and reads a composition's categories from its first stratifier 2026-11-13 15:19:00 -06:00
edgar 7eb144e8fe KPIs page drawing CaCu's measures from the WebApi's FHIR MeasureReport bundles 2026-11-13 15:19:00 -06:00
Angel Capetillo Zavala 7971a49dcd feat(cama): regular follow-up read from the cohort, with the revision refreshed on a new cut-off
The follow-up tab of breast cancer now reads the cohort the analysis publishes: it asks for the
cohort's revision at today's cut-off and lists the whole cohort quoting it. Where the server does
not publish the cohort (404 or 503 on its aggregate) the plain follow-up list is read.

- Another cut-off in the form asks for that cut-off's revision before the list; a revision that
  changes under the list (409) is asked for again once and the same query repeated, and a conflict
  that persists is reported.
- "Quitar selección" returns to the whole cohort instead of another source.
- An empty whole cohort says "Sin pacientes para el corte seleccionado"; filters and windows keep
  the text of the filters.
- Filters, cut-off, page and rows are kept while a record is opened and closed.
- Page specs that open CaMa follow-up answer the aggregate first.
2026-11-13 15:18:11 -06:00
Angel Capetillo Zavala c06cce20df Pass synthetic cohort access through the server proxy 2026-11-13 15:17:14 -06:00
Angel Capetillo Zavala 2b0f6dfbed feat(cama): readable BI-RADS and age labels, the biopsy report date, and no export of a list that does not match its group
Contract review against WebApi 1d5f1e0 (webapi/cama_analysis.py, cama_cohort.py, docs/cama-cohort-api.md).

- The cohort's list is rewritten once on arrival so the table, the record and the PDF/XLSX show
  "BI-RADS 5" and "50 a 59 años" (also "Menores de 40 años", "70 años o más", "Sin dato"); the codes
  stay in `<clave>_codigo` and in the filter options, which are what the requests send. Only codes
  whose meaning the API's own code confirms are labelled; biopsy grades are left as they arrive.
- The record calls the biopsy date what the list calls it ("Fecha de reporte"): in the cohort it is
  the date of the biopsy report, which can be known while its result is not.
- With the same cohort revision, cut-off and filter the aggregate and the list are counted from the
  same rows, so a different total breaks the contract: the list shows an alert and its PDF/XLSX
  buttons are disabled.
- When no category is published the analysis says so and keeps "No publicado": the answer cannot
  tell an empty cohort from categories under the threshold.
- Tests: the chosen cut-off reaches the aggregate, the list, the record and every page of the file.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-13 14:29:45 -06:00
Angel Capetillo Zavala c509cb7f87 Connect TEA screening views to FHIR 2026-11-13 14:28:04 -06:00
Angel Capetillo Zavala 5807f218b1 Add TEA status measure view 2026-11-13 14:28:04 -06:00
Angel Capetillo Zavala 1d43ebff3b feat(indicadores): Análisis epidemiológico tab for breast cancer, and the way back from Seguimiento
A CaMa-only tab between Histórico and Seguimiento shows how many patients of the cohort fall in
each BI-RADS category at a cut-off (GET /cama/analisis/indicadores?corte=), as the cohort API
publishes it. It is a descriptive count, not an incidence or a survival estimate.

- Loading, pending (404), unavailable (503), error and out-of-contract states; the answer is
  validated as an aggregate (no patient rows, nothing published under the threshold).
- A suppressed category is drawn grey and says why; only a published category opens its patients
  in Seguimiento ("Ver pacientes" or a click on its bar).
- The page keeps the selection while the user moves between tabs, clears it on a domain change, and
  "Volver al análisis" returns to the analysis as it was, with the scroll and the focus on the
  control that opened the list, and no new request.
- Tables and figure scroll inside their own region at phone width. CaCu and TEA keep their three
  sections. Curves, the heatmap and the cohort diagnostics of the prototype wait for an API.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-13 14:07:34 -06:00
Angel Capetillo Zavala eb92b99a1d feat(seguimiento): list opened on a group of the cohort, with its window, cut-off, cohort and revision
The follow-up list of breast cancer can now be opened on a selection that the analysis names: the
whole cohort (window 0, offered only while the selection is active), the cut-off the analysis was
computed at, the group's filter, and the cohort with its revision, which the server requires and
repeats.

- A cohort's list quotes `cohorte`, `escenario` and `revision` (not filters) on every page and in the
  export; an answer that loses a filter, changes the window or the cut-off, or is another cohort or
  revision is not drawn and cannot be exported.
- A new selection cancels the previous request; while it loads, and when it fails (403, 409, 503),
  no list of the previous query stays on screen.
- Inside the cohort the form refines the same cohort and says so; "Quitar selección" leaves it.
- "Volver al análisis" and a note when the list holds a different number of patients than the
  analysis counted.
- PDF and XLSX state the selection, the cut-off and "Toda la cohorte"; the file name tells a
  selection apart; an export in progress is cancelled, and a finished one discarded, when the query
  on screen changes.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-13 14:07:31 -06:00
Roberto Treviño Cervantes 4d67b019a6 updating nlp policies; more robust recognition beyond rules 2026-11-13 11:52:42 -06:00
Roberto Treviño Cervantes 934a793da3 fix governance reqs; allow for sandboxed jupyter notebooks for testing 2026-11-13 11:52:42 -06:00
Roberto Treviño Cervantes e6abf44bef improve ingestion system to match isssteleon setup 2026-11-13 11:52:42 -06:00
Angel Capetillo Zavala ee75e7a2a0 Chore: Visual fix. 2026-11-13 00:01:18 -06:00
Angel Capetillo Zavala b84d428814 Add breast cancer follow-up reports and patient record 2026-11-12 22:40:21 -06:00
Angel Capetillo Zavala 17a91d3924 style(indicadores): CaMa header, simplified general filters and collapsible suppressed-data notes
CaMa header reads "Sistema TNM de clasificación tumoral" without the top subtitle.
The general filters block is titled "Filtros generales" and drops the scope
description and the applied-filter summary. In the Histórico the suppressed-data
text becomes a collapsed footnote (details/summary) with the same full text.
CaCu and TEA headers and filters are unchanged.
2026-11-12 13:20:04 -06:00
Angel Capetillo Zavala cda3563184 Verify follow-up against final API responses 2026-11-12 11:57:48 -06:00
Angel Capetillo Zavala 7a6f87d141 Remove demonstration notices from CaMa views 2026-11-12 11:57:47 -06:00
Angel Capetillo Zavala 78313adb4a style(indicadores): CaMa histopathology rates stay readable at phone width
The rates figure lets the category labels size their own margin, shortens the
axis title, keeps few ticks and wraps «BI-RADS 4 sin subtipo» when the window is
600 px wide or less, and is redrawn when the window crosses that width. Values
and states are unchanged. The reading text keeps the capitals of a category
code inside a sentence («lesión de riesgo (B3)»).
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala 7dc420773f feat(indicadores): CaMa detection and result-to-diagnosis indicators wired with real payloads
CAM-01 and CAM-02 already had their KPI cards and history panels waiting for the
catalog; they are now covered with the answers WebApi gives for the synthetic
base, both visible (lowered suppression threshold) and suppressed (normal
threshold). Once published they draw only their KPI card in the summary, as the
mockup does, instead of an extra generic figure card; their evolution stays in
the history.

The stacked history figure now keeps a category the catalog announces even when
no row carries it, so a missing category is named under the figure instead of
silently disappearing. The integration specs also cover the summary and the
history with CAM-01, CAM-02 and CAM-03 published.
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala 552e2c194f feat(indicadores): CaMa histopathology by BI-RADS drawn from the published matrix
The card for cama_histopatologia_birads now shows rates with their Wilson
interval per BI-RADS category and a two-ring donut of the biopsy result, with
group and category selection, period navigation and the published values table.
A pure adapter turns the stratified C2 response into rows and figures; the view
only asks for the data and draws what the adapter returns.

BI-RADS 4 is a row of its own. The denominator is benign, B3, in situ and
invasive; no biopsy and no data are reported apart. A published zero is a zero,
a suppressed cell is suppressed, and a cell or stratum the response does not
carry is unavailable, never zero: no rate or donut total is drawn over an
incomplete matrix. The card keeps its place first in the summary and stays
pending while the catalog does not publish the indicator.

The `birads` stratum is added to the accepted dimensions of the data request.
The CaCu cytology confirmation view is not touched.
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala 8f01f8693d feat(indicadores): CaMa follow-up tab drawn from the announced filters and columns
The tab asks GET /cama/seguimiento when it is first opened and draws the form,
the table, the details and the pagination from what the answer announces, so a
later change of source behind the endpoint needs no change here. It shows the
demonstration notice when the answer is simulated, a clear pending state while
the endpoint is not published (404 on the first page), and error, empty and
retry states. Stale requests are cancelled.

The sections, CaCu and initial-integration specs now expect the CaMa request
when the tab opens.
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala ad8444a788 feat(indicadores): generic follow-up client with a strict response contract
GET /<dominio>/seguimiento with the window, page, size, cut-off date and the filters the list announces. Filters and columns come with the answer; only demonstration answers (simulado: true) are accepted and anything outside the contract is rejected before it reaches a view. The fixture is the synthetic answer of the reference prototype and is used by tests only.
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala f78db1ae37 feat(indicadores): CaMa KPI cards show only their own line, as in the reference
The kit's notes are no longer appended to CaMa's opportunity cards (they stay in the figure footers, Histórico and Datos y definiciones). The four cards measure 308 x 220 px at 1366 px, like the reference. TEA keeps its notes and CaCu already hid them.
2026-11-12 11:35:27 -06:00
Angel Capetillo Zavala 0914b8db23 feat(indicadores): CaMa summary keeps the paired card and a pending histopathology card
Confirmation, screening-to-diagnosis and exam-to-result cards leave the summary (they stay in Histórico and Datos y definiciones). The histopathological result by BI-RADS keeps its place and structure as a pending card, with no figure or number, until the catalog publishes its indicator. The patients KPI uses the reference's wording.
2026-11-12 11:35:26 -06:00
Angel Capetillo Zavala 8aa66c6277 style(indicadores): CaMa's filter block as one compact row, as in the reference
Fields and Aplicar at 40 px, tighter padding and a small description. Only the CaMa block changes; CaCu and TEA keep their filters.
2026-11-12 11:35:26 -06:00
Angel Capetillo Zavala 1e1999f264 style(indicadores): Roboto headings, 4 px corners and the reference's title and card sizes, scoped to the indicators pages
Tokens are set on body when the indicators header is present, so menus, selects and dialogs share them; the other routes keep Rajdhani and their shapes.

(cherry picked from commit f5103b483d9d7188b4feffe91beda38d997004d4)
2026-11-12 01:43:27 -06:00
Angel Capetillo Zavala e95c175f9b fix(shell): load the domain menu deferred and let the header wrap on narrow screens
The menu and its overlay were in the initial bundle of every route (+183 kB); they now load in their own chunk, with a same-size placeholder. On phones the title moves to a second row instead of being squeezed beside the selector.

(cherry picked from commit 2ccddf80dbbe41a328281fcdc1c95ebe421f4191)
2026-11-12 01:43:27 -06:00
Angel Capetillo Zavala ff03a88ea0 feat(indicadores): domain navigation moves to the header; searchVisible reads the catalog before the domain
The in-page domain buttons are removed, since the header selector replaces them. Also fixes a computed that, after a visit to CaMa, never became true again, so CaCu and TEA lost their search box when switched to from CaMa.

(cherry picked from commit 3678c3653b33fcb98ba2334ca8f03f838dc86440)
2026-11-12 01:43:27 -06:00
Angel Capetillo Zavala d761a6fb1a feat(shell): indicators header with the platform title and a domain selector
On /indicadores/<dominio> the header shows «Plataforma de Indicadores» and a menu button with the current domain (TEA, CaCu, Cáncer de mama) that links to the other two through the router. Institutional routes keep their breadcrumb header.

(cherry picked from commit 79a18fd7a8ed1a3a58201e7cc24c9692b53dbc47)
2026-11-12 01:43:27 -06:00
Angel Capetillo Zavala 2982d482bf feat(indicadores): CaMa history tab with the charts the published contracts support
A Histórico tab between Resumen and Seguimiento, for CaMa only: monthly or semestral interval, how many periods to show, and a custom period dialog. Counts are stacked, rates draw their confidence band and medians their quartile band; suppressed periods are shaded and listed, and a rate over no denominator or a median over no observations is no value. Five charts use published indicators; the three whose indicator the catalog does not publish are drawn as pending panels.

(cherry picked from commit 268d7443e0a89da8d6bc67ecb2b5db2715236f93)
2026-11-12 01:43:26 -06:00
Roberto Treviño Cervantes 0ee53fd286 Remember SQL connections in the browser, never the password 2026-11-12 01:13:34 -06:00
Angel Capetillo Zavala 5e16f5454b fix(indicadores): reconcile CaMa period selection and contracts 2026-11-12 00:39:57 -06:00
Angel Capetillo Zavala ce3ed34fbf feat(indicadores): CaMa paired card of mammograms and patients by BI-RADS
One card draws the exams by category as a donut and, per BI-RADS family, the patients next to the exams. Patients come from cama_birads_456_paciente (each patient once per period, in the category of the most severe exam), so its exclusive categories are added within that indicator only, for the verified version 0.2.0; other versions, suppressed or missing cells leave the figure unknown. No exams-per-patient ratio is computed and patients are never derived from exams. The patients' indicator has no card of its own while the exams' one is published.

(cherry picked from commit b7bafd178896cb2715049d5c8293185f31391c92)
2026-11-12 00:29:14 -06:00
Angel Capetillo Zavala d159067efd feat(indicadores): CaMa clinical section heading and counter, without search, pins, navigation or representation selector
CaMa's graphic section reads «Indicadores clínicos» and counts the indicators it draws. The search box, pins, floating navigation, representation selector and figure count are not drawn for CaMa; CaCu and TEA keep them.

(cherry picked from commit e54ee5a55aa3722f6895300fa7e8cefb28f12ebb)
2026-11-12 00:29:14 -06:00
Angel Capetillo Zavala 7b8fd9e01d feat(indicadores): CaMa labels, single-period filters and the four-card strip
CaMa reads «cáncer de mama» everywhere on the indicators page and uses the compact filter: interval, one period and Aplicar on one row, without the mode selector, the multiple selection or the editing summaries. The opportunity strip is the four cards only, and the biopsy distribution card is no longer drawn in the summary (it stays in Datos y definiciones). Other domains keep their filter and strip.

(cherry picked from commit 7c9dcf634e5870fec35ab96347b0863b2e3bb86e)
2026-11-12 00:29:08 -06:00
Angel Capetillo Zavala 8a3f68df6b fix(indicadores): guard invalid C1 denominators and preserve status 2026-11-11 23:56:32 -06:00
Angel Capetillo Zavala bc75c058e1 feat(indicadores): CaMa's four opportunity cards, pending where the catalog lacks the indicator
Cards: patients with BI-RADS 4, 5 and 6, histopathological detection rate, screening to result and result to diagnosis times. The detection rate and the result-to-diagnosis time are not published by the catalog yet, so they are drawn as explicit pending cards and are queried once the catalog lists them. cama_eu38a is added to the CaMa KPIs.
2026-11-11 23:56:32 -06:00
edgar 62cdb252ca Measures read from /<domain>/indicadores 2026-11-08 01:37:43 -06:00
edgar 8f2906fe6f KPIs page draws durations as boxes and reads a composition's categories from its first stratifier 2026-11-08 01:16:04 -06:00
edgar e8628508d8 KPIs page drawing CaCu's measures from the WebApi's FHIR MeasureReport bundles 2026-11-08 00:33:01 -06:00
edgar 53edec8692 feat(tea): periodos personalizados en Histórico
«Personalizado…» en «Periodos a mostrar» abre un diálogo con los periodos del
intervalo elegido, por año. Las figuras muestran solo los elegidos, sin volver
a consultar, y cada intervalo recuerda su propia selección.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-06 15:21:18 -06:00
edgar a1ea31039e feat(tea): abrir las alteraciones del EEG con un mapa visible
Al desplegar un paciente se abre su primera alteración, o la primera métrica
si no tiene alteraciones.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-06 13:46:26 -06:00
edgar ef631e2c0b feat(tea): cambios de la reunión del 5 de noviembre
Resumen
- Estado del caso (completo, en proceso, fuera del protocolo) al cierre del
  periodo, en una figura y en el párrafo, separado de diagnóstico confirmado.
- Tiempos por paso: M-CHAT a ADOS-2, ADOS-2 a diagnóstico y total.
- Un solo formato: barras. M24 son barras apiladas por grupo de edad.
- «Descargar reporte» abre la impresión con el periodo y los indicadores
  seleccionados.

Histórico
- Porcentaje de casos en proceso, tiempos por paso en la misma escala y
  calidad de los EEG (indicador solo de esta pestaña, con `vistas`).
- Ejes con unidades y fechas como «mar 2025».

Seguimiento
- Columna y filtro de estado del caso, con lo que falta.
- Filtro por tipo de alteración y resumen de EEG que sigue los filtros.
- Módulo de ADOS-2 junto al puntaje.
- Tarjetas de alteraciones: al elegir una se apartan y aparece su mapa, sin
  caja, con leyenda de colores. Referencia por grupo de edad.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-06 13:38:53 -06:00
edgar 27dc7a0166 feat(tea): calidad del EEG con criterios de PREP y calificación general
- La calificación general es una palabra (Bueno, Aceptable o Malo), como en
  Automagic, y es la peor de sus criterios.
- Los criterios son lo que busca PREP, con números: canales afectados de 19 y
  ruido de línea en dB.
- Se quitan impedancia, artefactos, canales rechazados, segmentos útiles y el
  puntaje de 100.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-06 12:46:01 -06:00
edgar e6353f9f4c test(tea): nuevas alteraciones del EEG en el resumen del paciente
Ritmo posterior, husos de sueño N2 y N3, picos paroxísticos y gradiente
anteroposterior.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 11:55:07 -06:00
edgar 3bb9c2121d feat(tea): botones y rótulos en la dona C2 de un solo anillo
Sin grupos de categorías (M23), la dona de TEA se dibuja como la de M21: un
anillo con rótulos, el total al centro y un botón por categoría.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 23:56:54 -06:00
edgar 737c6f9f14 feat(tea): redactar el resumen según los pacientes de M23
M23 ya no cuenta los diagnósticos descartados: el párrafo dice ahora «evaluados
por psicología [...] diagnóstico confirmado o en proceso».

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 23:48:19 -06:00
edgar 8e543cbcc6 feat(tea): filtros de edad, M-CHAT y ADOS-2 en Seguimiento
- Filtros por grupo de edad, rango de riesgo M-CHAT-R/F y nivel de CSS ADOS-2.
  Se envían a la API como grupo_edad, mchat_min/max y css_min/max.
- Se quita «Ordenar por prioridad», también de CaCu, donde estaba deshabilitado.
- El grupo de edad menor pasa a 16-23 meses, igual que en los indicadores.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 23:06:37 -06:00
edgar ea7aad5067 test(tea): husos del sueño por etapa N2 y N3 en el resumen del paciente
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 22:56:25 -06:00
edgar 09b52e6b0a feat(tea): pestaña Histórico, colores por edad en EEG y acordeón en Seguimiento
- Evolución pasa a llamarse Histórico y añade «Periodos a mostrar»: los
  últimos 5, 10, 15... meses o semestres, según el intervalo elegido.
- M21 y M22 usan un color por grupo de edad, sin verde ni rojo, también en
  sus líneas de Histórico.
- Se quita el selector «Representación gráfica».
- Todas las filas de Seguimiento de TEA se despliegan en su lugar; se quita
  la ventana propia de los pacientes impares.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 22:41:05 -06:00
edgar 078db53ae4 feat(tea): pestaña Evolución y paleta con el verde de ISSSTELEON
- Pestaña Evolución (solo TEA), entre Resumen y Seguimiento: una figura por
  indicador con todos los periodos publicados, mensual o semestral. Barras
  apiladas para C2, línea con intervalo de confianza para C1 y mediana con
  cuartiles para C3r. Los periodos suprimidos se sombrean, no se dibujan
  como cero.
- Paleta: verde #A8C243 y rojo ladrillo #B8433A, comprobados para
  daltonismo. Las líneas usan un verde más oscuro sobre fondo claro.
- «Sin EEG» conserva su color en M21 y M22.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 22:09:02 -06:00
edgar 957f4cd024 feat(tea): botones para resaltar grupos y categorías en las figuras
- Leyenda con botones, como la distribución de resultados citológicos de
  cáncer cervicouterino: el grupo o la categoría elegida conserva su color,
  el resto se atenúa, «Volver» retrocede y un clic en la figura equivale al
  botón (indicadores-highlight.ts).
- M21, M22 y M24 con botones por grupo de edad; el centro de las donas
  muestra la selección.
- En TEA, la dona C2 de un periodo (M23) se dibuja con ambos anillos y
  botones, y sus barras también los tienen.
2026-11-03 21:22:51 +00:00
edgar 1ce8d98663 feat(tea): ficha de paciente en tres columnas y dona de M21 solo con EEG
- La ficha propia del paciente reparte los paneles en tres columnas
  (dos o una en pantallas más estrechas), con los puntajes por reactivo
  abiertos y un mapa más grande.
- La dona de M21 muestra solo a los pacientes con EEG por grupo de edad;
  el centro conserva el porcentaje total con EEG.
2026-11-03 20:28:14 +00:00
edgar 1771cb7ec6 feat(tea): ficha propia para la mitad de los pacientes de Seguimiento
Los pacientes con número impar abren su propia ventana, como la ficha de
cáncer cervicouterino (con «Regresar» y un resumen arriba); los pares
conservan el resumen desplegable en la fila. El encabezado de la ficha ya
nombra el dominio en lugar de decir siempre cáncer cervicouterino.
2026-11-03 19:58:30 +00:00
edgar b74f188b15 feat(tea): dona por grupo de edad para M21 y barras por grupo de edad para M22
- M21 (fig_c1_dona_edad): solo el anillo por grupo de edad, con el porcentaje
  total con EEG al centro.
- M22 (fig_c1_barras_edad): una barra por grupo de edad con el porcentaje de
  pacientes sin EEG.
- M24 conserva la dona de dos anillos.
2026-11-03 19:45:32 +00:00
edgar 5196f20e47 feat(tea): dona de dos anillos por grupo de edad para M21, M22 y M24
Figura fig_c1_donas para indicadores C1 de un semestre: el anillo interior
divide la población entre con y sin el evento, y el exterior cada parte por
grupo de edad, con el mismo dibujo que la distribución de resultados
citológicos de cáncer cervicouterino. Se construye con los datos
estratificados por grupo de edad.
2026-11-03 19:22:54 +00:00
edgar 5d4cd6f654 feat(indicadores): enlace «Ir» en el selector y seguimiento de TEA más compacto
- Se quita el botón flotante de navegación por indicadores.
- Cada opción de «Buscar indicadores» tiene un enlace «Ir» que lleva a su
  tarjeta (y la muestra si estaba oculta por la selección).
- Resumen del paciente en Seguimiento más compacto; «Puntajes por reactivo»
  plegado por defecto, con un triángulo para desplegarlo.
2026-11-03 19:22:54 +00:00
edgar a05717f92d feat(tea): intervalo de análisis, resumen más preciso y alteraciones del EEG
- Filtro general: «Intervalo de análisis» (Semestral/Mensual) en lugar de
  «Modalidad»; al cambiar de intervalo se elige el periodo más reciente.
- Resumen de TEA: evaluaciones con o sin diagnóstico y diagnóstico positivo
  de TEA explícito.
- Seguimiento: panel «Alteraciones del EEG» (exponente aperiódico, husos del
  sueño, entropía multiescala) con posibles efectos asociados. Datos de
  ejemplo, pendientes de validación médica.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 00:07:22 +00:00
edgar 123232592f feat(indicadores): un solo periodo y selector de indicadores gráficos
- El filtro general admite un único periodo (Elegir periodo); agregar otro lo reemplaza.
- Buscar indicadores pasa a ser una lista desplegable con casillas; solo los
  indicadores marcados se muestran en Indicadores gráficos, con Mostrar todos.
2026-10-30 23:24:38 +00:00
edgar 2cbb994667 feat(tea): seguimiento con resumen por paciente y resumen por periodo
- Pestaña Seguimiento de TEA: tabla de pacientes con filtro de alteraciones EEG
  y fila desplegable con ADOS-2 por reactivo, calidad del EEG y mapa topográfico
  (GET /tea/seguimiento/<id>).
- Indicadores destacados: M21 y M22 (pacientes con TEA con y sin EEG).
- Con un solo periodo elegido, TEA muestra un párrafo de resumen en lugar de
  las tarjetas.
2026-10-30 23:24:38 +00:00
Roberto Treviño Cervantes f4d2a3e85f add bitacora page, self-hosted fonts/icons, review fixes for the install package 2026-10-30 11:19:34 -06:00
Roberto Treviño Cervantes 8c63ed83ac preliminary release 2026-10-29 12:14:56 -06:00
Roberto Treviño Cervantes e6e6fb7210 preliminary release 2026-10-29 12:12:15 -06:00
angel 82efba35cb Merge pull request 'Feature/eu7 transiciones animadas' (#8) from feature/eu7-transiciones-animadas into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/8
2026-10-28 17:18:12 +00:00
Angel Capetillo Zavala 26fe1ccbb3 feat(cacu): preparar interfaz de riesgo individual de paciente 2026-10-28 10:36:58 -06:00
Angel Capetillo Zavala 94c63c460c feat(eu7): incorporar transiciones animadas en dona y barras 2026-10-28 09:45:00 -06:00
angel 05a9967906 Merge pull request 'feat(indicadores): integrar ajustes CaCu, ficha de paciente y mejoras de navegación' (#7) from feature/detalle-paciente-cacu into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/7
2026-10-27 21:26:28 +00:00
Angel Capetillo Zavala 1c0bdf6184 feat(indicadores): completar ficha CaCu y navegación clínica 2026-10-27 14:46:51 -06:00
Roberto Treviño Cervantes 51517ddf61 integrating latest dashboard changes 2026-10-26 01:42:32 -06:00
edgar 70aa739f97 Bitácora: IND1 ya no cita kpi_catalog.yaml en la ficha
CSO5.5
2026-10-25 21:25:26 +00:00
edgar 394f2c626b fix(indicadores): «Valores publicados» y la tabla de contingencia plegada
Las tablas desplegables decían «Valores publicados y celdas suprimidas» o «… y cajas no disponibles», que confundía: ahora dicen «Valores publicados». La tabla de contingencia de citología y biopsia estaba siempre a la vista; ahora va plegada bajo «Valores publicados», como las demás. Registrado en docs/bitacora-textos.md.

CSO5.5
2026-10-25 19:43:19 +00:00
edgar 644803cf21 docs: pendiente de IND1 (fecha de corte y calidad del espécimen)
CSO5.5
2026-10-25 19:33:54 +00:00
edgar 8e9a40dec4 docs: pendientes de los textos de Tiempo de tamizaje a diagnóstico
CSO5.5
2026-10-25 18:58:40 +00:00
edgar 1bdec1b838 docs: pendientes de la ficha técnica y de la consulta de calidad satisfactoria
El método estadístico y los campos nuevos de la ficha se posponen; los textos dirán «calidad de espécimen satisfactoria» y la consulta se alineará después.

CSO5.5
2026-10-25 18:36:30 +00:00
edgar 220d5b9d26 fix(indicadores): decir qué junta «Sin dato» bajo la dona de resultados citológicos
«Sin resultado válido en el periodo» no decía qué es un resultado válido. La nota ahora dice «con resultado no disponible o de calidad de espécimen insatisfactoria a la fecha de corte», que es lo que cuenta la consulta. Registrado en docs/bitacora-textos.md.

CSO5.5
2026-10-25 18:08:00 +00:00
edgar fbfd97ec31 fix(indicadores): decir cáncer cervicouterino en lugar de CaCu en pantalla
CaCu es el nombre que le dimos nosotros, no el que busca un médico. Las etiquetas de la página dicen «cáncer cervicouterino», con mayúscula donde abre el texto (la línea «Cáncer cervicouterino, investigación», que ya no dice «Dominio»). El botón del encabezado para cambiar de proyecto sigue diciendo «CaCu», provisional; las direcciones no cambian (/indicadores/cacu). El encabezado dice «Indicadores» en lugar de «Dashboard de indicadores» y el subtítulo «Explora los indicadores de …» sin mencionar el servicio de reportes. «Datos y definiciones» ya no repite «Dominio: …» bajo su título. TEA y CaMa conservan su nombre. Registrado en docs/bitacora-textos.md.

CSO5.5
2026-10-25 17:47:14 +00:00
edgar 18692acc88 fix(indicadores): tarjetas de CaCu sin el pie de las figuras y con cuartiles escritos
Las tarjetas de indicadores de oportunidad de CaCu mostraban, después de su línea, las notas del kit (el pie de las figuras): repetían la definición y, en los tiempos, hablaban de la caja. Ahora dicen solo su línea: «Pacientes con citología tomada en el periodo.» y «n citologías; primer cuartil: x días; tercer cuartil: y días.», sin Q1 ni Q3. El número de Pacientes evaluadas no cambia; «Datos y definiciones» de CaCu aclara que incluye las citologías con espécimen insatisfactorio. TEA y CaMa no cambian. Registrado en docs/bitacora-textos.md.

CSO5.5
2026-10-25 17:18:24 +00:00
edgar 6c84dab730 refactor(indicadores): quitar interpretación y metodología de datos y definiciones
La sección general de advertencias al final de Datos y definiciones repetía avisos genéricos (nulos, periodos, intervalos, uso para investigación) que no son de ningún indicador y solo agregaban ruido; la interpretación de cada gráfica está en su botón Cómo leer. Se quita solo la sección de la plantilla y la aserción de la prueba que buscaba su texto.

CSO5.5
2026-10-25 01:46:37 +00:00
edgar 12ce93f58c fix(indicadores): conservar el pie del kit y la lectura de la fecha de corte
El kit no cambia el formato del pie de las figuras: sigue publicando «<fuente> · Fecha de corte: AAAA-MM-DD» y la misma fuente de TEA. Se revierten la expresión regular que valida el pie de TEA, la extracción de la fecha de corte bajo la gráfica, los fixtures sintéticos y sus specs a como estaban. El cambio de textos de pantalla queda solo en los literales que se muestran o se leen en aria-label, sin tocar la lógica que compara o valida.

CSO5.5
2026-10-25 01:40:17 +00:00
edgar dcaf1a8832 fix(indicadores): quitar flechas, rayas y puntos medios de los textos de pantalla
Los textos que ve una persona, visibles o en aria-label, ya no usan flechas ni rayas o puntos medios como separador: se separan con comas o se reescribe la frase (por ejemplo «Días de toma a resultado (laboratorio)», «Último dato visible, 2025-S1», «Dominio CaCu, investigación», «2025-S2, 1 de 3» o «Datos y definiciones de CaCu»). El pie que publica el kit cambia al mismo estilo, así que la validación del pie de TEA y la lectura de la fecha de corte reconocen el formato nuevo con comas y siguen aceptando el anterior para no romper con un kit previo. Se ajustan los fixtures sintéticos y las specs a los textos nuevos.

CSO5.5
2026-10-25 01:37:53 +00:00
edgar 04d529392e refactor(indicadores): quitar el resumen de indicadores del final de la página
La tabla de resumen repetía en formato largo los valores de todas las figuras; cada figura ya trae su propia tabla de valores. Se quitan el componente indicadores-numeric-summary y sus filas (indicadores-numeric-rows), y las pruebas que dependían de ellos.

CSO5.5
2026-10-25 01:19:07 +00:00
edgar 6f3e7e22f9 fix(indicadores): decir intervalo de tiempo en lugar de granularidad
El filtro general y sus mensajes de compatibilidad nombran «Intervalo de tiempo» (semestre o mes) en lugar de «Granularidad», que no es un término clínico. Cambian la etiqueta del selector y los cinco mensajes que la mencionan; las pruebas que citaban esos textos se ajustan.

CSO5.5
2026-10-25 01:04:14 +00:00
edgar 12a0398903 refactor(indicadores): quitar la tabla de reglas de datos y definiciones
Las reglas de cálculo que publica el kit en `parametros` (clave, valor, estado y fuente) irán en un apéndice o manual técnico aparte, no en la pestaña «Datos y definiciones». Se quita la tabla «Reglas» y su formato de valores, y la pestaña conserva la ficha técnica, las referencias y las poblaciones. También se retiran el tipo y la validación estricta de `parametros` en el servicio: ya nadie los usa y una lista mal formada bloqueaba los metadatos completos. Si el servidor envía `parametros`, se ignoran.

CSO5.5
2026-10-24 22:11:33 +00:00
edgar 03e51c07cc feat(indicadores): panel de tasa de confirmación histopatológica, tiempos pareados y ficha técnica
Agrega el panel de tasa de confirmación histopatológica (cacu_confirmacion_citologia): tasas por resultado citológico de alto grado con su intervalo de Wilson a la izquierda, dona del grado de biopsia a la derecha y tabla de contingencia; la vista base es «LIEAG o más» y las pacientes sin biopsia aún no entran al denominador. Une en una sola figura los tiempos de toma a resultado (pedido por id, oculto en el catálogo) y de toma a diagnóstico. La pestaña Datos y definiciones muestra la ficha técnica y las reglas del kit en tablas; las notas de cada figura pasan a su Cómo leer, las tarjetas dejan solo valor, n y periodo, y el Cómo leer de EU7 muestra solo lo que publica el kit. Las transiciones animadas quedan fuera, como entrega aparte para el diseñador.

CSO5.5
2026-10-24 21:04:57 +00:00
edgar e6be341ad9 Redondeo único de porcentajes y etiqueta de la última citología sin resultado
- indicadores-format.ts: una regla para todo porcentaje mostrado. Una décima,
  medio hacia arriba; entre 0 y 0.1, la primera cifra significativa (0.04 %).
  De un conteo se calcula con enteros; de un valor publicado, sin sorpresas de
  coma flotante. La usan el resumen numérico (que mostraba el valor crudo,
  «0.6600660066 %»), los KPI, la dona, las barras y la tabla de EU7.
- Seguimiento: la última citología sin Bethesda dice «Insatisfactoria» si su
  calidad lo es y «Sin resultado al corte» si no; antes las dos decían
  «No disponible», que queda para cuando no hay citología.

CSO5.5
2026-10-24 18:17:54 +00:00
angel 85ec11ab0f Merge pull request 'feat(indicadores): ajustar indicadores CaCu y presentacion EU7' (#6) from feature/dona-barras-generales into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/6
2026-10-24 03:23:00 +00:00
Angel Capetillo Zavala db9ab0d1a7 feat(indicadores): ajustar indicadores CaCu y presentacion EU7
Actualiza los indicadores de oportunidad y clínicos de CaCu, incorpora el KPI no disponible, prioriza EU7, independiza dos figuras mediante Todos con reporte y añade el selector de prioridad no disponible en Seguimiento. Integra además los totales por escenario en las barras de EU7 y elimina el listado inferior redundante.
2026-10-23 21:18:43 -06:00
angel af70d6f378 Merge pull request 'feat(indicadores): interacción dona-barras, homologación visual y escenario clínico EU7' (#5) from feature/dona-barras-generales into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/5
2026-10-23 19:26:56 +00:00
Angel Capetillo Zavala 1940f4fa47 feat(isssteleon): add EU7 clinical scenario charts 2026-10-23 13:18:57 -06:00
alberto ec406d5d2d Merge pull request 'Reword "¿Cómo leer?" text for proportion and box charts' (#4) from fix/como-leer-textos into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/4
2026-10-23 18:27:14 +00:00
edgar 7b82427713 Reword "¿Cómo leer?" text for proportion and box charts
Replace "denominadores pequeños" with "tamaño de muestra pequeño" and drop the mention of Plotly from the box chart and fallback texts.
2026-10-23 18:26:26 +00:00
Angel Capetillo Zavala ec642df834 style(indicadores): homologar tarjetas y navegación de dominios
Homologa la presentación de figuras y tarjetas en TEA, CaCu y CaMa; recupera las leyendas superiores, permite la expansión independiente de Cómo leer y mueve la navegación de dominios a un selector compacto con resaltado institucional en la topbar. Preserva el comportamiento de Plotly y la interacción dona-barras.
2026-10-23 12:14:17 -06:00
Angel Capetillo Zavala 540506bde0 feat(indicadores): conectar donas jerárquicas con barras generales
Habilita el filtrado visual local de barras generales mediante selecciones jerárquicas C2, preservando datos originales, periodos, porcentajes y restauración de la distribución completa.
2026-10-23 10:32:40 -06:00
Roberto Treviño Cervantes d9245fe9b7 integration layer; merge work on indicators from forks with existing ingestion pipeline 2026-10-23 08:07:02 -06:00
angel 14fd765122 Merge pull request 'Integra las mejoras del dashboard de indicadores para TEA, CaCu y CaMa.' (#3) from feature/dashboard-tabs-colores-donas into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/3
2026-10-23 07:30:35 +00:00
Angel Capetillo Zavala 9639423a32 feat(indicadores): completa metadatos y navegación multiperiodo 2026-10-23 01:18:24 -06:00
Angel Capetillo Zavala 1fe88dfb45 feat(indicadores): dashboard interactivo multidominio y seguimiento CaCu 2026-10-22 17:10:35 -06:00
edgar a30dbbb102 Merge pull request 'Feature/cama birads45' (#2) from feature/cama-birads45 into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/2
2026-10-20 07:04:58 +00:00
rodrigo 9cc67c0ef2 CaMa: sin la barra fija de BI-RADS 4 sin subcategoría
- Los catálogos de despliegue (cama.catalogos.birads y .birads_4_a_6) ya no
  traen B4: el hospital reporta la subcategoría (usuario, 2026-10-16) y la
  barra salía siempre en 0. Un 4 a secas sigue contando como sospecha y en
  BI-RADS 4 a 6, y si llega se reporta tal cual después de «Sin dato».
- CAMA_BIRADS 0.1.3, CAMA_BIRADS456_PACIENTE y _MASTOGRAFIA 0.1.1: misma
  consulta (misma huella), otras categorías publicadas.
- El fixture de H-003 pasa de B4 a B4A; pruebas e instantánea (solo agrega).

CSO5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 08:33:30 +00:00
rodrigo 1eda9eea29 CaMa: la tasa de confirmación histopatológica vuelve al catálogo
cama_confirmacion_birads45 deja de estar oculto (usuario, 2026-10-16): se ve
su tarjeta destacada con el filtro por omisión y su gráfica de tendencia
(fig_c1_puntos). Así WebApp no necesita un caso especial para un destacado
oculto del catálogo: se revierte ese mecanismo y las pruebas del colaborador
quedan como estaban.

CSO5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 07:48:21 +00:00
rodrigo 2cf3a5a40d Destacados: la tasa de confirmación de CaMa con su indicador oculto, y pacientes evaluadas
- cama_confirmacion_birads45 está `oculto` en su TOML a propósito (no sale en
  el catálogo ni tiene gráfica), pero su tarjeta destacada se quedaba en «Sin
  reportes disponibles» con el filtro por omisión: la disponibilidad y la
  tarjeta solo miraban el catálogo. Una definición marcada `hiddenInCatalog`
  pide sus periodos y datos por su id, que WebApi sigue sirviendo; no aparece
  en los indicadores gráficos. Las demás tarjetas no cambian.
- Primera tarjeta: «Pacientes evaluadas» (cacu_eu7) y «Pacientes evaluadas con
  BI-RADS 4, 5 y 6», que suma las categorías de cama_birads_456_paciente.
- Pruebas: indicadores-kpi-ocultos.spec.ts (con el catálogo real de CaMa),
  indicadores-kpi-cama-real.spec.ts (respuestas reales de WebApi sobre una
  base montada por dev-data: 31 pacientes, 66.7 % y la mediana del C3r). Las
  suites de catálogo y fijación aíslan sus peticiones de las tarjetas
  (kpiQueriesProvider), como las demás.

CSO5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 07:39:08 +00:00
rodrigo 30946823c4 CaMa: título «Tasa de confirmación histopatológica», como en CaCu
Título de cama_confirmacion_birads45 (usuario, 2026-10-16), en el TOML y en
la tarjeta de indicadores destacados. Solo cambia el texto.

CSO5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 07:16:51 +00:00
rodrigo d946228319 Destacados: títulos de los TOML y Tiempo de tamizaje a diagnóstico
- Los títulos de las tarjetas de indicadores destacados son ahora los
  `title` de los TOML del kit (M23, M24, M25, cacu_eu7, cacu_eu13,
  cama_birads, cama_confirmacion_birads45), copiados a mano: solución
  provisional hasta que las tarjetas lean el `titulo` que ya manda la API.
- La tercera tarjeta de CaCu y CaMa pasa de los días de la toma al resultado
  (cacu_eu_tiempo_reporte, cama_eu38a) a los días de la toma al diagnóstico
  (cacu_dias_toma_diagnostico, cama_dias_toma_diagnostico), «Tiempo de
  tamizaje a diagnóstico», con su horizonte provisional de 180 días.

CSO5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 07:09:36 +00:00
alberto 8cb3c97b80 Merge pull request 'Feature/arreglos viernes alberto' (#1) from feature/arreglos-viernes-alberto into dev
Reviewed-on: http://10.0.10.41:3000/ISSSTELEON/WebApp/pulls/1
2026-10-16 02:13:52 +00:00
edgar 1fc23bd0bd TEA: indicadores destacados (M23–M25), ocultar indicadores y renombrar a pacientes 2026-10-15 22:23:39 +00:00
Angel Capetillo Zavala 11337679dc feat(indicadores): mejorar presentación y legibilidad de figuras multidominio 2026-10-15 13:45:59 -06:00
Angel Capetillo Zavala 4685a91a7c feat(ui): mejorar presentacion y disponibilidad inicial de KPI 2026-10-14 13:00:54 -06:00
Angel Capetillo Zavala 69afcc7fdb feat(ui): mejorar periodos KPI y presentacion del dashboard 2026-10-14 11:46:17 -06:00
Angel Capetillo Zavala 9fcc65d84f feat(ui): incorporar selector de figuras KPI y fijacion de indicadores 2026-10-13 22:34:57 -06:00
Angel Capetillo Zavala c4faa7d9f6 feat(ui): incorporar filtros globales por dominio UX-06E.D.2 2026-10-13 19:45:48 -06:00
Angel Capetillo Zavala 98d0614d80 feat(ui): habilitar apertura automatica UX-06E.D.1.1 2026-10-13 16:34:28 -06:00
Angel Capetillo Zavala 35e1bc33d3 feat(ui): integrar grid y KPI preliminares UX-06E.D.1 2026-10-13 16:01:48 -06:00
Angel Capetillo Zavala f96fe97ed6 feat(ui): incorporar ayuda contextual UX-06E.B1 2026-10-13 15:21:48 -06:00
Angel Capetillo Zavala fe9442237b feat(ui): refinar buscador y navegacion UX-06E.A 2026-10-13 14:43:52 -06:00
Angel Capetillo Zavala 61cdf5b72e chore(tests): retirar scripts temporales UX-06 2026-10-13 13:42:10 -06:00
Angel Capetillo Zavala 37c4eacf84 feat(ui): completar presentacion de figuras UX-06D 2026-10-13 13:41:45 -06:00
Angel Capetillo Zavala 41be0c343f feat(ui): redisenar catalogo y filtros UX-06C 2026-10-13 12:34:03 -06:00
Angel Capetillo Zavala ecf2778f1a feat(ui): incorporar base institucional UX-06B 2026-10-13 11:38:17 -06:00
Angel Capetillo Zavala 9c012e9bb4 feat(indicadores): agregar busqueda priorizada UX-05C 2026-10-13 10:42:34 -06:00
Angel Capetillo Zavala 91832cc6ff feat(indicadores): implementar catalogo expandible UX-05B 2026-10-13 10:14:27 -06:00
Angel Capetillo Zavala ea91b31b17 feat(indicadores): implementar filtros hibridos y memoria UX-04 2026-10-13 00:29:46 -06:00
Angel Capetillo Zavala ae5e4c5db5 refactor(indicadores): extraer componente de figura UX-03 2026-10-12 23:33:40 -06:00
Angel Capetillo Zavala b1c4b78f32 feat(indicadores): habilitar dashboards Angular TEA CaCu y CaMa 2026-10-12 16:39:37 -06:00
Angel Capetillo Zavala a66205b725 feat(indicadores): agregar prototipo de dashboard TEA
Implementa el prototipo del dashboard de indicadores TEA.

- Integra catálogo y figuras mediante WebApi.
- Incorpora visualizaciones interactivas con Plotly.js.
- Agrega controles de indicadores, figuras, periodos y temas.
- Implementa estados de carga, errores y diseño responsive.
- Incluye explicaciones para los contratos C1, C2 y C3r.
- Incorpora pruebas unitarias y de integración de componentes.

Prototipo para investigación con datos sintéticos.
2026-10-12 10:43:00 -06:00
Roberto Treviño Cervantes b0608fdc70 Merge remote-tracking branch 'origin/feature/frontend-flujo_inicial-20260923' into wip/mapping 2026-09-24 11:30:40 -06:00
Angel Capetillo Zavala 473a269bed Feature: Flujo inicial 2026-09-23 16:39:33 -06:00
Roberto Treviño Cervantes 3605d23fc0 initial commit 2026-09-21 10:23:37 -06:00
566 changed files with 75979 additions and 11333 deletions
+4 -3
View File
@@ -1,3 +1,4 @@
node_modules node_modules/
dist dist/
.angular .angular/
.git/
-4
View File
@@ -42,7 +42,3 @@ __screenshots__/
# System files # System files
.DS_Store .DS_Store
Thumbs.db Thumbs.db
# Playwright
/test-results/
/playwright-report/
-1
View File
@@ -1 +0,0 @@
src/app/api/
+4
View File
@@ -0,0 +1,4 @@
{
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=827846
"recommendations": ["angular.ng-template"]
}
+20
View File
@@ -0,0 +1,20 @@
{
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "ng serve",
"type": "chrome",
"request": "launch",
"preLaunchTask": "npm: start",
"url": "http://localhost:4200/"
},
{
"name": "ng test",
"type": "chrome",
"request": "launch",
"preLaunchTask": "npm: test",
"url": "http://localhost:9876/debug.html"
}
]
}
+42
View File
@@ -0,0 +1,42 @@
{
// For more information, visit: https://go.microsoft.com/fwlink/?LinkId=733558
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "start",
"isBackground": true,
"problemMatcher": {
"owner": "typescript",
"pattern": "$tsc",
"background": {
"activeOnStart": true,
"beginsPattern": {
"regexp": "Changes detected"
},
"endsPattern": {
"regexp": "bundle generation (complete|failed)"
}
}
}
},
{
"type": "npm",
"script": "test",
"isBackground": true,
"problemMatcher": {
"owner": "typescript",
"pattern": "$tsc",
"background": {
"activeOnStart": true,
"beginsPattern": {
"regexp": "Changes detected"
},
"endsPattern": {
"regexp": "bundle generation (complete|failed)"
}
}
}
}
]
}
+6 -4
View File
@@ -1,10 +1,12 @@
FROM node:24-alpine AS build # Production image: the Angular build served by nginx, which proxies the API paths to `webapi`.
FROM node:22-slim AS build
WORKDIR /app WORKDIR /app
COPY package.json package-lock.json ./ COPY package.json package-lock.json ./
RUN npm ci RUN npm ci
COPY . . COPY . .
RUN npx ng build RUN npx ng build --configuration production
FROM nginx:1.29-alpine FROM nginx:1.27-alpine
COPY nginx.conf /etc/nginx/conf.d/default.conf COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=build /app/dist/webapp/browser /usr/share/nginx/html COPY --from=build /app/dist/WebApp/browser /usr/share/nginx/html
EXPOSE 80
+16
View File
@@ -0,0 +1,16 @@
# WebApp
Interfaz de ISSSTELEON en Angular y Angular Material: conexión e importación de
datos (`/conectar`), bitácora de cargas (`/bitacora`), gobernanza y tablero de
indicadores (`/indicadores`).
```bash
npm ci
npx ng serve # http://localhost:4200
npx ng test --watch=false # pruebas unitarias (Vitest)
npx ng build # compilación de producción en dist/WebApp
```
`ng serve` envía las rutas de la API a WebApi en `localhost:5050`
(`proxy.conf.json`). La imagen de Docker (`Dockerfile`) sirve la compilación con
nginx (`nginx.conf`), que reenvía esas mismas rutas al servicio `webapi`.
+23 -18
View File
@@ -2,11 +2,12 @@
"$schema": "./node_modules/@angular/cli/lib/config/schema.json", "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1, "version": 1,
"cli": { "cli": {
"packageManager": "npm" "packageManager": "npm",
"analytics": false
}, },
"newProjectRoot": "projects", "newProjectRoot": "projects",
"projects": { "projects": {
"webapp": { "WebApp": {
"projectType": "application", "projectType": "application",
"schematics": { "schematics": {
"@schematics/angular:component": { "@schematics/angular:component": {
@@ -30,17 +31,15 @@
} }
], ],
"styles": [ "styles": [
"@fontsource/roboto/300.css", "node_modules/@fontsource/roboto/300.css",
"@fontsource/roboto/400.css", "node_modules/@fontsource/roboto/400.css",
"@fontsource/roboto/500.css", "node_modules/@fontsource/roboto/500.css",
"@fontsource/roboto/700.css", "node_modules/@fontsource/rajdhani/600.css",
"@fontsource/rajdhani/500.css", "node_modules/@fontsource/rajdhani/700.css",
"@fontsource/rajdhani/600.css", "node_modules/@fontsource/roboto-mono/400.css",
"material-symbols/outlined.css", "node_modules/@fontsource/roboto-mono/600.css",
"node_modules/material-icons/iconfont/filled.css",
"src/styles.scss" "src/styles.scss"
],
"allowedCommonJsDependencies": [
"plotly.js-cartesian-dist-min"
] ]
}, },
"configurations": { "configurations": {
@@ -48,13 +47,13 @@
"budgets": [ "budgets": [
{ {
"type": "initial", "type": "initial",
"maximumWarning": "600kB", "maximumWarning": "500kB",
"maximumError": "1MB" "maximumError": "1MB"
}, },
{ {
"type": "anyComponentStyle", "type": "anyComponentStyle",
"maximumWarning": "4kB", "maximumWarning": "6kB",
"maximumError": "8kB" "maximumError": "10kB"
} }
], ],
"outputHashing": "all" "outputHashing": "all"
@@ -69,18 +68,24 @@
}, },
"serve": { "serve": {
"builder": "@angular/build:dev-server", "builder": "@angular/build:dev-server",
"options": {
"proxyConfig": "proxy.conf.json"
},
"configurations": { "configurations": {
"production": { "production": {
"buildTarget": "webapp:build:production" "buildTarget": "WebApp:build:production"
}, },
"development": { "development": {
"buildTarget": "webapp:build:development" "buildTarget": "WebApp:build:development"
} }
}, },
"defaultConfiguration": "development" "defaultConfiguration": "development"
}, },
"test": { "test": {
"builder": "@angular/build:unit-test" "builder": "@angular/build:unit-test",
"options": {
"isolate": true
}
} }
} }
} }
-85
View File
@@ -1,85 +0,0 @@
import { expect, Page, test } from '@playwright/test';
/** Every page loads from the API with no failed request and no console error. */
function watch(page: Page): string[] {
const problems: string[] = [];
page.on('console', (m) => m.type() === 'error' && problems.push(`console: ${m.text()}`));
page.on('response', (r) => r.status() >= 400 && problems.push(`${r.status()} ${r.url()}`));
page.on('pageerror', (e) => problems.push(`page: ${e.message}`));
return problems;
}
test("indicators: the KPIs are the API's MeasureReports, every tab and the patient view load", async ({
page,
}) => {
const problems = watch(page);
const report = page.waitForResponse(
(r) =>
r.url().includes('MeasureReport') &&
r.url().includes('measure=cacu-eu7') &&
!r.url().includes('%2C'),
);
await page.goto('/indicadores/cacu');
const eu7 = await (await report).json();
const count = eu7.entry[0].resource.group[0].population.find(
(p: any) => p.code.coding[0].code === 'initial-population',
).count;
await expect(page.locator('[data-measure="CACU_EU7"] .kpi-value')).toHaveText(String(count));
await expect(page.locator('app-tab-indicadores app-plot').first()).toBeVisible();
await page.getByRole('tab', { name: 'Trazabilidad' }).click();
await expect(page.locator('app-tab-trazabilidad mat-card')).toHaveCount(14);
await page.getByRole('tab', { name: 'Datos y definiciones' }).click();
await expect(page.locator('app-tab-definiciones tbody tr')).toHaveCount(14);
const list = page.waitForResponse((r) => r.url().includes('/fhir/Patient?'));
await page.getByRole('tab', { name: 'Análisis de riesgos' }).click();
const bundle = await (await list).json();
const first = bundle.entry.find((e: any) => e.search.mode === 'match').resource.id;
const rows = page.locator('table.worklist tbody tr');
await expect(rows).toHaveCount(Math.min(20, bundle.total));
await expect(rows.first().locator('a.id')).toHaveText(first.slice(0, 10));
await page.getByRole('button', { name: 'Siguiente' }).click();
await expect(page.getByText(`21–`)).toBeVisible();
await page.getByRole('button', { name: 'Anterior' }).click();
await rows.first().locator('a.id').click();
await expect(page.getByText('Historial médico')).toBeVisible();
await expect(page.getByText('Pruebas y resultados')).toBeVisible();
await expect(
page.locator('app-paciente table').nth(1).locator('tbody tr').first(),
).not.toContainText('Sin estudios');
await page.goto('/indicadores/cama');
await expect(page.getByText('todavía no tiene indicadores')).toBeVisible();
expect(problems).toEqual([]);
});
test('conectar: open the hospital pipeline, preview a source, run it to success', async ({
page,
}) => {
const problems = watch(page);
await page.goto('/conectar');
await page.getByText('cacu', { exact: true }).click();
await expect(page.locator('vflow')).toBeVisible();
await page.getByText('Fuente · Patients').click();
await expect(page.locator('formly-form')).toBeVisible();
await page.getByRole('button', { name: 'Vista previa' }).click();
await expect(page.locator('.preview tr[mat-row]').first()).toBeVisible();
await page.getByRole('button', { name: 'Ejecutar' }).click();
await expect(page.getByText('SUCCESS')).toBeVisible({ timeout: 10 * 60_000 });
expect(problems).toEqual([]);
});
test('revision: what the messy site holds, and a decision through the page', async ({ page }) => {
const problems = watch(page);
await page.goto('/revision');
await page.getByRole('tab', { name: 'Personas' }).click();
await page.locator('mat-form-field', { hasText: 'Canalización' }).click();
await page.getByRole('option', { name: 'site', exact: true }).click();
await expect(page.getByText(/Posibles pacientes duplicadas \([1-9]/)).toBeVisible();
await page.getByRole('button', { name: 'Distintas' }).first().click();
await expect(page.getByText('Decisión registrada.')).toBeVisible();
expect(problems).toEqual([]);
});
-6
View File
@@ -1,6 +0,0 @@
{
"$schema": "node_modules/ng-openapi-gen/ng-openapi-gen-schema.json",
"input": "openapi.json",
"output": "src/app/api",
"ignoreUnusedModels": false
}
+33 -9
View File
@@ -1,11 +1,35 @@
server { server {
listen 80; listen 80;
root /usr/share/nginx/html; server_name _;
location /api/ { root /usr/share/nginx/html;
proxy_pass http://api:8000/;
proxy_read_timeout 30s; # Files travel inside the import requests (multipart or base64 JSON):
} # keep this above WebApi's WEBAPI_MAX_UPLOAD_MB (200 MB default) plus
location / { # the ~33% base64 overhead.
try_files $uri $uri/ /index.html; client_max_body_size 270m;
}
gzip on;
gzip_types text/css application/javascript application/json image/svg+xml;
gzip_min_length 1024;
location ~ ^/(api|imports|data|cacu|cama|tea|governance|reportes|health)(/|$) {
proxy_pass http://webapi:5000;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# OCR over a stack of scanned pages takes a while.
proxy_read_timeout 600s;
}
# Bundles carry a content hash in their name; index.html doesn't, so it
# must be revalidated or browsers keep running the previous release.
location ~* \.(js|css)$ {
add_header Cache-Control "public, max-age=31536000, immutable";
try_files $uri =404;
}
location / {
add_header Cache-Control "no-cache";
try_files $uri $uri/ /index.html;
}
} }
-3163
View File
File diff suppressed because it is too large Load Diff
+2945 -2330
View File
File diff suppressed because it is too large Load Diff
+24 -35
View File
@@ -1,52 +1,41 @@
{ {
"name": "webapp", "name": "web-app",
"version": "0.0.0", "version": "0.0.0",
"scripts": { "scripts": {
"ng": "ng", "ng": "ng",
"start": "ng serve --proxy-config proxy.conf.json", "start": "ng serve",
"build": "ng build", "build": "ng build",
"watch": "ng build --watch --configuration development", "watch": "ng build --watch --configuration development",
"test": "ng test", "test": "ng test"
"api": "ng-openapi-gen -c ng-openapi-gen.json"
}, },
"private": true, "private": true,
"packageManager": "npm@11.20.0", "packageManager": "npm@11.17.0",
"dependencies": { "dependencies": {
"@angular/cdk": "^22.3.0", "@angular/cdk": "^22.1.7",
"@angular/common": "^22.3.0", "@angular/common": "^22.1.0",
"@angular/compiler": "^22.3.0", "@angular/compiler": "^22.1.0",
"@angular/core": "^22.3.0", "@angular/core": "^22.1.0",
"@angular/forms": "^22.3.0", "@angular/forms": "^22.1.0",
"@angular/material": "^22.3.0", "@angular/material": "^22.1.7",
"@angular/platform-browser": "^22.3.0", "@angular/platform-browser": "^22.1.0",
"@angular/router": "^22.3.0", "@angular/router": "^22.1.0",
"@fontsource/rajdhani": "5.3.0", "@fontsource/rajdhani": "^5.3.0",
"@fontsource/roboto": "5.3.0", "@fontsource/roboto": "^5.3.0",
"@ngx-formly/core": "11.2.0", "@fontsource/roboto-mono": "^5.3.0",
"@ngx-formly/material": "11.2.0", "material-icons": "^1.13.14",
"d3-drag": "3.0.0", "pdfmake": "0.3.14",
"d3-selection": "3.0.0",
"d3-zoom": "3.0.0",
"material-symbols": "0.48.3",
"ngx-vflow": "2.7.0",
"plotly.js-cartesian-dist-min": "4.1.2", "plotly.js-cartesian-dist-min": "4.1.2",
"rxjs": "~7.8.0", "rxjs": "~7.8.0",
"tslib": "^2.3.0" "tslib": "^2.3.0",
"write-excel-file": "4.1.1"
}, },
"devDependencies": { "devDependencies": {
"@angular/build": "^22.3.0", "@angular/build": "^22.1.8",
"@angular/cli": "^22.3.0", "@angular/cli": "^22.1.8",
"@angular/compiler-cli": "^22.3.0", "@angular/compiler-cli": "^22.1.0",
"@playwright/test": "1.64.1", "jsdom": "^28.0.0",
"@types/d3-drag": "3.0.7",
"@types/d3-selection": "3.0.13",
"@types/d3-zoom": "3.0.9",
"@types/fhir": "0.0.44",
"@types/plotly.js": "3.0.15",
"jsdom": "^31.0.0",
"ng-openapi-gen": "^1.1.0",
"prettier": "^3.8.1", "prettier": "^3.8.1",
"typescript": "~6.0.2", "typescript": "~6.0.2",
"vitest": "^5.0.0" "vitest": "^4.0.8"
} }
} }
-25
View File
@@ -1,25 +0,0 @@
import { defineConfig } from '@playwright/test';
/** The pages against a running API (API_URL), served by the dev server with the same
* proxy the app uses in production (`/api`). Run by WebApi/tests/test_webapp.py, which
* starts the platform and loads the synthetic hospital first. */
export default defineConfig({
testDir: 'e2e',
timeout: 15 * 60_000,
expect: { timeout: 60_000 },
workers: 1,
reporter: 'list',
use: {
baseURL: 'http://127.0.0.1:4310',
viewport: { width: 1440, height: 1000 },
actionTimeout: 60_000, // a stuck step fails, not the whole run
},
webServer: {
// IPv4 explicitly: `localhost` may resolve to ::1 only (CI containers), where the url below never answers.
command: 'npx ng serve --host 127.0.0.1 --port 4310 --proxy-config proxy.e2e.mjs',
env: { NG_CLI_ANALYTICS: 'false' },
url: 'http://127.0.0.1:4310',
timeout: 180_000,
reuseExistingServer: false,
},
});
+11 -1
View File
@@ -1 +1,11 @@
{ "/api": { "target": "http://127.0.0.1:5711", "pathRewrite": { "^/api": "" } } } {
"/api": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/imports": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/data": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/health": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/cacu": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/cama": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/tea": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/governance": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true },
"/reportes": { "target": "http://localhost:5050", "secure": false, "changeOrigin": true }
}
-2
View File
@@ -1,2 +0,0 @@
// `/api` to the API the e2e run started (API_URL).
export default { '/api': { target: process.env.API_URL, pathRewrite: { '^/api': '' } } };
+25 -25
View File
@@ -4,7 +4,7 @@
@use 'sass:map'; @use 'sass:map';
@use '@angular/material' as mat; @use '@angular/material' as mat;
// Note: Color palettes are generated from primary: #a8c243, tertiary: #5f9ea0 // Note: Color palettes are generated from primary: #a8c243, tertiary: #5f9ea0, neutral: #5c5f66
$_palettes: ( $_palettes: (
primary: ( primary: (
0: #000000, 0: #000000,
@@ -62,31 +62,31 @@ $_palettes: (
), ),
neutral: ( neutral: (
0: #000000, 0: #000000,
10: #1b1c14, 10: #181c22,
20: #303128, 20: #2d3037,
25: #3b3c32, 25: #383b42,
30: #46483d, 30: #44474d,
35: #525348, 35: #4f5259,
40: #5e5f54, 40: #5b5e65,
50: #77786c, 50: #74777e,
60: #919285, 60: #8e9198,
70: #acac9f, 70: #a9abb3,
80: #c7c7b9, 80: #c4c6ce,
90: #e4e3d5, 90: #e0e2ea,
95: #f2f2e3, 95: #eff0f9,
98: #fbfaeb, 98: #f9f9ff,
99: #fdfdf5, 99: #fdfcff,
100: #ffffff, 100: #ffffff,
4: #0d0f07, 4: #0b0e14,
6: #13140c, 6: #101419,
12: #1f2017, 12: #1c2026,
17: #292b21, 17: #272a30,
22: #34362c, 22: #32353b,
24: #393a30, 24: #363940,
87: #dbdbcd, 87: #d8dae2,
92: #e9e9da, 92: #e6e8f0,
94: #efefe0, 94: #ecedf6,
96: #f5f4e6, 96: #f1f3fc,
), ),
neutral-variant: ( neutral-variant: (
0: #000000, 0: #000000,
-27
View File
@@ -1,27 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Injectable } from '@angular/core';
/**
* Provides the ApiConfiguration configuration object with a given root URL.
*/
export function provideApiConfiguration(rootUrl: string) {
var config = new ApiConfiguration();
config.rootUrl = rootUrl;
return {
provide: ApiConfiguration,
useValue: config
};
}
/**
* Global configuration
*/
@Injectable({
providedIn: 'root',
})
export class ApiConfiguration {
rootUrl: string = '';
}
-64
View File
@@ -1,64 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Injectable } from '@angular/core';
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable, firstValueFrom } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { ApiConfiguration } from './api-configuration';
import { StrictHttpResponse } from './strict-http-response';
export type ApiFnOptional<P, R> = (http: HttpClient, rootUrl: string, params?: P, context?: HttpContext) => Observable<StrictHttpResponse<R>>;
export type ApiFnRequired<P, R> = (http: HttpClient, rootUrl: string, params: P, context?: HttpContext) => Observable<StrictHttpResponse<R>>;
/**
* Helper service to call API functions directly
*/
@Injectable({ providedIn: 'root' })
export class Api {
constructor(
private config: ApiConfiguration,
private http: HttpClient
) {
}
private _rootUrl?: string;
/**
* Returns the root url for API operations. If not set directly here,
* will fallback to `ApiConfiguration.rootUrl`.
*/
get rootUrl(): string {
return this._rootUrl || this.config.rootUrl;
}
/**
* Sets the root URL for API operations
*/
set rootUrl(rootUrl: string) {
this._rootUrl = rootUrl;
}
/**
* Executes an API call, returning the response body only
*/
invoke<P, R>(fn: ApiFnRequired<P, R>, params: P, context?: HttpContext): Promise<R>;
invoke<P, R>(fn: ApiFnOptional<P, R>, params?: P, context?: HttpContext): Promise<R>;
async invoke<P, R>(fn: ApiFnRequired<P, R> | ApiFnOptional<P, R>, params: P, context?: HttpContext): Promise<R> {
const resp = this.invoke$Response(fn, params, context);
return (await resp).body;
}
/**
* Executes an API call, returning the entire response
*/
invoke$Response<P, R>(fn: ApiFnRequired<P, R>, params: P, context?: HttpContext): Promise<StrictHttpResponse<R>>;
invoke$Response<P, R>(fn: ApiFnOptional<P, R>, params?: P, context?: HttpContext): Promise<StrictHttpResponse<R>>;
invoke$Response<P, R>(fn: ApiFnRequired<P, R> | ApiFnOptional<P, R>, params: P, context?: HttpContext): Promise<StrictHttpResponse<R>> {
const obs = fn(this.http, this.rootUrl, params, context)
.pipe(
filter(r => r instanceof HttpResponse),
map(r => r as StrictHttpResponse<R>));
return firstValueFrom(obs);
}
}
-34
View File
@@ -1,34 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface Metadata$Params {
domain: Domain;
}
export function metadata(http: HttpClient, rootUrl: string, params: Metadata$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, metadata.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
metadata.PATH = '/{domain}/fhir/metadata';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface ReadMeasure$Params {
domain: Domain;
id: string;
}
export function readMeasure(http: HttpClient, rootUrl: string, params: ReadMeasure$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, readMeasure.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.path('id', params.id, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
readMeasure.PATH = '/{domain}/fhir/Measure/{id}';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface ReadPatient$Params {
domain: Domain;
id: string;
}
export function readPatient(http: HttpClient, rootUrl: string, params: ReadPatient$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, readPatient.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.path('id', params.id, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
readPatient.PATH = '/{domain}/fhir/Patient/{id}';
-44
View File
@@ -1,44 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchCondition$Params {
domain: Domain;
/**
* Patient/<id>, comma-separated
*/
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchCondition(http: HttpClient, rootUrl: string, params: SearchCondition$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchCondition.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('subject', params.subject, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchCondition.PATH = '/{domain}/fhir/Condition';
@@ -1,44 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchDiagnosticReport$Params {
domain: Domain;
/**
* Patient/<id>, comma-separated
*/
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchDiagnosticReport(http: HttpClient, rootUrl: string, params: SearchDiagnosticReport$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchDiagnosticReport.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('subject', params.subject, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchDiagnosticReport.PATH = '/{domain}/fhir/DiagnosticReport';
@@ -1,62 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchMeasureReport$Params {
domain: Domain;
/**
* the Measure's id or canonical URL
*/
measure: string;
/**
* semesters (2025-S1) or months (2025-03), comma-separated
*/
'reporting-period': string;
/**
* count only what was known by then
*/
'as-of'?: (string | null);
/**
* durations count to this day
*/
'event-cutoff'?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchMeasureReport(http: HttpClient, rootUrl: string, params: SearchMeasureReport$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchMeasureReport.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('measure', params.measure, {});
rb.query('reporting-period', params['reporting-period'], {});
rb.query('as-of', params['as-of'], {});
rb.query('event-cutoff', params['event-cutoff'], {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchMeasureReport.PATH = '/{domain}/fhir/MeasureReport';
-38
View File
@@ -1,38 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchMeasure$Params {
domain: Domain;
'_count'?: (number | null);
'_offset'?: number;
}
export function searchMeasure(http: HttpClient, rootUrl: string, params: SearchMeasure$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchMeasure.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchMeasure.PATH = '/{domain}/fhir/Measure';
-44
View File
@@ -1,44 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchObservation$Params {
domain: Domain;
/**
* Patient/<id>, comma-separated
*/
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchObservation(http: HttpClient, rootUrl: string, params: SearchObservation$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchObservation.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('subject', params.subject, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchObservation.PATH = '/{domain}/fhir/Observation';
-78
View File
@@ -1,78 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchPatient$Params {
domain: Domain;
'_id'?: (string | null);
/**
* months: whoever had a cytology sampled within them up to the cut-off
*/
'follow-up-window'?: (number | null);
/**
* default: the last day with data
*/
'follow-up-cutoff'?: (string | null);
'follow-up-status'?: (string | null);
/**
* one of ('-recent', '-risk-cin2', '-risk-cancer'); the list only
*/
'_sort'?: string;
/**
* years
*/
'risk-horizon'?: number;
/**
* any of ('DiagnosticReport:subject', 'RiskAssessment:subject', 'Observation:subject')
*/
'_revinclude'?: Array<string>;
/**
* DiagnosticReport:result
*/
'_include:iterate'?: Array<string>;
'_count'?: (number | null);
'_offset'?: number;
}
export function searchPatient(http: HttpClient, rootUrl: string, params: SearchPatient$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchPatient.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('_id', params['_id'], {});
rb.query('follow-up-window', params['follow-up-window'], {});
rb.query('follow-up-cutoff', params['follow-up-cutoff'], {});
rb.query('follow-up-status', params['follow-up-status'], {});
rb.query('_sort', params['_sort'], {});
rb.query('risk-horizon', params['risk-horizon'], {});
rb.query('_revinclude', params['_revinclude'], {});
rb.query('_include:iterate', params['_include:iterate'], {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchPatient.PATH = '/{domain}/fhir/Patient';
-44
View File
@@ -1,44 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchProcedure$Params {
domain: Domain;
/**
* Patient/<id>, comma-separated
*/
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchProcedure(http: HttpClient, rootUrl: string, params: SearchProcedure$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchProcedure.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('subject', params.subject, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchProcedure.PATH = '/{domain}/fhir/Procedure';
@@ -1,44 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface SearchRiskAssessment$Params {
domain: Domain;
/**
* Patient/<id>, comma-separated
*/
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
}
export function searchRiskAssessment(http: HttpClient, rootUrl: string, params: SearchRiskAssessment$Params, context?: HttpContext): Observable<StrictHttpResponse<{
}>> {
const rb = new RequestBuilder(rootUrl, searchRiskAssessment.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.query('subject', params.subject, {});
rb.query('_count', params['_count'], {});
rb.query('_offset', params['_offset'], {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/fhir+json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
}>;
})
);
}
searchRiskAssessment.PATH = '/{domain}/fhir/RiskAssessment';
-39
View File
@@ -1,39 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface NodeRows$Params {
pipeline_id: string;
node_id: string;
limit?: number;
}
export function nodeRows(http: HttpClient, rootUrl: string, params: NodeRows$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<{
[key: string]: any;
}>>> {
const rb = new RequestBuilder(rootUrl, nodeRows.PATH, 'get');
if (params) {
rb.path('pipeline_id', params.pipeline_id, {});
rb.path('node_id', params.node_id, {});
rb.query('limit', params.limit, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<{
[key: string]: any;
}>>;
})
);
}
nodeRows.PATH = '/ingest/pipelines/{pipeline_id}/nodes/{node_id}/rows';
-34
View File
@@ -1,34 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { SavedPipeline } from '../../models/saved-pipeline';
export interface Pipeline$Params {
pipeline_id: string;
version?: (number | null);
}
export function pipeline(http: HttpClient, rootUrl: string, params: Pipeline$Params, context?: HttpContext): Observable<StrictHttpResponse<SavedPipeline>> {
const rb = new RequestBuilder(rootUrl, pipeline.PATH, 'get');
if (params) {
rb.path('pipeline_id', params.pipeline_id, {});
rb.query('version', params.version, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<SavedPipeline>;
})
);
}
pipeline.PATH = '/ingest/pipelines/{pipeline_id}';
-33
View File
@@ -1,33 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Pipelines$Params {
}
export function pipelines(http: HttpClient, rootUrl: string, params?: Pipelines$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<{
[key: string]: any;
}>>> {
const rb = new RequestBuilder(rootUrl, pipelines.PATH, 'get');
if (params) {
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<{
[key: string]: any;
}>>;
})
);
}
pipelines.PATH = '/ingest/pipelines';
-38
View File
@@ -1,38 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Pipeline } from '../../models/pipeline';
export interface SavePipeline$Params {
pipeline_id: string;
body: Pipeline
}
export function savePipeline(http: HttpClient, rootUrl: string, params: SavePipeline$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: number;
}>> {
const rb = new RequestBuilder(rootUrl, savePipeline.PATH, 'put');
if (params) {
rb.path('pipeline_id', params.pipeline_id, {});
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: number;
}>;
})
);
}
savePipeline.PATH = '/ingest/pipelines/{pipeline_id}';
-33
View File
@@ -1,33 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Schema$Params {
}
export function schema(http: HttpClient, rootUrl: string, params?: Schema$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: any;
}>> {
const rb = new RequestBuilder(rootUrl, schema.PATH, 'get');
if (params) {
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: any;
}>;
})
);
}
schema.PATH = '/ingest/schema';
-38
View File
@@ -1,38 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Source } from '../../models/source';
export interface SourcePreview$Params {
limit?: number;
body: Source
}
export function sourcePreview(http: HttpClient, rootUrl: string, params: SourcePreview$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<{
[key: string]: any;
}>>> {
const rb = new RequestBuilder(rootUrl, sourcePreview.PATH, 'post');
if (params) {
rb.query('limit', params.limit, {});
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<{
[key: string]: any;
}>>;
})
);
}
sourcePreview.PATH = '/ingest/sources/preview';
-32
View File
@@ -1,32 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { SourceRef } from '../../models/source-ref';
export interface SourceResources$Params {
body: SourceRef
}
export function sourceResources(http: HttpClient, rootUrl: string, params: SourceResources$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<string>>> {
const rb = new RequestBuilder(rootUrl, sourceResources.PATH, 'post');
if (params) {
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<string>>;
})
);
}
sourceResources.PATH = '/ingest/sources/resources';
-38
View File
@@ -1,38 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { RunRequest } from '../../models/run-request';
export interface StartRun$Params {
pipeline_id: string;
body: RunRequest
}
export function startRun(http: HttpClient, rootUrl: string, params: StartRun$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, startRun.PATH, 'post');
if (params) {
rb.path('pipeline_id', params.pipeline_id, {});
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
startRun.PATH = '/ingest/pipelines/{pipeline_id}/runs';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { BodyUpload } from '../../models/body-upload';
export interface Upload$Params {
body: BodyUpload
}
export function upload(http: HttpClient, rootUrl: string, params: Upload$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, upload.PATH, 'post');
if (params) {
rb.body(params.body, 'multipart/form-data');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
upload.PATH = '/ingest/uploads';
@@ -1,43 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { BodyAddClinicalValidation } from '../../models/body-add-clinical-validation';
import { Domain } from '../../models/domain';
export interface AddClinicalValidation$Params {
domain: Domain;
name: string;
version: number;
body: BodyAddClinicalValidation
}
export function addClinicalValidation(http: HttpClient, rootUrl: string, params: AddClinicalValidation$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: any;
}>> {
const rb = new RequestBuilder(rootUrl, addClinicalValidation.PATH, 'post');
if (params) {
rb.path('domain', params.domain, {});
rb.path('name', params.name, {});
rb.path('version', params.version, {});
rb.body(params.body, 'multipart/form-data');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: any;
}>;
})
);
}
addClinicalValidation.PATH = '/models/{domain}/{name}/versions/{version}/reports/clinical_validation';
-32
View File
@@ -1,32 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface Models$Params {
domain: Domain;
}
export function models(http: HttpClient, rootUrl: string, params: Models$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<string>>> {
const rb = new RequestBuilder(rootUrl, models.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<string>>;
})
);
}
models.PATH = '/models/{domain}';
-40
View File
@@ -1,40 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface Promote$Params {
domain: Domain;
name: string;
version: number;
}
export function promote(http: HttpClient, rootUrl: string, params: Promote$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: any;
}>> {
const rb = new RequestBuilder(rootUrl, promote.PATH, 'post');
if (params) {
rb.path('domain', params.domain, {});
rb.path('name', params.name, {});
rb.path('version', params.version, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: any;
}>;
})
);
}
promote.PATH = '/models/{domain}/{name}/versions/{version}/promote';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface Score$Params {
domain: Domain;
}
export function score(http: HttpClient, rootUrl: string, params: Score$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, score.PATH, 'post');
if (params) {
rb.path('domain', params.domain, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
score.PATH = '/models/{domain}/score';
-39
View File
@@ -1,39 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
import { Training } from '../../models/training';
export interface Train$Params {
domain: Domain;
body: Training
}
export function train(http: HttpClient, rootUrl: string, params: Train$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, train.PATH, 'post');
if (params) {
rb.path('domain', params.domain, {});
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
train.PATH = '/models/{domain}/train';
-35
View File
@@ -1,35 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
import { Version } from '../../models/version';
export interface Versions$Params {
domain: Domain;
name: string;
}
export function versions(http: HttpClient, rootUrl: string, params: Versions$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<Version>>> {
const rb = new RequestBuilder(rootUrl, versions.PATH, 'get');
if (params) {
rb.path('domain', params.domain, {});
rb.path('name', params.name, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<Version>>;
})
);
}
versions.PATH = '/models/{domain}/{name}/versions';
-30
View File
@@ -1,30 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Domain } from '../../models/domain';
export interface Domains$Params {
}
export function domains(http: HttpClient, rootUrl: string, params?: Domains$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<Domain>>> {
const rb = new RequestBuilder(rootUrl, domains.PATH, 'get');
if (params) {
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<Domain>>;
})
);
}
domains.PATH = '/domains';
-33
View File
@@ -1,33 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Health$Params {
}
export function health(http: HttpClient, rootUrl: string, params?: Health$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, health.PATH, 'get');
if (params) {
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
health.PATH = '/health';
-35
View File
@@ -1,35 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Conflicts$Params {
entity: 'identity' | 'death' | 'clinical_note' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy';
}
export function conflicts(http: HttpClient, rootUrl: string, params: Conflicts$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<{
[key: string]: any;
}>>> {
const rb = new RequestBuilder(rootUrl, conflicts.PATH, 'get');
if (params) {
rb.query('entity', params.entity, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<{
[key: string]: any;
}>>;
})
);
}
conflicts.PATH = '/review/conflicts';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Correction } from '../../models/correction';
export interface Correct$Params {
body: Correction
}
export function correct(http: HttpClient, rootUrl: string, params: Correct$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, correct.PATH, 'post');
if (params) {
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
correct.PATH = '/review/corrections';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { PersonDecision } from '../../models/person-decision';
export interface DecidePersons$Params {
body: PersonDecision
}
export function decidePersons(http: HttpClient, rootUrl: string, params: DecidePersons$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, decidePersons.PATH, 'post');
if (params) {
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
decidePersons.PATH = '/review/persons';
-35
View File
@@ -1,35 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Held$Params {
entity: 'identity' | 'death' | 'clinical_note' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy';
}
export function held(http: HttpClient, rootUrl: string, params: Held$Params, context?: HttpContext): Observable<StrictHttpResponse<Array<{
[key: string]: any;
}>>> {
const rb = new RequestBuilder(rootUrl, held.PATH, 'get');
if (params) {
rb.query('entity', params.entity, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<Array<{
[key: string]: any;
}>>;
})
);
}
held.PATH = '/review/held';
-41
View File
@@ -1,41 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface Persons$Params {
pipeline: string;
node: string;
}
export function persons(http: HttpClient, rootUrl: string, params: Persons$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: Array<{
[key: string]: any;
}>;
}>> {
const rb = new RequestBuilder(rootUrl, persons.PATH, 'get');
if (params) {
rb.query('pipeline', params.pipeline, {});
rb.query('node', params.node, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: Array<{
[key: string]: any;
}>;
}>;
})
);
}
persons.PATH = '/review/persons';
-36
View File
@@ -1,36 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
import { Rejection } from '../../models/rejection';
export interface Reject$Params {
body: Rejection
}
export function reject(http: HttpClient, rootUrl: string, params: Reject$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, reject.PATH, 'post');
if (params) {
rb.body(params.body, 'application/json');
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
reject.PATH = '/review/rejections';
-35
View File
@@ -1,35 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { StrictHttpResponse } from '../../strict-http-response';
import { RequestBuilder } from '../../request-builder';
export interface RunStatus$Params {
run_id: string;
}
export function runStatus(http: HttpClient, rootUrl: string, params: RunStatus$Params, context?: HttpContext): Observable<StrictHttpResponse<{
[key: string]: string;
}>> {
const rb = new RequestBuilder(rootUrl, runStatus.PATH, 'get');
if (params) {
rb.path('run_id', params.run_id, {});
}
return http.request(
rb.build({ responseType: 'json', accept: 'application/json', context })
).pipe(
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
map((r: HttpResponse<any>) => {
return r as StrictHttpResponse<{
[key: string]: string;
}>;
})
);
}
runStatus.PATH = '/runs/{run_id}';
-73
View File
@@ -1,73 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export type { Domains$Params as Domains$Params } from './fn/operations/domains';
export { domains as domains } from './fn/operations/domains';
export type { Health$Params as Health$Params } from './fn/operations/health';
export { health as health } from './fn/operations/health';
export type { Pipelines$Params as Pipelines$Params } from './fn/ingest/pipelines';
export { pipelines as pipelines } from './fn/ingest/pipelines';
export type { Pipeline$Params as Pipeline$Params } from './fn/ingest/pipeline';
export { pipeline as pipeline } from './fn/ingest/pipeline';
export type { SavePipeline$Params as SavePipeline$Params } from './fn/ingest/save-pipeline';
export { savePipeline as savePipeline } from './fn/ingest/save-pipeline';
export type { NodeRows$Params as NodeRows$Params } from './fn/ingest/node-rows';
export { nodeRows as nodeRows } from './fn/ingest/node-rows';
export type { StartRun$Params as StartRun$Params } from './fn/ingest/start-run';
export { startRun as startRun } from './fn/ingest/start-run';
export type { Schema$Params as Schema$Params } from './fn/ingest/schema';
export { schema as schema } from './fn/ingest/schema';
export type { SourcePreview$Params as SourcePreview$Params } from './fn/ingest/source-preview';
export { sourcePreview as sourcePreview } from './fn/ingest/source-preview';
export type { SourceResources$Params as SourceResources$Params } from './fn/ingest/source-resources';
export { sourceResources as sourceResources } from './fn/ingest/source-resources';
export type { Upload$Params as Upload$Params } from './fn/ingest/upload';
export { upload as upload } from './fn/ingest/upload';
export type { Models$Params as Models$Params } from './fn/models/models';
export { models as models } from './fn/models/models';
export type { Score$Params as Score$Params } from './fn/models/score';
export { score as score } from './fn/models/score';
export type { Train$Params as Train$Params } from './fn/models/train';
export { train as train } from './fn/models/train';
export type { Versions$Params as Versions$Params } from './fn/models/versions';
export { versions as versions } from './fn/models/versions';
export type { Promote$Params as Promote$Params } from './fn/models/promote';
export { promote as promote } from './fn/models/promote';
export type { AddClinicalValidation$Params as AddClinicalValidation$Params } from './fn/models/add-clinical-validation';
export { addClinicalValidation as addClinicalValidation } from './fn/models/add-clinical-validation';
export type { Conflicts$Params as Conflicts$Params } from './fn/review/conflicts';
export { conflicts as conflicts } from './fn/review/conflicts';
export type { Correct$Params as Correct$Params } from './fn/review/correct';
export { correct as correct } from './fn/review/correct';
export type { Held$Params as Held$Params } from './fn/review/held';
export { held as held } from './fn/review/held';
export type { Persons$Params as Persons$Params } from './fn/review/persons';
export { persons as persons } from './fn/review/persons';
export type { DecidePersons$Params as DecidePersons$Params } from './fn/review/decide-persons';
export { decidePersons as decidePersons } from './fn/review/decide-persons';
export type { Reject$Params as Reject$Params } from './fn/review/reject';
export { reject as reject } from './fn/review/reject';
export type { RunStatus$Params as RunStatus$Params } from './fn/runs/run-status';
export { runStatus as runStatus } from './fn/runs/run-status';
export type { SearchCondition$Params as SearchCondition$Params } from './fn/fhir/search-condition';
export { searchCondition as searchCondition } from './fn/fhir/search-condition';
export type { SearchDiagnosticReport$Params as SearchDiagnosticReport$Params } from './fn/fhir/search-diagnostic-report';
export { searchDiagnosticReport as searchDiagnosticReport } from './fn/fhir/search-diagnostic-report';
export type { SearchMeasure$Params as SearchMeasure$Params } from './fn/fhir/search-measure';
export { searchMeasure as searchMeasure } from './fn/fhir/search-measure';
export type { ReadMeasure$Params as ReadMeasure$Params } from './fn/fhir/read-measure';
export { readMeasure as readMeasure } from './fn/fhir/read-measure';
export type { SearchMeasureReport$Params as SearchMeasureReport$Params } from './fn/fhir/search-measure-report';
export { searchMeasureReport as searchMeasureReport } from './fn/fhir/search-measure-report';
export type { SearchObservation$Params as SearchObservation$Params } from './fn/fhir/search-observation';
export { searchObservation as searchObservation } from './fn/fhir/search-observation';
export type { SearchPatient$Params as SearchPatient$Params } from './fn/fhir/search-patient';
export { searchPatient as searchPatient } from './fn/fhir/search-patient';
export type { ReadPatient$Params as ReadPatient$Params } from './fn/fhir/read-patient';
export { readPatient as readPatient } from './fn/fhir/read-patient';
export type { SearchProcedure$Params as SearchProcedure$Params } from './fn/fhir/search-procedure';
export { searchProcedure as searchProcedure } from './fn/fhir/search-procedure';
export type { SearchRiskAssessment$Params as SearchRiskAssessment$Params } from './fn/fhir/search-risk-assessment';
export { searchRiskAssessment as searchRiskAssessment } from './fn/fhir/search-risk-assessment';
export type { Metadata$Params as Metadata$Params } from './fn/fhir/metadata';
export { metadata as metadata } from './fn/fhir/metadata';
-27
View File
@@ -1,27 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export type { BodyAddClinicalValidation } from './models/body-add-clinical-validation';
export type { BodyUpload } from './models/body-upload';
export type { Condition } from './models/condition';
export type { Correction } from './models/correction';
export type { Domain } from './models/domain';
export type { Extract } from './models/extract';
export type { HttpValidationError } from './models/http-validation-error';
export type { Join } from './models/join';
export type { Link } from './models/link';
export type { Map } from './models/map';
export type { PersonDecision } from './models/person-decision';
export type { Pipeline } from './models/pipeline';
export type { Position } from './models/position';
export type { Read } from './models/read';
export type { Rejection } from './models/rejection';
export type { Route } from './models/route';
export type { RunRequest } from './models/run-request';
export type { SavedPipeline } from './models/saved-pipeline';
export type { Source } from './models/source';
export type { SourceRef } from './models/source-ref';
export type { Target } from './models/target';
export type { Training } from './models/training';
export type { ValidationError } from './models/validation-error';
export type { Version } from './models/version';
@@ -1,6 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface BodyAddClinicalValidation {
file: string;
}
-6
View File
@@ -1,6 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface BodyUpload {
file: string;
}
-8
View File
@@ -1,8 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Condition {
column: string;
op: 'equals' | 'contains' | 'matches' | 'present';
value?: string;
}
-8
View File
@@ -1,8 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Correction {
field: 'record_number' | 'full_name' | 'curp' | 'nss' | 'birth_date' | 'sex' | 'postal_code';
record: string;
value: string;
}
-13
View File
@@ -1,13 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Domain } from './domain';
/**
* Each possible value of `Domain`
*/
export const DOMAIN: Domain[] = [
'cacu',
'cama',
'tea'
];
-5
View File
@@ -1,5 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export type Domain = 'cacu' | 'cama' | 'tea';
-35
View File
@@ -1,35 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Platform fields read from text, each kept with the text it was read from.
*
* `auto` asks the LLM when one is configured and answering, else applies `patterns`;
* with neither, the row is held. Patterns are regexes with one group, per field (the
* LLM can propose them from sample documents); their values go through `values` and
* `formats` as in `map`.
*/
export interface Extract {
column: string;
entity: 'identity' | 'death' | 'clinical_note' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy';
formats?: {
[key: string]: string;
};
hints?: string;
id: string;
inputs?: Array<string>;
kind?: 'extract';
label?: string;
method?: 'auto' | 'llm' | 'patterns';
patterns?: {
[key: string]: string;
};
position?: (Position | null);
values?: {
[key: string]: {
[key: string]: string;
};
};
}
@@ -1,7 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { ValidationError } from '../models/validation-error';
export interface HttpValidationError {
detail?: Array<ValidationError>;
}
-17
View File
@@ -1,17 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Two inputs side by side where their columns match.
*/
export interface Join {
how?: 'inner' | 'left';
id: string;
inputs?: Array<string>;
kind?: 'join';
label?: string;
on: Array<[string, string]>;
position?: (Position | null);
}
-23
View File
@@ -1,23 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Identity rows from every input, grouped into persons (Splink).
*
* Two records are the same person when any rule holds (Splink's SQL rule syntax, `l.`
* and `r.` for the two records); persons are the connected groups. A person whose
* records disagree on birth date or sex is held for review as a whole. Pairs Splink
* scores above `review` that ended up apart are queued as possible matches.
*/
export interface Link {
fields?: Array<string>;
id: string;
inputs?: Array<string>;
kind?: 'link';
label?: string;
position?: (Position | null);
review?: number;
rules?: Array<string>;
}
-26
View File
@@ -1,26 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Columns to platform fields, with the site's codes and date formats.
*/
export interface Map {
fields: {
[key: string]: string;
};
formats?: {
[key: string]: string;
};
id: string;
inputs?: Array<string>;
kind?: 'map';
label?: string;
position?: (Position | null);
values?: {
[key: string]: {
[key: string]: string;
};
};
}
-8
View File
@@ -1,8 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface PersonDecision {
candidate: string;
person: string;
same: boolean;
}
-14
View File
@@ -1,14 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Extract } from '../models/extract';
import { Join } from '../models/join';
import { Link } from '../models/link';
import { Map } from '../models/map';
import { Read } from '../models/read';
import { Route } from '../models/route';
import { Source } from '../models/source';
import { Target } from '../models/target';
export interface Pipeline {
nodes: Array<(Source | Read | Route | Map | Extract | Join | Link | Target)>;
}
-7
View File
@@ -1,7 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Position {
x: number;
y: number;
}
-16
View File
@@ -1,16 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Files in a column (PDF, Word, Excel, scans...) to text (MarkItDown, OCRmyPDF).
*/
export interface Read {
column: string;
id: string;
inputs?: Array<string>;
kind?: 'read';
label?: string;
position?: (Position | null);
}
-8
View File
@@ -1,8 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Rejection {
entity: 'identity' | 'death' | 'clinical_note' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy';
reason: string;
record: string;
}
-17
View File
@@ -1,17 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Condition } from '../models/condition';
import { Position } from '../models/position';
/**
* Only the rows where every condition holds (e.g. reports titled "Citología").
*/
export interface Route {
id: string;
inputs?: Array<string>;
kind?: 'route';
label?: string;
position?: (Position | null);
when: Array<Condition>;
}
-6
View File
@@ -1,6 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface RunRequest {
version?: (number | null);
}
-8
View File
@@ -1,8 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Pipeline } from '../models/pipeline';
export interface SavedPipeline {
pipeline: Pipeline;
version: number;
}
-9
View File
@@ -1,9 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface SourceRef {
args?: {
[key: string]: any;
};
source: string;
}
-23
View File
@@ -1,23 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* One table, file set or API resource, copied as it is (dlt). Merged on the source's
* own primary key or `primary_key`; replaced whole when it has none.
*/
export interface Source {
args?: {
[key: string]: any;
};
id: string;
inputs?: Array<string>;
kind?: 'source';
label?: string;
position?: (Position | null);
primary_key?: Array<string>;
resource?: (string | null);
source: string;
then?: (string | null);
}
-17
View File
@@ -1,17 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { Position } from '../models/position';
/**
* Rows of platform fields into one platform entity, each row given its person by the
* one `link` node among the inputs. Rule breaks are held for review.
*/
export interface Target {
entity: 'identity' | 'death' | 'clinical_note' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy';
id: string;
inputs?: Array<string>;
kind?: 'target';
label?: string;
position?: (Position | null);
}
-6
View File
@@ -1,6 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Training {
as_of?: (string | null);
}
-11
View File
@@ -1,11 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface ValidationError {
ctx?: {
};
input?: any;
loc: Array<(string | number)>;
msg: string;
type: string;
}
-15
View File
@@ -1,15 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
export interface Version {
aliases: Array<string>;
created: number;
metrics: {
[key: string]: number;
};
params: {
[key: string]: string;
};
reports: Array<string>;
version: number;
}
-369
View File
@@ -1,369 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpRequest, HttpParameterCodec, HttpParams, HttpHeaders, HttpContext } from '@angular/common/http';
/**
* Custom parameter codec to correctly handle the plus sign in parameter
* values. See https://github.com/angular/angular/issues/18261
*/
class ParameterCodec implements HttpParameterCodec {
encodeKey(key: string): string {
return encodeURIComponent(key);
}
encodeValue(value: string): string {
return encodeURIComponent(value);
}
decodeKey(key: string): string {
return decodeURIComponent(key);
}
decodeValue(value: string): string {
return decodeURIComponent(value);
}
}
const ParameterCodecInstance = new ParameterCodec();
/**
* Defines the options for appending a parameter
*/
interface ParameterOptions {
style?: string;
explode?: boolean;
}
/**
* Base class for a parameter
*/
abstract class Parameter {
constructor(public name: string, public value: any, public options: ParameterOptions, defaultStyle: string, defaultExplode: boolean) {
this.options = options || {};
if (this.options.style === null || this.options.style === undefined) {
this.options.style = defaultStyle;
}
if (this.options.explode === null || this.options.explode === undefined) {
this.options.explode = defaultExplode;
}
}
serializeValue(value: any, separator = ','): string {
if (value === null || value === undefined) {
return '';
} else if (value instanceof Array) {
return value.map(v => this.serializeValue(v).split(separator).join(encodeURIComponent(separator))).join(separator);
} else if (typeof value === 'object') {
const array: string[] = [];
for (const key of Object.keys(value)) {
let propVal = value[key];
if (propVal !== null && propVal !== undefined) {
propVal = this.serializeValue(propVal).split(separator).join(encodeURIComponent(separator));
if (this.options.explode) {
array.push(`${key}=${propVal}`);
} else {
array.push(key);
array.push(propVal);
}
}
}
return array.join(separator);
} else {
return String(value);
}
}
}
/**
* A parameter in the operation path
*/
class PathParameter extends Parameter {
constructor(name: string, value: any, options: ParameterOptions) {
super(name, value, options, 'simple', false);
}
append(path: string): string {
let value = this.value;
if (value === null || value === undefined) {
value = '';
}
let prefix = this.options.style === 'label' ? '.' : '';
let separator = this.options.explode ? prefix === '' ? ',' : prefix : ',';
let alreadySerialized = false;
if (this.options.style === 'matrix') {
// The parameter name is just used as prefix, except in some cases...
prefix = `;${this.name}=`;
if (this.options.explode && typeof value === 'object') {
prefix = ';';
if (value instanceof Array) {
// For arrays we have to repeat the name for each element
value = value.map(v => `${this.name}=${this.serializeValue(v, ';')}`);
value = value.join(';');
alreadySerialized = true;
} else {
// For objects we have to put each the key / value pairs
value = this.serializeValue(value, ';');
alreadySerialized = true
}
}
}
value = prefix + (alreadySerialized ? value : this.serializeValue(value, separator));
// Replace both the plain variable and the corresponding variant taking in the prefix and explode into account
path = path.replace(`{${this.name}}`, value);
path = path.replace(`{${prefix}${this.name}${this.options.explode ? '*' : ''}}`, value);
return path;
}
// @ts-ignore
serializeValue(value: any, separator = ','): string {
var result = typeof value === 'string' ? encodeURIComponent(value) : super.serializeValue(value, separator);
result = result.replace(/%3D/g, '=');
result = result.replace(/%3B/g, ';');
result = result.replace(/%2C/g, ',');
return result;
}
}
/**
* A parameter in the query
*/
class QueryParameter extends Parameter {
constructor(name: string, value: any, options: ParameterOptions) {
super(name, value, options, 'form', true);
}
append(params: HttpParams): HttpParams {
if (this.value instanceof Array) {
// Array serialization
if (this.options.explode) {
for (const v of this.value) {
params = params.append(this.name, this.serializeValue(v));
}
} else {
const separator = this.options.style === 'spaceDelimited'
? ' ' : this.options.style === 'pipeDelimited'
? '|' : ',';
return params.append(this.name, this.serializeValue(this.value, separator));
}
} else if (this.value !== null && typeof this.value === 'object') {
// Object serialization
if (this.options.style === 'deepObject') {
// Append a parameter for each key, in the form `name[key]`
for (const key of Object.keys(this.value)) {
const propVal = this.value[key];
if (propVal !== null && propVal !== undefined) {
params = params.append(`${this.name}[${key}]`, this.serializeValue(propVal));
}
}
} else if (this.options.explode) {
// Append a parameter for each key without using the parameter name
for (const key of Object.keys(this.value)) {
const propVal = this.value[key];
if (propVal !== null && propVal !== undefined) {
params = params.append(key, this.serializeValue(propVal));
}
}
} else {
// Append a single parameter whose values are a comma-separated list of key,value,key,value...
const array: any[] = [];
for (const key of Object.keys(this.value)) {
const propVal = this.value[key];
if (propVal !== null && propVal !== undefined) {
array.push(key);
array.push(propVal);
}
}
params = params.append(this.name, this.serializeValue(array));
}
} else if (this.value !== null && this.value !== undefined) {
// Plain value
params = params.append(this.name, this.serializeValue(this.value));
}
return params;
}
}
/**
* A parameter in the HTTP request header
*/
class HeaderParameter extends Parameter {
constructor(name: string, value: any, options: ParameterOptions) {
super(name, value, options, 'simple', false);
}
append(headers: HttpHeaders): HttpHeaders {
if (this.value !== null && this.value !== undefined) {
if (this.value instanceof Array) {
for (const v of this.value) {
headers = headers.append(this.name, this.serializeValue(v));
}
} else {
headers = headers.append(this.name, this.serializeValue(this.value));
}
}
return headers;
}
}
/**
* Helper to build http requests from parameters
*/
export class RequestBuilder {
private _path = new Map<string, PathParameter>();
private _query = new Map<string, QueryParameter>();
private _header = new Map<string, HeaderParameter>();
_bodyContent: any | null;
_bodyContentType?: string;
constructor(
public rootUrl: string,
public operationPath: string,
public method: string) {
}
/**
* Sets a path parameter
*/
path(name: string, value: any, options?: ParameterOptions): void {
this._path.set(name, new PathParameter(name, value, options || {}));
}
/**
* Sets a query parameter
*/
query(name: string, value: any, options?: ParameterOptions): void {
this._query.set(name, new QueryParameter(name, value, options || {}));
}
/**
* Sets a header parameter
*/
header(name: string, value: any, options?: ParameterOptions): void {
this._header.set(name, new HeaderParameter(name, value, options || {}));
}
/**
* Sets the body content, along with the content type
*/
body(value: any, contentType = 'application/json'): void {
if (value instanceof Blob) {
this._bodyContentType = value.type;
} else {
this._bodyContentType = contentType;
}
if (this._bodyContentType === 'application/x-www-form-urlencoded' && value !== null && typeof value === 'object') {
// Handle URL-encoded data
const pairs: Array<[string, string]> = [];
for (const key of Object.keys(value)) {
let val = value[key];
if (!(val instanceof Array)) {
val = [val];
}
for (const v of val) {
const formValue = this.formDataValue(v);
if (formValue !== null) {
pairs.push([key, formValue]);
}
}
}
this._bodyContent = pairs.map(p => `${encodeURIComponent(p[0])}=${encodeURIComponent(p[1])}`).join('&');
} else if (this._bodyContentType === 'multipart/form-data') {
// Handle multipart form data
const formData = new FormData();
if (value !== null && value !== undefined) {
for (const key of Object.keys(value)) {
const val = value[key];
if (val instanceof Array) {
for (const v of val) {
const toAppend = this.formDataValue(v);
if (toAppend !== null) {
formData.append(key, toAppend);
}
}
} else {
const toAppend = this.formDataValue(val);
if (toAppend !== null) {
formData.set(key, toAppend);
}
}
}
}
this._bodyContent = formData;
} else {
// The body is the plain content
this._bodyContent = value;
}
}
private formDataValue(value: any): any {
if (value === null || value === undefined) {
return null;
}
if (value instanceof Blob) {
return value;
}
if (typeof value === 'object') {
return new Blob([JSON.stringify(value)], {type: 'application/json'})
}
return String(value);
}
/**
* Builds the request with the current set parameters
*/
build<T = any>(options?: {
/** Which content types to accept */
accept?: string;
/** The expected response type */
responseType?: 'json' | 'text' | 'blob' | 'arraybuffer';
/** Whether to report progress on uploads / downloads */
reportProgress?: boolean;
/** Allow passing HttpContext for HttpClient */
context?: HttpContext;
}): HttpRequest<T> {
options = options || {};
// Path parameters
let path = this.operationPath;
for (const pathParam of this._path.values()) {
path = pathParam.append(path);
}
const url = this.rootUrl + path;
// Query parameters
let httpParams = new HttpParams({
encoder: ParameterCodecInstance
});
for (const queryParam of this._query.values()) {
httpParams = queryParam.append(httpParams);
}
// Header parameters
let httpHeaders = new HttpHeaders();
if (options.accept) {
httpHeaders = httpHeaders.append('Accept', options.accept);
}
for (const headerParam of this._header.values()) {
httpHeaders = headerParam.append(httpHeaders);
}
// Request content headers
if (this._bodyContentType && !(this._bodyContent instanceof FormData)) {
httpHeaders = httpHeaders.set('Content-Type', this._bodyContentType);
}
// Perform the request
return new HttpRequest<T>(this.method.toUpperCase(), url, this._bodyContent, {
params: httpParams,
headers: httpHeaders,
responseType: options.responseType,
reportProgress: options.reportProgress,
context: options.context
});
}
}
-11
View File
@@ -1,11 +0,0 @@
/* eslint-disable */
/* Code generated by ng-openapi-gen DO NOT EDIT. */
import { HttpResponse } from '@angular/common/http';
/**
* Constrains the http response to not have the body defined as `T | null`, but `T` only.
*/
export type StrictHttpResponse<T> = HttpResponse<T> & {
readonly body: T;
}
+91
View File
@@ -0,0 +1,91 @@
// Covers the shell's header: on an indicators page it carries the platform title and the domain selector; on
// the institutional routes it keeps the breadcrumb. The pages are stubs: only the header and the router matter.
import { Component } from '@angular/core';
import { Location } from '@angular/common';
import { TestBed } from '@angular/core/testing';
import { provideRouter, Router } from '@angular/router';
import { provideHttpClient } from '@angular/common/http';
import { provideHttpClientTesting } from '@angular/common/http/testing';
import { App } from './app';
import { routes } from './app.routes';
import { DOMINIOS } from './features/indicadores/indicadores.models';
@Component({ template: 'página', selector: 'app-stub' })
class Stub {}
describe('Encabezado del marco', () => {
const rutas = [
{ path: '', component: Stub },
{ path: 'conectar', component: Stub, data: { workspace: true, breadcrumb: 'Conectar datos' } },
{ path: 'gobernanza', component: Stub, data: { workspace: true, breadcrumb: 'Gobernanza de modelos' } },
...DOMINIOS.map(dominio => ({ path: `indicadores/${dominio}`, component: Stub, data: { workspace: true, breadcrumb: 'Indicadores', dominio } })),
];
let fixture: ReturnType<typeof TestBed.createComponent<App>>, router: Router;
beforeEach(async () => {
await TestBed.configureTestingModule({ imports: [App], providers: [provideRouter(rutas), provideHttpClient(), provideHttpClientTesting()] }).compileComponents();
fixture = TestBed.createComponent(App); router = TestBed.inject(Router);
fixture.detectChanges();
});
afterEach(() => { fixture.destroy(); document.querySelectorAll('.cdk-overlay-container').forEach(e => e.replaceChildren()); });
const root = () => fixture.nativeElement as HTMLElement;
async function ir(url: string) { await router.navigateByUrl(url); await fixture.whenStable(); fixture.detectChanges(); }
const selector = () => root().querySelector('.domain-selector') as HTMLButtonElement | null;
async function abrirMenu() {
selector()!.click(); fixture.detectChanges(); await fixture.whenStable(); fixture.detectChanges();
return [...document.querySelectorAll('.mat-mdc-menu-panel a[mat-menu-item]')] as HTMLAnchorElement[];
}
it('las rutas de los tres dominios existen en el enrutador de la aplicación', () => {
// Fails if the selector would point at a route the application does not have.
// The application's routes live under the guarded parent ('login' is its sibling).
const paths = routes.flatMap((ruta) => [ruta.path, ...(ruta.children ?? []).map((hijo) => hijo.path)]);
for (const dominio of DOMINIOS) expect(paths).toContain(`indicadores/${dominio}`);
});
it.each([['tea', 'Trastorno del espectro autista'], ['cacu', 'Cáncer cervicouterino'], ['cama', 'Cáncer de mama']] as const)('en /indicadores/%s muestra el título de la plataforma y el selector con «%s»', async (dominio, etiqueta) => {
await ir('/indicadores/' + dominio);
expect(root().querySelector('.platform-title')?.textContent).toBe('Plataforma de Indicadores');
expect(selector()?.textContent?.replace(/\s+/g, ' ').trim()).toBe(etiqueta + ' ▾');
expect(root().querySelector('.brand img')?.getAttribute('alt')).toBe('ISSSTELEON');
// The breadcrumb is replaced, not duplicated beside the selector.
expect(root().querySelector('.site-header__nav')).toBeNull();
expect(root().querySelector('.app-shell--indicadores')).not.toBeNull();
});
it('el selector tiene nombre accesible con el dominio actual y anuncia un menú', async () => {
await ir('/indicadores/cama');
expect(selector()!.getAttribute('aria-label')).toBe('Dominio actual: Cáncer de mama. Cambiar dominio');
expect(selector()!.getAttribute('aria-haspopup')).toBe('menu');
expect(selector()!.tagName).toBe('BUTTON');
expect(selector()!.tabIndex).toBeGreaterThanOrEqual(0);
});
it('el menú ofrece los otros dos dominios con sus rutas institucionales', async () => {
await ir('/indicadores/cama');
const items = await abrirMenu();
expect(items.map(a => a.textContent?.trim())).toEqual(['Trastorno del espectro autista', 'Cáncer cervicouterino']);
expect(items.map(a => a.getAttribute('href'))).toEqual(['/indicadores/tea', '/indicadores/cacu']);
expect(selector()!.getAttribute('aria-expanded')).toBe('true');
});
it('elegir otro dominio navega por el enrutador, actualiza el selector y deja una entrada en el historial', async () => {
await ir('/indicadores/cama');
const items = await abrirMenu();
items[1].click(); await fixture.whenStable(); fixture.detectChanges();
expect(router.url).toBe('/indicadores/cacu');
expect(selector()!.textContent).toContain('Cáncer cervicouterino');
// The choice is a router navigation (a history entry), not a page reload: going back lands on the previous domain.
const ubicacion = TestBed.inject(Location);
ubicacion.back(); await new Promise(r => setTimeout(r, 100));
expect(ubicacion.path()).toBe('/indicadores/cama');
});
it.each(['/', '/conectar', '/gobernanza'])('en %s conserva el encabezado institucional sin selector', async url => {
// Fails if the indicators header leaks into the institutional routes.
await ir(url);
expect(selector()).toBeNull();
expect(root().querySelector('.platform-title')).toBeNull();
expect(root().querySelector('.site-header__section')?.textContent).toBe('Análisis de información');
expect(root().querySelector('.app-shell--indicadores')).toBeNull();
if (url !== '/') expect(root().querySelector('.site-header__crumb')?.textContent).toContain(url === '/conectar' ? 'Conectar datos' : 'Gobernanza de modelos');
});
it('una ruta parecida que no es de indicadores no activa el selector', async () => {
await router.navigateByUrl('/'); fixture.detectChanges();
expect(selector()).toBeNull();
});
});
+16 -16
View File
@@ -1,24 +1,24 @@
import { ApplicationConfig, provideBrowserGlobalErrorListeners } from '@angular/core';
import { provideHttpClient } from '@angular/common/http'; import { provideHttpClient } from '@angular/common/http';
import { import { provideRouter } from '@angular/router';
ApplicationConfig,
inject,
provideAppInitializer,
provideBrowserGlobalErrorListeners,
} from '@angular/core';
import { MatIconRegistry } from '@angular/material/icon';
import { provideRouter, withComponentInputBinding } from '@angular/router';
import { provideApiConfiguration } from './api/api-configuration';
import { routes } from './app.routes'; import { routes } from './app.routes';
import { IndicadoresService } from './features/indicadores/indicadores.service';
import { IndicadoresPeriodos } from './features/indicadores/indicadores-periodos';
import { TeaSeguimientoService } from './features/indicadores/tea-seguimiento.service';
import { FhirIndicadoresPeriodos, FhirIndicadoresService } from './features/indicadores/indicadores-fhir';
import { FhirTeaSeguimientoService } from './features/indicadores/tea-seguimiento-fhir';
export const appConfig: ApplicationConfig = { export const appConfig: ApplicationConfig = {
providers: [ providers: [
provideBrowserGlobalErrorListeners(), provideBrowserGlobalErrorListeners(),
provideRouter(routes, withComponentInputBinding()), provideRouter(routes),
// La sesión es del navegador (`auth/auth.service.ts`): no hay interceptor
// porque la WebApi no responde 401.
provideHttpClient(), provideHttpClient(),
provideApiConfiguration('/api'), // The indicator page reads the WebApi's FHIR endpoint; without these lines it reads the indicator JSON contract
// Icons are the Material Symbols font served with the app. // (`/<domain>/indicadores/<id>/datos`, `/tea/seguimiento`).
provideAppInitializer(() => { { provide: IndicadoresService, useClass: FhirIndicadoresService },
inject(MatIconRegistry).setDefaultFontSetClass('material-symbols-outlined'); { provide: IndicadoresPeriodos, useClass: FhirIndicadoresPeriodos },
}), { provide: TeaSeguimientoService, useClass: FhirTeaSeguimientoService },
], ]
}; };
+50 -33
View File
@@ -1,39 +1,56 @@
<div class="shell"> <div class="app-shell" [class.app-shell--workspace]="workspace()" [class.app-shell--indicadores]="!!activeDomain()">
<header class="header"> @if (!sinCromo()) {
<a class="brand" routerLink="/" aria-label="ISSSTELEON, inicio"> <header class="site-header">
<img src="assets/branding/isssteleon-logo.png" alt="ISSSTELEON" /> <div class="site-header__content">
</a> <a class="brand" routerLink="/" aria-label="ISSSTELEON, inicio">
@if (domain(); as current) { <img src="assets/branding/isssteleon-logo.png" alt="ISSSTELEON" />
<span class="title">Plataforma de Indicadores</span> </a>
<button @if (activeDomain(); as domain) {
mat-flat-button <span class="platform-title">{{ title }}</span>
class="domain" @if (otherDomains().length) {
[matMenuTriggerFor]="menu" @defer (on immediate) {
[disabled]="!others().length" <app-domain-selector [actual]="domain" [otros]="otherDomains()" [labels]="domainLabels" />
> } @placeholder {
{{ labels[current] }} <!-- Same size as the selector until its code arrives, so the header does not jump. -->
<mat-icon iconPositionEnd>expand_more</mat-icon> <span class="domain-selector domain-selector--espera" aria-hidden="true">{{ domainLabels[domain] }}</span>
</button> }
<mat-menu #menu="matMenu"> } @else {
@for (d of others(); track d) { <!-- An account with a single domain has nothing to switch to: the domain is a label. -->
<a mat-menu-item [routerLink]="['/indicadores', d]">{{ labels[d] }}</a> <span class="domain-selector domain-selector--espera">{{ domainLabels[domain] }}</span>
}
} @else {
<nav class="site-header__nav" aria-label="Secciones">
<a class="site-header__section" routerLink="/">Análisis de información</a>
@if (breadcrumb(); as crumb) {
<span class="site-header__crumb" aria-current="page">› {{ crumb }}</span>
}
</nav>
} }
</mat-menu> @if (usuario(); as sesion) {
} @else { <button
<span class="title"></span> class="site-header__salir"
} type="button"
<nav class="sections" aria-label="Secciones"> (click)="salir()"
<a routerLink="/indicadores/cacu" routerLinkActive="active">Indicadores</a> [attr.title]="'Cerrar sesión de ' + sesion.nombre"
<a routerLink="/conectar" routerLinkActive="active">Conectar</a> [attr.aria-label]="'Cerrar sesión de ' + sesion.nombre"
<a routerLink="/revision" routerLinkActive="active">Revisión</a> >
</nav> <mat-icon aria-hidden="true">logout</mat-icon>
</header> <span class="site-header__salir-nombre">{{ sesion.nombre }}</span>
</button>
}
</div>
</header>
}
<main class="main"> <main class="app-main">
<router-outlet /> <router-outlet />
</main> </main>
<footer class="footer"> @if (!workspace() && !sinCromo()) {
<img src="assets/branding/isssteleon-logo.png" alt="" /> <footer class="site-footer">
</footer> <div class="site-footer__content">
<img src="assets/branding/isssteleon-logo.png" alt="ISSSTELEON" />
</div>
</footer>
}
</div> </div>
+61 -8
View File
@@ -1,16 +1,69 @@
import { Routes } from '@angular/router'; import { Routes } from '@angular/router';
import { Home } from './home';
import { authGuard } from './auth/auth.guard';
import { dominioGuard } from './auth/dominio.guard';
import { DOMINIOS } from './features/indicadores/indicadores.models';
const loadIndicadores = () => import('./features/indicadores/indicadores-page').then(module => module.IndicadoresPage);
export const routes: Routes = [ export const routes: Routes = [
{ path: '', pathMatch: 'full', redirectTo: 'indicadores/cacu' },
{ {
path: 'indicadores/:domain', path: 'login',
loadComponent: () => import('./indicadores/indicadores').then((m) => m.Indicadores), title: 'Inicio de sesión | ISSSTELEON',
loadComponent: () => import('./auth/login-page').then((m) => m.LoginPage),
// Sin encabezado ni pie: la pantalla ocupa la ventana completa.
data: { sinCromo: true },
}, },
{ {
path: 'indicadores/:domain/pacientes/:id', // Todo lo demás vive detrás de la sesión; el guard corre en cada ruta hija.
loadComponent: () => import('./paciente/paciente').then((m) => m.Paciente), path: '',
canActivateChild: [authGuard],
children: [
{ path: '', component: Home, title: 'Análisis de información | ISSSTELEON' },
{
path: 'indicadores/tea-estatus',
title: 'Casos por estatus | ISSSTELEON',
loadComponent: () => import('./features/indicadores/tea-status-page').then(m => m.TeaStatusPage),
canActivate: [dominioGuard],
data: { workspace: true, breadcrumb: 'Casos por estatus', dominio: 'tea' },
},
{
path: 'conectar',
title: 'Conectar datos | ISSSTELEON',
// Lazy: the workspace (and the ~15 Material modules it uses) only
// downloads when someone actually opens it.
loadComponent: () => import('./connect/components/connect-page/connect-page').then((m) => m.ConnectPage),
data: { workspace: true, breadcrumb: 'Conectar datos' },
},
{
path: 'gobernanza',
title: 'Gobernanza de modelos | ISSSTELEON',
loadComponent: () => import('./governance/components/governance-page/governance-page').then((m) => m.GovernancePage),
data: { workspace: true, breadcrumb: 'Gobernanza de modelos' },
},
{
path: 'bitacora',
title: 'Bitácora de cargas | ISSSTELEON',
loadComponent: () => import('./reportes/reportes-page').then((m) => m.ReportsPage),
data: { workspace: true, breadcrumb: 'Bitácora de cargas' },
},
{
path: 'kpis',
title: 'Indicadores | ISSSTELEON',
loadComponent: () => import('./features/indicadores/kpis-page').then(m => m.KpisPage),
// The page reads CaCu's measures: an account of another domain goes to its own.
canActivate: [dominioGuard],
data: { workspace: true, breadcrumb: 'Indicadores', dominio: 'cacu' },
},
{ path: 'indicadores', pathMatch: 'full', redirectTo: 'indicadores/tea' },
...DOMINIOS.map(dominio => ({
path: `indicadores/${dominio}`,
title: 'Indicadores | ISSSTELEON',
data: { workspace: true, breadcrumb: 'Indicadores', dominio },
canActivate: [dominioGuard],
loadComponent: loadIndicadores,
})),
{ path: '**', redirectTo: '' },
],
}, },
{ path: 'conectar', loadComponent: () => import('./conectar/conectar').then((m) => m.Conectar) },
{ path: 'revision', loadComponent: () => import('./revision/revision').then((m) => m.Revision) },
{ path: '**', redirectTo: 'indicadores/cacu' },
]; ];
+153 -36
View File
@@ -1,74 +1,191 @@
.shell { .app-shell {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
min-height: 100vh;
min-height: 100dvh; min-height: 100dvh;
} }
.header { .site-header {
align-items: center;
background: var(--color-surface); background: var(--color-surface);
border-bottom: 1px solid var(--color-border); border-bottom: 1px solid var(--color-border);
}
.site-header__content {
align-items: center;
display: flex; display: flex;
gap: var(--space-4); justify-content: space-between;
min-height: var(--header-height); min-height: var(--site-header-height);
padding: 0 clamp(16px, 3.2vw, 48px); padding: 0 clamp(32px, 3.2vw, 48px);
}
.brand {
align-items: center;
display: inline-flex;
} }
.brand img { .brand img {
display: block; display: block;
width: clamp(132px, 16vw, 200px); height: auto;
width: clamp(180px, 16vw, 200px);
} }
.title { .site-header__nav {
flex: 1; align-items: center;
font-size: 1.25rem;
font-weight: 500;
}
.domain {
--mat-button-filled-container-color: var(--color-primary);
--mat-button-filled-label-text-color: var(--color-text);
font-weight: 700;
}
.sections {
display: flex; display: flex;
gap: var(--space-4); gap: 6px;
} }
.sections a { .site-header__crumb {
color: var(--color-text-secondary); color: var(--color-primary);
font-size: 15px; font-size: 15px;
font-weight: 600; font-weight: 600;
}
.site-header__section {
text-decoration: none; text-decoration: none;
color: var(--color-text);
font-size: 15px;
font-weight: 500;
letter-spacing: 0.01em;
} }
.sections a.active { .app-main {
color: var(--color-primary);
}
.main {
display: flex; display: flex;
flex: 1; flex: 1;
flex-direction: column;
min-height: 0; min-height: 0;
} }
.footer { .app-shell--workspace {
align-items: center; height: 100dvh;
overflow: hidden;
}
.site-footer {
background: var(--color-text-secondary); background: var(--color-text-secondary);
}
.site-footer__content {
align-items: center;
display: flex; display: flex;
justify-content: center; justify-content: center;
min-height: 86px; min-height: 86px;
padding: 0 clamp(32px, 3.2vw, 48px);
} }
.footer img { .site-footer img {
display: block;
filter: brightness(0) invert(1); filter: brightness(0) invert(1);
width: clamp(155px, 15vw, 185px); height: auto;
width: clamp(160px, 15vw, 185px);
} }
@media (max-width: 720px) { @media (max-width: 600px) {
.title { .site-header__content {
display: none; min-height: var(--site-header-height);
padding: 0 20px;
}
.brand img {
width: clamp(132px, 42vw, 170px);
}
.site-header__section {
font-size: 13px;
text-align: right;
}
.site-footer__content {
min-height: 76px;
padding: 0 20px;
}
.site-footer img {
width: 155px;
} }
} }
.platform-title {
color: var(--color-text);
font-family: var(--issste-font-heading);
font-size: 1.25rem;
font-weight: 500;
line-height: 1.15;
margin-inline-start: var(--issste-space-4);
margin-inline-end: auto;
overflow-wrap: anywhere;
}
.domain-selector--espera {
align-items: center; border-radius: var(--issste-radius); box-sizing: border-box; display: inline-flex; flex: 0 0 auto;
max-width: 100%; background-color: var(--issste-accent); color: var(--issste-text); font-weight: 700; line-height: 1.2;
min-height: 40px; padding: 0 16px; white-space: nowrap;
}
/* Session exit: the same action look as the home buttons, in header size. */
.site-header__salir {
align-items: center;
background: transparent;
border: 1px solid var(--color-action);
border-radius: 8px;
color: var(--color-text);
cursor: pointer;
display: inline-flex;
flex: none;
font: inherit;
font-size: 13px;
font-weight: 600;
gap: 6px;
margin-inline-start: var(--space-4);
min-height: 34px;
padding: 0 var(--space-3);
transition:
background-color 0.2s ease,
border-color 0.2s ease,
color 0.2s ease;
}
.site-header__salir:hover {
background: var(--color-action-hover);
border-color: var(--color-action);
}
.site-header__salir:focus-visible {
outline: 2px solid var(--color-action);
outline-offset: 2px;
}
.site-header__salir mat-icon {
color: var(--color-action);
font-size: 18px;
height: 18px;
width: 18px;
}
// Full domain names need their own track. On a wide header they sit beside the title;
// below 900px the name takes a row of its own so the logo and the exit stay together.
.app-shell--indicadores .site-header__content {
display: grid;
grid-template-columns: auto minmax(0, 1fr) auto auto;
grid-template-areas: "brand title domain salir";
align-items: center;
column-gap: 16px;
row-gap: 8px;
padding-block: 8px;
}
.app-shell--indicadores .brand { grid-area: brand; }
.app-shell--indicadores .platform-title { grid-area: title; margin: 0; overflow-wrap: normal; }
.app-shell--indicadores .domain-selector,
.app-shell--indicadores .domain-selector--espera { grid-area: domain; justify-self: end; }
.app-shell--indicadores .site-header__salir { grid-area: salir; margin-inline-start: 0; }
@media (max-width: 900px) {
.app-shell--indicadores .site-header__content {
grid-template-columns: auto minmax(0, 1fr);
grid-template-areas:
"brand salir"
"domain domain"
"title title";
}
.app-shell--indicadores .domain-selector,
.app-shell--indicadores .domain-selector--espera { justify-self: start; white-space: normal; }
.app-shell--indicadores .platform-title { font-size: 1.125rem; }
}
+110 -8
View File
@@ -1,15 +1,117 @@
import { signal } from '@angular/core';
import { TestBed } from '@angular/core/testing';
import { provideHttpClient } from '@angular/common/http'; import { provideHttpClient } from '@angular/common/http';
import { provideHttpClientTesting } from '@angular/common/http/testing'; import { provideHttpClientTesting } from '@angular/common/http/testing';
import { TestBed } from '@angular/core/testing'; import { provideRouter, Router } from '@angular/router';
import { provideRouter } from '@angular/router'; import { of } from 'rxjs';
import { App } from './app'; import { App } from './app';
import { routes } from './app.routes';
import { AuthService, Usuario } from './auth/auth.service';
const TODOS: Usuario = { usuario: 'admin', nombre: 'Administrador', dominios: ['cacu', 'cama', 'tea'] };
/**
* Doble de la sesión: `App` lee la señal y los guards preguntan si hay sesión y
* qué dominios alcanza. Las pruebas de este archivo cubren el marco, no el
* inicio de sesión en sí (`auth/auth.service.spec.ts`).
*/
function authFalso(sesion: Usuario | null) {
return {
usuario: signal(sesion),
autenticado: signal(sesion !== null),
sesion: () => of(sesion),
puedeVer: (dominio: string) => sesion?.dominios.includes(dominio) ?? false,
logout: () => of(undefined),
limpiar: () => undefined,
};
}
async function montar(sesion: Usuario | null): Promise<Router> {
await TestBed.configureTestingModule({
imports: [App],
providers: [
provideRouter(routes),
provideHttpClient(),
provideHttpClientTesting(),
{ provide: AuthService, useValue: authFalso(sesion) },
],
}).compileComponents();
return TestBed.inject(Router);
}
describe('App', () => { describe('App', () => {
it('creates the shell', async () => { async function render(url: string) {
await TestBed.configureTestingModule({ const fixture = TestBed.createComponent(App);
imports: [App], fixture.detectChanges();
providers: [provideHttpClient(), provideHttpClientTesting(), provideRouter([])], await TestBed.inject(Router).navigateByUrl(url).catch(() => false);
}).compileComponents(); await fixture.whenStable();
expect(TestBed.createComponent(App).componentInstance).toBeTruthy(); fixture.detectChanges();
return fixture.nativeElement as HTMLElement;
}
describe('con sesión de administrador', () => {
beforeEach(() => montar(TODOS));
it('renders the ISSSTELEON shell and home page with its footer', async () => {
const page = await render('/');
expect(page.querySelector('.brand img')?.getAttribute('alt')).toBe('ISSSTELEON');
expect(page.querySelector('h1')?.textContent).toContain('Analiza tu información');
expect(page.querySelector('.home__action')?.getAttribute('href')).toBe('/conectar');
expect(page.querySelector('.site-footer')).not.toBeNull();
});
it('/conectar opens the full-height workspace (breadcrumb, no footer)', async () => {
const page = await render('/conectar');
expect(page.querySelector('app-connect-page')).not.toBeNull();
expect(page.querySelector('.site-header__crumb')?.textContent).toContain('Conectar datos');
expect(page.querySelector('.site-footer')).toBeNull();
}, 15000);
it('/gobernanza opens the governance workspace (breadcrumb, no footer)', async () => {
const page = await render('/gobernanza');
expect(page.querySelector('app-governance-page')).not.toBeNull();
expect(page.querySelector('.site-header__crumb')?.textContent).toContain('Gobernanza de modelos');
expect(page.querySelector('.site-footer')).toBeNull();
});
it('el encabezado nombra al usuario de la sesión y ofrece cerrarla', async () => {
// Fails if the shell forgets the session: the user would have no way out.
const page = await render('/');
expect(page.querySelector('.site-header__salir')?.textContent).toContain('Administrador');
});
});
describe('con una cuenta de un solo dominio', () => {
beforeEach(() => montar({ usuario: 'cacu', nombre: 'Equipo CaCu', dominios: ['cacu'] }));
it('no deja abrir el dominio ajeno: la manda al suyo', async () => {
// Fails if the domain scope exists only on the server: the interface would show an empty page.
await render('/indicadores/cama');
expect(TestBed.inject(Router).url).toBe('/indicadores/cacu');
}, 15000);
it('el encabezado no ofrece los otros dominios', async () => {
const page = await render('/indicadores/cacu');
expect(page.querySelector('app-domain-selector')).toBeNull();
expect(page.querySelector('.domain-selector--espera')?.textContent).toContain('Cáncer cervicouterino');
});
});
describe('sin sesión', () => {
beforeEach(() => montar(null));
it('cualquier ruta manda al inicio de sesión y no muestra el marco', async () => {
const page = await render('/conectar');
expect(TestBed.inject(Router).url).toContain('/login');
expect(page.querySelector('.login')).not.toBeNull();
expect(page.querySelector('.site-header')).toBeNull();
expect(page.querySelector('.site-footer')).toBeNull();
expect(page.querySelector('app-connect-page')).toBeNull();
});
it('el destino pedido viaja en returnUrl para volver después de entrar', async () => {
await render('/gobernanza');
expect(TestBed.inject(Router).url).toContain('returnUrl=%2Fgobernanza');
});
}); });
}); });
+50 -37
View File
@@ -1,51 +1,64 @@
import { Component, computed, inject, resource } from '@angular/core'; import { Component, computed, inject } from '@angular/core';
import { toSignal } from '@angular/core/rxjs-interop'; import { toSignal } from '@angular/core/rxjs-interop';
import { MatButtonModule } from '@angular/material/button';
import { MatIconModule } from '@angular/material/icon'; import { MatIconModule } from '@angular/material/icon';
import { MatMenuModule } from '@angular/material/menu'; import { ActivatedRoute, NavigationEnd, Router, RouterLink, RouterOutlet } from '@angular/router';
import { NavigationEnd, Router, RouterLink, RouterLinkActive, RouterOutlet } from '@angular/router';
import { filter, map } from 'rxjs'; import { filter, map } from 'rxjs';
import { Api } from './api/api'; import { AuthService } from './auth/auth.service';
import { domains } from './api/fn/operations/domains'; import { DomainSelector } from './domain-selector';
import { Domain } from './api/models/domain'; import { Dominio, DOMINIOS } from './features/indicadores/indicadores.models';
export const DOMAINS: Record<Domain, string> = {
cacu: 'Cáncer cervicouterino',
cama: 'Cáncer de mama',
tea: 'TEA',
};
/** The shell: header (logo, the domain's title and switcher, or the section), page, footer. */
@Component({ @Component({
imports: [MatIconModule, RouterLink, RouterOutlet, DomainSelector],
selector: 'app-root', selector: 'app-root',
imports: [
RouterOutlet,
RouterLink,
RouterLinkActive,
MatButtonModule,
MatIconModule,
MatMenuModule,
],
templateUrl: './app.html',
styleUrl: './app.scss', styleUrl: './app.scss',
templateUrl: './app.html',
}) })
export class App { export class App {
private readonly api = inject(Api);
private readonly router = inject(Router); private readonly router = inject(Router);
protected readonly labels = DOMAINS; private readonly route = inject(ActivatedRoute);
protected readonly domains = resource({ loader: () => this.api.invoke(domains) }); private readonly auth = inject(AuthService);
private readonly url = toSignal(
private readonly leafRouteData = toSignal(
this.router.events.pipe( this.router.events.pipe(
filter((e) => e instanceof NavigationEnd), filter((event) => event instanceof NavigationEnd),
map((e) => (e as NavigationEnd).urlAfterRedirects), map(() => {
let route = this.route;
while (route.firstChild) route = route.firstChild;
return route.snapshot.data;
}),
), ),
{ initialValue: '' }, { initialValue: {} as Record<string, unknown> },
);
/** The domain of an indicator page, if this is one. */
protected readonly domain = computed(
() => /^\/indicadores\/(\w+)/.exec(this.url())?.[1] as Domain | undefined,
);
protected readonly others = computed(() =>
(this.domains.value() ?? []).filter((d) => d !== this.domain()),
); );
/** Full-height workspace routes (`data.workspace`) drop the marketing footer. */
readonly workspace = computed(() => !!this.leafRouteData()['workspace']);
readonly breadcrumb = computed(() => this.leafRouteData()['breadcrumb'] as string | undefined);
/** The login screen (`data.sinCromo`) owns the whole window: no header, no footer. */
readonly sinCromo = computed(() => !!this.leafRouteData()['sinCromo']);
protected readonly usuario = this.auth.usuario;
protected readonly title = 'Plataforma de Indicadores';
protected readonly domainLabels: Record<Dominio, string> = {
tea: 'Trastorno del espectro autista', cacu: 'Cáncer cervicouterino', cama: 'Cáncer de mama',
};
private readonly url = toSignal(this.router.events.pipe(
filter((event) => event instanceof NavigationEnd), map(event => event.urlAfterRedirects)), { initialValue: this.router.url });
/** On an indicators page the header names its domain and switches to the others. */
protected readonly activeDomain = computed(() =>
DOMINIOS.find(domain => new RegExp(`^/indicadores/${domain}(?:[/?#]|$)`).test(this.url())));
/** Only the domains the account may see: the header never offers a forbidden one. */
private readonly permitidos = computed<readonly Dominio[]>(() => {
const sesion = this.auth.usuario();
return sesion ? DOMINIOS.filter(dominio => sesion.dominios.includes(dominio)) : DOMINIOS;
});
protected readonly otherDomains = computed(() =>
this.permitidos().filter(domain => domain !== this.activeDomain()));
protected salir(): void {
// Whether the server session was already gone, the browser ends up at the login screen.
this.auth.logout().subscribe({
next: () => void this.router.navigate(['/login']),
error: () => void this.router.navigate(['/login']),
});
}
} }
+22
View File
@@ -0,0 +1,22 @@
import { inject } from '@angular/core';
import { CanActivateFn, Router } from '@angular/router';
import { map } from 'rxjs';
import { AuthService } from './auth.service';
/**
* Sin sesión no hay ruta protegida: se manda al inicio de sesión y se recuerda
* `returnUrl` para volver a donde iba el usuario.
*/
export const authGuard: CanActivateFn = (_ruta, estado) => {
const auth = inject(AuthService);
const router = inject(Router);
return auth
.sesion()
.pipe(
map(
(usuario) =>
usuario !== null ||
router.createUrlTree(['/login'], { queryParams: { returnUrl: estado.url } }),
),
);
};
+60
View File
@@ -0,0 +1,60 @@
// La sesión vive en el navegador (la WebApi no autentica): estas pruebas fijan
// el contrato del servicio —quién entra, qué dominios ve y qué queda guardado—
// porque de él dependen el guard de rutas y el recorte de los selectores.
import { TestBed } from '@angular/core/testing';
import { AuthService } from './auth.service';
describe('AuthService', () => {
let auth: AuthService;
beforeEach(() => {
sessionStorage.clear();
TestBed.configureTestingModule({});
auth = TestBed.inject(AuthService);
});
it('entra con la contraseña correcta y deja al usuario en la señal', () => {
auth.login('cama', 'cama2026').subscribe();
expect(auth.usuario()).toEqual({ usuario: 'cama', nombre: 'Equipo CaMa', dominios: ['cama'] });
expect(auth.autenticado()).toBe(true);
});
it('rechaza una contraseña incorrecta sin abrir sesión', () => {
let error: Error | undefined;
auth.login('cama', 'otra').subscribe({ error: (e: Error) => (error = e) });
expect(error?.message).toContain('incorrectos');
expect(auth.autenticado()).toBe(false);
});
it('dice qué dominios puede ver la cuenta', () => {
auth.login('cama', 'cama2026').subscribe();
expect(auth.puedeVer('cama')).toBe(true);
expect(auth.puedeVer('cacu')).toBe(false);
expect(auth.puedeVer('tea')).toBe(false);
});
it('el administrador ve los tres dominios', () => {
auth.login('admin', 'admin2026').subscribe();
expect(['cacu', 'cama', 'tea'].every((dominio) => auth.puedeVer(dominio))).toBe(true);
});
it('cerrar sesión borra al usuario y lo guardado', () => {
auth.login('tea', 'tea2026').subscribe();
auth.logout().subscribe();
expect(auth.autenticado()).toBe(false);
expect(sessionStorage.getItem('isssteleon.sesion')).toBeNull();
});
it('la sesión sobrevive a una recarga de la pestaña', () => {
// Fails if the login is kept only in memory: a refresh would log the team out mid-task.
auth.login('cacu', 'cacu2026').subscribe();
TestBed.resetTestingModule();
TestBed.configureTestingModule({});
expect(TestBed.inject(AuthService).usuario()?.usuario).toBe('cacu');
});
});
+91
View File
@@ -0,0 +1,91 @@
import { Injectable, computed, signal } from '@angular/core';
import { Observable, of, throwError } from 'rxjs';
/** El usuario de la sesión, con los dominios que la interfaz le deja ver. */
export interface Usuario {
readonly usuario: string;
readonly nombre: string;
readonly dominios: readonly string[];
}
/**
* Cuentas de la interfaz. La WebApi no tiene autenticación: el inicio de sesión
* y el recorte por dominio viven aquí, en el navegador, para ordenar el trabajo
* de cada equipo. No son seguridad: cualquiera puede leer esta lista en el
* paquete de la aplicación y la API responde a quien la llame.
*/
const CUENTAS: readonly (Usuario & { contrasena: string })[] = [
{ usuario: 'admin', contrasena: 'admin2026', nombre: 'Administrador', dominios: ['cacu', 'cama', 'tea'] },
{ usuario: 'cacu', contrasena: 'cacu2026', nombre: 'Equipo CaCu', dominios: ['cacu'] },
{ usuario: 'cama', contrasena: 'cama2026', nombre: 'Equipo CaMa', dominios: ['cama'] },
{ usuario: 'tea', contrasena: 'tea2026', nombre: 'Equipo TEA', dominios: ['tea'] },
];
/** La sesión se guarda por pestaña: cerrar el navegador pide entrar de nuevo. */
const CLAVE = 'isssteleon.sesion';
/**
* Sesión local de la aplicación. Es la única fuente de verdad del usuario: el
* guard pregunta aquí, los paneles filtran dominios con `puedeVer` y salir solo
* borra el registro del navegador.
*/
@Injectable({ providedIn: 'root' })
export class AuthService {
private readonly usuarioActual = signal<Usuario | null>(this.leer());
readonly usuario = this.usuarioActual.asReadonly();
readonly autenticado = computed(() => this.usuarioActual() !== null);
/** Si la cuenta puede ver ese dominio. Sin sesión no se opina (los guards deciden). */
puedeVer(dominio: string): boolean {
const sesion = this.usuarioActual();
return sesion ? sesion.dominios.includes(dominio) : true;
}
/** La sesión guardada en esta pestaña; se resuelve al instante, sin servidor. */
sesion(): Observable<Usuario | null> {
return of(this.usuarioActual());
}
/** Valida contra la lista local; un error marca las credenciales como incorrectas. */
login(usuario: string, contrasena: string): Observable<Usuario> {
const cuenta = CUENTAS.find((c) => c.usuario === usuario.trim() && c.contrasena === contrasena);
if (!cuenta) return throwError(() => new Error('usuario o contraseña incorrectos'));
const sesion: Usuario = { usuario: cuenta.usuario, nombre: cuenta.nombre, dominios: [...cuenta.dominios] };
this.establecer(sesion);
return of(sesion);
}
logout(): Observable<void> {
this.limpiar();
return of(undefined);
}
limpiar(): void {
this.usuarioActual.set(null);
try {
sessionStorage.removeItem(CLAVE);
} catch {
// Almacenamiento deshabilitado: la sesión dura lo que la pestaña en memoria.
}
}
private establecer(sesion: Usuario): void {
this.usuarioActual.set(sesion);
try {
sessionStorage.setItem(CLAVE, JSON.stringify(sesion));
} catch {
// Idem: sin almacenamiento, la sesión no sobrevive a una recarga.
}
}
private leer(): Usuario | null {
try {
const crudo = sessionStorage.getItem(CLAVE);
if (!crudo) return null;
const sesion = JSON.parse(crudo) as Usuario;
return typeof sesion?.usuario === 'string' && Array.isArray(sesion.dominios) ? sesion : null;
} catch {
return null;
}
}
}
+17
View File
@@ -0,0 +1,17 @@
import { Usuario } from './auth.service';
/** Same key AuthService persists the visual session under. */
const CLAVE_SESION = 'isssteleon.sesion';
/**
* Seeds the browser-only visual session before the router and AuthService are created,
* so routes behind authGuard render instead of redirecting to /login. Pair every call
* with `limpiarSesionVisual()` in afterEach so the session never leaks between tests.
*/
export function iniciarSesionVisual(sesion: Usuario = { usuario: 'admin', nombre: 'Administrador', dominios: ['cacu', 'cama', 'tea'] }): void {
sessionStorage.setItem(CLAVE_SESION, JSON.stringify(sesion));
}
export function limpiarSesionVisual(): void {
sessionStorage.removeItem(CLAVE_SESION);
}
+22
View File
@@ -0,0 +1,22 @@
import { inject } from '@angular/core';
import { CanActivateFn, Router } from '@angular/router';
import { map } from 'rxjs';
import { AuthService } from './auth.service';
/**
* Cada cuenta ve solo sus dominios: una ruta con `data.dominio` ajeno manda a la
* cuenta a su primer dominio. Sin sesión no decide nada (`authGuard` ya la
* mandó al inicio de sesión).
*/
export const dominioGuard: CanActivateFn = (ruta) => {
const auth = inject(AuthService);
const router = inject(Router);
const pedido = ruta.data?.['dominio'] as string | undefined;
return auth.sesion().pipe(
map((usuario) => {
if (!usuario || !pedido || usuario.dominios.includes(pedido)) return true;
const propio = usuario.dominios[0];
return propio ? router.createUrlTree(['/indicadores', propio]) : router.createUrlTree(['/']);
}),
);
};
+27
View File
@@ -0,0 +1,27 @@
import { AuthService } from './auth.service';
/**
* Helpers for the screens that list domains (cargar información, gobernanza):
* an account only ever sees its own, and «Todos» only belongs to one that
* reaches every domain — the administrator.
*/
/** De la lista dada, las entradas cuyo dominio alcanza la cuenta. */
export function dominiosPermitidos<T extends { id: string }>(auth: AuthService, dominios: readonly T[]): T[] {
return dominios.filter((dominio) => auth.puedeVer(dominio.id));
}
/** Si la cuenta alcanza todos: solo entonces tiene sentido ofrecer «Todos». */
export function alcanzaTodos(auth: AuthService, dominios: readonly { id: string }[]): boolean {
return dominios.every((dominio) => auth.puedeVer(dominio.id));
}
/**
* El dominio con el que abre una pantalla: el único que alcanza la cuenta, o
* `null` («Todos») cuando alcanza varios. Sin sesión resuelta devuelve `null`,
* que es el comportamiento de siempre.
*/
export function dominioInicial<T extends string>(auth: AuthService, dominios: readonly { id: T }[]): T | null {
const propios = dominiosPermitidos(auth, dominios);
return propios.length === 1 ? propios[0].id : null;
}
+59
View File
@@ -0,0 +1,59 @@
<section class="login" aria-labelledby="login-titulo">
<div class="login__caja">
<img class="login__logo" src="assets/branding/isssteleon-logo.png" alt="ISSSTELEON" />
<h1 class="login__titulo" id="login-titulo">Inicio de sesión</h1>
<form class="login__formulario" (ngSubmit)="ingresar()" novalidate>
<mat-form-field appearance="outline" class="login__campo" subscriptSizing="dynamic">
<input
matInput
name="usuario"
[(ngModel)]="usuario"
placeholder="Usuario"
aria-label="Usuario"
autocomplete="username"
autocapitalize="none"
spellcheck="false"
/>
</mat-form-field>
<mat-form-field appearance="outline" class="login__campo" subscriptSizing="dynamic">
<input
matInput
name="contrasena"
[(ngModel)]="contrasena"
[type]="verContrasena() ? 'text' : 'password'"
placeholder="Contraseña"
aria-label="Contraseña"
autocomplete="current-password"
/>
<button
mat-icon-button
matSuffix
type="button"
class="login__ojo"
(click)="mostrarContrasena()"
[attr.aria-label]="verContrasena() ? 'Ocultar contraseña' : 'Mostrar contraseña'"
[attr.aria-pressed]="verContrasena()"
>
<mat-icon>{{ verContrasena() ? 'visibility_off' : 'visibility' }}</mat-icon>
</button>
</mat-form-field>
@if (error(); as mensaje) {
<p class="login__error" role="alert">{{ mensaje }}</p>
}
<button
type="submit"
class="login__ingresar"
[disabled]="!usuario.trim() || !contrasena || enviando()"
>
{{ enviando() ? 'Ingresando…' : 'Ingresar' }}
</button>
</form>
<p class="login__legal">©{{ anio }} Todos los derechos reservados.</p>
</div>
</section>
+170
View File
@@ -0,0 +1,170 @@
:host {
display: flex;
flex: 1;
min-width: 0;
/* The button borrows the home actions' palette: white with a thin gray border
until the form is complete, then `--color-action` (see styles.scss). */
--login-fondo: #f8f9fa;
--login-borde: #e9ecef;
}
.login {
align-items: center;
display: flex;
flex: 1;
justify-content: center;
/* The whole block sits a little below the middle: the logo above it gives the screen its weight. */
padding: var(--space-9) var(--space-5) var(--space-8);
}
.login__caja {
display: flex;
flex-direction: column;
gap: var(--space-4);
max-width: 340px;
width: 100%;
}
/* The brand opens the screen and is the biggest thing on it: it is what fills the empty space. */
.login__logo {
align-self: center;
display: block;
margin-bottom: 0;
width: 260px;
animation: login-logo-entrada 600ms ease-out both;
}
@keyframes login-logo-entrada {
from {
opacity: 0;
transform: translateY(-8px);
}
to {
opacity: 1;
transform: none;
}
}
@media (prefers-reduced-motion: reduce) {
.login__logo {
animation: none;
}
}
.login__titulo {
align-items: center;
color: var(--color-text);
display: flex;
font-family: var(--font-heading);
font-size: 1.375rem;
font-weight: 600;
gap: var(--space-4);
margin: 0 0 var(--space-2);
white-space: nowrap;
}
/* The two rules that flank the title, as in the reference screen. */
.login__titulo::before,
.login__titulo::after {
background: var(--color-border);
content: '';
flex: 1;
height: 1px;
}
.login__formulario {
display: flex;
flex-direction: column;
gap: var(--space-3);
}
.login__campo {
width: 100%;
--mat-form-field-container-height: 44px;
--mat-form-field-container-vertical-padding: 12px;
}
.login__ojo {
color: var(--color-text-secondary);
}
/* Edge paints its own reveal control over the password field; the eye in the field is ours. */
.login__campo input::-ms-reveal,
.login__campo input::-ms-clear {
display: none;
}
.login__error {
color: var(--mat-sys-error);
font-size: 0.875rem;
margin: calc(-1 * var(--space-1)) 0 0;
}
/* The button shares the fields' width: one column, one border, no icon and no underline.
Its border turns teal when the form is complete, and it fades in instead of switching. */
.login__ingresar {
align-items: center;
background: var(--login-fondo);
border: 1px solid var(--login-borde);
border-radius: 10px;
color: var(--color-text-secondary);
cursor: default;
display: flex;
font: inherit;
font-size: 0.9375rem;
font-weight: 500;
justify-content: center;
margin-top: var(--space-2);
min-height: 46px;
padding: 0 var(--space-5);
text-decoration: none;
transition:
background-color 260ms ease,
border-color 260ms ease,
color 260ms ease;
width: 100%;
}
.login__ingresar:not(:disabled) {
border-color: var(--color-action);
color: var(--color-text);
cursor: pointer;
}
.login__ingresar:hover:not(:disabled) {
background: var(--color-action-hover);
border-color: var(--color-action);
}
.login__ingresar:focus-visible {
outline: 2px solid var(--color-action);
outline-offset: 2px;
}
.login__ingresar:disabled {
background: var(--login-fondo);
border-color: var(--login-borde);
}
.login__legal {
color: var(--color-text-secondary);
font-size: 0.8125rem;
margin: var(--space-4) 0 0;
text-align: center;
}
@media (max-width: 600px) {
.login {
padding: var(--space-7) var(--space-4);
}
.login__caja {
max-width: 100%;
}
.login__logo {
width: 208px;
}
}

Some files were not shown because too many files have changed in this diff Show More