@openui5/sap.ui.integration 1.106.0 → 1.107.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 (242) hide show
  1. package/package.json +3 -3
  2. package/src/sap/ui/integration/.library +1 -6
  3. package/src/sap/ui/integration/ActionDefinition.js +1 -2
  4. package/src/sap/ui/integration/Designtime.js +1 -1
  5. package/src/sap/ui/integration/Extension.js +12 -2
  6. package/src/sap/ui/integration/Host.js +15 -1
  7. package/src/sap/ui/integration/cards/AdaptiveContent.js +5 -3
  8. package/src/sap/ui/integration/cards/AnalyticalContent.js +1 -1
  9. package/src/sap/ui/integration/cards/AnalyticsCloudContent.js +1 -1
  10. package/src/sap/ui/integration/cards/BaseContent.js +24 -7
  11. package/src/sap/ui/integration/cards/BaseListContent.js +1 -1
  12. package/src/sap/ui/integration/cards/CalendarContent.js +6 -4
  13. package/src/sap/ui/integration/cards/ComponentContent.js +1 -1
  14. package/src/sap/ui/integration/cards/Footer.js +34 -2
  15. package/src/sap/ui/integration/cards/Header.js +17 -22
  16. package/src/sap/ui/integration/cards/ListContent.js +39 -3
  17. package/src/sap/ui/integration/cards/NumericHeader.js +3 -19
  18. package/src/sap/ui/integration/cards/ObjectContent.js +82 -27
  19. package/src/sap/ui/integration/cards/TableContent.js +4 -3
  20. package/src/sap/ui/integration/cards/TimelineContent.js +1 -1
  21. package/src/sap/ui/integration/cards/WebPageContent.js +1 -1
  22. package/src/sap/ui/integration/cards/actions/CardActions.js +31 -23
  23. package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputChoiceSet.js +1 -1
  24. package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputDate.js +1 -1
  25. package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputNumber.js +1 -1
  26. package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputText.js +1 -1
  27. package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputToggle.js +1 -1
  28. package/src/sap/ui/integration/cards/filters/BaseFilter.js +3 -2
  29. package/src/sap/ui/integration/cards/filters/DateRangeFilter.js +1 -1
  30. package/src/sap/ui/integration/cards/filters/FilterBar.js +1 -1
  31. package/src/sap/ui/integration/cards/filters/FilterBarFactory.js +1 -1
  32. package/src/sap/ui/integration/cards/filters/SearchFilter.js +1 -1
  33. package/src/sap/ui/integration/cards/filters/SelectFilter.js +1 -1
  34. package/src/sap/ui/integration/controls/ActionsStrip.js +53 -7
  35. package/src/sap/ui/integration/controls/ActionsToolbar.js +12 -20
  36. package/src/sap/ui/integration/controls/LinkWithIcon.js +4 -2
  37. package/src/sap/ui/integration/controls/ListContentItem.js +1 -1
  38. package/src/sap/ui/integration/controls/Microchart.js +7 -1
  39. package/src/sap/ui/integration/controls/MicrochartLegend.js +1 -1
  40. package/src/sap/ui/integration/controls/Paginator.js +66 -16
  41. package/src/sap/ui/integration/designtime/baseEditor/BaseEditor.js +4 -2
  42. package/src/sap/ui/integration/designtime/baseEditor/PropertyEditor.js +11 -8
  43. package/src/sap/ui/integration/designtime/baseEditor/PropertyEditors.js +1 -1
  44. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n.properties +2 -2
  45. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ar.properties +1 -1
  46. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_bg.properties +1 -1
  47. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ca.properties +1 -1
  48. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_cs.properties +1 -1
  49. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_cy.properties +1 -1
  50. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_da.properties +1 -1
  51. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_de.properties +4 -4
  52. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_el.properties +1 -1
  53. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_en.properties +1 -1
  54. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_en_GB.properties +1 -1
  55. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_en_US_sappsd.properties +1 -1
  56. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_en_US_saprigi.properties +1 -1
  57. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_en_US_saptrc.properties +1 -1
  58. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_es.properties +1 -1
  59. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_es_MX.properties +1 -1
  60. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_et.properties +1 -1
  61. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_fi.properties +1 -1
  62. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_fr.properties +1 -1
  63. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_fr_CA.properties +1 -1
  64. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_hi.properties +1 -1
  65. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_hr.properties +1 -1
  66. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_hu.properties +1 -1
  67. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_id.properties +1 -1
  68. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_it.properties +1 -1
  69. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_iw.properties +1 -1
  70. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ja.properties +1 -1
  71. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_kk.properties +1 -1
  72. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ko.properties +1 -1
  73. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_lt.properties +1 -1
  74. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_lv.properties +1 -1
  75. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ms.properties +1 -1
  76. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_nl.properties +1 -1
  77. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_no.properties +1 -1
  78. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_pl.properties +1 -1
  79. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_pt.properties +1 -1
  80. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_pt_PT.properties +1 -1
  81. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ro.properties +1 -1
  82. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_ru.properties +1 -1
  83. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_sh.properties +1 -1
  84. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_sk.properties +1 -1
  85. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_sl.properties +1 -1
  86. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_sv.properties +1 -1
  87. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_th.properties +1 -1
  88. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_tr.properties +1 -1
  89. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_uk.properties +1 -1
  90. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_vi.properties +1 -1
  91. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_zh_CN.properties +1 -1
  92. package/src/sap/ui/integration/designtime/baseEditor/i18n/i18n_zh_TW.properties +1 -1
  93. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/BasePropertyEditor.js +15 -12
  94. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/PropertyEditorFactory.js +1 -1
  95. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/arrayEditor/ArrayEditor.js +1 -1
  96. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/booleanEditor/BooleanEditor.js +1 -1
  97. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/codeEditor/CodeEditor.js +22 -22
  98. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/codeEditor/CodeEditorDialog.fragment.xml +1 -1
  99. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateEditor/DateEditor.js +1 -1
  100. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateTimeEditor/DateTimeEditor.js +1 -1
  101. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/enumStringEditor/EnumStringEditor.js +1 -1
  102. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/groupEditor/GroupEditor.js +1 -1
  103. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
  104. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IsInIconPool.validator.js +1 -1
  105. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/integerEditor/IntegerEditor.js +1 -1
  106. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/jsonEditor/JsonEditor.js +1 -1
  107. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/listEditor/ListEditor.js +1 -1
  108. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/mapEditor/MapEditor.js +1 -1
  109. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/multiSelectEditor/MultiSelectEditor.js +1 -1
  110. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/numberEditor/NumberEditor.js +1 -1
  111. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/objectArrayEditor/ObjectArrayEditor.js +1 -1
  112. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/selectEditor/SelectEditor.js +1 -1
  113. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/separatorEditor/SeparatorEditor.js +1 -1
  114. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/stringEditor/StringEditor.js +1 -1
  115. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/textAreaEditor/TextAreaEditor.fragment.xml +14 -0
  116. package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/textAreaEditor/TextAreaEditor.js +126 -0
  117. package/src/sap/ui/integration/designtime/baseEditor/util/binding/ObjectBinding.js +1 -1
  118. package/src/sap/ui/integration/designtime/baseEditor/util/unset.js +1 -1
  119. package/src/sap/ui/integration/designtime/baseEditor/validator/IsBoolean.js +1 -1
  120. package/src/sap/ui/integration/designtime/baseEditor/validator/IsDate.js +1 -1
  121. package/src/sap/ui/integration/designtime/baseEditor/validator/IsInteger.js +1 -1
  122. package/src/sap/ui/integration/designtime/baseEditor/validator/IsNumber.js +1 -1
  123. package/src/sap/ui/integration/designtime/baseEditor/validator/IsSelectedKey.js +1 -1
  124. package/src/sap/ui/integration/designtime/baseEditor/validator/IsStringList.js +1 -1
  125. package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueKey.js +1 -1
  126. package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueList.js +1 -1
  127. package/src/sap/ui/integration/designtime/baseEditor/validator/IsValidBinding.js +1 -1
  128. package/src/sap/ui/integration/designtime/baseEditor/validator/MaxLength.js +1 -1
  129. package/src/sap/ui/integration/designtime/baseEditor/validator/NotABinding.js +1 -1
  130. package/src/sap/ui/integration/designtime/baseEditor/validator/ValidatorRegistry.js +1 -1
  131. package/src/sap/ui/integration/designtime/cardEditor/BASEditor.js +54 -5
  132. package/src/sap/ui/integration/designtime/cardEditor/config/index.js +1 -0
  133. package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_de.properties +1 -1
  134. package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/complexMapEditor/ComplexMapEditor.js +1 -1
  135. package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/destinationsEditor/DestinationsEditor.js +1 -1
  136. package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/filtersEditor/FiltersEditor.js +1 -1
  137. package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
  138. package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/parametersEditor/ParametersEditor.js +1 -1
  139. package/src/sap/ui/integration/designtime/editor/CardEditor.js +1 -2
  140. package/src/sap/ui/integration/designtime/editor/CardPreview.js +36 -34
  141. package/src/sap/ui/integration/editor/Editor.js +604 -912
  142. package/src/sap/ui/integration/editor/EditorResourceBundles.js +1 -1
  143. package/src/sap/ui/integration/editor/Extension.js +1 -2
  144. package/src/sap/ui/integration/editor/Manifest.js +1 -1
  145. package/src/sap/ui/integration/editor/Settings.js +7 -5
  146. package/src/sap/ui/integration/editor/css/Editor.css +4 -0
  147. package/src/sap/ui/integration/editor/fields/BaseField.js +48 -43
  148. package/src/sap/ui/integration/editor/fields/BooleanField.js +1 -1
  149. package/src/sap/ui/integration/editor/fields/DateField.js +1 -1
  150. package/src/sap/ui/integration/editor/fields/DateTimeField.js +1 -1
  151. package/src/sap/ui/integration/editor/fields/DestinationField.js +1 -1
  152. package/src/sap/ui/integration/editor/fields/GroupField.js +353 -0
  153. package/src/sap/ui/integration/editor/fields/IntegerField.js +1 -1
  154. package/src/sap/ui/integration/editor/fields/NumberField.js +1 -1
  155. package/src/sap/ui/integration/editor/fields/ObjectField.js +7 -3
  156. package/src/sap/ui/integration/editor/fields/ObjectListField.js +1 -1
  157. package/src/sap/ui/integration/editor/fields/StringField.js +3 -2
  158. package/src/sap/ui/integration/editor/fields/StringListField.js +1 -1
  159. package/src/sap/ui/integration/editor/fields/fragment/Controller.js +1 -1
  160. package/src/sap/ui/integration/editor/fields/viz/ColorSelect.js +8 -6
  161. package/src/sap/ui/integration/editor/fields/viz/IconSelect.js +6 -4
  162. package/src/sap/ui/integration/editor/fields/viz/ShapeSelect.js +5 -3
  163. package/src/sap/ui/integration/editor/fields/viz/VizBase.js +16 -9
  164. package/src/sap/ui/integration/library.js +2 -8
  165. package/src/sap/ui/integration/messagebundle_ar.properties +6 -0
  166. package/src/sap/ui/integration/messagebundle_bg.properties +6 -0
  167. package/src/sap/ui/integration/messagebundle_ca.properties +6 -0
  168. package/src/sap/ui/integration/messagebundle_cs.properties +6 -0
  169. package/src/sap/ui/integration/messagebundle_cy.properties +6 -0
  170. package/src/sap/ui/integration/messagebundle_da.properties +6 -0
  171. package/src/sap/ui/integration/messagebundle_de.properties +6 -0
  172. package/src/sap/ui/integration/messagebundle_el.properties +7 -1
  173. package/src/sap/ui/integration/messagebundle_en.properties +6 -0
  174. package/src/sap/ui/integration/messagebundle_en_GB.properties +6 -0
  175. package/src/sap/ui/integration/messagebundle_en_US_saptrc.properties +6 -0
  176. package/src/sap/ui/integration/messagebundle_es.properties +6 -0
  177. package/src/sap/ui/integration/messagebundle_es_MX.properties +6 -0
  178. package/src/sap/ui/integration/messagebundle_et.properties +6 -0
  179. package/src/sap/ui/integration/messagebundle_fi.properties +6 -0
  180. package/src/sap/ui/integration/messagebundle_fr.properties +6 -0
  181. package/src/sap/ui/integration/messagebundle_fr_CA.properties +6 -0
  182. package/src/sap/ui/integration/messagebundle_hi.properties +6 -0
  183. package/src/sap/ui/integration/messagebundle_hr.properties +6 -0
  184. package/src/sap/ui/integration/messagebundle_hu.properties +6 -0
  185. package/src/sap/ui/integration/messagebundle_id.properties +7 -1
  186. package/src/sap/ui/integration/messagebundle_it.properties +6 -0
  187. package/src/sap/ui/integration/messagebundle_iw.properties +6 -0
  188. package/src/sap/ui/integration/messagebundle_ja.properties +6 -0
  189. package/src/sap/ui/integration/messagebundle_kk.properties +7 -1
  190. package/src/sap/ui/integration/messagebundle_ko.properties +6 -0
  191. package/src/sap/ui/integration/messagebundle_lt.properties +6 -0
  192. package/src/sap/ui/integration/messagebundle_lv.properties +6 -0
  193. package/src/sap/ui/integration/messagebundle_ms.properties +6 -0
  194. package/src/sap/ui/integration/messagebundle_nl.properties +6 -0
  195. package/src/sap/ui/integration/messagebundle_no.properties +6 -0
  196. package/src/sap/ui/integration/messagebundle_pl.properties +6 -0
  197. package/src/sap/ui/integration/messagebundle_pt.properties +6 -0
  198. package/src/sap/ui/integration/messagebundle_pt_PT.properties +6 -0
  199. package/src/sap/ui/integration/messagebundle_ro.properties +6 -0
  200. package/src/sap/ui/integration/messagebundle_ru.properties +6 -0
  201. package/src/sap/ui/integration/messagebundle_sh.properties +6 -0
  202. package/src/sap/ui/integration/messagebundle_sk.properties +6 -0
  203. package/src/sap/ui/integration/messagebundle_sl.properties +6 -0
  204. package/src/sap/ui/integration/messagebundle_sv.properties +6 -0
  205. package/src/sap/ui/integration/messagebundle_th.properties +6 -0
  206. package/src/sap/ui/integration/messagebundle_tr.properties +6 -0
  207. package/src/sap/ui/integration/messagebundle_uk.properties +6 -0
  208. package/src/sap/ui/integration/messagebundle_vi.properties +6 -0
  209. package/src/sap/ui/integration/messagebundle_zh_CN.properties +6 -0
  210. package/src/sap/ui/integration/messagebundle_zh_TW.properties +6 -0
  211. package/src/sap/ui/integration/model/ContextModel.js +1 -1
  212. package/src/sap/ui/integration/model/ObservableModel.js +1 -1
  213. package/src/sap/ui/integration/model/PagingModelListBinding.js +1 -1
  214. package/src/sap/ui/integration/schemas/sap-card.json +67 -20
  215. package/src/sap/ui/integration/themes/base/ActionsStrip.less +5 -0
  216. package/src/sap/ui/integration/themes/base/Card.less +1 -12
  217. package/src/sap/ui/integration/themes/base/ListContentItem.less +9 -15
  218. package/src/sap/ui/integration/themes/base/Microchart.less +7 -0
  219. package/src/sap/ui/integration/themes/base/ObjectContent.less +11 -4
  220. package/src/sap/ui/integration/util/BaseFactory.js +1 -1
  221. package/src/sap/ui/integration/util/BindingHelper.js +1 -1
  222. package/src/sap/ui/integration/util/BindingResolver.js +1 -1
  223. package/src/sap/ui/integration/util/CardObserver.js +1 -1
  224. package/src/sap/ui/integration/util/ContentFactory.js +10 -1
  225. package/src/sap/ui/integration/util/CsrfTokenHandler.js +1 -1
  226. package/src/sap/ui/integration/util/DataProvider.js +2 -2
  227. package/src/sap/ui/integration/util/DataProviderFactory.js +1 -1
  228. package/src/sap/ui/integration/util/Destinations.js +1 -1
  229. package/src/sap/ui/integration/util/ExtensionDataProvider.js +1 -1
  230. package/src/sap/ui/integration/util/Forms.js +1 -1
  231. package/src/sap/ui/integration/util/HeaderFactory.js +10 -8
  232. package/src/sap/ui/integration/util/JSONBindingHelper.js +1 -1
  233. package/src/sap/ui/integration/util/LoadingProvider.js +1 -1
  234. package/src/sap/ui/integration/util/Manifest.js +1 -1
  235. package/src/sap/ui/integration/util/ManifestResolver.js +1 -0
  236. package/src/sap/ui/integration/util/RequestDataProvider.js +1 -1
  237. package/src/sap/ui/integration/util/ServiceDataProvider.js +1 -1
  238. package/src/sap/ui/integration/util/ServiceManager.js +1 -1
  239. package/src/sap/ui/integration/util/SkeletonCard.js +1 -1
  240. package/src/sap/ui/integration/util/Utils.js +1 -1
  241. package/src/sap/ui/integration/util/Validators.js +1 -1
  242. package/src/sap/ui/integration/widgets/Card.js +155 -26
