Skip to content
Snippets Groups Projects
Commit 0f1a044e authored by Alex Pott's avatar Alex Pott
Browse files

Issue #2208585 by googletorp, quicksketch: Make #wrapper_attributes official and document it

parent 4c49e1e5
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
...@@ -403,15 +403,9 @@ function template_preprocess_form_element(&$variables) { ...@@ -403,15 +403,9 @@ function template_preprocess_form_element(&$variables) {
// \Drupal::formBuilder()->doBuildForm(). // \Drupal::formBuilder()->doBuildForm().
$element += array( $element += array(
'#title_display' => 'before', '#title_display' => 'before',
'#wrapper_attributes' => array(),
); );
$variables['attributes'] = $element['#wrapper_attributes'];
// Take over any #wrapper_attributes defined by the element.
// @todo Temporary hack for #type 'item'.
// @see http://drupal.org/node/1829202
$variables['attributes'] = array();
if (isset($element['#wrapper_attributes'])) {
$variables['attributes'] = $element['#wrapper_attributes'];
}
// Add element #id for #type 'item'. // Add element #id for #type 'item'.
if (isset($element['#markup']) && !empty($element['#id'])) { if (isset($element['#markup']) && !empty($element['#id'])) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment