- Issue created by @stefan.korn
- Merge request !79Issue #3476619: Allow for use of Bootstrap "Floating labels" on Drupal form elements → (Open) created by stefan.korn
- 🇩🇪Germany stefan.korn Jossgrund
Screenshot of regular textfield and textfield with floating label:
Screenshot of regular textfield and textfield with floating label in focus:
Code is
$form['text'] = [ '#type' => 'textfield', '#title' => 'Textfield', ]; $form['text_float'] = [ '#type' => 'textfield', '#title' => 'Textfield', '#attributes' => [ 'placeholder' => 'Password', 'floating_label' => 1 ] ];
- 🇩🇪Germany stefan.korn Jossgrund
This will possibly conflict with some other MRs I have created, because of using preprocess_form_element and preprocess_input in these MRs too. If acceptable the MRs would need to be processed on after another and need to be rerolled.