LG-5213: IAL2 document capture tips prior to submission#5534
Conversation
Allow greater control of placement of Continue button
To create different messaging based on failure attempt
**Why**: Because tracked only as failed attempts
make development less annoying
Include list wrapper
This reverts commit a143950.
…its own. Added focus anchor at the top of step content.
app/javascript/packages/document-capture/components/form-steps.jsx
Outdated
Show resolved
Hide resolved
app/javascript/packages/document-capture/components/form-steps.scss
Outdated
Show resolved
Hide resolved
app/javascript/packages/document-capture/components/review-issues-step.jsx
Outdated
Show resolved
Hide resolved
…test fixing to come.
…ought it would work but it doesn't.
Test behavior of successful reset, no multi-display
Not managed at top-level anymore, step-specific
Seems like this should've been failing already?
| const { | ||
| documentCaptureTipsUrl: documentCaptureTipsURL, | ||
| maxCaptureAttemptsBeforeTips, | ||
| appName, | ||
| } = /** @type {AppRootData} */ (appRoot.dataset); |
There was a problem hiding this comment.
Something to consider following-up on, since there's a lot of inconsistency with how we pull attributes from the root element. This was also sparked from discussion point at #5535 (comment) .
A few observations:
- Renaming properties from naive dataset auto-conversion (e.g.
documentCaptureTipsUrl->documentCaptureTipsURL) - Casting type from dataset string to target type (e.g.
Number(maxCaptureAttemptsBeforeTips))
I'm familiar with some related validation libraries (e.g. joi, JSON Schema implementations like ajv). On closer inspection, Ajv has a "type coercion" feature which could be quite nice 🤔 A shame it's a very large library.
Maybe we could do some minimal utility to pick / format / rename:
const {
documentCaptureTipsURL,
maxCaptureAttemptsBeforeTips,
appName,
} = pick(appRoot.dataset, {
documentCaptureTipsUrl: compose(renameTo('documentCaptureTipsURL'), castAs(Number)),
maxCaptureAttemptsBeforeTips: castAs(Number),
appName: identity,
});This reverts commit eadf947.
**Why**: Maintain as close to the current implementation as we can until further research and user testing can give us insight into optimal navigation experience.
There was a problem hiding this comment.
Reviewed sandbox (iOS, Chrome and Safari) and tested glare errors. The main issue is that the tips screen appears on the second error, not the third? Also noticed that the scroll position does not appear to reset which can obscure the icon/heading at the top - would make sense to reset it to the top, I think.
Visually, couple tiny things:
- A little more space before and after the Try Again button (
2.5 remtotal top/bottom) - Thanks for catching that the Try Again button should be full width on mobile, I actually had that wrong in my mockups but it's fixed now! Is the button the
bigorregularsize, though? (should bebig) - Remove Start Over and Cancel here
Lastly, I didn't check that this doesn't appear on desktop/manual upload or other scenarios outside of blur and glare, anything like that worth manually testing? Thanks!
|
Thanks @anniehirshman-gsa ! Most of this looks like it should be relatively straight-forward to fix up.
The intention is that the title of the warning screen should be focused, which should at least reset the scroll to bring that element into view, even if not to the very top. I'll check to make sure that's working. Though based on what you're suggesting, maybe it would be better to reset it to the top regardless?
Correct, we're only counting these attempts in response to photos submitted through the Acuant SDK, so neither desktop nor manual upload would be a factor. |
|
Great thanks! Re: scroll position, I think setting it to the very top is fine, but it at least should show the main content area in view (if the heading is the first thing in view, you miss the warning icon/design element). Glad to hear we're all set for desktop and manual testing... I'm assuming other front-end scenarios that are not blur and glare (like image size) are unaffected as well. In that case, with these changes should be all set 👍 |
Missed this question: It's |
|
I just pushed the following revisions: As discussed on Slack, I'm going to leave the following items for quick follow-on pull requests, since they're non-trivial and this pull request is already quite large and blocking other effort:
|
Follow-up from #5534 **Why**: Per design, the "Start Over" and "Cancel" links are not intended to be shown in the troubleshooting tips. Because this was rendered outside the React application, the approach to hiding them is to absorb the logic of the links into the React application, rendering them only where applicable.
* LG-5213: Hide "Start Over" and "Cancel" in capture tips Follow-up from #5534 **Why**: Per design, the "Start Over" and "Cancel" links are not intended to be shown in the troubleshooting tips. Because this was rendered outside the React application, the approach to hiding them is to absorb the logic of the links into the React application, rendering them only where applicable. * Add component description for ButtonTo Portal-ing is non-obvious * Import FlowPath type from document-capture #5553 (comment)
Why: As an end user, if I am attempting to take images of my ID with the Acuant SDK, I want to see messaging to help me troubleshoot if I try multiple times, so that I get additional help when I need it.
Implementation Notes:
FormStepsto allow steps more control over how content is presented, specifically being less opinionated about the placement of heading and submit buttons, while offering equivalent conveniences (e.g.FormStepsContinueButton).TroubleshootingOptionsandBlockLinkcomponents are mostly one-to-one ports of ERB_troubleshooting_options.html.erband_block_link.html.erb.Screenshot: