ideas icon indicating copy to clipboard operation
ideas copied to clipboard

Make labels of array field type available in templates

Open klickreflex opened this issue 2 years ago • 0 comments

It is impossible to render the labels defined on a keyed array field in templates.

Assume the following field:

handle: stakeholders
  field:
    mode: keyed
    keys:
      visualisierung: Visualisierung
      freiflaechenplanung: Freiflächenplanung

We can iterate over keys and values in antlers:

{{ foreach:stakeholders }}
  {{ key }}
  {{ value }}
{{ /foreach:stakeholders }}

However, there is no way to render the label in templates (e.g. showing the labels Visualisierung and Freiflächenplanung instead of the keys visualisierung and value.

klickreflex avatar Jul 12 '22 14:07 klickreflex