Skip to content

chore: output scoped-elements build folder for base class elements with scoped subcomponents#22145

Draft
annawen1 wants to merge 3 commits intocarbon-design-system:mainfrom
annawen1:chore/scoped-elements-build
Draft

chore: output scoped-elements build folder for base class elements with scoped subcomponents#22145
annawen1 wants to merge 3 commits intocarbon-design-system:mainfrom
annawen1:chore/scoped-elements-build

Conversation

@annawen1
Copy link
Copy Markdown
Member

@annawen1 annawen1 commented Apr 29, 2026

Contributes to #17718

This PR adds a plugin file that is run in the Web Components' build. The plugin strips the customElement decorator from the component class files so that the components don't self-register into the global custom element registry. For components that have subcomponents (ie. cds-accordion-skeleton uses cds-accordion-item-skeleton), we use the CustomElementRegistry API to create a scoped custom registry and scope the subcomponents to the parent component.

Changelog

New

  • {{new thing}}

Changed

  • {{changed thing}}

Removed

  • {{removed thing}}

Testing / Reviewing

{{ Add steps or a checklist for how reviewers can verify this PR works or not }}

PR Checklist

As the author of this PR, before marking ready for review, confirm you:

  • Reviewed every line of the diff
  • Updated documentation and storybook examples
  • Wrote passing tests that cover this change
  • Addressed any impact on accessibility (a11y)
  • Tested for cross-browser consistency
  • Validated that this code is ready for review and status checks should pass

More details can be found in the pull request guide

@annawen1 annawen1 requested a review from a team as a code owner April 29, 2026 19:49
@annawen1 annawen1 marked this pull request as draft April 29, 2026 19:49
@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 29, 2026

Deploy Preview for v11-carbon-react ready!

Name Link
🔨 Latest commit 8dc6621
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-react/deploys/69f3682ddd6e6400075b9e1c
😎 Deploy Preview https://deploy-preview-22145--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 29, 2026

Deploy Preview for v11-carbon-web-components ready!

Name Link
🔨 Latest commit 8dc6621
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-web-components/deploys/69f3682d2bd71a000804a109
😎 Deploy Preview https://deploy-preview-22145--v11-carbon-web-components.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.06%. Comparing base (0ba3f47) to head (8dc6621).
⚠️ Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #22145      +/-   ##
==========================================
- Coverage   95.08%   95.06%   -0.03%     
==========================================
  Files         541      541              
  Lines       45217    45239      +22     
  Branches     6560     6566       +6     
==========================================
+ Hits        42996    43007      +11     
- Misses       2092     2103      +11     
  Partials      129      129              
Flag Coverage Δ
main-packages 89.14% <ø> (+<0.01%) ⬆️
web-components 97.88% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

1 participant