Skip to content

Fix component previews#2636

Open
lfdebrux wants to merge 2 commits intomainfrom
ldeb-fix-view-component-previews
Open

Fix component previews#2636
lfdebrux wants to merge 2 commits intomainfrom
ldeb-fix-view-component-previews

Conversation

@lfdebrux
Copy link
Member

What problem does this pull request solve?

The preview functionality in the ViewComponent library has changed its configuration API since we initially configured it, breaking all of our component preview links.

This PR updates to the new configuration, and adds a test so we'll be alerted if config changes break the previews again in future.

This PR copies the fix from alphagov/forms-runner#1833.

Things to consider when reviewing

  • Ensure that you consider the wider context.
  • Does it work when run on your machine?
  • Is it clear what the code is doing?
  • Do the commit messages explain why the changes were made?
  • Are there all the unit tests needed?
  • Do the end to end tests need updating before these changes will pass?
  • Has all relevant documentation been updated?

lfdebrux and others added 2 commits March 18, 2026 11:55
The preview functionality in the ViewComponent library has changed its
configuration API since we initially configured it, breaking all of our
component preview links.

This commit updates to the new configuration, and adds a test so we'll
be alerted if config changes break the previews again in future.

This commit copies the fix from alphagov/forms-runner#1833.

Co-authored-by: David Biddle <contact@davidbiddle.co.uk>
In commit 94da7e7 we changed the call signature for the constructor of
the page list component error summary, but the calls in the component
preview weren't updated because nothing was testing if they were
working. Now the component previews are working again, the previews for
are complaining.

This commit updates the specs to make the component preview tests pass
again.
@lfdebrux lfdebrux force-pushed the ldeb-fix-view-component-previews branch from 2196e19 to fe32ae7 Compare March 18, 2026 09:55
@sonarqubecloud
Copy link

@github-actions
Copy link

🎉 A review copy of this PR has been deployed! You can reach it at: https://pr-2636.admin.review.forms.service.gov.uk/

It may take 5 minutes or so for the application to be fully deployed and working. If it still isn't ready
after 5 minutes, there may be something wrong with the ECS task. You will need to go to the integration AWS account
to debug, or otherwise ask an infrastructure person.

For the sign in details and more information, see the review apps wiki page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants