From 2f170fbbd80880bd75e97f88167e1c54f4196be1 Mon Sep 17 00:00:00 2001 From: Andrea Mennillo Date: Wed, 21 Feb 2024 16:25:54 +0100 Subject: [PATCH] Improve poi shop style (#1634) The main goal is to improve consistency and reduce the number of poi without an icon. - Remove music from poi cultural, music has only two subclasses music and musical_instrument, both are styled as poi shop - Remove arts_centre from poi shop, it's already styled as poi cultural - Remove chocolate icon, chocolate uses confectionery icon (see: https://github.com/openmaptiles/openmaptiles/pull/1628) - Remove references to ice_cream class from poi shop - Add missing gallery icon and move it to poi cultural (see: https://wiki.openstreetmap.org/wiki/Tag:tourism%3Dgallery) - Use the icons alcohol, newsagent, perfumery, trade respectively for wine, kiosk, perfume and wholesale. - Add a generic fallback icon for shops --- layers/poi/style.json | 59 +++++++++++----------- style/icons/chocolate.svg | 60 ----------------------- style/icons/gallery.svg | 10 ++++ style/icons/{frozen_food.svg => shop.svg} | 0 style/icons/tattoo.svg | 59 ---------------------- style/icons/watches.svg | 59 ---------------------- 6 files changed, 39 insertions(+), 208 deletions(-) delete mode 100644 style/icons/chocolate.svg create mode 100644 style/icons/gallery.svg rename style/icons/{frozen_food.svg => shop.svg} (100%) delete mode 100644 style/icons/tattoo.svg delete mode 100644 style/icons/watches.svg diff --git a/layers/poi/style.json b/layers/poi/style.json index ad246b5f..546f2089 100644 --- a/layers/poi/style.json +++ b/layers/poi/style.json @@ -23,11 +23,29 @@ ] }, "icon-image": [ - "match", - ["get", "subclass"], - "chocolate", - "confectionery", - ["get", "subclass"] + "coalesce", + [ + "image", + [ + "match", + ["get", "subclass"], + "chocolate", + "confectionery", + "wine", + "alcohol", + "kiosk", + "newsagent", + "perfume", + "perfumery", + "wholesale", + "trade", + ["get", "subclass"] + ] + ], + [ + "image", + "shop" + ] ], "text-field": "{name:latin}\n{name:nonlatin}", "visibility": "visible", @@ -41,16 +59,7 @@ "icon-allow-overlap": true }, "paint": { - "text-color": [ - "match", - [ - "get", - "class" - ], - "ice_cream", - "#C77400", - "#939" - ], + "text-color": "#939", "icon-opacity": 1, "icon-halo-blur": 1, "text-halo-blur": 0.5, @@ -78,7 +87,9 @@ "subclass", "mall", "library", - "artwork" + "artwork", + "arts_centre", + "gallery" ] ], "order": 155 @@ -124,16 +135,7 @@ "icon-allow-overlap": true }, "paint": { - "text-color": [ - "match", - [ - "get", - "class" - ], - "ice_cream", - "#C77400", - "#939" - ], + "text-color": "#939", "icon-opacity": 1, "icon-halo-blur": 1, "text-halo-blur": 0.5, @@ -873,7 +875,6 @@ "class", "cinema", "library", - "music", "museum", "castle", "monument", @@ -883,9 +884,7 @@ "!in", "subclass", "books", - "musical_instrument", - "art", - "gallery" + "art" ] ], "order": 168 diff --git a/style/icons/chocolate.svg b/style/icons/chocolate.svg deleted file mode 100644 index ab55f153..00000000 --- a/style/icons/chocolate.svg +++ /dev/null @@ -1,60 +0,0 @@ - - - - - - image/svg+xml - - - - - - - - - diff --git a/style/icons/gallery.svg b/style/icons/gallery.svg new file mode 100644 index 00000000..ef93c527 --- /dev/null +++ b/style/icons/gallery.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/style/icons/frozen_food.svg b/style/icons/shop.svg similarity index 100% rename from style/icons/frozen_food.svg rename to style/icons/shop.svg diff --git a/style/icons/tattoo.svg b/style/icons/tattoo.svg deleted file mode 100644 index d29e518e..00000000 --- a/style/icons/tattoo.svg +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - image/svg+xml - - - - - - - - - diff --git a/style/icons/watches.svg b/style/icons/watches.svg deleted file mode 100644 index df654b43..00000000 --- a/style/icons/watches.svg +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - image/svg+xml - - - - - - - - -