mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-13 06:42:23 +00:00
fix(street-level): links keep the recipient's preferences; aim under the screen centre
Review fixes for gekh's #1113 round: - a link runs show_street_level with origin 'programmatic', so its source switch and layer are not saved as the recipient's preferences; - with no place named, the action looks under the screen centre (aim 'screen-centre', armed false), keeps the sky refusal and leaves a link's armed point alone; - an armed OPEN aimed at the sky opens nothing instead of the far link point; - an imagery-stage failure is spoken as an error, missing imagery as missing (street.nearestOutcome); the card says "the view centre" in the interface language; - every photo the action opens reveals its panel, and revealPanel scrolls the panel into view in the phone sheet; - embed: EXPAND survives embed's own clean view, the lifted photo hides in cockpit, recording and scene playback, and a failed photo step closes the earlier photo before the view flies; - links pasted into an open tab run their street-level step after the restore settles; a superseded start link does not; - Mapillary's nearest search gives up after 12 s, body included.
This commit is contained in:
1 parent
3f55077c2c
commit
451f3e41cf
22 files changed
+716
-64
No files matched your search
+25
-10
@@ -4483,26 +4483,35 @@ app.
|
||||
(voice and typed; `src/voice/gevActions.js`) is one call: it checks the
|
||||
source has its key (a keyless source explains itself and changes nothing, as
|
||||
a chip does), flies to the place at street framing and waits for arrival (a
|
||||
name, coordinates, a pointed spot, a numbered item, or nothing for the view
|
||||
centre), switches to the map the source needs (Google Street View: Google 3D),
|
||||
name, coordinates, a pointed spot, a numbered item, or nothing for the
|
||||
ground under the screen centre, as OPEN uses: `aim: 'screen-centre'` with
|
||||
`armed: false`, so sky refuses and a link's armed point is neither used nor
|
||||
dropped), switches to the map the source needs (Google Street View: Google 3D),
|
||||
lights that source through `setLayerParams` with origin `voice` (one source at
|
||||
a time, kept in the share link like a chip click), turns the layer on and
|
||||
a time, kept in the share link like a chip click; a link runs the action with
|
||||
origin `programmatic`, for the source switch and the layer, so it never writes
|
||||
the recipient's saved layer state), turns the layer on and
|
||||
calls `openNearest`. `provider` is `google` for "Street View", `mapillary`,
|
||||
`kartaview` or `panoramax` by name, else the lit source. Stages fail separately (`location`, `view`, `map`,
|
||||
`provider`, `layer`, `key`, `imagery`; `view` when cockpit, clean view,
|
||||
recording or scene playback hides the panel, checked after the flight and
|
||||
before anything switches or loads; embed mode exempts its own clean-view
|
||||
class because the photo is lifted above the globe; an empty `imagery` result names a
|
||||
narrowing 360°/flat or SINCE filter the source honours, as `filter`) and a
|
||||
narrowing 360°/flat or SINCE filter the source honours, as `filter`;
|
||||
`noImagery` marks an empty result, `imageryError` a source or viewer failure
|
||||
and `aim: 'sky'` a sky centre, from the layer's `street.nearestOutcome`) and a
|
||||
newer turn retires the lookup
|
||||
(`openNearest`'s `signal` option), so nothing opens after the user moved on.
|
||||
For a source without a coverage layer the lookup widens to 250 m
|
||||
(`NEAREST_RADIUS_MAX_M`; Google honours it, Mapillary's API caps at 50 m);
|
||||
clicks keep 50 m. Mapillary's search asks for 100 photos, the API's most: it
|
||||
clicks keep 50 m. Mapillary's search gives up after 12 s, body included
|
||||
(`NEAREST_TIMEOUT_MS`), and asks for 100 photos, the API's most: it
|
||||
returns the radius's photos in no particular order and cuts them at the limit
|
||||
first, so the distance sort and the imagery filter run over the spot's photos.
|
||||
On a phone the panel sits in the Cameras tab sheet: a photo that opens, and a
|
||||
link that arms, open that sheet (`revealPanel`). The layer exposes `requiredMapStack(id)` and
|
||||
link that arms, open that sheet and scroll the panel into view
|
||||
(`revealPanel`); every photo the action opens reveals the panel again, also
|
||||
one the user had collapsed. The layer exposes `requiredMapStack(id)` and
|
||||
`providerStatus(id)` for callers that must decide before the panel lists a
|
||||
source, and `coverageLines(id)` (the lines a provider draws now, current and
|
||||
stale tiles, as `[lon, lat]` parts) for diagnostics and the browser gate,
|
||||
@@ -4513,10 +4522,15 @@ source and point, defaulting to where the camera looks; a `google` source
|
||||
brings `map: photoreal` and refuses another map; not with `follow`), links as
|
||||
`sl=<source>,<lat>,<lon>`; `show_in_gods_eye_view` accepts it, the globe panel
|
||||
applies it through the action, and a plain link runs the action once restored
|
||||
(one shot: the rewritten hash drops `sl`). In embed mode the rail holding the
|
||||
(one shot: the rewritten hash drops `sl`). A link pasted into the open tab
|
||||
runs it after its restore settles (`gev:share-navigation-restore-settled`),
|
||||
and a start link whose restore a newer one superseded never runs. In embed mode the rail holding the
|
||||
panel is hidden, so an open photo moves to an overlay on the globe
|
||||
(`sl-viewer-wrap-embed`) and back when it closes; Esc closes it (in full
|
||||
screen, Esc leaves full screen first). Image-loading failures render inside
|
||||
screen, Esc leaves full screen first). EXPAND stays open under embed mode's
|
||||
own clean view; cockpit, recording and scene playback hide the overlay. A
|
||||
posted view whose photo step fails closes the earlier photo before its
|
||||
camera flies. Image-loading failures render inside
|
||||
the embedded overlay, since the panel's error region is hidden with the rail.
|
||||
A caller's abort is
|
||||
honoured through the viewer's mount and load, not just the lookup, and only
|
||||
@@ -4529,8 +4543,9 @@ link never loads a photo from a source that bills every load
|
||||
(`billedPerImage` on the provider; Google): the action runs with
|
||||
`autoOpen: false`, arms the lookup on the layer (`armNearest`: the link's
|
||||
point and radius, consumed only by the next OPEN press (`aim:
|
||||
'screen-centre'`), and only while the view centre is within 1 km of the point
|
||||
(`ARMED_REACH_M`; a user who moved on opens what the view shows); any other lookup, open, close, disable, its source
|
||||
'screen-centre'`), and only while the ground under the screen centre is within
|
||||
1 km of the point (`ARMED_REACH_M`; a user who moved on opens what the view
|
||||
shows) or cannot be picked; a sky centre refuses; any other lookup, open, close, disable, its source
|
||||
switched off or its map leaving drops it), opens the panel and a toast
|
||||
points at OPEN GOOGLE STREET VIEW. Only the panel page's own link (inline
|
||||
embed) for a tool result issued in the last 5 minutes, and posted views, open
|
||||
|
||||
Reference in new issue
Block a user