public function ContextualLinks::preRender in Drupal 10
Same name and namespace in other branches
- 8 core/modules/contextual/src/Plugin/views/field/ContextualLinks.php \Drupal\contextual\Plugin\views\field\ContextualLinks::preRender()
- 9 core/modules/contextual/src/Plugin/views/field/ContextualLinks.php \Drupal\contextual\Plugin\views\field\ContextualLinks::preRender()
File
- core/
modules/ contextual/ src/ Plugin/ views/ field/ ContextualLinks.php, line 73
Class
- ContextualLinks
- Provides a handler that adds contextual links.
Namespace
Drupal\contextual\Plugin\views\fieldCode
public function preRender(&$values) {
// Add a row plugin css class for the contextual link.
$class = 'contextual-region';
if (!empty($this->view->style_plugin->options['row_class'])) {
$this->view->style_plugin->options['row_class'] .= " {$class}";
}
else {
$this->view->style_plugin->options['row_class'] = $class;
}
}