- Issue created by @johnv
When the 'Default' formatter is selected, the title of the field is not aligned according to the 'Form Display' settings.
Thisis because the function sets ['#label_display'] hardcoded.
- select 'Default' in 'Form display' with 'in line' label.
- display a node, the field label is not according to the settings.
Let the function not set the ['#label_display'], but set it afterwards if needed.
Core code will merge the hardcoded values with configured codes, but will not overwrite the hardcoded values.
In some cases, you need to set the title_display afterwards:
$widget = workflow_state_formatter($entity, $field_name);
$widget['#label_display'] = 'before'; // 'above', 'hidden'.
Active
1.8
User interface