@openui5/sap.ui.rta 1.131.1 → 1.132.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 (200) hide show
  1. package/.eslintrc.json +1 -2
  2. package/THIRDPARTY.txt +1 -1
  3. package/package.json +6 -6
  4. package/src/sap/ui/rta/.library +2 -2
  5. package/src/sap/ui/rta/Client.js +2 -2
  6. package/src/sap/ui/rta/RuntimeAuthoring.js +26 -10
  7. package/src/sap/ui/rta/Utils.js +2 -2
  8. package/src/sap/ui/rta/api/startAdaptation.js +1 -1
  9. package/src/sap/ui/rta/api/startKeyUserAdaptation.js +1 -1
  10. package/src/sap/ui/rta/appVariant/AppVariantDialog.js +1 -1
  11. package/src/sap/ui/rta/appVariant/AppVariantManager.js +2 -2
  12. package/src/sap/ui/rta/appVariant/AppVariantOverviewDialog.js +1 -1
  13. package/src/sap/ui/rta/appVariant/AppVariantUtils.js +1 -1
  14. package/src/sap/ui/rta/appVariant/Feature.js +1 -1
  15. package/src/sap/ui/rta/appVariant/S4HanaCloudBackend.js +1 -1
  16. package/src/sap/ui/rta/appVariant/Utils.js +1 -1
  17. package/src/sap/ui/rta/appVariant/manageApps/webapp/Component.js +1 -1
  18. package/src/sap/ui/rta/appVariant/manageApps/webapp/controller/ManageApps.controller.js +1 -1
  19. package/src/sap/ui/rta/appVariant/manageApps/webapp/i18n/i18n_en_US_saptrc.properties +27 -27
  20. package/src/sap/ui/rta/appVariant/manageApps/webapp/index.html +3 -3
  21. package/src/sap/ui/rta/appVariant/manageApps/webapp/index.js +1 -1
  22. package/src/sap/ui/rta/appVariant/manageApps/webapp/model/models.js +1 -1
  23. package/src/sap/ui/rta/command/AddIFrame.js +2 -2
  24. package/src/sap/ui/rta/command/AddProperty.js +2 -2
  25. package/src/sap/ui/rta/command/AddXML.js +2 -2
  26. package/src/sap/ui/rta/command/AddXMLAtExtensionPoint.js +2 -2
  27. package/src/sap/ui/rta/command/AnnotationCommand.js +79 -0
  28. package/src/sap/ui/rta/command/AppDescriptorCommand.js +2 -2
  29. package/src/sap/ui/rta/command/BaseCommand.js +2 -2
  30. package/src/sap/ui/rta/command/BindProperty.js +6 -8
  31. package/src/sap/ui/rta/command/Combine.js +2 -2
  32. package/src/sap/ui/rta/command/CommandFactory.js +3 -3
  33. package/src/sap/ui/rta/command/CompositeCommand.js +2 -2
  34. package/src/sap/ui/rta/command/ControlVariantConfigure.js +9 -5
  35. package/src/sap/ui/rta/command/ControlVariantSave.js +2 -2
  36. package/src/sap/ui/rta/command/ControlVariantSaveAs.js +8 -6
  37. package/src/sap/ui/rta/command/ControlVariantSetTitle.js +14 -11
  38. package/src/sap/ui/rta/command/ControlVariantSwitch.js +6 -4
  39. package/src/sap/ui/rta/command/CreateContainer.js +2 -2
  40. package/src/sap/ui/rta/command/CustomAdd.js +2 -2
  41. package/src/sap/ui/rta/command/FlexCommand.js +2 -2
  42. package/src/sap/ui/rta/command/LREPSerializer.js +2 -2
  43. package/src/sap/ui/rta/command/LocalReset.js +2 -2
  44. package/src/sap/ui/rta/command/Move.js +2 -2
  45. package/src/sap/ui/rta/command/Property.js +2 -2
  46. package/src/sap/ui/rta/command/Remove.js +2 -2
  47. package/src/sap/ui/rta/command/Rename.js +2 -2
  48. package/src/sap/ui/rta/command/Resize.js +2 -2
  49. package/src/sap/ui/rta/command/Reveal.js +2 -2
  50. package/src/sap/ui/rta/command/Settings.js +2 -2
  51. package/src/sap/ui/rta/command/Split.js +2 -2
  52. package/src/sap/ui/rta/command/Stack.js +2 -2
  53. package/src/sap/ui/rta/command/appDescriptor/AddLibrary.js +2 -2
  54. package/src/sap/ui/rta/command/compVariant/CompVariantContent.js +2 -2
  55. package/src/sap/ui/rta/command/compVariant/CompVariantSaveAs.js +2 -2
  56. package/src/sap/ui/rta/command/compVariant/CompVariantSwitch.js +2 -2
  57. package/src/sap/ui/rta/command/compVariant/CompVariantUpdate.js +14 -2
  58. package/src/sap/ui/rta/enablement/TestDelegate.js +1 -1
  59. package/src/sap/ui/rta/enablement/elementActionTest.js +15 -16
  60. package/src/sap/ui/rta/library.js +3 -3
  61. package/src/sap/ui/rta/messagebundle.properties +18 -0
  62. package/src/sap/ui/rta/messagebundle_ar.properties +10 -0
  63. package/src/sap/ui/rta/messagebundle_bg.properties +13 -3
  64. package/src/sap/ui/rta/messagebundle_ca.properties +10 -0
  65. package/src/sap/ui/rta/messagebundle_cnr.properties +10 -0
  66. package/src/sap/ui/rta/messagebundle_cs.properties +10 -0
  67. package/src/sap/ui/rta/messagebundle_cy.properties +10 -0
  68. package/src/sap/ui/rta/messagebundle_da.properties +10 -0
  69. package/src/sap/ui/rta/messagebundle_de.properties +10 -0
  70. package/src/sap/ui/rta/messagebundle_el.properties +10 -0
  71. package/src/sap/ui/rta/messagebundle_en.properties +10 -0
  72. package/src/sap/ui/rta/messagebundle_en_GB.properties +10 -0
  73. package/src/sap/ui/rta/messagebundle_en_US_saprigi.properties +10 -0
  74. package/src/sap/ui/rta/messagebundle_en_US_saptrc.properties +347 -325
  75. package/src/sap/ui/rta/messagebundle_es.properties +10 -0
  76. package/src/sap/ui/rta/messagebundle_es_MX.properties +18 -8
  77. package/src/sap/ui/rta/messagebundle_et.properties +10 -0
  78. package/src/sap/ui/rta/messagebundle_fi.properties +10 -0
  79. package/src/sap/ui/rta/messagebundle_fr.properties +10 -0
  80. package/src/sap/ui/rta/messagebundle_fr_CA.properties +10 -0
  81. package/src/sap/ui/rta/messagebundle_hi.properties +10 -0
  82. package/src/sap/ui/rta/messagebundle_hr.properties +10 -0
  83. package/src/sap/ui/rta/messagebundle_hu.properties +10 -0
  84. package/src/sap/ui/rta/messagebundle_id.properties +10 -0
  85. package/src/sap/ui/rta/messagebundle_it.properties +10 -0
  86. package/src/sap/ui/rta/messagebundle_iw.properties +10 -0
  87. package/src/sap/ui/rta/messagebundle_ja.properties +10 -0
  88. package/src/sap/ui/rta/messagebundle_kk.properties +10 -0
  89. package/src/sap/ui/rta/messagebundle_ko.properties +10 -0
  90. package/src/sap/ui/rta/messagebundle_lt.properties +10 -0
  91. package/src/sap/ui/rta/messagebundle_lv.properties +10 -0
  92. package/src/sap/ui/rta/messagebundle_mk.properties +10 -0
  93. package/src/sap/ui/rta/messagebundle_ms.properties +14 -4
  94. package/src/sap/ui/rta/messagebundle_nl.properties +10 -0
  95. package/src/sap/ui/rta/messagebundle_no.properties +10 -0
  96. package/src/sap/ui/rta/messagebundle_pl.properties +10 -0
  97. package/src/sap/ui/rta/messagebundle_pt.properties +10 -0
  98. package/src/sap/ui/rta/messagebundle_pt_PT.properties +10 -0
  99. package/src/sap/ui/rta/messagebundle_ro.properties +10 -0
  100. package/src/sap/ui/rta/messagebundle_ru.properties +10 -0
  101. package/src/sap/ui/rta/messagebundle_sh.properties +10 -0
  102. package/src/sap/ui/rta/messagebundle_sk.properties +10 -0
  103. package/src/sap/ui/rta/messagebundle_sl.properties +10 -0
  104. package/src/sap/ui/rta/messagebundle_sr.properties +10 -0
  105. package/src/sap/ui/rta/messagebundle_sv.properties +10 -0
  106. package/src/sap/ui/rta/messagebundle_th.properties +10 -0
  107. package/src/sap/ui/rta/messagebundle_tr.properties +10 -0
  108. package/src/sap/ui/rta/messagebundle_uk.properties +11 -1
  109. package/src/sap/ui/rta/messagebundle_vi.properties +10 -0
  110. package/src/sap/ui/rta/messagebundle_zh_CN.properties +10 -0
  111. package/src/sap/ui/rta/messagebundle_zh_TW.properties +10 -0
  112. package/src/sap/ui/rta/plugin/AddXMLAtExtensionPoint.js +2 -2
  113. package/src/sap/ui/rta/plugin/BaseCreate.js +2 -2
  114. package/src/sap/ui/rta/plugin/Combine.js +2 -2
  115. package/src/sap/ui/rta/plugin/CompVariant.js +4 -2
  116. package/src/sap/ui/rta/plugin/ControlVariant.js +5 -23
  117. package/src/sap/ui/rta/plugin/CreateContainer.js +2 -2
  118. package/src/sap/ui/rta/plugin/CutPaste.js +2 -2
  119. package/src/sap/ui/rta/plugin/DragDrop.js +2 -2
  120. package/src/sap/ui/rta/plugin/LocalReset.js +2 -2
  121. package/src/sap/ui/rta/plugin/Plugin.js +15 -13
  122. package/src/sap/ui/rta/plugin/RTAElementMover.js +2 -2
  123. package/src/sap/ui/rta/plugin/Remove.js +2 -2
  124. package/src/sap/ui/rta/plugin/Rename.js +3 -3
  125. package/src/sap/ui/rta/plugin/RenameHandler.js +5 -9
  126. package/src/sap/ui/rta/plugin/Resize.js +3 -3
  127. package/src/sap/ui/rta/plugin/Selection.js +2 -2
  128. package/src/sap/ui/rta/plugin/Settings.js +2 -21
  129. package/src/sap/ui/rta/plugin/Split.js +2 -2
  130. package/src/sap/ui/rta/plugin/Stretch.js +7 -5
  131. package/src/sap/ui/rta/plugin/additionalElements/ActionExtractor.js +94 -126
  132. package/src/sap/ui/rta/plugin/additionalElements/AddElementsDialog.js +28 -31
  133. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsAnalyzer.js +141 -172
  134. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsPlugin.js +108 -137
  135. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsUtils.js +2 -2
  136. package/src/sap/ui/rta/plugin/additionalElements/CommandBuilder.js +96 -141
  137. package/src/sap/ui/rta/plugin/annotations/AnnotationChangeDialog.fragment.xml +112 -0
  138. package/src/sap/ui/rta/plugin/annotations/AnnotationChangeDialog.js +183 -0
  139. package/src/sap/ui/rta/plugin/annotations/AnnotationChangeDialogController.js +109 -0
  140. package/src/sap/ui/rta/plugin/annotations/AnnotationPlugin.js +239 -0
  141. package/src/sap/ui/rta/plugin/annotations/AnnotationTypes.js +15 -0
  142. package/src/sap/ui/rta/plugin/iframe/AddIFrame.js +2 -2
  143. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.js +3 -3
  144. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialogController.js +1 -1
  145. package/src/sap/ui/rta/plugin/iframe/urlCleaner.js +1 -1
  146. package/src/sap/ui/rta/service/Action.js +2 -2
  147. package/src/sap/ui/rta/service/ControllerExtension.js +2 -2
  148. package/src/sap/ui/rta/service/Outline.js +2 -2
  149. package/src/sap/ui/rta/service/Property.js +2 -2
  150. package/src/sap/ui/rta/service/Receiver.js +1 -1
  151. package/src/sap/ui/rta/service/Selection.js +2 -2
  152. package/src/sap/ui/rta/service/SupportTools.js +2 -2
  153. package/src/sap/ui/rta/service/index.js +1 -1
  154. package/src/sap/ui/rta/themes/base/WhatsNew.less +5 -0
  155. package/src/sap/ui/rta/themes/base/library.source.less +1 -1
  156. package/src/sap/ui/rta/themes/sap_hcb/library.source.less +1 -1
  157. package/src/sap/ui/rta/toolbar/Adaptation.js +2 -2
  158. package/src/sap/ui/rta/toolbar/AdaptationRenderer.js +1 -1
  159. package/src/sap/ui/rta/toolbar/Base.js +2 -2
  160. package/src/sap/ui/rta/toolbar/BaseRenderer.js +1 -1
  161. package/src/sap/ui/rta/toolbar/Fiori.js +3 -4
  162. package/src/sap/ui/rta/toolbar/FioriLike.js +2 -2
  163. package/src/sap/ui/rta/toolbar/OverflowToolbarButton.js +2 -2
  164. package/src/sap/ui/rta/toolbar/Standalone.js +2 -2
  165. package/src/sap/ui/rta/toolbar/contextBased/ManageAdaptations.js +1 -1
  166. package/src/sap/ui/rta/toolbar/contextBased/SaveAsAdaptation.js +2 -2
  167. package/src/sap/ui/rta/toolbar/translation/Translation.js +3 -3
  168. package/src/sap/ui/rta/toolbar/versioning/Versioning.js +2 -2
  169. package/src/sap/ui/rta/util/Animation.js +1 -1
  170. package/src/sap/ui/rta/util/BindingsExtractor.js +1 -1
  171. package/src/sap/ui/rta/util/PluginManager.js +16 -10
  172. package/src/sap/ui/rta/util/PopupManager.js +3 -3
  173. package/src/sap/ui/rta/util/ReloadManager.js +9 -9
  174. package/src/sap/ui/rta/util/ServiceEventBus.js +2 -2
  175. package/src/sap/ui/rta/util/ServiceManager.js +2 -2
  176. package/src/sap/ui/rta/util/adaptationStarter.js +17 -2
  177. package/src/sap/ui/rta/util/changeVisualization/ChangeCategories.js +1 -1
  178. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicator.js +2 -2
  179. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry.js +2 -2
  180. package/src/sap/ui/rta/util/changeVisualization/ChangeStates.js +1 -1
  181. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualization.js +5 -3
  182. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils.js +1 -1
  183. package/src/sap/ui/rta/util/changeVisualization/commands/CombineVisualization.js +1 -1
  184. package/src/sap/ui/rta/util/changeVisualization/commands/CreateContainerVisualization.js +1 -1
  185. package/src/sap/ui/rta/util/changeVisualization/commands/MoveVisualization.js +1 -1
  186. package/src/sap/ui/rta/util/changeVisualization/commands/RenameVisualization.js +1 -1
  187. package/src/sap/ui/rta/util/changeVisualization/commands/SplitVisualization.js +1 -1
  188. package/src/sap/ui/rta/util/changeVisualization/commands/getCommandVisualization.js +1 -1
  189. package/src/sap/ui/rta/util/hasStableId.js +1 -1
  190. package/src/sap/ui/rta/util/showMessageBox.js +1 -1
  191. package/src/sap/ui/rta/util/validateFlexEnabled.js +1 -1
  192. package/src/sap/ui/rta/util/validateStableIds.js +1 -1
  193. package/src/sap/ui/rta/util/validateText.js +1 -1
  194. package/src/sap/ui/rta/util/whatsNew/WhatsNew.js +2 -2
  195. package/src/sap/ui/rta/util/whatsNew/WhatsNewDialog.fragment.xml +5 -4
  196. package/src/sap/ui/rta/util/whatsNew/WhatsNewOverview.js +1 -1
  197. package/src/sap/ui/rta/util/whatsNew/WhatsNewOverviewDialog.fragment.xml +8 -2
  198. package/src/sap/ui/rta/util/whatsNew/WhatsNewUtils.js +1 -1
  199. package/src/sap/ui/rta/util/whatsNew/whatsNewContent/WhatsNewFeatures.js +1 -1
  200. package/src/sap/ui/rta/command/Annotation.js +0 -45
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -384,7 +384,7 @@ sap.ui.define([
384
384
  noSelector: true
385
385
  },
386
386
  annotation: {
387
- clazz: "sap/ui/rta/command/Annotation",
387
+ clazz: "sap/ui/rta/command/AnnotationCommand",
388
388
  noSelector: true
389
389
  },
390
390
  addIFrame: {
@@ -493,7 +493,7 @@ sap.ui.define([
493
493
  * @extends sap.ui.base.ManagedObject
494
494
  *
495
495
  * @author SAP SE
496
- * @version 1.131.1
496
+ * @version 1.132.0
497
497
  *
498
498
  * @constructor
499
499
  * @private
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -21,7 +21,7 @@ sap.ui.define([
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  *
23
23
  * @author SAP SE
24
- * @version 1.131.1
24
+ * @version 1.132.0
25
25
  *
26
26
  * @constructor
27
27
  * @private
@@ -1,12 +1,13 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
7
7
  "sap/ui/core/util/reflection/JsControlTreeModifier",
8
8
  "sap/ui/fl/apply/api/ControlVariantApplyAPI",
9
9
  "sap/ui/fl/apply/api/FlexRuntimeInfoAPI",
10
+ "sap/ui/fl/variants/VariantManager",
10
11
  "sap/ui/fl/write/api/ChangesWriteAPI",
11
12
  "sap/ui/fl/Utils",
12
13
  "sap/ui/rta/command/BaseCommand",
@@ -15,6 +16,7 @@ sap.ui.define([
15
16
  JsControlTreeModifier,
16
17
  ControlVariantApplyAPI,
17
18
  FlexRuntimeInfoAPI,
19
+ VariantManager,
18
20
  ChangesWriteAPI,
19
21
  FlUtils,
20
22
  BaseCommand,
@@ -28,7 +30,7 @@ sap.ui.define([
28
30
  * @class
29
31
  * @extends sap.ui.rta.command.BaseCommand
30
32
  * @author SAP SE
31
- * @version 1.131.1
33
+ * @version 1.132.0
32
34
  * @constructor
33
35
  * @private
34
36
  * @since 1.52
@@ -99,7 +101,7 @@ sap.ui.define([
99
101
  this.getChanges().forEach(function(mChangeProperties) {
100
102
  mChangeProperties.appComponent = this.oAppComponent;
101
103
  mChangeProperties.generator = rtaLibrary.GENERATOR_NAME;
102
- this._aPreparedChanges.push(this.oModel.addVariantChange(this.sVariantManagementReference, mChangeProperties));
104
+ this._aPreparedChanges.push(VariantManager.addVariantChange(this.sVariantManagementReference, mChangeProperties));
103
105
  }.bind(this));
104
106
 
105
107
  this._aDeletedFlexObjects = ChangesWriteAPI.deleteVariantsAndRelatedObjects({
@@ -125,7 +127,9 @@ sap.ui.define([
125
127
  delete this._aDeletedFlexObjects;
126
128
 
127
129
  this.getChanges().forEach(function(mChangeProperties, index) {
128
- const mPropertyBag = {};
130
+ const mPropertyBag = {
131
+ appComponent: this.oAppComponent
132
+ };
129
133
  Object.keys(mChangeProperties).forEach(function(sProperty) {
130
134
  var sOriginalProperty = `original${sProperty.charAt(0).toUpperCase()}${sProperty.substr(1)}`;
131
135
  if (sProperty === "visible") {
@@ -138,7 +142,7 @@ sap.ui.define([
138
142
  }
139
143
  });
140
144
  var oChange = this._aPreparedChanges[index];
141
- this.oModel.deleteVariantChange(this.sVariantManagementReference, mPropertyBag, oChange);
145
+ VariantManager.deleteVariantChange(this.sVariantManagementReference, mPropertyBag, oChange);
142
146
  }.bind(this));
143
147
 
144
148
  this._aPreparedChanges = null;
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.131.1
23
+ * @version 1.132.0
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.86
@@ -1,10 +1,11 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
7
7
  "sap/ui/core/util/reflection/JsControlTreeModifier",
8
+ "sap/ui/fl/variants/VariantManager",
8
9
  "sap/ui/fl/write/api/ContextSharingAPI",
9
10
  "sap/ui/fl/write/api/PersistenceWriteAPI",
10
11
  "sap/ui/fl/Utils",
@@ -13,6 +14,7 @@ sap.ui.define([
13
14
  "sap/ui/rta/Utils"
14
15
  ], function(
15
16
  JsControlTreeModifier,
17
+ VariantManager,
16
18
  ContextSharingAPI,
17
19
  PersistenceWriteAPI,
18
20
  flUtils,
@@ -28,7 +30,7 @@ sap.ui.define([
28
30
  * @class
29
31
  * @extends sap.ui.rta.command.BaseCommand
30
32
  * @author SAP SE
31
- * @version 1.131.1
33
+ * @version 1.132.0
32
34
  * @constructor
33
35
  * @private
34
36
  * @since 1.86
@@ -115,7 +117,7 @@ sap.ui.define([
115
117
  mParams.layer = this.sLayer;
116
118
  mParams.newVariantReference = this.sNewVariantReference;
117
119
  mParams.generator = rtaLibrary.GENERATOR_NAME;
118
- return this.oModel._handleSave(this.oVariantManagementControl, mParams)
120
+ return VariantManager.handleSaveEvent(this.oVariantManagementControl, mParams, this.oModel)
119
121
  .then(function(aDirtyChanges) {
120
122
  this._aPreparedChanges = aDirtyChanges;
121
123
  [this._oVariantChange] = aDirtyChanges;
@@ -151,11 +153,11 @@ sap.ui.define([
151
153
  variant: this._oVariantChange,
152
154
  sourceVariantReference: this.getSourceVariantReference(),
153
155
  variantManagementReference: this.sVariantManagementReference,
154
- component: this.oAppComponent
156
+ appComponent: this.oAppComponent
155
157
  };
156
158
 
157
- await this.oModel.removeVariant(mPropertyBag, true);
158
- await this.oModel.addAndApplyChangesOnVariant(this._aControlChangesWithoutVariant);
159
+ await VariantManager.removeVariant(mPropertyBag, true);
160
+ await VariantManager.addAndApplyChangesOnVariant(this._aControlChangesWithoutVariant, this.oAppComponent);
159
161
  this._aPreparedChanges = null;
160
162
  this._oVariantChange = null;
161
163
  }
@@ -1,20 +1,22 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
7
- "sap/ui/rta/command/BaseCommand",
8
- "sap/ui/rta/library",
9
7
  "sap/ui/core/util/reflection/JsControlTreeModifier",
10
8
  "sap/ui/fl/apply/api/ControlVariantApplyAPI",
11
- "sap/ui/fl/Utils"
9
+ "sap/ui/fl/variants/VariantManager",
10
+ "sap/ui/fl/Utils",
11
+ "sap/ui/rta/command/BaseCommand",
12
+ "sap/ui/rta/library"
12
13
  ], function(
13
- BaseCommand,
14
- rtaLibrary,
15
14
  JsControlTreeModifier,
16
15
  ControlVariantApplyAPI,
17
- flUtils
16
+ VariantManager,
17
+ flUtils,
18
+ BaseCommand,
19
+ rtaLibrary
18
20
  ) {
19
21
  "use strict";
20
22
 
@@ -24,7 +26,7 @@ sap.ui.define([
24
26
  * @class
25
27
  * @extends sap.ui.rta.command.BaseCommand
26
28
  * @author SAP SE
27
- * @version 1.131.1
29
+ * @version 1.132.0
28
30
  * @constructor
29
31
  * @private
30
32
  * @since 1.50
@@ -87,7 +89,7 @@ sap.ui.define([
87
89
  generator: rtaLibrary.GENERATOR_NAME
88
90
  };
89
91
 
90
- return Promise.resolve(this.oModel.addVariantChange(this.sVariantManagementReference, mPropertyBag))
92
+ return Promise.resolve(VariantManager.addVariantChange(this.sVariantManagementReference, mPropertyBag))
91
93
  .then(function(oChange) {
92
94
  this._oVariantChange = oChange;
93
95
  }.bind(this));
@@ -102,11 +104,12 @@ sap.ui.define([
102
104
  var mPropertyBag = {
103
105
  variantReference: this.sCurrentVariant,
104
106
  changeType: "setTitle",
105
- title: this.getOldText()
107
+ title: this.getOldText(),
108
+ appComponent: this.oAppComponent
106
109
  };
107
110
  var oChange = this._oVariantChange;
108
111
 
109
- return Promise.resolve(this.oModel.deleteVariantChange(this.sVariantManagementReference, mPropertyBag, oChange))
112
+ return Promise.resolve(VariantManager.deleteVariantChange(this.sVariantManagementReference, mPropertyBag, oChange))
110
113
  .then(function() {
111
114
  this._oVariantChange = null;
112
115
  }.bind(this));
@@ -1,16 +1,18 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
7
7
  "sap/ui/core/util/reflection/JsControlTreeModifier",
8
8
  "sap/ui/fl/apply/api/ControlVariantApplyAPI",
9
+ "sap/ui/fl/variants/VariantManager",
9
10
  "sap/ui/fl/Utils",
10
11
  "sap/ui/rta/command/BaseCommand"
11
12
  ], function(
12
13
  JsControlTreeModifier,
13
14
  ControlVariantApplyAPI,
15
+ VariantManager,
14
16
  flUtils,
15
17
  BaseCommand
16
18
  ) {
@@ -22,7 +24,7 @@ sap.ui.define([
22
24
  * @class
23
25
  * @extends sap.ui.rta.command.BaseCommand
24
26
  * @author SAP SE
25
- * @version 1.131.1
27
+ * @version 1.132.0
26
28
  * @constructor
27
29
  * @private
28
30
  * @since 1.50
@@ -59,7 +61,7 @@ sap.ui.define([
59
61
  });
60
62
 
61
63
  function discardVariantContent(sVReference) {
62
- return this.oModel.eraseDirtyChangesOnVariant(this.sVariantManagementReference, sVReference)
64
+ return VariantManager.eraseDirtyChangesOnVariant(this.sVariantManagementReference, sVReference, this._getAppComponent())
63
65
  .then(function(aDirtyChanges) {
64
66
  this.setDiscardedChanges(aDirtyChanges);
65
67
  }.bind(this));
@@ -107,7 +109,7 @@ sap.ui.define([
107
109
  .then(function() {
108
110
  // When discarding, dirty changes on source variant need to be applied AFTER the switch
109
111
  if (this.getDiscardVariantContent()) {
110
- return this.oModel.addAndApplyChangesOnVariant(this.getDiscardedChanges())
112
+ return VariantManager.addAndApplyChangesOnVariant(this.getDiscardedChanges(), this._getAppComponent())
111
113
  .then(function() {
112
114
  this.setDiscardedChanges([]);
113
115
  this.oModel.checkUpdate(true);
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.34
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.62
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -35,7 +35,7 @@ sap.ui.define([
35
35
  * @extends sap.ui.rta.command.BaseCommand
36
36
  *
37
37
  * @author SAP SE
38
- * @version 1.131.1
38
+ * @version 1.132.0
39
39
  *
40
40
  * @constructor
41
41
  * @private
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -27,7 +27,7 @@ sap.ui.define([
27
27
  * @class
28
28
  * @extends sap.ui.base.ManagedObject
29
29
  * @author SAP SE
30
- * @version 1.131.1
30
+ * @version 1.132.0
31
31
  * @constructor
32
32
  * @private
33
33
  * @since 1.42
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.131.1
23
+ * @version 1.132.0
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.90
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -17,7 +17,7 @@ function(
17
17
  * @class
18
18
  * @extends sap.ui.rta.command.FlexCommand
19
19
  * @author SAP SE
20
- * @version 1.131.1
20
+ * @version 1.132.0
21
21
  * @constructor
22
22
  * @private
23
23
  * @since 1.34
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.131.1
19
+ * @version 1.132.0
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.34
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.42
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.34
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.131.1
19
+ * @version 1.132.0
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.101
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.44
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.131.1
15
+ * @version 1.132.0
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.44
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -14,7 +14,7 @@ sap.ui.define([
14
14
  * @class
15
15
  * @extends sap.ui.rta.command.FlexCommand
16
16
  * @author SAP SE
17
- * @version 1.131.1
17
+ * @version 1.132.0
18
18
  * @constructor
19
19
  * @private
20
20
  * @since 1.46
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -73,7 +73,7 @@ sap.ui.define([
73
73
  * @class
74
74
  * @extends sap.ui.base.ManagedObject
75
75
  * @author SAP SE
76
- * @version 1.131.1
76
+ * @version 1.132.0
77
77
  * @constructor
78
78
  * @private
79
79
  * @since 1.34
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -19,7 +19,7 @@ sap.ui.define([
19
19
  * @extends sap.ui.rta.command.AppDescriptorCommand
20
20
  *
21
21
  * @author SAP SE
22
- * @version 1.131.1
22
+ * @version 1.132.0
23
23
  *
24
24
  * @constructor
25
25
  * @private
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.131.1
23
+ * @version 1.132.0
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.102
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.131.1
23
+ * @version 1.132.0
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.87
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -18,7 +18,7 @@ sap.ui.define([
18
18
  * @class
19
19
  * @extends sap.ui.rta.command.BaseCommand
20
20
  * @author SAP SE
21
- * @version 1.131.1
21
+ * @version 1.132.0
22
22
  * @constructor
23
23
  * @private
24
24
  * @since 1.87
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([
@@ -22,7 +22,7 @@ sap.ui.define([
22
22
  * @class
23
23
  * @extends sap.ui.rta.command.BaseCommand
24
24
  * @author SAP SE
25
- * @version 1.131.1
25
+ * @version 1.132.0
26
26
  * @constructor
27
27
  * @private
28
28
  * @since 1.87
@@ -41,6 +41,9 @@ sap.ui.define([
41
41
  oldDefaultVariantId: {
42
42
  type: "string"
43
43
  },
44
+ oldSelectedVariantId: {
45
+ type: "string"
46
+ },
44
47
  onlySave: {
45
48
  type: "boolean"
46
49
  },
@@ -91,6 +94,11 @@ sap.ui.define([
91
94
  if (oValue.deleted) {
92
95
  callFlAPIFunction.call(this, "removeVariant", sVariantId, {});
93
96
  this.getElement().removeVariant({variantId: sVariantId});
97
+ // Redo of delete command without direct UI interaction in VM dialog can keep deleted variant in the control.
98
+ // In this case we need to reactivate the *standard* variant
99
+ if (this.getElement().getCurrentVariantId() === sVariantId) {
100
+ this.getElement().activateVariant("*standard*");
101
+ }
94
102
  } else {
95
103
  var oVariant = callFlAPIFunction.call(this, "updateVariantMetadata", sVariantId, oValue);
96
104
  this.getElement().updateVariant(oVariant);
@@ -119,6 +127,10 @@ sap.ui.define([
119
127
  var oVariant = callFlAPIFunction.call(this, "revert", sVariantId, {});
120
128
  if (oValue.deleted) {
121
129
  this.getElement().addVariant(oVariant);
130
+ // If the current selected variant is deleted, the undo action should reactivate it
131
+ if (this.getOldSelectedVariantId() === sVariantId) {
132
+ this.getElement().activateVariant(sVariantId);
133
+ }
122
134
  } else {
123
135
  this.getElement().updateVariant(oVariant);
124
136
  }
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * OpenUI5
3
- * (c) Copyright 2009-2024 SAP SE or an SAP affiliate company.
3
+ * (c) Copyright 2009-2025 SAP SE or an SAP affiliate company.
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
  sap.ui.define([