ConfirmFormModal.php in Open Social 8.4
Same filename and directory in other branches
- 8.9 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.2 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.3 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.5 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.6 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.7 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
- 8.8 themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.php
Namespace
Drupal\socialbase\Plugin\PreprocessFile
themes/socialbase/src/Plugin/Preprocess/ConfirmFormModal.phpView source
<?php
namespace Drupal\socialbase\Plugin\Preprocess;
use Drupal\bootstrap\Plugin\Preprocess\PreprocessBase;
/**
* Pre-processes variables for the "confirm_form__modal" theme hook.
*
* @ingroup plugins_preprocess
*
* @BootstrapPreprocess("confirm_form__modal")
*/
class ConfirmFormModal extends PreprocessBase {
/**
* {@inheritdoc}
*/
public function preprocess(array &$variables, $hook, array $info) {
parent::preprocess($variables, $hook, $info);
$form =& $variables['form'];
$variables['title'] = $form['#title'];
$form['actions']['cancel']['#attributes']['class'] = [
'dialog-cancel',
'btn',
'btn-default',
'pull-left',
];
}
}
Classes
Name![]() |
Description |
---|---|
ConfirmFormModal | Pre-processes variables for the "confirm_form__modal" theme hook. |