Is there a way to control the width of wtf.form_field input fields without affecting the label width?
This worked for me
jinja2 template:
<div style="width: 50%">
{{ form1.language.label }}
</div>
<div style="width: 25%">
{{ form1.language }}
</div>
This is the form1 class:
class myForm(Form):
language = SelectField(u'Programming Language', choices=[('cpp', 'C++'), ('py', 'Python'), ('text', 'Plain Text')])
This should work too and it also maintain the visual consistency with other fields' widths:
<div>{{ wtf.form_field(form.blockingProbability, horizontal_columns=('lg', 2, 4)) }}</div>
The last value - 4
- in horizontal_columns
sets the width of the input field.