@openui5/sap.ui.fl 1.103.1 → 1.106.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.
Files changed (265) hide show
  1. package/.reuse/dep5 +35 -15
  2. package/LICENSES/LicenseRef-tzdata-PublicDomain.txt +5 -0
  3. package/THIRDPARTY.txt +64 -21
  4. package/package.json +3 -3
  5. package/src/sap/ui/fl/.library +1 -1
  6. package/src/sap/ui/fl/Cache.js +10 -4
  7. package/src/sap/ui/fl/Change.js +144 -34
  8. package/src/sap/ui/fl/ChangePersistence.js +59 -31
  9. package/src/sap/ui/fl/ChangePersistenceFactory.js +1 -1
  10. package/src/sap/ui/fl/FakeLrepConnector.js +6 -0
  11. package/src/sap/ui/fl/FakeLrepConnectorLocalStorage.js +9 -3
  12. package/src/sap/ui/fl/FakeLrepConnectorSessionStorage.js +9 -3
  13. package/src/sap/ui/fl/FakeLrepLocalStorage.js +9 -3
  14. package/src/sap/ui/fl/FlexController.js +6 -6
  15. package/src/sap/ui/fl/FlexControllerFactory.js +1 -1
  16. package/src/sap/ui/fl/Layer.js +5 -2
  17. package/src/sap/ui/fl/LayerUtils.js +1 -1
  18. package/src/sap/ui/fl/Utils.js +88 -56
  19. package/src/sap/ui/fl/apply/_internal/ChangesController.js +2 -2
  20. package/src/sap/ui/fl/apply/_internal/DelegateMediator.js +1 -1
  21. package/src/sap/ui/fl/apply/_internal/appVariant/DescriptorChangeTypes.js +2 -2
  22. package/src/sap/ui/fl/apply/_internal/changes/Applier.js +9 -10
  23. package/src/sap/ui/fl/apply/_internal/changes/FlexCustomData.js +1 -1
  24. package/src/sap/ui/fl/apply/_internal/changes/Reverter.js +2 -2
  25. package/src/sap/ui/fl/apply/_internal/changes/Utils.js +4 -5
  26. package/src/sap/ui/fl/apply/_internal/changes/descriptor/Preprocessor.js +1 -1
  27. package/src/sap/ui/fl/apply/_internal/changes/descriptor/Registration.js +1 -1
  28. package/src/sap/ui/fl/apply/_internal/changes/descriptor/RegistrationBuild.js +1 -1
  29. package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddAnnotationsToOData.js +1 -1
  30. package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/ChangeDataSource.js +1 -1
  31. package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/ChangeInbound.js +1 -1
  32. package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/SetTitle.js +1 -1
  33. package/src/sap/ui/fl/apply/_internal/changes/descriptor/fiori/SetAbstract.js +1 -1
  34. package/src/sap/ui/fl/apply/_internal/changes/descriptor/fiori/SetRegistrationIds.js +1 -1
  35. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/AddNewCard.js +1 -1
  36. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/ChangeCard.js +1 -1
  37. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/DeleteCard.js +1 -1
  38. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddComponentUsages.js +1 -1
  39. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddLibrary.js +1 -1
  40. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddNewModel.js +1 -1
  41. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddNewModelEnhanceWith.js +1 -1
  42. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/SetFlexExtensionPointEnabled.js +1 -1
  43. package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/SetMinUI5Version.js +1 -1
  44. package/src/sap/ui/fl/apply/_internal/connectors/ObjectStorageConnector.js +2 -2
  45. package/src/sap/ui/fl/apply/_internal/connectors/ObjectStorageUtils.js +3 -3
  46. package/src/sap/ui/fl/apply/_internal/controlVariants/URLHandler.js +2 -2
  47. package/src/sap/ui/fl/apply/_internal/controlVariants/Utils.js +8 -43
  48. package/src/sap/ui/fl/apply/_internal/extensionPoint/Processor.js +1 -1
  49. package/src/sap/ui/fl/apply/_internal/flexObjects/AppDescriptorChange.js +73 -0
  50. package/src/sap/ui/fl/apply/_internal/flexObjects/CompVariant.js +11 -20
  51. package/src/sap/ui/fl/apply/_internal/flexObjects/ControllerExtensionChange.js +81 -0
  52. package/src/sap/ui/fl/apply/_internal/flexObjects/FlVariant.js +111 -0
  53. package/src/sap/ui/fl/apply/_internal/flexObjects/FlexObject.js +51 -17
  54. package/src/sap/ui/fl/apply/_internal/flexObjects/FlexObjectFactory.js +114 -34
  55. package/src/sap/ui/fl/apply/_internal/flexObjects/Variant.js +4 -15
  56. package/src/sap/ui/fl/apply/_internal/flexState/FlexState.js +23 -7
  57. package/src/sap/ui/fl/apply/_internal/flexState/Loader.js +3 -3
  58. package/src/sap/ui/fl/apply/_internal/flexState/ManifestUtils.js +1 -1
  59. package/src/sap/ui/fl/apply/_internal/flexState/UI2Personalization/UI2PersonalizationState.js +3 -3
  60. package/src/sap/ui/fl/apply/_internal/flexState/appDescriptorChanges/prepareAppDescriptorMap.js +2 -2
  61. package/src/sap/ui/fl/apply/_internal/flexState/changes/DependencyHandler.js +14 -10
  62. package/src/sap/ui/fl/apply/_internal/flexState/changes/ExtensionPointState.js +14 -17
  63. package/src/sap/ui/fl/apply/_internal/flexState/changes/prepareChangesMap.js +2 -2
  64. package/src/sap/ui/fl/apply/_internal/flexState/compVariants/CompVariantMerger.js +6 -6
  65. package/src/sap/ui/fl/apply/_internal/flexState/compVariants/Utils.js +2 -2
  66. package/src/sap/ui/fl/apply/_internal/flexState/compVariants/prepareCompVariantsMap.js +2 -2
  67. package/src/sap/ui/fl/apply/_internal/flexState/controlVariants/Switcher.js +3 -3
  68. package/src/sap/ui/fl/apply/_internal/flexState/controlVariants/VariantManagementState.js +30 -38
  69. package/src/sap/ui/fl/apply/_internal/flexState/controlVariants/prepareVariantsMap.js +76 -111
  70. package/src/sap/ui/fl/apply/_internal/preprocessors/ControllerExtension.js +1 -1
  71. package/src/sap/ui/fl/apply/_internal/preprocessors/EventHistory.js +1 -1
  72. package/src/sap/ui/fl/apply/_internal/preprocessors/RegistrationDelegator.js +1 -1
  73. package/src/sap/ui/fl/apply/_internal/preprocessors/XmlPreprocessor.js +1 -1
  74. package/src/sap/ui/fl/apply/api/ControlVariantApplyAPI.js +4 -4
  75. package/src/sap/ui/fl/apply/api/DelegateMediatorAPI.js +2 -2
  76. package/src/sap/ui/fl/apply/api/FlexRuntimeInfoAPI.js +2 -2
  77. package/src/sap/ui/fl/apply/api/SmartVariantManagementApplyAPI.js +2 -2
  78. package/src/sap/ui/fl/apply/api/UI2PersonalizationApplyAPI.js +2 -2
  79. package/src/sap/ui/fl/changeHandler/AddIFrame.js +7 -7
  80. package/src/sap/ui/fl/changeHandler/AddXML.js +14 -16
  81. package/src/sap/ui/fl/changeHandler/AddXMLAtExtensionPoint.js +9 -6
  82. package/src/sap/ui/fl/changeHandler/Base.js +1 -1
  83. package/src/sap/ui/fl/changeHandler/BaseAddViaDelegate.js +35 -37
  84. package/src/sap/ui/fl/changeHandler/BaseAddXml.js +15 -16
  85. package/src/sap/ui/fl/changeHandler/BaseRename.js +9 -15
  86. package/src/sap/ui/fl/changeHandler/HideControl.js +1 -1
  87. package/src/sap/ui/fl/changeHandler/MoveControls.js +16 -10
  88. package/src/sap/ui/fl/changeHandler/MoveElements.js +3 -2
  89. package/src/sap/ui/fl/changeHandler/PropertyBindingChange.js +13 -12
  90. package/src/sap/ui/fl/changeHandler/PropertyChange.js +23 -26
  91. package/src/sap/ui/fl/changeHandler/StashControl.js +1 -1
  92. package/src/sap/ui/fl/changeHandler/UnhideControl.js +1 -1
  93. package/src/sap/ui/fl/changeHandler/UnstashControl.js +3 -5
  94. package/src/sap/ui/fl/changeHandler/UpdateIFrame.js +3 -5
  95. package/src/sap/ui/fl/changeHandler/common/ChangeCategories.js +16 -0
  96. package/src/sap/ui/fl/changeHandler/common/createIFrame.js +2 -2
  97. package/src/sap/ui/fl/changeHandler/common/getTargetAggregationIndex.js +3 -3
  98. package/src/sap/ui/fl/changeHandler/common/revertAddedControls.js +2 -2
  99. package/src/sap/ui/fl/codeExt/CodeExtManager.js +1 -1
  100. package/src/sap/ui/fl/descriptorRelated/api/DescriptorChangeFactory.js +13 -22
  101. package/src/sap/ui/fl/descriptorRelated/api/DescriptorInlineChangeFactory.js +1 -1
  102. package/src/sap/ui/fl/descriptorRelated/api/DescriptorVariantFactory.js +1 -1
  103. package/src/sap/ui/fl/designtime/variants/VariantManagement.designtime.js +5 -2
  104. package/src/sap/ui/fl/initial/_internal/Storage.js +18 -5
  105. package/src/sap/ui/fl/initial/_internal/StorageResultMerger.js +27 -3
  106. package/src/sap/ui/fl/initial/_internal/StorageUtils.js +4 -4
  107. package/src/sap/ui/fl/initial/_internal/changeHandlers/ChangeHandlerRegistration.js +8 -0
  108. package/src/sap/ui/fl/initial/_internal/changeHandlers/ChangeHandlerStorage.js +9 -1
  109. package/src/sap/ui/fl/initial/_internal/changeHandlers/ChangeRegistryItem.js +1 -2
  110. package/src/sap/ui/fl/initial/_internal/connectors/BackendConnector.js +3 -3
  111. package/src/sap/ui/fl/initial/_internal/connectors/KeyUserConnector.js +2 -2
  112. package/src/sap/ui/fl/initial/_internal/connectors/LrepConnector.js +3 -4
  113. package/src/sap/ui/fl/initial/_internal/connectors/NeoLrepConnector.js +2 -3
  114. package/src/sap/ui/fl/initial/_internal/connectors/PersonalizationConnector.js +2 -2
  115. package/src/sap/ui/fl/initial/_internal/connectors/StaticFileConnector.js +2 -2
  116. package/src/sap/ui/fl/initial/_internal/connectors/Utils.js +19 -6
  117. package/src/sap/ui/fl/initial/_internal/storageResultDisassemble.js +3 -3
  118. package/src/sap/ui/fl/interfaces/BaseLoadConnector.js +9 -6
  119. package/src/sap/ui/fl/interfaces/Delegate.js +34 -18
  120. package/src/sap/ui/fl/library.js +351 -30
  121. package/src/sap/ui/fl/library.support.js +1 -1
  122. package/src/sap/ui/fl/messagebundle.properties +4 -1
  123. package/src/sap/ui/fl/messagebundle_ar.properties +2 -0
  124. package/src/sap/ui/fl/messagebundle_bg.properties +2 -0
  125. package/src/sap/ui/fl/messagebundle_ca.properties +2 -0
  126. package/src/sap/ui/fl/messagebundle_cs.properties +2 -0
  127. package/src/sap/ui/fl/messagebundle_cy.properties +2 -0
  128. package/src/sap/ui/fl/messagebundle_da.properties +2 -0
  129. package/src/sap/ui/fl/messagebundle_de.properties +2 -0
  130. package/src/sap/ui/fl/messagebundle_el.properties +2 -0
  131. package/src/sap/ui/fl/messagebundle_en.properties +2 -0
  132. package/src/sap/ui/fl/messagebundle_en_GB.properties +2 -0
  133. package/src/sap/ui/fl/messagebundle_en_US_sappsd.properties +2 -0
  134. package/src/sap/ui/fl/messagebundle_en_US_saprigi.properties +37 -2
  135. package/src/sap/ui/fl/messagebundle_en_US_saptrc.properties +2 -0
  136. package/src/sap/ui/fl/messagebundle_es.properties +2 -0
  137. package/src/sap/ui/fl/messagebundle_es_MX.properties +2 -0
  138. package/src/sap/ui/fl/messagebundle_et.properties +2 -0
  139. package/src/sap/ui/fl/messagebundle_fi.properties +2 -0
  140. package/src/sap/ui/fl/messagebundle_fr.properties +2 -0
  141. package/src/sap/ui/fl/messagebundle_fr_CA.properties +2 -0
  142. package/src/sap/ui/fl/messagebundle_hi.properties +2 -0
  143. package/src/sap/ui/fl/messagebundle_hr.properties +2 -0
  144. package/src/sap/ui/fl/messagebundle_hu.properties +2 -0
  145. package/src/sap/ui/fl/messagebundle_id.properties +2 -0
  146. package/src/sap/ui/fl/messagebundle_it.properties +2 -0
  147. package/src/sap/ui/fl/messagebundle_iw.properties +2 -0
  148. package/src/sap/ui/fl/messagebundle_ja.properties +2 -0
  149. package/src/sap/ui/fl/messagebundle_kk.properties +2 -0
  150. package/src/sap/ui/fl/messagebundle_ko.properties +2 -0
  151. package/src/sap/ui/fl/messagebundle_lt.properties +2 -0
  152. package/src/sap/ui/fl/messagebundle_lv.properties +2 -0
  153. package/src/sap/ui/fl/messagebundle_ms.properties +2 -0
  154. package/src/sap/ui/fl/messagebundle_nl.properties +2 -0
  155. package/src/sap/ui/fl/messagebundle_no.properties +2 -0
  156. package/src/sap/ui/fl/messagebundle_pl.properties +2 -0
  157. package/src/sap/ui/fl/messagebundle_pt.properties +2 -0
  158. package/src/sap/ui/fl/messagebundle_pt_PT.properties +2 -0
  159. package/src/sap/ui/fl/messagebundle_ro.properties +2 -0
  160. package/src/sap/ui/fl/messagebundle_ru.properties +2 -0
  161. package/src/sap/ui/fl/messagebundle_sh.properties +2 -0
  162. package/src/sap/ui/fl/messagebundle_sk.properties +2 -0
  163. package/src/sap/ui/fl/messagebundle_sl.properties +2 -0
  164. package/src/sap/ui/fl/messagebundle_sv.properties +2 -0
  165. package/src/sap/ui/fl/messagebundle_th.properties +2 -0
  166. package/src/sap/ui/fl/messagebundle_tr.properties +2 -0
  167. package/src/sap/ui/fl/messagebundle_uk.properties +2 -0
  168. package/src/sap/ui/fl/messagebundle_vi.properties +2 -0
  169. package/src/sap/ui/fl/messagebundle_zh_CN.properties +2 -0
  170. package/src/sap/ui/fl/messagebundle_zh_TW.properties +2 -0
  171. package/src/sap/ui/fl/registry/Settings.js +17 -3
  172. package/src/sap/ui/fl/requireAsync.js +2 -2
  173. package/src/sap/ui/fl/support/{apps/uiFlexibilityDiagnostics/helper/Extractor.js → _internal/extractChangeDependencies.js} +55 -57
  174. package/src/sap/ui/fl/support/_internal/getChangeDependencies.js +6 -6
  175. package/src/sap/ui/fl/support/_internal/getFlexSettings.js +14 -4
  176. package/src/sap/ui/fl/support/api/SupportAPI.js +3 -3
  177. package/src/sap/ui/fl/support/apps/contentbrowser/Component.js +10 -6
  178. package/src/sap/ui/fl/support/apps/contentbrowser/controller/ContentDetails.controller.js +26 -11
  179. package/src/sap/ui/fl/support/apps/contentbrowser/controller/ContentDetailsEdit.controller.js +27 -13
  180. package/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js +1 -1
  181. package/src/sap/ui/fl/support/apps/contentbrowser/controller/Layers.controller.js +5 -4
  182. package/src/sap/ui/fl/support/apps/contentbrowser/i18n/i18n.properties +4 -1
  183. package/src/sap/ui/fl/support/apps/contentbrowser/lrepConnector/LRepConnector.js +11 -3
  184. package/src/sap/ui/fl/support/apps/contentbrowser/utils/DataUtils.js +1 -1
  185. package/src/sap/ui/fl/support/apps/contentbrowser/utils/ErrorUtils.js +5 -4
  186. package/src/sap/ui/fl/support/apps/contentbrowser/view/ContentDetails.view.xml +1 -0
  187. package/src/sap/ui/fl/support/apps/contentbrowser/view/ContentDetailsEdit.view.xml +1 -0
  188. package/src/sap/ui/fl/transport/TransportSelection.js +1 -1
  189. package/src/sap/ui/fl/util/IFrame.js +27 -2
  190. package/src/sap/ui/fl/util/ManagedObjectModel.js +1 -1
  191. package/src/sap/ui/fl/util/resolveBinding.js +1 -1
  192. package/src/sap/ui/fl/variants/VariantManagement.js +604 -2094
  193. package/src/sap/ui/fl/variants/VariantModel.js +96 -104
  194. package/src/sap/ui/fl/variants/context/Component.js +3 -0
  195. package/src/sap/ui/fl/write/_internal/FlexInfoSession.js +46 -0
  196. package/src/sap/ui/fl/write/_internal/SaveAs.js +8 -9
  197. package/src/sap/ui/fl/write/_internal/Storage.js +10 -10
  198. package/src/sap/ui/fl/write/_internal/StorageFeaturesMerger.js +3 -3
  199. package/src/sap/ui/fl/write/_internal/Versions.js +13 -7
  200. package/src/sap/ui/fl/write/_internal/appVariant/AppVariant.js +8 -8
  201. package/src/sap/ui/fl/write/_internal/appVariant/AppVariantFactory.js +6 -6
  202. package/src/sap/ui/fl/write/_internal/appVariant/AppVariantInlineChange.js +8 -8
  203. package/src/sap/ui/fl/write/_internal/appVariant/AppVariantInlineChangeFactory.js +1 -1
  204. package/src/sap/ui/fl/write/_internal/condenser/Condenser.js +3 -3
  205. package/src/sap/ui/fl/write/_internal/condenser/UIReconstruction.js +1 -1
  206. package/src/sap/ui/fl/write/_internal/connectors/BackendConnector.js +3 -3
  207. package/src/sap/ui/fl/write/_internal/connectors/JsObjectConnector.js +2 -2
  208. package/src/sap/ui/fl/write/_internal/connectors/KeyUserConnector.js +26 -21
  209. package/src/sap/ui/fl/write/_internal/connectors/LocalStorageConnector.js +2 -2
  210. package/src/sap/ui/fl/write/_internal/connectors/LrepConnector.js +15 -8
  211. package/src/sap/ui/fl/write/_internal/connectors/NeoLrepConnector.js +3 -3
  212. package/src/sap/ui/fl/write/_internal/connectors/ObjectPathConnector.js +3 -3
  213. package/src/sap/ui/fl/write/_internal/connectors/ObjectStorageConnector.js +2 -2
  214. package/src/sap/ui/fl/write/_internal/connectors/PersonalizationConnector.js +3 -3
  215. package/src/sap/ui/fl/write/_internal/connectors/SessionStorageConnector.js +2 -2
  216. package/src/sap/ui/fl/write/_internal/connectors/Utils.js +3 -3
  217. package/src/sap/ui/fl/write/_internal/delegates/ODataV4ReadDelegate.js +4 -4
  218. package/src/sap/ui/fl/write/_internal/extensionPoint/Processor.js +1 -1
  219. package/src/sap/ui/fl/write/_internal/extensionPoint/Registry.js +1 -1
  220. package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPAccess.js +1 -1
  221. package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPExtensibilityVariant.js +4 -4
  222. package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPExtensibilityVariantFactory.js +3 -3
  223. package/src/sap/ui/fl/write/_internal/fieldExtensibility/MultiTenantABAPExtensibilityVariant.js +3 -3
  224. package/src/sap/ui/fl/write/_internal/fieldExtensibility/ServiceValidation.js +1 -1
  225. package/src/sap/ui/fl/write/_internal/fieldExtensibility/SingleTenantABAPExtensibilityVariant.js +4 -4
  226. package/src/sap/ui/fl/write/_internal/fieldExtensibility/UriParser.js +1 -1
  227. package/src/sap/ui/fl/write/_internal/fieldExtensibility/Utils.js +68 -18
  228. package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/CAPAccess.js +1 -1
  229. package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/dialog/CustomFieldCAPDialog.js +1 -1
  230. package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/booleanEditor/BooleanEditor.js +1 -1
  231. package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/rangeEditor/RangeEditor.js +1 -1
  232. package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/timeEditor/TimeEditor.js +1 -1
  233. package/src/sap/ui/fl/write/_internal/flexState/FlexObjectState.js +47 -10
  234. package/src/sap/ui/fl/write/_internal/flexState/compVariants/CompVariantState.js +18 -24
  235. package/src/sap/ui/fl/write/_internal/transport/TransportDialog.js +12 -7
  236. package/src/sap/ui/fl/write/_internal/transport/TransportSelection.js +6 -7
  237. package/src/sap/ui/fl/write/_internal/transport/Transports.js +11 -4
  238. package/src/sap/ui/fl/write/api/AppVariantWriteAPI.js +2 -2
  239. package/src/sap/ui/fl/write/api/ChangesWriteAPI.js +36 -19
  240. package/src/sap/ui/fl/write/api/ContextSharingAPI.js +2 -2
  241. package/src/sap/ui/fl/write/api/ControlPersonalizationWriteAPI.js +3 -3
  242. package/src/sap/ui/fl/write/api/ExtensionPointRegistryAPI.js +2 -2
  243. package/src/sap/ui/fl/write/api/FeaturesAPI.js +28 -8
  244. package/src/sap/ui/fl/write/api/FieldExtensibility.js +3 -3
  245. package/src/sap/ui/fl/write/api/LocalResetAPI.js +2 -2
  246. package/src/sap/ui/fl/write/api/PersistenceWriteAPI.js +5 -46
  247. package/src/sap/ui/fl/write/api/ReloadInfoAPI.js +148 -110
  248. package/src/sap/ui/fl/write/api/SmartBusinessWriteAPI.js +2 -2
  249. package/src/sap/ui/fl/write/api/SmartVariantManagementWriteAPI.js +2 -2
  250. package/src/sap/ui/fl/write/api/TranslationAPI.js +2 -2
  251. package/src/sap/ui/fl/write/api/UI2PersonalizationWriteAPI.js +2 -2
  252. package/src/sap/ui/fl/write/api/VersionsAPI.js +5 -3
  253. package/src/sap/ui/fl/write/api/connectors/FileListBaseConnector.js +4 -3
  254. package/src/sap/ui/fl/write/api/connectors/ObjectStorageConnector.js +4 -3
  255. package/src/sap/ui/fl/write/connectors/BaseConnector.js +4 -4
  256. package/src/sap/ui/fl/Variant.js +0 -511
  257. package/src/sap/ui/fl/support/Flexibility.js +0 -384
  258. package/src/sap/ui/fl/support/apps/uiFlexibilityDiagnostics/Component.js +0 -18
  259. package/src/sap/ui/fl/support/apps/uiFlexibilityDiagnostics/controller/Root.controller.js +0 -227
  260. package/src/sap/ui/fl/support/apps/uiFlexibilityDiagnostics/index.html +0 -21
  261. package/src/sap/ui/fl/support/apps/uiFlexibilityDiagnostics/manifest.json +0 -44
  262. package/src/sap/ui/fl/support/apps/uiFlexibilityDiagnostics/view/Root.view.xml +0 -95
  263. package/src/sap/ui/fl/support/diagnostics/Flexibility.controller.js +0 -35
  264. package/src/sap/ui/fl/support/diagnostics/Flexibility.view.xml +0 -41
  265. package/src/sap/ui/fl/support/flexibility.css +0 -32
