function ThemeHooks::messagePlaceholder
Same name and namespace in other branches
- 11.x core/themes/admin/src/Hook/ThemeHooks.php \Drupal\admin\Hook\ThemeHooks::messagePlaceholder()
Prerender callback for status_messages placeholder.
Parameters
array $element: A renderable array.
Return value
array The updated renderable array containing the placeholder.
File
-
core/
themes/ admin/ src/ Hook/ ThemeHooks.php, line 446
Class
- ThemeHooks
- Provides theme related hook implementations.
Namespace
Drupal\admin\HookCode
public static function messagePlaceholder(array $element) : array {
if (isset($element['fallback']['#markup'])) {
$element['fallback']['#markup'] = '<div data-drupal-messages-fallback class="hidden messages-list"></div>';
}
return $element;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.