Repository navigation
Add a configurable Next steps screener component - #576
Draft
prestoncabe wants to merge 14 commits into
Draft
prestoncabe wants to merge 14 commits into
prestoncabe wants to merge 14 commits into
Conversation
A leftover document from a failed delete made create() throw ALREADY_EXISTS partway through publishing, leaving the published screener with only some of its benefits. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Saving rebuilt the editor's benefit, so the keyed Show remounted it mid-save: the saved status never appeared and focus was lost. Remount only for another benefit or a reset. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Switching benefits, resetting, closing or pressing Escape in the next steps modal silently dropped edits that hadn't been saved. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A Next steps field hidden by a condition still suppressed the page's completion message, so respondents saw no completion signal. Fields now report whether they are rendered, and the page drops its message only while one is. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replacing the page's role="status" completion message with a plain heading meant screen readers no longer heard that screening was complete. Keep a live region in the field that announces it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The properties panel checked component content against the benefits that loaded, so a benefit whose fetch failed was never flagged even though the content modal reported it. Check against the screener's benefits instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Links other than http(s) lost their href, so mailto: and tel: links analysts wrote showed as plain text. They now stay clickable without opening a new tab. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The canvas and Save waited for one request per benefit on every visit to the Form Editor, and any benefit change refetched them all. Load content in the background, fetch each benefit once, and fill Next steps components added before it arrived. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The viewer's webLink re-implemented the editor's http(s) check and had drifted: it skipped the hostname rules, so it showed links the editor would refuse to save. Move normalizeHttpUrl to a shared util and build webLink on it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Switch shows its Saving branch first, so isSaving() is always false in the other two branches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Now that the editor stays mounted through a save, its "Next steps saved." status appeared next to the modal's own. Keep the modal's message, which says the form still needs saving. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Screeners can now include a Next steps form component. It shows application instructions and contacts for eligible benefits, unmet requirements and an analyst note for ineligible benefits, and the benefits that still need more information. Analysts can show decisions as they arrive or wait until every benefit is decided.
Closes #556. Fourth PR for #552, following #574. Print summary and AI draft integration follow in #557 and #558.
The component copies benefit content into its own schema configuration on insertion. A modal lets analysts edit that screener's copy or reset an individual benefit from its source. Missing copies are flagged, removed benefits are ignored, and importing a schema preserves its saved content. Publishing uses the existing form-schema snapshot; public viewers do not fetch working benefit content.
Publishing preserves benefit IDs in the published subcollection so evaluation results match the schema's copied content. Screener transfers and example imports remap those content keys when allocating new benefit IDs, preserving analyst edits.
Markdown is sanitized without template evaluation, web links open in a new tab, and pending or failed evaluations suppress stale instructions. Forms with this component use its progress heading. Existing forms without it retain the legacy completion message, so previously published screeners keep their behavior.
Validation:
git diff --checkpassed; branch rebased onto currentmain.