Skip to content

fix: resolve web component enum properties as dropdowns via DataType - #380

Open
IlianaB wants to merge 1 commit into
masterfrom
fix/webc-enum-dropdown
Open

fix: resolve web component enum properties as dropdowns via DataType#380
IlianaB wants to merge 1 commit into
masterfrom
fix/webc-enum-dropdown

Conversation

@IlianaB

@IlianaB IlianaB commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Read enum values from the registered UI5 DataType
(DataType.getType(type).getEnumValues()) instead of walking the global window namespace. The generated UI5 Web Components wrappers are AMD-only modules that register their enums as DataTypes without exposing them on the global namespace, so the previous _transformStringTypeToObject walk failed and enum properties rendered as plain text fields. The legacy global walk is kept as a fallback for runtimes without getEnumValues().

Also guards against calling getDefaultValue()/getEnumValues() on a null DataType lookup.

Read enum values from the registered UI5 DataType
(DataType.getType(type).getEnumValues()) instead of walking the global
window namespace. The generated UI5 Web Components wrappers are AMD-only
modules that register their enums as DataTypes without exposing them on
the global namespace, so the previous _transformStringTypeToObject walk
failed and enum properties rendered as plain text fields. The legacy
global walk is kept as a fallback for runtimes without getEnumValues().

Also guards against calling getDefaultValue()/getEnumValues() on a null
DataType lookup.
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