Put news on the globe, with a feed panel in the right rail

Events ▸ News draws the last 24 hours of reports from curated hotspots
(Ukraine–Russia, Israel–Gaza–Lebanon, Iran–Hormuz, Yemen–Red Sea, Sudan,
Sahel) and developing situations elsewhere, from any server that answers the
`/api/news` read routes.

- Globe: one marker per merged event, clamped to the ground and culled at the
  horizon; one beacon per hotspot when zoomed out and a pulsing beacon for a
  developing situation; hotspot outlines with disputed areas dotted and
  labelled by who administers and who claims them; picture cards for at most
  ten major or fast-growing events with two or more sources, never
  overlapping, switchable off.
- Panel: hotspot chips, a severity filter (significant and above by default),
  categories, minor news off by default, and a scrolling list of event cards
  with picture, headline, place, sources, age and the sides that reported it.
  "In view" lists what is near the map below 3,000 km once the camera
  settles. A card flies the globe to its event and opens it with a link to
  the publisher. Reduced motion stops the pulse and the flights.
- Core serves no news itself: the local server proxies GEV_NEWS_ORIGIN when it
  is set, and answers 503 unavailable otherwise, so the layer reads "not
  configured" once instead of retrying.
- Share token 9 (enabled-only); voice stays off for this layer.
This commit is contained in:
Denis Groshev committed 2026-11-06 00:45:24 +01:00
1 parent 2d9d518946
commit 5bb489d1fb
48 files changed
+3394 -53

No files matched your search

