Currently, if you want to display the label for a field and it's value it's necessary to use more than one block.
The first would be a paragraph block containing the required label, the second the acf field block.
eg The labels are in the first column, the values in the second.
This is a bit cumbersome.
It would be nice to request the block to display the label as well as the value.
It would also be nice to be able to override the value of label.
Requirement
Extend the ACF field block to support the display of the field's label.
This option would only need to be applied to top level fields.
It would probably not be necessary for complex fields such as flexible content or repeater fields.
Proposed solution
Add a toggle to enable the field's label to be displayed
Add a text field to enable the field's label to be overridden
The generated HTML would change from
<div class="acf-field-field_64aa869f48df7 acf-type-text has-text-align- wp-block-acf-field-acf-field">Content for the Text field</div>
<div class="acf-field-field_64aa869f48df7 acf-type-text has-text-align- wp-block-acf-field-acf-field">
<div class="label">Text</div>
<div class="value">Content for the Text field</div>
</div>
Currently, if you want to display the label for a field and it's value it's necessary to use more than one block. The first would be a paragraph block containing the required label, the second the acf field block. eg The labels are in the first column, the values in the second.
This is a bit cumbersome. It would be nice to request the block to display the label as well as the value. It would also be nice to be able to override the value of label.
Requirement
Proposed solution
The generated HTML would change from
This could easily be styled as a grid.