@ui5/webcomponents-base 0.0.0-2f7664755 → 0.0.0-31ad69296

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (531) hide show
  1. package/.eslintignore +6 -4
  2. package/.eslintrc.cjs +3 -0
  3. package/.npsrc.json +3 -0
  4. package/CHANGELOG.md +895 -0
  5. package/README.md +6 -1
  6. package/bundle.esm.js +9 -3
  7. package/config/wdio.conf.cjs +400 -0
  8. package/dist/.tsbuildinfo +1 -0
  9. package/dist/AssetRegistry.d.ts +2 -2
  10. package/dist/AssetRegistry.js +2 -2
  11. package/dist/AssetRegistry.js.map +1 -1
  12. package/dist/Boot.d.ts +6 -4
  13. package/dist/Boot.js +36 -6
  14. package/dist/Boot.js.map +1 -1
  15. package/dist/CSP.d.ts +9 -6
  16. package/dist/CSP.js +9 -6
  17. package/dist/CSP.js.map +1 -1
  18. package/dist/CustomElementsRegistry.js.map +1 -1
  19. package/dist/CustomElementsScope.d.ts +4 -4
  20. package/dist/CustomElementsScope.js +2 -2
  21. package/dist/CustomElementsScope.js.map +1 -1
  22. package/dist/CustomElementsScopeUtils.d.ts +8 -1
  23. package/dist/CustomElementsScopeUtils.js +13 -1
  24. package/dist/CustomElementsScopeUtils.js.map +1 -1
  25. package/dist/DOMObserver.js.map +1 -1
  26. package/dist/Device.d.ts +2 -1
  27. package/dist/Device.js +119 -35
  28. package/dist/Device.js.map +1 -1
  29. package/dist/EventProvider.js +1 -1
  30. package/dist/EventProvider.js.map +1 -1
  31. package/dist/FeaturesRegistry.js.map +1 -1
  32. package/dist/FontFace.js +1 -1
  33. package/dist/FontFace.js.map +1 -1
  34. package/dist/IgnoreCustomElements.d.ts +25 -0
  35. package/dist/IgnoreCustomElements.js +37 -0
  36. package/dist/IgnoreCustomElements.js.map +1 -0
  37. package/dist/InitialConfiguration.d.ts +7 -2
  38. package/dist/InitialConfiguration.js +17 -7
  39. package/dist/InitialConfiguration.js.map +1 -1
  40. package/dist/Keys.d.ts +5 -1
  41. package/dist/Keys.js +109 -106
  42. package/dist/Keys.js.map +1 -1
  43. package/dist/ManagedStyles.d.ts +5 -4
  44. package/dist/ManagedStyles.js +95 -15
  45. package/dist/ManagedStyles.js.map +1 -1
  46. package/dist/MarkedEvents.js.map +1 -1
  47. package/dist/MediaRange.d.ts +6 -12
  48. package/dist/MediaRange.js +21 -31
  49. package/dist/MediaRange.js.map +1 -1
  50. package/dist/PropertiesFileFormat.js.map +1 -1
  51. package/dist/Render.js.map +1 -1
  52. package/dist/RenderQueue.js.map +1 -1
  53. package/dist/Runtimes.js.map +1 -1
  54. package/dist/StaticArea.d.ts +3 -0
  55. package/dist/StaticArea.js +4 -3
  56. package/dist/StaticArea.js.map +1 -1
  57. package/dist/StaticAreaItem.d.ts +3 -4
  58. package/dist/StaticAreaItem.js +10 -9
  59. package/dist/StaticAreaItem.js.map +1 -1
  60. package/dist/SystemCSSVars.js.map +1 -1
  61. package/dist/Theming.js.map +1 -1
  62. package/dist/UI5Element.d.ts +54 -39
  63. package/dist/UI5Element.js +119 -68
  64. package/dist/UI5Element.js.map +1 -1
  65. package/dist/UI5ElementMetadata.d.ts +6 -13
  66. package/dist/UI5ElementMetadata.js +17 -15
  67. package/dist/UI5ElementMetadata.js.map +1 -1
  68. package/dist/animations/AnimationQueue.js.map +1 -1
  69. package/dist/animations/animate.js.map +1 -1
  70. package/dist/animations/scroll.js.map +1 -1
  71. package/dist/animations/slideDown.js.map +1 -1
  72. package/dist/animations/slideUp.js.map +1 -1
  73. package/dist/asset-registries/Icons.d.ts +22 -13
  74. package/dist/asset-registries/Icons.js +63 -31
  75. package/dist/asset-registries/Icons.js.map +1 -1
  76. package/dist/asset-registries/Illustrations.d.ts +3 -1
  77. package/dist/asset-registries/Illustrations.js +51 -20
  78. package/dist/asset-registries/Illustrations.js.map +1 -1
  79. package/dist/asset-registries/LocaleData.js +1 -1
  80. package/dist/asset-registries/LocaleData.js.map +1 -1
  81. package/dist/asset-registries/Themes.d.ts +5 -3
  82. package/dist/asset-registries/Themes.js +28 -10
  83. package/dist/asset-registries/Themes.js.map +1 -1
  84. package/dist/asset-registries/i18n.d.ts +2 -2
  85. package/dist/asset-registries/i18n.js +12 -5
  86. package/dist/asset-registries/i18n.js.map +1 -1
  87. package/dist/asset-registries/util/IconCollectionsAlias.d.ts +30 -0
  88. package/dist/asset-registries/util/IconCollectionsAlias.js +37 -0
  89. package/dist/asset-registries/util/IconCollectionsAlias.js.map +1 -0
  90. package/dist/asset-registries/util/IconCollectionsByTheme.d.ts +20 -0
  91. package/dist/asset-registries/util/IconCollectionsByTheme.js +42 -0
  92. package/dist/asset-registries/util/IconCollectionsByTheme.js.map +1 -0
  93. package/dist/asset-registries/util/getIconCollectionByTheme.d.ts +13 -0
  94. package/dist/asset-registries/util/getIconCollectionByTheme.js +29 -0
  95. package/dist/asset-registries/util/getIconCollectionByTheme.js.map +1 -0
  96. package/dist/config/AnimationMode.d.ts +2 -2
  97. package/dist/config/AnimationMode.js +1 -1
  98. package/dist/config/AnimationMode.js.map +1 -1
  99. package/dist/config/CalendarType.d.ts +8 -1
  100. package/dist/config/CalendarType.js +18 -2
  101. package/dist/config/CalendarType.js.map +1 -1
  102. package/dist/config/FormatSettings.d.ts +5 -1
  103. package/dist/config/FormatSettings.js +5 -1
  104. package/dist/config/FormatSettings.js.map +1 -1
  105. package/dist/config/Icons.d.ts +31 -21
  106. package/dist/config/Icons.js +28 -32
  107. package/dist/config/Icons.js.map +1 -1
  108. package/dist/config/Language.d.ts +11 -2
  109. package/dist/config/Language.js +19 -4
  110. package/dist/config/Language.js.map +1 -1
  111. package/dist/config/NoConflict.js +1 -0
  112. package/dist/config/NoConflict.js.map +1 -1
  113. package/dist/config/Theme.d.ts +15 -5
  114. package/dist/config/Theme.js +31 -9
  115. package/dist/config/Theme.js.map +1 -1
  116. package/dist/config/ThemeRoot.d.ts +27 -0
  117. package/dist/config/ThemeRoot.js +57 -0
  118. package/dist/config/ThemeRoot.js.map +1 -0
  119. package/dist/config/Timezone.d.ts +17 -0
  120. package/dist/config/Timezone.js +30 -0
  121. package/dist/config/Timezone.js.map +1 -0
  122. package/dist/connectToComponent.d.ts +9 -0
  123. package/dist/connectToComponent.js +59 -0
  124. package/dist/connectToComponent.js.map +1 -0
  125. package/dist/css/FontFace.css +47 -17
  126. package/dist/css/SystemCSSVars.css +0 -8
  127. package/dist/custom-elements-internal.json +2863 -0
  128. package/dist/custom-elements.json +2593 -0
  129. package/dist/decorators/customElement.d.ts +17 -2
  130. package/dist/decorators/customElement.js +25 -5
  131. package/dist/decorators/customElement.js.map +1 -1
  132. package/dist/decorators/event.d.ts +5 -2
  133. package/dist/decorators/event.js +6 -6
  134. package/dist/decorators/event.js.map +1 -1
  135. package/dist/decorators/property.js +6 -6
  136. package/dist/decorators/property.js.map +1 -1
  137. package/dist/decorators/slot.js +9 -9
  138. package/dist/decorators/slot.js.map +1 -1
  139. package/dist/decorators.d.ts +5 -0
  140. package/dist/decorators.js +6 -0
  141. package/dist/decorators.js.map +1 -0
  142. package/dist/delegate/ItemNavigation.d.ts +9 -8
  143. package/dist/delegate/ItemNavigation.js +13 -14
  144. package/dist/delegate/ItemNavigation.js.map +1 -1
  145. package/dist/delegate/ResizeHandler.d.ts +6 -7
  146. package/dist/delegate/ResizeHandler.js +11 -9
  147. package/dist/delegate/ResizeHandler.js.map +1 -1
  148. package/dist/delegate/ScrollEnablement.js +2 -2
  149. package/dist/delegate/ScrollEnablement.js.map +1 -1
  150. package/dist/features/F6Navigation.d.ts +3 -0
  151. package/dist/features/F6Navigation.js +77 -38
  152. package/dist/features/F6Navigation.js.map +1 -1
  153. package/dist/features/LegacyDateFormats.d.ts +18 -0
  154. package/dist/features/LegacyDateFormats.js +20 -0
  155. package/dist/features/LegacyDateFormats.js.map +1 -0
  156. package/dist/features/OpenUI5Element.js.map +1 -1
  157. package/dist/features/OpenUI5Enablement.d.ts +1 -1
  158. package/dist/features/OpenUI5Enablement.js.map +1 -1
  159. package/dist/features/OpenUI5Support.d.ts +16 -3
  160. package/dist/features/OpenUI5Support.js +96 -33
  161. package/dist/features/OpenUI5Support.js.map +1 -1
  162. package/dist/features/patchPopup.d.ts +10 -0
  163. package/dist/features/patchPopup.js +15 -0
  164. package/dist/features/patchPopup.js.map +1 -0
  165. package/dist/generated/AssetParameters.d.ts +6 -0
  166. package/dist/generated/AssetParameters.js +4 -9
  167. package/dist/generated/AssetParameters.js.map +1 -0
  168. package/dist/generated/VersionInfo.d.ts +10 -0
  169. package/dist/generated/VersionInfo.js +9 -8
  170. package/dist/generated/VersionInfo.js.map +1 -0
  171. package/dist/generated/css/BusyIndicator.css.js.map +1 -1
  172. package/dist/generated/css/FontFace.css.js +1 -1
  173. package/dist/generated/css/FontFace.css.js.map +1 -1
  174. package/dist/generated/css/OverrideFontFace.css.js.map +1 -1
  175. package/dist/generated/css/SystemCSSVars.css.js +1 -1
  176. package/dist/generated/css/SystemCSSVars.css.js.map +1 -1
  177. package/dist/generated/templates/elements/WithComplexTemplateTemplate.lit.d.ts +4 -0
  178. package/dist/generated/templates/elements/WithComplexTemplateTemplate.lit.js +8 -10
  179. package/dist/generated/templates/elements/WithComplexTemplateTemplate.lit.js.map +1 -0
  180. package/dist/getSharedResource.d.ts +1 -1
  181. package/dist/getSharedResource.js +16 -2
  182. package/dist/getSharedResource.js.map +1 -1
  183. package/dist/global.d.ts +2 -0
  184. package/dist/i18nBundle.d.ts +2 -4
  185. package/dist/i18nBundle.js +3 -5
  186. package/dist/i18nBundle.js.map +1 -1
  187. package/dist/locale/Locale.js.map +1 -1
  188. package/dist/locale/RTLAwareRegistry.d.ts +1 -1
  189. package/dist/locale/RTLAwareRegistry.js.map +1 -1
  190. package/dist/locale/applyDirection.d.ts +3 -2
  191. package/dist/locale/applyDirection.js +3 -2
  192. package/dist/locale/applyDirection.js.map +1 -1
  193. package/dist/locale/directionChange.js.map +1 -1
  194. package/dist/locale/getEffectiveDir.d.ts +1 -1
  195. package/dist/locale/getEffectiveDir.js +3 -19
  196. package/dist/locale/getEffectiveDir.js.map +1 -1
  197. package/dist/locale/getLocale.js.map +1 -1
  198. package/dist/locale/languageChange.js.map +1 -1
  199. package/dist/locale/nextFallbackLocale.js.map +1 -1
  200. package/dist/locale/normalizeLocale.js.map +1 -1
  201. package/dist/renderer/LitRenderer.d.ts +5 -5
  202. package/dist/renderer/LitRenderer.js.map +1 -1
  203. package/dist/renderer/directives/style-map.d.ts +13 -0
  204. package/dist/renderer/directives/style-map.js +59 -59
  205. package/dist/renderer/directives/style-map.js.map +1 -0
  206. package/dist/renderer/executeTemplate.js +1 -1
  207. package/dist/renderer/executeTemplate.js.map +1 -1
  208. package/dist/sap/base/Log.js +698 -188
  209. package/dist/sap/base/assert.js +28 -1
  210. package/dist/sap/base/config/MemoryConfigurationProvider.js +20 -0
  211. package/dist/sap/base/security/URLListValidator.js +253 -6
  212. package/dist/sap/base/security/encodeCSS.js +34 -8
  213. package/dist/sap/base/security/encodeXML.js +47 -17
  214. package/dist/sap/base/security/sanitizeHTML.js +35 -13
  215. package/dist/sap/base/strings/toHex.js +27 -2
  216. package/dist/sap/base/util/now.js +24 -3
  217. package/dist/sap/base/util/uid.js +27 -0
  218. package/dist/sap/ui/thirdparty/caja-html-sanitizer.js +113 -98
  219. package/dist/ssr-dom-shim.d.ts +1 -0
  220. package/dist/ssr-dom-shim.js +12 -0
  221. package/dist/ssr-dom-shim.js.map +1 -0
  222. package/dist/ssr-dom.d.ts +0 -0
  223. package/dist/ssr-dom.js +3 -0
  224. package/dist/ssr-dom.js.map +1 -0
  225. package/dist/theming/CustomStyle.js +7 -5
  226. package/dist/theming/CustomStyle.js.map +1 -1
  227. package/dist/theming/ThemeLoaded.js.map +1 -1
  228. package/dist/theming/ThemeRegistered.d.ts +4 -0
  229. package/dist/theming/ThemeRegistered.js +11 -0
  230. package/dist/theming/ThemeRegistered.js.map +1 -0
  231. package/dist/theming/applyTheme.js +8 -7
  232. package/dist/theming/applyTheme.js.map +1 -1
  233. package/dist/theming/getConstructableStyle.js.map +1 -1
  234. package/dist/theming/getEffectiveLinksHrefs.js.map +1 -1
  235. package/dist/theming/getEffectiveStyle.js.map +1 -1
  236. package/dist/theming/getStylesString.d.ts +1 -1
  237. package/dist/theming/getStylesString.js.map +1 -1
  238. package/dist/theming/getThemeDesignerTheme.js.map +1 -1
  239. package/dist/theming/preloadLinks.js.map +1 -1
  240. package/dist/thirdparty/_merge.js.map +1 -1
  241. package/dist/thirdparty/isPlainObject.js.map +1 -1
  242. package/dist/thirdparty/merge.js.map +1 -1
  243. package/dist/types/AnimationMode.d.ts +0 -8
  244. package/dist/types/AnimationMode.js +0 -8
  245. package/dist/types/AnimationMode.js.map +1 -1
  246. package/dist/types/CSSColor.d.ts +0 -5
  247. package/dist/types/CSSColor.js +0 -5
  248. package/dist/types/CSSColor.js.map +1 -1
  249. package/dist/types/CSSSize.d.ts +11 -0
  250. package/dist/types/CSSSize.js +14 -0
  251. package/dist/types/CSSSize.js.map +1 -0
  252. package/dist/types/CalendarType.d.ts +0 -9
  253. package/dist/types/CalendarType.js +0 -9
  254. package/dist/types/CalendarType.js.map +1 -1
  255. package/dist/types/DOMReference.d.ts +1 -5
  256. package/dist/types/DOMReference.js +1 -5
  257. package/dist/types/DOMReference.js.map +1 -1
  258. package/dist/types/DataType.d.ts +1 -6
  259. package/dist/types/DataType.js +1 -6
  260. package/dist/types/DataType.js.map +1 -1
  261. package/dist/types/Float.d.ts +0 -4
  262. package/dist/types/Float.js +0 -4
  263. package/dist/types/Float.js.map +1 -1
  264. package/dist/types/Integer.d.ts +0 -4
  265. package/dist/types/Integer.js +0 -4
  266. package/dist/types/Integer.js.map +1 -1
  267. package/dist/types/InvisibleMessageMode.d.ts +5 -10
  268. package/dist/types/InvisibleMessageMode.js +4 -11
  269. package/dist/types/InvisibleMessageMode.js.map +1 -1
  270. package/dist/types/ItemNavigationBehavior.d.ts +0 -6
  271. package/dist/types/ItemNavigationBehavior.js +0 -6
  272. package/dist/types/ItemNavigationBehavior.js.map +1 -1
  273. package/dist/types/MovePlacement.d.ts +20 -0
  274. package/dist/types/MovePlacement.js +22 -0
  275. package/dist/types/MovePlacement.js.map +1 -0
  276. package/dist/types/NavigationMode.d.ts +0 -8
  277. package/dist/types/NavigationMode.js +0 -8
  278. package/dist/types/NavigationMode.js.map +1 -1
  279. package/dist/types/Orientation.d.ts +16 -0
  280. package/dist/types/Orientation.js +18 -0
  281. package/dist/types/Orientation.js.map +1 -0
  282. package/dist/types/ValueState.d.ts +0 -14
  283. package/dist/types/ValueState.js +0 -14
  284. package/dist/types/ValueState.js.map +1 -1
  285. package/dist/types.d.ts +11 -1
  286. package/dist/types.js.map +1 -1
  287. package/dist/updateShadowRoot.js +13 -5
  288. package/dist/updateShadowRoot.js.map +1 -1
  289. package/dist/util/AriaLabelHelper.d.ts +10 -1
  290. package/dist/util/AriaLabelHelper.js +135 -8
  291. package/dist/util/AriaLabelHelper.js.map +1 -1
  292. package/dist/util/Caret.js.map +1 -1
  293. package/dist/util/ColorConversion.js +200 -195
  294. package/dist/util/ColorConversion.js.map +1 -1
  295. package/dist/util/FetchHelper.js.map +1 -1
  296. package/dist/util/FocusableElements.js +4 -3
  297. package/dist/util/FocusableElements.js.map +1 -1
  298. package/dist/util/HTMLSanitizer.js.map +1 -1
  299. package/dist/util/InvisibleMessage.js.map +1 -1
  300. package/dist/util/PopupUtils.js +1 -1
  301. package/dist/util/PopupUtils.js.map +1 -1
  302. package/dist/util/SlotsHelper.js.map +1 -1
  303. package/dist/util/StringHelper.js.map +1 -1
  304. package/dist/util/TabbableElements.js.map +1 -1
  305. package/dist/util/arraysAreEqual.js.map +1 -1
  306. package/dist/util/clamp.js +2 -1
  307. package/dist/util/clamp.js.map +1 -1
  308. package/dist/util/createLinkInHead.d.ts +1 -1
  309. package/dist/util/createLinkInHead.js +1 -1
  310. package/dist/util/createLinkInHead.js.map +1 -1
  311. package/dist/util/createStyleInHead.d.ts +1 -1
  312. package/dist/util/createStyleInHead.js +1 -1
  313. package/dist/util/createStyleInHead.js.map +1 -1
  314. package/dist/util/debounce.js.map +1 -1
  315. package/dist/util/detectNavigatorLanguage.d.ts +2 -2
  316. package/dist/util/detectNavigatorLanguage.js +6 -1
  317. package/dist/util/detectNavigatorLanguage.js.map +1 -1
  318. package/dist/util/dragAndDrop/DragRegistry.d.ts +12 -0
  319. package/dist/util/dragAndDrop/DragRegistry.js +66 -0
  320. package/dist/util/dragAndDrop/DragRegistry.js.map +1 -0
  321. package/dist/util/dragAndDrop/findClosestPosition.d.ts +7 -0
  322. package/dist/util/dragAndDrop/findClosestPosition.js +59 -0
  323. package/dist/util/dragAndDrop/findClosestPosition.js.map +1 -0
  324. package/dist/util/dragAndDrop/longDragOverHandler.d.ts +2 -0
  325. package/dist/util/dragAndDrop/longDragOverHandler.js +25 -0
  326. package/dist/util/dragAndDrop/longDragOverHandler.js.map +1 -0
  327. package/dist/util/escapeRegex.js.map +1 -1
  328. package/dist/util/formatMessage.js.map +1 -1
  329. package/dist/util/generateHighlightedMarkup.js.map +1 -1
  330. package/dist/util/getActiveElement.js.map +1 -1
  331. package/dist/util/getClassCopy.d.ts +63 -43
  332. package/dist/util/getClassCopy.js.map +1 -1
  333. package/dist/util/getDesigntimePropertyAsArray.d.ts +2 -2
  334. package/dist/util/getDesigntimePropertyAsArray.js +2 -1
  335. package/dist/util/getDesigntimePropertyAsArray.js.map +1 -1
  336. package/dist/util/getEffectiveContentDensity.js.map +1 -1
  337. package/dist/util/getEffectiveScrollbarStyle.js.map +1 -1
  338. package/dist/util/getFastNavigationGroups.js.map +1 -1
  339. package/dist/util/getFileExtension.js.map +1 -1
  340. package/dist/util/getNormalizedTarget.js.map +1 -1
  341. package/dist/util/getParentElement.d.ts +2 -0
  342. package/dist/util/getParentElement.js +5 -0
  343. package/dist/util/getParentElement.js.map +1 -0
  344. package/dist/util/getSingletonElementInstance.d.ts +10 -1
  345. package/dist/util/getSingletonElementInstance.js +11 -2
  346. package/dist/util/getSingletonElementInstance.js.map +1 -1
  347. package/dist/util/isElementClickable.js.map +1 -1
  348. package/dist/util/isElementContainingBlock.d.ts +2 -0
  349. package/dist/util/isElementContainingBlock.js +11 -0
  350. package/dist/util/isElementContainingBlock.js.map +1 -0
  351. package/dist/util/isElementHidden.js.map +1 -1
  352. package/dist/util/isElementInView.js.map +1 -1
  353. package/dist/util/isElementTabbable.js.map +1 -1
  354. package/dist/util/isValidPropertyName.js.map +1 -1
  355. package/dist/util/whenDOMReady.js.map +1 -1
  356. package/dist/util/willShowContent.js.map +1 -1
  357. package/dist/validateThemeRoot.js +14 -13
  358. package/dist/validateThemeRoot.js.map +1 -1
  359. package/dist/vscode.html-custom-data.json +22 -0
  360. package/index.js +225 -1
  361. package/lib/generate-asset-parameters/index.js +6 -4
  362. package/lib/generate-styles/index.js +3 -3
  363. package/lib/generate-version-info/index.js +3 -3
  364. package/{package-scripts.js → package-scripts.cjs} +22 -22
  365. package/package.json +15 -6
  366. package/src/css/FontFace.css +47 -17
  367. package/src/css/SystemCSSVars.css +0 -8
  368. package/tsconfig.json +7 -0
  369. package/used-modules.txt +4 -0
  370. package/config/wdio.conf.js +0 -1
  371. package/dist/api.json +0 -1
  372. package/dist/assets/bundle.esm.8fc86dc4.js +0 -56
  373. package/dist/assets-meta/IconCollectionsAlias.d.ts +0 -17
  374. package/dist/assets-meta/IconCollectionsAlias.js +0 -18
  375. package/dist/assets-meta/IconCollectionsAlias.js.map +0 -1
  376. package/dist/config/RTL.d.ts +0 -7
  377. package/dist/config/RTL.js +0 -34
  378. package/dist/config/RTL.js.map +0 -1
  379. package/dist/config/ThemeRoots.d.ts +0 -4
  380. package/dist/config/ThemeRoots.js +0 -28
  381. package/dist/config/ThemeRoots.js.map +0 -1
  382. package/dist/decorators/fastNavigation.d.ts +0 -7
  383. package/dist/decorators/fastNavigation.js +0 -13
  384. package/dist/decorators/fastNavigation.js.map +0 -1
  385. package/dist/decorators/languageAware.d.ts +0 -7
  386. package/dist/decorators/languageAware.js +0 -13
  387. package/dist/decorators/languageAware.js.map +0 -1
  388. package/dist/decorators/themeAware.d.ts +0 -7
  389. package/dist/decorators/themeAware.js +0 -13
  390. package/dist/decorators/themeAware.js.map +0 -1
  391. package/src/AssetRegistry.ts +0 -11
  392. package/src/Boot.ts +0 -61
  393. package/src/CSP.ts +0 -66
  394. package/src/CustomElementsRegistry.ts +0 -98
  395. package/src/CustomElementsScope.ts +0 -33
  396. package/src/CustomElementsScopeUtils.ts +0 -115
  397. package/src/DOMObserver.ts +0 -28
  398. package/src/Device.ts +0 -124
  399. package/src/EventProvider.ts +0 -87
  400. package/src/FeaturesRegistry.ts +0 -14
  401. package/src/FontFace.ts +0 -31
  402. package/src/InitialConfiguration.ts +0 -207
  403. package/src/Keys.ts +0 -295
  404. package/src/ManagedStyles.ts +0 -92
  405. package/src/MarkedEvents.ts +0 -20
  406. package/src/MediaRange.ts +0 -110
  407. package/src/PropertiesFileFormat.ts +0 -95
  408. package/src/Render.ts +0 -180
  409. package/src/RenderQueue.ts +0 -71
  410. package/src/Runtimes.ts +0 -114
  411. package/src/StaticArea.ts +0 -3
  412. package/src/StaticAreaItem.ts +0 -113
  413. package/src/SystemCSSVars.ts +0 -10
  414. package/src/Theming.ts +0 -4
  415. package/src/UI5Element.ts +0 -1156
  416. package/src/UI5ElementMetadata.ts +0 -389
  417. package/src/animations/AnimationQueue.ts +0 -43
  418. package/src/animations/animate.ts +0 -64
  419. package/src/animations/scroll.ts +0 -21
  420. package/src/animations/slideDown.ts +0 -72
  421. package/src/animations/slideUp.ts +0 -67
  422. package/src/asset-registries/Icons.ts +0 -162
  423. package/src/asset-registries/Illustrations.ts +0 -75
  424. package/src/asset-registries/LocaleData.ts +0 -172
  425. package/src/asset-registries/Themes.ts +0 -67
  426. package/src/asset-registries/i18n.ts +0 -118
  427. package/src/assets-meta/IconCollectionsAlias.ts +0 -18
  428. package/src/config/AnimationMode.ts +0 -33
  429. package/src/config/CalendarType.ts +0 -23
  430. package/src/config/FormatSettings.ts +0 -21
  431. package/src/config/Icons.ts +0 -59
  432. package/src/config/Language.ts +0 -72
  433. package/src/config/NoConflict.ts +0 -67
  434. package/src/config/RTL.ts +0 -41
  435. package/src/config/Theme.ts +0 -64
  436. package/src/config/ThemeRoots.ts +0 -41
  437. package/src/decorators/customElement.ts +0 -17
  438. package/src/decorators/event.ts +0 -28
  439. package/src/decorators/fastNavigation.ts +0 -14
  440. package/src/decorators/languageAware.ts +0 -14
  441. package/src/decorators/property.ts +0 -30
  442. package/src/decorators/slot.ts +0 -49
  443. package/src/decorators/themeAware.ts +0 -14
  444. package/src/delegate/ItemNavigation.ts +0 -393
  445. package/src/delegate/ResizeHandler.ts +0 -95
  446. package/src/delegate/ScrollEnablement.ts +0 -224
  447. package/src/features/F6Navigation.ts +0 -141
  448. package/src/features/OpenUI5Element.ts +0 -11
  449. package/src/features/OpenUI5Enablement.ts +0 -117
  450. package/src/features/OpenUI5Support.ts +0 -148
  451. package/src/generated/css/BusyIndicator.css.ts +0 -9
  452. package/src/generated/css/FontFace.css.ts +0 -9
  453. package/src/generated/css/OverrideFontFace.css.ts +0 -9
  454. package/src/generated/css/SystemCSSVars.css.ts +0 -9
  455. package/src/getSharedResource.ts +0 -30
  456. package/src/global.d.ts +0 -38
  457. package/src/i18nBundle.ts +0 -108
  458. package/src/locale/Locale.ts +0 -101
  459. package/src/locale/RTLAwareRegistry.ts +0 -16
  460. package/src/locale/applyDirection.ts +0 -18
  461. package/src/locale/directionChange.ts +0 -34
  462. package/src/locale/getEffectiveDir.ts +0 -28
  463. package/src/locale/getLocale.ts +0 -46
  464. package/src/locale/languageChange.ts +0 -24
  465. package/src/locale/nextFallbackLocale.ts +0 -28
  466. package/src/locale/normalizeLocale.ts +0 -56
  467. package/src/renderer/LitRenderer.ts +0 -60
  468. package/src/renderer/directives/style-map.js +0 -72
  469. package/src/renderer/executeTemplate.ts +0 -40
  470. package/src/theming/CustomStyle.ts +0 -62
  471. package/src/theming/ThemeLoaded.ts +0 -24
  472. package/src/theming/applyTheme.ts +0 -90
  473. package/src/theming/getConstructableStyle.ts +0 -31
  474. package/src/theming/getEffectiveLinksHrefs.ts +0 -26
  475. package/src/theming/getEffectiveStyle.ts +0 -41
  476. package/src/theming/getStylesString.ts +0 -15
  477. package/src/theming/getThemeDesignerTheme.ts +0 -101
  478. package/src/theming/preloadLinks.ts +0 -24
  479. package/src/thirdparty/_merge.ts +0 -32
  480. package/src/thirdparty/isPlainObject.ts +0 -18
  481. package/src/thirdparty/merge.ts +0 -5
  482. package/src/types/AnimationMode.ts +0 -33
  483. package/src/types/CSSColor.ts +0 -20
  484. package/src/types/CalendarType.ts +0 -38
  485. package/src/types/DOMReference.ts +0 -28
  486. package/src/types/DataType.ts +0 -51
  487. package/src/types/Float.ts +0 -25
  488. package/src/types/Integer.ts +0 -25
  489. package/src/types/InvisibleMessageMode.ts +0 -27
  490. package/src/types/ItemNavigationBehavior.ts +0 -26
  491. package/src/types/NavigationMode.ts +0 -33
  492. package/src/types/ValueState.ts +0 -47
  493. package/src/types.ts +0 -30
  494. package/src/updateShadowRoot.ts +0 -37
  495. package/src/util/AriaLabelHelper.ts +0 -63
  496. package/src/util/Caret.ts +0 -28
  497. package/src/util/ColorConversion.ts +0 -399
  498. package/src/util/FetchHelper.ts +0 -31
  499. package/src/util/FocusableElements.ts +0 -92
  500. package/src/util/HTMLSanitizer.ts +0 -9
  501. package/src/util/InvisibleMessage.ts +0 -69
  502. package/src/util/PopupUtils.ts +0 -112
  503. package/src/util/SlotsHelper.ts +0 -39
  504. package/src/util/StringHelper.ts +0 -26
  505. package/src/util/TabbableElements.ts +0 -70
  506. package/src/util/arraysAreEqual.ts +0 -15
  507. package/src/util/clamp.ts +0 -12
  508. package/src/util/createLinkInHead.ts +0 -25
  509. package/src/util/createStyleInHead.ts +0 -20
  510. package/src/util/debounce.ts +0 -18
  511. package/src/util/detectNavigatorLanguage.ts +0 -13
  512. package/src/util/escapeRegex.ts +0 -11
  513. package/src/util/formatMessage.ts +0 -24
  514. package/src/util/generateHighlightedMarkup.ts +0 -43
  515. package/src/util/getActiveElement.ts +0 -11
  516. package/src/util/getClassCopy.ts +0 -12
  517. package/src/util/getDesigntimePropertyAsArray.ts +0 -4
  518. package/src/util/getEffectiveContentDensity.ts +0 -5
  519. package/src/util/getEffectiveScrollbarStyle.ts +0 -5
  520. package/src/util/getFastNavigationGroups.ts +0 -63
  521. package/src/util/getFileExtension.ts +0 -21
  522. package/src/util/getNormalizedTarget.ts +0 -16
  523. package/src/util/getSingletonElementInstance.ts +0 -13
  524. package/src/util/isElementClickable.ts +0 -19
  525. package/src/util/isElementHidden.ts +0 -9
  526. package/src/util/isElementInView.ts +0 -15
  527. package/src/util/isElementTabbable.ts +0 -37
  528. package/src/util/isValidPropertyName.ts +0 -29
  529. package/src/util/whenDOMReady.ts +0 -13
  530. package/src/util/willShowContent.ts +0 -7
  531. package/src/validateThemeRoot.ts +0 -58
