Skip to content

Conversation

@rileyseaburg
Copy link
Contributor

This pull request introduces a new form type, a11_v2_radio, which uses radio buttons for feedback and includes associated validations, UI updates, and tests. The changes ensure the new form type integrates seamlessly with the existing system while maintaining functionality and user experience.

New Form Type: a11_v2_radio

  • Added a new form type, a11_v2_radio, to the list of supported form kinds, with specific rules and validations for its structure and content. (app/models/form.rb, spec/models/form_spec.rb) [1] [2]
  • Implemented the ensure_a11_v2_radio_format method to validate that the form includes required questions and options, such as a radio button question with values 1-5 and specific positive/negative indicators. (app/models/form.rb)

UI and Behavior Enhancements

  • Created a new script to dynamically show or hide questions based on user input for the a11_v2_radio form type. (app/views/components/_form_a11_v2_radio_script.html.erb)
  • Updated the radio button question type to ensure proper rendering and alignment with the new form type requirements. (app/views/components/forms/question_types/_radio_buttons.html.erb)

Testing and Factories

  • Added a factory trait for a11_v2_radio to streamline test creation, including predefined questions and options. (spec/factories/form.rb) [1] [2]
  • Introduced feature tests to verify the behavior of the a11_v2_radio form type, including dynamic question visibility and successful submission. (spec/features/touchpoints_spec.rb)

Miscellaneous Updates

  • Updated the widget script to include support for the a11_v2_radio form type. (app/views/components/widget/_fba.js.erb)
  • Enhanced the find_inactive_forms_since method to exclude templates when querying published forms. (app/models/form.rb)

ryanwoldatwork and others added 11 commits May 2, 2025 10:57
first 3 show "what could have gone better"
last 2 show "what went well"
Bumps [rack-session](https://github.com/rack/rack-session) from 2.1.0 to 2.1.1.
- [Release notes](https://github.com/rack/rack-session/releases)
- [Changelog](https://github.com/rack/rack-session/blob/v2.1.1/releases.md)
- [Commits](rack/rack-session@v2.1.0...v2.1.1)

---
updated-dependencies:
- dependency-name: rack-session
  dependency-version: 2.1.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
A-11 v2 with Radio Buttons (5 options, conditional 2nd & 3rd question)
@rileyseaburg rileyseaburg self-assigned this May 21, 2025
@rileyseaburg rileyseaburg added the accessibility issues reporting accessibility errors label May 21, 2025
@rileyseaburg rileyseaburg merged commit 4c58b74 into production May 21, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

accessibility issues reporting accessibility errors

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants