@openui5/sap.ui.rta 1.98.0 → 1.101.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 (206) hide show
  1. package/THIRDPARTY.txt +6 -6
  2. package/package.json +6 -6
  3. package/src/sap/ui/rta/.library +1 -1
  4. package/src/sap/ui/rta/Client.js +1 -1
  5. package/src/sap/ui/rta/RuntimeAuthoring.js +64 -50
  6. package/src/sap/ui/rta/Utils.js +4 -6
  7. package/src/sap/ui/rta/appContexts/AppContextsOverviewDialog.js +76 -0
  8. package/src/sap/ui/rta/appContexts/Component.js +31 -0
  9. package/src/sap/ui/rta/appContexts/controller/ManageContexts.controller.js +323 -0
  10. package/src/sap/ui/rta/appContexts/controller/RestAPIConnector.js +22 -0
  11. package/src/sap/ui/rta/appContexts/i18n/i18n.properties +47 -0
  12. package/src/sap/ui/rta/appContexts/i18n/i18n_ar.properties +23 -0
  13. package/src/sap/ui/rta/appContexts/i18n/i18n_bg.properties +23 -0
  14. package/src/sap/ui/rta/appContexts/i18n/i18n_ca.properties +23 -0
  15. package/src/sap/ui/rta/appContexts/i18n/i18n_cs.properties +23 -0
  16. package/src/sap/ui/rta/appContexts/i18n/i18n_cy.properties +23 -0
  17. package/src/sap/ui/rta/appContexts/i18n/i18n_da.properties +23 -0
  18. package/src/sap/ui/rta/appContexts/i18n/i18n_de.properties +23 -0
  19. package/src/sap/ui/rta/appContexts/i18n/i18n_el.properties +23 -0
  20. package/src/sap/ui/rta/appContexts/i18n/i18n_en.properties +23 -0
  21. package/src/sap/ui/rta/appContexts/i18n/i18n_en_GB.properties +23 -0
  22. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_sappsd.properties +23 -0
  23. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_saprigi.properties +23 -0
  24. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_saptrc.properties +23 -0
  25. package/src/sap/ui/rta/appContexts/i18n/i18n_es.properties +23 -0
  26. package/src/sap/ui/rta/appContexts/i18n/i18n_es_MX.properties +23 -0
  27. package/src/sap/ui/rta/appContexts/i18n/i18n_et.properties +23 -0
  28. package/src/sap/ui/rta/appContexts/i18n/i18n_fi.properties +23 -0
  29. package/src/sap/ui/rta/appContexts/i18n/i18n_fr.properties +23 -0
  30. package/src/sap/ui/rta/appContexts/i18n/i18n_fr_CA.properties +23 -0
  31. package/src/sap/ui/rta/appContexts/i18n/i18n_hi.properties +23 -0
  32. package/src/sap/ui/rta/appContexts/i18n/i18n_hr.properties +23 -0
  33. package/src/sap/ui/rta/appContexts/i18n/i18n_hu.properties +23 -0
  34. package/src/sap/ui/rta/appContexts/i18n/i18n_id.properties +23 -0
  35. package/src/sap/ui/rta/appContexts/i18n/i18n_it.properties +23 -0
  36. package/src/sap/ui/rta/appContexts/i18n/i18n_iw.properties +23 -0
  37. package/src/sap/ui/rta/appContexts/i18n/i18n_ja.properties +23 -0
  38. package/src/sap/ui/rta/appContexts/i18n/i18n_kk.properties +23 -0
  39. package/src/sap/ui/rta/appContexts/i18n/i18n_ko.properties +23 -0
  40. package/src/sap/ui/rta/appContexts/i18n/i18n_lt.properties +23 -0
  41. package/src/sap/ui/rta/appContexts/i18n/i18n_lv.properties +23 -0
  42. package/src/sap/ui/rta/appContexts/i18n/i18n_ms.properties +23 -0
  43. package/src/sap/ui/rta/appContexts/i18n/i18n_nl.properties +23 -0
  44. package/src/sap/ui/rta/appContexts/i18n/i18n_no.properties +23 -0
  45. package/src/sap/ui/rta/appContexts/i18n/i18n_pl.properties +23 -0
  46. package/src/sap/ui/rta/appContexts/i18n/i18n_pt.properties +23 -0
  47. package/src/sap/ui/rta/appContexts/i18n/i18n_pt_PT.properties +23 -0
  48. package/src/sap/ui/rta/appContexts/i18n/i18n_ro.properties +23 -0
  49. package/src/sap/ui/rta/appContexts/i18n/i18n_ru.properties +23 -0
  50. package/src/sap/ui/rta/appContexts/i18n/i18n_sh.properties +23 -0
  51. package/src/sap/ui/rta/appContexts/i18n/i18n_sk.properties +23 -0
  52. package/src/sap/ui/rta/appContexts/i18n/i18n_sl.properties +23 -0
  53. package/src/sap/ui/rta/appContexts/i18n/i18n_sv.properties +23 -0
  54. package/src/sap/ui/rta/appContexts/i18n/i18n_th.properties +23 -0
  55. package/src/sap/ui/rta/appContexts/i18n/i18n_tr.properties +23 -0
  56. package/src/sap/ui/rta/appContexts/i18n/i18n_uk.properties +23 -0
  57. package/src/sap/ui/rta/appContexts/i18n/i18n_vi.properties +23 -0
  58. package/src/sap/ui/rta/appContexts/i18n/i18n_zh_CN.properties +23 -0
  59. package/src/sap/ui/rta/appContexts/i18n/i18n_zh_TW.properties +23 -0
  60. package/src/sap/ui/rta/appContexts/index.html +25 -0
  61. package/src/sap/ui/rta/appContexts/manifest.json +52 -0
  62. package/src/sap/ui/rta/appContexts/view/EditContextsDialog.fragment.xml +76 -0
  63. package/src/sap/ui/rta/appContexts/view/ManageContexts.view.xml +103 -0
  64. package/src/sap/ui/rta/appContexts/view/SaveAsContextsDialog.fragment.xml +76 -0
  65. package/src/sap/ui/rta/appVariant/AppVariantDialog.js +6 -3
  66. package/src/sap/ui/rta/appVariant/AppVariantManager.js +11 -11
  67. package/src/sap/ui/rta/appVariant/Feature.js +16 -6
  68. package/src/sap/ui/rta/command/AddIFrame.js +1 -1
  69. package/src/sap/ui/rta/command/AddProperty.js +1 -1
  70. package/src/sap/ui/rta/command/AddXML.js +3 -2
  71. package/src/sap/ui/rta/command/AddXMLAtExtensionPoint.js +3 -2
  72. package/src/sap/ui/rta/command/AppDescriptorCommand.js +1 -1
  73. package/src/sap/ui/rta/command/BaseCommand.js +1 -1
  74. package/src/sap/ui/rta/command/BindProperty.js +3 -2
  75. package/src/sap/ui/rta/command/Combine.js +5 -1
  76. package/src/sap/ui/rta/command/CommandFactory.js +20 -13
  77. package/src/sap/ui/rta/command/CompositeCommand.js +1 -1
  78. package/src/sap/ui/rta/command/ControlVariantConfigure.js +1 -1
  79. package/src/sap/ui/rta/command/ControlVariantSave.js +1 -1
  80. package/src/sap/ui/rta/command/ControlVariantSaveAs.js +1 -1
  81. package/src/sap/ui/rta/command/ControlVariantSetTitle.js +1 -1
  82. package/src/sap/ui/rta/command/ControlVariantSwitch.js +1 -1
  83. package/src/sap/ui/rta/command/CreateContainer.js +1 -1
  84. package/src/sap/ui/rta/command/CustomAdd.js +1 -1
  85. package/src/sap/ui/rta/command/FlexCommand.js +1 -1
  86. package/src/sap/ui/rta/command/LREPSerializer.js +1 -1
  87. package/src/sap/ui/rta/command/LocalReset.js +1 -1
  88. package/src/sap/ui/rta/command/Move.js +1 -1
  89. package/src/sap/ui/rta/command/Property.js +1 -1
  90. package/src/sap/ui/rta/command/Remove.js +1 -1
  91. package/src/sap/ui/rta/command/Rename.js +1 -1
  92. package/src/sap/ui/rta/command/Resize.js +45 -0
  93. package/src/sap/ui/rta/command/Reveal.js +1 -1
  94. package/src/sap/ui/rta/command/Settings.js +1 -1
  95. package/src/sap/ui/rta/command/Split.js +1 -1
  96. package/src/sap/ui/rta/command/Stack.js +15 -12
  97. package/src/sap/ui/rta/command/appDescriptor/AddLibrary.js +1 -1
  98. package/src/sap/ui/rta/command/compVariant/CompVariantSaveAs.js +1 -1
  99. package/src/sap/ui/rta/command/compVariant/CompVariantSwitch.js +1 -1
  100. package/src/sap/ui/rta/command/compVariant/CompVariantUpdate.js +1 -1
  101. package/src/sap/ui/rta/enablement/elementActionTest.js +1 -1
  102. package/src/sap/ui/rta/library.js +6 -9
  103. package/src/sap/ui/rta/messagebundle.properties +20 -11
  104. package/src/sap/ui/rta/messagebundle_ar.properties +14 -9
  105. package/src/sap/ui/rta/messagebundle_bg.properties +16 -11
  106. package/src/sap/ui/rta/messagebundle_ca.properties +15 -10
  107. package/src/sap/ui/rta/messagebundle_cs.properties +14 -9
  108. package/src/sap/ui/rta/messagebundle_cy.properties +14 -9
  109. package/src/sap/ui/rta/messagebundle_da.properties +14 -9
  110. package/src/sap/ui/rta/messagebundle_de.properties +14 -9
  111. package/src/sap/ui/rta/messagebundle_el.properties +14 -9
  112. package/src/sap/ui/rta/messagebundle_en.properties +14 -9
  113. package/src/sap/ui/rta/messagebundle_en_GB.properties +14 -9
  114. package/src/sap/ui/rta/messagebundle_en_US_sappsd.properties +14 -9
  115. package/src/sap/ui/rta/messagebundle_en_US_saprigi.properties +42 -20
  116. package/src/sap/ui/rta/messagebundle_en_US_saptrc.properties +14 -9
  117. package/src/sap/ui/rta/messagebundle_es.properties +14 -9
  118. package/src/sap/ui/rta/messagebundle_es_MX.properties +15 -10
  119. package/src/sap/ui/rta/messagebundle_et.properties +14 -9
  120. package/src/sap/ui/rta/messagebundle_fi.properties +14 -9
  121. package/src/sap/ui/rta/messagebundle_fr.properties +14 -9
  122. package/src/sap/ui/rta/messagebundle_fr_CA.properties +14 -9
  123. package/src/sap/ui/rta/messagebundle_hi.properties +13 -8
  124. package/src/sap/ui/rta/messagebundle_hr.properties +14 -9
  125. package/src/sap/ui/rta/messagebundle_hu.properties +14 -9
  126. package/src/sap/ui/rta/messagebundle_id.properties +14 -9
  127. package/src/sap/ui/rta/messagebundle_it.properties +14 -9
  128. package/src/sap/ui/rta/messagebundle_iw.properties +14 -9
  129. package/src/sap/ui/rta/messagebundle_ja.properties +14 -9
  130. package/src/sap/ui/rta/messagebundle_kk.properties +14 -9
  131. package/src/sap/ui/rta/messagebundle_ko.properties +14 -9
  132. package/src/sap/ui/rta/messagebundle_lt.properties +14 -9
  133. package/src/sap/ui/rta/messagebundle_lv.properties +16 -11
  134. package/src/sap/ui/rta/messagebundle_ms.properties +14 -9
  135. package/src/sap/ui/rta/messagebundle_nl.properties +14 -9
  136. package/src/sap/ui/rta/messagebundle_no.properties +14 -9
  137. package/src/sap/ui/rta/messagebundle_pl.properties +14 -9
  138. package/src/sap/ui/rta/messagebundle_pt.properties +14 -9
  139. package/src/sap/ui/rta/messagebundle_pt_PT.properties +14 -9
  140. package/src/sap/ui/rta/messagebundle_ro.properties +14 -9
  141. package/src/sap/ui/rta/messagebundle_ru.properties +14 -9
  142. package/src/sap/ui/rta/messagebundle_sh.properties +14 -9
  143. package/src/sap/ui/rta/messagebundle_sk.properties +15 -10
  144. package/src/sap/ui/rta/messagebundle_sl.properties +14 -9
  145. package/src/sap/ui/rta/messagebundle_sv.properties +14 -9
  146. package/src/sap/ui/rta/messagebundle_th.properties +14 -9
  147. package/src/sap/ui/rta/messagebundle_tr.properties +14 -9
  148. package/src/sap/ui/rta/messagebundle_uk.properties +13 -8
  149. package/src/sap/ui/rta/messagebundle_vi.properties +14 -9
  150. package/src/sap/ui/rta/messagebundle_zh_CN.properties +14 -9
  151. package/src/sap/ui/rta/messagebundle_zh_TW.properties +15 -10
  152. package/src/sap/ui/rta/plugin/AddXMLAtExtensionPoint.js +1 -1
  153. package/src/sap/ui/rta/plugin/BaseCreate.js +1 -1
  154. package/src/sap/ui/rta/plugin/Combine.js +15 -14
  155. package/src/sap/ui/rta/plugin/ControlVariant.js +3 -3
  156. package/src/sap/ui/rta/plugin/CreateContainer.js +1 -3
  157. package/src/sap/ui/rta/plugin/CutPaste.js +1 -1
  158. package/src/sap/ui/rta/plugin/DragDrop.js +1 -1
  159. package/src/sap/ui/rta/plugin/EasyAdd.js +1 -1
  160. package/src/sap/ui/rta/plugin/EasyRemove.js +1 -1
  161. package/src/sap/ui/rta/plugin/LocalReset.js +1 -1
  162. package/src/sap/ui/rta/plugin/Plugin.js +32 -11
  163. package/src/sap/ui/rta/plugin/RTAElementMover.js +1 -1
  164. package/src/sap/ui/rta/plugin/Remove.js +26 -27
  165. package/src/sap/ui/rta/plugin/Rename.js +6 -19
  166. package/src/sap/ui/rta/plugin/RenameHandler.js +21 -6
  167. package/src/sap/ui/rta/plugin/Resize.js +432 -0
  168. package/src/sap/ui/rta/plugin/Selection.js +21 -8
  169. package/src/sap/ui/rta/plugin/Settings.js +1 -1
  170. package/src/sap/ui/rta/plugin/Split.js +5 -11
  171. package/src/sap/ui/rta/plugin/Stretch.js +1 -1
  172. package/src/sap/ui/rta/plugin/additionalElements/ActionExtractor.js +39 -38
  173. package/src/sap/ui/rta/plugin/additionalElements/AddElementsDialog.js +1 -1
  174. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsPlugin.js +1 -1
  175. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsUtils.js +1 -1
  176. package/src/sap/ui/rta/plugin/additionalElements/CommandBuilder.js +1 -1
  177. package/src/sap/ui/rta/plugin/iframe/AddIFrame.js +1 -1
  178. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.js +1 -1
  179. package/src/sap/ui/rta/service/Action.js +1 -1
  180. package/src/sap/ui/rta/service/ControllerExtension.js +1 -1
  181. package/src/sap/ui/rta/service/Outline.js +1 -1
  182. package/src/sap/ui/rta/service/Property.js +1 -1
  183. package/src/sap/ui/rta/service/Selection.js +1 -1
  184. package/src/sap/ui/rta/themes/base/ChangeVisualization.less +55 -75
  185. package/src/sap/ui/rta/themes/base/Overlay.less +50 -0
  186. package/src/sap/ui/rta/toolbar/Adaptation.fragment.xml +5 -19
  187. package/src/sap/ui/rta/toolbar/Adaptation.js +4 -3
  188. package/src/sap/ui/rta/toolbar/Base.js +1 -1
  189. package/src/sap/ui/rta/toolbar/Fiori.js +1 -1
  190. package/src/sap/ui/rta/toolbar/FioriLike.js +1 -1
  191. package/src/sap/ui/rta/toolbar/OverflowToolbarButton.js +1 -1
  192. package/src/sap/ui/rta/toolbar/Personalization.js +1 -1
  193. package/src/sap/ui/rta/toolbar/Standalone.js +1 -1
  194. package/src/sap/ui/rta/toolbar/translation/Translation.js +52 -31
  195. package/src/sap/ui/rta/util/PluginManager.js +9 -3
  196. package/src/sap/ui/rta/util/PopupManager.js +33 -12
  197. package/src/sap/ui/rta/util/ServiceEventBus.js +1 -1
  198. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicator.js +109 -60
  199. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorCategorySelection.fragment.xml +30 -0
  200. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorPopover.fragment.xml +6 -5
  201. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry.js +1 -1
  202. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualization.js +146 -79
  203. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils.js +37 -0
  204. package/src/sap/ui/rta/util/changeVisualization/categories/MoveVisualization.js +25 -4
  205. package/src/sap/ui/rta/util/changeVisualization/categories/RenameVisualization.js +14 -2
  206. package/src/sap/ui/rta/util/changeVisualization/categories/SplitVisualization.js +5 -2
