Suddenly it was working in RC2 but not in 3.0 release.
Field type="email" is not rendered properly as it is missing in function _bootstrap_process_input (theme/process.inc). I would submit a patch, but structural endeavour: where to place it!
- it is HTML5 and not used by D7 core
- spotted it in webform module output, so we could create 'webform' section (as it is done for elements module), but pretty sure other modules might use that HTML5 compliant field as well (shall ther be 'HTML5' section)?
Something like this:
/**
* Process input elements.
*/
function _bootstrap_process_input(&$element, &$form_state) {
// Only add the "form-control" class for specific element input types.
$types = array(
// Core.
'password',
'password_confirm',
'select',
'textarea',
'textfield',
// HTML5.
'email',
// Elements module.
'emailfield',
'numberfield',
'rangefield',
'searchfield',
'telfield',
'urlfield',
);
if (!empty($element['#type']) && (in_array($element['#type'], $types) || ($element['#type'] === 'file' && empty($element['#managed_file'])))) {
$element['#attributes']['class'][] = 'form-control';
}
return $element;
}
Comments
Comment #1
betarobot commentedOh snap. Shame on me. That's exactly webform module issue. The affected field type is:
webform_emailComment #2
betarobot commentedComment #3
Michsk commentedworks.
Comment #4
wundo commentedCommitted ;)
Comment #5
wundo commentedComment #6
aeremeev commentedThank you!
Comment #8
raj45 commentedI just bumped into this problem, using Webform 7.x-4.2 and Bootstrap 7.x-3.0, and I can confirm that the patch works, and makes the e-mail-address field render correctly. So it seems like it hasn't been committed yet?
Comment #9
betarobot commentedIt was committed to 7.x-3.x-dev version. There was no full releases since then yet.
Comment #10
raj45 commentedI see, thanks for clarifying!
Comment #11
raj45 commentedActually, is it time to release again? Last release was a while ago, 2013-Nov-17.
Comment #12
heylookalive commented+1 for a stable release please :) really enjoying working with this theme by the way!
Comment #13
TheThemerist commentedSorry, I know this is a closed issue, but for those looking for a quick, valid work around without applying a patch or while waiting for it to be included in a stable release of Bootsatrap Theme, the following line in your theme's LESS files will solve it in the short term:
(Basically just using 'form-control' as a mixin, so that 'form-email' inherits all it styling properties.)
Comment #14
mesch commentedIn the same spirit of #13, another solution is to alter the form and add the class. I only had one such field in one form so this was a quick and easy solution.
Edit: Actually, this can be done via the UI via the component instance settings by adding a css class.
Comment #15
raj45 commentedThanks for sharing your very simple solution mesch! (#14)
To others: add
form-controlin theCSS Classesfield at the bottom of the e-mail-address component and all is well.Comment #16
simone960 commentedThanks @raj45 (#15). Simplest solution by just adding the class "form-control" to the field.