protected function ImageStyleDeleteForm::getReplacementOptions in Drupal 9
Same name and namespace in other branches
- 8 core/modules/image/src/Form/ImageStyleDeleteForm.php \Drupal\image\Form\ImageStyleDeleteForm::getReplacementOptions()
Returns a list of image style replacement options.
Return value
array An option list suitable for the form select '#options'.
2 calls to ImageStyleDeleteForm::getReplacementOptions()
- ImageStyleDeleteForm::form in core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php - Gets the actual form array to be built.
- ImageStyleDeleteForm::getDescription in core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php - Returns additional text to display as a description.
File
- core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php, line 79
Class
- ImageStyleDeleteForm
- Creates a form to delete an image style.
Namespace
Drupal\image\FormCode
protected function getReplacementOptions() {
if (!isset($this->replacementOptions)) {
$this->replacementOptions = array_diff_key(image_style_options(), [
$this
->getEntity()
->id() => '',
]);
}
return $this->replacementOptions;
}