IS-10847 Finish the HaapiStepper renames in the props interface and README - #306
Open
aleixsuau wants to merge 1 commit into
Open
IS-10847 Finish the HaapiStepper renames in the props interface and README#306aleixsuau wants to merge 1 commit into
aleixsuau wants to merge 1 commit into
Conversation
aleixsuau
requested review from
luisgoncalves,
urre and
vahag-curity
and
a lite review from Copilot
August 26, 2026 12:58
…EADME. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Completes the HAAPI stepper rename cleanups and improves UX/accessibility by introducing a form-scoped “submitting” state so only the submitted form’s button shows a spinner and becomes disabled while its request is in flight.
Changes:
- Rename remaining stale “HaapiErrorNotifier” / “HaapiValidationErrorInputWrapper” references in docs and props typing.
- Add
isSubmittingto the form context and set it based on whether this form initiated the current stepperloadingtransition. - Show a submit-button spinner (with
aria-busy+ disabled) during submission, and updateSpinnerSVG to scale correctly at smaller sizes.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/haapi-react-sdk/haapi-stepper/ui/spinner/Spinner.tsx | Adds viewBox to allow SVG scaling for smaller spinner usage (e.g., in buttons). |
| src/haapi-react-sdk/haapi-stepper/README.md | Updates README examples/headings to renamed stepper utility component names. |
| src/haapi-react-sdk/haapi-stepper/feature/stepper/HaapiStepperErrorNotifier.tsx | Renames the props interface to match the component name. |
| src/haapi-react-sdk/haapi-stepper/feature/actions/form/HaapiStepperFormUI.tsx | Introduces form-scoped submit tracking and exposes isSubmitting via form context. |
| src/haapi-react-sdk/haapi-stepper/feature/actions/form/HaapiStepperFormSubmitButton.tsx | Renders spinner + sets aria-busy and disables the button while submitting. |
| src/haapi-react-sdk/haapi-stepper/feature/actions/form/HaapiStepperFormSubmitButton.spec.tsx | Adds tests for the form-scoped pending/spinner behavior. |
| src/haapi-react-sdk/haapi-stepper/feature/actions/form/HaapiStepperFormContext.ts | Extends the form context value with isSubmitting. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
22
to
26
| role="img" | ||
| aria-labelledby="svgTitle" | ||
| focusable="false" | ||
| viewBox={`0 0 ${SIZE} ${SIZE}`} | ||
| width={SIZE} |
Comment on lines
+196
to
+199
| // A step can render several forms, and `loading` is shared by the whole stepper. Gating on a ref | ||
| // set by this form's own submit keeps the pending state on the form the user actually submitted. | ||
| // Reading the ref during render is safe here because only a `loading` change re-renders us, and | ||
| // the ref is always set before the request that flips it starts. |
Comment on lines
+264
to
+268
| const { ui, action } = renderFormInStepper(false); | ||
| const { rerender } = render(ui); | ||
|
|
||
| await userEvent.click(screen.getByTestId(submitButtonTestId)); | ||
| rerender( |
Comment on lines
51
to
54
| {isSubmitting ? ( | ||
| <span className="icon" data-testid="form-submit-button-spinner"> | ||
| <Spinner width={16} height={16} /> | ||
| </span> |
aleixsuau
force-pushed
the
fix/dev/IS-10847-stepper-renames-and-submit-spinner
branch
from
August 26, 2026 13:04
c39849a to
00299fa
Compare
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.
Jira: https://curity.atlassian.net/browse/IS-10847
Purpose and context
Two components were renamed a while ago, but the rename stopped at the component names. The props interface and the README kept the old ones, so anyone reading the docs still saw
<HaapiErrorNotifier>, which no longer exists.This PR finishes that rename. It is documentation and a type name only. No behaviour changes.