mapbox / mapbox/mapbox-gl-js

Style spec: represent default `center` and `parallels` values for conic projections

Open
#11,189 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

needs discussion :speech_balloon:
Dominant language
TypeScript
Stars
12.4k
Forks
2.4k
PR merge metrics
No merged PRs in 30d

Description

## Motivation

Conic projections ([Albers](https://github.com/mapbox/mapbox-gl-js/blob/main/src/geo/projection/albers.js#L10-L11) and [Lambert](https://github.com/mapbox/mapbox-gl-js/blob/main/src/geo/projection/lambert.js#L16-L17)) are initialized with default values for `center` and `parallels`, but these values aren't recorded in the [spec](https://github.com/mapbox/mapbox-gl-js/blob/main/src/style-spec/reference/v8.json#L4005-L4055).

Since these defaults are different depending on the projection's `name`, how might we represent dependent defaults in the spec?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the default center and parallels in src/geo/projection/albers.js and src/geo/projection/lambert.js with the projection definitions in style-spec/reference/v8.json. Determine how the spec can represent defaults that depend on the projection name. Done means the dependent defaults are defined consistently in the spec without losing the existing projection behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.