Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: 60931e7 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
77d9494 to
076d438
Compare
…ria-busy={loading}
…shimmer animation.
|
Claude finished @punkbit's task in 3m 10s —— View job Code Review — chore: initial CSS modules setupGreat work on this! The architecture is well thought-out — marking 🚨 Must Fix
♿ Accessibility
💡 Suggestions (non-blocking)
Overall this is a well-structured foundation for the migration. The build pipeline approach (external CSS + static copy) is clever and the changeset with migration notes is appreciated. Resolve the
|
📚 Storybook Preview Deployed✅ Preview URL: https://click-hbtuf53ux-clickhouse.vercel.app Built from commit: |
Why?
Provide the initial setup foundations for CSS Modules for migrating from Styled-Components in a sustainable and iterative manner.
This library will now use CSS Modules for styling and is distributed unbundled, giving your application full control over bundling and optimisations. This means you only include what you actually use, resulting in smaller bundle sizes and better performance!
Regression risk assessment
The migration workflow provides visual regression tests, including changes to tests to include every relevant component state. For example, the following are implementations of it in practice:
chore: 🤖 support local visual regression testing via docker
#931
chore: 🤖 GitHub action for visual regression (development environment based [initial version])
#932
It ensures consistent visual regression snapshots by enabling local testing within a Dockerized environment. This prevents false positive diffs caused by operating system variations, e.g., macOS vs. linux.
Introduces a GitHub Action for visual regression testing within the CI/CD pipeline. Unlike our existing Chromatic implementation, which relies on Storybook stories and cloud-managed snapshots, this action executes tests using screenshots managed directly within the development environment (curated by author). This ensures snapshots remain tightly coupled with the implementation code.
It's important to note that the CI/CD process runs in every pull request contribution, under a matching Linux instance encountered in the local dev setup for an accelerated feedback loop.
Furthermore, these visual regression tests differ from the cloud-based regression testing Chromatic, as they're closer to local development setup, e.g. a contributor can run them in their environment immediately. Comparatively, the Chromatic setup provides feedback at a later stage of contribution, e.g. only running in the Cloud, causing the feedback loop to be much slower. While Chromatic automatically generates tests based on Storybook story screenshots, the local regression test suite allows the contributor to curate these for proper assessment and more in line with the intended implementation and behaviour checkup, e.g. can assess components singularly, compose scenarios with multiple components, and run interactive userflows to cause state changes.
Finally, it runs on Playwright but is adapted to Chromatic's extension, allowing for easier interchangeability.
Bug tracking
The Click UI has issues tracked, which can further any reports found during any test or release.
For example, during the migration process, there's an opportunity to snapshot and enhance checkups for proper testing against expected behaviour. If differences or unexpected behaviour's detected, these can be compared to the original Styled Component version and resolved comparatively, e.g. on visual regression testing, a local development suit is made available to help catch during time of contribution. Before, visual regression tests are solely base in Chromatic, which are autogenerated.
How?
Preview?
demo-button-ss-to-css-migration-states.mov
Demonstrates computed CSS Module in DOM
Distribution showcasing Button.module.css (in-place)