+378
View File
@@ -0,0 +1,378 @@
/* News rail panel (#news-panel): the last 24 hours as a doom-scroll of event
cards drawn with GEV's own tokens. Colour is
severity only (the layer sets --news-color per card); never a side. The
rail owns placement and height; only the body scrolls. */
.news-panel-inner {
position: relative;
display: flex;
flex-direction: column;
gap: 8px;
min-height: 0;
max-height: 100%;
box-sizing: border-box;
padding: 14px;
border: 1px solid var(--glass-border);
border-radius: var(--panel-radius);
background: var(--glass-bg);
backdrop-filter: blur(24px) saturate(1.4);
-webkit-backdrop-filter: blur(24px) saturate(1.4);
box-shadow:
0 8px 32px rgba(0, 0, 0, 0.5),
0 0 0 1px rgba(255, 255, 255, 0.03) inset,
0 1px 0 rgba(255, 255, 255, 0.06) inset;
}
#news-panel .panel-glow {
position: absolute;
inset: -18px;
background: radial-gradient(
ellipse at center,
rgba(0, 212, 255, 0.16) 0%,
transparent 65%
);
filter: blur(16px);
opacity: 0.25;
pointer-events: none;
}
#news-panel .panel-header {
flex: 0 0 auto;
}
#news-panel-count {
color: var(--text-secondary);
font: 9px var(--font-mono);
}
#news-panel-body {
min-height: 0;
max-height: calc(var(--right-stack-max-height, 50svh) - 64px);
overflow-y: auto;
overscroll-behavior: contain;
}
#news-panel.collapsed #news-panel-body,
#news-panel[hidden] {
display: none !important;
}
#right-context-rail > #news-panel {
position: relative;
inset: auto;
flex: 0 0 auto;
width: 100%;
max-height: 100%;
pointer-events: auto;
}
#right-context-rail > #news-panel:not(.collapsed) {
display: flex;
flex-direction: column;
flex-shrink: 1;
min-height: 0;
}
#right-context-rail.layout-focus > #news-panel:not(.collapsed) {
flex: 0 1 var(--right-panel-allocated-height);
height: var(--right-panel-allocated-height);
min-height: 0;
max-height: var(--right-panel-allocated-height);
}
#right-context-rail.layout-focus
> #news-panel:not(.collapsed)
.news-panel-inner {
height: 100%;
}
#right-context-rail[data-rail-measuring]
> #news-panel:not(.collapsed)
> .news-panel-inner {
height: auto !important;
}
#right-context-rail #news-panel.collapsed {
width: var(--right-display-collapsed-width);
margin-inline-start: auto;
}
#right-context-rail #news-panel.collapsed .news-panel-inner {
height: 50px;
min-height: 50px;
padding-bottom: 10px;
}
@media (max-width: 720px) {
#right-context-rail #news-panel.collapsed {
width: 100%;
}
}
:root[data-ui-theme='cyber'] .news-panel-inner {
border-radius: 0;
clip-path: var(--cyber-panel-frame);
box-shadow: var(--cyber-panel-shadow);
}
.news-readout {
display: flex;
flex-direction: column;
gap: 10px;
min-width: 0;
color: var(--text-primary);
font: 11px/1.4 var(--font-sans);
}
.news-readout__window,
.news-readout__head {
margin: 0;
color: var(--text-secondary);
font: 600 9px var(--font-mono);
letter-spacing: 0.12em;
text-transform: uppercase;
}
.news-readout__chips {
display: flex;
flex-wrap: wrap;
gap: 4px;
}
.news-readout__filters {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 6px;
}
.news-filter {
min-width: 0;
}
.news-toggle {
display: flex;
align-items: center;
gap: 6px;
color: var(--text-secondary);
font-size: 10px;
cursor: pointer;
}
.news-toggle input {
accent-color: var(--accent);
}
.news-readout__section {
display: flex;
flex-direction: column;
gap: 6px;
}
.news-readout__list {
display: flex;
flex-direction: column;
gap: 6px;
margin: 0;
padding: 0;
list-style: none;
}
.news-readout__list.is-stale {
opacity: 0.5;
}
.news-readout__status,
.news-readout__empty {
color: var(--text-dim);
font: 10px var(--font-mono);
}
.news-readout__footer {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
}
.news-card {
border: 1px solid var(--glass-border);
border-inline-start: 3px solid var(--news-color, var(--glass-border));
border-radius: 6px;
background: rgba(255, 255, 255, 0.02);
}
.news-card:hover,
.news-card.is-open {
border-color: var(--glass-border-hover);
border-inline-start-color: var(--news-color);
background: rgba(0, 212, 255, 0.06);
}
.news-card.is-unmapped .news-card__title {
color: var(--text-secondary);
}
.news-card__main {
display: grid;
grid-template-columns: 96px 1fr;
column-gap: 8px;
row-gap: 3px;
width: 100%;
padding: 6px;
border: 0;
background: transparent;
color: inherit;
font: inherit;
text-align: start;
cursor: pointer;
}
.news-card__main > :not(.news-card__thumb) {
grid-column: 1 / -1;
}
.news-card__thumb ~ * {
grid-column: 2 !important;
}
.news-card__thumb {
position: relative;
grid-row: 1 / span 5;
width: 96px;
height: 64px;
overflow: hidden;
border-radius: 4px;
background: var(--bg-dark);
}
.news-card__thumb img {
width: 100%;
height: 100%;
object-fit: cover;
}
.news-card__credit {
position: absolute;
inset-inline-end: 0;
bottom: 0;
max-width: 100%;
overflow: hidden;
padding: 0 4px;
background: rgba(0, 0, 0, 0.6);
color: var(--text-primary);
font-size: 8px;
text-overflow: ellipsis;
white-space: nowrap;
}
.news-card__title {
display: -webkit-box;
overflow: hidden;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
font-size: 12px;
font-weight: 600;
line-height: 1.3;
}
.news-card__note,
.news-card__sides {
color: var(--text-secondary);
font-size: 10px;
}
.news-card__meta {
display: flex;
align-items: center;
gap: 5px;
min-width: 0;
color: var(--text-secondary);
font: 10px var(--font-mono);
}
.news-card__marker {
flex: none;
display: inline-grid;
place-items: center;
width: 14px;
height: 14px;
border: 1px solid rgba(0, 0, 0, 0.8);
border-radius: 50%;
background: var(--news-color);
}
.news-card__marker svg {
width: 9px;
height: 9px;
fill: none;
stroke: var(--bg-dark);
stroke-width: 1.8;
stroke-linecap: round;
stroke-linejoin: round;
}
.news-card__marker.solid svg {
fill: var(--bg-dark);
stroke: none;
}
.news-card__chips {
display: flex;
flex-wrap: wrap;
gap: 4px;
}
.news-chip {
padding: 1px 6px;
border: 1px solid var(--glass-border-hover);
border-radius: 999px;
color: var(--text-secondary);
font: 9px var(--font-mono);
}
.news-chip--official,
.news-chip--confirmed {
border-color: rgba(0, 212, 255, 0.45);
color: var(--text-primary);
}
.news-chip--claimed {
border-style: dashed;
}
.news-card__open {
display: flex;
flex-direction: column;
gap: 6px;
padding: 0 8px 8px;
}
.news-card__original,
.news-card__snippet {
margin: 0;
color: var(--text-primary);
font-size: 11px;
}
.news-card__original {
color: var(--text-secondary);
}
.news-card__others {
display: flex;
flex-direction: column;
gap: 3px;
margin: 0;
padding: 0;
list-style: none;
font-size: 10px;
}
.news-card__others a,
.news-card__link {
color: var(--accent);
text-decoration: none;
overflow-wrap: anywhere;
}
.news-card__others a:hover,
.news-card__link:hover {
text-decoration: underline;
}
.news-card__side {
margin-inline-end: 6px;
color: var(--text-secondary);
}
.news-card__actions {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
font: 10px var(--font-mono);
}
.news-legend {
color: var(--text-secondary);
font-size: 10px;
}
.news-legend summary {
cursor: pointer;
}
.news-legend p {
margin: 4px 0;
}
.news-legend__severity {
display: flex;
flex-wrap: wrap;
gap: 4px 10px;
margin: 4px 0;
padding: 0;
list-style: none;
}
.news-legend__severity li::before {
content: '';
display: inline-block;
width: 8px;
height: 8px;
margin-inline-end: 4px;
border-radius: 50%;
background: var(--news-color);
}
@media (prefers-reduced-motion: no-preference) {
.news-card,
.news-readout__list {
transition:
background var(--transition-fast),
border-color var(--transition-fast),
opacity var(--transition-fast);
}
}