@@ -139,13 +139,12 @@ sap.ui.define([
139
139
  * @extends sap.ui.core.Control
140
140
  *
141
141
  * @author SAP SE
142
- * @version 1.106.0
142
+ * @version 1.107.0
143
143
  * @constructor
144
144
  * @since 1.94
145
145
  * @private
146
146
  * @experimental since 1.94.0
147
147
  * @alias sap.ui.integration.editor.Editor
148
- * @ui5-metamodel This control/element also will be described in the UI5 (legacy) designtime metamodel
149
148
  */
150
149
  var Editor = Control.extend("sap.ui.integration.editor.Editor", /** @lends sap.ui.integration.editor.Editor.prototype */ {
151
150
  metadata: {
@@ -232,336 +231,459 @@ sap.ui.define([
232
231
  manifestReady: {}
233
232
  }
234
233
  },
235
- renderer: function (oRm, oControl) {
236
- var oPreview = oControl.getAggregation("_preview");
237
- var bShowPreview = oControl.getMode() !== "translation" && oControl.hasPreview();
238
- var sPreviewPosition = oControl.getPreviewPosition();
239
- if (bShowPreview
240
- && (sPreviewPosition === "top" || sPreviewPosition === "bottom")) {
241
- oRm.openStart("div");
242
- oRm.writeElementData(oControl);
243
- oRm.openEnd();
244
- //render the additional content if alignment of it is "top"
245
- if (oControl.isReady() && sPreviewPosition === "top") {
246
- oRm.renderControl(oPreview);
247
- oRm.close("div");
248
- }
249
- }
250
- oRm.openStart("div");
251
- oRm.addClass("sapUiIntegrationEditor");
252
- if (bShowPreview && sPreviewPosition === "left") {
253
- oRm.writeElementData(oControl);
254
- oRm.openEnd();
255
- if (oControl.isReady()){
256
- oRm.renderControl(oPreview);
257
- oRm.close("div");
258
- }
259
- } else if (bShowPreview
260
- && (sPreviewPosition === "bottom" || sPreviewPosition === "top")) {
261
- oRm.openEnd();
262
- } else {
263
- oRm.writeElementData(oControl);
264
- oRm.openEnd();
265
- }
266
- if (oControl.isReady()) {
267
- //surrounding div tag for form <div class="sapUiIntegrationEditorForm"
268
- oRm.openStart("div");
269
- oRm.addClass("sapUiIntegrationEditorForm");
270
- if (oControl.getMode() !== "translation") {
271
- oRm.addClass("settingsButtonSpace");
234
+ renderer: {
235
+ apiVersion: 2,
236
+ render: function (oRm, oControl) {
237
+ var oPreview = oControl.getAggregation("_preview");
238
+ var bShowPreview = oControl.getMode() !== "translation" && oControl.hasPreview();
239
+ var sPreviewPosition = oControl.getPreviewPosition();
240
+ if (bShowPreview
241
+ && (sPreviewPosition === "top" || sPreviewPosition === "bottom")) {
242
+ oRm.openStart("div", oControl);
243
+ oRm.openEnd();
244
+ //render the additional content if alignment of it is "top"
245
+ if (oControl.isReady() && sPreviewPosition === "top") {
246
+ oRm.renderControl(oPreview);
247
+ oRm.close("div");
248
+ }
272
249
  }
273
- oRm.openEnd();
274
- if (oControl.getMode() !== "translation") {
275
- oRm.renderControl(oControl.getAggregation("_messageStrip"));
250
+ if (bShowPreview && sPreviewPosition === "left") {
251
+ oRm.openStart("div", oControl);
252
+ oRm.class("sapUiIntegrationEditor");
253
+ oRm.openEnd();
254
+ if (oControl.isReady()){
255
+ oRm.renderControl(oPreview);
256
+ oRm.close("div");
257
+ }
258
+ } else if (bShowPreview
259
+ && (sPreviewPosition === "bottom" || sPreviewPosition === "top")) {
260
+ oRm.openStart("div");
261
+ oRm.class("sapUiIntegrationEditor");
262
+ oRm.openEnd();
263
+ } else {
264
+ oRm.openStart("div", oControl);
265
+ oRm.class("sapUiIntegrationEditor");
266
+ oRm.openEnd();
276
267
  }
277
- var aItems = oControl.getAggregation("_formContent");
278
- //render items
279
- if (aItems) {
280
- var oPanel;
281
- var oSubGroup;
282
- var oLanguagePanel;
283
- var oLabelItemForNotWrapping;
284
- var oColFields = [];
285
- var oColFieldsOfSubGroup = [];
286
- var oOriginalField;
287
- var addColFields = function () {
288
- if (oColFields.length > 0) {
289
- var iLess = 2 - oColFields.length;
290
- for (var n = 0; n < iLess; n++) {
291
- oColFields.push(new VBox());
292
- }
293
- oPanel.addContent(new FlexBox({
294
- alignItems: "Start",
295
- justifyContent: "SpaceBetween",
296
- items: oColFields
297
- }));
298
- oColFields = [];
299
- }
300
- };
301
- var addColFieldsOfSubGroup = function () {
302
- if (oColFieldsOfSubGroup.length > 0) {
303
- var iLess = 2 - oColFieldsOfSubGroup.length;
304
- for (var n = 0; n < iLess; n++) {
305
- oColFieldsOfSubGroup.push(new VBox());
306
- }
307
- oSubGroup.addContent(new FlexBox({
308
- alignItems: "Start",
309
- justifyContent: "SpaceBetween",
310
- items: oColFieldsOfSubGroup
311
- }));
312
- oColFieldsOfSubGroup = [];
313
- }
314
- };
315
- var renderPanel = function (oPanel) {
316
- if (oPanel.getContent().length > 0) {
317
- var aContents = oPanel.getContent();
318
- if (aContents.length === 1 && aContents[0].isA("sap.m.MessageStrip")) {
319
- return;
320
- }
321
- if (aContents[0].isA("sap.m.MessageStrip")) {
322
- oPanel.removeContent(0);
323
- oPanel.addContent(aContents[0]);
324
- }
325
- oRm.renderControl(oPanel);
326
- if (oPanel._messageStrip) {
327
- oRm.renderControl(oPanel._messageStrip);
268
+ if (oControl.isReady()) {
269
+ //surrounding div tag for form <div class="sapUiIntegrationEditorForm"
270
+ oRm.openStart("div");
271
+ oRm.class("sapUiIntegrationEditorForm");
272
+ if (oControl.getMode() !== "translation") {
273
+ oRm.class("settingsButtonSpace");
274
+ }
275
+ oRm.openEnd();
276
+ if (oControl.getMode() !== "translation") {
277
+ oRm.renderControl(oControl.getAggregation("_messageStrip"));
278
+ }
279
+ var aItems = oControl.getAggregation("_formContent");
280
+ //render items
281
+ if (aItems) {
282
+ var oPanel;
283
+ var oSubGroup;
284
+ var oLanguagePanel;
285
+ var oLabelItemForNotWrapping;
286
+ var oColFields = [];
287
+ var oColFieldsOfSubGroup = [];
288
+ var oOriginalField;
289
+ var addColFields = function () {
290
+ if (oColFields.length > 0) {
291
+ var iLess = 2 - oColFields.length;
292
+ for (var n = 0; n < iLess; n++) {
293
+ oColFields.push(new VBox());
294
+ }
295
+ oPanel.addContent(new FlexBox({
296
+ alignItems: "Start",
297
+ justifyContent: "SpaceBetween",
298
+ items: oColFields
299
+ }));
300
+ oColFields = [];
328
301
  }
329
- }
330
- };
331
- var addSubPanel = function (oPanel, oSubGroup) {
332
- if (oPanel && oSubGroup.getContent().length > 0) {
333
- var aContents = oSubGroup.getContent();
334
- if (aContents[0].isA("sap.m.MessageStrip")) {
335
- oSubGroup.removeContent(0);
336
- oSubGroup.addContent(aContents[0]);
302
+ };
303
+ var addColFieldsOfSubGroup = function () {
304
+ if (oColFieldsOfSubGroup.length > 0) {
305
+ var iLess = 2 - oColFieldsOfSubGroup.length;
306
+ for (var n = 0; n < iLess; n++) {
307
+ oColFieldsOfSubGroup.push(new VBox());
308
+ }
309
+ oSubGroup.addContent(new FlexBox({
310
+ alignItems: "Start",
311
+ justifyContent: "SpaceBetween",
312
+ items: oColFieldsOfSubGroup
313
+ }));
314
+ oColFieldsOfSubGroup = [];
337
315
  }
338
- oPanel.addContent(oSubGroup);
339
- if (oSubGroup._messageStrip) {
340
- oPanel.addContent(oSubGroup._messageStrip);
316
+ };
317
+ var renderPanel = function (oPanel) {
318
+ if (oPanel.getContent().length > 0) {
319
+ var aContents = oPanel.getContent();
320
+ if (aContents.length === 1 && aContents[0].isA("sap.m.MessageStrip")) {
321
+ return;
322
+ }
323
+ if (aContents[0].isA("sap.m.MessageStrip")) {
324
+ oPanel.removeContent(0);
325
+ oPanel.addContent(aContents[0]);
326
+ }
327
+ oRm.renderControl(oPanel.getParent());
328
+ if (oPanel._messageStrip) {
329
+ oRm.renderControl(oPanel._messageStrip);
330
+ }
341
331
  }
342
- } else {
343
- oSubGroup = null;
344
- }
345
- };
346
- var addSubTab = function (oPanel, oSubGroup) {
347
- var oSubItems = oPanel.getContent(),
348
- oIconTabBar;
349
- if (oSubItems.length > 0) {
350
- for (var m = 0; m < oSubItems.length; m++) {
351
- if (oSubItems[m].isA("sap.m.IconTabBar")) {
352
- oIconTabBar = oSubItems[m];
332
+ };
333
+ var addSubPanel = function (oPanel, oSubGroup) {
334
+ if (oPanel && oSubGroup.getContent().length > 0) {
335
+ var aContents = oSubGroup.getContent();
336
+ if (aContents[0].isA("sap.m.MessageStrip")) {
337
+ oSubGroup.removeContent(0);
338
+ oSubGroup.addContent(aContents[0]);
339
+ }
340
+ oPanel.addContent(oSubGroup.getParent());
341
+ if (oSubGroup._messageStrip) {
342
+ oPanel.addContent(oSubGroup._messageStrip);
353
343
  }
344
+ } else {
345
+ oSubGroup = null;
354
346
  }
355
- }
356
- if (oIconTabBar && oSubGroup.getContent().length > 0) {
357
- oIconTabBar.addItem(oSubGroup);
358
- }
359
- };
360
- for (var i = 0; i < aItems.length; i++) {
361
- var oItem = aItems[i];
362
- if (oControl.getMode() !== "translation") {
363
- if (oItem.isA("sap.m.Panel") || oItem.isA("sap.m.IconTabBar")) {
364
- if (oSubGroup) {
365
- //add current col fields to previous sub panel, then empty the col fields list
366
- addColFieldsOfSubGroup();
367
- //add sub group to panel
368
- if (oItem.isA("sap.m.Panel") && oSubGroup.isA("sap.m.Panel")) {
369
- addSubPanel(oPanel, oSubGroup);
370
- } else {
371
- addSubTab(oPanel, oSubGroup);
347
+ };
348
+ var addSubTab = function (oPanel, oSubGroup) {
349
+ var oSubItems = oPanel.getContent(),
350
+ oIconTabBar;
351
+ if (oSubItems.length > 0) {
352
+ for (var m = 0; m < oSubItems.length; m++) {
353
+ if (oSubItems[m].getAggregation("_field") && oSubItems[m].getAggregation("_field").isA("sap.m.IconTabBar")) {
354
+ oIconTabBar = oSubItems[m].getAggregation("_field");
372
355
  }
373
356
  }
374
- var oItemLevel = 0;
375
- if (oItem.isA("sap.m.Panel")) {
376
- oItemLevel = oItem._level;
377
- } else if (oItem.isA("sap.m.IconTabBar")) {
378
- oItemLevel = "1";
379
- }
380
- if (oItemLevel === "1") {
381
- if (oColFields.length > 0) {
382
- addColFields();
383
- // renderPanel(oPanel);
357
+ }
358
+ if (oIconTabBar && oSubGroup.getContent().length > 0) {
359
+ oIconTabBar.addItem(oSubGroup);
360
+ }
361
+ };
362
+ for (var i = 0; i < aItems.length; i++) {
363
+ var oItem = aItems[i];
364
+ if (oControl.getMode() !== "translation") {
365
+ if (oItem.isA("sap.ui.integration.editor.fields.GroupField")) {
366
+ var oGroupControl = oItem.getAggregation("_field");
367
+ if (oSubGroup) {
368
+ //add current col fields to previous sub panel, then empty the col fields list
369
+ addColFieldsOfSubGroup();
370
+ //add sub group to panel
371
+ if (oGroupControl.isA("sap.m.Panel") && oSubGroup.isA("sap.m.Panel")) {
372
+ addSubPanel(oPanel, oSubGroup);
373
+ } else {
374
+ addSubTab(oPanel, oSubGroup);
375
+ }
376
+ }
377
+ var oItemLevel = 0;
378
+ if (oGroupControl.isA("sap.m.Panel")) {
379
+ oItemLevel = oGroupControl._level;
380
+ } else if (oGroupControl.isA("sap.m.IconTabBar")) {
381
+ oItemLevel = "1";
384
382
  }
385
- if (oItem.isA("sap.m.IconTabBar")) {
386
- var subItems = oPanel.getContent(),
387
- iconTabBarExist = false,
388
- nIconTabBar;
389
- if (subItems.length > 0) {
390
- for (var j = 0; j < subItems.length; j++) {
391
- if (subItems[j].isA("sap.m.IconTabBar")) {
392
- iconTabBarExist = true;
393
- nIconTabBar = subItems[j];
383
+ if (oItemLevel === "1") {
384
+ if (oColFields.length > 0) {
385
+ addColFields();
386
+ // renderPanel(oPanel);
387
+ }
388
+ if (oGroupControl.isA("sap.m.IconTabBar")) {
389
+ var subItems = oPanel.getContent(),
390
+ iconTabBarExist = false,
391
+ nIconTabBar;
392
+ if (subItems.length > 0) {
393
+ for (var j = 0; j < subItems.length; j++) {
394
+ if (subItems[j].getAggregation("_field") && subItems[j].getAggregation("_field").isA("sap.m.IconTabBar")) {
395
+ iconTabBarExist = true;
396
+ nIconTabBar = subItems[j].getAggregation("_field");
397
+ }
394
398
  }
395
399
  }
396
- }
397
- if (!iconTabBarExist) {
398
- oSubGroup = oItem.getItems()[0];
399
- oSubGroup._subItems = [];
400
- oItem.removeItem(oItem.getItems()[0]);
401
- if (oItem.isA("sap.m.IconTabBar") && oItem._messageStrip) {
402
- oPanel.addContent(oItem._messageStrip);
400
+ oSubGroup = oGroupControl.getItems()[0];
401
+ oSubGroup._subItems = oSubGroup._subItems || [];
402
+ if (!iconTabBarExist) {
403
+ oGroupControl.removeItem(oGroupControl.getItems()[0]);
404
+ if (oGroupControl._messageStrip) {
405
+ oPanel.addContent(oGroupControl._messageStrip);
406
+ }
407
+ oGroupControl.addStyleClass("sapUiIntegrationEditorSubTab");
408
+ oPanel.addContent(oItem);
409
+ } else {
410
+ //add the iconTabFilter into the existed iconTabBar
411
+ nIconTabBar.addItem(oGroupControl.getItems()[0]);
412
+ //remove the unnecessary iconTabBar
413
+ oGroupControl.destroy();
403
414
  }
404
- oItem.addStyleClass("sapUiIntegrationEditorSubTab");
405
- oPanel.addContent(oItem);
406
415
  } else {
407
- oSubGroup = oItem.getItems()[0];
408
- oSubGroup._subItems = [];
409
- //add the iconTabFilter into the existed iconTabBar
410
- nIconTabBar.addItem(oItem.getItems()[0]);
411
- //remove the unnecessary iconTabBar
412
- oItem.destroy();
416
+ oSubGroup = oGroupControl;
417
+ oSubGroup._subItems = oSubGroup._subItems || [];
418
+ oSubGroup.addStyleClass("sapUiIntegrationEditorSubGroup");
413
419
  }
414
420
  } else {
415
- oSubGroup = oItem;
416
- oSubGroup._subItems = [];
417
- oSubGroup.addStyleClass("sapUiIntegrationEditorSubGroup");
421
+ if (oPanel) {
422
+ //add current col fields to previous panel, then empty the col fields list
423
+ addColFields();
424
+ //render previous panel
425
+ renderPanel(oPanel);
426
+ oSubGroup = null;
427
+ }
428
+ oPanel = oGroupControl;
429
+ oPanel._subItems = oPanel._subItems || [];
430
+ oPanel.addStyleClass("sapUiIntegrationEditorItem");
418
431
  }
419
- } else {
420
- if (oPanel) {
421
- //add current col fields to previous panel, then empty the col fields list
432
+ if (i === aItems.length - 1) {
433
+ //add current col fields to panel, then empty the col fields list
422
434
  addColFields();
423
- //render previous panel
424
435
  renderPanel(oPanel);
425
- oSubGroup = null;
426
436
  }
427
- oPanel = oItem;
428
- oPanel._subItems = [];
429
- oPanel.addStyleClass("sapUiIntegrationEditorItem");
430
- }
431
- if (i === aItems.length - 1) {
432
- //add current col fields to panel, then empty the col fields list
433
- addColFields();
434
- renderPanel(oPanel);
437
+ continue;
435
438
  }
436
- continue;
437
- }
438
- // add style class for the hint under group and checkbox/toggle
439
- if (oItem.isA("sap.m.FormattedText")) {
440
- if (oSubGroup) {
441
- oSubGroup.addContent(oItem.addStyleClass("sapUiIntegrationEditorHint"));
442
- } else {
443
- oPanel.addContent(oItem.addStyleClass("sapUiIntegrationEditorHint"));
444
- }
445
- if (i === aItems.length - 1) {
439
+ // add style class for the hint under group and checkbox/toggle
440
+ if (oItem.isA("sap.m.FormattedText")) {
446
441
  if (oSubGroup) {
447
- //add current col fields to previous sub panel, then empty the col fields list
448
- addColFieldsOfSubGroup();
449
- //add sub panel to panel
450
- addSubPanel(oPanel, oSubGroup);
442
+ oSubGroup.addContent(oItem.addStyleClass("sapUiIntegrationEditorHint"));
443
+ } else {
444
+ oPanel.addContent(oItem.addStyleClass("sapUiIntegrationEditorHint"));
451
445
  }
452
- //add current col fields to panel, then empty the col fields list
453
- addColFields();
454
- renderPanel(oPanel);
446
+ if (i === aItems.length - 1) {
447
+ if (oSubGroup) {
448
+ //add current col fields to previous sub panel, then empty the col fields list
449
+ addColFieldsOfSubGroup();
450
+ //add sub panel to panel
451
+ addSubPanel(oPanel, oSubGroup);
452
+ }
453
+ //add current col fields to panel, then empty the col fields list
454
+ addColFields();
455
+ renderPanel(oPanel);
456
+ }
457
+ continue;
455
458
  }
456
- continue;
457
- }
458
459
 
459
- var oLayout = oItem._layout;
460
- if (oItem.isA("sap.m.Label")) {
461
- oItem.addStyleClass("sapUiIntegrationEditorItemLabel");
462
- if (oLayout && !deepEqual(oLayout, {})) {
463
- if (oLayout.alignment && oLayout.alignment.label === "end") {
464
- oItem.setTextAlign("End");
460
+ var oLayout = oItem._layout;
461
+ if (oItem.isA("sap.m.Label")) {
462
+ oItem.addStyleClass("sapUiIntegrationEditorItemLabel");
463
+ if (oItem.getRequired()) {
464
+ oItem.addStyleClass("sapUiIntegrationEditorItemLabelWithRequired");
465
465
  }
466
- oLabelItemForNotWrapping = oItem;
467
- } else {
468
- //if cols === 1 and reach the col size, add the col fields to panel, then empty the col fields list
469
- //if cols === 2, add the col fields to panel, then empty the col fields list
470
- if (oItem._cols === 2) {
471
- if (oSubGroup) {
466
+ if (oLayout && !deepEqual(oLayout, {})) {
467
+ if (oLayout.alignment && oLayout.alignment.label === "end") {
468
+ oItem.setTextAlign("End");
469
+ }
470
+ oLabelItemForNotWrapping = oItem;
471
+ } else {
472
+ //if cols === 1 and reach the col size, add the col fields to panel, then empty the col fields list
473
+ //if cols === 2, add the col fields to panel, then empty the col fields list
474
+ if (oItem._cols === 2) {
475
+ if (oSubGroup) {
476
+ addColFieldsOfSubGroup();
477
+ } else {
478
+ addColFields();
479
+ }
480
+ } else if (oColFieldsOfSubGroup.length === 2) {
472
481
  addColFieldsOfSubGroup();
473
- } else {
482
+ } else if (oColFields.length === 2) {
474
483
  addColFields();
475
484
  }
476
- } else if (oColFieldsOfSubGroup.length === 2) {
477
- addColFieldsOfSubGroup();
478
- } else if (oColFields.length === 2) {
479
- addColFields();
485
+ if (oSubGroup) {
486
+ oSubGroup.addContent(oItem);
487
+ } else {
488
+ oPanel.addContent(oItem);
489
+ }
490
+ }
491
+ } else if (oItem.isA("sap.m.ToolbarSpacer")) {
492
+ if (oItem._hasLine) {
493
+ oItem.addStyleClass("sapUiIntegrationEditorSpacerWithLine");
494
+ } else {
495
+ oItem.addStyleClass("sapUiIntegrationEditorSpacerWithoutLine");
480
496
  }
481
497
  if (oSubGroup) {
498
+ addColFieldsOfSubGroup();
482
499
  oSubGroup.addContent(oItem);
483
500
  } else {
501
+ addColFields();
484
502
  oPanel.addContent(oItem);
485
503
  }
486
- }
487
- } else if (oItem.isA("sap.m.ToolbarSpacer")) {
488
- if (oItem._hasLine) {
489
- oItem.addStyleClass("sapUiIntegrationEditorSpacerWithLine");
490
- } else {
491
- oItem.addStyleClass("sapUiIntegrationEditorSpacerWithoutLine");
492
- }
493
- if (oSubGroup) {
494
- addColFieldsOfSubGroup();
495
- oSubGroup.addContent(oItem);
496
504
  } else {
497
- addColFields();
498
- oPanel.addContent(oItem);
499
- }
500
- } else {
501
- var oConfig = oItem.getConfiguration(),
502
- aInfoHBox = new HBox(),
503
- iInfoHBoxWidth = 0.1,
504
- iSettingsHBoxWidth = 0,
505
- oLabelHBox;
506
- if (oItem._descriptionIcon) {
507
- aInfoHBox.addItem(oItem._descriptionIcon);
508
- iInfoHBoxWidth += 0.9;
509
- }
510
- var oMessageIcon = Core.byId(oItem.getAssociation("_messageIcon"));
511
- if (oItem.getAssociation("_messageIcon") && oMessageIcon) {
512
- aInfoHBox.addItem(oMessageIcon);
513
- iInfoHBoxWidth += 1.2;
514
- }
515
- if (oItem._settingsButton) {
516
- oItem._settingsButton.addStyleClass("sapUiIntegrationEditorSettingsButton");
517
- iSettingsHBoxWidth = 2;
518
- }
519
- var oFlexItemDataForSettings = new FlexItemData({
520
- growFactor: 10,
521
- maxWidth: "calc(100% - " + iSettingsHBoxWidth + "rem)"
522
- });
523
- var oFlexItemDataForInfo = new FlexItemData({
524
- maxWidth: "calc(100% - " + iInfoHBoxWidth + "rem)"
525
- });
526
- if (oLabelItemForNotWrapping) {
527
- var oHBox,
528
- oFlexBox,
529
- sLabelWidth = "50%";
530
- if (oLayout && oLayout["label-width"]) {
531
- sLabelWidth = oLayout["label-width"];
505
+ var oConfig = oItem.getConfiguration(),
506
+ aInfoHBox = new HBox(),
507
+ iInfoHBoxWidth = 0.1,
508
+ iSettingsHBoxWidth = 0,
509
+ oLabelHBox;
510
+ if (oItem._descriptionIcon) {
511
+ aInfoHBox.addItem(oItem._descriptionIcon);
512
+ iInfoHBoxWidth += 0.9;
532
513
  }
533
- var iLabelWidth = parseInt(sLabelWidth);
534
- var iFieldWidth = 100 - iLabelWidth;
535
- if (oItem._cols === 2) {
536
- iLabelWidth = iLabelWidth - 0.5;
537
- iFieldWidth = iFieldWidth - 0.5;
514
+ var oMessageIcon = Core.byId(oItem.getAssociation("_messageIcon"));
515
+ if (oItem.getAssociation("_messageIcon") && oMessageIcon) {
516
+ aInfoHBox.addItem(oMessageIcon);
517
+ iInfoHBoxWidth += 1.2;
538
518
  }
539
-
540
- if (oLayout.alignment && oLayout.alignment.field === "end") {
541
- oItem.addStyleClass("sapUiIntegrationEditorFieldAlignEnd");
542
- }
543
- if (oLayout.alignment && oLayout.alignment.label === "end") {
544
- oLabelItemForNotWrapping.setLayoutData(new FlexItemData({
545
- maxWidth: "calc(100% - " + iInfoHBoxWidth + "rem)",
546
- minWidth: "calc(100% - " + iInfoHBoxWidth + "rem)"
547
- }));
548
- } else {
549
- oLabelItemForNotWrapping.setLayoutData(oFlexItemDataForInfo);
519
+ if (oItem._settingsButton) {
520
+ oItem._settingsButton.addStyleClass("sapUiIntegrationEditorSettingsButton");
521
+ iSettingsHBoxWidth = 2;
550
522
  }
551
- if (aInfoHBox.getItems().length > 0) {
552
- oLabelItemForNotWrapping.addStyleClass("sapUiIntegrationEditorItemLabelWithInfo");
553
- oLabelHBox = new HBox({
554
- items: [
555
- oLabelItemForNotWrapping,
556
- aInfoHBox
557
- ]
558
- });
523
+ var oFlexItemDataForSettings = new FlexItemData({
524
+ growFactor: 10,
525
+ maxWidth: "calc(100% - " + iSettingsHBoxWidth + "rem)"
526
+ });
527
+ var oFlexItemDataForInfo = new FlexItemData({
528
+ maxWidth: "calc(100% - " + iInfoHBoxWidth + "rem)"
529
+ });
530
+ if (oLabelItemForNotWrapping) {
531
+ var oHBox,
532
+ oFlexBox,
533
+ sLabelWidth = "50%";
534
+ if (oLayout && oLayout["label-width"]) {
535
+ sLabelWidth = oLayout["label-width"];
536
+ }
537
+ var iLabelWidth = parseInt(sLabelWidth);
538
+ var iFieldWidth = 100 - iLabelWidth;
539
+ if (oItem._cols === 2) {
540
+ iLabelWidth = iLabelWidth - 0.5;
541
+ iFieldWidth = iFieldWidth - 0.5;
542
+ }
543
+
544
+ if (oLayout.alignment && oLayout.alignment.field === "end") {
545
+ oItem.addStyleClass("sapUiIntegrationEditorFieldAlignEnd");
546
+ }
547
+ if (oLayout.alignment && oLayout.alignment.label === "end") {
548
+ oLabelItemForNotWrapping.setLayoutData(new FlexItemData({
549
+ maxWidth: "calc(100% - " + iInfoHBoxWidth + "rem)",
550
+ minWidth: "calc(100% - " + iInfoHBoxWidth + "rem)"
551
+ }));
552
+ } else {
553
+ oLabelItemForNotWrapping.setLayoutData(oFlexItemDataForInfo);
554
+ }
555
+ if (aInfoHBox.getItems().length > 0) {
556
+ oLabelItemForNotWrapping.addStyleClass("sapUiIntegrationEditorItemLabelWithInfo");
557
+ oLabelHBox = new HBox({
558
+ items: [
559
+ oLabelItemForNotWrapping,
560
+ aInfoHBox
561
+ ]
562
+ });
563
+ } else {
564
+ oLabelHBox = oLabelItemForNotWrapping;
565
+ }
566
+ if (oLayout && oLayout.position && oLayout.position === "field-label") {
567
+ oLabelHBox.setLayoutData(oFlexItemDataForSettings);
568
+ oFlexBox = new HBox({
569
+ alignItems: "Start",
570
+ justifyContent: "SpaceBetween",
571
+ items: [
572
+ oLabelHBox,
573
+ oItem._settingsButton
574
+ ]
575
+ });
576
+ oFlexBox.setLayoutData(new FlexItemData({
577
+ growFactor: iLabelWidth,
578
+ maxWidth: iLabelWidth + "%"
579
+ }));
580
+ oItem.setLayoutData(new FlexItemData({
581
+ growFactor: iFieldWidth,
582
+ maxWidth: iFieldWidth + "%"
583
+ }));
584
+ oHBox = new HBox({
585
+ alignItems: "Start",
586
+ justifyContent: "SpaceBetween",
587
+ items: [
588
+ oItem,
589
+ oFlexBox
590
+ ]
591
+ });
592
+ } else {
593
+ oItem.setLayoutData(oFlexItemDataForSettings);
594
+ oFlexBox = new HBox({
595
+ alignItems: "Start",
596
+ justifyContent: "SpaceBetween",
597
+ items: [
598
+ oItem,
599
+ oItem._settingsButton
600
+ ]
601
+ });
602
+ oLabelHBox.setLayoutData(new FlexItemData({
603
+ growFactor: iLabelWidth,
604
+ maxWidth: iLabelWidth + "%"
605
+ }));
606
+ oFlexBox.setLayoutData(new FlexItemData({
607
+ growFactor: iFieldWidth,
608
+ maxWidth: iFieldWidth + "%"
609
+ }));
610
+ oHBox = new HBox({
611
+ alignItems: "Start",
612
+ justifyContent: "SpaceBetween",
613
+ items: [
614
+ oLabelHBox,
615
+ oFlexBox
616
+ ]
617
+ });
618
+ }
619
+ //render label and field for NotWrapping parameter
620
+ if (oItem._cols === 1) {
621
+ if (oSubGroup) {
622
+ if (oColFieldsOfSubGroup.length === 2) {
623
+ addColFieldsOfSubGroup();
624
+ }
625
+ if (oConfig.hint) {
626
+ var oHint = oControl._createHint(oConfig.hint);
627
+ var oColVBox = new VBox({
628
+ items: [
629
+ oHBox,
630
+ oHint.addStyleClass("sapUiIntegrationEditorHint")
631
+ ]
632
+ });
633
+ oColVBox.addStyleClass("col1");
634
+ oColFieldsOfSubGroup.push(oColVBox);
635
+ } else {
636
+ oHBox.addStyleClass("col1");
637
+ oColFieldsOfSubGroup.push(oHBox);
638
+ }
639
+ } else {
640
+ if (oColFields.length === 2) {
641
+ addColFields();
642
+ }
643
+ if (oConfig.hint) {
644
+ var oHint = oControl._createHint(oConfig.hint);
645
+ var oColVBox = new VBox({
646
+ items: [
647
+ oHBox,
648
+ oHint.addStyleClass("sapUiIntegrationEditorHint")
649
+ ]
650
+ });
651
+ oColVBox.addStyleClass("col1");
652
+ oColFields.push(oColVBox);
653
+ } else {
654
+ oHBox.addStyleClass("col1");
655
+ oColFields.push(oHBox);
656
+ }
657
+ }
658
+ } else if (oSubGroup) {
659
+ addColFieldsOfSubGroup();
660
+ oSubGroup.addContent(oHBox);
661
+ } else {
662
+ addColFields();
663
+ oPanel.addContent(oHBox);
664
+ }
665
+ oLabelItemForNotWrapping = null;
559
666
  } else {
560
- oLabelHBox = oLabelItemForNotWrapping;
561
- }
562
- if (oLayout && oLayout.position && oLayout.position === "field-label") {
667
+ var oLabel;
668
+ if (oSubGroup) {
669
+ oLabel = oSubGroup.getContent().pop();
670
+ } else {
671
+ oLabel = oPanel.getContent().pop();
672
+ }
673
+ oLabel.setLayoutData(oFlexItemDataForInfo);
674
+ if (aInfoHBox.getItems().length > 0) {
675
+ oLabel.addStyleClass("sapUiIntegrationEditorItemLabelWithInfo");
676
+ oLabelHBox = new HBox({
677
+ items: [
678
+ oLabel,
679
+ aInfoHBox
680
+ ]
681
+ });
682
+ } else {
683
+ oLabelHBox = oLabel;
684
+ }
563
685
  oLabelHBox.setLayoutData(oFlexItemDataForSettings);
564
- oFlexBox = new HBox({
686
+ var oLabelFlexBox = new FlexBox({
565
687
  alignItems: "Start",
566
688
  justifyContent: "SpaceBetween",
567
689
  items: [
@@ -569,298 +691,182 @@ sap.ui.define([
569
691
  oItem._settingsButton
570
692
  ]
571
693
  });
572
- oFlexBox.setLayoutData(new FlexItemData({
573
- growFactor: iLabelWidth,
574
- maxWidth: iLabelWidth + "%"
575
- }));
576
- oItem.setLayoutData(new FlexItemData({
577
- growFactor: iFieldWidth,
578
- maxWidth: iFieldWidth + "%"
579
- }));
580
- oHBox = new HBox({
581
- alignItems: "Start",
582
- justifyContent: "SpaceBetween",
583
- items: [
584
- oItem,
585
- oFlexBox
586
- ]
587
- });
588
- } else {
589
- oItem.setLayoutData(oFlexItemDataForSettings);
590
- oFlexBox = new HBox({
591
- alignItems: "Start",
592
- justifyContent: "SpaceBetween",
593
- items: [
594
- oItem,
595
- oItem._settingsButton
596
- ]
597
- });
598
- oLabelHBox.setLayoutData(new FlexItemData({
599
- growFactor: iLabelWidth,
600
- maxWidth: iLabelWidth + "%"
601
- }));
602
- oFlexBox.setLayoutData(new FlexItemData({
603
- growFactor: iFieldWidth,
604
- maxWidth: iFieldWidth + "%"
605
- }));
606
- oHBox = new HBox({
607
- alignItems: "Start",
608
- justifyContent: "SpaceBetween",
609
- items: [
610
- oLabelHBox,
611
- oFlexBox
612
- ]
613
- });
614
- }
615
- //render label and field for NotWrapping parameter
616
- if (oItem._cols === 1) {
617
- if (oSubGroup) {
618
- if (oColFieldsOfSubGroup.length === 2) {
619
- addColFieldsOfSubGroup();
620
- }
694
+ if (oItem._cols === 1) {
695
+ var oColVBox = new VBox({
696
+ items: [
697
+ oLabelFlexBox,
698
+ oItem
699
+ ]
700
+ });
621
701
  if (oConfig.hint) {
622
702
  var oHint = oControl._createHint(oConfig.hint);
623
- var oColVBox = new VBox({
624
- items: [
625
- oHBox,
626
- oHint.addStyleClass("sapUiIntegrationEditorHint")
627
- ]
628
- });
629
- oColVBox.addStyleClass("col1");
703
+ oColVBox.addItem(oHint.addStyleClass("sapUiIntegrationEditorHint"));
704
+ }
705
+ oColVBox.addStyleClass("col1");
706
+ if (oSubGroup) {
630
707
  oColFieldsOfSubGroup.push(oColVBox);
631
708
  } else {
632
- oHBox.addStyleClass("col1");
633
- oColFieldsOfSubGroup.push(oHBox);
634
- }
635
- } else {
636
- if (oColFields.length === 2) {
637
- addColFields();
638
- }
639
- if (oConfig.hint) {
640
- var oHint = oControl._createHint(oConfig.hint);
641
- var oColVBox = new VBox({
642
- items: [
643
- oHBox,
644
- oHint.addStyleClass("sapUiIntegrationEditorHint")
645
- ]
646
- });
647
- oColVBox.addStyleClass("col1");
648
709
  oColFields.push(oColVBox);
649
- } else {
650
- oHBox.addStyleClass("col1");
651
- oColFields.push(oHBox);
652
710
  }
711
+ } else if (oSubGroup) {
712
+ oSubGroup.addContent(oLabelFlexBox);
713
+ oSubGroup.addContent(oItem);
714
+ } else {
715
+ oPanel.addContent(oLabelFlexBox);
716
+ oPanel.addContent(oItem);
653
717
  }
654
- } else if (oSubGroup) {
655
- addColFieldsOfSubGroup();
656
- oSubGroup.addContent(oHBox);
657
- } else {
658
- addColFields();
659
- oPanel.addContent(oHBox);
660
718
  }
661
- oLabelItemForNotWrapping = null;
662
- } else {
663
- var oLabel;
664
719
  if (oSubGroup) {
665
- oLabel = oSubGroup.getContent().pop();
666
- } else {
667
- oLabel = oPanel.getContent().pop();
668
- }
669
- oLabel.setLayoutData(oFlexItemDataForInfo);
670
- if (aInfoHBox.getItems().length > 0) {
671
- oLabel.addStyleClass("sapUiIntegrationEditorItemLabelWithInfo");
672
- oLabelHBox = new HBox({
673
- items: [
674
- oLabel,
675
- aInfoHBox
676
- ]
677
- });
678
- } else {
679
- oLabelHBox = oLabel;
680
- }
681
- oLabelHBox.setLayoutData(oFlexItemDataForSettings);
682
- var oLabelFlexBox = new FlexBox({
683
- alignItems: "Start",
684
- justifyContent: "SpaceBetween",
685
- items: [
686
- oLabelHBox,
687
- oItem._settingsButton
688
- ]
689
- });
690
- if (oItem._cols === 1) {
691
- var oColVBox = new VBox({
692
- items: [
693
- oLabelFlexBox,
694
- oItem
695
- ]
720
+ oSubGroup._subItems.push({
721
+ "settingspath": oItem.getConfiguration()._settingspath,
722
+ "itemId": oItem.getId()
696
723
  });
697
- if (oConfig.hint) {
698
- var oHint = oControl._createHint(oConfig.hint);
699
- oColVBox.addItem(oHint.addStyleClass("sapUiIntegrationEditorHint"));
700
- }
701
- oColVBox.addStyleClass("col1");
702
- if (oSubGroup) {
703
- oColFieldsOfSubGroup.push(oColVBox);
704
- } else {
705
- oColFields.push(oColVBox);
706
- }
707
- } else if (oSubGroup) {
708
- oSubGroup.addContent(oLabelFlexBox);
709
- oSubGroup.addContent(oItem);
710
- } else {
711
- oPanel.addContent(oLabelFlexBox);
712
- oPanel.addContent(oItem);
713
724
  }
714
- }
715
- if (oSubGroup) {
716
- oSubGroup._subItems.push({
725
+ oPanel._subItems.push({
717
726
  "settingspath": oItem.getConfiguration()._settingspath,
718
727
  "itemId": oItem.getId()
719
728
  });
720
729
  }
721
- oPanel._subItems.push({
722
- "settingspath": oItem.getConfiguration()._settingspath,
723
- "itemId": oItem.getId()
724
- });
725
- }
726
- if (i === aItems.length - 1) {
727
- if (oSubGroup) {
728
- //add current col fields to previous sub panel, then empty the col fields list
729
- addColFieldsOfSubGroup();
730
- //add sub panel to panel
731
- if (oSubGroup.isA("sap.m.Panel")) {
732
- addSubPanel(oPanel, oSubGroup);
733
- } else {
734
- addSubTab(oPanel, oSubGroup);
730
+ if (i === aItems.length - 1) {
731
+ if (oSubGroup) {
732
+ //add current col fields to previous sub panel, then empty the col fields list
733
+ addColFieldsOfSubGroup();
734
+ //add sub panel to panel
735
+ if (oSubGroup.isA("sap.m.Panel")) {
736
+ addSubPanel(oPanel, oSubGroup);
737
+ } else {
738
+ addSubTab(oPanel, oSubGroup);
739
+ }
735
740
  }
741
+ //add current col fields to panel, then empty the col fields list
742
+ addColFields();
743
+ renderPanel(oPanel);
736
744
  }
737
- //add current col fields to panel, then empty the col fields list
738
- addColFields();
739
- renderPanel(oPanel);
740
- }
741
- } else {
742
- if (i === 0) {
743
- //render the top panel of translation
744
- oLanguagePanel = oItem;
745
- oRm.renderControl(oLanguagePanel);
746
- oLanguagePanel.addStyleClass("sapUiIntegrationEditorTranslationPanel");
747
- continue;
748
- }
749
- if (oItem.isA("sap.m.Panel") || oItem.isA("sap.m.IconTabBar")) {
750
- if (oSubGroup) {
751
- //add sub panel to panel
752
- if (oItem.isA("sap.m.Panel") && oSubGroup.isA("sap.m.Panel")) {
753
- addSubPanel(oPanel, oSubGroup);
754
- } else {
755
- addSubTab(oPanel, oSubGroup);
756
- }
745
+ } else {
746
+ if (i === 0) {
747
+ //render the top panel field of translation
748
+ oLanguagePanel = oItem.getAggregation("_field");
749
+ oRm.renderControl(oItem);
750
+ oItem.addStyleClass("sapUiIntegrationEditorTranslationPanel");
751
+ continue;
757
752
  }
758
- var tItemLevel = 0;
759
- if (oItem.isA("sap.m.Panel")) {
760
- tItemLevel = oItem._level;
761
- } else if (oItem.isA("sap.m.IconTabBar")) {
762
- if (oItem.getItems().length > 0 && oItem.getItems()[0]._level) {
763
- tItemLevel = oItem.getItems()[0]._level;
753
+ if (oItem.isA("sap.ui.integration.editor.fields.GroupField")) {
754
+ var oGroupControl = oItem.getAggregation("_field");
755
+ if (oSubGroup) {
756
+ //add sub panel to panel
757
+ if (oGroupControl.isA("sap.m.Panel") && oSubGroup.isA("sap.m.Panel")) {
758
+ addSubPanel(oPanel, oSubGroup);
759
+ } else {
760
+ addSubTab(oPanel, oSubGroup);
761
+ }
764
762
  }
765
- }
766
- if (tItemLevel === "1") {
767
- if (oItem.isA("sap.m.IconTabBar")) {
768
- if (i !== aItems.length - 1 || (i < aItems.length && (aItems[i].isA("sap.m.IconTabBar") || aItems[i].isA("sap.m.Panel")))) {
769
- var tSubItems = oPanel.getContent(),
770
- tIconTabBarExist = false;
771
- if (tSubItems.length > 0) {
772
- for (var l = 0; l < tSubItems.length; l++) {
773
- if (tSubItems[l].isA("sap.m.IconTabBar")) {
774
- tIconTabBarExist = true;
763
+ var tItemLevel = 0;
764
+ if (oGroupControl.isA("sap.m.Panel")) {
765
+ tItemLevel = oGroupControl._level;
766
+ } else if (oGroupControl.isA("sap.m.IconTabBar")) {
767
+ if (oGroupControl.getItems().length > 0 && oGroupControl.getItems()[0]._level) {
768
+ tItemLevel = oGroupControl.getItems()[0]._level;
769
+ }
770
+ }
771
+ if (tItemLevel === "1") {
772
+ if (oGroupControl.isA("sap.m.IconTabBar")) {
773
+ if (i !== aItems.length - 1 || (i < aItems.length && (aItems[i].isA("sap.m.IconTabBar") || aItems[i].isA("sap.m.Panel")))) {
774
+ var tSubItems = oPanel.getContent(),
775
+ tIconTabBarExist = false;
776
+ if (tSubItems.length > 0) {
777
+ for (var l = 0; l < tSubItems.length; l++) {
778
+ if (tSubItems[l].getAggregation("_field") && tSubItems[l].getAggregation("_field").isA("sap.m.IconTabBar")) {
779
+ tIconTabBarExist = true;
780
+ }
775
781
  }
776
782
  }
783
+ if (!tIconTabBarExist) {
784
+ oSubGroup = oGroupControl.getItems()[0];
785
+ oGroupControl.removeItem(oGroupControl.getItems()[0]);
786
+ oPanel.addContent(oGroupControl.getParent());
787
+ } else {
788
+ oSubGroup = oGroupControl.getItems()[0];
789
+ }
777
790
  }
778
- if (!tIconTabBarExist) {
779
- oSubGroup = oItem.getItems()[0];
780
- oItem.removeItem(oItem.getItems()[0]);
781
- oPanel.addContent(oItem);
782
- } else {
783
- oSubGroup = oItem.getItems()[0];
784
- }
791
+ } else {
792
+ oSubGroup = oGroupControl;
793
+ oSubGroup.addStyleClass("sapUiIntegrationEditorSubGroup");
785
794
  }
786
795
  } else {
787
- oSubGroup = oItem;
788
- oSubGroup.addStyleClass("sapUiIntegrationEditorSubGroup");
796
+ oSubGroup = null;
797
+ //add sub panel if it has content into top panel
798
+ if (oPanel && oPanel.getContent().length > 0) {
799
+ oLanguagePanel.addContent(oPanel.getParent());
800
+ }
801
+ oPanel = oGroupControl;
802
+ oPanel.addStyleClass("sapUiIntegrationEditorSubGroup");
789
803
  }
790
- } else {
791
- oSubGroup = null;
792
- //add sub panel if it has content into top panel
793
- if (oPanel && oPanel.getContent().length > 0) {
794
- oLanguagePanel.addContent(oPanel);
804
+ if (i === aItems.length - 1) {
805
+ //add current col fields to panel, then empty the col fields list
806
+ addColFields();
807
+ renderPanel(oPanel);
795
808
  }
796
- oPanel = oItem;
797
- oPanel.addStyleClass("sapUiIntegrationEditorSubGroup");
809
+ continue;
798
810
  }
799
- if (i === aItems.length - 1) {
800
- //add current col fields to panel, then empty the col fields list
801
- addColFields();
802
- renderPanel(oPanel);
811
+ if (oItem.isA("sap.m.ToolbarSpacer")) {
812
+ continue;
803
813
  }
804
- continue;
805
- }
806
- if (oItem.isA("sap.m.ToolbarSpacer")) {
807
- continue;
808
- }
809
- if (oItem.isA("sap.m.FormattedText")) {
810
- continue;
811
- }
812
- if (oItem.isA("sap.m.Label")) {
814
+ if (oItem.isA("sap.m.FormattedText")) {
815
+ continue;
816
+ }
817
+ if (oItem.isA("sap.m.Label")) {
818
+ if (oSubGroup) {
819
+ oSubGroup.addContent(oItem);
820
+ } else {
821
+ oPanel.addContent(oItem);
822
+ }
823
+ continue;
824
+ }
825
+ //oItem.addStyleClass("language");
826
+ if (oItem.isOrigLangField) {
827
+ oOriginalField = oItem;
828
+ continue;
829
+ }
830
+ oOriginalField.addStyleClass("sapUiIntegrationFieldTranslationText");
831
+ //bind originalField and translation field together
832
+ var oHBox = new HBox({
833
+ items: [
834
+ oOriginalField,
835
+ oItem
836
+ ]
837
+ }).addStyleClass("notWrappingRow");
813
838
  if (oSubGroup) {
814
- oSubGroup.addContent(oItem);
839
+ oSubGroup.addContent(oHBox);
815
840
  } else {
816
- oPanel.addContent(oItem);
841
+ oPanel.addContent(oHBox);
817
842
  }
818
- continue;
819
- }
820
- //oItem.addStyleClass("language");
821
- if (oItem.isOrigLangField) {
822
- oOriginalField = oItem;
823
- continue;
824
- }
825
- oOriginalField.addStyleClass("sapUiIntegrationFieldTranslationText");
826
- //bind originalField and translation field together
827
- var oHBox = new HBox({
828
- items: [
829
- oOriginalField,
830
- oItem
831
- ]
832
- }).addStyleClass("notWrappingRow");
833
- if (oSubGroup) {
834
- oSubGroup.addContent(oHBox);
835
- } else {
836
- oPanel.addContent(oHBox);
837
- }
838
- if (i === aItems.length - 1) {
839
- if (oSubGroup) {
840
- //add sub panel to panel
841
- if (oSubGroup.isA("sap.m.Panel")) {
842
- addSubPanel(oPanel, oSubGroup);
843
- } else {
844
- addSubTab(oPanel, oSubGroup);
843
+ if (i === aItems.length - 1) {
844
+ if (oSubGroup) {
845
+ //add sub panel to panel
846
+ if (oSubGroup.isA("sap.m.Panel")) {
847
+ addSubPanel(oPanel, oSubGroup);
848
+ } else {
849
+ addSubTab(oPanel, oSubGroup);
850
+ }
845
851
  }
852
+ oLanguagePanel.addContent(oPanel.getParent());
846
853
  }
847
- oLanguagePanel.addContent(oPanel);
848
854
  }
849
855
  }
850
856
  }
857
+ oRm.close("div");
858
+ //render the additional content if alignment of it is "right"
859
+ if (bShowPreview && sPreviewPosition === "right") {
860
+ oRm.renderControl(oPreview);
861
+ }
851
862
  }
852
863
  oRm.close("div");
853
864
  //render the additional content if alignment of it is "right"
854
- if (bShowPreview && sPreviewPosition === "right") {
865
+ if (oControl.isReady() && bShowPreview && sPreviewPosition === "bottom") {
855
866
  oRm.renderControl(oPreview);
867
+ oRm.close("div");
856
868
  }
857
869
  }
858
- oRm.close("div");
859
- //render the additional content if alignment of it is "right"
860
- if (oControl.isReady() && bShowPreview && sPreviewPosition === "bottom") {
861
- oRm.renderControl(oPreview);
862
- oRm.close("div");
863
- }
864
870
  }
865
871
  });
866
872
  /**
@@ -887,7 +893,7 @@ sap.ui.define([
887
893
  * @experimental since 1.94
888
894
  * @public
889
895
  * @author SAP SE
890
- * @version 1.106.0
896
+ * @version 1.107.0
891
897
  * @borrows sap.ui.integration.editor.Editor#getParameters as getParameters
892
898
  * @borrows sap.ui.integration.editor.Editor#resolveDestination as resolveDestination
893
899
  * @borrows sap.ui.integration.editor.Editor#request as request
@@ -1507,6 +1513,7 @@ sap.ui.define([
1507
1513
  // recount the position value
1508
1514
  for (var i = 0; i < aValue.length; i++) {
1509
1515
  var oValue = aValue[i];
1516
+ oValue._dt = oValue._dt || {};
1510
1517
  oValue._dt._position = i + 1;
1511
1518
  }
1512
1519
  mResult[oItem.manifestpath] = aValue;
@@ -1801,7 +1808,8 @@ sap.ui.define([
1801
1808
  "datetime": "sap/ui/integration/editor/fields/DateTimeField",
1802
1809
  "object": "sap/ui/integration/editor/fields/ObjectField",
1803
1810
  "object[]": "sap/ui/integration/editor/fields/ObjectListField",
1804
- "destination": "sap/ui/integration/editor/fields/DestinationField"
1811
+ "destination": "sap/ui/integration/editor/fields/DestinationField",
1812
+ "group": "sap/ui/integration/editor/fields/GroupField"
1805
1813
  };
1806
1814
  Editor.Fields = null;
1807
1815
  /**
@@ -2006,59 +2014,64 @@ sap.ui.define([
2006
2014
  });
2007
2015
 
2008
2016
  this._aFieldReadyPromise.push(oField._readyPromise.then(function() {
2009
- if (oConfig.require
2010
- || oConfig.validation
2011
- || (oConfig.validations && oConfig.validations.length > 0)
2012
- || (oConfig.values && oConfig.values.data && !oConfig.values.data.json)) {
2013
- var oMsgIcon = this._createMessageIcon(oField);
2014
- oField.setAssociation("_messageIcon", oMsgIcon);
2015
- }
2016
- if (oConfig.description && this.getMode() !== "translation") {
2017
- oField._descriptionIcon = this._createDescription(oConfig);
2018
- }
2019
- if (oConfig._changeDynamicValues) {
2020
- oField._settingsButton = this._createSettingsButton(oField);
2021
- oField._applyButtonStyles();
2017
+ // for group field, will do nothing else
2018
+ if (oConfig.type !== "group") {
2019
+ if (oConfig.require
2020
+ || oConfig.validation
2021
+ || (oConfig.validations && oConfig.validations.length > 0)
2022
+ || (oConfig.values && oConfig.values.data && !oConfig.values.data.json)) {
2023
+ var oMsgIcon = this._createMessageIcon(oField);
2024
+ oField.setAssociation("_messageIcon", oMsgIcon);
2025
+ }
2026
+ if (oConfig.description && this.getMode() !== "translation") {
2027
+ oField._descriptionIcon = this._createDescription(oConfig);
2028
+ }
2029
+ if (oConfig._changeDynamicValues) {
2030
+ oField._settingsButton = this._createSettingsButton(oField);
2031
+ oField._applyButtonStyles();
2032
+ }
2022
2033
  }
2023
2034
  }.bind(this)));
2024
- //listen to value changes on the settings
2025
- oField._oValueBinding = this._settingsModel.bindProperty(oConfig._settingspath + "/value");
2026
- oField._oValueBinding.attachChange(function () {
2027
- if (!this._bIgnoreUpdates) {
2028
- oConfig._changed = true;
2029
- if (oConfig._dependentFields && oConfig._dependentFields.length > 0) {
2030
- this._updateEditor(oConfig._dependentFields);
2035
+ if (oConfig.type !== "group") {
2036
+ // listen to value changes on the settings
2037
+ oField._oValueBinding = this._settingsModel.bindProperty(oConfig._settingspath + "/value");
2038
+ oField._oValueBinding.attachChange(function () {
2039
+ if (!this._bIgnoreUpdates) {
2040
+ oConfig._changed = true;
2041
+ if (oConfig._dependentFields && oConfig._dependentFields.length > 0) {
2042
+ this._updateEditor(oConfig._dependentFields);
2043
+ }
2044
+ this._updatePreview();
2031
2045
  }
2032
- this._updatePreview();
2033
- }
2034
- }.bind(this));
2035
- if (oField.isFilterBackend()) {
2036
- //listen to suggest value changes on the settings if current field support filter backend feature
2037
- var oSuggestValueBinding = this._settingsModel.bindProperty(oConfig._settingspath + "/suggestValue");
2038
- oSuggestValueBinding.attachChange(function () {
2039
- var oConfigTemp = merge({}, oConfig);
2040
- oConfigTemp._cancel = false;
2041
- this._addValueListModel(oConfigTemp, oField);
2042
2046
  }.bind(this));
2043
- }
2044
- if (oConfig.values) {
2045
- // load metadata
2046
- if (oConfig.values.metadata) {
2047
- this._addMetadataModel(oConfig, oField);
2047
+ if (oField.isFilterBackend()) {
2048
+ // listen to suggest value changes on the settings if current field support filter backend feature
2049
+ var oSuggestValueBinding = this._settingsModel.bindProperty(oConfig._settingspath + "/suggestValue");
2050
+ oSuggestValueBinding.attachChange(function () {
2051
+ var oConfigTemp = merge({}, oConfig);
2052
+ oConfigTemp._cancel = false;
2053
+ this._addValueListModel(oConfigTemp, oField);
2054
+ }.bind(this));
2048
2055
  }
2049
- // for MultiInput used in string[] field with filter backend, do not request data when creating it
2050
- if (oConfig.type === "string[]" && oField.isFilterBackend() && oConfig.visualization && oConfig.visualization.type === "MultiInput") {
2051
- oField.setModel(new JSONModel({}), undefined);
2052
- } else {
2053
- this._addValueListModel(oConfig, oField);
2056
+ if (oConfig.values) {
2057
+ // load metadata
2058
+ if (oConfig.values.metadata) {
2059
+ this._addMetadataModel(oConfig, oField);
2060
+ }
2061
+ // for MultiInput used in string[] field with filter backend, do not request data when creating it
2062
+ if (oConfig.type === "string[]" && oField.isFilterBackend() && oConfig.visualization && oConfig.visualization.type === "MultiInput") {
2063
+ oField.setModel(new JSONModel({}), undefined);
2064
+ } else {
2065
+ this._addValueListModel(oConfig, oField);
2066
+ }
2054
2067
  }
2068
+ this._createDependentFields(oConfig, oField);
2069
+ oField._oDataProviderFactory = this._oDataProviderFactory;
2055
2070
  }
2056
- this._createDependentFields(oConfig, oField);
2057
2071
  oField._cols = oConfig.cols || 2; //by default 2 cols
2058
2072
  if (oConfig.layout) {
2059
2073
  oField._layout = oConfig.layout;
2060
2074
  }
2061
- oField._oDataProviderFactory = this._oDataProviderFactory;
2062
2075
  oField.setAssociation("_messageStrip", MessageStripId);
2063
2076
  return oField;
2064
2077
  };
@@ -2510,62 +2523,12 @@ sap.ui.define([
2510
2523
  this._settingsModel.setProperty(sTranslationPath, oTexts);
2511
2524
  };
2512
2525
 
2513
- Editor.prototype._handleITBValidation = function (oEditor, sItem, sErrorType) {
2514
- var oResourceBundle = oEditor._oResourceBundle;
2515
- if (sItem.getItems().length > 0 && sItem._oExpandButton) {
2516
- var expandBTN = sItem._oExpandButton;
2517
- var errorMSG = null;
2518
- if (sErrorType === "Error") {
2519
- errorMSG = oResourceBundle.getText("EDITOR_GROUP_ERRORS");
2520
- expandBTN.setIcon("sap-icon://message-error");
2521
- expandBTN.addStyleClass("errorBTNImage");
2522
- } else if (sErrorType === "Warning") {
2523
- errorMSG = oResourceBundle.getText("EDITOR_GROUP_WARNINGS");
2524
- expandBTN.setIcon("sap-icon://message-warning");
2525
- expandBTN.addStyleClass("warningBTNImage");
2526
- }
2527
- //remove expandButton addtional information
2528
- expandBTN.setTooltip(null);
2529
- expandBTN.addEventDelegate({
2530
- onAfterRendering: function(oEvent) {
2531
- var eExpandBTN = document.getElementById(expandBTN.getId());
2532
- eExpandBTN.setAttribute("aria-label", "With validation errors");
2533
- eExpandBTN.setAttribute("title", "");
2534
- }
2535
- });
2536
- expandBTN.setEnabled(false);
2537
- expandBTN.addStyleClass("errorBTN").addStyleClass("errorBTNDisabled");
2538
- var iITBar = expandBTN.getParent().getParent().getParent();
2539
- var iMessageStrip = Core.byId(iITBar.getId() + "_strip");
2540
- expandBTN.addEventDelegate({
2541
- onmouseover: function() {
2542
- iMessageStrip.setVisible(true);
2543
- iMessageStrip.setType(sErrorType);
2544
- iMessageStrip.setText(errorMSG);
2545
- },
2546
- onmouseout: function() {
2547
- iMessageStrip.setVisible(false);
2548
- }
2549
- }, oEditor);
2550
- }
2551
- };
2552
-
2553
- Editor.prototype._delayHandleITBValidation = function(oEditor,oItem, sErrorType) {
2554
- var checkExpandBTNExist = setInterval(function() {
2555
- if (oItem._oExpandButton) {
2556
- oEditor._handleITBValidation(oEditor, oItem, sErrorType);
2557
- clearInterval(checkExpandBTNExist);
2558
- }
2559
- }, 50);
2560
- };
2561
-
2562
2526
  /**
2563
2527
  * Adds an item to the _formContent aggregation based on the config settings
2564
2528
  * @param {} oConfig
2565
2529
  */
2566
2530
  Editor.prototype._addItem = function (oConfig) {
2567
- var sMode = this.getMode(),
2568
- that = this;
2531
+ var sMode = this.getMode();
2569
2532
  //force to turn off features for settings and dynamic values and set the default if not configured
2570
2533
  if (this.getAllowDynamicValues() === false || !oConfig.allowDynamicValues) {
2571
2534
  oConfig.allowDynamicValues = false;
@@ -2582,273 +2545,12 @@ sap.ui.define([
2582
2545
  //display subPanel as iconTabBar or Panel
2583
2546
  if (oConfig.type === "group") {
2584
2547
  oConfig.expanded = oConfig.expanded !== false;
2585
- if (oConfig.visualization && oConfig.visualization.type === "Tab") {
2586
- var oIconTabBar = new IconTabBar({
2587
- expandable: oConfig.expandable !== false,
2588
- visible: oConfig.visible,
2589
- expanded: "{currentSettings>expanded}",
2590
- objectBindings: {
2591
- currentSettings: {
2592
- path: "currentSettings>" + oConfig._settingspath
2593
- },
2594
- items: {
2595
- path: "items>/form/items"
2596
- },
2597
- context: {
2598
- path: "context>/"
2599
- }
2600
- },
2601
- select: function (oEvent) {
2602
- var oControl = oEvent.getSource(),
2603
- oSelectITFKey = oControl.getSelectedKey(),
2604
- aItems = oControl.getItems(),
2605
- vExpanded = oControl.getExpanded(),
2606
- vShowErrors = false;
2607
- for (var n = 0; n < aItems.length; n++) {
2608
- if (!vExpanded) {
2609
- vShowErrors = true;
2610
- } else if (aItems[n].getId() !== oSelectITFKey) {
2611
- vShowErrors = true;
2612
- } else if (aItems[n].getId() === oSelectITFKey) {
2613
- vShowErrors = false;
2614
- }
2615
- if (vShowErrors) {
2616
- var bHasError = false,
2617
- sErrorType = "None";
2618
- if (aItems[n]._subItems && aItems[n]._subItems.length > 0) {
2619
- var oCurrentSettingsModel = aItems[n].getModel("currentSettings");
2620
- for (var i = 0; i < aItems[n]._subItems.length; i++) {
2621
- var sSettingsPath = aItems[n]._subItems[i].settingspath;
2622
- var oItem = Core.byId(aItems[n]._subItems[i].itemId);
2623
- if (oCurrentSettingsModel.getProperty(sSettingsPath + "/hasError") === true && oItem.getVisible()) {
2624
- bHasError = true;
2625
- var sType = oCurrentSettingsModel.getProperty(sSettingsPath + "/errorType");
2626
- if (sType === "Error") {
2627
- sErrorType = "Error";
2628
- break;
2629
- } else if (sType === "Warning" && sErrorType !== "Error") {
2630
- sErrorType = "Warning";
2631
- }
2632
- }
2633
- }
2634
- oCurrentSettingsModel.setProperty("hasError", bHasError, oControl.getBindingContext("currentSettings"));
2635
- oCurrentSettingsModel.setProperty("errorType", sErrorType, oControl.getBindingContext("currentSettings"));
2636
- }
2637
- if (bHasError) {
2638
- var vITF = new IconTabFilter(),
2639
- aItem = aItems[n];
2640
- if (aItem.getItems().length > 0) {
2641
- aItem.removeAllItems();
2642
- }
2643
- aItem.addItem(vITF);
2644
- that._handleITBValidation(that, aItem, sErrorType);
2645
- if (aItem._oExpandButton === undefined) {
2646
- that._delayHandleITBValidation(that, aItem, sErrorType);
2647
- } else {
2648
- that._handleITBValidation(that, aItem, sErrorType);
2649
- }
2650
- }
2651
- } else if (aItems[n].getItems().length > 0) {
2652
- aItems[n].removeItem(aItems[n].getItems()[0]);
2653
- if (aItems[n]._oExpandButton) {
2654
- aItems[n]._oExpandButton.visible = false;
2655
- }
2656
- //handle error message for fields
2657
- var tMessageStrip = oControl.getParent().getParent().getAggregation("_messageStrip");
2658
- if (tMessageStrip === null) {
2659
- tMessageStrip = Core.byId(MessageStripId);
2660
- }
2661
- aItems[n].addContent(tMessageStrip);
2662
- }
2663
- }
2664
- }
2665
- });
2666
- var oIconTabFilter = new IconTabFilter({
2667
- text: oConfig.label,
2668
- visible: oConfig.visible,
2669
- objectBindings: {
2670
- currentSettings: {
2671
- path: "currentSettings>" + oConfig._settingspath
2672
- },
2673
- items: {
2674
- path: "items>/form/items"
2675
- },
2676
- context: {
2677
- path: "context>/"
2678
- }
2679
- }
2680
- });
2681
- oIconTabBar.addItem(oIconTabFilter);
2682
- oIconTabBar.setBackgroundDesign("Transparent");
2683
- oIconTabBar.setHeaderBackgroundDesign("Transparent");
2684
- // oIconTabBar.setHeaderBackgroundDesign("Solid");
2685
- oIconTabBar.addStyleClass("sapUiIntegrationEditorSubGroup");
2686
- // oIconTabBar.addStyleClass("sapUiIntegrationEditorSubGroup").addStyleClass("cardEditorIconTabBarBG");
2687
- // handle messageStrip for tab filter
2688
- if (sMode !== "translation") {
2689
- var oMessageStripOfTab = new MessageStrip({
2690
- id: oIconTabBar.getId() + "_strip",
2691
- showIcon: false,
2692
- visible: false
2693
- });
2694
- oMessageStripOfTab.addStyleClass("sapUiIntegrationEditorTabMessageStrip");
2695
- oIconTabBar._messageStrip = oMessageStripOfTab;
2696
- }
2697
- this.addAggregation("_formContent", oIconTabBar);
2698
- // oIconTabFilter._cols = oConfig.cols || 2; //by default 2 cols
2699
- oIconTabFilter._level = oConfig.level || 0; //by default 0 level
2700
- if (oConfig.hint) {
2701
- this._addHint(oConfig.hint);
2702
- }
2703
- return;
2704
- } else {
2705
- var oPanel = new Panel({
2706
- headerText: oConfig.label,
2707
- visible: oConfig.visible,
2708
- expandable: oConfig.expandable !== false,
2709
- expanded: "{currentSettings>expanded}",
2710
- width: "auto",
2711
- backgroundDesign: "Transparent",
2712
- objectBindings: {
2713
- currentSettings: {
2714
- path: "currentSettings>" + oConfig._settingspath
2715
- },
2716
- items: {
2717
- path: "items>/form/items"
2718
- },
2719
- context: {
2720
- path: "context>/"
2721
- }
2722
- },
2723
- expand: function (oEvent) {
2724
- var oControl = oEvent.getSource();
2725
- var bExpand = oEvent.getParameter("expand");
2726
- // handle error message strip for field
2727
- var oMessageStrip = oControl._level === "1" ? oControl.getParent().getParent().getAggregation("_messageStrip") : oControl.getParent().getAggregation("_messageStrip");
2728
- if (oMessageStrip === null) {
2729
- oMessageStrip = Core.byId(MessageStripId);
2730
- }
2731
- if (!bExpand && oControl._level === "1") {
2732
- oControl.getParent().addContent(oMessageStrip);
2733
- oControl.getParent().focus();
2734
- } else {
2735
- oControl.addContent(oMessageStrip);
2736
- oControl.focus();
2737
- }
2738
- // handle error message for panel
2739
- if (!bExpand && oControl._subItems && oControl._subItems.length > 0) {
2740
- var oCurrentSettingsModel = oControl.getModel("currentSettings");
2741
- var bHasError = false;
2742
- var sErrorType = "None";
2743
- for (var i = 0; i < oControl._subItems.length; i++) {
2744
- var sSettingsPath = oControl._subItems[i].settingspath;
2745
- var oItem = Core.byId(oControl._subItems[i].itemId);
2746
- if (oCurrentSettingsModel.getProperty(sSettingsPath + "/hasError") === true && oItem.getVisible()) {
2747
- bHasError = true;
2748
- var sType = oCurrentSettingsModel.getProperty(sSettingsPath + "/errorType");
2749
- if (sType === "Error") {
2750
- sErrorType = "Error";
2751
- break;
2752
- } else if (sType === "Warning" && sErrorType !== "Error") {
2753
- sErrorType = "Warning";
2754
- }
2755
- }
2756
- }
2757
- oCurrentSettingsModel.setProperty("hasError", bHasError, oControl.getBindingContext("currentSettings"));
2758
- oCurrentSettingsModel.setProperty("errorType", sErrorType, oControl.getBindingContext("currentSettings"));
2759
- }
2760
- }
2761
- });
2762
- if (sMode !== "translation") {
2763
- /*
2764
- var oMessage = new MessageStrip({
2765
- showIcon: false,
2766
- text: {
2767
- path: 'currentSettings>errorType',
2768
- formatter: function (errorType) {
2769
- var sPanelTitle = "";
2770
- switch (errorType) {
2771
- case "Error":
2772
- sPanelTitle = oResourceBundle.getText("EDITOR_GROUP_ERRORS");
2773
- break;
2774
- case "Warning":
2775
- sPanelTitle = oResourceBundle.getText("EDITOR_GROUP_WARNINGS");
2776
- break;
2777
- default:
2778
- }
2779
- return sPanelTitle;
2780
- }
2781
- },
2782
- type: "{currentSettings>errorType}",
2783
- visible: "{= !${currentSettings>expanded} && ${currentSettings>hasError} === true}"
2784
- }).addStyleClass("sapUiIntegrationEditorPanelMessageStrip");
2785
- var oHeaderToolbar = new OverflowToolbar({
2786
- content: [
2787
- new Title({
2788
- text: oConfig.label
2789
- }),
2790
- new Separator(),
2791
- oMessage
2792
- ]
2793
- }).addStyleClass("sapUiIntegrationEditorPanelHeader");
2794
- oPanel.setHeaderToolbar(oHeaderToolbar);
2795
- */
2796
- var oResourceBundle = this._oResourceBundle;
2797
- var oMessageStripOfPanel = new MessageStrip({
2798
- showIcon: false,
2799
- visible: "{= !${currentSettings>expanded} && ${currentSettings>hasError} === true}",
2800
- text: {
2801
- path: 'currentSettings>errorType',
2802
- formatter: function (errorType) {
2803
- var sPanelTitle = "";
2804
- switch (errorType) {
2805
- case "Error":
2806
- sPanelTitle = oResourceBundle.getText("EDITOR_GROUP_ERRORS");
2807
- break;
2808
- case "Warning":
2809
- sPanelTitle = oResourceBundle.getText("EDITOR_GROUP_WARNINGS");
2810
- break;
2811
- default:
2812
- }
2813
- return sPanelTitle;
2814
- }
2815
- },
2816
- type: "{currentSettings>errorType}",
2817
- objectBindings: {
2818
- currentSettings: {
2819
- path: "currentSettings>" + oConfig._settingspath
2820
- }
2821
- }
2822
- });
2823
- if (oConfig.level !== "1") {
2824
- oMessageStripOfPanel.setModel(this._settingsModel, "currentSettings");
2825
- }
2826
- oMessageStripOfPanel.addStyleClass("sapUiIntegrationEditorPanelMessageStrip");
2827
- oPanel._messageStrip = oMessageStripOfPanel;
2828
- }/* else {
2829
- oPanel.setHeaderText(oConfig.label);
2830
- }*/
2831
- this.addAggregation("_formContent", oPanel);
2832
- oPanel._cols = oConfig.cols || 2; //by default 2 cols
2833
- oPanel._level = oConfig.level || 0; //by default 0 level
2834
- if (oConfig.hint) {
2835
- this._addHint(oConfig.hint);
2836
- }
2837
- //add "aria-label" for each panel to make the landmark uniquely
2838
- var oDelegate = {
2839
- onAfterRendering: function(oEvent) {
2840
- var ePanel = document.getElementById(oPanel.getId());
2841
- ePanel.setAttribute("aria-label", oConfig.label);
2842
- var oControl = oEvent.srcControl;
2843
- var oMessageStrip = oControl._messageStrip;
2844
- if (oControl._level !== "1" && oMessageStrip) {
2845
- oMessageStrip.rerender();
2846
- }
2847
- }
2848
- };
2849
- oPanel.addEventDelegate(oDelegate);
2850
- return;
2548
+ var oField = this._createField(oConfig);
2549
+ this.addAggregation("_formContent", oField);
2550
+ if (oConfig.hint) {
2551
+ this._addHint(oConfig.hint);
2851
2552
  }
2553
+ return;
2852
2554
  }
2853
2555
  if (oConfig.type === "separator") {
2854
2556
  var oSeparator = new Separator();
@@ -3253,14 +2955,12 @@ sap.ui.define([
3253
2955
  if (this.getMode() !== "translation") {
3254
2956
  this._initPreview().then(function() {
3255
2957
  Promise.all(this._aFieldReadyPromise).then(function () {
3256
- this.setPreviewPositionForFields();
3257
2958
  this._ready = true;
3258
2959
  this.fireReady();
3259
2960
  }.bind(this));
3260
2961
  }.bind(this));
3261
2962
  } else {
3262
2963
  Promise.all(this._aFieldReadyPromise).then(function () {
3263
- this.setPreviewPositionForFields();
3264
2964
  this._ready = true;
3265
2965
  this.fireReady();
3266
2966
  }.bind(this));
@@ -3281,14 +2981,6 @@ sap.ui.define([
3281
2981
  }
3282
2982
  };
3283
2983
 
3284
- Editor.prototype.setPreviewPositionForFields = function() {
3285
- var sPosition = this.hasPreview() ? this.getPreviewPosition() : "";
3286
- var oSettings = this._settingsModel.getData();
3287
- oSettings.preview = oSettings.preview || {};
3288
- oSettings.preview.position = sPosition;
3289
- this._settingsModel.setData(oSettings);
3290
- };
3291
-
3292
2984
  /**
3293
2985
  * Destroy the editor and the internal instances that it created
3294
2986
  */