@openui5/sap.ui.rta 1.120.21 → 1.120.22

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 (95) 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 +1 -1
  5. package/src/sap/ui/rta/Utils.js +1 -1
  6. package/src/sap/ui/rta/appVariant/AppVariantManager.js +1 -1
  7. package/src/sap/ui/rta/command/AddIFrame.js +6 -1
  8. package/src/sap/ui/rta/command/AddProperty.js +1 -1
  9. package/src/sap/ui/rta/command/AddXML.js +1 -1
  10. package/src/sap/ui/rta/command/AddXMLAtExtensionPoint.js +1 -1
  11. package/src/sap/ui/rta/command/AppDescriptorCommand.js +1 -1
  12. package/src/sap/ui/rta/command/BaseCommand.js +1 -1
  13. package/src/sap/ui/rta/command/BindProperty.js +1 -1
  14. package/src/sap/ui/rta/command/Combine.js +1 -1
  15. package/src/sap/ui/rta/command/CommandFactory.js +1 -1
  16. package/src/sap/ui/rta/command/CompositeCommand.js +1 -1
  17. package/src/sap/ui/rta/command/ControlVariantConfigure.js +1 -1
  18. package/src/sap/ui/rta/command/ControlVariantSave.js +1 -1
  19. package/src/sap/ui/rta/command/ControlVariantSaveAs.js +1 -1
  20. package/src/sap/ui/rta/command/ControlVariantSetTitle.js +1 -1
  21. package/src/sap/ui/rta/command/ControlVariantSwitch.js +1 -1
  22. package/src/sap/ui/rta/command/CreateContainer.js +1 -1
  23. package/src/sap/ui/rta/command/CustomAdd.js +1 -1
  24. package/src/sap/ui/rta/command/FlexCommand.js +1 -1
  25. package/src/sap/ui/rta/command/LREPSerializer.js +1 -1
  26. package/src/sap/ui/rta/command/LocalReset.js +1 -1
  27. package/src/sap/ui/rta/command/Move.js +1 -1
  28. package/src/sap/ui/rta/command/Property.js +1 -1
  29. package/src/sap/ui/rta/command/Remove.js +1 -1
  30. package/src/sap/ui/rta/command/Rename.js +1 -1
  31. package/src/sap/ui/rta/command/Resize.js +1 -1
  32. package/src/sap/ui/rta/command/Reveal.js +1 -1
  33. package/src/sap/ui/rta/command/Settings.js +1 -1
  34. package/src/sap/ui/rta/command/Split.js +1 -1
  35. package/src/sap/ui/rta/command/Stack.js +1 -1
  36. package/src/sap/ui/rta/command/appDescriptor/AddLibrary.js +1 -1
  37. package/src/sap/ui/rta/command/compVariant/CompVariantContent.js +1 -1
  38. package/src/sap/ui/rta/command/compVariant/CompVariantSaveAs.js +1 -1
  39. package/src/sap/ui/rta/command/compVariant/CompVariantSwitch.js +1 -1
  40. package/src/sap/ui/rta/command/compVariant/CompVariantUpdate.js +1 -1
  41. package/src/sap/ui/rta/enablement/elementActionTest.js +1 -1
  42. package/src/sap/ui/rta/library.js +2 -2
  43. package/src/sap/ui/rta/messagebundle.properties +8 -0
  44. package/src/sap/ui/rta/plugin/AddXMLAtExtensionPoint.js +1 -1
  45. package/src/sap/ui/rta/plugin/BaseCreate.js +1 -1
  46. package/src/sap/ui/rta/plugin/Combine.js +1 -1
  47. package/src/sap/ui/rta/plugin/ControlVariant.js +1 -1
  48. package/src/sap/ui/rta/plugin/CreateContainer.js +1 -1
  49. package/src/sap/ui/rta/plugin/CutPaste.js +1 -1
  50. package/src/sap/ui/rta/plugin/DragDrop.js +1 -1
  51. package/src/sap/ui/rta/plugin/EasyAdd.js +1 -1
  52. package/src/sap/ui/rta/plugin/EasyRemove.js +1 -1
  53. package/src/sap/ui/rta/plugin/LocalReset.js +1 -1
  54. package/src/sap/ui/rta/plugin/Plugin.js +1 -1
  55. package/src/sap/ui/rta/plugin/RTAElementMover.js +1 -1
  56. package/src/sap/ui/rta/plugin/Remove.js +1 -1
  57. package/src/sap/ui/rta/plugin/Rename.js +1 -1
  58. package/src/sap/ui/rta/plugin/RenameHandler.js +1 -1
  59. package/src/sap/ui/rta/plugin/Resize.js +1 -1
  60. package/src/sap/ui/rta/plugin/Selection.js +1 -1
  61. package/src/sap/ui/rta/plugin/Settings.js +1 -1
  62. package/src/sap/ui/rta/plugin/Split.js +1 -1
  63. package/src/sap/ui/rta/plugin/Stretch.js +1 -1
  64. package/src/sap/ui/rta/plugin/additionalElements/ActionExtractor.js +1 -1
  65. package/src/sap/ui/rta/plugin/additionalElements/AddElementsDialog.js +1 -1
  66. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsPlugin.js +1 -1
  67. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsUtils.js +1 -1
  68. package/src/sap/ui/rta/plugin/additionalElements/CommandBuilder.js +1 -1
  69. package/src/sap/ui/rta/plugin/iframe/AddIFrame.js +3 -2
  70. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.fragment.xml +117 -7
  71. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.js +21 -4
  72. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialogController.js +48 -1
  73. package/src/sap/ui/rta/service/Action.js +1 -1
  74. package/src/sap/ui/rta/service/ControllerExtension.js +1 -1
  75. package/src/sap/ui/rta/service/Outline.js +1 -1
  76. package/src/sap/ui/rta/service/Property.js +1 -1
  77. package/src/sap/ui/rta/service/Selection.js +1 -1
  78. package/src/sap/ui/rta/service/SupportTools.js +1 -1
  79. package/src/sap/ui/rta/toolbar/Adaptation.js +1 -1
  80. package/src/sap/ui/rta/toolbar/Base.js +1 -1
  81. package/src/sap/ui/rta/toolbar/Fiori.js +1 -1
  82. package/src/sap/ui/rta/toolbar/FioriLike.js +1 -1
  83. package/src/sap/ui/rta/toolbar/OverflowToolbarButton.js +1 -1
  84. package/src/sap/ui/rta/toolbar/Personalization.js +1 -1
  85. package/src/sap/ui/rta/toolbar/Standalone.js +1 -1
  86. package/src/sap/ui/rta/toolbar/contextBased/SaveAsAdaptation.js +1 -1
  87. package/src/sap/ui/rta/toolbar/translation/Translation.js +1 -1
  88. package/src/sap/ui/rta/toolbar/versioning/Versioning.js +1 -1
  89. package/src/sap/ui/rta/util/PluginManager.js +1 -1
  90. package/src/sap/ui/rta/util/PopupManager.js +1 -1
  91. package/src/sap/ui/rta/util/ReloadManager.js +1 -1
  92. package/src/sap/ui/rta/util/ServiceEventBus.js +1 -1
  93. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicator.js +1 -1
  94. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry.js +1 -1
  95. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualization.js +1 -1
