queryStyledRootProperties method
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
## Motivation
The style editor in Studio uses the map to navigate to layers or components. It would be great if you could click on the map and use something like [`queryRenderedFeatures`](https://docs.mapbox.com/mapbox-gl-js/api/map/#map#queryrenderedfeatures) to find styled root properties (like atmosphere, fog, light)

## Design Alternatives
Workaround this by evaluating zoom/pitch/clicked coordinates/root properties set to condition whether to include root property navigation in the tooltip.
## Design
```js
// Return a collection of styled (or default styled) root properties found.
const rootProperties = map.queryStyledRootProperties();
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the existing queryRenderedFeatures API and the Studio style editor described in the issue. Determine how a map click currently reaches layer or component navigation, then define the returned collection for styled or default-styled root properties such as atmosphere, fog, and light. Done means the new queryStyledRootProperties API supports the map-click navigation use case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- api, frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100