@openui5/sap.ui.rta 1.98.0 → 1.99.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/package.json +6 -6
  2. package/src/sap/ui/rta/.library +1 -1
  3. package/src/sap/ui/rta/Client.js +1 -1
  4. package/src/sap/ui/rta/RuntimeAuthoring.js +48 -41
  5. package/src/sap/ui/rta/Utils.js +2 -2
  6. package/src/sap/ui/rta/appContexts/AppContextsOverviewDialog.js +76 -0
  7. package/src/sap/ui/rta/appContexts/Component.js +31 -0
  8. package/src/sap/ui/rta/appContexts/controller/ManageContexts.controller.js +323 -0
  9. package/src/sap/ui/rta/appContexts/controller/RestAPIConnector.js +22 -0
  10. package/src/sap/ui/rta/appContexts/i18n/i18n.properties +47 -0
  11. package/src/sap/ui/rta/appContexts/i18n/i18n_ar.properties +23 -0
  12. package/src/sap/ui/rta/appContexts/i18n/i18n_bg.properties +23 -0
  13. package/src/sap/ui/rta/appContexts/i18n/i18n_ca.properties +23 -0
  14. package/src/sap/ui/rta/appContexts/i18n/i18n_cs.properties +23 -0
  15. package/src/sap/ui/rta/appContexts/i18n/i18n_cy.properties +23 -0
  16. package/src/sap/ui/rta/appContexts/i18n/i18n_da.properties +23 -0
  17. package/src/sap/ui/rta/appContexts/i18n/i18n_de.properties +23 -0
  18. package/src/sap/ui/rta/appContexts/i18n/i18n_el.properties +23 -0
  19. package/src/sap/ui/rta/appContexts/i18n/i18n_en.properties +23 -0
  20. package/src/sap/ui/rta/appContexts/i18n/i18n_en_GB.properties +23 -0
  21. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_sappsd.properties +23 -0
  22. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_saprigi.properties +23 -0
  23. package/src/sap/ui/rta/appContexts/i18n/i18n_en_US_saptrc.properties +23 -0
  24. package/src/sap/ui/rta/appContexts/i18n/i18n_es.properties +23 -0
  25. package/src/sap/ui/rta/appContexts/i18n/i18n_es_MX.properties +23 -0
  26. package/src/sap/ui/rta/appContexts/i18n/i18n_et.properties +23 -0
  27. package/src/sap/ui/rta/appContexts/i18n/i18n_fi.properties +23 -0
  28. package/src/sap/ui/rta/appContexts/i18n/i18n_fr.properties +23 -0
  29. package/src/sap/ui/rta/appContexts/i18n/i18n_fr_CA.properties +23 -0
  30. package/src/sap/ui/rta/appContexts/i18n/i18n_hi.properties +23 -0
  31. package/src/sap/ui/rta/appContexts/i18n/i18n_hr.properties +23 -0
  32. package/src/sap/ui/rta/appContexts/i18n/i18n_hu.properties +23 -0
  33. package/src/sap/ui/rta/appContexts/i18n/i18n_id.properties +23 -0
  34. package/src/sap/ui/rta/appContexts/i18n/i18n_it.properties +23 -0
  35. package/src/sap/ui/rta/appContexts/i18n/i18n_iw.properties +23 -0
  36. package/src/sap/ui/rta/appContexts/i18n/i18n_ja.properties +23 -0
  37. package/src/sap/ui/rta/appContexts/i18n/i18n_kk.properties +23 -0
  38. package/src/sap/ui/rta/appContexts/i18n/i18n_ko.properties +23 -0
  39. package/src/sap/ui/rta/appContexts/i18n/i18n_lt.properties +23 -0
  40. package/src/sap/ui/rta/appContexts/i18n/i18n_lv.properties +23 -0
  41. package/src/sap/ui/rta/appContexts/i18n/i18n_ms.properties +23 -0
  42. package/src/sap/ui/rta/appContexts/i18n/i18n_nl.properties +23 -0
  43. package/src/sap/ui/rta/appContexts/i18n/i18n_no.properties +23 -0
  44. package/src/sap/ui/rta/appContexts/i18n/i18n_pl.properties +23 -0
  45. package/src/sap/ui/rta/appContexts/i18n/i18n_pt.properties +23 -0
  46. package/src/sap/ui/rta/appContexts/i18n/i18n_pt_PT.properties +23 -0
  47. package/src/sap/ui/rta/appContexts/i18n/i18n_ro.properties +23 -0
  48. package/src/sap/ui/rta/appContexts/i18n/i18n_ru.properties +23 -0
  49. package/src/sap/ui/rta/appContexts/i18n/i18n_sh.properties +23 -0
  50. package/src/sap/ui/rta/appContexts/i18n/i18n_sk.properties +23 -0
  51. package/src/sap/ui/rta/appContexts/i18n/i18n_sl.properties +23 -0
  52. package/src/sap/ui/rta/appContexts/i18n/i18n_sv.properties +23 -0
  53. package/src/sap/ui/rta/appContexts/i18n/i18n_th.properties +23 -0
  54. package/src/sap/ui/rta/appContexts/i18n/i18n_tr.properties +23 -0
  55. package/src/sap/ui/rta/appContexts/i18n/i18n_uk.properties +23 -0
  56. package/src/sap/ui/rta/appContexts/i18n/i18n_vi.properties +23 -0
  57. package/src/sap/ui/rta/appContexts/i18n/i18n_zh_CN.properties +23 -0
  58. package/src/sap/ui/rta/appContexts/i18n/i18n_zh_TW.properties +23 -0
  59. package/src/sap/ui/rta/appContexts/index.html +25 -0
  60. package/src/sap/ui/rta/appContexts/manifest.json +52 -0
  61. package/src/sap/ui/rta/appContexts/view/EditContextsDialog.fragment.xml +76 -0
  62. package/src/sap/ui/rta/appContexts/view/ManageContexts.view.xml +103 -0
  63. package/src/sap/ui/rta/appContexts/view/SaveAsContextsDialog.fragment.xml +76 -0
  64. package/src/sap/ui/rta/appVariant/AppVariantDialog.js +6 -3
  65. package/src/sap/ui/rta/appVariant/AppVariantManager.js +11 -11
  66. package/src/sap/ui/rta/appVariant/Feature.js +16 -6
  67. package/src/sap/ui/rta/command/AddIFrame.js +1 -1
  68. package/src/sap/ui/rta/command/AddProperty.js +1 -1
  69. package/src/sap/ui/rta/command/AddXML.js +1 -1
  70. package/src/sap/ui/rta/command/AddXMLAtExtensionPoint.js +1 -1
  71. package/src/sap/ui/rta/command/AppDescriptorCommand.js +1 -1
  72. package/src/sap/ui/rta/command/BaseCommand.js +1 -1
  73. package/src/sap/ui/rta/command/BindProperty.js +1 -1
  74. package/src/sap/ui/rta/command/Combine.js +5 -1
  75. package/src/sap/ui/rta/command/CommandFactory.js +15 -11
  76. package/src/sap/ui/rta/command/CompositeCommand.js +1 -1
  77. package/src/sap/ui/rta/command/ControlVariantConfigure.js +1 -1
  78. package/src/sap/ui/rta/command/ControlVariantSave.js +1 -1
  79. package/src/sap/ui/rta/command/ControlVariantSaveAs.js +1 -1
  80. package/src/sap/ui/rta/command/ControlVariantSetTitle.js +1 -1
  81. package/src/sap/ui/rta/command/ControlVariantSwitch.js +1 -1
  82. package/src/sap/ui/rta/command/CreateContainer.js +1 -1
  83. package/src/sap/ui/rta/command/CustomAdd.js +1 -1
  84. package/src/sap/ui/rta/command/FlexCommand.js +1 -1
  85. package/src/sap/ui/rta/command/LREPSerializer.js +1 -1
  86. package/src/sap/ui/rta/command/LocalReset.js +1 -1
  87. package/src/sap/ui/rta/command/Move.js +1 -1
  88. package/src/sap/ui/rta/command/Property.js +1 -1
  89. package/src/sap/ui/rta/command/Remove.js +1 -1
  90. package/src/sap/ui/rta/command/Rename.js +1 -1
  91. package/src/sap/ui/rta/command/Reveal.js +1 -1
  92. package/src/sap/ui/rta/command/Settings.js +1 -1
  93. package/src/sap/ui/rta/command/Split.js +1 -1
  94. package/src/sap/ui/rta/command/Stack.js +1 -1
  95. package/src/sap/ui/rta/command/appDescriptor/AddLibrary.js +1 -1
  96. package/src/sap/ui/rta/command/compVariant/CompVariantSaveAs.js +1 -1
  97. package/src/sap/ui/rta/command/compVariant/CompVariantSwitch.js +1 -1
  98. package/src/sap/ui/rta/command/compVariant/CompVariantUpdate.js +1 -1
  99. package/src/sap/ui/rta/enablement/elementActionTest.js +1 -1
  100. package/src/sap/ui/rta/library.js +2 -2
  101. package/src/sap/ui/rta/messagebundle.properties +7 -4
  102. package/src/sap/ui/rta/messagebundle_ar.properties +5 -3
  103. package/src/sap/ui/rta/messagebundle_bg.properties +7 -5
  104. package/src/sap/ui/rta/messagebundle_ca.properties +5 -3
  105. package/src/sap/ui/rta/messagebundle_cs.properties +5 -3
  106. package/src/sap/ui/rta/messagebundle_cy.properties +5 -3
  107. package/src/sap/ui/rta/messagebundle_da.properties +5 -3
  108. package/src/sap/ui/rta/messagebundle_de.properties +5 -3
  109. package/src/sap/ui/rta/messagebundle_el.properties +5 -3
  110. package/src/sap/ui/rta/messagebundle_en.properties +5 -3
  111. package/src/sap/ui/rta/messagebundle_en_GB.properties +5 -3
  112. package/src/sap/ui/rta/messagebundle_en_US_sappsd.properties +5 -3
  113. package/src/sap/ui/rta/messagebundle_en_US_saprigi.properties +39 -20
  114. package/src/sap/ui/rta/messagebundle_en_US_saptrc.properties +5 -3
  115. package/src/sap/ui/rta/messagebundle_es.properties +5 -3
  116. package/src/sap/ui/rta/messagebundle_es_MX.properties +6 -4
  117. package/src/sap/ui/rta/messagebundle_et.properties +5 -3
  118. package/src/sap/ui/rta/messagebundle_fi.properties +5 -3
  119. package/src/sap/ui/rta/messagebundle_fr.properties +5 -3
  120. package/src/sap/ui/rta/messagebundle_fr_CA.properties +5 -3
  121. package/src/sap/ui/rta/messagebundle_hi.properties +5 -3
  122. package/src/sap/ui/rta/messagebundle_hr.properties +5 -3
  123. package/src/sap/ui/rta/messagebundle_hu.properties +5 -3
  124. package/src/sap/ui/rta/messagebundle_id.properties +5 -3
  125. package/src/sap/ui/rta/messagebundle_it.properties +5 -3
  126. package/src/sap/ui/rta/messagebundle_iw.properties +5 -3
  127. package/src/sap/ui/rta/messagebundle_ja.properties +5 -3
  128. package/src/sap/ui/rta/messagebundle_kk.properties +5 -3
  129. package/src/sap/ui/rta/messagebundle_ko.properties +5 -3
  130. package/src/sap/ui/rta/messagebundle_lt.properties +5 -3
  131. package/src/sap/ui/rta/messagebundle_lv.properties +7 -5
  132. package/src/sap/ui/rta/messagebundle_ms.properties +5 -3
  133. package/src/sap/ui/rta/messagebundle_nl.properties +5 -3
  134. package/src/sap/ui/rta/messagebundle_no.properties +5 -3
  135. package/src/sap/ui/rta/messagebundle_pl.properties +5 -3
  136. package/src/sap/ui/rta/messagebundle_pt.properties +5 -3
  137. package/src/sap/ui/rta/messagebundle_pt_PT.properties +5 -3
  138. package/src/sap/ui/rta/messagebundle_ro.properties +5 -3
  139. package/src/sap/ui/rta/messagebundle_ru.properties +5 -3
  140. package/src/sap/ui/rta/messagebundle_sh.properties +5 -3
  141. package/src/sap/ui/rta/messagebundle_sk.properties +6 -4
  142. package/src/sap/ui/rta/messagebundle_sl.properties +5 -3
  143. package/src/sap/ui/rta/messagebundle_sv.properties +5 -3
  144. package/src/sap/ui/rta/messagebundle_th.properties +5 -3
  145. package/src/sap/ui/rta/messagebundle_tr.properties +5 -3
  146. package/src/sap/ui/rta/messagebundle_uk.properties +4 -2
  147. package/src/sap/ui/rta/messagebundle_vi.properties +5 -3
  148. package/src/sap/ui/rta/messagebundle_zh_CN.properties +5 -3
  149. package/src/sap/ui/rta/messagebundle_zh_TW.properties +5 -3
  150. package/src/sap/ui/rta/plugin/AddXMLAtExtensionPoint.js +1 -1
  151. package/src/sap/ui/rta/plugin/BaseCreate.js +1 -1
  152. package/src/sap/ui/rta/plugin/Combine.js +10 -3
  153. package/src/sap/ui/rta/plugin/ControlVariant.js +3 -3
  154. package/src/sap/ui/rta/plugin/CreateContainer.js +1 -1
  155. package/src/sap/ui/rta/plugin/CutPaste.js +1 -1
  156. package/src/sap/ui/rta/plugin/DragDrop.js +1 -1
  157. package/src/sap/ui/rta/plugin/EasyAdd.js +1 -1
  158. package/src/sap/ui/rta/plugin/EasyRemove.js +1 -1
  159. package/src/sap/ui/rta/plugin/LocalReset.js +1 -1
  160. package/src/sap/ui/rta/plugin/Plugin.js +1 -1
  161. package/src/sap/ui/rta/plugin/RTAElementMover.js +1 -1
  162. package/src/sap/ui/rta/plugin/Remove.js +2 -2
  163. package/src/sap/ui/rta/plugin/Rename.js +1 -1
  164. package/src/sap/ui/rta/plugin/RenameHandler.js +1 -1
  165. package/src/sap/ui/rta/plugin/Selection.js +21 -8
  166. package/src/sap/ui/rta/plugin/Settings.js +1 -1
  167. package/src/sap/ui/rta/plugin/Split.js +1 -1
  168. package/src/sap/ui/rta/plugin/Stretch.js +1 -1
  169. package/src/sap/ui/rta/plugin/additionalElements/ActionExtractor.js +39 -38
  170. package/src/sap/ui/rta/plugin/additionalElements/AddElementsDialog.js +1 -1
  171. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsPlugin.js +1 -1
  172. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsUtils.js +1 -1
  173. package/src/sap/ui/rta/plugin/additionalElements/CommandBuilder.js +1 -1
  174. package/src/sap/ui/rta/plugin/iframe/AddIFrame.js +1 -1
  175. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.js +1 -1
  176. package/src/sap/ui/rta/service/Action.js +1 -1
  177. package/src/sap/ui/rta/service/ControllerExtension.js +1 -1
  178. package/src/sap/ui/rta/service/Outline.js +1 -1
  179. package/src/sap/ui/rta/service/Property.js +1 -1
  180. package/src/sap/ui/rta/service/Selection.js +1 -1
  181. package/src/sap/ui/rta/themes/base/ChangeVisualization.less +42 -53
  182. package/src/sap/ui/rta/toolbar/Adaptation.js +1 -1
  183. package/src/sap/ui/rta/toolbar/Base.js +1 -1
  184. package/src/sap/ui/rta/toolbar/Fiori.js +1 -1
  185. package/src/sap/ui/rta/toolbar/FioriLike.js +1 -1
  186. package/src/sap/ui/rta/toolbar/OverflowToolbarButton.js +1 -1
  187. package/src/sap/ui/rta/toolbar/Personalization.js +1 -1
  188. package/src/sap/ui/rta/toolbar/Standalone.js +1 -1
  189. package/src/sap/ui/rta/toolbar/translation/Translation.js +52 -31
  190. package/src/sap/ui/rta/util/PluginManager.js +1 -1
  191. package/src/sap/ui/rta/util/PopupManager.js +1 -1
  192. package/src/sap/ui/rta/util/ServiceEventBus.js +1 -1
  193. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicator.js +107 -59
  194. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorPopover.fragment.xml +6 -5
  195. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry.js +1 -1
  196. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualization.js +64 -60
  197. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils.js +37 -0
  198. package/src/sap/ui/rta/util/changeVisualization/categories/MoveVisualization.js +5 -2
  199. package/src/sap/ui/rta/util/changeVisualization/categories/RenameVisualization.js +14 -2
  200. package/src/sap/ui/rta/util/changeVisualization/categories/SplitVisualization.js +5 -2
