diff --git a/.editorconfig b/.editorconfig
index f166060..c956c72 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -1,4 +1,3 @@
-# Editor configuration, see https://editorconfig.org
root = true
[*]
@@ -11,7 +10,3 @@ trim_trailing_whitespace = true
[*.ts]
quote_type = single
ij_typescript_use_double_quotes = false
-
-[*.md]
-max_line_length = off
-trim_trailing_whitespace = false
diff --git a/.gitignore b/.gitignore
index 13efd40..0038462 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,17 +1,12 @@
-# See https://docs.github.com/get-started/getting-started-with-git/ignoring-files for more about ignoring files.
-
-# Compiled output
/dist
/tmp
/out-tsc
/bazel-out
-# Node
/node_modules
npm-debug.log
yarn-error.log
-# IDEs and editors
.idea/
.project
.classpath
@@ -20,7 +15,6 @@ yarn-error.log
.settings/
*.sublime-workspace
-# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
@@ -29,7 +23,6 @@ yarn-error.log
!.vscode/mcp.json
.history/*
-# Miscellaneous
/.angular/cache
.sass-cache/
/connect.lock
@@ -39,10 +32,8 @@ testem.log
/typings
__screenshots__/
-# System files
.DS_Store
Thumbs.db
-# Playwright
/test-results/
/playwright-report/
diff --git a/src/_theme-colors.scss b/src/_theme-colors.scss
index b629981..2d4e024 100644
--- a/src/_theme-colors.scss
+++ b/src/_theme-colors.scss
@@ -1,10 +1,6 @@
-// This file was generated by running 'ng generate @angular/material:theme-color'.
-// Proceed with caution if making changes to this file.
-
@use 'sass:map';
@use '@angular/material' as mat;
-// Note: Color palettes are generated from primary: #a8c243, tertiary: #5f9ea0
$_palettes: (
primary: (
0: #000000,
diff --git a/src/app/api/api-configuration.ts b/src/app/api/api-configuration.ts
index 6e2dc7b..737b8a7 100644
--- a/src/app/api/api-configuration.ts
+++ b/src/app/api/api-configuration.ts
@@ -3,9 +3,6 @@
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;
@@ -15,9 +12,6 @@ export function provideApiConfiguration(rootUrl: string) {
};
}
-/**
- * Global configuration
- */
@Injectable({
providedIn: 'root',
})
diff --git a/src/app/api/api.ts b/src/app/api/api.ts
index ece177f..655b5d8 100644
--- a/src/app/api/api.ts
+++ b/src/app/api/api.ts
@@ -11,9 +11,6 @@ import { StrictHttpResponse } from './strict-http-response';
export type ApiFnOptional
= (http: HttpClient, rootUrl: string, params?: P, context?: HttpContext) => Observable>;
export type ApiFnRequired = (http: HttpClient, rootUrl: string, params: P, context?: HttpContext) => Observable>;
-/**
- * Helper service to call API functions directly
- */
@Injectable({ providedIn: 'root' })
export class Api {
constructor(
@@ -24,24 +21,14 @@ export class Api {
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(fn: ApiFnRequired
, params: P, context?: HttpContext): Promise;
invoke(fn: ApiFnOptional
, params?: P, context?: HttpContext): Promise;
async invoke(fn: ApiFnRequired
| ApiFnOptional
, params: P, context?: HttpContext): Promise {
@@ -49,9 +36,6 @@ export class Api {
return (await resp).body;
}
- /**
- * Executes an API call, returning the entire response
- */
invoke$Response(fn: ApiFnRequired
, params: P, context?: HttpContext): Promise>;
invoke$Response(fn: ApiFnOptional
, params?: P, context?: HttpContext): Promise>;
invoke$Response(fn: ApiFnRequired
| ApiFnOptional
, params: P, context?: HttpContext): Promise> {
diff --git a/src/app/api/fn/fhir/eeg-summary.ts b/src/app/api/fn/fhir/eeg-summary.ts
index c91dd76..5f333cb 100644
--- a/src/app/api/fn/fhir/eeg-summary.ts
+++ b/src/app/api/fn/fhir/eeg-summary.ts
@@ -12,19 +12,10 @@ import { Domain } from '../../models/domain';
export interface EegSummary$Params {
domain: Domain;
-/**
- * months: the domain's follow-up list over that window up to the cut-off
- */
'follow-up-window'?: (number | null);
-/**
- * explicit window start that overrides follow-up-window
- */
'follow-up-start'?: (string | null);
-/**
- * default: the last day with data
- */
'follow-up-cutoff'?: (string | null);
'follow-up-status'?: (string | null);
}
diff --git a/src/app/api/fn/fhir/post-bundle.ts b/src/app/api/fn/fhir/post-bundle.ts
index 1475811..41fa1d0 100644
--- a/src/app/api/fn/fhir/post-bundle.ts
+++ b/src/app/api/fn/fhir/post-bundle.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface PostBundle$Params {
domain: Domain;
-/**
- * the sender's pipeline (its fhir nodes read this inbox)
- */
sender: string;
body: {
[key: string]: any;
diff --git a/src/app/api/fn/fhir/search-condition.ts b/src/app/api/fn/fhir/search-condition.ts
index a3f0c13..7bca23d 100644
--- a/src/app/api/fn/fhir/search-condition.ts
+++ b/src/app/api/fn/fhir/search-condition.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchCondition$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-diagnostic-report.ts b/src/app/api/fn/fhir/search-diagnostic-report.ts
index 0e9c6e6..7732e43 100644
--- a/src/app/api/fn/fhir/search-diagnostic-report.ts
+++ b/src/app/api/fn/fhir/search-diagnostic-report.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchDiagnosticReport$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-encounter.ts b/src/app/api/fn/fhir/search-encounter.ts
index a75e808..f8c44c2 100644
--- a/src/app/api/fn/fhir/search-encounter.ts
+++ b/src/app/api/fn/fhir/search-encounter.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchEncounter$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-measure-report.ts b/src/app/api/fn/fhir/search-measure-report.ts
index 5407f7e..d482003 100644
--- a/src/app/api/fn/fhir/search-measure-report.ts
+++ b/src/app/api/fn/fhir/search-measure-report.ts
@@ -12,24 +12,12 @@ 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;
diff --git a/src/app/api/fn/fhir/search-observation.ts b/src/app/api/fn/fhir/search-observation.ts
index 65de5fd..bc3617c 100644
--- a/src/app/api/fn/fhir/search-observation.ts
+++ b/src/app/api/fn/fhir/search-observation.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchObservation$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-patient.ts b/src/app/api/fn/fhir/search-patient.ts
index ffb423f..bef5c48 100644
--- a/src/app/api/fn/fhir/search-patient.ts
+++ b/src/app/api/fn/fhir/search-patient.ts
@@ -13,50 +13,23 @@ export interface SearchPatient$Params {
domain: Domain;
'_id'?: (string | null);
-/**
- * months: the domain's follow-up list over that window up to the cut-off
- */
'follow-up-window'?: (number | null);
-/**
- * explicit window start that overrides follow-up-window
- */
'follow-up-start'?: (string | null);
-/**
- * default: the last day with data
- */
'follow-up-cutoff'?: (string | null);
'follow-up-status'?: (string | null);
-/**
- * each word starts a word of her name (case and accents ignored)
- */
name?: (string | null);
-/**
- * [system|]value: a CURP or record number (case ignored)
- */
identifier?: (string | null);
-/**
- * -recent or -risk-
- */
'_sort'?: string;
-/**
- * years
- */
'risk-horizon'?: (number | null);
-/**
- * any of ('DiagnosticReport:subject', 'RiskAssessment:subject', 'Observation:subject')
- */
'_revinclude'?: Array;
-/**
- * DiagnosticReport:result
- */
'_include:iterate'?: Array;
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-procedure.ts b/src/app/api/fn/fhir/search-procedure.ts
index bb932f8..2ca5ad2 100644
--- a/src/app/api/fn/fhir/search-procedure.ts
+++ b/src/app/api/fn/fhir/search-procedure.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchProcedure$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/fn/fhir/search-risk-assessment.ts b/src/app/api/fn/fhir/search-risk-assessment.ts
index 63d2e4a..b6adcc0 100644
--- a/src/app/api/fn/fhir/search-risk-assessment.ts
+++ b/src/app/api/fn/fhir/search-risk-assessment.ts
@@ -12,9 +12,6 @@ import { Domain } from '../../models/domain';
export interface SearchRiskAssessment$Params {
domain: Domain;
-/**
- * Patient/, comma-separated
- */
subject?: (string | null);
'_count'?: (number | null);
'_offset'?: number;
diff --git a/src/app/api/models/condition.ts b/src/app/api/models/condition.ts
index 045ab03..48f0457 100644
--- a/src/app/api/models/condition.ts
+++ b/src/app/api/models/condition.ts
@@ -3,14 +3,8 @@
export interface Condition {
- /**
- * Por ejemplo «text», el texto leído del documento.
- */
column: string;
op: 'equals' | 'contains' | 'matches' | 'present';
- /**
- * Lo que se busca; por ejemplo «citología».
- */
value?: string;
}
diff --git a/src/app/api/models/correction.ts b/src/app/api/models/correction.ts
index bf2543d..2a6e0e4 100644
--- a/src/app/api/models/correction.ts
+++ b/src/app/api/models/correction.ts
@@ -2,10 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * One field of one record as a reviewer read it in the source document: an identity
- * field (a mistyped record number) or a study's (a stage the scan made unreadable).
- */
export interface Correction {
entity?: 'identity' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy' | 'breast_treatment' | 'breast_recurrence' | 'clinical_note' | 'death' | 'mchat' | 'ados2' | 'eeg';
field: string;
diff --git a/src/app/api/models/domain-array.ts b/src/app/api/models/domain-array.ts
index 14c6f90..333d797 100644
--- a/src/app/api/models/domain-array.ts
+++ b/src/app/api/models/domain-array.ts
@@ -3,9 +3,6 @@
import { Domain } from './domain';
-/**
- * Each possible value of `Domain`
- */
export const DOMAIN: Domain[] = [
'cacu',
'cama',
diff --git a/src/app/api/models/edf.ts b/src/app/api/models/edf.ts
index e935a12..ccc88e8 100644
--- a/src/app/api/models/edf.ts
+++ b/src/app/api/models/edf.ts
@@ -3,30 +3,12 @@
import { Position } from '../models/position';
-/**
- * EDF files (a column of file hashes) to the facts their header holds: patient code, sex,
- * birth date, recording date, record code, duration and channel count, as `edf_*` columns.
- * An unreadable file keeps its row with `edf_error` set.
- *
- * Use a filesystem source (`dlt.sources.filesystem:filesystem`) with the uploads folder as
- * `bucket_url`, `file_glob: "*.edf"`, and `then: "persistance.readers:read_bytes"`. Read its
- * `content` column with this node. Map `edf_patient_code`, `edf_birth_date`, and `edf_sex` to
- * identity's `record_number`, `birth_date`, and `sex`, using the site's formats and ConceptMap.
- *
- * The patient code must match the hospital's record number including its prefix. Feed the
- * identity map into the pipeline's link node alongside the hospital identity source. Map
- * `edf_study_date` to `study_date` (format `%Y-%m-%d`), `edf_record_code` to `lab_record_id`,
- * and `content` to `edf`, then feed that map and the link into a target with entity `eeg`.
- */
export interface Edf {
column: string;
id: string;
inputs?: Array;
kind?: 'edf';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
}
diff --git a/src/app/api/models/execution.ts b/src/app/api/models/execution.ts
index b8a6ccd..e3a5601 100644
--- a/src/app/api/models/execution.ts
+++ b/src/app/api/models/execution.ts
@@ -2,9 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * What a request or a job config carries: None means the deployment's default.
- */
export interface Execution {
mode?: ('sync' | 'local' | 'remote' | null);
scheduler?: (string | null);
diff --git a/src/app/api/models/extract.ts b/src/app/api/models/extract.ts
index 56b7cd5..1ea49ac 100644
--- a/src/app/api/models/extract.ts
+++ b/src/app/api/models/extract.ts
@@ -3,50 +3,27 @@
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 the ConceptMap
- * and `formats` as in `map`.
- */
export interface Extract {
column: (string | Array);
- /**
- * Dato → columna, sin leer el texto.
- */
columns?: {
[key: string]: string;
};
concept_map?: (string | null);
- /**
- * Qué estudio se saca del documento.
- */
entity: 'identity' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy' | 'breast_treatment' | 'breast_recurrence' | 'clinical_note' | 'death' | 'mchat' | 'ados2' | 'eeg';
formats?: {
[key: string]: string;
};
- /**
- * Para el modelo de lenguaje.
- */
hints?: string;
id: string;
inputs?: Array;
kind?: 'extract';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
method?: 'auto' | 'llm' | 'patterns';
- /**
- * Dato → expresión con un grupo ( ).
- */
patterns?: {
[key: string]: string;
};
diff --git a/src/app/api/models/fhir.ts b/src/app/api/models/fhir.ts
index 53d2d6d..e70821b 100644
--- a/src/app/api/models/fhir.ts
+++ b/src/app/api/models/fhir.ts
@@ -3,11 +3,6 @@
import { Position } from '../models/position';
-/**
- * FHIR R4 Bundles a standard hospital sent (a column of their JSON) as rows of one
- * entity: identity, death or a study (core.fhir_in). The sender's own codes go through
- * its ConceptMap.
- */
export interface Fhir {
column?: string;
concept_map?: (string | null);
@@ -16,9 +11,6 @@ export interface Fhir {
inputs?: Array;
kind?: 'fhir';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
}
diff --git a/src/app/api/models/folder-training-source.ts b/src/app/api/models/folder-training-source.ts
index 4132452..2c5f1e0 100644
--- a/src/app/api/models/folder-training-source.ts
+++ b/src/app/api/models/folder-training-source.ts
@@ -3,9 +3,6 @@
export interface FolderTrainingSource {
- /**
- * Carpeta dentro de TEA_REFERENCE_ROOT
- */
folder: string;
kind: 'folder';
line_hz?: 50 | 60;
diff --git a/src/app/api/models/guided.ts b/src/app/api/models/guided.ts
index e75cc8f..8ae5029 100644
--- a/src/app/api/models/guided.ts
+++ b/src/app/api/models/guided.ts
@@ -2,10 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * How the Conectar dialog drew a source: its type (core.sources) and the answers given.
- * The node's dlt fields are made from them; drawn by hand ("Avanzado"), a node has none.
- */
export interface Guided {
answers?: {
[key: string]: any;
diff --git a/src/app/api/models/join.ts b/src/app/api/models/join.ts
index 8a820be..323d11c 100644
--- a/src/app/api/models/join.ts
+++ b/src/app/api/models/join.ts
@@ -3,23 +3,14 @@
import { Position } from '../models/position';
-/**
- * Two inputs side by side where their columns match.
- */
export interface Join {
how?: 'inner' | 'left';
id: string;
inputs?: Array;
kind?: 'join';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
- /**
- * Columna de la primera entrada = columna de la segunda.
- */
on: Array<[string, string]>;
position?: (Position | null);
}
diff --git a/src/app/api/models/link.ts b/src/app/api/models/link.ts
index 9e3d8b0..96f5050 100644
--- a/src/app/api/models/link.ts
+++ b/src/app/api/models/link.ts
@@ -3,33 +3,16 @@
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;
id: string;
inputs?: Array;
kind?: 'link';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
- /**
- * Parecidos por encima de esto los ve un revisor.
- */
review?: number;
- /**
- * Vacío: las de siempre (mismo identificador, o misma fecha de nacimiento y nombre).
- */
rules?: Array;
}
diff --git a/src/app/api/models/listing.ts b/src/app/api/models/listing.ts
index f669610..368e55a 100644
--- a/src/app/api/models/listing.ts
+++ b/src/app/api/models/listing.ts
@@ -2,10 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * What "Probar conexión" shows: a database's tables (the resources of `source`, built
- * from `args`), or the first rows the type's own node reads (files, records).
- */
export interface Listing {
args?: {
[key: string]: any;
diff --git a/src/app/api/models/map.ts b/src/app/api/models/map.ts
index 3efccb7..e3e4adc 100644
--- a/src/app/api/models/map.ts
+++ b/src/app/api/models/map.ts
@@ -3,27 +3,14 @@
import { Position } from '../models/position';
-/**
- * Columns to platform fields, the site's codes translated by its ConceptMap
- * (core.concept_map), and its date formats.
- */
export interface Map {
- /**
- * La tabla de códigos del sitio.
- */
concept_map?: (string | null);
- /**
- * Dato de la plataforma → columna del sitio.
- */
fields: {
[key: string]: string;
};
- /**
- * Por ejemplo %d/%m/%Y.
- */
formats?: {
[key: string]: string;
};
@@ -31,15 +18,9 @@ export interface Map {
inputs?: Array;
kind?: 'map';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
- /**
- * Un dato igual para todas las filas.
- */
values?: {
[key: string]: string;
};
diff --git a/src/app/api/models/progress.ts b/src/app/api/models/progress.ts
index 1b97efe..e5168b9 100644
--- a/src/app/api/models/progress.ts
+++ b/src/app/api/models/progress.ts
@@ -4,9 +4,6 @@
import { Tasks } from '../models/tasks';
import { Worker } from '../models/worker';
-/**
- * The run tag's JSON; the API returns it as it is.
- */
export interface Progress {
done: number;
elapsed_s: number;
diff --git a/src/app/api/models/provider.ts b/src/app/api/models/provider.ts
index 43e30cc..675988c 100644
--- a/src/app/api/models/provider.ts
+++ b/src/app/api/models/provider.ts
@@ -2,9 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * A sign-in button's OAuth 2.0 provider (authorization code flow).
- */
export interface Provider {
authorize_params?: {
[key: string]: string;
diff --git a/src/app/api/models/read.ts b/src/app/api/models/read.ts
index 2f7b104..65352fc 100644
--- a/src/app/api/models/read.ts
+++ b/src/app/api/models/read.ts
@@ -3,22 +3,13 @@
import { Position } from '../models/position';
-/**
- * Files in a column (PDF, Word, Excel, scans...) to text (MarkItDown, OCRmyPDF).
- */
export interface Read {
- /**
- * Donde la entrada trae cada documento.
- */
column: string;
id: string;
inputs?: Array;
kind?: 'read';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
}
diff --git a/src/app/api/models/route.ts b/src/app/api/models/route.ts
index 57ac688..0f109e1 100644
--- a/src/app/api/models/route.ts
+++ b/src/app/api/models/route.ts
@@ -4,24 +4,13 @@
import { Condition } from '../models/condition';
import { Position } from '../models/position';
-/**
- * Only the rows where every condition holds (e.g. reports titled "Citología"). An
- * `otherwise` route takes the rows of its input that none of the other routes on that
- * input take (documents nobody recognises, for a reviewer), then its own conditions.
- */
export interface Route {
id: string;
inputs?: Array;
kind?: 'route';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
- /**
- * Recoge lo que nadie reconoce, para revisarlo.
- */
otherwise?: boolean;
position?: (Position | null);
when?: Array;
diff --git a/src/app/api/models/scope.ts b/src/app/api/models/scope.ts
index e0aa5d0..b3a6e24 100644
--- a/src/app/api/models/scope.ts
+++ b/src/app/api/models/scope.ts
@@ -2,10 +2,6 @@
/* Code generated by ng-openapi-gen DO NOT EDIT. */
-/**
- * Which EEGs an analysis takes: the pending ones, the first `n` of them, or the named
- * ones (re-analysis), each named by the `id` that `/tea/eegs` shows.
- */
export interface Scope {
ids?: Array;
mode?: 'pending' | 'first_n' | 'ids';
diff --git a/src/app/api/models/source.ts b/src/app/api/models/source.ts
index ca4498a..dc41355 100644
--- a/src/app/api/models/source.ts
+++ b/src/app/api/models/source.ts
@@ -4,15 +4,8 @@
import { Guided } from '../models/guided';
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 {
- /**
- * Los de la fuente dlt.
- */
args?: {
[key: string]: any;
};
@@ -21,29 +14,14 @@ export interface Source {
inputs?: Array;
kind?: 'source';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
- /**
- * Columnas que identifican una fila.
- */
primary_key?: Array;
- /**
- * Cuál, si la fuente ofrece varios (una tabla).
- */
resource?: (string | null);
- /**
- * Módulo:función de la fuente dlt.
- */
source: string;
- /**
- * Transformador dlt para los archivos.
- */
then?: (string | null);
}
diff --git a/src/app/api/models/target.ts b/src/app/api/models/target.ts
index d06856c..15a6208 100644
--- a/src/app/api/models/target.ts
+++ b/src/app/api/models/target.ts
@@ -3,23 +3,13 @@
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 {
- /**
- * En qué estudio de la plataforma se guarda.
- */
entity: 'identity' | 'cervical_cytology' | 'cervical_biopsy' | 'mammography' | 'breast_biopsy' | 'breast_treatment' | 'breast_recurrence' | 'clinical_note' | 'death' | 'mchat' | 'ados2' | 'eeg';
id: string;
inputs?: Array;
kind?: 'target';
- /**
- * Cómo se ve en el diagrama.
- */
label?: string;
position?: (Position | null);
}
diff --git a/src/app/api/models/training.ts b/src/app/api/models/training.ts
index 2abbf55..93e4788 100644
--- a/src/app/api/models/training.ts
+++ b/src/app/api/models/training.ts
@@ -5,9 +5,6 @@ import { Execution } from '../models/execution';
import { TrainingSource } from '../models/training-source';
export interface Training {
- /**
- * Fecha de corte de los datos (por omisión, hoy)
- */
as_of?: (string | null);
execution?: (Execution | null);
models?: Array;
diff --git a/src/app/api/request-builder.ts b/src/app/api/request-builder.ts
index 9e28788..5b95b12 100644
--- a/src/app/api/request-builder.ts
+++ b/src/app/api/request-builder.ts
@@ -3,10 +3,6 @@
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);
@@ -26,17 +22,11 @@ class ParameterCodec implements HttpParameterCodec {
}
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 || {};
@@ -74,9 +64,6 @@ abstract class Parameter {
}
}
-/**
- * A parameter in the operation path
- */
class PathParameter extends Parameter {
constructor(name: string, value: any, options: ParameterOptions) {
super(name, value, options, 'simple', false);
@@ -91,24 +78,20 @@ class PathParameter extends Parameter {
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;
@@ -124,9 +107,6 @@ class PathParameter extends Parameter {
}
}
-/**
- * A parameter in the query
- */
class QueryParameter extends Parameter {
constructor(name: string, value: any, options: ParameterOptions) {
super(name, value, options, 'form', true);
@@ -134,7 +114,6 @@ class QueryParameter extends Parameter {
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));
@@ -146,9 +125,7 @@ class QueryParameter extends Parameter {
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) {
@@ -156,7 +133,6 @@ class QueryParameter extends Parameter {
}
}
} 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) {
@@ -164,7 +140,6 @@ class QueryParameter extends Parameter {
}
}
} 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];
@@ -176,16 +151,12 @@ class QueryParameter extends Parameter {
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);
@@ -205,9 +176,6 @@ class HeaderParameter extends Parameter {
}
}
-/**
- * Helper to build http requests from parameters
- */
export class RequestBuilder {
private _path = new Map();
@@ -222,30 +190,18 @@ export class RequestBuilder {
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;
@@ -253,7 +209,6 @@ export class RequestBuilder {
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];
@@ -269,7 +224,6 @@ export class RequestBuilder {
}
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)) {
@@ -291,7 +245,6 @@ export class RequestBuilder {
}
this._bodyContent = formData;
} else {
- // The body is the plain content
this._bodyContent = value;
}
}
@@ -309,33 +262,24 @@ export class RequestBuilder {
return String(value);
}
- /**
- * Builds the request with the current set parameters
- */
build(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 {
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
});
@@ -343,7 +287,6 @@ export class RequestBuilder {
httpParams = queryParam.append(httpParams);
}
- // Header parameters
let httpHeaders = new HttpHeaders();
if (options.accept) {
httpHeaders = httpHeaders.append('Accept', options.accept);
@@ -352,12 +295,10 @@ export class RequestBuilder {
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(this.method.toUpperCase(), url, this._bodyContent, {
params: httpParams,
headers: httpHeaders,
diff --git a/src/app/api/strict-http-response.ts b/src/app/api/strict-http-response.ts
index 174f119..e4cbf57 100644
--- a/src/app/api/strict-http-response.ts
+++ b/src/app/api/strict-http-response.ts
@@ -3,9 +3,6 @@
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 = HttpResponse & {
readonly body: T;
}
diff --git a/tsconfig.app.json b/tsconfig.app.json
index 1eb42f4..281dc21 100644
--- a/tsconfig.app.json
+++ b/tsconfig.app.json
@@ -1,5 +1,3 @@
-/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
-/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
{
"extends": "./tsconfig.json",
"compilerOptions": {
diff --git a/tsconfig.json b/tsconfig.json
index d2fbb9c..d31de45 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -1,5 +1,3 @@
-/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
-/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
{
"compileOnSave": false,
"compilerOptions": {
diff --git a/tsconfig.spec.json b/tsconfig.spec.json
index aecce35..d5b00dc 100644
--- a/tsconfig.spec.json
+++ b/tsconfig.spec.json
@@ -1,5 +1,3 @@
-/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
-/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
{
"extends": "./tsconfig.json",
"compilerOptions": {