Skip to content

Conversation

LinnJS
Copy link
Owner

@LinnJS LinnJS commented Aug 22, 2025

Description

This PR completes the migration of the UI package to use USWDS
(U.S. Web Design System) classes as the primary styling
approach, establishes a comprehensive testing architecture,
and improves type safety throughout the codebase.

The changes include:

  • Migration of all components from Tailwind utilities to USWDS
    BEM classes
  • Implementation of comprehensive unit and E2E testing with
    colocated test architecture
  • Removal of all any types and unsafe type assertions for
    improved type safety
  • Resolution of component import errors and test failures

This work ensures the UI package is production-ready with
proper USWDS styling, comprehensive test coverage, and
improved maintainability.

Type of Change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand
    areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my
    feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in
    downstream modules
  • I have checked my code and corrected any misspellings

Screenshots (if appropriate)

N/A - Component styling and test infrastructure changes

Additional Notes

Test Coverage

  • 123 unit tests passing across 7 test suites

  • Playwright E2E tests configured for Storybook stories

  • Tests colocated in tests directories within component
    folders

    Type Safety Improvements

  • Created FieldValue type union for validation system

  • Replaced unsafe type assertions with proper type guards

  • Zero TypeScript errors or ESLint warnings

    Components Updated

  • Button, Card, Form, Accordion, Alert, Badge, Typography
    components now use USWDS classes

  • All components maintain backward compatibility while using
    USWDS as primary styling

@LinnJS LinnJS self-assigned this Aug 22, 2025
@LinnJS LinnJS added enhancement New feature or request ui Changes to the ui package labels Aug 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request ui Changes to the ui package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant