getodk / getodk/web-forms

Question in a relevant repeat isn't displayed in edit if it wasn't relevant in the submission

Open
#904 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
38
Forks
22
PR merge metrics
No merged PRs in 30d

Description

### Observed Behaviour
It seems that the question in a relevant repeat isn't displayed in edits (if it wasn't relevant in the submission).
In the form (screenshot 1 below) the relevant repeat appears after selecting option 1.
The issue occurs in edit when in the submission the relevant question didn't appear (option 2 or 3 was selected).

1. The relevant repeat group in a **new submission (text question + add repeat button)**:

Image

2. The relevant repeat group in an **edit ( no text question, just the add repeat button)**:

Image

In Enketo in edits the question and add repeat button appear.

### Reproduction Steps

[relevant_repeat_group.xlsx.txt](https://github.com/user-attachments/files/31785768/relevant_repeat_group.xlsx.txt)

Steps:
1. Open and new submission in https://staging.getodk.cloud/projects/235/forms/repeat_group_relevant/submissions
2. Select option 2 and send the submission.
3. Go to the submissions table and edit the submission.
4. Select option 1 and check the relevant repeat text question.

### Screenshots or Videos

https://jam.dev/c/b0feb2e6-de40-49a6-b445-7acea4595941

### Environment

- Browser: Chrome, Firefox
- Web Forms version: 1.0.3

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the attached relevant_repeat_group.xlsx.txt and reproduce the edit flow at the staging submissions URL: submit with option 2, edit the submission, then select option 1. Trace the repeat group's relevance and rendering during editing; done means the text question and add-repeat control appear after selecting option 1, matching Enketo.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.