From 86da3e382fd7674db9169d775a0dbcb0d701a4ba Mon Sep 17 00:00:00 2001 From: Charlie Plett Date: Fri, 31 Jul 2026 22:23:57 -0600 Subject: [PATCH 1/2] Added labels for address nodes and building_addresses and appended address to building names --- historical/historical.json | 63 +++++++++++++++++++++++++++++++++++++- 1 file changed, 62 insertions(+), 1 deletion(-) diff --git a/historical/historical.json b/historical/historical.json index 23ce22ec..4c719634 100644 --- a/historical/historical.json +++ b/historical/historical.json @@ -6162,6 +6162,56 @@ "text-opacity": ["interpolate", ["linear"], ["zoom"], 13.99, 0, 14, 1] } }, + { + "id": "address_points_labels", + "type": "symbol", + "source": "ohm", + "source-layer": "address_points", + "minzoom": 16, + "filter": ["has", "addr_housenumber"], + "layout": { + "text-field": ["get", "addr_housenumber"], + "text-size": ["interpolate", ["linear"], ["zoom"], 16, 8, 17, 9, 20, 10], + "text-anchor": "top", + "text-offset": [0, 1], + "text-font": ["OpenHistorical"], + "visibility": "visible" + }, + "paint": { + "text-color": "rgba(80, 80, 80, 1)", + "text-halo-color": "rgba(255, 255, 255, 1)", + "text-halo-width": 1, + "text-halo-blur": 0.5, + "text-opacity": ["interpolate", ["linear"], ["zoom"], 16.99, 0, 17, 1] + } + }, + { + "id": "buildings_address_labels", + "type": "symbol", + "source": "ohm", + "source-layer": "buildings", + "minzoom": 16, + "filter": [ + "all", + ["has", "addr_housenumber"], + ["any", ["!", ["has", "name"]], ["==", ["get", "name"], ""]] + ], + "layout": { + "text-field": ["get", "addr_housenumber"], + "text-size": ["interpolate", ["linear"], ["zoom"], 16, 8, 17, 9, 20, 10], + "text-anchor": "top", + "text-offset": [0, 1], + "text-font": ["OpenHistorical"], + "visibility": "visible" + }, + "paint": { + "text-color": "rgba(80, 80, 80, 1)", + "text-halo-color": "rgba(255, 255, 255, 1)", + "text-halo-width": 1, + "text-halo-blur": 0.5, + "text-opacity": ["interpolate", ["linear"], ["zoom"], 16.99, 0, 17, 1] + } + }, { "id": "points_of_interest_buildings", "type": "symbol", @@ -6172,7 +6222,18 @@ "layout": { "icon-image": "{tourism}-18", "visibility": "visible", - "text-field": ["get", "name"], + "text-field": [ + "case", + ["all", ["has", "name"], ["has", "addr_housenumber"]], + [ + "concat", + ["get", "name"], + " (", + ["get", "addr_housenumber"], + ")" + ], + ["get", "name"] + ], "text-size": ["interpolate", ["linear"], ["zoom"], 16, 12, 17, 14, 20, 16], "text-anchor": "center", "text-offset": [0, 0], From 280ee97fc2120a87d30b52a7a522a3055eb15bbd Mon Sep 17 00:00:00 2001 From: Charlie Plett Date: Thu, 6 Aug 2026 12:42:06 -0600 Subject: [PATCH 2/2] moved address below the name and set them to same font size as other addresses --- historical/historical.json | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/historical/historical.json b/historical/historical.json index 4c719634..c123d0e1 100644 --- a/historical/historical.json +++ b/historical/historical.json @@ -6223,16 +6223,24 @@ "icon-image": "{tourism}-18", "visibility": "visible", "text-field": [ - "case", - ["all", ["has", "name"], ["has", "addr_housenumber"]], + "step", + ["zoom"], + ["get", "name"], + 17, [ - "concat", - ["get", "name"], - " (", - ["get", "addr_housenumber"], - ")" - ], - ["get", "name"] + "case", + ["all", ["has", "name"], ["has", "addr_housenumber"]], + [ + "format", + ["get", "name"], + {}, + "\n", + {}, + ["get", "addr_housenumber"], + {"font-scale": 0.65} + ], + ["get", "name"] + ] ], "text-size": ["interpolate", ["linear"], ["zoom"], 16, 12, 17, 14, 20, 16], "text-anchor": "center",