Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SelectField option_widget argument not used #381

Open
nathan-steyer opened this issue Apr 10, 2018 · 2 comments
Open

SelectField option_widget argument not used #381

nathan-steyer opened this issue Apr 10, 2018 · 2 comments
Labels
bug Unexpected behavior

Comments

@nathan-steyer
Copy link

nathan-steyer commented Apr 10, 2018

The option_widget parameter to SelectField is not used by the built-in Select widget to render the choices as option elements. It appears to use its render_option class method regardless.

@ftm ftm added the bug Unexpected behavior label Jun 13, 2018
@ftm
Copy link
Contributor

ftm commented Jun 13, 2018

If nothing uses it, I think the option_widget parameter should be removed as unless I'm mistaken there's nothing else you can use other than <option> which is the default.

@davidism
Copy link
Member

It's definitely used elsewhere. See RadioField for an example:

class RadioField(SelectField):
    widget = widgets.ListWidget(prefix_label=False)
    option_widget = widgets.RadioInput()

SelectField could use some cleanup, it's a bit circuitous right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected behavior
Development

No branches or pull requests

3 participants