@@ -5,6 +5,7 @@
5
5
  */
6
6
 
7
7
  sap.ui.define([
8
+ "sap/ui/core/Fragment",
8
9
  "sap/base/util/restricted/_difference",
9
10
  "sap/base/util/deepEqual",
10
11
  "sap/base/Log",
@@ -12,7 +13,6 @@ sap.ui.define([
12
13
  "sap/ui/core/Control",
13
14
  "sap/ui/dt/OverlayRegistry",
14
15
  "sap/ui/dt/ElementUtil",
15
- "sap/ui/events/KeyCodes",
16
16
  "sap/ui/fl/apply/_internal/changes/Utils",
17
17
  "sap/ui/fl/write/api/ChangesWriteAPI",
18
18
  "sap/ui/fl/write/api/PersistenceWriteAPI",
@@ -23,6 +23,7 @@ sap.ui.define([
23
23
  "sap/ui/rta/util/changeVisualization/ChangeIndicator",
24
24
  "sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry"
25
25
  ], function(
26
+ Fragment,
26
27
  difference,
27
28
  deepEqual,
28
29
  Log,
@@ -30,7 +31,6 @@ sap.ui.define([
30
31
  Control,
31
32
  OverlayRegistry,
32
33
  ElementUtil,
33
- KeyCodes,
34
34
  ChangesUtils,
35
35
  ChangesWriteAPI,
36
36
  PersistenceWriteAPI,
@@ -79,8 +79,9 @@ sap.ui.define([
79
79
  * When clicking anywhere on the application, the menu must close
80
80
  */
81
81
  function _onClick() {
82
- if (this.oMenuButton) {
83
- this.oMenuButton.getMenu().close();
82
+ var oPopover = this.getPopover();
83
+ if (oPopover && oPopover.isOpen()) {
84
+ oPopover.close();
84
85
  }
85
86
  }
86
87
 
@@ -92,7 +93,7 @@ sap.ui.define([
92
93
  * @alias sap.ui.rta.util.changeVisualization.ChangeVisualization
93
94
  * @author SAP SE
94
95
  * @since 1.84.0
95
- * @version 1.98.0
96
+ * @version 1.101.0
96
97
  * @private
97
98
  */
98
99
  var ChangeVisualization = Control.extend("sap.ui.rta.util.changeVisualization.ChangeVisualization", {
@@ -112,9 +113,15 @@ sap.ui.define([
112
113
  type: "boolean",
113
114
  defaultValue: false
114
115
  }
116
+ },
117
+ aggregations: {
118
+ popover: {
119
+ type: "sap.m.Popover",
120
+ multiple: false
121
+ }
115
122
  }
116
123
  },
117
- constructor: function () {
124
+ constructor: function() {
118
125
  Control.prototype.constructor.apply(this, arguments);
119
126
 
120
127
  this._oChangeIndicatorRegistry = new ChangeIndicatorRegistry({
@@ -137,18 +144,18 @@ sap.ui.define([
137
144
  }
138
145
  });
139
146
 
140
- ChangeVisualization.prototype.setRootControlId = function (sRootControlId) {
147
+ ChangeVisualization.prototype.setRootControlId = function(sRootControlId) {
141
148
  if (this.getRootControlId() && this.getRootControlId() !== sRootControlId) {
142
149
  this._reset();
143
150
  }
144
151
  this.setProperty("rootControlId", sRootControlId);
145
152
  };
146
153
 
147
- ChangeVisualization.prototype._getComponent = function () {
154
+ ChangeVisualization.prototype._getComponent = function() {
148
155
  return FlUtils.getAppComponentForControl(ElementUtil.getElementInstance(this.getRootControlId()));
149
156
  };
150
157
 
151
- ChangeVisualization.prototype.setIsActive = function (bActiveState) {
158
+ ChangeVisualization.prototype.setIsActive = function(bActiveState) {
152
159
  if (bActiveState === this.getIsActive()) {
153
160
  return;
154
161
  }
@@ -161,24 +168,37 @@ sap.ui.define([
161
168
  }
162
169
  };
163
170
 
164
- ChangeVisualization.prototype.exit = function () {
171
+ ChangeVisualization.prototype.exit = function() {
165
172
  this._oChangeIndicatorRegistry.destroy();
166
173
  if (this.oRootOverlay) {
167
- this.oRootOverlay.getDomRef().removeEventListener("click", this._fnOnClickHandler, {capture: true});
174
+ this.oRootOverlay.getDomRef().removeEventListener("click", this._fnOnClickHandler, { capture: true });
168
175
  }
169
176
  };
170
177
 
171
- ChangeVisualization.prototype._reset = function () {
178
+ ChangeVisualization.prototype._reset = function() {
172
179
  this._oChangeIndicatorRegistry.reset();
173
180
  };
174
181
 
175
- ChangeVisualization.prototype._updateVisualizationModelMenuData = function () {
176
- var aCommandData = Object.keys(VALID_COMMANDS).map(function (sCommandCategoryName) {
177
- var sTitle = this._getCommandCategoryLabel(sCommandCategoryName,
178
- this._getChangesForCommandCategory(sCommandCategoryName).length);
182
+ ChangeVisualization.prototype._updateVisualizationModelMenuData = function() {
183
+ var aVisualizedChanges = this._oChangeVisualizationModel.getData().visualizedChanges;
184
+ var aHiddenChanges = [];
185
+ var aRegisteredChanges = this._oChangeIndicatorRegistry.getChanges();
186
+ aRegisteredChanges.forEach(function(oChange) {
187
+ var oVisualizedChange = aVisualizedChanges.find(function(oVisualizedChange) {
188
+ return oChange.change.getId() === oVisualizedChange.id;
189
+ });
190
+ if (!oVisualizedChange && !oChange.dependent) {
191
+ aHiddenChanges.push(oChange);
192
+ }
193
+ });
194
+ var aCommandData = Object.keys(VALID_COMMANDS).map(function(sCommandCategoryName) {
195
+ var sTitle = this._getCommandCategoryLabel(
196
+ sCommandCategoryName,
197
+ this._getChangesForCommandCategory(sCommandCategoryName, aVisualizedChanges).length
198
+ );
179
199
  return {
180
200
  key: sCommandCategoryName,
181
- count: this._getChangesForCommandCategory(sCommandCategoryName).length,
201
+ count: this._getChangesForCommandCategory(sCommandCategoryName, aVisualizedChanges).length,
182
202
  title: sTitle,
183
203
  icon: CATEGORY_ICONS[sCommandCategoryName]
184
204
  };
@@ -186,50 +206,85 @@ sap.ui.define([
186
206
 
187
207
  aCommandData.unshift({
188
208
  key: CATEGORY_ALL,
189
- count: this._getChangesForCommandCategory(CATEGORY_ALL).length,
190
- title: this._getCommandCategoryLabel(CATEGORY_ALL, this._getChangesForCommandCategory(CATEGORY_ALL).length),
209
+ count: this._getChangesForCommandCategory(CATEGORY_ALL, aVisualizedChanges).length,
210
+ title: this._getCommandCategoryLabel(CATEGORY_ALL, this._getChangesForCommandCategory(CATEGORY_ALL, aVisualizedChanges).length),
191
211
  icon: CATEGORY_ICONS[CATEGORY_ALL]
192
212
  });
193
213
 
194
214
  this._updateVisualizationModel({
195
- commandCategories: aCommandData
215
+ commandCategories: aCommandData,
216
+ hiddenChanges: aHiddenChanges,
217
+ popupInfoMessage: this._oTextBundle.getText(
218
+ "MSG_CHANGEVISUALIZATION_HIDDEN_CHANGES_INFO",
219
+ [aHiddenChanges.length]
220
+ )
196
221
  });
197
222
  };
198
223
 
199
- ChangeVisualization.prototype._getChangesForCommandCategory = function (sCommandCategory) {
200
- var aRegisteredChanges = this._oChangeIndicatorRegistry.getChanges();
201
- return aRegisteredChanges.filter(function (oChange) {
224
+ ChangeVisualization.prototype._getChangesForCommandCategory = function(sCommandCategory, aChanges) {
225
+ return aChanges.filter(function(oChange) {
202
226
  return sCommandCategory === CATEGORY_ALL
203
227
  ? oChange.commandCategory !== undefined
204
228
  : sCommandCategory === oChange.commandCategory;
205
229
  });
206
230
  };
207
231
 
208
- ChangeVisualization.prototype._getCommandCategoryLabel = function (sCommandCategoryName, iChangesCount) {
232
+ ChangeVisualization.prototype._getCommandCategoryLabel = function(sCommandCategoryName, iChangesCount) {
209
233
  var sLabelKey = "TXT_CHANGEVISUALIZATION_OVERVIEW_" + sCommandCategoryName.toUpperCase();
210
234
  return this._oTextBundle.getText(sLabelKey, [iChangesCount]);
211
235
  };
212
236
 
213
- ChangeVisualization.prototype._getCommandCategoryButton = function (sCommandCategoryName) {
237
+ ChangeVisualization.prototype._getCommandCategoryButton = function(sCommandCategoryName) {
214
238
  var sButtonKey = "BTN_CHANGEVISUALIZATION_OVERVIEW_" + sCommandCategoryName.toUpperCase();
215
239
  return this._oTextBundle.getText(sButtonKey);
216
240
  };
217
241
 
242
+ ChangeVisualization.prototype.openChangeCategorySelectionPopover = function(oEvent) {
243
+ if (!this._oToolbarButton) {
244
+ // Event bubbled through the toolbar, get original source
245
+ this._oToolbarButton = sap.ui.getCore().byId(oEvent.getParameter("id"));
246
+ }
247
+ var oPopover = this.getPopover();
248
+
249
+ if (!oPopover) {
250
+ Fragment.load({
251
+ name: "sap.ui.rta.util.changeVisualization.ChangeIndicatorCategorySelection",
252
+ id: this._getComponent().createId("changeVisualization_changesListPopover"),
253
+ controller: this
254
+ })
255
+ .then(function(oPopover) {
256
+ this._oToolbarButton.addDependent(oPopover);
257
+ oPopover.setModel(this._oChangeVisualizationModel, "visualizationModel");
258
+ oPopover.openBy(this._oToolbarButton);
259
+ this.setPopover(oPopover);
260
+ }.bind(this));
261
+ return;
262
+ }
263
+
264
+ if (oPopover.isOpen()) {
265
+ oPopover.close();
266
+ } else {
267
+ oPopover.openBy(this._oToolbarButton);
268
+ }
269
+ };
270
+
218
271
  /**
219
272
  * Sets the selected command category and visualizes all changes for the given category
220
273
  *
221
274
  * @param {event} oEvent - Event
222
- * @returns {promise} - Promise of category change
275
+ * @returns {Promise} - Promise of category change
223
276
  */
224
- ChangeVisualization.prototype.onCommandCategorySelection = function (oEvent) {
225
- var sSelectedCommandCategory = oEvent.getParameter("item").getKey();
277
+ ChangeVisualization.prototype.onCommandCategorySelection = function(oEvent) {
278
+ var sSelectedCommandCategory = oEvent.getSource().getBindingContext("visualizationModel").getObject().key;
226
279
  return this._selectCommandCategory(sSelectedCommandCategory);
227
280
  };
228
281
 
229
- ChangeVisualization.prototype._selectCommandCategory = function (sSelectedCommandCategory) {
282
+ ChangeVisualization.prototype._selectCommandCategory = function(sSelectedCommandCategory) {
230
283
  this._sSelectedCommandCategory = sSelectedCommandCategory;
231
284
 
232
- var aRelevantChanges = this._getChangesForCommandCategory(sSelectedCommandCategory);
285
+ var aRegisteredChanges = this._oChangeIndicatorRegistry.getChanges();
286
+ var aRelevantChanges = this._getChangesForCommandCategory(sSelectedCommandCategory, aRegisteredChanges);
287
+
233
288
  var sCommandCategoryText = this._getCommandCategoryButton(sSelectedCommandCategory);
234
289
 
235
290
  this._updateVisualizationModel({
@@ -237,22 +292,22 @@ sap.ui.define([
237
292
  commandCategoryText: sCommandCategoryText
238
293
  });
239
294
 
240
- return Promise.all(aRelevantChanges.map(function (oChange) {
295
+ return Promise.all(aRelevantChanges.map(function(oChange) {
241
296
  return this._getVisualizationInfo(oChange)
242
- .then(function (mVisualizationInfo) {
297
+ .then(function(mVisualizationInfo) {
243
298
  this._oChangeIndicatorRegistry.addVisualizationInfo(
244
299
  oChange.change.getId(),
245
300
  mVisualizationInfo
246
301
  );
247
302
  }.bind(this));
248
303
  }.bind(this)))
249
- .then(function () {
304
+ .then(function() {
250
305
  this._updateChangeIndicators();
251
306
  this._setFocusedIndicator();
252
307
  }.bind(this));
253
308
  };
254
309
 
255
- ChangeVisualization.prototype._getVisualizationInfo = function (mChangeInformation) {
310
+ ChangeVisualization.prototype._getVisualizationInfo = function(mChangeInformation) {
256
311
  var oComponent = this._getComponent();
257
312
 
258
313
  function getSelectorIds(aSelectorList) {
@@ -260,7 +315,7 @@ sap.ui.define([
260
315
  return undefined;
261
316
  }
262
317
  return aSelectorList
263
- .map(function (vSelector) {
318
+ .map(function(vSelector) {
264
319
  var oElement = typeof vSelector.getId === "function"
265
320
  ? vSelector
266
321
  : JsControlTreeModifier.bySelector(vSelector, oComponent);
@@ -270,7 +325,7 @@ sap.ui.define([
270
325
  }
271
326
 
272
327
  return this._getInfoFromChangeHandler(oComponent, mChangeInformation.change)
273
- .then(function (oInfoFromChangeHandler) {
328
+ .then(function(oInfoFromChangeHandler) {
274
329
  var mVisualizationInfo = oInfoFromChangeHandler || {};
275
330
  var aAffectedElementIds = (
276
331
  getSelectorIds(mVisualizationInfo.affectedControls || [mChangeInformation.change.getSelector()])
@@ -329,7 +384,7 @@ sap.ui.define([
329
384
  && searchForCommand(OverlayRegistry.getOverlay(oLastDependentSelectorControl));
330
385
  };
331
386
 
332
- ChangeVisualization.prototype._getInfoFromChangeHandler = function (oAppComponent, oChange) {
387
+ ChangeVisualization.prototype._getInfoFromChangeHandler = function(oAppComponent, oChange) {
333
388
  var oControl = JsControlTreeModifier.bySelector(oChange.getSelector(), oAppComponent);
334
389
  if (oControl) {
335
390
  var mPropertyBag = {
@@ -344,50 +399,54 @@ sap.ui.define([
344
399
  modifier: JsControlTreeModifier,
345
400
  layer: oChange.getLayer()
346
401
  })
347
- .then(function (oChangeHandler) {
348
- if (oChangeHandler && typeof oChangeHandler.getChangeVisualizationInfo === "function") {
349
- return oChangeHandler.getChangeVisualizationInfo(oChange, oAppComponent);
350
- }
351
- return undefined;
352
- })
353
- .catch(function(vErr) {
354
- Log.error(vErr);
355
- return undefined;
356
- });
402
+ .then(function(oChangeHandler) {
403
+ if (oChangeHandler && typeof oChangeHandler.getChangeVisualizationInfo === "function") {
404
+ return oChangeHandler.getChangeVisualizationInfo(oChange, oAppComponent);
405
+ }
406
+ return undefined;
407
+ })
408
+ .catch(function(vErr) {
409
+ Log.error(vErr);
410
+ return undefined;
411
+ });
357
412
  }
358
413
 
359
414
  return Promise.resolve();
360
415
  };
361
416
 
362
- ChangeVisualization.prototype._collectChanges = function () {
417
+ ChangeVisualization.prototype._collectChanges = function() {
363
418
  var oComponent = this._getComponent();
364
419
  var mPropertyBag = {
365
- oComponent: oComponent,
366
420
  selector: oComponent,
367
421
  invalidateCache: false,
368
- includeVariants: true,
369
422
  // includeCtrlVariants: true,
370
- currentLayer: Layer.CUSTOMER
423
+ currentLayer: Layer.CUSTOMER,
424
+ includeDirtyChanges: true,
425
+ onlyCurrentVariants: true
371
426
  };
372
427
  return PersistenceWriteAPI._getUIChanges(mPropertyBag);
373
428
  };
374
429
 
375
- ChangeVisualization.prototype._updateChangeRegistry = function () {
376
- return this._collectChanges().then(function (aChanges) {
430
+ ChangeVisualization.prototype._updateChangeRegistry = function() {
431
+ return this._collectChanges().then(function(aChanges) {
377
432
  var aRegisteredChangeIds = this._oChangeIndicatorRegistry.getChangeIds();
378
- var oCurrentChanges = aChanges.reduce(function (oChanges, oChange) {
379
- oChanges[oChange.getId()] = oChange;
380
- return oChanges;
381
- }, {});
433
+ var oCurrentChanges = aChanges
434
+ .filter(function(oChange) {
435
+ return oChange.getFileType() === 'change';
436
+ })
437
+ .reduce(function(oChanges, oChange) {
438
+ oChanges[oChange.getId()] = oChange;
439
+ return oChanges;
440
+ }, {});
382
441
  var aCurrentChangeIds = Object.keys(oCurrentChanges);
383
442
 
384
443
  // Remove registered changes which no longer exist
385
- difference(aRegisteredChangeIds, aCurrentChangeIds).forEach(function (sChangeIdToRemove) {
444
+ difference(aRegisteredChangeIds, aCurrentChangeIds).forEach(function(sChangeIdToRemove) {
386
445
  this._oChangeIndicatorRegistry.removeChange(sChangeIdToRemove);
387
446
  }.bind(this));
388
447
 
389
448
  // Register missing changes
390
- difference(aCurrentChangeIds, aRegisteredChangeIds).forEach(function (sChangeIdToAdd) {
449
+ difference(aCurrentChangeIds, aRegisteredChangeIds).forEach(function(sChangeIdToAdd) {
391
450
  var oChangeToAdd = oCurrentChanges[sChangeIdToAdd];
392
451
  var sCommandName = this._getCommandForChange(oChangeToAdd);
393
452
  this._oChangeIndicatorRegistry.registerChange(oChangeToAdd, sCommandName);
@@ -395,24 +454,24 @@ sap.ui.define([
395
454
  }.bind(this));
396
455
  };
397
456
 
398
- ChangeVisualization.prototype.selectChange = function (oEvent) {
457
+ ChangeVisualization.prototype.selectChange = function(oEvent) {
399
458
  var sChangeId = oEvent.getParameter("changeId");
400
459
  this._selectChange(sChangeId);
401
460
  };
402
461
 
403
- ChangeVisualization.prototype._selectChange = function (sChangeId) {
462
+ ChangeVisualization.prototype._selectChange = function(sChangeId) {
404
463
  var aDependentElements = this._oChangeIndicatorRegistry.getChange(sChangeId).visualizationInfo.dependentElementIds;
405
464
  aDependentElements.forEach(function(sElementId) {
406
465
  var oOverlayDomRef = OverlayRegistry.getOverlay(sElementId).getDomRef();
407
466
  oOverlayDomRef.scrollIntoViewIfNeeded();
408
467
  oOverlayDomRef.classList.add("sapUiRtaChangeIndicatorDependent");
409
- oOverlayDomRef.addEventListener("animationend", function () {
468
+ oOverlayDomRef.addEventListener("animationend", function() {
410
469
  oOverlayDomRef.classList.remove("sapUiRtaChangeIndicatorDependent");
411
- }, {once: true});
470
+ }, { once: true });
412
471
  });
413
472
  };
414
473
 
415
- ChangeVisualization.prototype._updateVisualizationModel = function (oData) {
474
+ ChangeVisualization.prototype._updateVisualizationModel = function(oData) {
416
475
  this._oChangeVisualizationModel.setData(Object.assign(
417
476
  {},
418
477
  this._oChangeVisualizationModel.getData(),
@@ -420,23 +479,27 @@ sap.ui.define([
420
479
  ));
421
480
  };
422
481
 
423
- ChangeVisualization.prototype._updateChangeIndicators = function () {
482
+ ChangeVisualization.prototype._updateChangeIndicators = function() {
424
483
  var oSelectors = this._oChangeIndicatorRegistry.getChangeIndicatorData();
425
484
  var oIndicators = {};
485
+ var aVisualizedChanges = [];
426
486
  Object.keys(oSelectors)
427
- .forEach(function (sSelectorId) {
487
+ .forEach(function(sSelectorId) {
428
488
  var aChanges = oSelectors[sSelectorId];
429
489
  var oOverlay = OverlayRegistry.getOverlay(sSelectorId);
430
- if (!oOverlay || !oOverlay.getDomRef()) {
490
+ if (!oOverlay || !oOverlay.getDomRef() || !oOverlay.isVisible()) {
431
491
  // Change is not visible
432
492
  return undefined;
433
493
  }
434
-
435
- var oOverlayPosition = oOverlay.getDomRef().getClientRects()[0] || {left: 0, top: 0};
494
+ var oOverlayPosition = oOverlay.getDomRef().getClientRects()[0] || { left: 0, top: 0 };
495
+ var aRelevantChanges = this._filterRelevantChanges(aChanges);
496
+ aRelevantChanges.forEach(function (oChange) {
497
+ aVisualizedChanges.push(oChange);
498
+ });
436
499
  oIndicators[sSelectorId] = {
437
500
  posX: parseInt(oOverlayPosition.left),
438
501
  posY: parseInt(oOverlayPosition.top),
439
- changes: this._filterRelevantChanges(aChanges)
502
+ changes: aRelevantChanges
440
503
  };
441
504
 
442
505
  if (!this._oChangeIndicatorRegistry.hasChangeIndicator(sSelectorId)) {
@@ -449,21 +512,25 @@ sap.ui.define([
449
512
  !deepEqual(
450
513
  oIndicators,
451
514
  this._oChangeVisualizationModel.getData().content
515
+ ) || !deepEqual(
516
+ aVisualizedChanges,
517
+ this._oChangeVisualizationModel.getData().visualizedChanges
452
518
  )
453
519
  ) {
454
520
  this._updateVisualizationModel({
455
- content: oIndicators
521
+ content: oIndicators,
522
+ visualizedChanges: aVisualizedChanges
456
523
  });
457
524
  }
458
525
  };
459
526
 
460
- ChangeVisualization.prototype._filterRelevantChanges = function (aChanges) {
527
+ ChangeVisualization.prototype._filterRelevantChanges = function(aChanges) {
461
528
  if (!Array.isArray(aChanges)) {
462
529
  return aChanges;
463
530
  }
464
531
  var oRootData = this._oChangeVisualizationModel.getData();
465
532
 
466
- return aChanges.filter(function (oChange) {
533
+ return aChanges.filter(function(oChange) {
467
534
  return (
468
535
  !oChange.dependent
469
536
  && (
@@ -474,7 +541,7 @@ sap.ui.define([
474
541
  });
475
542
  };
476
543
 
477
- ChangeVisualization.prototype._createChangeIndicator = function (oOverlay, sSelectorId) {
544
+ ChangeVisualization.prototype._createChangeIndicator = function(oOverlay, sSelectorId) {
478
545
  var oChangeIndicator = new ChangeIndicator({
479
546
  changes: "{changes}",
480
547
  posX: "{posX}",
@@ -494,17 +561,17 @@ sap.ui.define([
494
561
  this._oChangeIndicatorRegistry.registerChangeIndicator(sSelectorId, oChangeIndicator);
495
562
  };
496
563
 
497
- ChangeVisualization.prototype._setFocusedIndicator = function () {
564
+ ChangeVisualization.prototype._setFocusedIndicator = function() {
498
565
  // Sort the Indicators according XY-Position
499
566
  // Set the tabindex according the sorting
500
567
  // Focus the first visible indicator
501
568
  sap.ui.getCore().applyChanges();
502
569
 
503
570
  var aVisibleIndicators = this._oChangeIndicatorRegistry.getChangeIndicators()
504
- .filter(function (oIndicator) {
571
+ .filter(function(oIndicator) {
505
572
  return oIndicator.getVisible();
506
573
  })
507
- .sort(function (oIndicator1, oIndicator2) {
574
+ .sort(function(oIndicator1, oIndicator2) {
508
575
  var iDeltaY = oIndicator1.getPosY() - oIndicator2.getPosY();
509
576
  var iDeltaX = oIndicator1.getPosX() - oIndicator2.getPosX();
510
577
  // Only consider x value if y is the same
@@ -533,12 +600,12 @@ sap.ui.define([
533
600
  if (this.getIsActive()) {
534
601
  this.setIsActive(false);
535
602
  if (this.oRootOverlay) {
536
- this.oRootOverlay.getDomRef().removeEventListener("click", this._fnOnClickHandler, {capture: true});
603
+ this.oRootOverlay.getDomRef().removeEventListener("click", this._fnOnClickHandler, { capture: true });
537
604
  }
538
605
  return;
539
606
  }
540
607
  if (this.oRootOverlay) {
541
- this.oRootOverlay.getDomRef().addEventListener("click", this._fnOnClickHandler, {capture: true});
608
+ this.oRootOverlay.getDomRef().addEventListener("click", this._fnOnClickHandler, { capture: true });
542
609
  }
543
610
  if (!this.getRootControlId()) {
544
611
  this.setRootControlId(oRootControl);
@@ -0,0 +1,37 @@
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
+ ], function(
9
+ ) {
10
+ "use strict";
11
+
12
+ var ChangeVisualizationUtils = {};
13
+
14
+ /**
15
+ *
16
+ * Shortens a string if it is longer than 60 characters in the middle
17
+ * and only shows the first and last part of it.
18
+ *
19
+ * @param {string} sString - Any string
20
+ * @returns {string} Shortened string
21
+ * @private
22
+ */
23
+ ChangeVisualizationUtils.shortenString = function(sString) {
24
+ if (!sString) {
25
+ return null;
26
+ }
27
+ var iStringLength = sString.length;
28
+ if (iStringLength > 60) {
29
+ var sFirstPart = sString.substring(0, 27);
30
+ var sLastPart = sString.substring(iStringLength - 27);
31
+ sString = sFirstPart + "(...)" + sLastPart;
32
+ }
33
+ return sString;
34
+ };
35
+
36
+ return ChangeVisualizationUtils;
37
+ });
@@ -5,7 +5,11 @@
5
5
  */
6
6
 
7
7
  sap.ui.define([
8
+ "sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils",
9
+ "sap/ui/core/util/reflection/JsControlTreeModifier"
8
10
  ], function(
11
+ ChangeVisualizationUtils,
12
+ JsControlTreeModifier
9
13
  ) {
10
14
  "use strict";
11
15
 
@@ -17,13 +21,30 @@ sap.ui.define([
17
21
  *
18
22
  * @param {object} mPayload - Change visualization payload from the change handler
19
23
  * @param {string} sLabel - Change handler label
24
+ * @param {object} mPropertyBag - Additional properties
20
25
  * @returns {object} Localized description text and button text
21
26
  */
22
- MoveVisualization.getDescription = function (mPayload, sLabel) {
27
+ MoveVisualization.getDescription = function(mPayload, sLabel, mPropertyBag) {
23
28
  var oRtaResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.ui.rta");
24
- var sDescriptionText = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_MOVE", sLabel);
25
- var sButtonText = oRtaResourceBundle.getText("BTN_CHANGEVISUALIZATION_SHOW_DEPENDENT_CONTAINER_MOVE");
26
- return { descriptionText: sDescriptionText, buttonText: sButtonText};
29
+ var sDescriptionText = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_MOVE_WITHIN", ChangeVisualizationUtils.shortenString(sLabel));
30
+ var sDescriptionTooltip = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_MOVE_WITHIN", sLabel);
31
+ var sButtonText;
32
+ var oAppComponent = mPropertyBag.appComponent;
33
+ var sSourceParentId = (
34
+ mPayload.sourceParentContainer
35
+ && JsControlTreeModifier.getControlIdBySelector(mPayload.sourceParentContainer, oAppComponent)
36
+ );
37
+ var sTargetParentId = (
38
+ mPayload.targetParentContainer
39
+ && JsControlTreeModifier.getControlIdBySelector(mPayload.targetParentContainer, oAppComponent)
40
+ );
41
+
42
+ if (sSourceParentId !== sTargetParentId) {
43
+ sButtonText = oRtaResourceBundle.getText("BTN_CHANGEVISUALIZATION_SHOW_DEPENDENT_CONTAINER_MOVE");
44
+ sDescriptionText = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_MOVE", ChangeVisualizationUtils.shortenString(sLabel));
45
+ sDescriptionTooltip = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_MOVE", sLabel);
46
+ }
47
+ return { descriptionText: sDescriptionText, descriptionTooltip: sDescriptionTooltip, buttonText: sButtonText };
27
48
  };
28
49
 
29
50
  return MoveVisualization;
@@ -5,7 +5,9 @@
5
5
  */
6
6
 
7
7
  sap.ui.define([
8
+ "sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils"
8
9
  ], function(
10
+ ChangeVisualizationUtils
9
11
  ) {
10
12
  "use strict";
11
13
 
@@ -21,19 +23,29 @@ sap.ui.define([
21
23
  * @param {string} sFallbackLabel - New label as a fallback if change handler provides no info
22
24
  * @returns {object} Localized description
23
25
  */
24
- RenameVisualization.getDescription = function (mPayload, sFallbackLabel) {
26
+ RenameVisualization.getDescription = function(mPayload, sFallbackLabel) {
25
27
  var oRtaResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.ui.rta");
26
28
  var sKey = mPayload.originalLabel
27
29
  ? "TXT_CHANGEVISUALIZATION_CHANGE_RENAME_FROM_TO"
28
30
  : "TXT_CHANGEVISUALIZATION_CHANGE_RENAME_TO";
29
31
  var sDescriptionText = oRtaResourceBundle.getText(
32
+ sKey,
33
+ [
34
+ ChangeVisualizationUtils.shortenString(mPayload.newLabel) || sFallbackLabel,
35
+ ChangeVisualizationUtils.shortenString(mPayload.originalLabel)
36
+ ]
37
+ );
38
+ var sDescriptionTooltip = oRtaResourceBundle.getText(
30
39
  sKey,
31
40
  [
32
41
  mPayload.newLabel || sFallbackLabel,
33
42
  mPayload.originalLabel
34
43
  ]
35
44
  );
36
- return {descriptionText: sDescriptionText};
45
+ return {
46
+ descriptionText: sDescriptionText,
47
+ descriptionTooltip: sDescriptionTooltip
48
+ };
37
49
  };
38
50
 
39
51
  return RenameVisualization;
@@ -5,7 +5,9 @@
5
5
  */
6
6
 
7
7
  sap.ui.define([
8
+ "sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils"
8
9
  ], function(
10
+ ChangeVisualizationUtils
9
11
  ) {
10
12
  "use strict";
11
13
 
@@ -21,9 +23,10 @@ sap.ui.define([
21
23
  */
22
24
  SplitVisualization.getDescription = function (mPayload, sLabel) {
23
25
  var oRtaResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.ui.rta");
24
- var sDescriptionText = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_SPLIT", sLabel);
26
+ var sDescriptionText = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_SPLIT", ChangeVisualizationUtils.shortenString(sLabel));
27
+ var sDescriptionTooltip = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CHANGE_SPLIT", sLabel);
25
28
  var sButtonText = oRtaResourceBundle.getText("BTN_CHANGEVISUALIZATION_SHOW_DEPENDENT_CONTAINER_SPLIT");
26
- return { descriptionText: sDescriptionText, buttonText: sButtonText};
29
+ return { descriptionText: sDescriptionText, descriptionTooltip: sDescriptionTooltip, buttonText: sButtonText};
27
30
  };
28
31
 
29
32
  return SplitVisualization;