You are here

public function WebformUiElementDeleteForm::getDetails in Webform 8.5

Same name and namespace in other branches
  1. 6.x 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 163

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 [];
  }
}