Skip to content
Snippets Groups Projects
Commit 742d7ae1 authored by Kevin Paxman's avatar Kevin Paxman
Browse files

ISTWCMS-5880: only load styles from the default group, which contains the...

ISTWCMS-5880: only load styles from the default group, which contains the section widths - needed for when other section styles ship
parent 4de9165e
No related branches found
No related tags found
3 merge requests!284Feature/istwcms 5880 ebremner banners above,!274Draft: ISTWCMS-5551: fixing office hours display,!260Feature/istwcms 5668 a5kulkar rename references to publications
...@@ -604,13 +604,17 @@ function _uw_cfg_common_get_layout_builder_styles( ...@@ -604,13 +604,17 @@ function _uw_cfg_common_get_layout_builder_styles(
// Get all the styles for sections. // Get all the styles for sections.
$all_styles = _layout_builder_styles_retrieve_by_type('section'); $all_styles = _layout_builder_styles_retrieve_by_type('section');
// Array of options. // Array of options.
$options = []; $options = [];
// Step through each style and get the info. // Step through each style and get the info.
foreach ($all_styles as $style) { foreach ($all_styles as $style) {
$options[$style->id()] = $style->label(); // Only load styles from the "default" group,
// which contains the section widths.
// Needed for when other section styles ship.
if ($style->getGroup() == 'default') {
$options[$style->id()] = $style->label();
}
} }
return $options; return $options;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment