@sapui5/sap.ushell 1.122.1 → 1.123.0
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/package.json +1 -1
- package/src/main/js/sap/ushell/.library +1 -1
- package/src/main/js/sap/ushell/Container.js +9 -1
- package/src/main/js/sap/ushell/Fiori20Adapter.js +1 -1
- package/src/main/js/sap/ushell/Fiori20AdapterTest.js +1 -1
- package/src/main/js/sap/ushell/NWBCInterface.js +1 -1
- package/src/main/js/sap/ushell/TechnicalParameters.js +1 -1
- package/src/main/js/sap/ushell/URLTemplateProcessor.js +1 -1
- package/src/main/js/sap/ushell/Ui5NativeServiceFactory.js +1 -1
- package/src/main/js/sap/ushell/Ui5ServiceFactory.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/DefinitionParameterSetBuilder.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/DependencyGraph.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/Functions.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/Resolvers.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/TemplateParameterParser.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/utils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ClientSideTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/CommonDataModelAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ConfigurationDefaultsAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ContainerAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PagesCommonDataModelAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PersonalizationAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PersonalizationV2Adapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/modifyHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/readCatalogs.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/readHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/uri.transform.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/util/AppForInbound.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/util/cdmSiteUtils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/AdapterBase.js +1 -2
- package/src/main/js/sap/ushell/adapters/cdm/v3/FlpLaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/StaticGroupsAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readApplications.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readCatalogs.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readPages.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readUtils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readVisualizations.js +1 -1
- package/src/main/js/sap/ushell/adapters/cep/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cep/NavTargetResolutionInternalAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cep/SearchCEPAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cflp/UserDefaultParameterPersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/AdapterContainer.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/AppStateAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/ClientSideTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/ContainerAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/FlpLaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/NavTargetResolutionInternalAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PageBuildingAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PagePersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PersonalizationAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PersonalizationV2Adapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SearchAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SearchCEPAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SupportTicketAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/UserDefaultParameterPersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/UserInfoAdapter.js +1 -1
- package/src/main/js/sap/ushell/api/workpage/Designtime.js +18 -0
- package/src/main/js/sap/ushell/appRuntime/ui5/AppRuntime.js +13 -2
- package/src/main/js/sap/ushell/appRuntime/ui5/renderers/fiori2/RendererExtensions.js +2 -2
- package/src/main/js/sap/ushell/appRuntime/ui5/services/AppConfiguration.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/AppLifeCycleAgent.js +18 -8
- package/src/main/js/sap/ushell/appRuntime/ui5/services/adapters/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/_SchedulingAgent/logger.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/_SchedulingAgent/state.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/cdm/cdm.constants.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/common/common.configure.ui5datetimeformat.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/common/common.create.configcontract.core.js +5 -1
- package/src/main/js/sap/ushell/bootstrap/common/common.util.js +27 -2
- package/src/main/js/sap/ushell/bootstrap/sandbox2/sandboxConfig.json +0 -5
- package/src/main/js/sap/ushell/bootstrap/sandbox2/sandboxSite.json +3 -112
- package/src/main/js/sap/ushell/bootstrap/sandbox2.js +8 -1
- package/src/main/js/sap/ushell/components/_HeaderManager/AddHeadEndItemsStrategy.js +3 -0
- package/src/main/js/sap/ushell/components/_HeaderManager/ControlManager.js +1 -1
- package/src/main/js/sap/ushell/components/appfinder/Catalog.controller.js +2 -2
- package/src/main/js/sap/ushell/components/appfinder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/AppLifeCycle.js +1 -2
- package/src/main/js/sap/ushell/components/applicationIntegration/application/Application.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/application/BlueBoxHandler.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/application/PostMessageAPI.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/configuration/AppMeta.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/elements/model.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/relatedServices/RelatedServices.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/relatedShellElements/RelatedShellElements.js +1 -1
- package/src/main/js/sap/ushell/components/container/ApplicationContainer.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/Component.js +13 -2
- package/src/main/js/sap/ushell/components/contentFinder/controller/AppSearch.controller.js +12 -5
- package/src/main/js/sap/ushell/components/contentFinder/controller/ContentFinderDialog.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/controller/WidgetGallery.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/model/formatter.js +0 -4
- package/src/main/js/sap/ushell/components/contentFinder/resources/resources.properties +2 -0
- package/src/main/js/sap/ushell/components/contentFinder/view/AppSearch.view.xml +159 -137
- package/src/main/js/sap/ushell/components/contentFinder/view/AppSearchCategoryTree.view.xml +24 -0
- package/src/main/js/sap/ushell/components/contentFinderStandalone/Component.js +31 -0
- package/src/main/js/sap/ushell/components/contentFinderStandalone/controller/ContentFinderStandalone.controller.js +146 -0
- package/src/main/js/sap/ushell/components/contentFinderStandalone/manifest.json +59 -0
- package/src/main/js/sap/ushell/components/contentFinderStandalone/manifestAppSearch.json +50 -0
- package/src/main/js/sap/ushell/components/contentFinderStandalone/view/ContentFinderStandalone.view.xml +15 -0
- package/src/main/js/sap/ushell/components/factsheet/Component.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/ActionMode.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardContent.view.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardGroupsBox.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardUIActions.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/pages/ActionMode.js +1 -1
- package/src/main/js/sap/ushell/components/pages/Component.js +1 -1
- package/src/main/js/sap/ushell/components/pages/MyHomeImport.js +1 -1
- package/src/main/js/sap/ushell/components/pages/controller/PageRuntime.controller.js +1 -1
- package/src/main/js/sap/ushell/components/pages/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/runtimeSwitcher/controller/RuntimeSwitcher.controller.js +1 -1
- package/src/main/js/sap/ushell/components/runtimeSwitcher/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/MenuBar/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/NavigationBarMenu/controller/NavigationBarMenu.controller.js +1 -1
- package/src/main/js/sap/ushell/components/shell/NavigationBarMenu/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/Notifications/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Notifications/Notifications.controller.js +0 -4
- package/src/main/js/sap/ushell/components/shell/ProductSwitch/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Search/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/FrequentActivityProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/RecentSearchProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/SearchProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/SearchServiceProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Settings/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Settings/userLanguageRegion/LanguageRegionSelector.controller.js +1 -1
- package/src/main/js/sap/ushell/components/shell/UserActionsMenu/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/UserImage/Component.js +1 -1
- package/src/main/js/sap/ushell/components/visualizationOrganizer/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controller/WorkPageBuilder.accessibility.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controller/WorkPageBuilder.controller.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPage.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageButton.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageCell.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageColumn.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageColumnResizer.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageRow.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/controller/WorkPageRuntime.controller.js +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/manifest.json +1 -1
- package/src/main/js/sap/ushell/designtime/ApplicationContainer.designtime.js +1 -1
- package/src/main/js/sap/ushell/library.js +2 -1
- package/src/main/js/sap/ushell/navigationMode.js +1 -1
- package/src/main/js/sap/ushell/performance/ShellAnalytics.js +1 -1
- package/src/main/js/sap/ushell/performance/StatisticalRecord.js +1 -1
- package/src/main/js/sap/ushell/plugins/appwarmup/Component.js +1 -1
- package/src/main/js/sap/ushell/renderer/Renderer.js +44 -32
- package/src/main/js/sap/ushell/renderer/Shell.controller.js +2 -24
- package/src/main/js/sap/ushell/renderer/search/searchComponent/manifest.json +1 -1
- package/src/main/js/sap/ushell/renderers/fiori2/Renderer.js +2 -1
- package/src/main/js/sap/ushell/services/AppConfiguration.js +26 -12
- package/src/main/js/sap/ushell/services/AppLifeCycle.js +154 -39
- package/src/main/js/sap/ushell/services/AppState.js +1 -1
- package/src/main/js/sap/ushell/services/Bookmark.js +1 -1
- package/src/main/js/sap/ushell/services/BookmarkV2.js +104 -134
- package/src/main/js/sap/ushell/services/ClientSideTargetResolution.js +1 -1
- package/src/main/js/sap/ushell/services/CommonDataModel.js +1 -1
- package/src/main/js/sap/ushell/services/Configuration.js +1 -1
- package/src/main/js/sap/ushell/services/ConfigurationDefaults.js +1 -1
- package/src/main/js/sap/ushell/services/ContentExtensionAdapterFactory.js +1 -1
- package/src/main/js/sap/ushell/services/CrossApplicationNavigation.js +1 -1
- package/src/main/js/sap/ushell/services/DarkModeSupport.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/FloatingContainer.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/Footer.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/Header.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/Item.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/SidePane.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/ToolArea.js +1 -1
- package/src/main/js/sap/ushell/services/Extension.js +1 -1
- package/src/main/js/sap/ushell/services/FlpLaunchPage.js +9 -2
- package/src/main/js/sap/ushell/services/LaunchPage.js +1 -1
- package/src/main/js/sap/ushell/services/Menu.js +1 -1
- package/src/main/js/sap/ushell/services/Message.js +1 -1
- package/src/main/js/sap/ushell/services/MessageBroker.js +1 -1
- package/src/main/js/sap/ushell/services/Navigation/utils.js +1 -1
- package/src/main/js/sap/ushell/services/Navigation.js +46 -9
- package/src/main/js/sap/ushell/services/NavigationDataProvider.js +1 -1
- package/src/main/js/sap/ushell/services/NotificationsV2.js +141 -9
- package/src/main/js/sap/ushell/services/PageBuilding.js +1 -1
- package/src/main/js/sap/ushell/services/PagePersistence.js +1 -1
- package/src/main/js/sap/ushell/services/PageReferencing.js +1 -1
- package/src/main/js/sap/ushell/services/Pages.js +58 -16
- package/src/main/js/sap/ushell/services/Personalization.js +1 -1
- package/src/main/js/sap/ushell/services/PersonalizationV2/ContextContainer.js +1 -1
- package/src/main/js/sap/ushell/services/PersonalizationV2/VariantSetAdapter.js +1 -1
- package/src/main/js/sap/ushell/services/PersonalizationV2.js +1 -1
- package/src/main/js/sap/ushell/services/PluginManager.js +1 -1
- package/src/main/js/sap/ushell/services/ReferenceResolver.js +1 -1
- package/src/main/js/sap/ushell/services/Search.js +1 -1
- package/src/main/js/sap/ushell/services/SearchCEP.js +1 -1
- package/src/main/js/sap/ushell/services/SearchableContent.js +1 -1
- package/src/main/js/sap/ushell/services/ShellNavigation.js +1 -1
- package/src/main/js/sap/ushell/services/SmartNavigation.js +1 -1
- package/src/main/js/sap/ushell/services/SpaceContent.js +38 -13
- package/src/main/js/sap/ushell/services/UITracer.js +1 -1
- package/src/main/js/sap/ushell/services/URLParsing.js +42 -20
- package/src/main/js/sap/ushell/services/URLShortening.js +1 -1
- package/src/main/js/sap/ushell/services/URLTemplate.js +1 -1
- package/src/main/js/sap/ushell/services/Ui5ComponentLoader.js +1 -1
- package/src/main/js/sap/ushell/services/UserDefaultParameterPersistence.js +1 -1
- package/src/main/js/sap/ushell/services/UserDefaultParameters.js +1 -1
- package/src/main/js/sap/ushell/services/UserInfo.js +17 -4
- package/src/main/js/sap/ushell/services/UserRecents.js +1 -1
- package/src/main/js/sap/ushell/services/VisualizationDataProvider.js +1 -1
- package/src/main/js/sap/ushell/services/VisualizationInstantiation.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Formatter.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/InboundIndex.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/InboundProvider.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/PrelaunchOperations.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Search.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/StagedLogger.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/SystemContext.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Utils.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/VirtualInbounds.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/XAppStateProcessing.js +1 -1
- package/src/main/js/sap/ushell/services/_CommonDataModel/SiteConverter.js +1 -1
- package/src/main/js/sap/ushell/services/_CommonDataModel/vizTypeDefaults/VizTypeDefaults.js +1 -1
- package/src/main/js/sap/ushell/services/_ContentExtensionAdapterFactory/ContentExtensionAdapterConfig.js +1 -1
- package/src/main/js/sap/ushell/services/_ContentExtensionAdapterFactory/FeaturedGroupConfig.js +1 -1
- package/src/main/js/sap/ushell/services/_CrossApplicationNavigation/utils.js +1 -1
- package/src/main/js/sap/ushell/services/_MessageBroker/MessageBrokerEngine.js +1 -1
- package/src/main/js/sap/ushell/services/_PageReferencing/PageReferencer.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/Extensions.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/HeaderExtensions.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/MenuExtensions.js +1 -1
- package/src/main/js/sap/ushell/services/_Ui5ComponentLoader/utils.js +34 -5
- package/src/main/js/sap/ushell/support/plugins/flpConfig/FlpConfigurationPlugin.js +1 -1
- package/src/main/js/sap/ushell/ui/AppContainer.js +44 -0
- package/src/main/js/sap/ushell/ui/appfinder/AppBoxInternal.js +3 -3
- package/src/main/js/sap/ushell/ui/appfinder/AppBoxInternalRenderer.js +103 -0
- package/src/main/js/sap/ushell/ui/appfinder/AppBoxRenderer.js +7 -98
- package/src/main/js/sap/ushell/ui/cards/RecentActivitiesExtension.js +1 -1
- package/src/main/js/sap/ushell/ui/launchpad/CatalogsContainer.js +5 -3
- package/src/main/js/sap/ushell/ui/launchpad/ExtendedChangeDetection.js +1 -1
- package/src/main/js/sap/ushell/ui/launchpad/Section.js +1 -1
- package/src/main/js/sap/ushell/ui/launchpad/ViewPortState.js +2 -1
- package/src/main/js/sap/ushell/ui/launchpad/section/CompactArea.js +1 -1
- package/src/main/js/sap/ushell/ui/shell/ToolAreaItem.js +1 -1
- package/src/main/js/sap/ushell/ui/utils.js +1 -1
- package/src/main/js/sap/ushell/ui5service/ShellUIService.js +1 -1
- package/src/main/js/sap/ushell/ui5service/UserStatus.js +1 -1
- package/src/main/js/sap/ushell/ui5service/_ShellUIService/shelluiservice.class.factory.js +30 -48
- package/src/main/js/sap/ushell/utils/UrlShortening.js +1 -1
- package/src/main/js/sap/ushell/utils/tilecard/TileCard.js +342 -0
- package/src/main/js/sap/ushell/utils/tilecard/TileCardExtension.js +384 -0
- package/src/main/js/sap/ushell/utils/tilecard/resources/resources.properties +11 -0
- package/src/main/js/sap/ushell/utils/workpage/WorkPageHost.js +1 -1
- package/src/main/js/sap/ushell/utils/workpage/WorkPageService.js +57 -4
- package/src/main/js/sap/ushell/utils/workpage/WorkPageVizInstantiation.js +44 -17
- package/src/test/js/sap/ushell/bootstrap/sandbox.js +1 -1
- package/ui5.yaml +2 -0
|
@@ -0,0 +1,342 @@
|
|
|
1
|
+
// Copyright (c) 2009-2023 SAP SE, All Rights Reserved
|
|
2
|
+
|
|
3
|
+
sap.ui.define([
|
|
4
|
+
"sap/base/Log"
|
|
5
|
+
], function (
|
|
6
|
+
Log
|
|
7
|
+
) {
|
|
8
|
+
|
|
9
|
+
"use strict";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* @alias sap.ushell.utils.tilecard.TileCard
|
|
13
|
+
* @class
|
|
14
|
+
* @classdesc Util to create a TileCardConfiguration.
|
|
15
|
+
* @since 1.123.0
|
|
16
|
+
* @private
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @typedef {object} TileCardConfiguration ConfigurationData for the pagebuilder to instaniate a card.
|
|
21
|
+
* @property {string} displayVariant The expected displayVariant for the tile card.
|
|
22
|
+
* @property {string[]} availableDisplayVariants The available display variants for the tile card.
|
|
23
|
+
* @property {boolean} error indicates if an error occured.
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
const sStaticAppLauncher = "sap.ushell.StaticAppLauncher";
|
|
27
|
+
const sDynamicAppLauncher = "sap.ushell.DynamicAppLauncher";
|
|
28
|
+
const sTileExtension = "module:sap/ushell/utils/tilecard/TileCardExtension";
|
|
29
|
+
const oLogger = Log.getLogger("sap.ushell.utils.tilecard.TileCard");
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
const errorTile = {
|
|
33
|
+
_version: "1.41.0",
|
|
34
|
+
"sap.app": {
|
|
35
|
+
id: "sap.ushell.utils.tilecard.Error",
|
|
36
|
+
type: "card",
|
|
37
|
+
applicationVersion: {
|
|
38
|
+
version: "1.123.0"
|
|
39
|
+
},
|
|
40
|
+
i18n: {
|
|
41
|
+
bundleName: "sap.ushell.utils.tilecard.resources/resources"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"sap.card": {
|
|
45
|
+
type: "List",
|
|
46
|
+
header: {
|
|
47
|
+
title: "{{TileCard.Widget.NotAvailable}}",
|
|
48
|
+
icon: {
|
|
49
|
+
src: "sap-icon://sys-cancel"
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Creates the TileCard Configuration based on the extended vizData.
|
|
57
|
+
* The configuration contains additional data, besides the descriptor.value used to initialize a
|
|
58
|
+
* card correctly.
|
|
59
|
+
* @param {TileConfigurationData} oData the extended vizData.
|
|
60
|
+
* @returns {TileCardConfiguration} The configuration object for a card.
|
|
61
|
+
* @private
|
|
62
|
+
* @since 1.123.0
|
|
63
|
+
*/
|
|
64
|
+
function createTileCardConfiguration (oData) {
|
|
65
|
+
|
|
66
|
+
let oResult;
|
|
67
|
+
try {
|
|
68
|
+
oResult = {
|
|
69
|
+
descriptor: {
|
|
70
|
+
value: createManifest(oData)
|
|
71
|
+
},
|
|
72
|
+
displayVariant: getDisplayVariant(oData.displayFormatHint || "standard"),
|
|
73
|
+
availableDisplayVariants: getAvailableDisplayVariants(oData),
|
|
74
|
+
error: false
|
|
75
|
+
};
|
|
76
|
+
// error case, not a custom tile and no descriptor
|
|
77
|
+
if (!oResult.descriptor.value) {
|
|
78
|
+
throw new Error("No custom tile and no descriptor value");
|
|
79
|
+
}
|
|
80
|
+
oLogger.debug("TileCard was initialized.", JSON.stringify(oData));
|
|
81
|
+
|
|
82
|
+
} catch (ex) {
|
|
83
|
+
oLogger.debug("TileCard cannot be initialized.", JSON.stringify(oData));
|
|
84
|
+
oLogger.info("TileCard initialization failed", ex.message);
|
|
85
|
+
oResult = {
|
|
86
|
+
descriptor: {
|
|
87
|
+
value: errorTile
|
|
88
|
+
},
|
|
89
|
+
displayVariant: getDisplayVariant(oData.displayFormatHint || "standard"),
|
|
90
|
+
availableDisplayVariants: getAvailableDisplayVariants([
|
|
91
|
+
"TileStandard",
|
|
92
|
+
"TileFlat",
|
|
93
|
+
"TileFlatWide",
|
|
94
|
+
"TileStandardWide"
|
|
95
|
+
]),
|
|
96
|
+
error: true
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
return oResult;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Creates and returns the Card manifest json for a static and dynamic tile
|
|
104
|
+
* @param {ExtendedVizData} oData the extended viz data from WorkPageVizInstantiation
|
|
105
|
+
* @returns {object | null} The manifest to be applied or null.
|
|
106
|
+
* @private
|
|
107
|
+
* @since 1.123.0
|
|
108
|
+
*/
|
|
109
|
+
function createManifest (oData) {
|
|
110
|
+
if (oData.vizType === sDynamicAppLauncher || oData.vizType === sStaticAppLauncher) {
|
|
111
|
+
// always create a Numeric header for the card
|
|
112
|
+
return getManifest(oData.vizType === sDynamicAppLauncher, oData);
|
|
113
|
+
}
|
|
114
|
+
return null;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Returns the available display variants for the given oData.
|
|
119
|
+
* If no supportedDisplayFormats are available, the TileStandard display variant is returned.
|
|
120
|
+
*
|
|
121
|
+
* @param {object} oData the vizConfig from the extended viz data.
|
|
122
|
+
* @returns {string[]} The available display variants or ["TileStandard"]
|
|
123
|
+
* @private
|
|
124
|
+
* @since 1.123.0
|
|
125
|
+
*/
|
|
126
|
+
function getAvailableDisplayVariants (oData) {
|
|
127
|
+
if (!Array.isArray(oData.supportedDisplayFormats) || oData.supportedDisplayFormats.length === 0) {
|
|
128
|
+
return ["TileStandard"];
|
|
129
|
+
}
|
|
130
|
+
const aFormats = oData.supportedDisplayFormats || [
|
|
131
|
+
"flat",
|
|
132
|
+
"standard",
|
|
133
|
+
"standardWide",
|
|
134
|
+
"flatWide",
|
|
135
|
+
"compact"
|
|
136
|
+
];
|
|
137
|
+
|
|
138
|
+
return aFormats.map(function (sFormat) {
|
|
139
|
+
return getDisplayVariant(sFormat);
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* Returns the generated TileCard manifest for the static and dynamic tile described by the given oData.
|
|
145
|
+
* @param {boolean} bDynamic true for a dynamic tile.
|
|
146
|
+
* @param {ExtendedVizData} oData the extended viz data from WorkPageVizInstantiation.
|
|
147
|
+
* @returns {object} The generated manifest.
|
|
148
|
+
* @private
|
|
149
|
+
* @since 1.123.0
|
|
150
|
+
*/
|
|
151
|
+
function getManifest (bDynamic, oData) {
|
|
152
|
+
return {
|
|
153
|
+
_version: "1.41.0",
|
|
154
|
+
"sap.app": {
|
|
155
|
+
id: oData.id,
|
|
156
|
+
type: "card",
|
|
157
|
+
tags: { keywords: oData.keywords },
|
|
158
|
+
i18n: {
|
|
159
|
+
bundleName: "sap.ushell.utils.tilecard.resources/resources"
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
"sap.ui": oData.vizConfig["sap.ui"] || {},
|
|
163
|
+
"sap.flp": oData.vizConfig["sap.flp"] || {},
|
|
164
|
+
"sap.fiori": oData.vizConfig["sap.fiori"] || {},
|
|
165
|
+
"sap.card": {
|
|
166
|
+
extension: bDynamic ? sTileExtension : "",
|
|
167
|
+
header: getHeader(bDynamic, oData),
|
|
168
|
+
type: "List",
|
|
169
|
+
configuration: {
|
|
170
|
+
parameters: {
|
|
171
|
+
dataPath: {
|
|
172
|
+
value: getDataPath(oData)
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
};
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* Returns the card header settings for the static and dynamic tile described by the given oData.
|
|
182
|
+
* @param {boolean} bDynamic true for a dynamic tile.
|
|
183
|
+
* @param {ExtendedVizData} oData the extended viz data from WorkPageVizInstantiation.
|
|
184
|
+
* @returns {object} The header settings.
|
|
185
|
+
* @private
|
|
186
|
+
* @since 1.123.0
|
|
187
|
+
*/
|
|
188
|
+
function getHeader (bDynamic, oData) {
|
|
189
|
+
// use a numeric header to allow details/info to be shown
|
|
190
|
+
const oHeaderConfig = {
|
|
191
|
+
type: "Numeric",
|
|
192
|
+
title: oData.title || "",
|
|
193
|
+
titleMaxLines: oData.subtitle ? 2 : 3, // if there is a subtitle, we have 2 lines for title, otherwise 3
|
|
194
|
+
subTitle: oData.subtitle || "", // card title is otherwise not top aligned. will be fixed to top soon.
|
|
195
|
+
subTitleMaxLines: 1,
|
|
196
|
+
wrappingType: "Hyphenated",
|
|
197
|
+
icon: {
|
|
198
|
+
src: oData.icon || "",
|
|
199
|
+
shape: "Square",
|
|
200
|
+
visible: !!oData.icon
|
|
201
|
+
},
|
|
202
|
+
actions: getNavigationAction(oData),
|
|
203
|
+
details: {
|
|
204
|
+
text: oData.info,
|
|
205
|
+
state: "None"
|
|
206
|
+
},
|
|
207
|
+
banner: oData.displayProviderLabel ? [
|
|
208
|
+
{
|
|
209
|
+
text: oData.contentProviderLabel
|
|
210
|
+
}
|
|
211
|
+
] : []
|
|
212
|
+
};
|
|
213
|
+
|
|
214
|
+
// dynamic tile specific settings and bindings
|
|
215
|
+
if (bDynamic) {
|
|
216
|
+
const dataSource = oData.indicatorDataSource;
|
|
217
|
+
// initialize a data request later handled in TileCardExtension
|
|
218
|
+
oHeaderConfig.data = {
|
|
219
|
+
updateInterval: dataSource && dataSource.refresh ? dataSource.refresh : 0,
|
|
220
|
+
path: "/",
|
|
221
|
+
request: {
|
|
222
|
+
method: "GET",
|
|
223
|
+
url: "{parameters>/dataPath/value}",
|
|
224
|
+
withCredentials: true,
|
|
225
|
+
retryAfter: 1
|
|
226
|
+
}
|
|
227
|
+
};
|
|
228
|
+
|
|
229
|
+
// all data bindings will be resolved after the TileCard Extension has loaded the data.
|
|
230
|
+
|
|
231
|
+
// set or bind icon src and its visibility
|
|
232
|
+
oHeaderConfig.icon.src = "{= ${/_data/icon} || '" + (oData.icon || "") + "'}";
|
|
233
|
+
oHeaderConfig.icon.visible = "{= !!${/_data/icon}}";
|
|
234
|
+
// set or bind number units
|
|
235
|
+
oHeaderConfig.unitOfMeasurement = "{= ${/numberUnit} || '" + (oData.numberUnit || "") + "'}";
|
|
236
|
+
// bind indicator to data
|
|
237
|
+
oHeaderConfig.mainIndicator = {
|
|
238
|
+
number: "{/_data/number}",
|
|
239
|
+
unit: "{/_data/unit}",
|
|
240
|
+
trend: "{/_data/trend}",
|
|
241
|
+
state: "{/_data/state}"
|
|
242
|
+
};
|
|
243
|
+
// bind details
|
|
244
|
+
oHeaderConfig.details = {
|
|
245
|
+
text: "{= ${/_data/details/text} || '" + (oData.info || " ") + "'}", // bug, will be fixed, for blank text [Object object] is shown.
|
|
246
|
+
state: "{= ${/_data/details/state} || 'None'}"
|
|
247
|
+
};
|
|
248
|
+
}
|
|
249
|
+
return oHeaderConfig;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* Returns the navigation action for the header settings for the static and dynamic tile described by the given oData.
|
|
254
|
+
* @param {ExtendedVizData} oData the extended viz data from WorkPageVizInstantiation.
|
|
255
|
+
* @returns {object} The navigation action settings.
|
|
256
|
+
* @private
|
|
257
|
+
* @since 1.123.0
|
|
258
|
+
*/
|
|
259
|
+
function getNavigationAction (oData) {
|
|
260
|
+
// @TODO: Can we only use the targetURL, what about the parameters like hint?
|
|
261
|
+
const oTarget = oData.target;
|
|
262
|
+
if (!oTarget) {
|
|
263
|
+
return [];
|
|
264
|
+
}
|
|
265
|
+
if (oTarget.semanticObject && oTarget.action) {
|
|
266
|
+
return [
|
|
267
|
+
{
|
|
268
|
+
type: "Navigation",
|
|
269
|
+
parameters: {
|
|
270
|
+
ibnTarget: {
|
|
271
|
+
semanticObject: oTarget.semanticObject,
|
|
272
|
+
action: oTarget.action
|
|
273
|
+
},
|
|
274
|
+
ibnParams: oTarget.mParameters
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
];
|
|
278
|
+
} else if (oTarget.type && oTarget.type === "URL") {
|
|
279
|
+
return [
|
|
280
|
+
{
|
|
281
|
+
type: "Navigation",
|
|
282
|
+
parameters: {
|
|
283
|
+
url: oTarget.url
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
];
|
|
287
|
+
} else if (oData.targetURL) {
|
|
288
|
+
return [
|
|
289
|
+
{
|
|
290
|
+
type: "Navigation",
|
|
291
|
+
parameters: {
|
|
292
|
+
url: oData.targetURL
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
];
|
|
296
|
+
}
|
|
297
|
+
return [];
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
/**
|
|
301
|
+
* Returns the data path for dynamic data based on the indicatorDataSource and (if available) the corresponding dataSource.
|
|
302
|
+
* @param {ExtendedVizData} oData the extended viz data from WorkPageVizInstantiation.
|
|
303
|
+
* @returns {string} The dataPath.
|
|
304
|
+
* @private
|
|
305
|
+
* @since 1.123.0
|
|
306
|
+
*/
|
|
307
|
+
function getDataPath (oData) {
|
|
308
|
+
const oIndicatorDataSource = oData.indicatorDataSource;
|
|
309
|
+
if (!oIndicatorDataSource) {
|
|
310
|
+
return "";
|
|
311
|
+
}
|
|
312
|
+
let sPath = oIndicatorDataSource.path;
|
|
313
|
+
if (oIndicatorDataSource.dataSource && oData.dataSource && oData.dataSource.uri) {
|
|
314
|
+
if (!oData.dataSource.uri.endsWith("/")) {
|
|
315
|
+
oData.dataSource.uri = oData.dataSource.uri + "/"; // ensure slash at end.
|
|
316
|
+
}
|
|
317
|
+
sPath = oData.dataSource.uri + oIndicatorDataSource.path;
|
|
318
|
+
sPath = sPath.replaceAll("//", "/"); //avoid double slashes from concats.
|
|
319
|
+
}
|
|
320
|
+
return sPath || "/";
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
/**
|
|
324
|
+
* Returns the display variant for the card settings derived from the displayFormatHint.
|
|
325
|
+
* @param {string} sHint the displayFormatHint (standard, flat, flatWide, standardWide)
|
|
326
|
+
* @returns {object} The display variant for the card.
|
|
327
|
+
* @private
|
|
328
|
+
* @since 1.123.0
|
|
329
|
+
*/
|
|
330
|
+
function getDisplayVariant (sHint) {
|
|
331
|
+
switch (sHint) {
|
|
332
|
+
case "flat" : return "TileFlat";
|
|
333
|
+
case "standardWide" : return "TileStandardWide";
|
|
334
|
+
case "flatWide" : return "TileFlatWide";
|
|
335
|
+
case "compact" : return "LinkHeader";
|
|
336
|
+
default: return "TileStandard";
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
return {
|
|
340
|
+
createTileCardConfiguration: createTileCardConfiguration
|
|
341
|
+
};
|
|
342
|
+
});
|