Skip to content

Change the case of labels

Use the upcase and downcase expressions to change the case of labels.

---
title: Change the case of labels
type: geojson
description: Use the upcase and downcase expressions to change the case of labels.
options:
  center: [-116.231, 43.604]
  zoom: 11
style:
  extends: https://styles.trailsta.sh/osm-liberty.json
  layers:
    - type: symbol
      icon-image: maki:dog-park
      icon-size: 0.3666
      text-field:
         - format
         - [upcase, [get, FacilityName]]
         - {font-scale: 0.8}
         - "\n"
         - {}
         - [downcase, [get, Comments]]
         - {font-scale: 0.6}
      text-font: [Open Sans Semibold]
      text-offset: [0, 0.6]
      text-anchor: top
---
https://maplibre.org/maplibre-gl-js/docs/assets/boise.geojson


View Map on Ultra
Edit Query on Ultra
View MapLibre Example