Primary Field

Categories

Component ID

2674136

Component name

Primary Field

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Downloads

385

Component created

Component changed

Component body

This is a simple module that allows a site builder to set up a field group in a node type's display mode where only the first field (based on weight) that has content will render.

This can be useful as a 'primary media' group at the top of articles. Based on the example screenshot, if the gallery field is populated then it will render without any of the other fields. If the gallery field is empty but the video field is populated then the video field will render without any of the others. Finally, if the picture field is populated and both the gallery and video fields are empty then the picture field will render.