@@ -1,50 +1,59 @@
1
1
  /******************************************************************
2
2
  Style of the RTA Change Visualization - base theme
3
3
  *******************************************************************/
4
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColor: rgba(131, 201, 233, 0.75);
5
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorFocus: #1c678a;
6
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorHover: rgba(14, 138, 195, 0.75);
7
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolid: rgb(131, 201, 233);
8
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolidBG: white;
9
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolidHover: #0f648b;
10
- @_sap_ui_rta_ChangeVisualization_DependentIndicatorColor: rgba(219,149,51,0.75);
11
- @_sap_ui_rta_ChangeVisualization_DependentIndicatorColorTransparent: rgba(219,149,51,0);
12
- @_sap_ui_rta_ChangeVisualization_DependentIndicatorColorFocus: #a67026;
13
- @_sap_ui_rta_ChangeVisualization_DependentIndicatorColorSolid: rgb(219, 149, 51);
14
- @_sap_ui_rta_ChangeVisualization_DependentIndicatorColorSolidHover: #b67a26;
15
- @_sap_ui_rta_ChangeVisualization_ChangeIndicatorTextColor: #1c678a;
4
+ @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorLight: @sapUiChartPaletteSequentialHue1Light1;
5
+ @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorMedium: @sapUiChartPaletteSequentialHue1Dark1;
6
+ @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark: @sapUiChartPaletteSequentialHue11Dark2;
7
+ @_sap_ui_rta_ChangeVisualization_DependentIndicatorColorTransparent: @sapUiGroupTitleBackground;
16
8
 