@@ -1,8 +1,17 @@
1
+ import "@ui5/webcomponents-base/dist/ssr-dom.js";
1
2
  import UI5ElementMetadata, { Slot, SlotValue, State, PropertyValue, Metadata } from "./UI5ElementMetadata.js";
2
3
  import EventProvider from "./EventProvider.js";
3
4
  import StaticAreaItem from "./StaticAreaItem.js";
4
- import { TemplateFunction, TemplateFunctionResult } from "./renderer/executeTemplate.js";
5
- import { PromiseResolve, ComponentStylesData, ClassMap } from "./types.js";
5
+ import type { TemplateFunction, TemplateFunctionResult } from "./renderer/executeTemplate.js";
6
+ import type { AccessibilityInfo, PromiseResolve, ComponentStylesData, ClassMap } from "./types.js";
7
+ type Renderer = (templateResult: TemplateFunctionResult, container: HTMLElement | DocumentFragment, styleStrOrHrefsArr: string | Array<string> | undefined, forStaticArea: boolean, options: RendererOptions) => void;
8
+ type RendererOptions = {
9
+ /**
10
+ * An object to use as the `this` value for event listeners. It's often
11
+ * useful to set this to the host component rendering a template.
12
+ */
13
+ host?: object;
14
+ };
6
15
  type ChangeInfo = {
7
16
  type: "property" | "slot";
8
17
  name: string;
@@ -18,12 +27,9 @@ type InvalidationInfo = ChangeInfo & {
18
27
  type ChildChangeListener = (param: InvalidationInfo) => void;
19
28
  type SlotChangeListener = (this: HTMLSlotElement, ev: Event) => void;
20
29
  /**
30
+ * @class
21
31
  * Base class for all UI5 Web Components
22
32
  *
23
- * @class
24
- * @constructor
25
- * @author SAP SE
26
- * @alias sap.ui.webc.base.UI5Element
27
33
  * @extends HTMLElement
28
34
  * @public
29
35
  */
@@ -31,7 +37,8 @@ declare abstract class UI5Element extends HTMLElement {
31
37
  __id?: string;
32
38
  _suppressInvalidation: boolean;
33
39
  _changedState: Array<ChangeInfo>;
34
- _eventProvider: EventProvider<InvalidationInfo, void>;
40
+ _invalidationEventProvider: EventProvider<InvalidationInfo, void>;
41
+ _componentStateFinalizedEventProvider: EventProvider<void, void>;
35
42
  _inDOM: boolean;
36
43
  _fullyConnected: boolean;
37
44
  _childChangeListeners: Map<string, ChildChangeListener>;
@@ -41,15 +48,16 @@ declare abstract class UI5Element extends HTMLElement {
41
48
  };
42
49
  _doNotSyncAttributes: Set<string>;
43
50
  _state: State;
44
- _onComponentStateFinalized?: () => void;
45
51
  _getRealDomRef?: () => HTMLElement;
46
52
  staticAreaItem?: StaticAreaItem;
47
53
  static template?: TemplateFunction;
48
54
  static staticAreaTemplate?: TemplateFunction;
49
55
  static _metadata: UI5ElementMetadata;
50
- static render: (templateFunctionResult: TemplateFunctionResult, container: HTMLElement | DocumentFragment, styleStrOrHrefsArr: string | Array<string> | undefined, forStaticArea: boolean, options: {
51
- host: HTMLElement;
52
- }) => void;
56
+ /**
57
+ * @deprecated
58
+ */
59
+ static render: Renderer;
60
+ static renderer?: Renderer;
53
61
  constructor();
54
62
  /**
55
63
  * Returns a unique ID for this UI5 Element
@@ -58,6 +66,8 @@ declare abstract class UI5Element extends HTMLElement {
58
66
  * @protected
59
67
  */
60
68
  get _id(): string;
69
+ render(): object;
70
+ renderStatic(): object;
61
71
  /**
62
72
  * Do not call this method from derivatives of UI5Element, use "onEnterDOM" only
63
73
  * @private
@@ -113,22 +123,22 @@ declare abstract class UI5Element extends HTMLElement {
113
123
  /**
114
124
  * Attach a callback that will be executed whenever the component is invalidated
115
125
  *
116
- * @param {InvalidationInfo} callback
126
+ * @param callback
117
127
  * @public
118
128
  */
119
129
  attachInvalidate(callback: (param: InvalidationInfo) => void): void;
120
130
  /**
121
131
  * Detach the callback that is executed whenever the component is invalidated
122
132
  *
123
- * @param {InvalidationInfo} callback
133
+ * @param callback
124
134
  * @public
125
135
  */
126
136
  detachInvalidate(callback: (param: InvalidationInfo) => void): void;
127
137
  /**
128
138
  * Callback that is executed whenever a monitored child changes its state
129
139
  *
130
- * @param {sting} slotName the slot in which a child was invalidated
131
- * @param { ChangeInfo } childChangeInfo the changeInfo object for the child in the given slot
140
+ * @param slotName the slot in which a child was invalidated
141
+ * @param childChangeInfo the changeInfo object for the child in the given slot
132
142
  * @private
133
143
  */
134
144
  _onChildChange(slotName: string, childChangeInfo: ChangeInfo): void;
@@ -153,15 +163,13 @@ declare abstract class UI5Element extends HTMLElement {
153
163
  * Returns a singleton event listener for the "change" event of a child in a given slot
154
164
  *
155
165
  * @param slotName the name of the slot, where the child is
156
- * @returns {ChildChangeListener}
157
166
  * @private
158
167
  */
159
- _getChildChangeListener(slotName: string): ChildChangeListener | undefined;
168
+ _getChildChangeListener(slotName: string): ChildChangeListener;
160
169
  /**
161
170
  * Returns a singleton slotchange event listener that invalidates the component due to changes in the given slot
162
171
  *
163
172
  * @param slotName the name of the slot, where the slot element (whose slotchange event we're listening to) is
164
- * @returns {SlotChangeListener}
165
173
  * @private
166
174
  */
167
175
  _getSlotChangeListener(slotName: string): SlotChangeListener;
@@ -245,7 +253,7 @@ declare abstract class UI5Element extends HTMLElement {
245
253
  getFocusDomRefAsync(): Promise<HTMLElement | undefined>;
246
254
  /**
247
255
  * Set the focus to the element, returned by "getFocusDomRef()" (marked by "data-sap-focus-ref")
248
- * @param {FocusOptions} focusOptions additional options for the focus
256
+ * @param focusOptions additional options for the focus
249
257
  * @public
250
258
  */
251
259
  focus(focusOptions?: FocusOptions): Promise<void>;
@@ -256,7 +264,7 @@ declare abstract class UI5Element extends HTMLElement {
256
264
  * @param data - additional data for the event
257
265
  * @param cancelable - true, if the user can call preventDefault on the event object
258
266
  * @param bubbles - true, if the event bubbles
259
- * @returns {boolean} false, if the event was cancelled (preventDefault called), true otherwise
267
+ * @returns false, if the event was cancelled (preventDefault called), true otherwise
260
268
  */
261
269
  fireEvent<T>(name: string, data?: T, cancelable?: boolean, bubbles?: boolean): boolean;
262
270
  _fireEvent<T>(name: string, data?: T, cancelable?: boolean, bubbles?: boolean): boolean;
@@ -265,22 +273,41 @@ declare abstract class UI5Element extends HTMLElement {
265
273
  * Useful when there are transitive slots in nested component scenarios and you don't want to get a list of the slots, but rather of their content.
266
274
  * @public
267
275
  */
268
- getSlottedNodes(slotName: string): Node[];
276
+ getSlottedNodes<T = Node>(slotName: string): Array<T>;
277
+ /**
278
+ * Attach a callback that will be executed whenever the component's state is finalized
279
+ *
280
+ * @param callback
281
+ * @public
282
+ */
283
+ attachComponentStateFinalized(callback: () => void): void;
284
+ /**
285
+ * Detach the callback that is executed whenever the component's state is finalized
286
+ *
287
+ * @param callback
288
+ * @public
289
+ */
290
+ detachComponentStateFinalized(callback: () => void): void;
269
291
  /**
270
292
  * Determines whether the component should be rendered in RTL mode or not.
271
293
  * Returns: "rtl", "ltr" or undefined
272
294
  *
273
295
  * @public
274
- * @returns {String|undefined}
296
+ * @default undefined
275
297
  */
276
298
  get effectiveDir(): string | undefined;
277
299
  /**
278
300
  * Used to duck-type UI5 elements without using instanceof
279
- * @returns {boolean}
280
301
  * @public
302
+ * @default true
281
303
  */
282
304
  get isUI5Element(): boolean;
283
305
  get classes(): ClassMap;
306
+ /**
307
+ * Returns the component accessibility info.
308
+ * @private
309
+ */
310
+ get accessibilityInfo(): AccessibilityInfo;
284
311
  /**
285
312
  * Do not override this method in derivatives of UI5Element, use metadata properties instead
286
313
  * @private
@@ -306,17 +333,12 @@ declare abstract class UI5Element extends HTMLElement {
306
333
  * Returns the metadata object for this UI5 Web Component Class
307
334
  * @protected
308
335
  */
309
- static get metadata(): Metadata;
310
- /**
311
- * Sets a new metadata object for this UI5 Web Component Class
312
- * @protected
313
- */
314
- static set metadata(newMetadata: Metadata);
336
+ static metadata: Metadata;
315
337
  /**
316
338
  * Returns the CSS for this UI5 Web Component Class
317
339
  * @protected
318
340
  */
319
- static get styles(): ComponentStylesData;
341
+ static styles: ComponentStylesData;
320
342
  /**
321
343
  * Returns the Static Area CSS for this UI5 Web Component Class
322
344
  * @protected
@@ -335,40 +357,33 @@ declare abstract class UI5Element extends HTMLElement {
335
357
  *
336
358
  * @public
337
359
  */
338
- static getUniqueDependencies(this: typeof UI5Element): (typeof UI5Element)[];
360
+ static getUniqueDependencies(this: typeof UI5Element): Array<typeof UI5Element>;
339
361
  /**
340
362
  * Returns a promise that resolves whenever all dependencies for this UI5 Web Component have resolved
341
- *
342
- * @returns {Promise}
343
363
  */
344
364
  static whenDependenciesDefined(): Promise<Array<typeof UI5Element>>;
345
365
  /**
346
366
  * Hook that will be called upon custom element definition
347
367
  *
348
368
  * @protected
349
- * @returns {Promise<void>}
350
369
  */
351
370
  static onDefine(): Promise<void>;
352
371
  /**
353
372
  * Registers a UI5 Web Component in the browser window object
354
373
  * @public
355
- * @returns {Promise<UI5Element>}
356
374
  */
357
375
  static define(): Promise<typeof UI5Element>;
358
376
  /**
359
377
  * Returns an instance of UI5ElementMetadata.js representing this UI5 Web Component's full metadata (its and its parents')
360
378
  * Note: not to be confused with the "get metadata()" method, which returns an object for this class's metadata only
361
379
  * @public
362
- * @returns {UI5ElementMetadata}
363
380
  */
364
381
  static getMetadata(): UI5ElementMetadata;
365
- static decoratorMetadata: Metadata;
366
382
  }
367
383
  /**
368
384
  * Always use duck-typing to cover all runtimes on the page.
369
- * @returns {boolean}
370
385
  */
371
386
  declare const instanceOfUI5Element: (object: any) => object is UI5Element;
372
387
  export default UI5Element;
373
388
  export { instanceOfUI5Element };
374
- export type { ChangeInfo };
389
+ export type { ChangeInfo, Renderer, RendererOptions, };
@@ -1,3 +1,5 @@
1
+ // eslint-disable-next-line import/no-extraneous-dependencies
2
+ import "@ui5/webcomponents-base/dist/ssr-dom.js";
1
3
  import merge from "./thirdparty/merge.js";
2
4
  import { boot } from "./Boot.js";
3
5
  import UI5ElementMetadata from "./UI5ElementMetadata.js";
@@ -5,6 +7,7 @@ import EventProvider from "./EventProvider.js";
5
7
  import getSingletonElementInstance from "./util/getSingletonElementInstance.js";
6
8
  import StaticAreaItem from "./StaticAreaItem.js";
7
9
  import updateShadowRoot from "./updateShadowRoot.js";
10
+ import { shouldIgnoreCustomElement } from "./IgnoreCustomElements.js";
8
11
  import { renderDeferred, renderImmediately, cancelRender } from "./Render.js";
9
12
  import { registerTag, isTagRegistered, recordTagRegistrationFailure } from "./CustomElementsRegistry.js";
10
13
  import { observeDOMNode, unobserveDOMNode } from "./DOMObserver.js";
@@ -16,6 +19,7 @@ import { getSlotName, getSlottedNodesList } from "./util/SlotsHelper.js";
16
19
  import arraysAreEqual from "./util/arraysAreEqual.js";
17
20
  import { markAsRtlAware } from "./locale/RTLAwareRegistry.js";
18
21
  import preloadLinks from "./theming/preloadLinks.js";
22
+ import executeTemplate from "./renderer/executeTemplate.js";
19
23
  let autoId = 0;
20
24
  const elementTimeouts = new Map();
21
25
  const uniqueDependenciesCache = new Map();
@@ -34,16 +38,28 @@ function _invalidate(changeInfo) {
34
38
  this.onInvalidation(changeInfo);
35
39
  this._changedState.push(changeInfo);
36
40
  renderDeferred(this);
37
- this._eventProvider.fireEvent("invalidate", { ...changeInfo, target: this });
41
+ this._invalidationEventProvider.fireEvent("invalidate", { ...changeInfo, target: this });
38
42
  }
39
- let metadata = {};
40
43
  /**
44
+ * looks up a property descsriptor including in the prototype chain
45
+ * @param proto the starting prototype
46
+ * @param name the property to look for
47
+ * @returns the property descriptor if found directly or in the prototype chaing, undefined if not found
48
+ */
49
+ function getPropertyDescriptor(proto, name) {
50
+ do {
51
+ const descriptor = Object.getOwnPropertyDescriptor(proto, name);
52
+ if (descriptor) {
53
+ return descriptor;
54
+ }
55
+ // go up the prototype chain
56
+ proto = Object.getPrototypeOf(proto);
57
+ } while (proto && proto !== HTMLElement.prototype);
58
+ }
59
+ /**
60
+ * @class
41
61
  * Base class for all UI5 Web Components
42
62
  *
43
- * @class
44
- * @constructor
45
- * @author SAP SE
46
- * @alias sap.ui.webc.base.UI5Element
47
63
  * @extends HTMLElement
48
64
  * @public
49
65
  */
@@ -57,7 +73,8 @@ class UI5Element extends HTMLElement {
57
73
  this._fullyConnected = false; // A flag telling whether the UI5Element's onEnterDOM hook was called (since it's possible to have the element removed from DOM before that)
58
74
  this._childChangeListeners = new Map(); // used to store lazy listeners per slot for the child change event of every child inside that slot
59
75
  this._slotChangeListeners = new Map(); // used to store lazy listeners per slot for the slotchange event of all slot children inside that slot
60
- this._eventProvider = new EventProvider(); // used by parent components for listening to changes to child components
76
+ this._invalidationEventProvider = new EventProvider(); // used by parent components for listening to changes to child components
77
+ this._componentStateFinalizedEventProvider = new EventProvider(); // used by friend classes for synchronization
61
78
  let deferredResolve;
62
79
  this._domRefReadyPromise = new Promise(resolve => {
63
80
  deferredResolve = resolve;
@@ -82,6 +99,14 @@ class UI5Element extends HTMLElement {
82
99
  }
83
100
  return this.__id;
84
101
  }
102
+ render() {
103
+ const template = this.constructor.template;
104
+ return executeTemplate(template, this);
105
+ }
106
+ renderStatic() {
107
+ const template = this.constructor.staticAreaTemplate;
108
+ return executeTemplate(template, this);
109
+ }
85
110
  /**
86
111
  * Do not call this method from derivatives of UI5Element, use "onEnterDOM" only
87
112
  * @private
@@ -152,14 +177,16 @@ class UI5Element extends HTMLElement {
152
177
  */
153
178
  _startObservingDOMChildren() {
154
179
  const ctor = this.constructor;
155
- const shouldObserveChildren = ctor.getMetadata().hasSlots();
180
+ const metadata = ctor.getMetadata();
181
+ const shouldObserveChildren = metadata.hasSlots();
156
182
  if (!shouldObserveChildren) {
157
183
  return;
158
184
  }
159
- const canSlotText = ctor.getMetadata().canSlotText();
185
+ const canSlotText = metadata.canSlotText();
186
+ const hasClonedSlot = Object.keys(metadata.getSlots()).some(slotName => metadata.getSlots()[slotName].cloned);
160
187
  const mutationObserverOptions = {
161
188
  childList: true,
162
- subtree: canSlotText,
189
+ subtree: canSlotText || hasClonedSlot,
163
190
  characterData: canSlotText,
164
191
  };
165
192
  observeDOMNode(this, this._processChildren.bind(this), mutationObserverOptions);
@@ -220,11 +247,11 @@ class UI5Element extends HTMLElement {
220
247
  // Await for not-yet-defined custom elements
221
248
  if (child instanceof HTMLElement) {
222
249
  const localName = child.localName;
223
- const isCustomElement = localName.includes("-");
224
- if (isCustomElement) {
225
- const isDefined = window.customElements.get(localName);
250
+ const shouldWaitForCustomElement = localName.includes("-") && !shouldIgnoreCustomElement(localName);
251
+ if (shouldWaitForCustomElement) {
252
+ const isDefined = customElements.get(localName);
226
253
  if (!isDefined) {
227
- const whenDefinedPromise = window.customElements.whenDefined(localName); // Class registered, but instances not upgraded yet
254
+ const whenDefinedPromise = customElements.whenDefined(localName); // Class registered, but instances not upgraded yet
228
255
  let timeoutPromise = elementTimeouts.get(localName);
229
256
  if (!timeoutPromise) {
230
257
  timeoutPromise = new Promise(resolve => setTimeout(resolve, 1000));
@@ -232,7 +259,7 @@ class UI5Element extends HTMLElement {
232
259
  }
233
260
  await Promise.race([whenDefinedPromise, timeoutPromise]);
234
261
  }
235
- window.customElements.upgrade(child);
262
+ customElements.upgrade(child);
236
263
  }
237
264
  }
238
265
  child = ctor.getMetadata().constructor.validateSlotValue(child, slotData);
@@ -307,26 +334,26 @@ class UI5Element extends HTMLElement {
307
334
  /**
308
335
  * Attach a callback that will be executed whenever the component is invalidated
309
336
  *
310
- * @param {InvalidationInfo} callback
337
+ * @param callback
311
338
  * @public
312
339
  */
313
340
  attachInvalidate(callback) {
314
- this._eventProvider.attachEvent("invalidate", callback);
341
+ this._invalidationEventProvider.attachEvent("invalidate", callback);
315
342
  }
316
343
  /**
317
344
  * Detach the callback that is executed whenever the component is invalidated
318
345
  *
319
- * @param {InvalidationInfo} callback
346
+ * @param callback
320
347
  * @public
321
348
  */
322
349
  detachInvalidate(callback) {
323
- this._eventProvider.detachEvent("invalidate", callback);
350
+ this._invalidationEventProvider.detachEvent("invalidate", callback);
324
351
  }
325
352
  /**
326
353
  * Callback that is executed whenever a monitored child changes its state
327
354
  *
328
- * @param {sting} slotName the slot in which a child was invalidated
329
- * @param { ChangeInfo } childChangeInfo the changeInfo object for the child in the given slot
355
+ * @param slotName the slot in which a child was invalidated
356
+ * @param childChangeInfo the changeInfo object for the child in the given slot
330
357
  * @private
331
358
  */
332
359
  _onChildChange(slotName, childChangeInfo) {
@@ -436,7 +463,6 @@ class UI5Element extends HTMLElement {
436
463
  * Returns a singleton event listener for the "change" event of a child in a given slot
437
464
  *
438
465
  * @param slotName the name of the slot, where the child is
439
- * @returns {ChildChangeListener}
440
466
  * @private
441
467
  */
442
468
  _getChildChangeListener(slotName) {
@@ -449,7 +475,6 @@ class UI5Element extends HTMLElement {
449
475
  * Returns a singleton slotchange event listener that invalidates the component due to changes in the given slot
450
476
  *
451
477
  * @param slotName the name of the slot, where the slot element (whose slotchange event we're listening to) is
452
- * @returns {SlotChangeListener}
453
478
  * @private
454
479
  */
455
480
  _getSlotChangeListener(slotName) {
@@ -525,9 +550,7 @@ class UI5Element extends HTMLElement {
525
550
  this._suppressInvalidation = true;
526
551
  this.onBeforeRendering();
527
552
  // Intended for framework usage only. Currently ItemNavigation updates tab indexes after the component has updated its state but before the template is rendered
528
- if (this._onComponentStateFinalized) {
529
- this._onComponentStateFinalized();
530
- }
553
+ this._componentStateFinalizedEventProvider.fireEvent("componentStateFinalized");
531
554
  // resume normal invalidation handling
532
555
  this._suppressInvalidation = false;
533
556
  // Update the shadow root with the render result
@@ -627,7 +650,7 @@ class UI5Element extends HTMLElement {
627
650
  }
628
651
  /**
629
652
  * Set the focus to the element, returned by "getFocusDomRef()" (marked by "data-sap-focus-ref")
630
- * @param {FocusOptions} focusOptions additional options for the focus
653
+ * @param focusOptions additional options for the focus
631
654
  * @public
632
655
  */
633
656
  async focus(focusOptions) {
@@ -644,13 +667,13 @@ class UI5Element extends HTMLElement {
644
667
  * @param data - additional data for the event
645
668
  * @param cancelable - true, if the user can call preventDefault on the event object
646
669
  * @param bubbles - true, if the event bubbles
647
- * @returns {boolean} false, if the event was cancelled (preventDefault called), true otherwise
670
+ * @returns false, if the event was cancelled (preventDefault called), true otherwise
648
671
  */
649
672
  fireEvent(name, data, cancelable = false, bubbles = true) {
650
673
  const eventResult = this._fireEvent(name, data, cancelable, bubbles);
651
674
  const camelCaseEventName = kebabToCamelCase(name);
652
675
  if (camelCaseEventName !== name) {
653
- return eventResult && this._fireEvent(camelCaseEventName, data, cancelable);
676
+ return eventResult && this._fireEvent(camelCaseEventName, data, cancelable, bubbles);
654
677
  }
655
678
  return eventResult;
656
679
  }
@@ -685,12 +708,30 @@ class UI5Element extends HTMLElement {
685
708
  getSlottedNodes(slotName) {
686
709
  return getSlottedNodesList(this[slotName]);
687
710
  }
711
+ /**
712
+ * Attach a callback that will be executed whenever the component's state is finalized
713
+ *
714
+ * @param callback
715
+ * @public
716
+ */
717
+ attachComponentStateFinalized(callback) {
718
+ this._componentStateFinalizedEventProvider.attachEvent("componentStateFinalized", callback);
719
+ }
720
+ /**
721
+ * Detach the callback that is executed whenever the component's state is finalized
722
+ *
723
+ * @param callback
724
+ * @public
725
+ */
726
+ detachComponentStateFinalized(callback) {
727
+ this._componentStateFinalizedEventProvider.detachEvent("componentStateFinalized", callback);
728
+ }
688
729
  /**
689
730
  * Determines whether the component should be rendered in RTL mode or not.
690
731
  * Returns: "rtl", "ltr" or undefined
691
732
  *
692
733
  * @public
693
- * @returns {String|undefined}
734
+ * @default undefined
694
735
  */
695
736
  get effectiveDir() {
696
737
  markAsRtlAware(this.constructor); // if a UI5 Element calls this method, it's considered to be rtl-aware
@@ -698,8 +739,8 @@ class UI5Element extends HTMLElement {
698
739
  }
699
740
  /**
700
741
  * Used to duck-type UI5 elements without using instanceof
701
- * @returns {boolean}
702
742
  * @public
743
+ * @default true
703
744
  */
704
745
  get isUI5Element() {
705
746
  return true;
@@ -707,6 +748,13 @@ class UI5Element extends HTMLElement {
707
748
  get classes() {
708
749
  return {};
709
750
  }
751
+ /**
752
+ * Returns the component accessibility info.
753
+ * @private
754
+ */
755
+ get accessibilityInfo() {
756
+ return {};
757
+ }
710
758
  /**
711
759
  * Do not override this method in derivatives of UI5Element, use metadata properties instead
712
760
  * @private
@@ -718,13 +766,13 @@ class UI5Element extends HTMLElement {
718
766
  * @private
719
767
  */
720
768
  static _needsShadowDOM() {
721
- return !!this.template;
769
+ return !!this.template || Object.prototype.hasOwnProperty.call(this.prototype, "render");
722
770
  }
723
771
  /**
724
772
  * @private
725
773
  */
726
774
  static _needsStaticArea() {
727
- return !!this.staticAreaTemplate;
775
+ return !!this.staticAreaTemplate || Object.prototype.hasOwnProperty.call(this.prototype, "renderStatic");
728
776
  }
729
777
  /**
730
778
  * @public
@@ -766,8 +814,25 @@ class UI5Element extends HTMLElement {
766
814
  if (propData.multiple && propData.defaultValue) {
767
815
  throw new Error(`Cannot set a default value for property "${prop}". All multiple properties are empty arrays by default.`);
768
816
  }
817
+ const descriptor = getPropertyDescriptor(proto, prop);
818
+ // if the decorator is on a setter, proxy the new setter to it
819
+ let origSet;
820
+ if (descriptor?.set) {
821
+ // eslint-disable-next-line @typescript-eslint/unbound-method
822
+ origSet = descriptor.set;
823
+ }
824
+ // if the decorator is on a setter, there will be a corresponding getter - proxy the new getter to it
825
+ let origGet;
826
+ if (descriptor?.get) {
827
+ // eslint-disable-next-line @typescript-eslint/unbound-method
828
+ origGet = descriptor.get;
829
+ }
769
830
  Object.defineProperty(proto, prop, {
770
831
  get() {
832
+ // proxy the getter to the original accessor if there was one
833
+ if (origGet) {
834
+ return origGet.call(this);
835
+ }
771
836
  if (this._state[prop] !== undefined) {
772
837
  return this._state[prop];
773
838
  }
@@ -792,7 +857,7 @@ class UI5Element extends HTMLElement {
792
857
  value = metadataCtor.validatePropertyValue(value, propData);
793
858
  const propertyType = propData.type;
794
859
  let propertyValidator = propData.validator;
795
- const oldState = this._state[prop];
860
+ const oldState = origGet ? origGet.call(this) : this._state[prop];
796
861
  if (propertyType && propertyType.isDataTypeClass) {
797
862
  propertyValidator = propertyType;
798
863
  }
@@ -806,7 +871,13 @@ class UI5Element extends HTMLElement {
806
871
  isDifferent = oldState !== value;
807
872
  }
808
873
  if (isDifferent) {
809
- this._state[prop] = value;
874
+ // if the decorator is on a setter, use it for storage
875
+ if (origSet) {
876
+ origSet.call(this, value);
877
+ }
878
+ else {
879
+ this._state[prop] = value;
880
+ }
810
881
  _invalidate.call(this, {
811
882
  type: "property",
812
883
  name: prop,
@@ -840,27 +911,6 @@ class UI5Element extends HTMLElement {
840
911
  }
841
912
  }
842
913
  }
843
- /**
844
- * Returns the metadata object for this UI5 Web Component Class
845
- * @protected
846
- */
847
- static get metadata() {
848
- return metadata;
849
- }
850
- /**
851
- * Sets a new metadata object for this UI5 Web Component Class
852
- * @protected
853
- */
854
- static set metadata(newMetadata) {
855
- metadata = newMetadata;
856
- }
857
- /**
858
- * Returns the CSS for this UI5 Web Component Class
859
- * @protected
860
- */
861
- static get styles() {
862
- return "";
863
- }
864
914
  /**
865
915
  * Returns the Static Area CSS for this UI5 Web Component Class
866
916
  * @protected
@@ -892,8 +942,6 @@ class UI5Element extends HTMLElement {
892
942
  }
893
943
  /**
894
944
  * Returns a promise that resolves whenever all dependencies for this UI5 Web Component have resolved
895
- *
896
- * @returns {Promise}
897
945
  */
898
946
  static whenDependenciesDefined() {
899
947
  return Promise.all(this.getUniqueDependencies().map(dep => dep.define()));
@@ -902,7 +950,6 @@ class UI5Element extends HTMLElement {
902
950
  * Hook that will be called upon custom element definition
903
951
  *
904
952
  * @protected
905
- * @returns {Promise<void>}
906
953
  */
907
954
  static async onDefine() {
908
955
  return Promise.resolve();
@@ -910,7 +957,6 @@ class UI5Element extends HTMLElement {
910
957
  /**
911
958
  * Registers a UI5 Web Component in the browser window object
912
959
  * @public
913
- * @returns {Promise<UI5Element>}
914
960
  */
915
961
  static async define() {
916
962
  await boot();
@@ -927,7 +973,7 @@ class UI5Element extends HTMLElement {
927
973
  else if (!definedGlobally) {
928
974
  this._generateAccessors();
929
975
  registerTag(tag);
930
- window.customElements.define(tag, this);
976
+ customElements.define(tag, this);
931
977
  preloadLinks(this);
932
978
  }
933
979
  return this;
@@ -936,29 +982,34 @@ class UI5Element extends HTMLElement {
936
982
  * Returns an instance of UI5ElementMetadata.js representing this UI5 Web Component's full metadata (its and its parents')
937
983
  * Note: not to be confused with the "get metadata()" method, which returns an object for this class's metadata only
938
984
  * @public
939
- * @returns {UI5ElementMetadata}
940
985
  */
941
986
  static getMetadata() {
942
987
  if (this.hasOwnProperty("_metadata")) { // eslint-disable-line
943
988
  return this._metadata;
944
989
  }
945
- const effectiveMetadata = Object.keys(this.metadata).length ? this.metadata : this.decoratorMetadata;
946
- const metadataObjects = [effectiveMetadata];
990
+ const metadataObjects = [this.metadata];
947
991
  let klass = this; // eslint-disable-line
948
992
  while (klass !== UI5Element) {
949
993
  klass = Object.getPrototypeOf(klass);
950
- const effectiveKlassMetadata = Object.keys(klass.metadata).length ? klass.metadata : klass.decoratorMetadata;
951
- metadataObjects.unshift(effectiveKlassMetadata);
994
+ metadataObjects.unshift(klass.metadata);
952
995
  }
953
996
  const mergedMetadata = merge({}, ...metadataObjects);
954
997
  this._metadata = new UI5ElementMetadata(mergedMetadata);
955
998
  return this._metadata;
956
999
  }
957
1000
  }
958
- UI5Element.decoratorMetadata = {};
1001
+ /**
1002
+ * Returns the metadata object for this UI5 Web Component Class
1003
+ * @protected
1004
+ */
1005
+ UI5Element.metadata = {};
1006
+ /**
1007
+ * Returns the CSS for this UI5 Web Component Class
1008
+ * @protected
1009
+ */
1010
+ UI5Element.styles = "";
959
1011
  /**
960
1012
  * Always use duck-typing to cover all runtimes on the page.
961
- * @returns {boolean}
962
1013
  */
963
1014
  const instanceOfUI5Element = (object) => {
964
1015
  return "isUI5Element" in object;