Add the news report model, markers and source

The pure half of a news layer: validated records for a news server's
`/api/news/hotspots|feed|outline` contract, a presentation model and canvas
markers and picture cards, and a fetch client.

- Colour carries severity only (0 no physical event, 1 minor, 2 significant,
  3 major), never a side; the category is the icon, the rim is attestation
  (confirmed, a claim, one side's own press), size grows with sources and
  markers fade with age.
- Cards say "Reported by {side} sources" and mark official channels; a
  machine-read English headline is labelled as such.
- `createNewsSource` reads same-origin routes with a 15 s timeout, a 4 MiB cap
  and record-by-record validation; `NEWS_API_PATHS` and `newsQueryAllowed`
  let a host proxy exactly what the client sends. A 503 marked unavailable
  means "not configured": no retries.
- Exported as `./layers/news/source`, with its own package boundary.
This commit is contained in:
Denis Groshev committed 2026-11-06 00:45:22 +01:00
1 parent dd83812a21
commit 2d9d518946
21 files changed
+2653

No files matched your search

+53
View File
@@ -1,4 +1,57 @@
{
"News feed unavailable": "Noticias no disponibles",
"Disputed: {name}": "En disputa: {name}",
"Administered by {holder} · claimed by {claimant}": "Administrado por {holder} · reclamado por {claimant}",
"Self-administered · claimed by {claimant}": "Autogobernado · reclamado por {claimant}",
"UN-patrolled zone": "Zona patrullada por la ONU",
"Claimed by neither neighbour": "Ningún vecino lo reclama",
"Video": "Vídeo",
"Photos": "Fotos",
"Claimed by {who}": "Según {who}",
"Claimed": "Afirmación",
"Not yet confirmed by others": "Aún sin confirmar por otros",
"Reported by {side} sources": "Informado por fuentes de {side}",
"Reported by {sides}": "Informado por {sides}",
"{side} sources": "fuentes de {side}",
"Official": "Oficial",
"Reported by both sides": "Informado por ambos bandos",
"Independently reported": "Informado de forma independiente",
"Single source": "Fuente única",
"International": "Internacional",
"Independent": "Independiente",
"Unattributed": "Sin atribuir",
"Outside party": "Parte externa",
"Ukraine–Russia": "Ucrania–Rusia",
"Israel–Gaza–Lebanon": "Israel–Gaza–Líbano",
"Iran–Hormuz": "Irán–Ormuz",
"Yemen–Red Sea": "Yemen–Mar Rojo",
"Sudan": "Sudán",
"Sahel": "Sahel",
"Elsewhere": "En otros lugares",
"Strike": "Ataque",
"Alert": "Alerta",
"Air defence": "Defensa aérea",
"Ground fighting": "Combates terrestres",
"Casualties": "Víctimas",
"Humanitarian": "Humanitario",
"Disaster": "Catástrofe",
"Protest": "Protesta",
"Political": "Político",
"No physical event": "Sin hecho físico",
"Minor incident": "Incidente menor",
"Significant": "Significativo",
"Major": "Grave",
"age|now": "ahora",
"{minutes} min": "{minutes} min",
"{hours} h": "{hours} h",
"{count} sources": {
"one": "{count} fuente",
"many": "{count} fuentes",
"other": "{count} fuentes"
},
"News feed not configured on this server": "Noticias no configuradas en este servidor",
"Malformed news hotspots response": "Respuesta de focos de noticias mal formada",
"Malformed news feed response": "Respuesta de noticias mal formada",
"NO PLACE LEFT BEHIND": "NINGÚN RINCÓN SIN VIGILAR",
"Initializing photorealistic world...": "Inicializando el mundo fotorrealista...",
"Configuring viewer...": "Configurando el visor...",