@openui5/sap.ui.core 1.91.0 → 1.93.2

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 (373) hide show
  1. package/.eslintrc.json +37 -0
  2. package/.reuse/dep5 +46 -0
  3. package/THIRDPARTY.txt +59 -1
  4. package/package.json +1 -1
  5. package/src/jquery.sap.global.js +6 -2
  6. package/src/jquery.sap.properties.js +1 -1
  7. package/src/jquery.sap.resources.js +1 -1
  8. package/src/jquery.sap.script.js +1 -1
  9. package/src/jquery.sap.storage.js +7 -4
  10. package/src/jquery.sap.stubs.js +0 -1
  11. package/src/sap/base/i18n/ResourceBundle.js +2 -2
  12. package/src/sap/base/security/encodeCSS.js +1 -0
  13. package/src/sap/base/security/encodeJS.js +1 -0
  14. package/src/sap/base/security/encodeURL.js +1 -0
  15. package/src/sap/base/security/encodeXML.js +2 -0
  16. package/src/sap/base/util/LoaderExtensions.js +1 -1
  17. package/src/sap/base/util/Properties.js +4 -1
  18. package/src/sap/base/util/isEmptyObject.js +1 -2
  19. package/src/sap/base/util/restricted/_CancelablePromise.js +1 -1
  20. package/src/sap/base/util/restricted/_castArray.js +1 -1
  21. package/src/sap/base/util/restricted/_compact.js +1 -1
  22. package/src/sap/base/util/restricted/_curry.js +1 -1
  23. package/src/sap/base/util/restricted/_debounce.js +1 -1
  24. package/src/sap/base/util/restricted/_difference.js +1 -1
  25. package/src/sap/base/util/restricted/_differenceBy.js +1 -1
  26. package/src/sap/base/util/restricted/_differenceWith.js +1 -1
  27. package/src/sap/base/util/restricted/_flatMap.js +1 -1
  28. package/src/sap/base/util/restricted/_flatMapDeep.js +1 -1
  29. package/src/sap/base/util/restricted/_flatMapDepth.js +1 -1
  30. package/src/sap/base/util/restricted/_flatten.js +1 -1
  31. package/src/sap/base/util/restricted/_flattenDeep.js +1 -1
  32. package/src/sap/base/util/restricted/_flattenDepth.js +1 -1
  33. package/src/sap/base/util/restricted/_intersection.js +1 -1
  34. package/src/sap/base/util/restricted/_intersectionBy.js +1 -1
  35. package/src/sap/base/util/restricted/_intersectionWith.js +1 -1
  36. package/src/sap/base/util/restricted/_isEqual.js +1 -1
  37. package/src/sap/base/util/restricted/_isEqualWith.js +1 -1
  38. package/src/sap/base/util/restricted/_isNil.js +1 -1
  39. package/src/sap/base/util/restricted/_max.js +1 -1
  40. package/src/sap/base/util/restricted/_merge.js +1 -1
  41. package/src/sap/base/util/restricted/_mergeWith.js +1 -1
  42. package/src/sap/base/util/restricted/_min.js +1 -1
  43. package/src/sap/base/util/restricted/_omit.js +1 -1
  44. package/src/sap/base/util/restricted/_pick.js +1 -1
  45. package/src/sap/base/util/restricted/_pickBy.js +1 -1
  46. package/src/sap/base/util/restricted/_throttle.js +1 -1
  47. package/src/sap/base/util/restricted/_toArray.js +1 -1
  48. package/src/sap/base/util/restricted/_union.js +1 -1
  49. package/src/sap/base/util/restricted/_unionBy.js +1 -1
  50. package/src/sap/base/util/restricted/_unionWith.js +1 -1
  51. package/src/sap/base/util/restricted/_uniq.js +1 -1
  52. package/src/sap/base/util/restricted/_uniqBy.js +1 -1
  53. package/src/sap/base/util/restricted/_uniqWith.js +1 -1
  54. package/src/sap/base/util/restricted/_without.js +1 -1
  55. package/src/sap/base/util/restricted/_xor.js +1 -1
  56. package/src/sap/base/util/restricted/_xorBy.js +1 -1
  57. package/src/sap/base/util/restricted/_xorWith.js +1 -1
  58. package/src/sap/base/util/restricted/_zipObject.js +1 -1
  59. package/src/sap/base/util/restricted/_zipObjectDeep.js +1 -1
  60. package/src/sap/ui/Device.js +10 -10
  61. package/src/sap/ui/Global.js +4 -4
  62. package/src/sap/ui/VersionInfo.js +1 -0
  63. package/src/sap/ui/base/DataType.js +1 -0
  64. package/src/sap/ui/base/Event.js +1 -1
  65. package/src/sap/ui/base/EventProvider.js +1 -1
  66. package/src/sap/ui/base/Interface.js +1 -1
  67. package/src/sap/ui/base/ManagedObject.js +121 -18
  68. package/src/sap/ui/base/ManagedObjectMetadata.js +13 -4
  69. package/src/sap/ui/base/Metadata.js +1 -1
  70. package/src/sap/ui/base/Object.js +1 -1
  71. package/src/sap/ui/base/ObjectPool.js +1 -1
  72. package/src/sap/ui/core/.library +4 -2
  73. package/src/sap/ui/core/BusyIndicator.js +1 -1
  74. package/src/sap/ui/core/BusyIndicatorUtils.js +4 -1
  75. package/src/sap/ui/core/Component.js +144 -43
  76. package/src/sap/ui/core/ComponentContainer.js +51 -2
  77. package/src/sap/ui/core/ComponentMetadata.js +1 -1
  78. package/src/sap/ui/core/ComponentSupport.js +1 -1
  79. package/src/sap/ui/core/Configuration.js +2 -1
  80. package/src/sap/ui/core/Control.js +1 -1
  81. package/src/sap/ui/core/Core.js +20 -22
  82. package/src/sap/ui/core/CustomData.js +1 -1
  83. package/src/sap/ui/core/CustomizingConfiguration.js +2 -2
  84. package/src/sap/ui/core/DeclarativeSupport.js +1 -1
  85. package/src/sap/ui/core/Element.js +1 -1
  86. package/src/sap/ui/core/ElementMetadata.js +1 -3
  87. package/src/sap/ui/core/EnabledPropagator.js +1 -1
  88. package/src/sap/ui/core/EventBus.js +1 -1
  89. package/src/sap/ui/core/ExtensionPoint.js +59 -16
  90. package/src/sap/ui/core/Fragment.js +3 -3
  91. package/src/sap/ui/core/HTML.js +1 -1
  92. package/src/sap/ui/core/History.js +1 -1
  93. package/src/sap/ui/core/Icon.js +1 -1
  94. package/src/sap/ui/core/IndicationColorSupport.js +1 -1
  95. package/src/sap/ui/core/IntervalTrigger.js +1 -1
  96. package/src/sap/ui/core/InvisibleMessage.js +9 -1
  97. package/src/sap/ui/core/InvisibleRenderer.js +1 -1
  98. package/src/sap/ui/core/InvisibleText.js +1 -1
  99. package/src/sap/ui/core/Item.js +1 -1
  100. package/src/sap/ui/core/LabelEnablement.js +1 -1
  101. package/src/sap/ui/core/LayoutData.js +1 -1
  102. package/src/sap/ui/core/ListItem.js +1 -1
  103. package/src/sap/ui/core/LocalBusyIndicator.js +1 -1
  104. package/src/sap/ui/core/Locale.js +1 -1
  105. package/src/sap/ui/core/LocaleData.js +15 -1328
  106. package/src/sap/ui/core/Manifest.js +124 -69
  107. package/src/sap/ui/core/Message.js +1 -1
  108. package/src/sap/ui/core/Patcher.js +143 -153
  109. package/src/sap/ui/core/Placeholder.js +173 -0
  110. package/src/sap/ui/core/Popup.js +29 -5
  111. package/src/sap/ui/core/RenderManager.js +344 -104
  112. package/src/sap/ui/core/Renderer.js +1 -1
  113. package/src/sap/ui/core/ResizeHandler.js +1 -1
  114. package/src/sap/ui/core/ScrollBar.js +1 -1
  115. package/src/sap/ui/core/SeparatorItem.js +1 -1
  116. package/src/sap/ui/core/ThemeCheck.js +14 -62
  117. package/src/sap/ui/core/Title.js +1 -1
  118. package/src/sap/ui/core/TooltipBase.js +1 -1
  119. package/src/sap/ui/core/UIArea.js +6 -3
  120. package/src/sap/ui/core/UIComponent.js +46 -23
  121. package/src/sap/ui/core/UIComponentMetadata.js +1 -1
  122. package/src/sap/ui/core/ValueStateSupport.js +1 -1
  123. package/src/sap/ui/core/VariantLayoutData.js +1 -1
  124. package/src/sap/ui/core/XMLComposite.js +3 -5
  125. package/src/sap/ui/core/XMLCompositeMetadata.js +1 -1
  126. package/src/sap/ui/core/XMLTemplateProcessor.js +5 -6
  127. package/src/sap/ui/core/cldr/en.json +1 -0
  128. package/src/sap/ui/core/date/UniversalDate.js +4 -2
  129. package/src/sap/ui/core/delegate/ItemNavigation.js +4 -4
  130. package/src/sap/ui/core/delegate/ScrollEnablement.js +1 -1
  131. package/src/sap/ui/core/dnd/DragAndDrop.js +1 -1
  132. package/src/sap/ui/core/dnd/DragDropBase.js +2 -9
  133. package/src/sap/ui/core/dnd/DragDropInfo.js +1 -1
  134. package/src/sap/ui/core/dnd/DragInfo.js +41 -1
  135. package/src/sap/ui/core/dnd/DropInfo.js +1 -1
  136. package/src/sap/ui/core/format/DateFormat.js +4 -2
  137. package/src/sap/ui/core/format/NumberFormat.js +3 -0
  138. package/src/sap/ui/core/hyphenation/Hyphenation.js +1 -1
  139. package/src/sap/ui/core/library.js +26 -4
  140. package/src/sap/ui/core/message/ControlMessageProcessor.js +1 -1
  141. package/src/sap/ui/core/message/Message.js +1 -1
  142. package/src/sap/ui/core/message/MessageManager.js +4 -2
  143. package/src/sap/ui/core/message/MessageParser.js +1 -1
  144. package/src/sap/ui/core/message/MessageProcessor.js +1 -1
  145. package/src/sap/ui/core/messagebundle_cs.properties +1 -1
  146. package/src/sap/ui/core/messagebundle_ms.properties +1 -1
  147. package/src/sap/ui/core/messagebundle_pt.properties +6 -6
  148. package/src/sap/ui/core/messagebundle_tr.properties +1 -1
  149. package/src/sap/ui/core/mvc/Controller.js +146 -8
  150. package/src/sap/ui/core/mvc/HTMLView.js +3 -1
  151. package/src/sap/ui/core/mvc/JSONView.js +7 -5
  152. package/src/sap/ui/core/mvc/JSView.js +4 -2
  153. package/src/sap/ui/core/mvc/TemplateView.js +1 -1
  154. package/src/sap/ui/core/mvc/View.js +145 -68
  155. package/src/sap/ui/core/mvc/ViewType.js +2 -0
  156. package/src/sap/ui/core/mvc/XMLView.js +13 -9
  157. package/src/sap/ui/core/plugin/DeclarativeSupport.js +1 -1
  158. package/src/sap/ui/core/plugin/LessSupport.js +1 -1
  159. package/src/sap/ui/core/plugin/TemplatingSupport.js +1 -1
  160. package/src/sap/ui/core/postmessage/Bus.js +1 -1
  161. package/src/sap/ui/core/postmessage/confirmationDialog.js +1 -1
  162. package/src/sap/ui/core/routing/HashChangerBase.js +9 -2
  163. package/src/sap/ui/core/routing/History.js +188 -87
  164. package/src/sap/ui/core/routing/Route.js +10 -1
  165. package/src/sap/ui/core/routing/Router.js +8 -5
  166. package/src/sap/ui/core/routing/RouterHashChanger.js +26 -16
  167. package/src/sap/ui/core/routing/TargetCache.js +19 -8
  168. package/src/sap/ui/core/routing/Targets.js +29 -3
  169. package/src/sap/ui/core/routing/async/Route.js +9 -1
  170. package/src/sap/ui/core/routing/async/Target.js +249 -85
  171. package/src/sap/ui/core/routing/async/TargetCache.js +9 -7
  172. package/src/sap/ui/core/routing/async/Targets.js +4 -2
  173. package/src/sap/ui/core/routing/sync/Target.js +15 -0
  174. package/src/sap/ui/core/rules/App.support.js +36 -2
  175. package/src/sap/ui/core/search/OpenSearchProvider.js +1 -1
  176. package/src/sap/ui/core/search/SearchProvider.js +1 -1
  177. package/src/sap/ui/core/service/Service.js +1 -1
  178. package/src/sap/ui/core/service/ServiceFactory.js +1 -1
  179. package/src/sap/ui/core/service/ServiceFactoryRegistry.js +1 -1
  180. package/src/sap/ui/core/support/InteractionTree.css +0 -14
  181. package/src/sap/ui/core/support/Plugin.js +1 -1
  182. package/src/sap/ui/core/support/RuleEngineOpaExtension.js +0 -2
  183. package/src/sap/ui/core/support/Support.js +1 -1
  184. package/src/sap/ui/core/support/TimelineOverview.css +0 -35
  185. package/src/sap/ui/core/support/controls/ObjectViewer.js +5 -9
  186. package/src/sap/ui/core/support/controls/TreeViewer.js +0 -1
  187. package/src/sap/ui/core/support/interactionSlider.css +0 -3
  188. package/src/sap/ui/core/support/plugins/ControlTree.js +2 -2
  189. package/src/sap/ui/core/support/plugins/Interaction.js +1 -1
  190. package/src/sap/ui/core/support/plugins/LocalStorage.js +1 -1
  191. package/src/sap/ui/core/support/plugins/MessageTest.js +1 -1
  192. package/src/sap/ui/core/support/plugins/Performance.js +2 -1
  193. package/src/sap/ui/core/support/plugins/Selector.js +1 -1
  194. package/src/sap/ui/core/support/plugins/TechInfo.js +1 -1
  195. package/src/sap/ui/core/support/plugins/Trace.js +1 -1
  196. package/src/sap/ui/core/support/plugins/ViewInfo.js +1 -3
  197. package/src/sap/ui/core/support/support.css +4 -164
  198. package/src/sap/ui/core/support/trace/E2eTraceLib.js +3 -3
  199. package/src/sap/ui/core/support/usage/EventBroadcaster.js +0 -22
  200. package/src/sap/ui/core/themes/base/BlindLayer.less +0 -2
  201. package/src/sap/ui/core/themes/base/BrowserScrollbar.less +0 -9
  202. package/src/sap/ui/core/themes/base/LocalBusyIndicator.less +5 -5
  203. package/src/sap/ui/core/themes/base/SAP-icons.css +2 -0
  204. package/src/sap/ui/core/themes/base/SAP-icons.less +10 -0
  205. package/src/sap/ui/core/themes/base/TechnicalInfo.less +0 -1
  206. package/src/sap/ui/core/themes/base/base.less +569 -414
  207. package/src/sap/ui/core/themes/base/global.less +38 -0
  208. package/src/sap/ui/core/themes/base/library.source.less +1 -2
  209. package/src/sap/ui/core/themes/base/shared.less +1 -1
  210. package/src/sap/ui/core/themes/sap_hcb/global.less +34 -0
  211. package/src/sap/ui/core/theming/Parameters.js +222 -60
  212. package/src/sap/ui/core/theming/ThemeHelper.js +94 -0
  213. package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -1
  214. package/src/sap/ui/core/tmpl/DOMElement.js +1 -1
  215. package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
  216. package/src/sap/ui/core/tmpl/Template.js +2 -1
  217. package/src/sap/ui/core/tmpl/TemplateControl.js +1 -1
  218. package/src/sap/ui/core/util/AsyncHintsHelper.js +1 -1
  219. package/src/sap/ui/core/util/Export.js +1 -1
  220. package/src/sap/ui/core/util/ExportCell.js +1 -1
  221. package/src/sap/ui/core/util/ExportColumn.js +1 -1
  222. package/src/sap/ui/core/util/ExportRow.js +1 -1
  223. package/src/sap/ui/core/util/ExportType.js +1 -1
  224. package/src/sap/ui/core/util/ExportTypeCSV.js +1 -1
  225. package/src/sap/ui/core/util/File.js +1 -1
  226. package/src/sap/ui/core/util/LibraryInfo.js +1 -1
  227. package/src/sap/ui/core/util/MockServer.js +27 -7
  228. package/src/sap/ui/core/util/PasteHelper.js +1 -1
  229. package/src/sap/ui/core/util/XMLPreprocessor.js +2 -2
  230. package/src/sap/ui/core/util/reflection/BaseTreeModifier.js +18 -0
  231. package/src/sap/ui/core/util/serializer/HTMLViewSerializer.js +1 -1
  232. package/src/sap/ui/core/util/serializer/Serializer.js +1 -1
  233. package/src/sap/ui/core/util/serializer/ViewSerializer.js +1 -1
  234. package/src/sap/ui/core/util/serializer/XMLViewSerializer.js +1 -1
  235. package/src/sap/ui/core/util/serializer/delegate/Delegate.js +1 -1
  236. package/src/sap/ui/core/util/serializer/delegate/HTML.js +2 -2
  237. package/src/sap/ui/core/util/serializer/delegate/XML.js +2 -2
  238. package/src/sap/ui/core/ws/ReadyState.js +1 -1
  239. package/src/sap/ui/core/ws/SapPcpWebSocket.js +2 -1
  240. package/src/sap/ui/core/ws/WebSocket.js +1 -1
  241. package/src/sap/ui/debug/ControlTree.js +1 -1
  242. package/src/sap/ui/debug/DebugEnv.js +1 -1
  243. package/src/sap/ui/debug/PropertyList.js +1 -1
  244. package/src/sap/ui/dom/jquery/zIndex.js +3 -3
  245. package/src/sap/ui/events/jquery/EventSimulation.js +7 -6
  246. package/src/sap/ui/events/jquery/EventTriggerHook.js +1 -1
  247. package/src/sap/ui/model/Binding.js +7 -3
  248. package/src/sap/ui/model/ClientModel.js +1 -1
  249. package/src/sap/ui/model/CompositeBinding.js +1 -1
  250. package/src/sap/ui/model/CompositeDataState.js +1 -1
  251. package/src/sap/ui/model/CompositeType.js +1 -1
  252. package/src/sap/ui/model/Context.js +31 -11
  253. package/src/sap/ui/model/DataState.js +1 -1
  254. package/src/sap/ui/model/ListBinding.js +19 -0
  255. package/src/sap/ui/model/MetaModel.js +1 -1
  256. package/src/sap/ui/model/Model.js +3 -3
  257. package/src/sap/ui/model/SelectionModel.js +5 -1
  258. package/src/sap/ui/model/SimpleType.js +1 -1
  259. package/src/sap/ui/model/TreeAutoExpandMode.js +1 -1
  260. package/src/sap/ui/model/Type.js +1 -1
  261. package/src/sap/ui/model/analytics/AnalyticalBinding.js +36 -45
  262. package/src/sap/ui/model/analytics/odata4analytics.js +31 -31
  263. package/src/sap/ui/model/base/ManagedObjectModel.js +11 -1
  264. package/src/sap/ui/model/json/JSONModel.js +1 -1
  265. package/src/sap/ui/model/message/MessageModel.js +1 -1
  266. package/src/sap/ui/model/odata/AnnotationParser.js +23 -18
  267. package/src/sap/ui/model/odata/ODataAnnotations.js +1 -1
  268. package/src/sap/ui/model/odata/ODataListBinding.js +1 -0
  269. package/src/sap/ui/model/odata/ODataMessageParser.js +1 -1
  270. package/src/sap/ui/model/odata/ODataMetaModel.js +52 -40
  271. package/src/sap/ui/model/odata/ODataMetadata.js +3 -3
  272. package/src/sap/ui/model/odata/ODataModel.js +6 -6
  273. package/src/sap/ui/model/odata/ODataTreeBindingFlat.js +1 -1
  274. package/src/sap/ui/model/odata/ODataUtils.js +126 -0
  275. package/src/sap/ui/model/odata/_AnnotationHelperBasics.js +30 -27
  276. package/src/sap/ui/model/odata/type/Boolean.js +1 -1
  277. package/src/sap/ui/model/odata/type/Byte.js +1 -1
  278. package/src/sap/ui/model/odata/type/Currency.js +7 -2
  279. package/src/sap/ui/model/odata/type/Date.js +1 -1
  280. package/src/sap/ui/model/odata/type/DateTime.js +1 -1
  281. package/src/sap/ui/model/odata/type/DateTimeBase.js +1 -1
  282. package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
  283. package/src/sap/ui/model/odata/type/Decimal.js +1 -1
  284. package/src/sap/ui/model/odata/type/Double.js +1 -1
  285. package/src/sap/ui/model/odata/type/Guid.js +1 -1
  286. package/src/sap/ui/model/odata/type/Int.js +1 -1
  287. package/src/sap/ui/model/odata/type/Int16.js +1 -1
  288. package/src/sap/ui/model/odata/type/Int32.js +1 -1
  289. package/src/sap/ui/model/odata/type/Int64.js +1 -1
  290. package/src/sap/ui/model/odata/type/ODataType.js +1 -1
  291. package/src/sap/ui/model/odata/type/Raw.js +1 -1
  292. package/src/sap/ui/model/odata/type/SByte.js +1 -1
  293. package/src/sap/ui/model/odata/type/Single.js +1 -1
  294. package/src/sap/ui/model/odata/type/Stream.js +1 -1
  295. package/src/sap/ui/model/odata/type/String.js +3 -1
  296. package/src/sap/ui/model/odata/type/Time.js +1 -1
  297. package/src/sap/ui/model/odata/type/TimeOfDay.js +1 -1
  298. package/src/sap/ui/model/odata/type/Unit.js +7 -2
  299. package/src/sap/ui/model/odata/type/UnitMixin.js +20 -7
  300. package/src/sap/ui/model/odata/v2/Context.js +165 -0
  301. package/src/sap/ui/model/odata/v2/ODataAnnotations.js +1 -1
  302. package/src/sap/ui/model/odata/v2/ODataContextBinding.js +19 -5
  303. package/src/sap/ui/model/odata/v2/ODataListBinding.js +20 -79
  304. package/src/sap/ui/model/odata/v2/ODataModel.js +75 -53
  305. package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +55 -41
  306. package/src/sap/ui/model/odata/v4/Context.js +48 -15
  307. package/src/sap/ui/model/odata/v4/ODataBinding.js +89 -9
  308. package/src/sap/ui/model/odata/v4/ODataContextBinding.js +87 -21
  309. package/src/sap/ui/model/odata/v4/ODataListBinding.js +72 -50
  310. package/src/sap/ui/model/odata/v4/ODataMetaModel.js +8 -8
  311. package/src/sap/ui/model/odata/v4/ODataModel.js +109 -171
  312. package/src/sap/ui/model/odata/v4/ODataParentBinding.js +34 -67
  313. package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +18 -9
  314. package/src/sap/ui/model/odata/v4/ODataUtils.js +1 -1
  315. package/src/sap/ui/model/odata/v4/SubmitMode.js +3 -3
  316. package/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js +1 -1
  317. package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +17 -16
  318. package/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js +5 -1
  319. package/src/sap/ui/model/odata/v4/lib/_Cache.js +86 -117
  320. package/src/sap/ui/model/odata/v4/lib/{_GrandTotalHelper.js → _ConcatHelper.js} +34 -27
  321. package/src/sap/ui/model/odata/v4/lib/_GroupLock.js +2 -2
  322. package/src/sap/ui/model/odata/v4/lib/_Helper.js +122 -7
  323. package/src/sap/ui/model/odata/v4/lib/_MetadataConverter.js +4 -4
  324. package/src/sap/ui/model/odata/v4/lib/_MetadataRequestor.js +2 -2
  325. package/src/sap/ui/model/odata/v4/lib/_MinMaxHelper.js +25 -74
  326. package/src/sap/ui/model/odata/v4/lib/_Requestor.js +49 -12
  327. package/src/sap/ui/model/odata/v4/lib/_V2Requestor.js +7 -7
  328. package/src/sap/ui/model/resource/ResourceModel.js +1 -1
  329. package/src/sap/ui/model/type/Boolean.js +1 -1
  330. package/src/sap/ui/model/type/Currency.js +1 -1
  331. package/src/sap/ui/model/type/Date.js +1 -1
  332. package/src/sap/ui/model/type/DateInterval.js +3 -3
  333. package/src/sap/ui/model/type/DateTime.js +1 -1
  334. package/src/sap/ui/model/type/DateTimeInterval.js +3 -3
  335. package/src/sap/ui/model/type/FileSize.js +1 -1
  336. package/src/sap/ui/model/type/Float.js +1 -1
  337. package/src/sap/ui/model/type/Integer.js +1 -1
  338. package/src/sap/ui/model/type/String.js +1 -1
  339. package/src/sap/ui/model/type/Time.js +1 -1
  340. package/src/sap/ui/model/type/TimeInterval.js +3 -3
  341. package/src/sap/ui/model/type/Unit.js +1 -1
  342. package/src/sap/ui/model/xml/XMLModel.js +1 -1
  343. package/src/sap/ui/performance/Measurement.js +3 -5
  344. package/src/sap/ui/performance/trace/FESR.js +2 -1
  345. package/src/sap/ui/performance/trace/Interaction.js +11 -9
  346. package/src/sap/ui/qunit/QUnitUtils.js +1 -1
  347. package/src/sap/ui/qunit/qunit-coverage.js +1 -0
  348. package/src/sap/ui/qunit/qunit-junit.js +1 -0
  349. package/src/sap/ui/qunit/utils/ControlIterator.js +1 -1
  350. package/src/sap/ui/qunit/utils/MemoryLeakCheck.js +1 -1
  351. package/src/sap/ui/security/FrameOptions.js +2 -1
  352. package/src/sap/ui/test/Opa5.js +1 -1
  353. package/src/sap/ui/test/OpaBuilder.js +1 -0
  354. package/src/sap/ui/test/TestUtils.js +17 -30
  355. package/src/sap/ui/test/_BrowserLogCollector.js +1 -0
  356. package/src/sap/ui/test/actions/Action.js +1 -1
  357. package/src/sap/ui/test/launchers/componentLauncher.js +2 -1
  358. package/src/sap/ui/test/opaQunit.js +6 -9
  359. package/src/sap/ui/test/pipelines/MatcherPipeline.js +1 -1
  360. package/src/sap/ui/test/selectors/_ControlSelectorGenerator.js +4 -4
  361. package/src/sap/ui/test/starter/_utils.js +6 -0
  362. package/src/sap/ui/test/starter/createSuite.js +1 -1
  363. package/src/sap/ui/thirdparty/IPv6.js +2 -2
  364. package/src/sap/ui/thirdparty/SecondLevelDomains.js +2 -2
  365. package/src/sap/ui/thirdparty/URI.js +14 -5
  366. package/src/sap/ui/thirdparty/URITemplate.js +2 -2
  367. package/src/sap/ui/thirdparty/caja-html-sanitizer.js +1 -1
  368. package/src/sap/ui/thirdparty/crossroads.js +10 -2
  369. package/src/sap/ui/util/Mobile.js +10 -7
  370. package/src/sap/ui/util/Storage.js +1 -1
  371. package/src/ui5loader-autoconfig.js +1 -1
  372. package/src/ui5loader.js +24 -6
  373. package/src/sap/ui/model/odata/v4/.eslintrc +0 -6
