Skip to content

Conversation

@fbeaudoincoveo
Copy link
Contributor

@fbeaudoincoveo fbeaudoincoveo commented Dec 15, 2025

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a static analysis script and CI job to detect invalid :host CSS selectors in Lit components that use Light DOM (no Shadow DOM). The validation prevents a subtle bug where :host selectors in Light DOM components cause style leakage or misapplication since there's no shadow boundary.

Key changes:

  • New validation script that recursively analyzes component files and imported styles for :host selectors in Light DOM components
  • CI workflow integration to run validation on every build
  • npm script entry for local validation

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
packages/atomic/scripts/check-light-dom-host-selectors.mjs New validation script that detects :host selectors in LightDomMixin and ItemSectionMixin components, including imported styles
packages/atomic/package.json Adds validate:light-dom-styles npm script to run the validation
.github/workflows/ci.yml Adds validate-light-dom-styles CI job that runs after build step

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI commented Dec 16, 2025

@fbeaudoincoveo I've opened a new pull request, #6811, to work on those changes. Once the pull request is ready, I'll request review from you.

Copy link
Contributor

Copilot AI commented Dec 16, 2025

@fbeaudoincoveo I've opened a new pull request, #6812, to work on those changes. Once the pull request is ready, I'll request review from you.

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: fbeaudoincoveo <[email protected]>
…ts CI job (#6812)

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: fbeaudoincoveo <[email protected]>
@fbeaudoincoveo fbeaudoincoveo added this pull request to the merge queue Dec 16, 2025
Merged via the queue into main with commit 3856fab Dec 16, 2025
98 checks passed
@fbeaudoincoveo fbeaudoincoveo deleted the KIT-5334-again branch December 16, 2025 15:18
@fbeaudoincoveo fbeaudoincoveo self-assigned this Dec 17, 2025
@fbeaudoincoveo fbeaudoincoveo linked an issue Dec 17, 2025 that may be closed by this pull request
3 tasks
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.

chore: add script / CI job to validate light DOM styles in Lit components

4 participants