@@ -25,7 +25,7 @@ sap.ui.define([
25
25
  * @class The Settings allows trigger change of settings operations on the overlay
26
26
  * @extends sap.ui.rta.plugin.Plugin
27
27
  * @author SAP SE
28
- * @version 1.120.21
28
+ * @version 1.120.22
29
29
  * @constructor
30
30
  * @private
31
31
  * @since 1.44
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @class
24
24
  * @extends sap.ui.rta.plugin.Plugin
25
25
  * @author SAP SE
26
- * @version 1.120.21
26
+ * @version 1.120.22
27
27
  * @constructor
28
28
  * @private
29
29
  * @since 1.46
@@ -31,7 +31,7 @@ sap.ui.define([
31
31
  * @extends sap.ui.rta.plugin.Plugin
32
32
  *
33
33
  * @author SAP SE
34
- * @version 1.120.21
34
+ * @version 1.120.22
35
35
  *
36
36
  * @constructor
37
37
  * @private
@@ -34,7 +34,7 @@ sap.ui.define([
34
34
  * handled by the AdditionalElements Plugin (Reveal, Add Via Delegate, Add Custom)
35
35
  *
36
36
  * @author SAP SE
37
- * @version 1.120.21
37
+ * @version 1.120.22
38
38
  * @private
39
39
  * @since 1.94
40
40
  */
@@ -34,7 +34,7 @@ sap.ui.define([
34
34
  * @class Context - Dialog for available Fields in Runtime Authoring
35
35
  * @extends sap.ui.base.ManagedObject
36
36
  * @author SAP SE
37
- * @version 1.120.21
37
+ * @version 1.120.22
38
38
  * @constructor
39
39
  * @private
40
40
  * @since 1.44
@@ -77,7 +77,7 @@ sap.ui.define([
77
77
  * @class The plugin allows to add additional elements that exist either hidden in the UI or in the OData service
78
78
  * @extends sap.ui.rta.plugin.Plugin
79
79
  * @author SAP SE
80
- * @version 1.120.21
80
+ * @version 1.120.22
81
81
  * @constructor
82
82
  * @private
83
83
  * @since 1.44
@@ -17,7 +17,7 @@ sap.ui.define([
17
17
  * Helper object containing methods for the AdditionalElements plugin
18
18
  *
19
19
  * @author SAP SE
20
- * @version 1.120.21
20
+ * @version 1.120.22
21
21
  * @private
22
22
  * @since 1.94
23
23
  */
@@ -25,7 +25,7 @@ sap.ui.define([
25
25
  * Helper object to build the RTA commands resulting from the AdditionalElements Plugin
26
26
  *
27
27
  * @author SAP SE
28
- * @version 1.120.21
28
+ * @version 1.120.22
29
29
  * @private
30
30
  * @since 1.94
31
31
  */
@@ -52,7 +52,8 @@ sap.ui.define([
52
52
  width: sWidth,
53
53
  height: sHeight,
54
54
  title: mSettings.title,
55
- useLegacyNavigation: mSettings.useLegacyNavigation
55
+ useLegacyNavigation: mSettings.useLegacyNavigation,
56
+ advancedSettings: mSettings.advancedSettings
56
57
  }, oDesignTimeMetadata, sVariantManagementKey);
57
58
  }
58
59
 
@@ -119,7 +120,7 @@ sap.ui.define([
119
120
  * @class The AddIFrame allows trigger AddIFrame operations on the overlay.
120
121
  * @extends sap.ui.rta.plugin.BaseCreate
121
122
  * @author SAP SE
122
- * @version 1.120.21
123
+ * @version 1.120.22
123
124
  * @constructor
124
125
  * @private
125
126
  * @since 1.75
@@ -17,9 +17,9 @@
17
17
  contentWidth="50rem"
18
18
  contentHeight="44rem"
19
19
  core:require="{ FloatType: 'sap/ui/model/type/Float' }"
20
+ afterOpen="configureMultiInput"
20
21
  >
21
22
  <content>
22
-
23
23
  <layout:VerticalLayout
24
24
  id="sapUiRtaAddIFrameDialog_VL"
25
25
  width="100%"
@@ -199,7 +199,7 @@
199
199
  <ToolbarSpacer />
200
200
  <Button
201
201
  id="sapUiRtaAddIFrameDialog_PreviewButton"
202
- enabled="{=${/previewUrl/value} !== ${/frameUrl/value} || ${/previewUseLegacyNavigation/value} !== ${/useLegacyNavigation/value}}"
202
+ enabled="{=${/previewUrl/value} !== ${/frameUrl/value} || ${/previewUseLegacyNavigation/value} !== ${/useLegacyNavigation/value} || ${/settingsUpdate/value}}"
203
203
  text="{=${/previewUrl/value} === '' ? ${/text/showPreviewButton} : ${/text/updatePreviewButton} }"
204
204
  press="onShowPreview"
205
205
  class="sapUiTinyMarginTop sapUiRtaAddIFrameDialogPreviewButton" />
@@ -209,7 +209,7 @@
209
209
  <Link
210
210
  id="sapUiRtaAddIFrameDialog_PreviewLink"
211
211
  class="sapUiRtaAddIFrameDialogPreviewLink"
212
- href="{/previewUrl/value}" text="{/previewUrl/value}" wrapping="true" visible="{= !!${/previewUrl/value} }" />
212
+ href="{/previewUrl/value}" text="{/previewUrl/value}" wrapping="true" visible="{= !!${/previewUrl/value} }" target="_blank" />
213
213
  </content>
214
214
  </Panel>
215
215
  </layout:Grid>
@@ -236,7 +236,8 @@
236
236
  title="{/text/previewFrameLabel}"
237
237
  useLegacyNavigation="{/previewUseLegacyNavigation/value/}"
238
238
  class="sapUiRtaAddIFrameDialogPreviewFrame"
239
- visible="{= !!${/previewUrl/value} }"/>
239
+ visible="{= !!${/previewUrl/value} }"
240
+ advancedSettings="{/advancedSettings/value}" />
240
241
  </items>
241
242
  </VBox>
242
243
  </layout:Grid>
@@ -261,7 +262,7 @@
261
262
  <content>
262
263
  <HBox
263
264
  alignItems="Center"
264
- class="sapUiRtaAddIFrameDialogLegacyNavigationContainer">
265
+ class="sapUiRtaAddIFrameDialogLegacyNavigationContainer sapUiLargeMarginBottom">
265
266
  <Switch
266
267
  id="sapUiRtaAddIFrameDialog_UseLegacyNavigationToggle"
267
268
  customTextOn=" "
@@ -274,7 +275,117 @@
274
275
  type="Transparent"
275
276
  press="onLegacyNavigationInfoPress"
276
277
  ariaHasPopup="Dialog" />
277
- </HBox>
278
+ </HBox>
279
+ <MessageStrip
280
+ id="sapUiRtaAddIFrameDialog_SecurityWarningMessage"
281
+ text="{/text/additionalParametersSecurityWarningText}"
282
+ type="Warning"
283
+ showIcon="true"
284
+ showCloseButton="true"
285
+ class="sapUiSmallMarginBottom">
286
+ <link>
287
+ <Link text="{/text/additionalParametersWarningMoreInfoText}"
288
+ target="_blank"
289
+ href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#sandbox"/>
290
+ </link>
291
+ </MessageStrip>
292
+ <form:Form editable="true">
293
+ <form:layout>
294
+ <form:ResponsiveGridLayout
295
+ id="sapUiRtaAddIFrameDialog_SanboxPropertiesForm"
296
+ adjustLabelSpan="false" singleContainerFullSize="false"
297
+ labelSpanXL="6" labelSpanL="6" labelSpanM="6" labelSpanS="12"
298
+ columnsXL="2" columnsL="2" columnsM="2"/>
299
+ </form:layout>
300
+ <form:FormContainer>
301
+ <form:FormElement label="allow-forms">
302
+ <Switch
303
+ change="onSwitchChange"
304
+ id="sapUiRtaAddIFrameDialog_allowFormsSwitch"
305
+ customTextOn=" "
306
+ customTextOff=" "
307
+ state="{/advancedSettings/value/allowForms}" />
308
+ </form:FormElement>
309
+ <form:FormElement label="allow-scripts">
310
+ <Switch
311
+ change="onSwitchChange"
312
+ id="sapUiRtaAddIFrameDialog_allowScriptsSwitch"
313
+ customTextOn=" "
314
+ customTextOff=" "
315
+ state="{/advancedSettings/value/allowScripts}" />
316
+ </form:FormElement>
317
+ <form:FormElement label="allow-same-origin">
318
+ <Switch
319
+ change="onSwitchChange"
320
+ id="sapUiRtaAddIFrameDialog_allowSameOriginSwitch"
321
+ customTextOn=" "
322
+ customTextOff=" "
323
+ state="{/advancedSettings/value/allowSameOrigin}" />
324
+ </form:FormElement>
325
+ <form:FormElement label="allow-popups">
326
+ <Switch
327
+ change="onSwitchChange"
328
+ id="sapUiRtaAddIFrameDialog_allowPopupsSwitch"
329
+ customTextOn=" "
330
+ customTextOff=" "
331
+ state="{/advancedSettings/value/allowPopups}" />
332
+ </form:FormElement>
333
+ <form:FormElement label="allow-modals">
334
+ <Switch
335
+ change="onSwitchChange"
336
+ id="sapUiRtaAddIFrameDialog_allowModalsSwitch"
337
+ customTextOn=" "
338
+ customTextOff=" "
339
+ state="{/advancedSettings/value/allowModals}" />
340
+ </form:FormElement>
341
+ </form:FormContainer>
342
+ <form:FormContainer>
343
+ <form:FormElement label="allow-top-navigation">
344
+ <Switch
345
+ change="onSwitchChange"
346
+ id="sapUiRtaAddIFrameDialog_allowTopNavigationSwitch"
347
+ customTextOn=" "
348
+ customTextOff=" "
349
+ state="{/advancedSettings/value/allowTopNavigation}" />
350
+ </form:FormElement>
351
+ <form:FormElement label="allow-downloads">
352
+ <Switch
353
+ change="onSwitchChange"
354
+ id="sapUiRtaAddIFrameDialog_allowDownloadsSwitch"
355
+ customTextOn=" "
356
+ customTextOff=" "
357
+ state="{/advancedSettings/value/allowDownloads}" />
358
+ </form:FormElement>
359
+ <form:FormElement label="allow-downloads-without-user-activation">
360
+ <Switch
361
+ change="onSwitchChange"
362
+ id="sapUiRtaAddIFrameDialog_allowDownloadsWithoutUserActivationSwitch"
363
+ customTextOn=" "
364
+ customTextOff=" "
365
+ state="{/advancedSettings/value/allowDownloadsWithoutUserActivation}" />
366
+ </form:FormElement>
367
+ <form:FormElement>
368
+ <Label
369
+ id="sapUiRtaAddIFrameDialog_AddAdditionalParametersLabel"
370
+ class="sapUiSmallMarginTop"
371
+ text="{/text/additionalSandboxParametersLabel}"
372
+ labelFor="sapUiRtaAddIFrameDialog_AddAdditionalParametersInput" />
373
+ </form:FormElement>
374
+ <form:FormElement>
375
+ <MultiInput
376
+ id="sapUiRtaAddIFrameDialog_AddAdditionalParametersInput"
377
+ placeholder="{/text/additionalSandboxParametersPlaceholder}"
378
+ showValueHelp="false"
379
+ tokenUpdate="onTokenUpdate"
380
+ tokens="{/advancedSettings/value/additionalSandboxParameters}"
381
+ ariaLabelledBy="sapUiRtaAddIFrameDialog_AddAdditionalParametersLabel">
382
+ <tokens>
383
+ <Token text="{}" key="{}"/>
384
+ </tokens>
385
+ </MultiInput>
386
+ </form:FormElement>
387
+ </form:FormContainer>
388
+ </form:Form>
278
389
  </content>
279
390
  </Panel>
280
391
  </layout:Grid>
@@ -285,7 +396,6 @@
285
396
  <core:InvisibleText id="sapUiRtaAddIFrameDialog_HeightUnitLabel" text="{/text/heightUnitLabel}"/>
286
397
  <core:InvisibleText id="sapUiRtaAddIFrameDialog_ParameterSearchLabel" text="{/text/parameterSearchLabel}"/>
287
398
  </content>
288
-
289
399
  <beginButton>
290
400
  <Button
291
401
  id="sapUiRtaAddIFrameDialogSaveButton"
@@ -64,10 +64,14 @@ sap.ui.define([
64
64
  selectAdditionalTextRem: _oTextResources.getText("IFRAME_ADDIFRAME_DIALOG_SELECT_ADDITIONAL_TEXT_REM"),
65
65
  advancedSettingsTitle: _oTextResources.getText("IFRAME_ADDIFRAME_ADVANCED_SETTINGS"),
66
66
  useLegacyNavigationLabel: _oTextResources.getText("IFRAME_ADDIFRAME_USE_LEGACY_NAVIGATION"),
67
- useLegacyNavigationInfo: _oTextResources.getText("IFRAME_ADDIFRAME_USE_LEGACY_NAVIGATION_INFO")
67
+ useLegacyNavigationInfo: _oTextResources.getText("IFRAME_ADDIFRAME_USE_LEGACY_NAVIGATION_INFO"),
68
+ additionalParametersSecurityWarningText: _oTextResources.getText("IFRAME_ADDIFRAME_ADDITIONAL_PARAMETERS_SECURITY_WARNING_TEXT"),
69
+ additionalParametersWarningMoreInfoText: _oTextResources.getText("IFRAME_ADDIFRAME_ADDITIONAL_PARAMETERS_WARNING_MORE_INFO_TEXT"),
70
+ additionalSandboxParametersLabel: _oTextResources.getText("IFRAME_ADDIFRAME_ADD_ADDITIONAL_SANDBOX_PARAMETERS_LABEL"),
71
+ additionalSandboxParametersPlaceholder: _oTextResources.getText("IFRAME_ADDIFRAME_ADD_ADDITIONAL_SANDBOX_PARAMETERS_PLACEHOLDER")
68
72
  };
69
73
 
70
- function createJSONModel(bSetUpdateTitle, bAsContainer, sFrameWidthValue, sFrameHeightValue, bUseLegacyNavigation) {
74
+ function createJSONModel(bSetUpdateTitle, bAsContainer, sFrameWidthValue, sFrameHeightValue, bUseLegacyNavigation, oAdvancedSettings) {
71
75
  _mText.dialogTitle = bSetUpdateTitle ? _mText.dialogUpdateTitle : _mText.dialogCreateTitle;
72
76
 
73
77
  var sSelectAdditionalTextPercent = bAsContainer
@@ -134,6 +138,18 @@ sap.ui.define([
134
138
  },
135
139
  previewUseLegacyNavigation: {
136
140
  value: !!bUseLegacyNavigation
141
+ },
142
+ advancedSettings: {
143
+ value: {
144
+ allowForms: true,
145
+ allowScripts: true,
146
+ allowSameOrigin: true,
147
+ additionalSandboxParameters: [],
148
+ ...oAdvancedSettings
149
+ }
150
+ },
151
+ settingsUpdate: {
152
+ value: false
137
153
  }
138
154
  });
139
155
  }
@@ -144,7 +160,7 @@ sap.ui.define([
144
160
  * @class Context - Dialog for IFrame settings in Runtime Authoring
145
161
  * @extends sap.ui.base.ManagedObject
146
162
  * @author SAP SE
147
- * @version 1.120.21
163
+ * @version 1.120.22
148
164
  * @constructor
149
165
  * @private
150
166
  * @since 1.78
@@ -185,7 +201,8 @@ sap.ui.define([
185
201
  !!mSettings?.asContainer,
186
202
  mSettings?.frameWidth,
187
203
  mSettings?.frameHeight,
188
- mSettings?.useLegacyNavigation
204
+ mSettings?.useLegacyNavigation,
205
+ mSettings?.advancedSettings
189
206
  );
190
207
  this._oController = new AddIFrameDialogController(this._oJSONModel, mSettings);
191
208
  Fragment.load({
@@ -7,6 +7,7 @@ sap.ui.define([
7
7
  "sap/base/Log",
8
8
  "sap/m/Popover",
9
9
  "sap/m/Text",
10
+ "sap/m/Token",
10
11
  "sap/ui/core/mvc/Controller",
11
12
  "sap/ui/core/Element",
12
13
  "sap/ui/core/library",
@@ -20,6 +21,7 @@ sap.ui.define([
20
21
  Log,
21
22
  Popover,
22
23
  Text,
24
+ Token,
23
25
  Controller,
24
26
  Element,
25
27
  coreLibrary,
@@ -37,12 +39,17 @@ sap.ui.define([
37
39
 
38
40
  var _aTextInputFields = ["frameUrl", "title"];
39
41
  var _aNumericInputFields = ["frameWidth", "frameHeight"];
40
- var _aOtherInputFields = ["frameWidthUnit", "frameHeightUnit", "useLegacyNavigation"];
42
+ var _aOtherInputFields = ["frameWidthUnit", "frameHeightUnit", "useLegacyNavigation", "advancedSettings"];
41
43
 
42
44
  function isValidUrl(sUrl) {
43
45
  return IFrame.isValidUrl(encodeURI(sUrl));
44
46
  }
45
47
 
48
+ function multiInputValidator(oValue) {
49
+ const sText = oValue.text;
50
+ return new Token({key: sText, text: sText});
51
+ }
52
+
46
53
  return Controller.extend("sap.ui.rta.plugin.iframe.AddIFrameDialogController", {
47
54
  // eslint-disable-next-line object-shorthand
48
55
  constructor: function(oJSONModel, mSettings) {
@@ -51,6 +58,39 @@ sap.ui.define([
51
58
  this._mParameterHashMap = this._buildParameterHashMap(mSettings);
52
59
  },
53
60
 
61
+ configureMultiInput() {
62
+ // This syntax is the suggested way by the UI5 documentation to trigger a submit on the input field on focus loss
63
+ const oMultiInput = Element.getElementById("sapUiRtaAddIFrameDialog_AddAdditionalParametersInput");
64
+ oMultiInput.addValidator(multiInputValidator);
65
+ },
66
+
67
+ onSwitchChange() {
68
+ this._oJSONModel.setProperty("/settingsUpdate/value", true);
69
+ },
70
+
71
+ /**
72
+ * Event handler for token update
73
+ * @param {sap.ui.base.Event} oEvent - Event
74
+ */
75
+ onTokenUpdate(oEvent) {
76
+ let aSandboxParameters = this._oJSONModel.getProperty("/advancedSettings/value/additionalSandboxParameters");
77
+
78
+ if (oEvent.getParameter("type") === "added") {
79
+ oEvent.getParameter("addedTokens").forEach(function(oToken) {
80
+ aSandboxParameters = [...aSandboxParameters, oToken.getText()];
81
+ });
82
+ } else if (oEvent.getParameter("type") === "removed") {
83
+ oEvent.getParameter("removedTokens").forEach(function(oToken) {
84
+ aSandboxParameters = aSandboxParameters.filter(function(sText) {
85
+ return sText !== oToken.getText();
86
+ });
87
+ });
88
+ }
89
+
90
+ this._oJSONModel.setProperty("/advancedSettings/value/additionalSandboxParameters", aSandboxParameters);
91
+ this._oJSONModel.setProperty("/settingsUpdate/value", true);
92
+ },
93
+
54
94
  /**
55
95
  * Event handler for validation success
56
96
  * @param {sap.ui.base.Event} oEvent - Event
@@ -109,6 +149,9 @@ sap.ui.define([
109
149
  this._oJSONModel.getProperty("/useLegacyNavigation/value")
110
150
  );
111
151
  oIFrame.setUrl(sURL);
152
+ this._oJSONModel.setProperty("/settingsUpdate/value", false);
153
+
154
+ oIFrame.applySettings({ url: sURL, advancedSettings: {...this._oJSONModel.getProperty("/advancedSettings/value")} });
112
155
  } catch (oError) {
113
156
  Log.error("Error previewing the URL: ", oError);
114
157
  }
@@ -317,6 +360,10 @@ sap.ui.define([
317
360
  Object.keys(mSettings).forEach(function(sFieldName) {
318
361
  if (sFieldName === "frameWidth" || sFieldName === "frameHeight") {
319
362
  this._importIFrameSize(sFieldName, mSettings[sFieldName]);
363
+ } else if (sFieldName === "advancedSettings" && !mSettings[sFieldName]) {
364
+ // legacy iframes do not have advancedSettings properties so we need to skip the setProperty
365
+ // on the json model to not overwrite the default values with undefined
366
+ return;
320
367
  } else {
321
368
  this._oJSONModel.setProperty(`/${sFieldName}/value`, mSettings[sFieldName]);
322
369
  }
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @name sap.ui.rta.service.Action
25
25
  * @author SAP SE
26
26
  * @since 1.58
27
- * @version 1.120.21
27
+ * @version 1.120.22
28
28
  * @private
29
29
  * @ui5-restricted
30
30
  *
@@ -32,7 +32,7 @@ sap.ui.define([
32
32
  * @name sap.ui.rta.service.ControllerExtension
33
33
  * @author SAP SE
34
34
  * @since 1.58
35
- * @version 1.120.21
35
+ * @version 1.120.22
36
36
  * @private
37
37
  * @ui5-restricted
38
38
  */
@@ -43,7 +43,7 @@ sap.ui.define([
43
43
  * @name sap.ui.rta.service.Outline
44
44
  * @author SAP SE
45
45
  * @since 1.56
46
- * @version 1.120.21
46
+ * @version 1.120.22
47
47
  * @private
48
48
  * @ui5-restricted
49
49
  */
@@ -27,7 +27,7 @@ sap.ui.define([
27
27
  * @name sap.ui.rta.service.Property
28
28
  * @author SAP SE
29
29
  * @since 1.58
30
- * @version 1.120.21
30
+ * @version 1.120.22
31
31
  * @private
32
32
  * @ui5-restricted
33
33
  */
@@ -14,7 +14,7 @@ sap.ui.define(function() {
14
14
  * @name sap.ui.rta.service.Selection
15
15
  * @author SAP SE
16
16
  * @since 1.58
17
- * @version 1.120.21
17
+ * @version 1.120.22
18
18
  * @private
19
19
  * @ui5-restricted
20
20
  */
@@ -28,7 +28,7 @@ sap.ui.define([
28
28
  * @name sap.ui.rta.service.SupportTools
29
29
  * @author SAP SE
30
30
  * @since 1.106
31
- * @version 1.120.21
31
+ * @version 1.120.22
32
32
  * @private
33
33
  * @ui5-restricted
34
34
  */
@@ -57,7 +57,7 @@ sap.ui.define([
57
57
  * @extends sap.ui.rta.toolbar.Base
58
58
  *
59
59
  * @author SAP SE
60
- * @version 1.120.21
60
+ * @version 1.120.22
61
61
  *
62
62
  * @constructor
63
63
  * @private
@@ -33,7 +33,7 @@ sap.ui.define([
33
33
  * @extends sap.m.HBox
34
34
  *
35
35
  * @author SAP SE
36
- * @version 1.120.21
36
+ * @version 1.120.22
37
37
  *
38
38
  * @constructor
39
39
  * @private
@@ -32,7 +32,7 @@ function(
32
32
  * @extends sap.ui.rta.toolbar.Adaptation
33
33
  *
34
34
  * @author SAP SE
35
- * @version 1.120.21
35
+ * @version 1.120.22
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.120.21
23
+ * @version 1.120.22
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.120.21
26
+ * @version 1.120.22
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.120.21
25
+ * @version 1.120.22
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.120.21
23
+ * @version 1.120.22
24
24
  *
25
25
  * @constructor
26
26
  * @private
@@ -45,7 +45,7 @@ sap.ui.define([
45
45
  * @class
46
46
  *
47
47
  * @author SAP SE
48
- * @version 1.120.21
48
+ * @version 1.120.22
49
49
  *
50
50
  * @constructor
51
51
  * @private
@@ -53,7 +53,7 @@ sap.ui.define([
53
53
  * @class
54
54
  *
55
55
  * @author SAP SE
56
- * @version 1.120.21
56
+ * @version 1.120.22
57
57
  *
58
58
  * @constructor
59
59
  * @private
@@ -36,7 +36,7 @@ sap.ui.define([
36
36
  * @class
37
37
  *
38
38
  * @author SAP SE
39
- * @version 1.120.21
39
+ * @version 1.120.22
40
40
  *
41
41
  * @constructor
42
42
  * @private
@@ -68,7 +68,7 @@ sap.ui.define([
68
68
  * Constructor for a new sap.ui.rta.util.PluginManager
69
69
  * @extends sap.ui.base.ManagedObject
70
70
  * @author SAP SE
71
- * @version 1.120.21
71
+ * @version 1.120.22
72
72
  * @constructor
73
73
  * @private
74
74
  * @since 1.86
@@ -42,7 +42,7 @@ sap.ui.define([
42
42
  * Constructor for a new sap.ui.rta.util.PopupManager
43
43
  * @extends sap.ui.base.ManagedObject
44
44
  * @author SAP SE
45
- * @version 1.120.21
45
+ * @version 1.120.22
46
46
  * @constructor
47
47
  * @private
48
48
  * @since 1.48
@@ -30,7 +30,7 @@ sap.ui.define([
30
30
  * @namespace sap.ui.rta.util.ReloadManager
31
31
  * @alias sap.ui.rta.util.ReloadManager
32
32
  * @since 1.104
33
- * @version 1.120.21
33
+ * @version 1.120.22
34
34
  * @private
35
35
  * @ui5-restricted
36
36
  */
@@ -19,7 +19,7 @@ function(
19
19
  *
20
20
  * @extends sap.ui.core.EventBus
21
21
  * @author SAP SE
22
- * @version 1.120.21
22
+ * @version 1.120.22
23
23
  * @private
24
24
  * @since 1.56.0
25
25
  * @alias sap.ui.rta.util.ServiceEventBus
@@ -44,7 +44,7 @@ sap.ui.define([
44
44
  * @alias sap.ui.rta.util.changeVisualization.ChangeIndicator
45
45
  * @author SAP SE
46
46
  * @since 1.84.0
47
- * @version 1.120.21
47
+ * @version 1.120.22
48
48
  * @private
49
49
  */
50
50
  var ChangeIndicator = Control.extend("sap.ui.rta.util.changeVisualization.ChangeIndicator", {
@@ -39,7 +39,7 @@ sap.ui.define([
39
39
  * @alias sap.ui.rta.util.changeVisualization.ChangeIndicatorRegistry
40
40
  * @author SAP SE
41
41
  * @since 1.86.0
42
- * @version 1.120.21
42
+ * @version 1.120.22
43
43
  * @private
44
44
  */
45
45
  var ChangeIndicatorRegistry = ManagedObject.extend("sap.ui.rta.util.changeVisualization.ChangeIndicatorRegistry", {
@@ -86,7 +86,7 @@ sap.ui.define([
86
86
  * @alias sap.ui.rta.util.changeVisualization.ChangeVisualization
87
87
  * @author SAP SE
88
88
  * @since 1.84.0
89
- * @version 1.120.21
89
+ * @version 1.120.22
90
90
  * @private
91
91
  */
92
92
  var ChangeVisualization = Control.extend("sap.ui.rta.util.changeVisualization.ChangeVisualization", {