@@ -1,511 +0,0 @@
1
- /*!
2
- * OpenUI5
3
- * (c) Copyright 2009-2022 SAP SE or an SAP affiliate company.
4
- * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
- */
6
-
7
- sap.ui.define([
8
- "sap/ui/thirdparty/jquery",
9
- "sap/ui/base/ManagedObject",
10
- "sap/ui/fl/Layer",
11
- "sap/ui/fl/Utils",
12
- "sap/ui/fl/LayerUtils",
13
- "sap/ui/fl/registry/Settings",
14
- "sap/base/util/merge",
15
- "sap/base/Log"
16
- ], function (
17
- jQuery,
18
- ManagedObject,
19
- Layer,
20
- Utils,
21
- LayerUtils,
22
- Settings,
23
- merge,
24
- Log
25
- ) {
26
- "use strict";
27
-
28
- /**
29
- * Flexibility variant class. Stores variant content, changes and related information.
30
- *
31
- * @param {object} oFile - variant's content, changes and admin data
32
- *
33
- * @class Variant class.
34
- * @extends sap.ui.base.ManagedObject
35
- * @author SAP SE
36
- * @version 1.103.1
37
- * @alias sap.ui.fl.Variant
38
- * @experimental Since 1.52.0
39
- */
40
- var Variant = ManagedObject.extend("sap.ui.fl.Variant", /** @lends sap.ui.fl.Variant.prototype */ {
41
- constructor: function(oFile) {
42
- ManagedObject.apply(this);
43
-
44
- if (!jQuery.isPlainObject(oFile)) {
45
- Log.error("Constructor : sap.ui.fl.Variant : oFile is not defined");
46
- }
47
-
48
- this._oDefinition = oFile;
49
- this._oOriginDefinition = merge({}, oFile);
50
- this._sRequest = '';
51
- this._bUserDependent = (oFile.content.layer === Layer.USER);
52
- this._vRevertData = null;
53
- this.setState(Variant.states.NEW);
54
- },
55
- metadata: {
56
- properties: {
57
- state: {
58
- type: "string"
59
- }
60
- }
61
- }
62
- });
63
-
64
- Variant.states = {
65
- NEW: "NEW",
66
- PERSISTED: "NONE",
67
- DELETED: "DELETE",
68
- DIRTY: "UPDATE"
69
- };
70
-
71
- Variant.events = {
72
- markForDeletion: "markForDeletion"
73
- };
74
-
75
- Variant.prototype.setState = function(sState) {
76
- if (this._isValidState(sState)) {
77
- this.setProperty("state", sState);
78
- }
79
- return this;
80
- };
81
-
82
- /**
83
- * Validates if the new state of variant has a valid value
84
- * The new state value has to be in the <code>Variant.states</code> list
85
- * Moving of state directly from <code>Variant.states.NEW</code> to <code>Variant.states.DIRTY</code> is not allowed.
86
- * @param {string} sState - value of target state
87
- * @returns {boolean} - new state is valid
88
- * @private
89
- */
90
- Variant.prototype._isValidState = function(sState) {
91
- //new state have to be in the Variant.states value list
92
- var bStateFound = false;
93
- Object.keys(Variant.states).some(function(sKey) {
94
- if (Variant.states[sKey] === sState) {
95
- bStateFound = true;
96
- }
97
- return bStateFound;
98
- });
99
- if (!bStateFound) {
100
- return false;
101
- }
102
- //change' state can not move from NEW to DIRTY directly
103
- if ((this.getState() === Variant.states.NEW) && (sState === Variant.states.DIRTY)) {
104
- return false;
105
- }
106
- return true;
107
- };
108
-
109
- /**
110
- * Returns if the variant protocol is valid
111
- * @returns {boolean} Variant is valid (mandatory fields are filled, etc)
112
- *
113
- * @public
114
- */
115
- Variant.prototype.isValid = function () {
116
- var bIsValid = true;
117
-
118
- if (typeof (this._oDefinition) !== "object") {
119
- bIsValid = false;
120
- }
121
- if (!this._oDefinition.content.fileType || this._oDefinition.content.fileType !== "ctrl_variant") {
122
- bIsValid = false;
123
- }
124
- if (!this._oDefinition.content.fileName) {
125
- bIsValid = false;
126
- }
127
- if (!this._oDefinition.content.content.title) {
128
- bIsValid = false;
129
- }
130
- if (!this._oDefinition.content.variantManagementReference) {
131
- bIsValid = false;
132
- }
133
- if (!this._oDefinition.content.layer) {
134
- bIsValid = false;
135
- }
136
- if (!this._oDefinition.content.originalLanguage) {
137
- bIsValid = false;
138
- }
139
-
140
- return bIsValid;
141
- };
142
-
143
- /**
144
- * Returns if the variant is of type variant
145
- * @returns {boolean} fileType of the ctrl_variant document is a variant
146
- *
147
- * @public
148
- */
149
- Variant.prototype.isVariant = function () {
150
- return true;
151
- };
152
-
153
- Variant.prototype.getDefinitionWithChanges = function () {
154
- return this._oDefinition;
155
- };
156
-
157
- /**
158
- * Returns the title
159
- *
160
- * @returns {string} Title of the variant
161
- * @public
162
- */
163
- Variant.prototype.getTitle = function () {
164
- if (this._oDefinition) {
165
- return this._oDefinition.content.content.title;
166
- }
167
- };
168
-
169
- /**
170
- * Returns the file type
171
- *
172
- * @returns {string} fileType of the variant
173
- * @public
174
- */
175
- Variant.prototype.getFileType = function () {
176
- if (this._oDefinition) {
177
- return this._oDefinition.content.fileType;
178
- }
179
- };
180
-
181
- /**
182
- * Returns variant changes
183
- *
184
- * @returns {array} Array of changes belonging to Variant
185
- * @public
186
- */
187
- Variant.prototype.getControlChanges = function () {
188
- return this._oDefinition.controlChanges;
189
- };
190
-
191
- /**
192
- * Returns the abap package name
193
- * @returns {string} ABAP package where the variant is assigned to
194
- *
195
- * @public
196
- */
197
- Variant.prototype.getPackage = function () {
198
- return this._oDefinition.content.packageName;
199
- };
200
-
201
- /**
202
- * Returns the namespace. The variants' namespace is
203
- * also the namespace of the change file in the repository.
204
- *
205
- * @returns {string} Namespace of the variants document
206
- *
207
- * @public
208
- */
209
- Variant.prototype.getNamespace = function () {
210
- return this._oDefinition.content.namespace;
211
- };
212
-
213
- /**
214
- * Sets the namespace.
215
- *
216
- * @param {string} sNamespace Namespace of the variants document
217
- *
218
- * @public
219
- */
220
- Variant.prototype.setNamespace = function (sNamespace) {
221
- this._oDefinition.content.namespace = sNamespace;
222
- };
223
-
224
- /**
225
- * Returns the id of the variant
226
- * @returns {string} Id of the variant document
227
- *
228
- * @public
229
- */
230
- Variant.prototype.getId = function () {
231
- return this._oDefinition.content.fileName;
232
- };
233
-
234
- /**
235
- * Returns the content section of the variant
236
- * @returns {string} Content of the variant document. The content structure can be any JSON.
237
- *
238
- * @public
239
- */
240
- Variant.prototype.getContent = function () {
241
- return this._oDefinition.content.content;
242
- };
243
-
244
- /**
245
- * Sets the object of the content attribute
246
- *
247
- * @param {object} oContent The content of the variant document. Can be any JSON object.
248
- *
249
- * @public
250
- */
251
- Variant.prototype.setContent = function (oContent) {
252
- this._oDefinition.content.content = oContent;
253
- this.setState(Variant.states.DIRTY);
254
- };
255
-
256
- /**
257
- * Returns the variant management reference of the variant
258
- * @returns {string} variant management reference of the variant.
259
- *
260
- * @public
261
- */
262
- Variant.prototype.getVariantManagementReference = function () {
263
- return this._oDefinition.content.variantManagementReference;
264
- };
265
-
266
- /**
267
- * Returns the variant reference of the variant
268
- * @returns {string} variant reference of the variant.
269
- *
270
- * @public
271
- */
272
- Variant.prototype.getVariantReference = function () {
273
- return this._oDefinition.content.variantReference;
274
- };
275
-
276
- /**
277
- * Returns the text in the current language for a given id
278
- *
279
- * @param {string} sTextId
280
- * text id which was used as part of the <code>oTexts</code> object
281
- * @returns {string} The text for the given text id
282
- *
283
- * @function
284
- */
285
- Variant.prototype.getText = function (sTextId) {
286
- if (typeof (sTextId) !== "string") {
287
- Log.error("sap.ui.fl.Variant.getTexts : sTextId is not defined");
288
- }
289
- if (this._oDefinition.content.texts) {
290
- if (this._oDefinition.content.texts[sTextId]) {
291
- return this._oDefinition.content.texts[sTextId].value;
292
- }
293
- }
294
- return "";
295
- };
296
-
297
- /**
298
- * Sets the new text for the given text id
299
- *
300
- * @param {string} sTextId
301
- * text id which was used as part of the <code>oTexts</code> object
302
- * @param {string} sNewText the new text for the given text id
303
- *
304
- * @public
305
- */
306
- Variant.prototype.setText = function (sTextId, sNewText) {
307
- if (typeof (sTextId) !== "string") {
308
- Log.error("sap.ui.fl.Variant.setTexts : sTextId is not defined");
309
- return;
310
- }
311
- if (this._oDefinition.content.texts) {
312
- if (this._oDefinition.content.texts[sTextId]) {
313
- this._oDefinition.content.texts[sTextId].value = sNewText;
314
- this.setState(Variant.states.DIRTY);
315
- }
316
- }
317
- };
318
-
319
- /**
320
- * Marks the current variant to be deleted persistently
321
- *
322
- * @public
323
- */
324
- Variant.prototype.markForDeletion = function () {
325
- this.setState(Variant.states.DELETED);
326
- };
327
-
328
- /**
329
- * Sets the transport request
330
- *
331
- * @param {string} sRequest Transport request
332
- *
333
- * @public
334
- */
335
- Variant.prototype.setRequest = function (sRequest) {
336
- if (typeof (sRequest) !== "string") {
337
- Log.error("sap.ui.fl.Variant.setRequest : sRequest is not defined");
338
- }
339
- this._sRequest = sRequest;
340
- };
341
-
342
- /**
343
- * Gets the transport request
344
- * @returns {string} Transport request
345
- *
346
- * @public
347
- */
348
- Variant.prototype.getRequest = function () {
349
- return this._sRequest;
350
- };
351
-
352
- /**
353
- * Gets the layer type for the variant
354
- * @returns {string} The layer of the variant
355
- *
356
- * @public
357
- */
358
- Variant.prototype.getLayer = function () {
359
- return this._oDefinition.content.layer;
360
- };
361
-
362
- /**
363
- * Gets the component for the variant
364
- * @returns {string} The SAPUI5 component this variant is assigned to
365
- *
366
- * @public
367
- */
368
- Variant.prototype.getComponent = function () {
369
- return this._oDefinition.content.reference;
370
- };
371
-
372
- /**
373
- * Sets the component for the variant
374
- *
375
- * @param {string} sComponent ID of the app or app variant
376
- * @public
377
- */
378
- Variant.prototype.setComponent = function (sComponent) {
379
- this._oDefinition.content.reference = sComponent;
380
- };
381
-
382
- /**
383
- * Gets the creation timestamp
384
- *
385
- * @returns {string} creation timestamp
386
- *
387
- * @public
388
- */
389
- Variant.prototype.getCreation = function () {
390
- return this._oDefinition.content.creation;
391
- };
392
-
393
- /**
394
- * Gets the JSON definition of the variant
395
- * @returns {object} the content of the variant
396
- *
397
- * @public
398
- */
399
- Variant.prototype.getDefinition = function () {
400
- return this._oDefinition.content;
401
- };
402
-
403
- /**
404
- * Set the response from the back end after saving the variant
405
- * @param {object} oResponse the content of the variant
406
- *
407
- * @public
408
- */
409
- Variant.prototype.setResponse = function (oResponse) {
410
- var sResponse = JSON.stringify(oResponse);
411
- if (sResponse) {
412
- this._oDefinition = JSON.parse(sResponse);
413
- this._oOriginDefinition = JSON.parse(sResponse);
414
- this.setState(Variant.states.PERSISTED);
415
- }
416
- };
417
-
418
- /**
419
- * Returns the revert specific data
420
- *
421
- * @returns {*} revert specific data
422
- * @public
423
- */
424
- Variant.prototype.getRevertData = function() {
425
- return this._vRevertData;
426
- };
427
-
428
- /**
429
- * Sets the revert specific data
430
- *
431
- * @param {*} vData revert specific data
432
- * @public
433
- */
434
- Variant.prototype.setRevertData = function(vData) {
435
- this._vRevertData = vData;
436
- };
437
-
438
- /**
439
- * Reset the revert specific data
440
- * @public
441
- */
442
- Variant.prototype.resetRevertData = function() {
443
- this.setRevertData(null);
444
- };
445
-
446
- /**
447
- * Creates and returns an instance of change instance
448
- *
449
- * @param {object} [oPropertyBag] property bag
450
- * @param {object} [oPropertyBag.content] content of the new change
451
- * @param {string} [oPropertyBag.content.fileName] name/id of the file. if not set implicitly created
452
- * @param {string} [oPropertyBag.content.content.title] title of the variant
453
- * @param {string} [oPropertyBag.content.fileType] file type of a variant
454
- * @param {string} [oPropertyBag.content.variantManagementReference] Reference to the variant management control
455
- * @param {string} [oPropertyBag.content.variantReference] Reference to another variant
456
- * @param {string} [oPropertyBag.content.reference] Application component name
457
- * @param {string} [oPropertyBag.content.packageName] Package name for transport
458
- * @param {string} [oPropertyBag.content.layer] Layer of the variant
459
- * @param {object} [oPropertyBag.content.texts] map object with all referenced texts within the file
460
- * these texts will be connected to the translation process
461
- * @param {string} [oPropertyBag.content.namespace] The namespace of the change file
462
- * @param {string} [oPropertyBag.service] name of the OData service
463
- * @param {boolean} [oPropertyBag.isVariant] ctrl_variant?
464
- * @param {boolean} [oPropertyBag.isUserDependent] true for enduser changes
465
- * @param {string} !!!![oPropertyBag.context] ID of the context
466
- * @param {string} [oPropertyBag.generator] Tool which is used to generate the variant change file
467
- *
468
- * @returns {object} The content of the change file
469
- *
470
- * @public
471
- */
472
- Variant.createInitialFileContent = function (oPropertyBag) {
473
- if (!oPropertyBag) {
474
- oPropertyBag = {};
475
- }
476
-
477
- var sFileName = oPropertyBag.content.fileName || Utils.createDefaultFileName();
478
- var sNamespace = oPropertyBag.content.namespace || Utils.createNamespace(oPropertyBag.content, "ctrl_variant");
479
- var oNewFile = {
480
- content: {
481
- fileName: sFileName,
482
- fileType: "ctrl_variant",
483
- variantManagementReference: oPropertyBag.content.variantManagementReference,
484
- variantReference: oPropertyBag.content.variantReference || "",
485
- reference: oPropertyBag.content.reference || "",
486
- packageName: oPropertyBag.content.packageName || "",
487
- content: {title: oPropertyBag.content.content.title || ""},
488
- self: sNamespace + sFileName + "." + "ctrl_variant",
489
- layer: oPropertyBag.content.layer || (oPropertyBag.isUserDependent ? Layer.USER : LayerUtils.getCurrentLayer()),
490
- texts: oPropertyBag.content.texts || {},
491
- namespace: sNamespace, //TODO: we need to think of a better way to create namespaces from Adaptation projects.
492
- creation: "",
493
- originalLanguage: Utils.getCurrentLanguage(),
494
- conditions: {},
495
- contexts: oPropertyBag.content.contexts || {},
496
- support: {
497
- generator: oPropertyBag.generator || "Change.createInitialFileContent",
498
- service: oPropertyBag.service || "",
499
- user: "",
500
- sapui5Version: sap.ui.version
501
- }
502
- },
503
- controlChanges: oPropertyBag.controlChanges || [],
504
- variantChanges: {} //should be empty for new variant
505
- };
506
-
507
- return oNewFile;
508
- };
509
-
510
- return Variant;
511
- }, true);