Skip to content

Reintroduce Lookbook for component previews#7115

Merged
aduth merged 39 commits intomainfrom
aduth-revert-revert-lookbook
Oct 21, 2022
Merged

Reintroduce Lookbook for component previews#7115
aduth merged 39 commits intomainfrom
aduth-revert-revert-lookbook

Conversation

@aduth
Copy link
Contributor

@aduth aduth commented Oct 7, 2022

🛠 Summary of changes

This reintroduces the Lookbook tool for ViewComponent previews.

It's essentially a revert of #6004.

Some of the issues we had encountered at the time have since been resolved as far as being able to host Lookbook in a deployed environment. As of https://github.com/allmarkedup/lookbook/issues/73, there are still some conflicts with content-security policy due to implementation of an underlying JavaScript library. For now, I'm proposing that this would only be available for local development. Edit: These are now addressed in this pull request.

It had been discussed as part of @18F/identity-joy-engineers's recent engineering sync as a useful tool to be able to perform implementation iterations and accessibility testing in an isolated preview environment, rather than having to navigate through entire flows of the real-world application.

📜 Testing Plan

👀 Screenshots

image

@aduth aduth requested review from a team and sheldon-b October 7, 2022 15:45
Copy link
Contributor

@zachmargolis zachmargolis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@aduth
Copy link
Contributor Author

aduth commented Oct 7, 2022

Currently this pull request simply reverts to what had previously existed, which is a bit out of date with the featureset of the components which were documented. Originally I was planning to do a follow-up pull request, but thinking I may as well just include them here and now.

@aduth aduth marked this pull request as draft October 7, 2022 20:41
@aduth
Copy link
Contributor Author

aduth commented Oct 11, 2022

With the changes in 122074e, we may be able to support previews in deployed environments. I'll plan to test this in my personal sandbox.

aduth added 20 commits October 20, 2022 11:35
changelog: Internal, Component Preview, Add development preview environment for UI components
For future support in deployed environments
Because current_content_security_policy will not be nil, even if empty
@aduth aduth force-pushed the aduth-revert-revert-lookbook branch from 31f0846 to 612539f Compare October 20, 2022 15:35
@aduth aduth changed the title Reintroduce Lookbook for local development component previews Reintroduce Lookbook for component previews Oct 20, 2022
aduth added 5 commits October 20, 2022 14:31
Theory is something in the engine init is messing with the tests? Shouldn't be mounted tho, based on feature flag
@aduth aduth marked this pull request as ready for review October 21, 2022 16:46
@aduth aduth merged commit f35ae1c into main Oct 21, 2022
@aduth aduth deleted the aduth-revert-revert-lookbook branch October 21, 2022 18:08
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