Skip to content

Conversation

@devtomtom
Copy link
Collaborator

The rollup plugin for webcomponents now properly handles sap/ui/core/html/HTMLElement as a base class. This allows webcomponents to extend from it and be properly integrated into the UI5 rendering.

The WebComponentRegistry is now able to resolve the superclass for webcomponents in the @ui5/html namespace to sap.ui.core.html.HTMLElement.

Helper functions isUi5CoreHTMLElement and isHTMLElementBase have been added to WebComponentRegistryHelper.js to facilitate this change.

@Thodd Thodd force-pushed the feat/html-element-wrapper-classes branch from 601145d to ff53060 Compare August 7, 2025 16:53
devtomtom and others added 8 commits October 15, 2025 17:16
…omponents

The rollup plugin for webcomponents now properly handles sap/ui/core/html/HTMLElement as a base
class. This allows webcomponents to extend from it and be properly integrated into the UI5
rendering.

The WebComponentRegistry is now able to resolve the superclass for webcomponents in the @ui5/html
namespace to sap.ui.core.html.HTMLElement.

Helper functions isUi5CoreHTMLElement and isHTMLElementBase have been added to
WebComponentRegistryHelper.js to facilitate this change.
This commit introduces support for web components from the @ui5/html package
(not final). The @ui5/html package provides the custom-elements.json to
generate the HTMLElement wrapper classes.

The changes include:
 - Refactoring the WebComponentRegistryHelper to provide a more generic
   isSubclassOf check.
 - Updating the rollup-plugin-webcomponents.js to handle the @ui5/html
   namespace.
 - Modifying the UI5Package.hbs template to conditionally include the
   webcPackage.
 - Adding @ui5/html as a dependency to the ui5-tsapp-webc showcase and
   updating the views to use the new components.
The d.ts generation for UI5 web components has been improved to support also
non-UI5 web components (extending from HTMLElement). The metadata class is
now dynamically determined based on the component's inheritance
(e.g., HTMLElement or UI5Element) and imported accordingly.
@Thodd Thodd force-pushed the feat/html-element-wrapper-classes branch from 2852a9d to 8d53041 Compare October 15, 2025 15:31
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.

3 participants