From a56b61ef28dfd06350ec3068b7b2c9b0d877c169 Mon Sep 17 00:00:00 2001 From: Quincy Morgan <2046746+quincylvania@users.noreply.github.com> Date: Fri, 10 Nov 2023 14:44:27 -0700 Subject: [PATCH] Add ranger station poi icon --- img/map/ranger_station.png | Bin 0 -> 983 bytes index.js | 10 +++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 img/map/ranger_station.png diff --git a/img/map/ranger_station.png b/img/map/ranger_station.png new file mode 100644 index 0000000000000000000000000000000000000000..69fd515368a884f6de8c153c431723b1af68fec4 GIT binary patch literal 983 zcmV;|11S87P)_16e-QLwFTIO5@fJZEAs+Np=tU|1q@mtC6l_Ef_E2bc zoVRt?bpNumnYugB2O+!f&CmDEd-L|^Edd{?5Pu z0~mY*U=2dyopw5V1t*@+TAE7$CNMX%!y1k{k6UM+QeiL zz?J_C-n7N?pU3<;?unnKCyYISF%OXVz&DLWD3<6gP^1IUIfHv5iMrhlD;NAy^RqRb z-$5mR($DN+V+q8}jTLI7%9vyu545go%#esZsRNxQJn2RyUY-i#8N5bOqO)RD;QODK zlrS~n6;@5**fHPZ?SZN?f>~(4?`@35vB$Jm>vWwLL7|ifKU%fjqM%@JFM~^ zI3VEW`a?rQ4z-)k(I|vMx(8Cj!|>?YQwJ2(p-r|(C2(YP6c%1Q2W@iFffIFT!!|NS z8i61H{RoC7C56EG;zc8Df`o_}V%SH9ByySTy?zF|G&cvg9zKBNz(C+(63HY?O;5wt z?=5Jpt_JSs)-W^yLMhBw@4&Si*Mab7QBlD@XQwW};ZzFVFE8_l!Em?qp$K3~tS&r( z;+0uZ+>Z9z!~`548-ta%@1V1@ z*a^BP>vbGvfdUce$Hl!s+wGzu+H(_!Nt1R^qUR!MmXx)EQ2vtiB<0CT^f@6=2zkyH z1B3J@vR*4F+k?t`;DA8X+WeYtO9v { if (error) throw error; map.addImage('trailhead-icon', image, { pixelRatio: 2 }); }); + map.loadImage('img/map/ranger_station.png', (error, image) => { + if (error) throw error; + map.addImage('ranger_station-icon', image, { pixelRatio: 2 }); + }); var impliedYesHighways = { foot: [ @@ -330,7 +334,11 @@ window.onload = (event) => { "source-layer": "trail_poi", "type": "symbol", "layout": { - "icon-image": ["image", "trailhead-icon"], + "icon-image": [ + "match", ["get", "highway"], + "trailhead", ["image", "trailhead-icon"], + ["image", "ranger_station-icon"] + ], "icon-size": [ "interpolate", ["linear"], ["zoom"], 12, 0.5,