HSLdevcom / HSLdevcom/hsl-map-style

House letters (eg. the F in Löylytie 7 F) are shown inconsistently

Open
#189 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
14
Forks
10
Avg merge
1m
Merged PRs (30d)
2

Description

Reittiopas currently displays only the street house number on top of a building on the map if the value of the building's addr:housenumber field contains only the house number. It is common for housenumber to contain only that base number, while the staircase or building letter itself is stored in the addr:unit field.

It would be more practical if the staircase/building letter were also visible alongside the street number. For example, at the address Löylytie 7 A, "7" is displayed on top of both this building (A) and the adjacent buildings (B, C, D, etc.), whereas a better alternative would be for it to display "7 A".

For entrances tagged with an address, the number is already shown in Reittiopas in exactly this way; for example, on top of the entrance for Liittokuja 8 F19, Reittiopas displays "8F19". This functionality would be desirable for building polygons as well.

It would likely also be desirable for the house number not to appear on top of entrances if the house number (addr:housenumber) is already tagged on the building polygon to which the entrance is attached. In that case, for example, the entrances attached to the side of Saarniraiviontie 8 would not display "8A", "8B", etc., but rather "A", "B", since the house number 8 is already shown over the middle of the building.

Sometimes mappers tag the building letter on both the building polygon and its entrances, causing labels like "8B" to repeat multiple times in a small area. If an entrance's addr:unit and addr:housenumber are identical to the attached building polygon's addr:unit and addr:housenumber, it would be desirable not to display the address redundantly over the entrances.

Current rendering of the address on buildings with addr:housenumber=7 and addr:unit=A or B etc.:
Image

Desirable display (here addr:housenumber itself contains the letter):
Image

Entrance letter duplication:
Image

Contributor guide

No contributing guide indexed for this repository

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 locating the map-style rules that render address labels for building polygons and entrances; no specific files or tests are named in the issue. Trace how addr:housenumber and addr:unit are combined, then verify the requested Löylytie 7 A and Saarniraiviontie 8 cases in the map to confirm letters are shown and duplicate entrance labels are suppressed.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.