mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 08:12:24 +00:00
Ratchet Cesium-shaped viewer access in files off the Cesium list
A second ratchet beside the Cesium allow-list: files off that list (and outside the Cesium adapter) may no longer reach Cesium through the viewer either. src/render/viewerAccessAllowList.json records, per file, how many such accesses it still makes (the viewer's entities, dataSources, scene, camera, clock, imageryLayers, terrainProvider, trackedEntity and canvas; the scene's primitives, pick, drillPick, pickPosition, globe, frame events, canvas, requestRender and camera), read from the parsed source in their plain, optional, bracketed, call-result and destructured forms. viewer.container, comments and tests do not count. The test fails when a file makes more accesses than recorded, when a recorded count is higher than the file now needs or names a file gone or back on the Cesium list, and when the record grows against origin/main. scripts/viewer-access-baseline.mjs lowers the record to what the files hold; it never adds or raises an entry. The record starts with 25 files and 50 accesses.
This commit is contained in:
1 parent
0f9bd23829
commit
396e7f0deb
7 files changed
+557
No files matched your search
@@ -138,6 +138,7 @@ The highest-leverage places to jump in:
|
||||
|
||||
- **Vue 3 + Pinia for the interface,** [CesiumJS](https://cesium.com/platform/cesiumjs/) for the globe and [Vite](https://vitejs.dev/) to build. See [Building UI](#building-ui).
|
||||
- **Assembly lives in `src/app/`; standalone defaults live in `src/standalone/`.** UI controllers live in `src/ui/`, layer factories in `src/layers/`, portable sources in `src/sources/`, and application operations in `src/services/`. Existing `src/data/<layer>.js` entries retain compatibility; new code belongs with its focused owner.
|
||||
- **Reach the renderer through its contract** ([docs/RENDERER-CONTRACT.md](docs/RENDERER-CONTRACT.md#moving-code-onto-the-contract)): `findDraw`, `findCamera` and the other ports in `src/render/rendererOf.js`, not Cesium or the viewer's `scene`, `camera` or `entities`. Two ratchet tests hold this: only files on `src/render/cesiumAllowList.json` may import Cesium, and `src/render/viewerAccessAllowList.json` caps the viewer accesses each other file still makes. Neither list may grow; when you port code off them, shrink them (`node scripts/viewer-access-baseline.mjs` lowers the second).
|
||||
- Sources acquire records; renderers own Cesium resources. Import `gods-eye-view/layers/<family>/source` when only a source factory is needed. Common voice controls consume the session interface; protocol adapters own connection details.
|
||||
- **Secrets stay server-side.** Anything needing a private key goes through a local proxy under `server/providers/`. The browser only ever sees the Google Maps key (which you restrict) and ephemeral tokens.
|
||||
- `docs/CURRENT-STATE.md` is the authoritative runtime reference — read it first.
|
||||
|
||||
Reference in new issue
Block a user