Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions client/src/pages/Survey/utils/survey.json
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@
},
{
"type": "text",
"name": "non_family_network_size",
"name": "network_size_agg",
"title": "Other than any family living with you, how many people do you closely know who are also unhoused or experiencing homelessness today?",
"validators": [
{
Expand All @@ -295,6 +295,18 @@
}
]
},
{
"name": "network_size_bridge",
"title": "Network Module",
"elements": [
{
"type": "expression",
"name": "network_size_list",
"visible": false,
"expression": "{network_size_agg}"
Comment on lines +303 to +306
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

network_size_list is implemented as an expression question (expression: "{network_size_agg}"). Expression questions continuously recompute their value from the expression, which can overwrite updates coming from the paneldynamic bindings.panelCount when panels are added/removed. To make this a true β€œseed then mutate” bridge, use a value that is only initialized from network_size_agg (e.g., a hidden question with a defaultValue/defaultValueExpression) rather than a continuously calculated expression.

Suggested change
"type": "expression",
"name": "network_size_list",
"visible": false,
"expression": "{network_size_agg}"
"type": "text",
"name": "network_size_list",
"visible": false,
"readOnly": true,
"defaultValueExpression": "{network_size_agg}"

Copilot uses AI. Check for mistakes.
}
]
},
Comment on lines +298 to +309
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

network_size_bridge is added as a new page between network_questions_p1 and network_questions_p2, but it has no visible elements. This will insert an extra blank step in the survey flow. Consider moving network_size_list into an existing page (e.g., network_questions_p2) as a hidden element, or mark this page itself as not visible so it doesn’t appear in navigation.

Copilot uses AI. Check for mistakes.
{
"name": "network_questions_p2",
"title": "Network Module",
Expand All @@ -306,10 +318,10 @@
},
{
"type": "paneldynamic",
"name": "non_family_network",
"title": "For those {non_family_network_size} people, please fill in as much of the following information as you are able:\n",
"name": "network_list",
"title": "For those {network_size_agg} people, please fill in as much of the following information as you are able:\n",
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The panel title interpolates {network_size_agg}, but the actual panel count is bound to network_size_list. If the interviewer adds/removes panels, the title can become inaccurate. Consider referencing the bound count variable (or another value that tracks the current panel count) so the UI stays consistent with the data being collected.

Suggested change
"title": "For those {network_size_agg} people, please fill in as much of the following information as you are able:\n",
"title": "For those {network_size_list} people, please fill in as much of the following information as you are able:\n",

Copilot uses AI. Check for mistakes.
"bindings": {
"panelCount": "non_family_network"
"panelCount": "network_size_list"
},
"templateElements": [
{
Expand Down
Loading