Add loading spinner to ContactNotLoaded placeholder component#4044
Add loading spinner to ContactNotLoaded placeholder component#4044
Conversation
Co-authored-by: stephenhand <1694716+stephenhand@users.noreply.github.com>
stephenhand
left a comment
There was a problem hiding this comment.
Make the aria label translatable, defaulting to Loading contact in English. Use the three part standard for naming the translation key, {containing site section}-{component}-{specific text descriptor}
…ontactNotLoaded-Loading key Co-authored-by: stephenhand <1694716+stephenhand@users.noreply.github.com>
Done in 56dfbbd. Added the |
stephenhand
left a comment
There was a problem hiding this comment.
The spinner isn't centered vertically, perhaps the containing element needs to be expanded to fill its parent
…centered Co-authored-by: stephenhand <1694716+stephenhand@users.noreply.github.com>
Fixed in 7c372a2 — added |
stephenhand
left a comment
There was a problem hiding this comment.
Double the height wand double the width of the spinner
Co-authored-by: stephenhand <1694716+stephenhand@users.noreply.github.com>
Done in a8bb74a — added |
Adds a centered
CircularProgressspinner to theContactNotLoadedcomponent, which is displayed when a contact fails to load from HRM.Description
ContactNotLoaded.tsx: AddedCircularProgress(from@material-ui/core, consistent with existing usage across the codebase) absolutely positioned and centered within the component container:Boxgetsposition: relativeandheight: '100%'to fill its parent and act as positioning context, ensuring the spinner is vertically centered within the full component areaposition: absolute, full-coverage (top/left/right/bottom: 0), flex-centered,pointerEvents: noneso the Retry/Finish links remain fully interactive80px(size={80}) — double the default 40px — for improved visibilityaria-labeluses the translatable string keyTabbedForms-ContactNotLoaded-LoadingviagetTemplateStrings(), defaulting to "Loading contact" in EnglishTranslation files: Added the
TabbedForms-ContactNotLoaded-Loadingkey to all locale files that contain the full set of ContactNotLoaded strings (en,en-GB,es,fr,hu,pt,th)Checklist
Other Related Issues
None
Verification steps
Navigate to a task where the contact fails to load from HRM (or mock
unsavedContactas undefined inTaskView). TheContactNotLoadedcomponent should display with a large (80px) spinning circular progress indicator centered both horizontally and vertically over the full component area, while the "Retry" and "End Without Saving" links remain visible and clickable. Verify with a screen reader that the spinner is announced as the translated "Loading contact" label for the active locale.AFTER YOU MERGE
You are responsible for ensuring the above steps are completed. If you move a ticket into QA without advising what version to test, the QA team will assume the latest tag has the changes. If it does not, the following confusion is on you! :-P
Original prompt
🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.