mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 02:44:02 +00:00
refactor(street-level): one provider, no orbit overview, no prewarm, simpler tile choice
The layer now owns its Mapillary parts directly: the provider registry,
pick router, multi-provider UI summary, params codec helper and provider
context are gone. createStreetLevelLayer({ source }) builds coverage,
sequences, the nearest-image lookup and the MapillaryJS viewer itself; a
single providerOn switch keeps the share link's `mapillary` option (off
draws nothing), and getParams/setParams keep { mapillary, pano, sinceDays }.
No z0-5 overview points: above 60 km nothing is drawn and the panel says to
zoom in; the proxy now serves only coverage z11-14. Tiles come from the
visible ground within range of the camera, ranked from the ground under it
(no line-of-sight ranking or near-range padding). MapillaryJS loads on the
first photo; viewer prewarm is removed. Key status, a rejected key and a
rate limit share one `blocked` state on coverage.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
0f41fb04cd
commit
37a96072fa
51 files changed
+1240
-2659
No files matched your search
@@ -180,15 +180,10 @@ export class StreetLevelControls {
|
||||
|
||||
async _toggleEnabled() {
|
||||
const enabled = this.actions.isEnabled?.() === true;
|
||||
// The pill is the only switch: switching on also brings back a provider
|
||||
// a share link or a tool turned off, or the layer would draw nothing.
|
||||
const dark = enabled
|
||||
? []
|
||||
: (this._state?.providers || []).filter((entry) => entry.on === false);
|
||||
if (dark.length)
|
||||
this._setParams(
|
||||
Object.fromEntries(dark.map((entry) => [entry.id, true])),
|
||||
);
|
||||
// The pill is the only switch: switching on also brings back Mapillary
|
||||
// if a share link or a tool turned it off, or the layer would draw nothing.
|
||||
if (!enabled && this._state?.providerOn === false)
|
||||
this._setParams({ mapillary: true });
|
||||
try {
|
||||
await this.actions.setEnabled?.(!enabled);
|
||||
} catch (error) {
|
||||
|
||||
Reference in new issue
Block a user