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

feat: Conditional Input History - Form Builder #3859

Merged
merged 64 commits into from
Jul 19, 2024

Conversation

thiessenp-cds
Copy link
Contributor

@thiessenp-cds thiessenp-cds commented Jun 18, 2024

Summary | Résumé

Adds the conditional input history feature to the form-builder and Review page only. A followup PR will add this feature to Forms-forms submissions.

More Info:
Using the group history logic to allow a user to navigate the conditional logic in a form, update the user answers (form input) to only include answers that follow the users navigation.
For example, a user may go down conditional logic option A but then later go back and choose conditional logic option B, then follow the option B branch. So the questions answered on option A's branch should not be included in the form submission, only the answers from the option B branch.

Testing

Note: show/hide value filtering is applied on the form-builder only. So submitting a form will still have the previous functionality of including both visible and hidden values from any show/hide elements.

Ideally test creating a form with conditional logic in both the Form-Builder Preview. Try going down a few conditional logic branches and check if the answers you inputted match the "conditional input history" you navigated within the form.

Here is an example manual test that focusses on making sure the correct "history" of answers is on the Review page. The user chose the A conditional "branch", so only those answers should be in the form submission. Not the branching answers the user also answered from going down the B conditional and C conditional branches (though those answers remain in the form inputs for user convenience).

Screen.Recording.2024-06-27.at.11.21.51.AM.mov

Copy link
Contributor

@thiessenp-cds thiessenp-cds changed the title Conditional Input History (WIP) feat: Conditional Logic: Conditional Input History (WIP) Jun 19, 2024
@thiessenp-cds thiessenp-cds changed the title feat: Conditional Logic: Conditional Input History (WIP) feat: Conditional Logic: Conditional Input History Jun 25, 2024
@thiessenp-cds thiessenp-cds marked this pull request as ready for review June 25, 2024 19:12
@thiessenp-cds thiessenp-cds changed the title feat: Conditional Logic: Conditional Input History feat: Conditional Logic: Conditional Input History - Form Builder Jul 17, 2024
@thiessenp-cds thiessenp-cds changed the title feat: Conditional Logic: Conditional Input History - Form Builder feat: Conditional Input History - Form Builder Jul 17, 2024
@thiessenp-cds thiessenp-cds marked this pull request as ready for review July 17, 2024 19:53
lib/formContext.ts Outdated Show resolved Hide resolved
lib/formContext.ts Outdated Show resolved Hide resolved
@thiessenp-cds thiessenp-cds merged commit 5b6c525 into develop Jul 19, 2024
13 checks passed
@thiessenp-cds thiessenp-cds deleted the feat/conditional-input-history branch July 19, 2024 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants