Merge branch 'main' into samehkhamis/start-layers

This commit is contained in:
Sameh Khamis authored and GitHub committed 2026-11-19 15:12:01 -08:00
commit 54b6ba827e
62 files changed
+5709 -372

No files matched your search

+42 -11
View File
@@ -2001,14 +2001,33 @@ directory. Every `/api/cctv` route refuses cross-site browser requests but
accepts forwarding headers, so cameras work behind a reverse proxy; a forwarded
request skips the key-bearing Street View fallback and gets the placeholder.
The CCTV layer draws only the cameras on or near the screen. Zoomed out, it
keeps one camera per ground cell sized to the view, preferring a healthy feed,
and the cells are anchored to the ground so a pan keeps the same cameras. The
active camera always shows. Ground placement and coverage geometry load only
for the cameras in view, with at most two attempts per camera and view regime.
The view pass reruns while the camera moves, paced by its own cost. The camera
picker lists the cameras in view, active camera first, and closes with the
count of cameras outside the view.
The CCTV layer draws only the cameras on or near the screen. Zoomed out, a
ground cell with two or more cameras shows one marker at their mean position. A
green camera pictogram sits under its top edge and the count just below its
middle. The marker grows with the count and paints on the world overlay at
callout resolution. The count covers the whole cell up to the horizon, including
its off-screen cameras. Overlapping markers merge and add their counts. A lone
camera whose icon would touch a marker joins the nearest one, unless the HUD
hides the merged marker. In that case the lone camera keeps its icon and the
count stays where it was before the merge. If the marker there would still cover
the icon, the camera stays in its count when the label fits. The active camera
keeps its own icon beside any marker that would cover it and stays out of the
count. A click on a marker zooms in on its group, at least halving the distance
each time. If halving would leave the group wider or taller than the frame, the
view zooms in on the nearest of the group's ground cells with two or more
cameras. The cockpit or a tracked object holds the view in place. Ambient cards
and coverage attach only to
cameras drawn as icons. On a globe map a marker stands on the drawn terrain. A
camera the height batch never answered for takes the drawn terrain as its ground
once it is near the screen. It reads that height again from much closer, once
the terrain in view has loaded, or when the terrain source changes. A later
Re:Earth answer replaces it. A fallback preserves it. Close up every camera
shows. Cameras on one mount draw side by side and their records keep the mount.
Ground placement has at most two attempts per camera and view regime. The view
pass reruns while the camera moves, paced by its own cost, and when the terrain
in view finishes loading. The camera picker lists the active camera first, then
one camera per visible cell, preferring healthy feeds. It ends with the count of
catalog cameras missing from the list.
Traffic owns its rendered-surface observer only while enabled, removes it on disable/destroy, and rebuilds no cached heights on frames where the surface identity is unchanged. Its dots and heat-lines are two renderer draw sets, it animates on the frame port's preRender, and it follows the camera through the camera port at its own 5% threshold rather than the shared `percentageChanged` ledger. The surface identity is the globe port's `surfaceVersion()` and tile readiness its `isSettled('surface')`, so the layer no longer reaches Cesium. Heat-lines are always asked for draped: where the Cesium renderer cannot drape (no depth textures) its draw port draws them (and every other draped line) over the surface, in their colour where the surface hides them and hidden past the horizon, recolouring a line in place when only its colour changes, rather than the layer dropping them.
@@ -2127,7 +2146,10 @@ trail, a route. A layer under another layer's card or label
(`isUnderOtherCard`) does nothing: it neither acts on its item there nor
treats the click as empty space, so a tracked aircraft stays tracked and a
selection stays selected. Context (`src/ui/entityContextBridge.js`) names
nothing under a card. With no card on top, the scene rules are unchanged.
nothing under a card. A layer can claim a target it paints outside the overlay's
entries (`registerClickClaim`) where no card or label is on top. A CCTV count
claims each click that zooms to it, so a tracked aircraft stays tracked.
With no card or claim on top, the scene rules are unchanged.
World-overlay hit rectangles are what is painted on screen until the next
paint: an overlay change (a click subscriber publishing its selection card)
no longer clears them mid-click, and a paint that draws nothing clears them
@@ -6314,7 +6336,16 @@ caption has no place name (KartaView's is where the drive began) and links to
the full-size photo through the image proxy, since kartaview.org's photo
pages fail for signed-out visitors. The viewer itself is `photoViewer.js`,
shared with Panoramax: each provider hands it a `PhotoSources` table (first
and sharper flat and panorama URLs, and the caption fields).
and sharper flat and panorama URLs, and the caption fields). It builds no
element: it presents the viewer through the layer's
`subscribePhotoViewer()`, which the application shell publishes to the
`gev-street-level-photo` store, and `StreetLevelPhotoViewer` draws it in the
viewer host and hands back the canvas the panorama is drawn on (a fresh one
after a lost context). Each mount and each canvas has a key of its own, so
a viewer never draws on another one's elements, and of two viewers
mounting at once only the later one is drawn (`photoViewers.js`): the
earlier one's mount closes. Without a subscribed view these photos cannot
open.
Panoramax (`providers/panoramax/`) is keyless and browser-side: the
meta-catalogue `api.panoramax.xyz` (CORS open) federates every instance, and
@@ -7526,7 +7557,7 @@ silently demoting every later lookup for the session.
ground clamp now lifts the cap _center_ only so the wireframe stays a true pyramid welded to
the plane (was a flattened fan / the ~47.5 m divergence — RESOLVED), re-selecting the active
camera is a no-op (killed a click-flash), and texture swaps gate on canvas content (killed a
periodic white flash). Camera icons are cyan for stills, violet for cameras with a video feed, and amber for the active camera. Coverage is now **metro-wide: 250 cameras** (`CCTV_AUSTIN_MAX_SOURCES`
periodic white flash). Camera icons are green for stills, violet for cameras with a video feed, and amber for the active camera. Coverage is now **metro-wide: 250 cameras** (`CCTV_AUSTIN_MAX_SOURCES`
default 36 → 250, hard bound 300), filtered to `camera_status === TURNED_ON` (~815 live of
1,003 rows). City packs (2026-07-04): Caltrans (districts 4/7/11/3 — SF, LA, San Diego,
Sacramento; cap 300) and TfL London JamCams (cap 250) join Austin (cap 250) as keyless default
+1
View File
@@ -107,6 +107,7 @@ Call it before views render. `onLocaleChange` listeners word their text again at
- **Translate the label, not the value.** Layer ids, enums, share-link parameters, API fields, voice tool schemas and feed data (callsigns, vessel and place names) stay as they are; translate only the text shown for them.
- **No `t()` at module top level.** Keep the English in `msg()` and call `t()` when rendering.
- **Numbers and dates** go through `formatNumber`, `formatDate`, `formatRelativeTime` and `formatUtcDayMonth` from `src/i18n/index.js`, which follow the active language.
Compact CCTV count badges painted on the map use Latin digits, a decimal point and a `K` suffix for thousands (`999`, `1.7K`, `12K`). Each badge keeps its width and reads the same across locales. Format these badges only with `formatCameraCount` in `src/data/cctvCellCounts.js`.
- **Identical English means identical translation,** unless you give it a context: `t('CLEAR', { context: 'action' })` (a button) is its own catalog entry, `action|CLEAR`, while `t('CLEAR')` (the sky) stays separate. English output is the same.
- **Text that should stay English** (a brand, a code, a unit symbol) is simply not wrapped.
+24 -1
View File
@@ -260,6 +260,16 @@ targets in its template, as many as `view.subRings` says, rather than
building them in script; the Omnibar's one other `material-symbols-outlined`
is a stylesheet selector, and the layer disclosure only names a button in a
comment (`src/ui/kit/smallSurfacesControls.test.mjs` pins it).
The Street Level photo viewer of KartaView and Panoramax (the photo, the
panorama canvas and the ‹ › buttons) is `StreetLevelPhotoViewer`, drawn
from what the photo viewer presents rather than built in script. Its ‹ and
› are ghost `UiButton`s, not pressed toggles, whose glyphs are text
characters; the viewer builds no element, and the street-level layer it
belongs to needs no Vue (`src/ui/kit/streetLevelPhotoControls.test.mjs`
pins it). The notice the God's Eye View panel page shows when it loses its
3D graphics (`#status`, in `src/app/globePanelRuntime.js`) stays built in
script: that script is sent to the host as source text and runs in the
host's panel page before the app loads, so it can import nothing.
The Bhote Koshi reconstruction panel's buttons (previous and next beat,
Play, Play scene, Cinematic, Full story, Open original, Lower gorge, the
field reports and Open public map) are ghost `UiButton`s that keep their
@@ -460,7 +470,20 @@ slot whenever its view is drawn.
(done: `RecentImageryReadout` and its day cards, the same way),
Street level (done: `StreetLevelPanel` renders the `gev-street-level`
store that `StreetLevelControls` publishes to; the controls keep their
listeners, EXPAND, focus and resizing), CCTV (done: `CctvPanel` renders
listeners, EXPAND, focus and resizing; `StreetLevelPhotoViewer`, beside
it in the layer panels, teleports into the viewer host the photo viewer
KartaView and Panoramax mount there, which `createPhotoViewer()`
presents through the layer's `subscribePhotoViewer()` and the
application shell publishes to the `gev-street-level-photo` store, so
the portable `./layers/street-level` entries need no Vue; the viewer
keeps every decision, the photo loading, keys, drag and zoom, and draws
its panorama on the canvas the view hands back, a fresh one after a lost
WebGL context; each mount and canvas is keyed, so no viewer reuses
another's elements, and of two viewers mounting at once only the later
is drawn while the earlier one's mount closes; with no view
subscribed, as when the layer runs without the application shell, a
KartaView or Panoramax photo cannot mount),
CCTV (done: `CctvPanel` renders
the whole panel from the `gev-cctv` store, including the camera picker,
the inline pose editor, the frame preview, source badge and typed
summary; `CctvControls` keeps its listeners, the frame requests and the