' . t('About') . ''; $output .= '

' . t('Add Bootstrap Grid support to Layout Builder module. currently, work for both Bootstrap 3 and Bootstrap 4.') . '

'; return $output; default: } } /** * Implements hook_theme(). */ function bootstrap_layout_builder_theme() { return [ 'blb_container_wrapper' => [ 'variables' => [ 'attributes' => [], 'children' => [], ], ], 'blb_container' => [ 'variables' => [ 'attributes' => [], 'children' => [], ], ], 'blb_section' => [ 'template' => 'blb-section', 'render element' => 'content', 'base hook' => 'layout', ], ]; } /** * Implements hook_preprocess_HOOK(). */ function bootstrap_layout_builder_preprocess_blb_section(&$variables) { foreach (Element::children($variables['content']) as $name) { if (!isset($variables['content'][$name]['#attributes'])) { $variables['content'][$name]['#attributes'] = []; } $variables['region_attributes'][$name] = new Attribute($variables['content'][$name]['#attributes']); } }