You are here

public function WebformUiElementDeleteForm::getDetails in Webform 6.x

Same name and namespace in other branches
  1. 8.5 modules/webform_ui/src/Form/WebformUiElementDeleteForm.php \Drupal\webform_ui\Form\WebformUiElementDeleteForm::getDetails()

Returns details to display.

Return value

array A renderable array containing details.

Overrides WebformDeleteFormBase::getDetails

File

modules/webform_ui/src/Form/WebformUiElementDeleteForm.php, line 144

Class

WebformUiElementDeleteForm
Webform for deleting a webform element.

Namespace

Drupal\webform_ui\Form

Code

public function getDetails() {
  $elements = $this
    ->getDeletedElementsItemList($this->element['#webform_children']);
  if ($elements) {
    return [
      '#type' => 'details',
      '#title' => $this
        ->t('Nested elements being deleted'),
      'elements' => $elements,
    ];
  }
  else {
    return [];
  }
}