@openui5/sap.ui.core 1.93.3 → 1.96.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.
- package/.eslintrc.json +13 -2
- package/.reuse/dep5 +6 -11
- package/THIRDPARTY.txt +10 -16
- package/package.json +1 -1
- package/src/jquery.sap.global.js +5 -2
- package/src/jquery.sap.properties.js +1 -1
- package/src/jquery.sap.resources.js +1 -1
- package/src/jquery.sap.script.js +1 -1
- package/src/jquery.sap.storage.js +3 -3
- package/src/jquery.sap.stubs.js +2 -1
- package/src/jquery.sap.trace.js +2 -1
- package/src/sap/base/i18n/ResourceBundle.js +6 -2
- package/src/sap/base/strings/whitespaceReplacer.js +52 -0
- package/src/sap/base/util/restricted/_CancelablePromise.js +1 -1
- package/src/sap/base/util/restricted/_castArray.js +1 -1
- package/src/sap/base/util/restricted/_compact.js +1 -1
- package/src/sap/base/util/restricted/_curry.js +1 -1
- package/src/sap/base/util/restricted/_debounce.js +1 -1
- package/src/sap/base/util/restricted/_difference.js +1 -1
- package/src/sap/base/util/restricted/_differenceBy.js +1 -1
- package/src/sap/base/util/restricted/_differenceWith.js +1 -1
- package/src/sap/base/util/restricted/_flatMap.js +1 -1
- package/src/sap/base/util/restricted/_flatMapDeep.js +1 -1
- package/src/sap/base/util/restricted/_flatMapDepth.js +1 -1
- package/src/sap/base/util/restricted/_flatten.js +1 -1
- package/src/sap/base/util/restricted/_flattenDeep.js +1 -1
- package/src/sap/base/util/restricted/_flattenDepth.js +1 -1
- package/src/sap/base/util/restricted/_intersection.js +1 -1
- package/src/sap/base/util/restricted/_intersectionBy.js +1 -1
- package/src/sap/base/util/restricted/_intersectionWith.js +1 -1
- package/src/sap/base/util/restricted/_isEqual.js +1 -1
- package/src/sap/base/util/restricted/_isEqualWith.js +1 -1
- package/src/sap/base/util/restricted/_isNil.js +1 -1
- package/src/sap/base/util/restricted/_max.js +1 -1
- package/src/sap/base/util/restricted/_merge.js +1 -1
- package/src/sap/base/util/restricted/_mergeWith.js +1 -1
- package/src/sap/base/util/restricted/_min.js +1 -1
- package/src/sap/base/util/restricted/_omit.js +1 -1
- package/src/sap/base/util/restricted/_pick.js +1 -1
- package/src/sap/base/util/restricted/_pickBy.js +1 -1
- package/src/sap/base/util/restricted/_throttle.js +1 -1
- package/src/sap/base/util/restricted/_toArray.js +1 -1
- package/src/sap/base/util/restricted/_union.js +1 -1
- package/src/sap/base/util/restricted/_unionBy.js +1 -1
- package/src/sap/base/util/restricted/_unionWith.js +1 -1
- package/src/sap/base/util/restricted/_uniq.js +1 -1
- package/src/sap/base/util/restricted/_uniqBy.js +1 -1
- package/src/sap/base/util/restricted/_uniqWith.js +1 -1
- package/src/sap/base/util/restricted/_without.js +1 -1
- package/src/sap/base/util/restricted/_xor.js +1 -1
- package/src/sap/base/util/restricted/_xorBy.js +1 -1
- package/src/sap/base/util/restricted/_xorWith.js +1 -1
- package/src/sap/base/util/restricted/_zipObject.js +1 -1
- package/src/sap/base/util/restricted/_zipObjectDeep.js +1 -1
- package/src/sap/ui/Device.js +37 -42
- package/src/sap/ui/Global.js +8 -7
- package/src/sap/ui/base/DataType.js +14 -8
- package/src/sap/ui/base/Event.js +1 -1
- package/src/sap/ui/base/EventProvider.js +1 -1
- package/src/sap/ui/base/ExpressionParser.js +9 -6
- package/src/sap/ui/base/Interface.js +3 -49
- package/src/sap/ui/base/ManagedObject.js +12 -7
- package/src/sap/ui/base/ManagedObjectMetadata.js +1 -1
- package/src/sap/ui/base/Metadata.js +1 -1
- package/src/sap/ui/base/Object.js +49 -4
- package/src/sap/ui/base/ObjectPool.js +1 -1
- package/src/sap/ui/base/syncXHRFix.js +2 -1
- package/src/sap/ui/core/.library +5 -5
- package/src/sap/ui/core/AppCacheBuster.js +4 -4
- package/src/sap/ui/core/BusyIndicator.js +1 -11
- package/src/sap/ui/core/Component.js +300 -140
- package/src/sap/ui/core/ComponentContainer.js +24 -8
- package/src/sap/ui/core/ComponentMetadata.js +14 -3
- package/src/sap/ui/core/ComponentSupport.js +1 -1
- package/src/sap/ui/core/Configuration.js +67 -31
- package/src/sap/ui/core/Control.js +1 -1
- package/src/sap/ui/core/Core.js +103 -25
- package/src/sap/ui/core/CustomData.js +1 -1
- package/src/sap/ui/core/CustomizingConfiguration.js +35 -260
- package/src/sap/ui/core/DeclarativeSupport.js +3 -2
- package/src/sap/ui/core/Element.js +1 -1
- package/src/sap/ui/core/ElementMetadata.js +4 -2
- package/src/sap/ui/core/EnabledPropagator.js +91 -73
- package/src/sap/ui/core/EventBus.js +1 -1
- package/src/sap/ui/core/ExtensionPoint.js +7 -14
- package/src/sap/ui/core/Fragment.js +30 -32
- package/src/sap/ui/core/HTML.js +1 -1
- package/src/sap/ui/core/History.js +1 -1
- package/src/sap/ui/core/Icon.js +7 -8
- package/src/sap/ui/core/IconPool.js +26 -1097
- package/src/sap/ui/core/IconRenderer.js +6 -6
- package/src/sap/ui/core/IndicationColorSupport.js +1 -1
- package/src/sap/ui/core/IntervalTrigger.js +1 -1
- package/src/sap/ui/core/InvisibleMessage.js +1 -1
- package/src/sap/ui/core/InvisibleRenderer.js +1 -1
- package/src/sap/ui/core/InvisibleText.js +1 -1
- package/src/sap/ui/core/Item.js +1 -1
- package/src/sap/ui/core/LabelEnablement.js +1 -1
- package/src/sap/ui/core/LayoutData.js +1 -1
- package/src/sap/ui/core/ListItem.js +1 -1
- package/src/sap/ui/core/LocalBusyIndicator.js +1 -1
- package/src/sap/ui/core/Locale.js +26 -4
- package/src/sap/ui/core/LocaleData.js +1 -1
- package/src/sap/ui/core/Manifest.js +4 -61
- package/src/sap/ui/core/Message.js +1 -1
- package/src/sap/ui/core/Patcher.js +27 -3
- package/src/sap/ui/core/Placeholder.js +28 -15
- package/src/sap/ui/core/RenderManager.js +36 -6
- package/src/sap/ui/core/Renderer.js +13 -3
- package/src/sap/ui/core/ResizeHandler.js +1 -1
- package/src/sap/ui/core/ScrollBar.js +2 -2
- package/src/sap/ui/core/SeparatorItem.js +1 -1
- package/src/sap/ui/core/ShortcutHintsMixin.js +14 -7
- package/src/sap/ui/core/Title.js +1 -1
- package/src/sap/ui/core/TooltipBase.js +1 -1
- package/src/sap/ui/core/UIArea.js +1 -1
- package/src/sap/ui/core/UIComponent.js +42 -16
- package/src/sap/ui/core/UIComponentMetadata.js +1 -1
- package/src/sap/ui/core/ValueStateSupport.js +1 -1
- package/src/sap/ui/core/VariantLayoutData.js +1 -1
- package/src/sap/ui/core/XMLComposite.js +2 -2
- package/src/sap/ui/core/XMLCompositeMetadata.js +2 -2
- package/src/sap/ui/core/XMLTemplateProcessor.js +116 -41
- package/src/sap/ui/core/_IconRegistry.js +1148 -0
- package/src/sap/ui/core/delegate/ItemNavigation.js +1 -1
- package/src/sap/ui/core/delegate/ScrollEnablement.js +6 -3
- package/src/sap/ui/core/dnd/DragDropBase.js +1 -1
- package/src/sap/ui/core/dnd/DragDropInfo.js +1 -1
- package/src/sap/ui/core/dnd/DragInfo.js +2 -2
- package/src/sap/ui/core/dnd/DropInfo.js +1 -1
- package/src/sap/ui/core/format/NumberFormat.js +16 -1
- package/src/sap/ui/core/hyphenation/Hyphenation.js +73 -221
- package/src/sap/ui/core/hyphenation/HyphenationTestingWords.js +11 -10
- package/src/sap/ui/core/library.js +3 -3
- package/src/sap/ui/core/message/ControlMessageProcessor.js +1 -1
- package/src/sap/ui/core/message/Message.js +1 -1
- package/src/sap/ui/core/message/MessageManager.js +13 -15
- package/src/sap/ui/core/message/MessageParser.js +1 -1
- package/src/sap/ui/core/message/MessageProcessor.js +1 -1
- package/src/sap/ui/core/messagebundle_de.properties +1 -1
- package/src/sap/ui/core/messagebundle_fr.properties +1 -1
- package/src/sap/ui/core/messagebundle_it.properties +1 -1
- package/src/sap/ui/core/messagebundle_pl.properties +1 -1
- package/src/sap/ui/core/messagebundle_th.properties +2 -2
- package/src/sap/ui/core/mvc/Controller.js +38 -19
- package/src/sap/ui/core/mvc/ControllerExtensionProvider.js +30 -32
- package/src/sap/ui/core/mvc/ControllerMetadata.js +18 -18
- package/src/sap/ui/core/mvc/HTMLView.js +2 -2
- package/src/sap/ui/core/mvc/JSONView.js +2 -2
- package/src/sap/ui/core/mvc/JSView.js +2 -2
- package/src/sap/ui/core/mvc/TemplateView.js +2 -2
- package/src/sap/ui/core/mvc/View.js +58 -85
- package/src/sap/ui/core/mvc/XMLView.js +2 -2
- package/src/sap/ui/core/mvc/XMLViewRenderer.js +17 -20
- package/src/sap/ui/core/plugin/DeclarativeSupport.js +1 -1
- package/src/sap/ui/core/plugin/LessSupport.js +1 -1
- package/src/sap/ui/core/plugin/TemplatingSupport.js +1 -1
- package/src/sap/ui/core/postmessage/Bus.js +1 -1
- package/src/sap/ui/core/postmessage/confirmationDialog.js +1 -1
- package/src/sap/ui/core/routing/History.js +10 -2
- package/src/sap/ui/core/routing/Router.js +8 -1
- package/src/sap/ui/core/routing/Target.js +13 -0
- package/src/sap/ui/core/routing/Targets.js +13 -2
- package/src/sap/ui/core/routing/async/Route.js +1 -1
- package/src/sap/ui/core/routing/async/Target.js +353 -259
- package/src/sap/ui/core/search/OpenSearchProvider.js +1 -1
- package/src/sap/ui/core/search/SearchProvider.js +1 -1
- package/src/sap/ui/core/service/Service.js +1 -1
- package/src/sap/ui/core/service/ServiceFactory.js +1 -1
- package/src/sap/ui/core/service/ServiceFactoryRegistry.js +1 -1
- package/src/sap/ui/core/support/BootSupportTool.js +11 -0
- package/src/sap/ui/core/support/InteractionTree.css +4 -0
- package/src/sap/ui/core/support/Plugin.js +1 -1
- package/src/sap/ui/core/support/Support.js +1 -1
- package/src/sap/ui/core/support/ViewInfo.css +599 -0
- package/src/sap/ui/core/support/controls/InteractionTree.js +352 -222
- package/src/sap/ui/core/support/controls/ObjectViewer.js +3 -41
- package/src/sap/ui/core/support/controls/TimelineOverview.js +49 -24
- package/src/sap/ui/core/support/controls/TreeViewer.js +12 -58
- package/src/sap/ui/core/support/plugins/ControlTree.js +59 -68
- package/src/sap/ui/core/support/plugins/Debugging.js +9 -11
- package/src/sap/ui/core/support/plugins/Interaction.js +2 -2
- package/src/sap/ui/core/support/plugins/LocalStorage.js +1 -1
- package/src/sap/ui/core/support/plugins/Performance.js +147 -75
- package/src/sap/ui/core/support/plugins/Selector.js +19 -24
- package/src/sap/ui/core/support/plugins/TechInfo.js +5 -5
- package/src/sap/ui/core/support/plugins/Trace.js +95 -32
- package/src/sap/ui/core/support/plugins/ViewInfo.js +9 -73
- package/src/sap/ui/core/support/support.css +109 -14
- package/src/sap/ui/core/support/support.html +6 -2
- package/src/sap/ui/core/support/techinfo/TechnicalInfo.fragment.xml +1 -0
- package/src/sap/ui/core/support/techinfo/TechnicalInfo.js +149 -72
- package/src/sap/ui/core/themes/base/Icon.less +9 -0
- package/src/sap/ui/core/themes/base/fonts/SAP-icons.woff2 +0 -0
- package/src/sap/ui/core/theming/Parameters.js +6 -4
- package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -1
- package/src/sap/ui/core/tmpl/DOMElement.js +1 -1
- package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
- package/src/sap/ui/core/tmpl/Template.js +10 -28
- package/src/sap/ui/core/tmpl/TemplateControl.js +4 -4
- package/src/sap/ui/core/tmpl/_parsePath.js +35 -0
- package/src/sap/ui/core/util/AsyncHintsHelper.js +1 -1
- package/src/sap/ui/core/util/DraftEnabledMockServer.js +9 -4
- package/src/sap/ui/core/util/Export.js +1 -1
- package/src/sap/ui/core/util/ExportCell.js +1 -1
- package/src/sap/ui/core/util/ExportColumn.js +1 -1
- package/src/sap/ui/core/util/ExportRow.js +1 -1
- package/src/sap/ui/core/util/ExportType.js +1 -1
- package/src/sap/ui/core/util/ExportTypeCSV.js +1 -1
- package/src/sap/ui/core/util/File.js +1 -1
- package/src/sap/ui/core/util/LibraryInfo.js +1 -1
- package/src/sap/ui/core/util/MockServer.js +5 -5
- package/src/sap/ui/core/util/MockServerAnnotationsHandler.js +3 -2
- package/src/sap/ui/core/util/PasteHelper.js +1 -1
- package/src/sap/ui/core/util/XMLPreprocessor.js +11 -12
- package/src/sap/ui/core/util/reflection/BaseTreeModifier.js +136 -63
- package/src/sap/ui/core/util/reflection/JsControlTreeModifier.js +170 -153
- package/src/sap/ui/core/util/reflection/XmlTreeModifier.js +424 -293
- package/src/sap/ui/core/util/serializer/HTMLViewSerializer.js +1 -1
- package/src/sap/ui/core/util/serializer/Serializer.js +1 -1
- package/src/sap/ui/core/util/serializer/ViewSerializer.js +1 -1
- package/src/sap/ui/core/util/serializer/XMLViewSerializer.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/Delegate.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/HTML.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/XML.js +1 -1
- package/src/sap/ui/core/ws/ReadyState.js +1 -1
- package/src/sap/ui/core/ws/SapPcpWebSocket.js +1 -1
- package/src/sap/ui/core/ws/WebSocket.js +1 -1
- package/src/sap/ui/debug/ControlTree.js +10 -4
- package/src/sap/ui/debug/DebugEnv.js +3 -4
- package/src/sap/ui/debug/Highlighter.js +8 -2
- package/src/sap/ui/debug/PropertyList.css +55 -0
- package/src/sap/ui/debug/PropertyList.js +111 -182
- package/src/sap/ui/model/Binding.js +174 -118
- package/src/sap/ui/model/ClientContextBinding.js +1 -1
- package/src/sap/ui/model/ClientListBinding.js +1 -3
- package/src/sap/ui/model/ClientModel.js +4 -4
- package/src/sap/ui/model/ClientPropertyBinding.js +4 -2
- package/src/sap/ui/model/ClientTreeBinding.js +15 -9
- package/src/sap/ui/model/ClientTreeBindingAdapter.js +28 -23
- package/src/sap/ui/model/CompositeBinding.js +98 -77
- package/src/sap/ui/model/CompositeDataState.js +2 -2
- package/src/sap/ui/model/CompositeType.js +2 -2
- package/src/sap/ui/model/Context.js +4 -2
- package/src/sap/ui/model/ContextBinding.js +6 -14
- package/src/sap/ui/model/DataState.js +2 -2
- package/src/sap/ui/model/Filter.js +255 -53
- package/src/sap/ui/model/FilterOperator.js +1 -1
- package/src/sap/ui/model/FilterProcessor.js +27 -17
- package/src/sap/ui/model/FilterType.js +1 -1
- package/src/sap/ui/model/ListBinding.js +180 -117
- package/src/sap/ui/model/MetaModel.js +4 -9
- package/src/sap/ui/model/Model.js +345 -294
- package/src/sap/ui/model/PropertyBinding.js +92 -58
- package/src/sap/ui/model/SelectionModel.js +2 -2
- package/src/sap/ui/model/SimpleType.js +2 -2
- package/src/sap/ui/model/Sorter.js +1 -1
- package/src/sap/ui/model/SorterProcessor.js +1 -1
- package/src/sap/ui/model/StaticBinding.js +1 -1
- package/src/sap/ui/model/TreeAutoExpandMode.js +2 -2
- package/src/sap/ui/model/TreeBinding.js +1 -1
- package/src/sap/ui/model/TreeBindingAdapter.js +251 -100
- package/src/sap/ui/model/TreeBindingCompatibilityAdapter.js +16 -9
- package/src/sap/ui/model/TreeBindingUtils.js +1 -0
- package/src/sap/ui/model/Type.js +1 -1
- package/src/sap/ui/model/analytics/AnalyticalBinding.js +8 -4
- package/src/sap/ui/model/analytics/AnalyticalTreeBindingAdapter.js +1 -1
- package/src/sap/ui/model/analytics/AnalyticalVersionInfo.js +1 -1
- package/src/sap/ui/model/analytics/BatchResponseCollector.js +1 -1
- package/src/sap/ui/model/analytics/ODataModelAdapter.js +1 -1
- package/src/sap/ui/model/analytics/odata4analytics.js +34 -25
- package/src/sap/ui/model/base/ManagedObjectModel.js +4 -0
- package/src/sap/ui/model/json/JSONListBinding.js +8 -5
- package/src/sap/ui/model/json/JSONModel.js +24 -15
- package/src/sap/ui/model/json/JSONPropertyBinding.js +4 -3
- package/src/sap/ui/model/json/JSONTreeBinding.js +1 -1
- package/src/sap/ui/model/message/MessageListBinding.js +6 -3
- package/src/sap/ui/model/message/MessageModel.js +23 -15
- package/src/sap/ui/model/message/MessagePropertyBinding.js +2 -2
- package/src/sap/ui/model/odata/AnnotationHelper.js +1 -1
- package/src/sap/ui/model/odata/AnnotationParser.js +1 -1
- package/src/sap/ui/model/odata/CountMode.js +1 -1
- package/src/sap/ui/model/odata/Filter.js +1 -1
- package/src/sap/ui/model/odata/ODataAnnotations.js +2 -2
- package/src/sap/ui/model/odata/ODataContextBinding.js +1 -1
- package/src/sap/ui/model/odata/ODataListBinding.js +1 -1
- package/src/sap/ui/model/odata/ODataMessageParser.js +2 -2
- package/src/sap/ui/model/odata/ODataMetaModel.js +5 -3
- package/src/sap/ui/model/odata/ODataMetadata.js +2 -2
- package/src/sap/ui/model/odata/ODataModel.js +8 -7
- package/src/sap/ui/model/odata/ODataPropertyBinding.js +1 -1
- package/src/sap/ui/model/odata/ODataTreeBinding.js +65 -33
- package/src/sap/ui/model/odata/ODataTreeBindingAdapter.js +1 -1
- package/src/sap/ui/model/odata/ODataTreeBindingFlat.js +2 -2
- package/src/sap/ui/model/odata/ODataUtils.js +13 -11
- package/src/sap/ui/model/odata/OperationMode.js +1 -1
- package/src/sap/ui/model/odata/_AnnotationHelperExpression.js +1 -1
- package/src/sap/ui/model/odata/type/Boolean.js +1 -1
- package/src/sap/ui/model/odata/type/Byte.js +1 -1
- package/src/sap/ui/model/odata/type/Currency.js +1 -1
- package/src/sap/ui/model/odata/type/Date.js +1 -1
- package/src/sap/ui/model/odata/type/DateTime.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeBase.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
- package/src/sap/ui/model/odata/type/Decimal.js +1 -1
- package/src/sap/ui/model/odata/type/Double.js +1 -1
- package/src/sap/ui/model/odata/type/Guid.js +1 -1
- package/src/sap/ui/model/odata/type/Int.js +1 -1
- package/src/sap/ui/model/odata/type/Int16.js +1 -1
- package/src/sap/ui/model/odata/type/Int32.js +1 -1
- package/src/sap/ui/model/odata/type/Int64.js +1 -1
- package/src/sap/ui/model/odata/type/ODataType.js +1 -1
- package/src/sap/ui/model/odata/type/Raw.js +1 -1
- package/src/sap/ui/model/odata/type/SByte.js +1 -1
- package/src/sap/ui/model/odata/type/Single.js +1 -1
- package/src/sap/ui/model/odata/type/Stream.js +1 -1
- package/src/sap/ui/model/odata/type/String.js +1 -1
- package/src/sap/ui/model/odata/type/Time.js +1 -1
- package/src/sap/ui/model/odata/type/TimeOfDay.js +1 -1
- package/src/sap/ui/model/odata/type/Unit.js +1 -1
- package/src/sap/ui/model/odata/v2/Context.js +81 -9
- package/src/sap/ui/model/odata/v2/ODataAnnotations.js +3 -3
- package/src/sap/ui/model/odata/v2/ODataContextBinding.js +39 -49
- package/src/sap/ui/model/odata/v2/ODataListBinding.js +236 -73
- package/src/sap/ui/model/odata/v2/ODataModel.js +314 -164
- package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +110 -97
- package/src/sap/ui/model/odata/v2/_CreatedContextsCache.js +129 -0
- package/src/sap/ui/model/odata/v4/Context.js +6 -3
- package/src/sap/ui/model/odata/v4/ODataBinding.js +5 -6
- package/src/sap/ui/model/odata/v4/ODataContextBinding.js +117 -40
- package/src/sap/ui/model/odata/v4/ODataListBinding.js +95 -15
- package/src/sap/ui/model/odata/v4/ODataMetaModel.js +44 -31
- package/src/sap/ui/model/odata/v4/ODataModel.js +86 -78
- package/src/sap/ui/model/odata/v4/ODataParentBinding.js +47 -28
- package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +11 -7
- package/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js +10 -3
- package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +8 -1
- package/src/sap/ui/model/odata/v4/lib/_Cache.js +24 -16
- package/src/sap/ui/model/odata/v4/lib/_Helper.js +32 -30
- package/src/sap/ui/model/odata/v4/lib/_Requestor.js +52 -17
- package/src/sap/ui/model/odata/v4/lib/_V2Requestor.js +2 -2
- package/src/sap/ui/model/resource/ResourceModel.js +6 -2
- package/src/sap/ui/model/resource/ResourcePropertyBinding.js +1 -1
- package/src/sap/ui/model/type/Boolean.js +2 -2
- package/src/sap/ui/model/type/Currency.js +2 -2
- package/src/sap/ui/model/type/Date.js +9 -3
- package/src/sap/ui/model/type/DateInterval.js +4 -2
- package/src/sap/ui/model/type/DateTime.js +2 -2
- package/src/sap/ui/model/type/DateTimeInterval.js +2 -2
- package/src/sap/ui/model/type/FileSize.js +4 -2
- package/src/sap/ui/model/type/Float.js +4 -2
- package/src/sap/ui/model/type/Integer.js +4 -2
- package/src/sap/ui/model/type/String.js +2 -2
- package/src/sap/ui/model/type/Time.js +2 -2
- package/src/sap/ui/model/type/TimeInterval.js +2 -2
- package/src/sap/ui/model/type/Unit.js +14 -7
- package/src/sap/ui/model/xml/XMLListBinding.js +15 -9
- package/src/sap/ui/model/xml/XMLModel.js +70 -41
- package/src/sap/ui/model/xml/XMLPropertyBinding.js +4 -4
- package/src/sap/ui/model/xml/XMLTreeBinding.js +5 -4
- package/src/sap/ui/performance/trace/Interaction.js +30 -15
- package/src/sap/ui/performance/trace/initTraces.js +1 -1
- package/src/sap/ui/qunit/QUnitUtils.js +3 -2
- package/src/sap/ui/qunit/utils/ControlIterator.js +1 -1
- package/src/sap/ui/qunit/utils/MemoryLeakCheck.js +9 -11
- package/src/sap/ui/test/TestUtils.js +11 -4
- package/src/sap/ui/test/actions/Drag.js +6 -2
- package/src/sap/ui/test/actions/Drop.js +6 -2
- package/src/sap/ui/test/actions/EnterText.js +6 -0
- package/src/sap/ui/test/actions/Press.js +6 -0
- package/src/sap/ui/test/actions/Scroll.js +6 -0
- package/src/sap/ui/test/autowaiter/_resourceWaiter.js +4 -4
- package/src/sap/ui/test/launchers/componentLauncher.js +0 -4
- package/src/sap/ui/test/matchers/I18NText.js +29 -11
- package/src/sap/ui/test/opaQunit.js +5 -0
- package/src/sap/ui/thirdparty/crossroads.js +6 -4
- package/src/sap/ui/thirdparty/hyphenopoly/Hyphenopoly.js +1196 -0
- package/src/sap/ui/thirdparty/hyphenopoly/Hyphenopoly_Loader.js +797 -0
- package/src/sap/ui/thirdparty/hyphenopoly/hyphenEngine.asm.js +108 -127
- package/src/sap/ui/thirdparty/hyphenopoly/hyphenEngine.wasm +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/bg.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/ca.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/da.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/de.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/el-monoton.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/en-us.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/es.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/et.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/fi.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/fr.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/hi.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/hr.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/hu.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/it.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/lt.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/nb-no.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/nl.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/pt.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/ru.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/sl.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/sv.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/th.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/tr.hpb +0 -0
- package/src/sap/ui/thirdparty/hyphenopoly/patterns/uk.hpb +0 -0
- package/src/sap/ui/thirdparty/jquery.js +9 -1
- package/src/sap/ui/thirdparty/qunit-2.js +1 -1
- package/src/sap/ui/thirdparty/qunit.js +1 -1
- package/src/sap/ui/util/Mobile.js +2 -20
- package/src/sap/ui/util/Storage.js +1 -1
- package/src/sap/ui/util/isCrossOriginURL.js +16 -6
- package/src/sap-ui-core-nojQuery.js +1 -1
- package/src/sap-ui-core.js +1 -1
- package/src/sap-ui-debug.js +3 -17
- package/ui5.yaml +5 -2
- package/src/sap/ui/core/support/plugins/MessageTest.js +0 -96
- package/src/sap/ui/thirdparty/hyphenopoly/hyphenopoly.bundle.js +0 -860
|
@@ -50,10 +50,8 @@ sap.ui.define([
|
|
|
50
50
|
*/
|
|
51
51
|
_display: function (vData, oSequencePromise, oTargetCreateInfo) {
|
|
52
52
|
if (this._oParent) {
|
|
53
|
-
// replace the sync
|
|
54
53
|
oSequencePromise = this._oParent._display(vData, oSequencePromise, Object.assign({}, oTargetCreateInfo));
|
|
55
54
|
}
|
|
56
|
-
|
|
57
55
|
return this._place(vData, oSequencePromise, oTargetCreateInfo);
|
|
58
56
|
},
|
|
59
57
|
|
|
@@ -215,284 +213,372 @@ sap.ui.define([
|
|
|
215
213
|
},
|
|
216
214
|
|
|
217
215
|
/**
|
|
218
|
-
*
|
|
216
|
+
* Load the target and wait for the first <code>routeMatched</code> event if it's a Component target
|
|
219
217
|
*
|
|
220
|
-
* @param {object}
|
|
221
|
-
*
|
|
222
|
-
*
|
|
223
|
-
* @param {object} oTargetCreateInfo Additional information for the component creation. Currently the object only contains the prefix for the routerHashChanger
|
|
224
|
-
* @return {Promise} resolves with {name: *, view: *, control: *} if the target can be successfully displayed otherwise it rejects with an error message
|
|
218
|
+
* @param {object} oTargetCreateInfo The corresponding target create info
|
|
219
|
+
* @return {Promise} Promise resolving with the loaded target object and the promise that waits for the
|
|
220
|
+
* <code>routeMatched</code> event in case of a Component target
|
|
225
221
|
* @private
|
|
226
222
|
*/
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
223
|
+
load: function(oTargetCreateInfo) {
|
|
224
|
+
return this._load(oTargetCreateInfo)
|
|
225
|
+
.then(function (oLoadedTarget) {
|
|
226
|
+
return {
|
|
227
|
+
object: oLoadedTarget,
|
|
228
|
+
nestedComponentReady: this.waitForComponentTarget({
|
|
229
|
+
target: oLoadedTarget,
|
|
230
|
+
createInfo: oTargetCreateInfo
|
|
231
|
+
})
|
|
232
|
+
};
|
|
233
|
+
}.bind(this));
|
|
234
|
+
},
|
|
233
235
|
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
236
|
+
/**
|
|
237
|
+
* Wait for the next <code>routeMatched</code> event from the Component target
|
|
238
|
+
*
|
|
239
|
+
* @param {object} mTargetOptions The option object that contains the loaded target object and the corresponding
|
|
240
|
+
* target create info.
|
|
241
|
+
* @return {Promise} Promise resolving when the first <code>routeMatched</code> event is fired when the target
|
|
242
|
+
* has type "Component" otherwise the Promise resolves immediately
|
|
243
|
+
* @private
|
|
244
|
+
*/
|
|
245
|
+
waitForComponentTarget: function(mTargetOptions) {
|
|
246
|
+
return new Promise(function(resolve, reject) {
|
|
247
|
+
var oLoadedTarget = mTargetOptions.target;
|
|
248
|
+
var oTargetCreateInfo = mTargetOptions.createInfo;
|
|
249
|
+
var bInstantResolve = true;
|
|
250
|
+
|
|
251
|
+
if (oLoadedTarget.isA("sap.ui.core.UIComponent")) {
|
|
252
|
+
var oRouter = oLoadedTarget.getRouter();
|
|
253
|
+
if (oRouter && oLoadedTarget.hasNativeRouter()) {
|
|
254
|
+
var sHash = oRouter.getHashChanger().getHash();
|
|
255
|
+
var oRoute = oRouter.getRouteByHash(sHash);
|
|
256
|
+
var bIgnoreInitialHash = oTargetCreateInfo && oTargetCreateInfo.ignoreInitialHash;
|
|
257
|
+
|
|
258
|
+
if (!oRouter._oConfig.async){
|
|
259
|
+
throw new Error("The router of component '" + oLoadedTarget.getId() +
|
|
260
|
+
"' which is loaded via the target '" + this._oOptions._name +
|
|
261
|
+
"' is defined as synchronous which is not supported using as a nested component.");
|
|
262
|
+
}
|
|
241
263
|
|
|
242
|
-
|
|
264
|
+
if (oRouter._oOwner && oTargetCreateInfo) {
|
|
265
|
+
// update the flag once the component is displayed again after it's already loaded
|
|
266
|
+
oRouter._oOwner._bRoutingPropagateTitle = oTargetCreateInfo.propagateTitle;
|
|
267
|
+
}
|
|
243
268
|
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
269
|
+
// TODO: offer getter for target info
|
|
270
|
+
//
|
|
271
|
+
// The router is normally initialized in the UIComponent.prototype.init function and the
|
|
272
|
+
// init function should be already called before it reaches this place which means that the
|
|
273
|
+
// router is initialized in most of the cases. If a router is already initialized, we still
|
|
274
|
+
// need to check whether the route match process is finished. If it's not finished, we are
|
|
275
|
+
// sure that there will be a "routeMatched" event fired and we can wait for it.
|
|
276
|
+
if (!bIgnoreInitialHash && (!oRouter.isInitialized() || oRouter._bMatchingProcessStarted) && oRoute && oRoute._oConfig.target) {
|
|
277
|
+
bInstantResolve = false;
|
|
278
|
+
oRouter.attachRouteMatched(resolve);
|
|
279
|
+
}
|
|
280
|
+
if (oRouter.isStopped()) {
|
|
281
|
+
// initialize the router in nested component
|
|
282
|
+
// if it has been previously stopped
|
|
283
|
+
oRouter.initialize(bIgnoreInitialHash);
|
|
284
|
+
}
|
|
285
|
+
}
|
|
250
286
|
}
|
|
251
|
-
pLoaded = this._load(oTargetCreateInfo).then(function (oObject) {
|
|
252
|
-
if (oObject.isA("sap.ui.core.UIComponent")) {
|
|
253
|
-
var oRouter = oObject.getRouter();
|
|
254
|
-
if (oRouter && oObject.hasNativeRouter()) {
|
|
255
|
-
var sHash = oRouter.getHashChanger().getHash();
|
|
256
|
-
var oRoute = oRouter.getRouteByHash(sHash);
|
|
257
|
-
var bIgnoreInitialHash = oTargetCreateInfo && oTargetCreateInfo.ignoreInitialHash;
|
|
258
|
-
|
|
259
|
-
if (!oRouter._oConfig.async){
|
|
260
|
-
throw new Error("The router of component '" + oObject.getId() +
|
|
261
|
-
"' which is loaded via the target '" + that._oOptions._name +
|
|
262
|
-
"' is defined as synchronous which is not supported using as a nested component.");
|
|
263
|
-
}
|
|
264
287
|
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
288
|
+
if (bInstantResolve) {
|
|
289
|
+
resolve();
|
|
290
|
+
}
|
|
291
|
+
}.bind(this));
|
|
292
|
+
},
|
|
293
|
+
|
|
294
|
+
/**
|
|
295
|
+
* Find the container control in the following order:
|
|
296
|
+
* <ul>
|
|
297
|
+
* <li>Within the parent target in case <code>oParentInfo</code> is given</li>
|
|
298
|
+
* <li>Within the root view of the owner component</li>
|
|
299
|
+
* <li>Using the given control ID in the global scope</li>
|
|
300
|
+
* </ul>
|
|
301
|
+
*
|
|
302
|
+
* @param {object} [oParentInfo] The view information from the displayed parent target
|
|
303
|
+
* @return {Promise} Promise resolving with the container control
|
|
304
|
+
* @private
|
|
305
|
+
*/
|
|
306
|
+
resolveContainerControl: function(oParentInfo) {
|
|
307
|
+
// use a Promise.resovle() to delay the container resolve to occur after the current call stack because the
|
|
308
|
+
// oOptions.rootView can be available after the current call stack.
|
|
309
|
+
return Promise.resolve().then(function() {
|
|
310
|
+
oParentInfo = oParentInfo || {};
|
|
311
|
+
|
|
312
|
+
var oOptions = this._oOptions;
|
|
313
|
+
var vValid = this._isValid(oParentInfo);
|
|
314
|
+
var sErrorMessage;
|
|
315
|
+
|
|
316
|
+
// validate config and log errors if necessary
|
|
317
|
+
if (vValid !== true) {
|
|
318
|
+
sErrorMessage = vValid;
|
|
319
|
+
return this._refuseInvalidTarget(oOptions._name, sErrorMessage);
|
|
320
|
+
}
|
|
269
321
|
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
322
|
+
var oViewContainingTheControl = oParentInfo.view,
|
|
323
|
+
oControl = oParentInfo.control,
|
|
324
|
+
pViewContainingTheControl,
|
|
325
|
+
pContainerControl;
|
|
326
|
+
|
|
327
|
+
// if the parent target loads a component, the oViewContainingTheControl is an instance of
|
|
328
|
+
// ComponentContainer. The root control of the component should be retrieved and set as
|
|
329
|
+
// oViewContainingTheControl
|
|
330
|
+
if (oViewContainingTheControl && oViewContainingTheControl.isA("sap.ui.core.ComponentContainer")) {
|
|
331
|
+
oViewContainingTheControl = oViewContainingTheControl.getComponentInstance().getRootControl();
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
//no parent view - see if container can be found by using oOptions.controlId under oOptions.rootView
|
|
335
|
+
if (!oViewContainingTheControl && oOptions.rootView) {
|
|
336
|
+
// oOptions.rootView can be either an id or a promise that resolves with the id
|
|
337
|
+
pViewContainingTheControl = Promise.resolve(oOptions.rootView)
|
|
338
|
+
.then(function(oRootViewId) {
|
|
339
|
+
var oView;
|
|
340
|
+
|
|
341
|
+
if (oRootViewId) {
|
|
342
|
+
oView = sap.ui.getCore().byId(oRootViewId);
|
|
343
|
+
oOptions.rootView = oRootViewId;
|
|
280
344
|
}
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
345
|
+
|
|
346
|
+
if (!oView) {
|
|
347
|
+
sErrorMessage = "Did not find the root view with the id " + oOptions.rootView;
|
|
348
|
+
return this._refuseInvalidTarget(oOptions._name, sErrorMessage);
|
|
349
|
+
} else {
|
|
350
|
+
return oView;
|
|
285
351
|
}
|
|
286
|
-
}
|
|
287
|
-
|
|
352
|
+
}.bind(this));
|
|
353
|
+
} else {
|
|
354
|
+
pViewContainingTheControl = Promise.resolve(oViewContainingTheControl);
|
|
355
|
+
}
|
|
288
356
|
|
|
289
|
-
|
|
290
|
-
|
|
357
|
+
pViewContainingTheControl = pViewContainingTheControl.then(function(oView) {
|
|
358
|
+
if (oView && oView.isA("sap.ui.core.mvc.View")) {
|
|
359
|
+
return oView.loaded();
|
|
360
|
+
} else {
|
|
361
|
+
return oView;
|
|
291
362
|
}
|
|
292
|
-
return oObject;
|
|
293
363
|
});
|
|
294
|
-
// when target information is given
|
|
295
|
-
oSequencePromise = oSequencePromise
|
|
296
|
-
.then(function(oParentInfo) {
|
|
297
|
-
oParentInfo = oParentInfo || {};
|
|
298
364
|
|
|
299
|
-
|
|
365
|
+
if (oOptions.controlId) {
|
|
366
|
+
pContainerControl = pViewContainingTheControl.then(function(oContainerView) {
|
|
367
|
+
var oContainerControl;
|
|
300
368
|
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
sErrorMessage = vValid;
|
|
304
|
-
return that._refuseInvalidTarget(oOptions._name, sErrorMessage);
|
|
369
|
+
if (oContainerView) {
|
|
370
|
+
oContainerControl = oContainerView.byId(oOptions.controlId);
|
|
305
371
|
}
|
|
306
372
|
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
pContainerControl;
|
|
311
|
-
|
|
312
|
-
// if the parent target loads a component, the oViewContainingTheControl is an instance of
|
|
313
|
-
// ComponentContainer. The root control of the component should be retrieved and set as
|
|
314
|
-
// oViewContainingTheControl
|
|
315
|
-
if (oViewContainingTheControl && oViewContainingTheControl.isA("sap.ui.core.ComponentContainer")) {
|
|
316
|
-
oViewContainingTheControl = oViewContainingTheControl.getComponentInstance().getRootControl();
|
|
373
|
+
if (!oContainerControl) {
|
|
374
|
+
//Test if control exists in core (without prefix) since it was not found in the parent or root view
|
|
375
|
+
oContainerControl = sap.ui.getCore().byId(oOptions.controlId);
|
|
317
376
|
}
|
|
318
377
|
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
var oView;
|
|
325
|
-
|
|
326
|
-
if (oRootViewId) {
|
|
327
|
-
oView = sap.ui.getCore().byId(oRootViewId);
|
|
328
|
-
oOptions.rootView = oRootViewId;
|
|
329
|
-
}
|
|
330
|
-
|
|
331
|
-
if (!oView) {
|
|
332
|
-
sErrorMessage = "Did not find the root view with the id " + oOptions.rootView;
|
|
333
|
-
return that._refuseInvalidTarget(oOptions._name, sErrorMessage);
|
|
334
|
-
} else {
|
|
335
|
-
return oView;
|
|
336
|
-
}
|
|
337
|
-
});
|
|
338
|
-
} else {
|
|
339
|
-
pViewContainingTheControl = Promise.resolve(oViewContainingTheControl);
|
|
340
|
-
}
|
|
378
|
+
return oContainerControl;
|
|
379
|
+
});
|
|
380
|
+
} else {
|
|
381
|
+
pContainerControl = Promise.resolve(oControl);
|
|
382
|
+
}
|
|
341
383
|
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
384
|
+
return pContainerControl.then(function(oContainerControl) {
|
|
385
|
+
if (!oContainerControl) {
|
|
386
|
+
sErrorMessage = "Control with ID " + oOptions.controlId + " could not be found";
|
|
387
|
+
return this._refuseInvalidTarget(oOptions._name, sErrorMessage);
|
|
388
|
+
} else {
|
|
389
|
+
return oContainerControl;
|
|
390
|
+
}
|
|
391
|
+
}.bind(this));
|
|
392
|
+
}.bind(this));
|
|
393
|
+
},
|
|
349
394
|
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
395
|
+
/**
|
|
396
|
+
* Create and display the placeholder on the respective container
|
|
397
|
+
*
|
|
398
|
+
* @param {object} oTargetCreateInfo Object containing the target create info
|
|
399
|
+
* @param {object} oContainerControl The container control
|
|
400
|
+
* @returns {object} the view info object
|
|
401
|
+
* @private
|
|
402
|
+
*/
|
|
403
|
+
displayPlaceholder: function(oTargetCreateInfo, oContainerControl) {
|
|
404
|
+
var oObject,
|
|
405
|
+
oOptions = this._oOptions,
|
|
406
|
+
bIsComponentTarget = oOptions.type === "Component",
|
|
407
|
+
bHasPlaceholderConfig = false,
|
|
408
|
+
oPlaceholderConfig = oTargetCreateInfo.placeholder || oOptions.placeholder || {},
|
|
409
|
+
pPlaceholder = Promise.resolve();
|
|
410
|
+
|
|
411
|
+
if (Placeholder.hasProviders()) {
|
|
412
|
+
Object.assign(oPlaceholderConfig, Placeholder.getPlaceholderFromProviders({
|
|
413
|
+
name: oOptions.name,
|
|
414
|
+
type: oOptions.type
|
|
415
|
+
}));
|
|
416
|
+
}
|
|
353
417
|
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
418
|
+
if (Object.keys(oPlaceholderConfig).length > 0) {
|
|
419
|
+
if (oPlaceholderConfig.autoClose === undefined) {
|
|
420
|
+
oPlaceholderConfig.autoClose = true;
|
|
421
|
+
}
|
|
422
|
+
bHasPlaceholderConfig = true;
|
|
423
|
+
}
|
|
357
424
|
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
}
|
|
425
|
+
if (bIsComponentTarget) {
|
|
426
|
+
var oOwnerComponent = this._oCache._oComponent;
|
|
427
|
+
var sComponentContainerId = oTargetCreateInfo.componentId + "-container";
|
|
362
428
|
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
} else {
|
|
366
|
-
pContainerControl = Promise.resolve(oControl);
|
|
367
|
-
}
|
|
429
|
+
oObject = (oOwnerComponent && oOwnerComponent.byId(sComponentContainerId))
|
|
430
|
+
|| sap.ui.getCore().byId(sComponentContainerId);
|
|
368
431
|
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
432
|
+
if (!oObject) {
|
|
433
|
+
// defaults mixed in with configured settings
|
|
434
|
+
var oContainerOptions = Object.assign({
|
|
435
|
+
height: "100%",
|
|
436
|
+
width: "100%",
|
|
437
|
+
lifecycle: ComponentLifecycle.Application
|
|
438
|
+
}, oOptions.containerOptions);
|
|
439
|
+
|
|
440
|
+
if (oOwnerComponent) {
|
|
441
|
+
oOwnerComponent.runAsOwner(function() {
|
|
442
|
+
oObject = new ComponentContainer(oOwnerComponent.createId(sComponentContainerId), oContainerOptions);
|
|
376
443
|
});
|
|
377
|
-
}
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
if (Placeholder.hasProviders()) {
|
|
383
|
-
Object.assign(oPlaceholderConfig, Placeholder.getPlaceholderFromProviders({
|
|
384
|
-
name: that._oOptions.name,
|
|
385
|
-
type: that._oOptions.type
|
|
386
|
-
})
|
|
387
|
-
);
|
|
388
|
-
}
|
|
444
|
+
} else {
|
|
445
|
+
oObject = new ComponentContainer(sComponentContainerId, oContainerOptions);
|
|
446
|
+
}
|
|
447
|
+
}
|
|
389
448
|
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
}
|
|
449
|
+
// set container object only if placeholder config is available
|
|
450
|
+
if (bHasPlaceholderConfig) {
|
|
451
|
+
oPlaceholderConfig.container = oObject;
|
|
452
|
+
}
|
|
453
|
+
}
|
|
396
454
|
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
oObject = (oOwnerComponent && oOwnerComponent.byId(sComponentContainerId))
|
|
402
|
-
|| sap.ui.getCore().byId(sComponentContainerId);
|
|
403
|
-
|
|
404
|
-
if (!oObject) {
|
|
405
|
-
// defaults mixed in with configured settings
|
|
406
|
-
var oContainerOptions = Object.assign({
|
|
407
|
-
height: "100%",
|
|
408
|
-
width: "100%",
|
|
409
|
-
lifecycle: ComponentLifecycle.Application
|
|
410
|
-
}, oOptions.containerOptions);
|
|
411
|
-
|
|
412
|
-
if (oOwnerComponent) {
|
|
413
|
-
oOwnerComponent.runAsOwner(function() {
|
|
414
|
-
oObject = new ComponentContainer(oOwnerComponent.createId(sComponentContainerId), oContainerOptions);
|
|
415
|
-
});
|
|
416
|
-
} else {
|
|
417
|
-
oObject = new ComponentContainer(sComponentContainerId, oContainerOptions);
|
|
418
|
-
}
|
|
419
|
-
}
|
|
455
|
+
// for view targets use container control to display placeholder
|
|
456
|
+
if (bHasPlaceholderConfig && oContainerControl.isA("sap.ui.core.IPlaceholderSupport")) {
|
|
457
|
+
oPlaceholderConfig.container = oContainerControl;
|
|
458
|
+
}
|
|
420
459
|
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
}
|
|
425
|
-
}
|
|
460
|
+
// Placeholder creation
|
|
461
|
+
if (oPlaceholderConfig.container && !oTargetCreateInfo.repeatedRoute) {
|
|
462
|
+
oPlaceholderConfig.aggregation = this._oOptions.controlAggregation;
|
|
426
463
|
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
oPlaceholderConfig.container = oContainerControl;
|
|
430
|
-
}
|
|
464
|
+
var oCreateOptions = this._getCreateOptions(oTargetCreateInfo);
|
|
465
|
+
var oCachedObject = this._oCache.fetch(oCreateOptions, this._oOptions.type);
|
|
431
466
|
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
467
|
+
if (oCachedObject && bIsComponentTarget) {
|
|
468
|
+
// for type "Component", the object that is saved in the placeholder config should be
|
|
469
|
+
// the component container instead of the component
|
|
470
|
+
oPlaceholderConfig.object = oObject;
|
|
471
|
+
} else {
|
|
472
|
+
oPlaceholderConfig.object = oCachedObject;
|
|
473
|
+
}
|
|
435
474
|
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
475
|
+
if (oPlaceholderConfig.html) {
|
|
476
|
+
oPlaceholderConfig.placeholder = new Placeholder({
|
|
477
|
+
html: oPlaceholderConfig.html
|
|
478
|
+
});
|
|
479
|
+
}
|
|
439
480
|
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
} else {
|
|
445
|
-
oPlaceholderConfig.object = oCachedObject;
|
|
446
|
-
}
|
|
447
|
-
}
|
|
481
|
+
if (oPlaceholderConfig.placeholder && sap.ui.getCore().getConfiguration().getPlaceholder()) {
|
|
482
|
+
pPlaceholder = this.showPlaceholder(oPlaceholderConfig);
|
|
483
|
+
}
|
|
484
|
+
}
|
|
448
485
|
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
486
|
+
// wait for placeholder to load
|
|
487
|
+
return pPlaceholder.then(function(sPlaceholderContent) {
|
|
488
|
+
// returning view info object
|
|
489
|
+
return {
|
|
490
|
+
containerControl: oContainerControl,
|
|
491
|
+
object: oObject,
|
|
492
|
+
placeholderConfig: oPlaceholderConfig,
|
|
493
|
+
placeholderShown: !!sPlaceholderContent
|
|
494
|
+
};
|
|
495
|
+
});
|
|
496
|
+
},
|
|
454
497
|
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
498
|
+
/**
|
|
499
|
+
* Here the magic happens - recursion + placement + view creation needs to be refactored
|
|
500
|
+
*
|
|
501
|
+
* @param {object} [vData] an object that will be passed to the display event in the data property. If the
|
|
502
|
+
* target has parents, the data will also be passed to them.
|
|
503
|
+
* @param {Promise} oSequencePromise Promise chain for resolution in the correct order
|
|
504
|
+
* @param {object} oTargetCreateInfo Additional information for the component creation. Currently the object only contains the prefix for the routerHashChanger
|
|
505
|
+
* @return {Promise} resolves with {name: *, view: *, control: *} if the target can be successfully displayed otherwise it rejects with an error message
|
|
506
|
+
* @private
|
|
507
|
+
*/
|
|
508
|
+
_place: function (vData, oSequencePromise, oTargetCreateInfo) {
|
|
509
|
+
var oOptions = this._oOptions,
|
|
510
|
+
that = this,
|
|
511
|
+
sErrorMessage,
|
|
512
|
+
bIsComponentTarget = oOptions.type === "Component";
|
|
459
513
|
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
514
|
+
var pLoaded, /* target is loaded and promise for waiting on "routeMatched" event in nested component is ready*/
|
|
515
|
+
pContainerReady; /* container control and placeholder ready */
|
|
516
|
+
|
|
517
|
+
if (vData instanceof Promise) {
|
|
518
|
+
oTargetCreateInfo = oSequencePromise;
|
|
519
|
+
oSequencePromise = vData;
|
|
520
|
+
vData = undefined;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
oTargetCreateInfo = oTargetCreateInfo || {};
|
|
524
|
+
|
|
525
|
+
if (bIsComponentTarget) {
|
|
526
|
+
oTargetCreateInfo.componentId = oOptions.id || ManagedObjectMetadata.uid("uicomponent");
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
if ((oOptions.name || oOptions.usage) && oOptions.type) {
|
|
530
|
+
// target loading
|
|
531
|
+
pLoaded = this.load(oTargetCreateInfo);
|
|
532
|
+
|
|
533
|
+
// Either if parent available, then we need to wait until the parent got displayed or
|
|
534
|
+
// if no target info is given, then we need to wait for the oSequencePromise to be resolved
|
|
535
|
+
if (this._oParent || oTargetCreateInfo.legacy) {
|
|
536
|
+
// resolve container control and placeholder creation
|
|
537
|
+
pContainerReady = oSequencePromise.then(this.resolveContainerControl.bind(this));
|
|
538
|
+
} else {
|
|
539
|
+
// no need to wait for oSequencePromise, resolve container control in parallel
|
|
540
|
+
pContainerReady = this.resolveContainerControl();
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
pContainerReady = pContainerReady.then(this.displayPlaceholder.bind(this, oTargetCreateInfo));
|
|
544
|
+
|
|
545
|
+
// when target information is given
|
|
546
|
+
oSequencePromise = Promise.all([pLoaded, pContainerReady, oSequencePromise])
|
|
547
|
+
// prepareTitleProvider
|
|
548
|
+
.then(function(aArguments) {
|
|
549
|
+
var oObject = aArguments[0].object,
|
|
550
|
+
oViewInfo = aArguments[1],
|
|
551
|
+
oView, oRootControl;
|
|
552
|
+
|
|
553
|
+
oViewInfo.nestedComponentReady = aArguments[0].nestedComponentReady;
|
|
554
|
+
|
|
555
|
+
if (bIsComponentTarget) {
|
|
556
|
+
var fnOriginalDestroy = oObject.destroy;
|
|
557
|
+
oObject.destroy = function () {
|
|
558
|
+
if (fnOriginalDestroy) {
|
|
559
|
+
fnOriginalDestroy.apply(this);
|
|
483
560
|
}
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
561
|
+
// destroy the component container when the component is destroyed
|
|
562
|
+
oViewInfo.object.destroy();
|
|
563
|
+
};
|
|
564
|
+
oViewInfo.object.setComponent(oObject);
|
|
565
|
+
|
|
566
|
+
oRootControl = oObject.getRootControl();
|
|
567
|
+
if (oRootControl && oRootControl.isA("sap.ui.core.mvc.View")) {
|
|
568
|
+
oView = oRootControl;
|
|
488
569
|
}
|
|
570
|
+
} else {
|
|
571
|
+
// view
|
|
572
|
+
oViewInfo.object = oObject;
|
|
573
|
+
oView = oObject;
|
|
574
|
+
}
|
|
489
575
|
|
|
490
|
-
|
|
491
|
-
|
|
576
|
+
that._bindTitleInTitleProvider(oView);
|
|
577
|
+
that._addTitleProviderAsDependent(oView);
|
|
492
578
|
|
|
493
|
-
|
|
494
|
-
});
|
|
579
|
+
return oViewInfo;
|
|
495
580
|
})
|
|
581
|
+
// placing the view or component into container
|
|
496
582
|
.then(function(oViewInfo) {
|
|
497
583
|
var oContainerControl = oViewInfo.containerControl,
|
|
498
584
|
oObject = oViewInfo.object;
|
|
@@ -529,7 +615,9 @@ sap.ui.define([
|
|
|
529
615
|
name: oOptions._name,
|
|
530
616
|
view: oObject,
|
|
531
617
|
control: oContainerControl,
|
|
532
|
-
|
|
618
|
+
nestedComponentReady: oViewInfo.nestedComponentReady,
|
|
619
|
+
placeholderConfig: oViewInfo.placeholderConfig,
|
|
620
|
+
placeholderShown: oViewInfo.placeholderShown
|
|
533
621
|
};
|
|
534
622
|
});
|
|
535
623
|
} else {
|
|
@@ -540,33 +628,39 @@ sap.ui.define([
|
|
|
540
628
|
});
|
|
541
629
|
}
|
|
542
630
|
|
|
543
|
-
return
|
|
544
|
-
var
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
view : oObject.isA("sap.ui.core.mvc.View") ? oObject : undefined,
|
|
550
|
-
object: oObject,
|
|
551
|
-
control : oContainerControl,
|
|
552
|
-
config : that._oOptions,
|
|
553
|
-
data: vData,
|
|
554
|
-
routeRelevant: oTargetCreateInfo.routeRelevant
|
|
555
|
-
});
|
|
556
|
-
}
|
|
631
|
+
return oSequencePromise.then(function(oParams) {
|
|
632
|
+
var pNestedComponentReady = oParams.nestedComponentReady || Promise.resolve();
|
|
633
|
+
return pNestedComponentReady.then(function() {
|
|
634
|
+
var oContainerControl = oParams.control,
|
|
635
|
+
oObject = oParams.view,
|
|
636
|
+
oPlaceholderConfig = oParams.placeholderConfig;
|
|
557
637
|
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
638
|
+
if (oContainerControl && oObject) {
|
|
639
|
+
that.fireDisplay({
|
|
640
|
+
view : oObject.isA("sap.ui.core.mvc.View") ? oObject : undefined,
|
|
641
|
+
object: oObject,
|
|
642
|
+
control : oContainerControl,
|
|
643
|
+
config : that._oOptions,
|
|
644
|
+
data: vData,
|
|
645
|
+
routeRelevant: oTargetCreateInfo.routeRelevant
|
|
646
|
+
});
|
|
647
|
+
}
|
|
648
|
+
|
|
649
|
+
if (oPlaceholderConfig && oPlaceholderConfig.container &&
|
|
650
|
+
oPlaceholderConfig.autoClose && that.hidePlaceholder) {
|
|
651
|
+
that.hidePlaceholder(oPlaceholderConfig);
|
|
652
|
+
}
|
|
562
653
|
|
|
563
|
-
|
|
654
|
+
return oParams;
|
|
655
|
+
});
|
|
564
656
|
});
|
|
565
657
|
},
|
|
566
658
|
|
|
567
659
|
showPlaceholder: function(mSettings) {
|
|
568
660
|
if (mSettings.container && mSettings.container.showPlaceholder) {
|
|
569
|
-
mSettings.container.showPlaceholder(mSettings);
|
|
661
|
+
return mSettings.container.showPlaceholder(mSettings);
|
|
662
|
+
} else {
|
|
663
|
+
return Promise.resolve();
|
|
570
664
|
}
|
|
571
665
|
},
|
|
572
666
|
|