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

Fixed #34034 -- Allow setting HTML attributes on Select widget options. #18146

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

marianaasilva
Copy link
Contributor

Trac ticket number

Related to ticket-34034

Branch description

Picks up on @khink's previous work to add the option_attrs parameter for widgets inheriting from ChoiceWidget.
I've updated the ChoiceWidget.__deepcopy__ method and the test for it ChoiceWidgetTest.test_deepcopy and added a test for RadioSelect RadioSelectTest.test_constructor_option_attrs to ensure that option_attrs takes precedence.

Checklist

  • This PR targets the main branch.
  • The commit message is written in past tense, mentions the ticket number, and ends with a period.
  • I have checked the "Has patch" ticket flag in the Trac system.
  • I have added or updated relevant tests.
  • I have added or updated relevant docs, including release notes if applicable.
  • I have attached screenshots in both light and dark modes for any UI changes.

khink and others added 2 commits June 23, 2023 15:52
- Added tests for the Select widget, applied patch supplied by nessita
- Set option_attrs on AutocompleteMixin so create_option doesn't need to check if the instance has an option_attrs attribute
@marianaasilva marianaasilva changed the title Fixed #34034 -- Allow setting HTML attributes on Select widget options Fixed #34034 -- Allow setting HTML attributes on Select widget options. May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants