Codelists
Codelists allow to map property values to a different value. This is useful especially for HTML representations.
Configuration
The following table describes the structure of the code list files.
| Name | Default | Description | Type | Since | 
|---|---|---|---|---|
label | id | Human readable label.  | string  | v2.0  | 
description | null | A description of the codelist.  | string  | v4.3  | 
entries | {} | Map with the original value as key and the new value as value.  | object  | v2.0  | 
sourceType | TEMPLATES | Always  TEMPLATES. | string  | v2.0  | 
fallback | the value | Optional default value.  | string  | v2.0  | 
For the target values in entries and for fallback also stringFormat transformations can be used. If the transformed value is intended for HTML output, then Markdown markup can also be used, this will be formatted in the HTML output.
Example
Based on the INSPIRE codelist EnvironmentalDomain, maps values like soil to the German label of the entry in the INSPIRE codelist registry.
---
label: Umweltbereich, für den Umweltziele festgelegt werden können.
entries:
  air: Luft
  climateAndClimateChange: Klima und Klimawandel
  healthProtection: Gesundheitsschutz
  landUse: Bodennutzung
  naturalResources: natürliche Ressourcen
  natureAndBiodiversity: Natur und biologische Vielfalt
  noise: Lärm
  soil: Boden
  sustainableDevelopment: nachhaltige Entwicklung
  waste: Abfall
  water: Wasser
Storage
Codelists reside in the Store as values with type codelists.
Codelists have a path instead of an id. That means for example values/codelists/bar.yml would be referenced as bar, but you could additionally define values/codelists/foo/bar.yml. To reference that codelist somewhere else in the configuration you would need to use foo/bar.