protected function Dropdown::preprocessLinks in Open Social 8.9
Same name and namespace in other branches
- 8 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.2 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.3 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.4 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.5 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.6 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.7 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
- 8.8 themes/socialbase/src/Plugin/Preprocess/Dropdown.php \Drupal\socialbase\Plugin\Preprocess\Dropdown::preprocessLinks()
Function to preprocess the links.
Overrides BootstrapDropdown::preprocessLinks
1 call to Dropdown::preprocessLinks()
- DropdownActions::preprocessLinks in themes/
socialbase/ src/ Plugin/ Preprocess/ DropdownActions.php - Function to preprocess the links.
1 method overrides Dropdown::preprocessLinks()
- DropdownActions::preprocessLinks in themes/
socialbase/ src/ Plugin/ Preprocess/ DropdownActions.php - Function to preprocess the links.
File
- themes/
socialbase/ src/ Plugin/ Preprocess/ Dropdown.php, line 52
Class
- Dropdown
- Pre-processes variables for the "bootstrap_dropdown" theme hook.
Namespace
Drupal\socialbase\Plugin\PreprocessCode
protected function preprocessLinks(Variables $variables) {
parent::preprocessLinks($variables);
$operations = !!mb_strpos($variables->theme_hook_original, 'operations');
// Make operations button small, not smaller ;).
// Bootstrap basetheme override.
if ($operations) {
$variables->toggle['#attributes']['class'] = [
'btn-sm',
];
$variables['btn_context'] = 'operations';
$variables['alignment'] = 'right';
}
}