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": "Fil d’actualités indisponible",
"Disputed: {name}": "Contesté : {name}",
"Administered by {holder} · claimed by {claimant}": "Administré par {holder} · revendiqué par {claimant}",
"Self-administered · claimed by {claimant}": "Autoadministré · revendiqué par {claimant}",
"UN-patrolled zone": "Zone patrouillée par l’ONU",
"Claimed by neither neighbour": "Revendiqué par aucun voisin",
"Video": "Vidéo",
"Photos": "Photos",
"Claimed by {who}": "Selon {who}",
"Claimed": "Affirmation",
"Not yet confirmed by others": "Pas encore confirmé par d’autres",
"Reported by {side} sources": "Rapporté par des sources {side}",
"Reported by {sides}": "Rapporté par {sides}",
"{side} sources": "sources {side}",
"Official": "Officiel",
"Reported by both sides": "Rapporté par les deux camps",
"Independently reported": "Rapporté de façon indépendante",
"Single source": "Source unique",
"International": "Internationale",
"Independent": "Indépendante",
"Unattributed": "Non attribué",
"Outside party": "Partie extérieure",
"Ukraine–Russia": "Ukraine–Russie",
"Israel–Gaza–Lebanon": "Israël–Gaza–Liban",
"Iran–Hormuz": "Iran–Ormuz",
"Yemen–Red Sea": "Yémen–mer Rouge",
"Sudan": "Soudan",
"Sahel": "Sahel",
"Elsewhere": "Ailleurs",
"Strike": "Frappe",
"Alert": "Alerte",
"Air defence": "Défense aérienne",
"Ground fighting": "Combats au sol",
"Casualties": "Victimes",
"Humanitarian": "Humanitaire",
"Disaster": "Catastrophe",
"Protest": "Manifestation",
"Political": "Politique",
"No physical event": "Aucun événement physique",
"Minor incident": "Incident mineur",
"Significant": "Important",
"Major": "Majeur",
"age|now": "maintenant",
"{minutes} min": "{minutes} min",
"{hours} h": "{hours} h",
"{count} sources": {
"one": "{count} source",
"many": "{count} sources",
"other": "{count} sources"
},
"News feed not configured on this server": "Fil d’actualités non configuré sur ce serveur",
"Malformed news hotspots response": "Réponse des foyers d’actualité mal formée",
"Malformed news feed response": "Réponse du fil d’actualités mal formée",
"Pick a shape, then click the map.": "Choisissez une forme, puis cliquez sur la carte.",
"Enter to place the pin, Esc to cancel.": "Enter pour poser l'épingle, Esc pour annuler.",
"Click where the pin goes.": "Cliquez à l'endroit où poser l'épingle.",