You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This code in localgov_subsites_paragraphs sets which heading levels are allowed for several paragraph types (like key facts).
function _localgov_subsites_paragraphs_create_heading(string$heading_text, string$heading_level) {
$allowed_heading_levels = ['h2', 'h3', 'h4', 'h5', 'h6'];
if (!in_array($heading_level, $allowed_heading_levels, TRUE)) {
return;
}
By default, h1 is not allowed in the field config.
BHCC has created a seperate paragraph for creating headings that re-uses the same field.
Since the page title could potentially be turned off in our theme, we allow the h1 to be set. This though means we have to allow the h1 everywhere (I think, it seems to apply the config everywhere).
This causes a side effect that when a keyfact accidently sets to a h1, the heading itself disappears.
Could we use the field config to set the allowed values here? And then we can find a way to allow for seperate allowed values in the different paragraphs.
The text was updated successfully, but these errors were encountered:
This code in localgov_subsites_paragraphs sets which heading levels are allowed for several paragraph types (like key facts).
By default, h1 is not allowed in the field config.
BHCC has created a seperate paragraph for creating headings that re-uses the same field.
Since the page title could potentially be turned off in our theme, we allow the h1 to be set. This though means we have to allow the h1 everywhere (I think, it seems to apply the config everywhere).
This causes a side effect that when a keyfact accidently sets to a h1, the heading itself disappears.
Could we use the field config to set the allowed values here? And then we can find a way to allow for seperate allowed values in the different paragraphs.
The text was updated successfully, but these errors were encountered: