I've set the widget on the MultipleChoiceField with:
self.fields['field_1'] = forms.MultipleChoiceField(
choices=[(c.name, str(c)) for c in customers],
widget=forms.CheckboxSelectMultiple()
)
This ultimately spits out some html where each choice in choices gets an <input> in a <label> in an <li> in a <ul>.
I'd like to set a class on every <li>. I need to remove the bullet point set next to each <li>, change the font size, maybe even style the checkbox. Achievable with CSS selectors, but that strikes me as a code smell.
How can I do that? Thanks!
widget=forms.SelectMultiple(attrs={'class': 'yourclassname multi-select'}I think this will add a class as in
then add css to that class name as, and to remove bullet point you have to just add this
Thanks! Hope it helps.