17
9
  .sapUiRtaChangeIndicator{
18
- border-radius: 25px;
19
- z-index: 1000;
10
+ height: 0.8rem;
11
+ width: 0.8rem;
20
12
  position: relative;
13
+ border-radius: 50%;
14
+ margin-top: 0.25rem;
15
+ margin-left: 0.25rem;
16
+ transition: width 0.3s, height 0.3s, box-shadow 0.3s;
21
17
  cursor: pointer;
22
18
  }
23
19
 
24
- .sapUiRtaChangeIndicatorChange{
25
- border: 1px solid @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColor;
26
- background: white;
27
- background: radial-gradient(circle, transparent 41%, @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColor 72%, @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolid 100%);
20
+ .sapUiRtaChangeIndicator:focus{
21
+ outline: 0;
22
+ }
28
23
 
29
- &:focus{
30
- border: 1px solid @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorFocus;
31
- outline: none;
32
- }
24
+ .sapUiRtaChangeIndicatorColorLight{
25
+ background-color: @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorLight;
26
+ opacity: 0.6;
27
+ }
33
28
 
34
- &:hover{
35
- background: radial-gradient(circle, transparent 41%, @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorHover 62%, @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolidHover 100%);
29
+ .sapUiRtaChangeIndicatorColorMedium{
30
+ background-color: @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorMedium;
31
+ opacity: 0.75;
32
+ }
36
33
 
37
- .sapUiRtaChangeIndicatorText{
38
- color:white;
39
- }
40
- }
34
+ .sapUiRtaChangeIndicatorColorDark{
35
+ background-color: @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark;
36
+ opacity: 0.75;
37
+ }
38
+
39
+ .sapUiRtaChangeIndicatorVerticallyCentered{
40
+ top: 50%;
41
+ transform: translateY(-50%);
42
+ margin-top: 0;
43
+ }
44
+
45
+ .sapUiRtaHover{
46
+ height: 0.9rem;
47
+ width: 0.9rem;
48
+ box-shadow: 0 0 0.25rem @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark;
41
49
  }
42
50
 
43
51
  .sapUiRtaChangeIndicatorDependent{
44
52
  height: 100%;
45
- width: 100%;
53
+ width: auto;
54
+ display: block;
46
55
  position: absolute;
47
- outline: 3px solid @_sap_ui_rta_ChangeVisualization_DependentIndicatorColor;
56
+ outline: 3px solid @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark;
48
57
  outline-offset: -3px;
49
58
  box-shadow: @_sap_ui_rta_Overlay_BoxShadow;
50
59
  animation: fadeOut linear 1.5s;
@@ -52,11 +61,11 @@
52
61
 
53
62
  @keyframes fadeOut {
54
63
  0% {
55
- outline: 3px solid @_sap_ui_rta_ChangeVisualization_DependentIndicatorColor;
64
+ outline: 3px solid @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark;
56
65
  outline-offset: -3px;
57
66
  }
58
67
  66%{
59
- outline: 3px solid @_sap_ui_rta_ChangeVisualization_DependentIndicatorColor;
68
+ outline: 3px solid @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorDark;
60
69
  outline-offset: -3px;
61
70
  }
62
71
  100% {
@@ -67,28 +76,8 @@
67
76
  }
68
77
  }
69
78
 
70
- .sapUiRtaChangeIndicatorText{
71
- top: 0;
72
- left: 0;
73
- position: absolute;
74
- width: 50%;
75
- height: 50%;
76
- border-radius: 50%;
77
- background: @_sap_ui_rta_ChangeVisualization_ChangeIndicatorColorSolid;
78
- color: black;
79
- display: flex;
80
- justify-content: center;
81
- align-items: center;
82
- opacity: 0.8;
83
- cursor: pointer;
84
- }
85
-
86
79
  .sapUiRtaChangeIndicatorHovered {
87
- -webkit-transition: background 0.1s cubic-bezier(1,.01,1,0);
88
- -moz-transition: background 0.1s cubic-bezier(1,.01,1,0);
89
- -o-transition: background 0.1s cubic-bezier(1,.01,1,0);
90
- transition: background 0.1s cubic-bezier(1,.01,1,0);
91
-
80
+ cursor: pointer!important;
92
81
  &:after {
93
82
  content: " ";
94
83
  border: 0.0625rem solid @_sap_ui_rta_Overlay_HoverBorder!important; //1px
@@ -39,7 +39,7 @@ function(
39
39
  * @extends sap.ui.rta.toolbar.Base
40
40
  *
41
41
  * @author SAP SE
42
- * @version 1.98.0
42
+ * @version 1.99.0
43
43
  *
44
44
  * @constructor
45
45
  * @private
@@ -25,7 +25,7 @@ sap.ui.define([
25
25
  * @extends sap.m.HBox
26
26
  *
27
27
  * @author SAP SE
28
- * @version 1.98.0
28
+ * @version 1.99.0
29
29
  *
30
30
  * @constructor
31
31
  * @private
@@ -32,7 +32,7 @@ function(
32
32
  * @extends sap.ui.rta.toolbar.Adaptation
33
33
  *
34
34
  * @author SAP SE
35
- * @version 1.98.0
35
+ * @version 1.99.0
36
36
  *
37
37
  * @constructor
38
38
  * @private
@@ -20,7 +20,7 @@ function(
20
20
  * @extends sap.ui.rta.toolbar.Adaptation
21
21
  *
22
22
  * @author SAP SE
23
- * @version 1.98.0
23
+ * @version 1.99.0
24
24
  *
25
25
  * @constructor
26
26
  * @private
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @extends sap.m.OverflowToolbarButton
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.98.0
26
+ * @version 1.99.0
27
27
  *
28
28
  * @constructor
29
29
  * @private
@@ -22,7 +22,7 @@ function(
22
22
  * @extends sap.ui.rta.toolbar.Base
23
23
  *
24
24
  * @author SAP SE
25
- * @version 1.98.0
25
+ * @version 1.99.0
26
26
  *
27
27
  * @constructor
28
28
  * @private
@@ -20,7 +20,7 @@ function(
20
20
  * @extends sap.ui.rta.toolbar.Adaptation
21
21
  *
22
22
  * @author SAP SE
23
- * @version 1.98.0
23
+ * @version 1.99.0
24
24
  *
25
25
  * @constructor
26
26
  * @private
@@ -4,6 +4,8 @@
4
4
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
5
  */
6
6
 
7
+ /* global FormData */
8
+
7
9
  sap.ui.define([
8
10
  "sap/ui/base/ManagedObject",
9
11
  "sap/ui/core/Fragment",
@@ -15,8 +17,7 @@ sap.ui.define([
15
17
  "sap/ui/fl/write/api/TranslationAPI",
16
18
  "sap/ui/fl/Layer",
17
19
  "sap/ui/core/util/File"
18
- ],
19
- function(
20
+ ], function(
20
21
  ManagedObject,
21
22
  Fragment,
22
23
  Utils,
@@ -30,6 +31,34 @@ function(
30
31
  ) {
31
32
  "use strict";
32
33
 
34
+ /**
35
+ * Controller for the <code>sap.ui.rta.toolbar.translation.Translation</code> controls.
36
+ * Contains implementation of translation functionality.
37
+ *
38
+ * @class
39
+ *
40
+ * @author SAP SE
41
+ * @version 1.99.0
42
+ *
43
+ * @constructor
44
+ * @private
45
+ * @since 1.93
46
+ * @alias sap.ui.rta.toolbar.translation.Translation
47
+ */
48
+ var Translation = ManagedObject.extend("sap.ui.rta.toolbar.translation.Translation", {
49
+ metadata: {
50
+ properties: {
51
+ toolbar: {
52
+ type: "sap.ui.rta.toolbar.Base"
53
+ }
54
+ }
55
+ },
56
+ constructor: function () {
57
+ ManagedObject.prototype.constructor.apply(this, arguments);
58
+ this._oTranslationModel = new JSONModel(getTranslationModelData());
59
+ }
60
+ });
61
+
33
62
  function saveFiles(oEvent) {
34
63
  this._oTranslationModel.setProperty("/file", oEvent.getParameter("files")[0]);
35
64
  }
@@ -82,7 +111,8 @@ function(
82
111
  onCancelUploadDialog: function () {
83
112
  this._oDialogUpload.close();
84
113
  }.bind(this),
85
- saveFiles: saveFiles.bind(this)
114
+ saveFiles: saveFiles.bind(this),
115
+ handleUploadPress: handleUploadPress.bind(this, sUploadId)
86
116
  }
87
117
  }).then(function (oTranslationDialog) {
88
118
  this._oDialogUpload = oTranslationDialog;
@@ -92,6 +122,25 @@ function(
92
122
  }.bind(this));
93
123
  }
94
124
 
125
+
126
+ function handleUploadPress(sUploadId) {
127
+ var oFileUploader = sap.ui.getCore().byId(sUploadId + "--fileUploader");
128
+ oFileUploader.checkFileReadable().then(function() {
129
+ if (this._oTranslationModel.getProperty("/file")) {
130
+ var mPropertyBag = {
131
+ layer: Layer.CUSTOMER,
132
+ payload: new FormData()
133
+ };
134
+ mPropertyBag.payload.append("file", this._oTranslationModel.getProperty("/file"), oFileUploader.getValue());
135
+ TranslationAPI.postTranslationTexts(mPropertyBag).then(function () {
136
+ MessageToast.show("Translation texts import successful");
137
+ }).catch(function (sError) {
138
+ MessageBox.error("Translation texts import failed: " + sError);
139
+ }).finally(oFileUploader.clear.bind(oFileUploader));
140
+ }
141
+ }.bind(this));
142
+ }
143
+
95
144
  function getTranslationModelData() {
96
145
  return Object.assign({}, {
97
146
  sourceLanguage: "",
@@ -101,34 +150,6 @@ function(
101
150
  });
102
151
  }
103
152
 
104
- /**
105
- * Controller for the <code>sap.ui.rta.toolbar.translation.Translation</code> controls.
106
- * Contains implementation of translation functionality.
107
- *
108
- * @class
109
- *
110
- * @author SAP SE
111
- * @version 1.98.0
112
- *
113
- * @constructor
114
- * @private
115
- * @since 1.93
116
- * @alias sap.ui.rta.toolbar.translation.Translation
117
- */
118
- var Translation = ManagedObject.extend("sap.ui.rta.toolbar.translation.Translation", {
119
- metadata: {
120
- properties: {
121
- toolbar: {
122
- type: "sap.ui.rta.toolbar.Base"
123
- }
124
- }
125
- },
126
- constructor: function () {
127
- ManagedObject.prototype.constructor.apply(this, arguments);
128
- this._oTranslationModel = new JSONModel(getTranslationModelData());
129
- }
130
- });
131
-
132
153
  Translation.prototype.showTranslationPopover = function (oEvent) {
133
154
  var oTranslationButton = oEvent.getSource();
134
155
 
@@ -66,7 +66,7 @@ sap.ui.define([
66
66
  * Constructor for a new sap.ui.rta.util.PluginManager
67
67
  * @extends sap.ui.base.ManagedObject
68
68
  * @author SAP SE
69
- * @version 1.98.0
69
+ * @version 1.99.0
70
70
  * @constructor
71
71
  * @private
72
72
  * @since 1.86
@@ -40,7 +40,7 @@ sap.ui.define([
40
40
  * Constructor for a new sap.ui.rta.util.PopupManager
41
41
  * @extends sap.ui.base.ManagedObject
42
42
  * @author SAP SE
43
- * @version 1.98.0
43
+ * @version 1.99.0
44
44
  * @constructor
45
45
  * @private
46
46
  * @since 1.48
@@ -19,7 +19,7 @@ function(
19
19
  *
20
20
  * @extends sap.ui.core.EventBus
21
21
  * @author SAP SE
22
- * @version 1.98.0
22
+ * @version 1.99.0
23
23
  * @private
24
24
  * @since 1.56.0
25
25
  * @alias sap.ui.rta.util.ServiceEventBus
@@ -13,7 +13,9 @@ sap.ui.define([
13
13
  "sap/ui/events/KeyCodes",
14
14
  "sap/ui/rta/util/changeVisualization/categories/getVisualizationCategory",
15
15
  "sap/ui/fl/Utils",
16
- "sap/ui/fl/util/resolveBinding"
16
+ "sap/ui/fl/util/resolveBinding",
17
+ "sap/ui/rta/util/changeVisualization/ChangeVisualizationUtils",
18
+ "sap/ui/core/Core"
17
19
  ], function(
18
20
  Fragment,
19
21
  JSONModel,
@@ -23,9 +25,20 @@ sap.ui.define([
23
25
  KeyCodes,
24
26
  getVisualizationCategory,
25
27
  FlUtils,
26
- resolveBinding
28
+ resolveBinding,
29
+ ChangeVisualizationUtils,
30
+ Core
27
31
  ) {
28
32
  "use strict";
33
+
34
+ var CATEGORY_ICONS = {
35
+ add: "sap-icon://add",
36
+ move: "sap-icon://move",
37
+ rename: "sap-icon://edit",
38
+ combinesplit: "sap-icon://combine",
39
+ remove: "sap-icon://less"
40
+ };
41
+
29
42
  /**
30
43
  * @class
31
44
  * Constructor for a new <code>sap.ui.rta.util.changeVisualization.ChangeIndicator</code> class.
@@ -35,7 +48,7 @@ sap.ui.define([
35
48
  * @alias sap.ui.rta.util.changeVisualization.ChangeIndicator
36
49
  * @author SAP SE
37
50
  * @since 1.84.0
38
- * @version 1.98.0
51
+ * @version 1.99.0
39
52
  * @private
40
53
  */
41
54
  var ChangeIndicator = Control.extend("sap.ui.rta.util.changeVisualization.ChangeIndicator", {
@@ -79,11 +92,6 @@ sap.ui.define([
79
92
  type: "sap.m.Popover",
80
93
  multiple: false,
81
94
  visibility: "hidden"
82
- },
83
- _text: {
84
- type: "sap.m.Text",
85
- multiple: false,
86
- visibility: "hidden"
87
95
  }
88
96
  },
89
97
  events: {
@@ -115,59 +123,87 @@ sap.ui.define([
115
123
  oRm.openStart("div", oControl);
116
124
  oRm.class("sapUiRtaChangeIndicator");
117
125
  oRm.class("sapUiRtaChangeIndicatorChange");
118
- oRm.style("width", oControl._getSize() + "px");
119
- oRm.style("height", oControl._getSize() + "px");
120
- oRm.openEnd();
121
- oRm.openStart("div");
126
+ if (oControl.getChanges().length > 4) {
127
+ oRm.class("sapUiRtaChangeIndicatorColorDark");
128
+ } else if (oControl.getChanges().length > 1) {
129
+ oRm.class("sapUiRtaChangeIndicatorColorMedium");
130
+ } else {
131
+ oRm.class("sapUiRtaChangeIndicatorColorLight");
132
+ }
122
133
  oRm.openEnd();
123
- oRm.renderControl(oControl.getAggregation("_text"));
124
- oRm.close("div");
125
134
  oRm.close("div");
126
135
  }
127
136
  },
128
- constructor: function () {
137
+ constructor: function() {
129
138
  this._oDetailModel = new JSONModel();
130
139
  this._oDetailModel.setDefaultBindingMode("OneWay");
131
140
 
132
141
  Control.prototype.constructor.apply(this, arguments);
142
+
143
+ this._fnHoverTrue = this._toggleHoverStyleClasses.bind(this, true);
144
+ this._fnHoverFalse = this._toggleHoverStyleClasses.bind(this, false);
133
145
  }
134
146
  });
135
147
 
136
- ChangeIndicator.prototype.init = function () {
148
+ function handleBrowserEventsOnElement(oElement, sEventHandler) {
149
+ oElement[sEventHandler]("click", this._onSelect, this);
150
+ oElement[sEventHandler]("tap", this._onSelect, this);
151
+ oElement[sEventHandler]("keydown", this._onKeyDown, this);
152
+ oElement[sEventHandler]("mouseout", this._fnHoverFalse);
153
+ oElement[sEventHandler]("focusout", this._fnHoverFalse);
154
+ oElement[sEventHandler]("mouseover", this._fnHoverTrue);
155
+ oElement[sEventHandler]("focusin", this._fnHoverTrue);
156
+ }
157
+
158
+ function centerVertically(oIndicator) {
159
+ var oIndicatorDomRef = oIndicator.getDomRef();
160
+ var iOverlayHeight = document.getElementById(oIndicator.getOverlayId()).offsetHeight;
161
+ var iIndicatorHeight = oIndicatorDomRef.offsetHeight;
162
+ // the indicator should be centered only if the element has a small enough height to improve the design and visibility
163
+ if (iOverlayHeight < iIndicatorHeight * 5) {
164
+ oIndicator.addStyleClass("sapUiRtaChangeIndicatorVerticallyCentered");
165
+ }
166
+ }
167
+
168
+ ChangeIndicator.prototype.init = function() {
137
169
  this._iOldTabIndex = 0;
138
- this.setAggregation("_text", new Text({
139
- text: "{= (${changes} || []).length}",
140
- visible: "{= (${changes} || []).length > 1}"
141
- }).addStyleClass("sapUiRtaChangeIndicatorText"));
170
+ handleBrowserEventsOnElement.call(this, this, "attachBrowserEvent");
171
+ };
142
172
 
143
- this.attachBrowserEvent("click", this._onSelect, this);
144
- this.attachBrowserEvent("tap", this._onSelect, this);
145
- this.attachBrowserEvent("keydown", this._onKeyDown, this);
146
- this.attachBrowserEvent("mouseleave", function() {this._toggleHoverStyleClasses(false); }, this);
147
- this.attachBrowserEvent("focusout", function() {this._toggleHoverStyleClasses(false); }, this);
148
- this.attachBrowserEvent("mouseover", function() {this._toggleHoverStyleClasses(true); }, this);
149
- this.attachBrowserEvent("focusin", function() {this._toggleHoverStyleClasses(true); }, this);
173
+ ChangeIndicator.prototype.setVisible = function(bVisible) {
174
+ Control.prototype.setVisible.apply(this, arguments);
175
+ var oOverlay = Core.byId(this.getOverlayId());
176
+ // needed because the change indicator cleanup is only triggered on save and exit
177
+ if (oOverlay) {
178
+ if (bVisible) {
179
+ handleBrowserEventsOnElement.call(this, oOverlay, "attachBrowserEvent");
180
+ } else {
181
+ handleBrowserEventsOnElement.call(this, oOverlay, "detachBrowserEvent");
182
+ if (this.getAggregation("_popover")) {
183
+ this.getAggregation("_popover").destroy();
184
+ }
185
+ }
186
+ }
187
+ return this;
150
188
  };
151
189
 
152
- ChangeIndicator.prototype.focus = function () {
190
+ ChangeIndicator.prototype.focus = function() {
153
191
  if (this.getDomRef()) {
154
192
  // Element is rendered, focus immediately
155
193
  Control.prototype.focus.apply(this, arguments);
156
194
  this._bScheduledForFocus = false;
195
+ return;
157
196
  }
158
197
  this._bScheduledForFocus = true;
159
198
  };
160
199
 
161
- ChangeIndicator.prototype._getSize = function () {
162
- var oOverlay = document.getElementById(this.getOverlayId());
163
- var iSize = oOverlay.offsetHeight;
164
- return (iSize > 50 ? 50 : iSize) - 2;
165
- };
166
-
167
- ChangeIndicator.prototype.onAfterRendering = function () {
168
- // Attach to the overlay
200
+ ChangeIndicator.prototype.onAfterRendering = function() {
169
201
  var oOverlay = document.getElementById(this.getOverlayId());
170
- oOverlay.appendChild(this.getDomRef());
202
+ if (oOverlay) {
203
+ // Attach to the overlay
204
+ oOverlay.appendChild(this.getDomRef());
205
+ centerVertically(this);
206
+ }
171
207
  // Restore the Tabindex if stored before; set to 0 as default
172
208
  this.getDomRef().tabIndex = this._iOldTabIndex;
173
209
 
@@ -178,21 +214,27 @@ sap.ui.define([
178
214
  }
179
215
  };
180
216
 
181
- ChangeIndicator.prototype.exit = function () {
217
+ ChangeIndicator.prototype.exit = function() {
182
218
  var oDomRef = this.getDomRef();
219
+ var oOverlay = Core.byId(this.getOverlayId());
183
220
  if (oDomRef) {
184
221
  oDomRef.parentNode.removeChild(oDomRef);
185
222
  }
186
- this.detachBrowserEvent("click", this._onSelect, this);
187
- this.detachBrowserEvent("keydown", this._onKeyDown, this);
223
+ if (oOverlay) {
224
+ if (this.getAggregation("_popover")) {
225
+ this.getAggregation("_popover").destroy();
226
+ }
227
+ handleBrowserEventsOnElement.call(this, oOverlay, "detachBrowserEvent");
228
+ }
229
+ handleBrowserEventsOnElement.call(this, this, "detachBrowserEvent");
188
230
  };
189
231
 
190
- ChangeIndicator.prototype.setChanges = function (aChanges) {
232
+ ChangeIndicator.prototype.setChanges = function(aChanges) {
191
233
  this.setProperty("changes", aChanges);
192
- this._oDetailModel.setData((aChanges || []).map(this._formatChangesModelItem.bind(this)));
234
+ this._oDetailModel.setData((aChanges || []).reverse().map(this._formatChangesModelItem.bind(this)));
193
235
  };
194
236
 
195
- ChangeIndicator.prototype._onSelect = function (oEvent) {
237
+ ChangeIndicator.prototype._onSelect = function(oEvent) {
196
238
  this.focus();
197
239
  oEvent.stopPropagation();
198
240
  this._openDetailPopover();
@@ -208,19 +250,23 @@ sap.ui.define([
208
250
  });
209
251
  };
210
252
 
211
- ChangeIndicator.prototype._toggleHoverStyleClasses = function(bAdd) {
212
- var oOverlay = sap.ui.getCore().byId(this.getOverlayId());
253
+ ChangeIndicator.prototype._toggleHoverStyleClasses = function(bAdd, oEvent) {
254
+ if (oEvent) {
255
+ oEvent.stopPropagation();
256
+ oEvent.preventDefault();
257
+ }
258
+ var oOverlay = Core.byId(this.getOverlayId());
213
259
  if (oOverlay.getMetadata().getName() !== "sap.ui.dt.ElementOverlay") {
214
260
  return;
215
261
  }
216
262
  var sFunctionName = bAdd ? "addStyleClass" : "removeStyleClass";
217
- oOverlay[sFunctionName]("sapUiRtaOverlayHover");
218
263
  oOverlay[sFunctionName]("sapUiRtaChangeIndicatorHovered");
264
+ this[sFunctionName]("sapUiRtaHover");
219
265
  };
220
266
 
221
- ChangeIndicator.prototype._formatChangesModelItem = function (mChangeInformation) {
222
- var oAffectedElement = sap.ui.getCore().byId(mChangeInformation.affectedElementId);
223
- var mPayload = Object.keys(mChangeInformation.payload || {}).reduce(function (mPayload, sKey) {
267
+ ChangeIndicator.prototype._formatChangesModelItem = function(mChangeInformation) {
268
+ var oAffectedElement = Core.byId(mChangeInformation.affectedElementId);
269
+ var mPayload = Object.keys(mChangeInformation.payload || {}).reduce(function(mPayload, sKey) {
224
270
  var vOriginalValue = mChangeInformation.payload[sKey];
225
271
  var bIsBinding = FlUtils.isBinding(vOriginalValue);
226
272
  var vValue = bIsBinding
@@ -230,36 +276,38 @@ sap.ui.define([
230
276
  return mPayload;
231
277
  }, {});
232
278
 
233
- var oOverlay = sap.ui.getCore().byId(this.getOverlayId());
279
+ var oOverlay = Core.byId(this.getOverlayId());
234
280
  var sElementLabel = oOverlay.getDesignTimeMetadata().getLabel(oAffectedElement);
235
281
  var oVisualizationUtil = getVisualizationCategory(mChangeInformation.commandName);
236
282
  var oDescription = oVisualizationUtil && oVisualizationUtil.getDescription(mPayload, sElementLabel);
237
- var oRtaResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.ui.rta");
238
- var sChangeTitle = mChangeInformation.commandName.charAt(0).toUpperCase() + mChangeInformation.commandName.slice(1);
283
+ var oRtaResourceBundle = Core.getLibraryResourceBundle("sap.ui.rta");
239
284
  sElementLabel = sElementLabel && "'" + sElementLabel + "'";
285
+ var sShortenedElementLabel = ChangeVisualizationUtils.shortenString(sElementLabel);
240
286
  var sChangeTextKey = (
241
287
  "TXT_CHANGEVISUALIZATION_CHANGE_"
242
288
  + mChangeInformation.commandName.toUpperCase()
243
289
  );
244
- var sChangeText = oDescription ? oDescription.descriptionText : oRtaResourceBundle.getText(sChangeTextKey, sElementLabel);
290
+ var sDescriptionText = oDescription ? oDescription.descriptionText : oRtaResourceBundle.getText(sChangeTextKey, sShortenedElementLabel);
291
+ var sDescriptionTooltip = oDescription ? oDescription.descriptionTooltip : oRtaResourceBundle.getText(sChangeTextKey, sElementLabel);
245
292
  var sCreationDate = mChangeInformation.change.getCreation();
246
293
  var oDate = new Date(sCreationDate);
247
294
  var sFallbackDate = oRtaResourceBundle.getText("TXT_CHANGEVISUALIZATION_CREATED_IN_SESSION_DATE");
248
295
  var sFullDate = sCreationDate ? DateFormat.getDateTimeInstance().format(oDate) : sFallbackDate;
249
- var sRelativeDate = sCreationDate ? DateFormat.getDateTimeInstance({relative: "true"}).format(oDate) : sFallbackDate;
296
+ var sRelativeDate = sCreationDate ? DateFormat.getDateTimeInstance({ relative: "true" }).format(oDate) : sFallbackDate;
250
297
  var sDetailButtonText = oDescription && oDescription.buttonText;
251
298
  return {
252
299
  id: mChangeInformation.id,
253
300
  change: mChangeInformation,
254
- changeTitle: sChangeTitle,
255
- description: sChangeText,
301
+ description: sDescriptionText,
302
+ descriptionTooltip: sDescriptionTooltip && sDescriptionText.length < sDescriptionTooltip.length ? sDescriptionTooltip : null,
256
303
  fullDate: sFullDate,
257
304
  relativeDate: sRelativeDate,
258
- detailButtonText: sDetailButtonText
305
+ detailButtonText: sDetailButtonText,
306
+ icon: CATEGORY_ICONS[mChangeInformation.commandCategory]
259
307
  };
260
308
  };
261
309
 
262
- ChangeIndicator.prototype._openDetailPopover = function () {
310
+ ChangeIndicator.prototype._openDetailPopover = function() {
263
311
  if (!this.getAggregation("_popover")) {
264
312
  //store the tabindex (tabindex will be removed on opening the popover)
265
313
  this._iOldTabIndex = this.getDomRef().getAttribute("tabindex");
@@ -280,7 +328,7 @@ sap.ui.define([
280
328
  }
281
329
  };
282
330
 
283
- ChangeIndicator.prototype._showDependentElements = function (oEvent) {
331
+ ChangeIndicator.prototype._showDependentElements = function(oEvent) {
284
332
  this.getAggregation("_popover").close();
285
333
  var sChangeId = this.getChanges().length > 1
286
334
  ? oEvent.getSource().getBindingContext("details").getObject().id