@@ -19,6 +19,18 @@ sap.ui.define([
19
19
  // Whether a path segment is an index or contains a transient predicate
20
20
  rIndexOrTransientPredicate = /\/\d|\(\$uid=/;
21
21
 
22
+ /*
23
+ * Tells whether the first given change reason has precedence over the second one.
24
+ *
25
+ * @param {string} sChangeReason0 - A change reason
26
+ * @param {string} sChangeReason1 - A change reason
27
+ * @returns {boolean} Whether the first given change reason has precedence over the second one
28
+ */
29
+ function hasPrecedenceOver(sChangeReason0, sChangeReason1) {
30
+ return aChangeReasonPrecedence.indexOf(sChangeReason0)
31
+ > aChangeReasonPrecedence.indexOf(sChangeReason1);
32
+ }
33
+
22
34
  /**
23
35
  * A mixin for all OData V4 bindings.
24
36
  *
@@ -59,11 +71,11 @@ sap.ui.define([
59
71
  };
60
72
 
61
73
  /**
62
- * Throws an Error that the response is discarded if the current cache not the expected one.
63
- * The error has the property <code>canceled : true</code>
74
+ * Throws an error that the response is being ignored if the current cache is not the expected
75
+ * one. The error has the property <code>canceled : true</code>
64
76
  *
65
77
  * @param {sap.ui.model.odata.v4.lib._Cache} oExpectedCache - The expected cache
66
- * @throws {Error} If the cache has changed
78
+ * @throws {Error} If the current cache is not the expected one
67
79
  *
68
80
  * @private
69
81
  */
@@ -71,7 +83,8 @@ sap.ui.define([
71
83
  var oError;
72
84
 
73
85
  if (this.oCache !== oExpectedCache) {
74
- oError = new Error("Response discarded: cache is inactive");
86
+ oError = new Error(this + " is ignoring response from inactive cache: "
87
+ + oExpectedCache);
75
88
  oError.canceled = true;
76
89
  throw oError;
77
90
  }
@@ -171,14 +184,19 @@ sap.ui.define([
171
184
  /**
172
185
  * Throws an Error if the binding's root binding is suspended.
173
186
  *
174
- * @throws {Error} If the binding's root binding is suspended
187
+ * @param {boolean} [bIfNoResumeChangeReason]
188
+ * Whether to accept a suspended root binding as long as no <code>sResumeChangeReason</code>
189
+ * is known for this binding (which must not be a root itself) or any of its dependents
190
+ * @throws {Error} If the binding's root binding is suspended, except if
191
+ * <code>bIfNoResumeChangeReason</code> is used as described
175
192
  *
176
193
  * @private
177
194
  */
178
- ODataBinding.prototype.checkSuspended = function () {
195
+ ODataBinding.prototype.checkSuspended = function (bIfNoResumeChangeReason) {
179
196
  var oRootBinding = this.getRootBinding();
180
197
 
181
- if (oRootBinding && oRootBinding.isSuspended()) {
198
+ if (oRootBinding && oRootBinding.isSuspended()
199
+ && (!bIfNoResumeChangeReason || this.isRoot() || this.getResumeChangeReason())) {
182
200
  throw new Error("Must not call method when the binding's root binding is suspended: "
183
201
  + this);
184
202
  }
@@ -668,6 +686,32 @@ sap.ui.define([
668
686
  return sPath;
669
687
  };
670
688
 
689
+ /**
690
+ * Returns the "strongest" change reason that {@link #resume} would fire for this binding or any
691
+ * of its dependents.
692
+ *
693
+ * @returns {sap.ui.model.ChangeReason}
694
+ * The "strongest" change reason, or <code>undefined</code>
695
+ *
696
+ * @private
697
+ * @see #getDependentBindings
698
+ * @see #setResumeChangeReason
699
+ */
700
+ ODataBinding.prototype.getResumeChangeReason = function () {
701
+ var sStrongestChangeReason = this.sResumeChangeReason;
702
+
703
+ this.getDependentBindings().forEach(function (oDependentBinding) {
704
+ var sDependentChangeReason = oDependentBinding.getResumeChangeReason();
705
+
706
+ if (sDependentChangeReason
707
+ && hasPrecedenceOver(sDependentChangeReason, sStrongestChangeReason)) {
708
+ sStrongestChangeReason = sDependentChangeReason;
709
+ }
710
+ });
711
+
712
+ return sStrongestChangeReason;
713
+ };
714
+
671
715
  /**
672
716
  * Returns a promise which resolves as soon as this binding is resumed.
673
717
  *
@@ -1002,6 +1046,43 @@ sap.ui.define([
1002
1046
  }
1003
1047
  };
1004
1048
 
1049
+ /**
1050
+ * Requests side effects for the given absolute paths.
1051
+ *
1052
+ * @param {string} sGroupId
1053
+ * The effective group ID
1054
+ * @param {string[]} aAbsolutePaths
1055
+ * The absolute paths to request side effects for
1056
+ * @returns {sap.ui.base.SyncPromise}
1057
+ * A promise resolving without a defined result, or rejecting with an error if loading of side
1058
+ * effects fails, or <code>undefined</code> if there is nothing to do
1059
+ *
1060
+ * @private
1061
+ */
1062
+ ODataBinding.prototype.requestAbsoluteSideEffects = function (sGroupId, aAbsolutePaths) {
1063
+ var aPaths = [],
1064
+ sMetaPath = _Helper.getMetaPath(this.getResolvedPath());
1065
+
1066
+ aAbsolutePaths.some(function (sAbsolutePath) {
1067
+ var sRelativePath = _Helper.getRelativePath(sAbsolutePath, sMetaPath);
1068
+
1069
+ if (sRelativePath !== undefined) {
1070
+ aPaths.push(sRelativePath);
1071
+ } else if (_Helper.hasPathPrefix(sMetaPath, sAbsolutePath)) {
1072
+ aPaths = [""]; // "refresh"
1073
+ return true; // break
1074
+ }
1075
+ });
1076
+
1077
+ if (aPaths.length) {
1078
+ if (this.requestSideEffects) {
1079
+ return this.requestSideEffects(sGroupId, aPaths);
1080
+ }
1081
+ return this.refreshInternal("", sGroupId, true);
1082
+ }
1083
+ // return undefined;
1084
+ };
1085
+
1005
1086
  /**
1006
1087
  * Refreshes the binding and returns a promise to wait for it. See {@link #refresh} for details.
1007
1088
  * Use {@link #refresh} if you do not need the promise.
@@ -1109,8 +1190,7 @@ sap.ui.define([
1109
1190
  * @private
1110
1191
  */
1111
1192
  ODataBinding.prototype.setResumeChangeReason = function (sChangeReason) {
1112
- if (aChangeReasonPrecedence.indexOf(sChangeReason) >
1113
- aChangeReasonPrecedence.indexOf(this.sResumeChangeReason)) {
1193
+ if (hasPrecedenceOver(sChangeReason, this.sResumeChangeReason)) {
1114
1194
  this.sResumeChangeReason = sChangeReason;
1115
1195
  }
1116
1196
  };
@@ -106,7 +106,7 @@ sap.ui.define([
106
106
  * @mixes sap.ui.model.odata.v4.ODataParentBinding
107
107
  * @public
108
108
  * @since 1.37.0
109
- * @version 1.91.0
109
+ * @version 1.93.2
110
110
  *
111
111
  * @borrows sap.ui.model.odata.v4.ODataBinding#getGroupId as #getGroupId
112
112
  * @borrows sap.ui.model.odata.v4.ODataBinding#getRootBinding as #getRootBinding
@@ -257,6 +257,8 @@ sap.ui.define([
257
257
  * @param {boolean} [bIgnoreETag]
258
258
  * Whether the entity's ETag should be actively ignored (If-Match:*); supported for bound
259
259
  * actions only
260
+ * @param {function} [fnOnStrictHandlingFailed]
261
+ * Callback for strict handling; supported for actions only
260
262
  * @returns {Promise}
261
263
  * A promise that is resolved without data or a return value context when the operation call
262
264
  * succeeded, or rejected with an instance of <code>Error</code> in case of failure. A return
@@ -268,7 +270,8 @@ sap.ui.define([
268
270
  * @private
269
271
  * @see #execute for details
270
272
  */
271
- ODataContextBinding.prototype._execute = function (oGroupLock, mParameters, bIgnoreETag) {
273
+ ODataContextBinding.prototype._execute = function (oGroupLock, mParameters, bIgnoreETag,
274
+ fnOnStrictHandlingFailed) {
272
275
  var oMetaModel = this.oModel.getMetaModel(),
273
276
  oOperationMetadata,
274
277
  oPromise,
@@ -302,7 +305,7 @@ sap.ui.define([
302
305
  }
303
306
  oOperationMetadata = aOperationMetadata[0];
304
307
  return that.createCacheAndRequest(oGroupLock, sResolvedPath, oOperationMetadata,
305
- mParameters, fnGetEntity, bIgnoreETag);
308
+ mParameters, fnGetEntity, bIgnoreETag, fnOnStrictHandlingFailed);
306
309
  }).then(function (oResponseEntity) {
307
310
  var sContextPredicate, oOldValue, sResponsePredicate;
308
311
 
@@ -566,17 +569,25 @@ sap.ui.define([
566
569
  * @param {boolean} [bIgnoreETag]
567
570
  * Whether the entity's ETag should be actively ignored (If-Match:*); supported for bound
568
571
  * actions only
572
+ * @param {function} [fnOnStrictHandlingFailed]
573
+ * Callback for strict handling; supported for actions only
569
574
  * @returns {SyncPromise}
570
575
  * The request promise
571
576
  * @throws {Error}
572
- * If a collection-valued parameter for an operation other than a V4 action is encountered,
573
- * or if the given metadata is neither an "Action" nor a "Function", or if
574
- * <code>bIgnoreETag</code> is used for an operation other than a bound action
577
+ * If
578
+ * <ul>
579
+ * <li> the given metadata is neither an "Action" nor a "Function",
580
+ * <li> a collection-valued parameter for an operation other than a V4 action is encountered,
581
+ * <li> <code>bIgnoreETag</code> is used for an operation other than a bound action,
582
+ * <li> <code>fnOnStrictHandlingFailed</code> is given but the given metadata is not an
583
+ * "Action",
584
+ * <li> <code>fnOnStrictHandlingFailed</code> is given and it does not return a promise.
585
+ * </ul>
575
586
  *
576
587
  * @private
577
588
  */
578
589
  ODataContextBinding.prototype.createCacheAndRequest = function (oGroupLock, sPath,
579
- oOperationMetadata, mParameters, fnGetEntity, bIgnoreETag) {
590
+ oOperationMetadata, mParameters, fnGetEntity, bIgnoreETag, fnOnStrictHandlingFailed) {
580
591
  var bAction = oOperationMetadata.$kind === "Action",
581
592
  oCache,
582
593
  vEntity = fnGetEntity,
@@ -607,6 +618,35 @@ sap.ui.define([
607
618
  return sOriginalResourcePath;
608
619
  }
609
620
 
621
+ /*
622
+ * Calls back into the application with the messages whether to repeat the action.
623
+ * @param {Error} oError The error from the failed request
624
+ * @returns {Promise} A promise resolving with a boolean
625
+ * @throws {Error} If <code>fnOnStrictHandlingFailed</code> does not return a promise
626
+ */
627
+ function onStrictHandling(oError) {
628
+ var oRawMessages, oResult;
629
+
630
+ _Helper.adjustTargetsInError(oError, oOperationMetadata,
631
+ that.oParameterContext.getPath(),
632
+ that.bRelative ? that.oContext.getPath() : undefined);
633
+ oError.error.$ignoreTopLevel = true;
634
+ oRawMessages = _Helper.extractMessages(oError);
635
+
636
+ oResult = fnOnStrictHandlingFailed(
637
+ oRawMessages.bound.concat(oRawMessages.unbound).map(function (oRawMessage) {
638
+ return that.oModel.createUI5Message(oRawMessage);
639
+ }));
640
+
641
+ if (!(oResult instanceof Promise)) {
642
+ throw new Error("Not a promise: " + oResult);
643
+ }
644
+ return oResult;
645
+ }
646
+
647
+ if (fnOnStrictHandlingFailed && oOperationMetadata.$kind !== "Action") {
648
+ throw new Error("Not an action: " + sPath);
649
+ }
610
650
  if (!bAction && oOperationMetadata.$kind !== "Function") {
611
651
  throw new Error("Not an operation: " + sPath);
612
652
  }
@@ -636,8 +676,10 @@ sap.ui.define([
636
676
  sMetaPath);
637
677
  this.oCache = oCache;
638
678
  this.oCachePromise = SyncPromise.resolve(oCache);
679
+
639
680
  return bAction
640
- ? oCache.post(oGroupLock, mParameters, vEntity, bIgnoreETag)
681
+ ? oCache.post(oGroupLock, mParameters, vEntity, bIgnoreETag,
682
+ fnOnStrictHandlingFailed && onStrictHandling)
641
683
  : oCache.fetchValue(oGroupLock);
642
684
  };
643
685
 
@@ -741,14 +783,31 @@ sap.ui.define([
741
783
  * IDs as specified in {@link sap.ui.model.odata.v4.ODataModel}.
742
784
  * @param {boolean} [bIgnoreETag]
743
785
  * Whether the entity's ETag should be actively ignored (If-Match:*); supported for bound
744
- * actions only, since 1.90.0
786
+ * actions only, since 1.90.0. Ignored if there is no ETag (since 1.93.0).
787
+ * @param {function} [fnOnStrictHandlingFailed]
788
+ * If this callback is given for an action, the preference "handling=strict" is applied. If
789
+ * the service responds with the HTTP status code 412 and a
790
+ * "Preference-applied: handling=strict" header, the details from the OData error response are
791
+ * extracted and passed to the callback as an array of {@link sap.ui.core.message.Message}
792
+ * items. The callback has to return a <code>Promise</code> resolving with a
793
+ * <code>boolean</code> value in order to indicate whether the bound action should either be
794
+ * repeated <b>without</b> applying the preference or rejected with an <code>Error</code>
795
+ * instance <code>oError</code> where <code>oError.canceled === true</code>.
796
+ * Since 1.92.0.
745
797
  * @returns {Promise}
746
798
  * A promise that is resolved without data or with a return value context when the operation
747
- * call succeeded, or rejected with an instance of <code>Error</code> in case of failure,
748
- * for instance if the operation metadata is not found, if overloading is not supported, if a
749
- * collection-valued function parameter is encountered, or if <code>bIgnoreETag</code> is used
750
- * for an operation other than a bound action.
751
- *
799
+ * call succeeded, or rejected with an <code>Error</code> instance <code>oError</code> in case
800
+ * of failure, for instance if the operation metadata is not found, if overloading is not
801
+ * supported, if a collection-valued function parameter is encountered, or if
802
+ * <code>bIgnoreETag</code> is used for an operation other than a bound action. It is also
803
+ * rejected if <code>fnOnStrictHandlingFailed</code> is supplied and
804
+ * <ul>
805
+ * <li> is used for an operation other than an action,
806
+ * <li> another request that applies the preference "handling=strict" exists in a different
807
+ * change set of the same $batch request,
808
+ * <li> returns a <code>Promise</code> that resolves with <code>false</code>. In this case
809
+ * <code>oError.canceled === true</code>.
810
+ * </ul>
752
811
  * A return value context is a {@link sap.ui.model.odata.v4.Context} which represents a bound
753
812
  * operation response. It is created only if the operation is bound and has a single entity
754
813
  * return value from the same entity set as the operation's binding parameter and has a
@@ -765,12 +824,15 @@ sap.ui.define([
765
824
  * {@link sap.ui.model.Binding#isResolved}) or relative to a transient context (see
766
825
  * {@link sap.ui.model.odata.v4.Context#isTransient}), or if deferred operation bindings are
767
826
  * nested, or if the OData resource path for a deferred operation binding's context cannot be
768
- * determined.
827
+ * determined, or if <code>fnOnStrictHandlingFailed</code> is called and does not return a
828
+ * <code>Promise</code>.
829
+
769
830
  *
770
831
  * @public
771
832
  * @since 1.37.0
772
833
  */
773
- ODataContextBinding.prototype.execute = function (sGroupId, bIgnoreETag) {
834
+ ODataContextBinding.prototype.execute = function (sGroupId, bIgnoreETag,
835
+ fnOnStrictHandlingFailed) {
774
836
  var sResolvedPath = this.getResolvedPath();
775
837
 
776
838
  this.checkSuspended();
@@ -792,7 +854,8 @@ sap.ui.define([
792
854
  }
793
855
 
794
856
  return this._execute(this.lockGroup(sGroupId, true),
795
- _Helper.publicClone(this.oOperation.mParameters, true), bIgnoreETag);
857
+ _Helper.publicClone(this.oOperation.mParameters, true), bIgnoreETag,
858
+ fnOnStrictHandlingFailed);
796
859
  };
797
860
 
798
861
  /**
@@ -804,7 +867,7 @@ sap.ui.define([
804
867
  * Some absolute path
805
868
  * @param {sap.ui.model.odata.v4.ODataPropertyBinding} [oListener]
806
869
  * A property binding which registers itself as listener at the cache
807
- * @param {boolean} [bCached=false]
870
+ * @param {boolean} [bCached]
808
871
  * Whether to return cached values only and not trigger a request
809
872
  * @returns {sap.ui.base.SyncPromise}
810
873
  * A promise on the outcome of the cache's <code>fetchValue</code> call; it is rejected in
@@ -1192,7 +1255,8 @@ sap.ui.define([
1192
1255
  that = this;
1193
1256
 
1194
1257
  /*
1195
- * Adds an error handler to the given promise which reports errors to the model.
1258
+ * Adds an error handler to the given promise which reports errors to the model and ignores
1259
+ * cancellations.
1196
1260
  *
1197
1261
  * @param {Promise} oPromise - A promise
1198
1262
  * @return {Promise} A promise including an error handler
@@ -1200,7 +1264,9 @@ sap.ui.define([
1200
1264
  function reportError(oPromise) {
1201
1265
  return oPromise.catch(function (oError) {
1202
1266
  oModel.reportError("Failed to request side effects", sClassName, oError);
1203
- throw oError;
1267
+ if (!oError.canceled) {
1268
+ throw oError;
1269
+ }
1204
1270
  });
1205
1271
  }
1206
1272
 
@@ -1297,7 +1363,7 @@ sap.ui.define([
1297
1363
  ODataContextBinding.prototype.setContext = function (oContext) {
1298
1364
  if (this.oContext !== oContext) {
1299
1365
  if (this.bRelative && (this.oContext || oContext)) {
1300
- this.checkSuspended();
1366
+ this.checkSuspended(true);
1301
1367
  if (this.oElementContext) {
1302
1368
  this.oElementContext.destroy();
1303
1369
  this.oElementContext = null;