@sapui5/sap.suite.ui.commons 1.138.0 → 1.140.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 (106) hide show
  1. package/package.json +1 -1
  2. package/src/sap/suite/ui/commons/.library +1 -1
  3. package/src/sap/suite/ui/commons/AriaProperties.js +1 -1
  4. package/src/sap/suite/ui/commons/CalculationBuilder.js +1 -1
  5. package/src/sap/suite/ui/commons/CalculationBuilderExpression.js +1 -1
  6. package/src/sap/suite/ui/commons/CalculationBuilderFunction.js +1 -1
  7. package/src/sap/suite/ui/commons/CalculationBuilderGroup.js +1 -1
  8. package/src/sap/suite/ui/commons/CalculationBuilderItem.js +1 -1
  9. package/src/sap/suite/ui/commons/CalculationBuilderValidationResult.js +1 -1
  10. package/src/sap/suite/ui/commons/CalculationBuilderVariable.js +1 -1
  11. package/src/sap/suite/ui/commons/ChartContainer.js +0 -1
  12. package/src/sap/suite/ui/commons/CloudFilePicker.js +26 -26
  13. package/src/sap/suite/ui/commons/MicroProcessFlow.js +1 -1
  14. package/src/sap/suite/ui/commons/MicroProcessFlowItem.js +1 -1
  15. package/src/sap/suite/ui/commons/TimelineItemRenderer.js +46 -3
  16. package/src/sap/suite/ui/commons/TimelineRenderManager.js +1 -1
  17. package/src/sap/suite/ui/commons/collaboration/CollaborationHelper.js +104 -7
  18. package/src/sap/suite/ui/commons/collaboration/ContactPopover.fragment.xml +17 -17
  19. package/src/sap/suite/ui/commons/collaboration/TeamsHelperService.js +55 -58
  20. package/src/sap/suite/ui/commons/collaboration/flpplugins/msplugin/Component-preload.js +2 -2
  21. package/src/sap/suite/ui/commons/collaboration/flpplugins/msplugin/Component.js +4 -1
  22. package/src/sap/suite/ui/commons/flexibility/changeHandler/PropertyChangeMapper.js +1 -1
  23. package/src/sap/suite/ui/commons/imageeditor/CropCustomShapeHistoryItem.js +1 -1
  24. package/src/sap/suite/ui/commons/imageeditor/CropEllipseHistoryItem.js +1 -1
  25. package/src/sap/suite/ui/commons/imageeditor/CropRectangleHistoryItem.js +1 -1
  26. package/src/sap/suite/ui/commons/imageeditor/CustomSizeItem.js +1 -1
  27. package/src/sap/suite/ui/commons/imageeditor/FilterHistoryItem.js +1 -1
  28. package/src/sap/suite/ui/commons/imageeditor/FlipHistoryItem.js +1 -1
  29. package/src/sap/suite/ui/commons/imageeditor/HistoryItem.js +1 -1
  30. package/src/sap/suite/ui/commons/imageeditor/ImageEditor.js +1 -1
  31. package/src/sap/suite/ui/commons/imageeditor/ImageEditorContainer.js +1 -1
  32. package/src/sap/suite/ui/commons/imageeditor/ImageEditorResponsiveContainer.js +1 -1
  33. package/src/sap/suite/ui/commons/imageeditor/ResizeHistoryItem.js +1 -1
  34. package/src/sap/suite/ui/commons/imageeditor/RotateHistoryItem.js +1 -1
  35. package/src/sap/suite/ui/commons/library.js +1 -1
  36. package/src/sap/suite/ui/commons/messagebundle.properties +13 -2
  37. package/src/sap/suite/ui/commons/messagebundle_ar.properties +1 -1
  38. package/src/sap/suite/ui/commons/messagebundle_bg.properties +1 -1
  39. package/src/sap/suite/ui/commons/messagebundle_ca.properties +3 -3
  40. package/src/sap/suite/ui/commons/messagebundle_cnr.properties +1 -1
  41. package/src/sap/suite/ui/commons/messagebundle_cs.properties +1 -1
  42. package/src/sap/suite/ui/commons/messagebundle_cy.properties +1 -1
  43. package/src/sap/suite/ui/commons/messagebundle_da.properties +1 -1
  44. package/src/sap/suite/ui/commons/messagebundle_de.properties +1 -1
  45. package/src/sap/suite/ui/commons/messagebundle_el.properties +1 -1
  46. package/src/sap/suite/ui/commons/messagebundle_en.properties +1 -1
  47. package/src/sap/suite/ui/commons/messagebundle_en_GB.properties +1 -1
  48. package/src/sap/suite/ui/commons/messagebundle_en_US_saprigi.properties +1 -1
  49. package/src/sap/suite/ui/commons/messagebundle_es.properties +4 -4
  50. package/src/sap/suite/ui/commons/messagebundle_es_MX.properties +2 -2
  51. package/src/sap/suite/ui/commons/messagebundle_et.properties +1 -1
  52. package/src/sap/suite/ui/commons/messagebundle_fi.properties +1 -1
  53. package/src/sap/suite/ui/commons/messagebundle_fr.properties +1 -1
  54. package/src/sap/suite/ui/commons/messagebundle_fr_CA.properties +1 -1
  55. package/src/sap/suite/ui/commons/messagebundle_hi.properties +1 -1
  56. package/src/sap/suite/ui/commons/messagebundle_hr.properties +1 -1
  57. package/src/sap/suite/ui/commons/messagebundle_hu.properties +1 -1
  58. package/src/sap/suite/ui/commons/messagebundle_id.properties +1 -1
  59. package/src/sap/suite/ui/commons/messagebundle_it.properties +1 -1
  60. package/src/sap/suite/ui/commons/messagebundle_iw.properties +1 -1
  61. package/src/sap/suite/ui/commons/messagebundle_ja.properties +2 -2
  62. package/src/sap/suite/ui/commons/messagebundle_kk.properties +1 -1
  63. package/src/sap/suite/ui/commons/messagebundle_ko.properties +1 -1
  64. package/src/sap/suite/ui/commons/messagebundle_lt.properties +1 -1
  65. package/src/sap/suite/ui/commons/messagebundle_lv.properties +1 -1
  66. package/src/sap/suite/ui/commons/messagebundle_mk.properties +3 -3
  67. package/src/sap/suite/ui/commons/messagebundle_ms.properties +1 -1
  68. package/src/sap/suite/ui/commons/messagebundle_nl.properties +1 -1
  69. package/src/sap/suite/ui/commons/messagebundle_no.properties +1 -1
  70. package/src/sap/suite/ui/commons/messagebundle_pl.properties +1 -1
  71. package/src/sap/suite/ui/commons/messagebundle_pt.properties +1 -1
  72. package/src/sap/suite/ui/commons/messagebundle_pt_PT.properties +1 -1
  73. package/src/sap/suite/ui/commons/messagebundle_ro.properties +1 -1
  74. package/src/sap/suite/ui/commons/messagebundle_ru.properties +1 -1
  75. package/src/sap/suite/ui/commons/messagebundle_sh.properties +1 -1
  76. package/src/sap/suite/ui/commons/messagebundle_sk.properties +3 -3
  77. package/src/sap/suite/ui/commons/messagebundle_sl.properties +1 -1
  78. package/src/sap/suite/ui/commons/messagebundle_sr.properties +1 -1
  79. package/src/sap/suite/ui/commons/messagebundle_sv.properties +1 -1
  80. package/src/sap/suite/ui/commons/messagebundle_th.properties +1 -1
  81. package/src/sap/suite/ui/commons/messagebundle_tr.properties +1 -1
  82. package/src/sap/suite/ui/commons/messagebundle_uk.properties +1 -1
  83. package/src/sap/suite/ui/commons/messagebundle_vi.properties +1 -1
  84. package/src/sap/suite/ui/commons/messagebundle_zh_CN.properties +1 -1
  85. package/src/sap/suite/ui/commons/messagebundle_zh_TW.properties +1 -1
  86. package/src/sap/suite/ui/commons/networkgraph/Node.js +3 -0
  87. package/src/sap/suite/ui/commons/statusindicator/Circle.js +1 -1
  88. package/src/sap/suite/ui/commons/statusindicator/CustomShape.js +1 -1
  89. package/src/sap/suite/ui/commons/statusindicator/DiscreteThreshold.js +1 -1
  90. package/src/sap/suite/ui/commons/statusindicator/FillingOption.js +1 -1
  91. package/src/sap/suite/ui/commons/statusindicator/LibraryShape.js +1 -1
  92. package/src/sap/suite/ui/commons/statusindicator/Path.js +1 -1
  93. package/src/sap/suite/ui/commons/statusindicator/PropertyThreshold.js +1 -1
  94. package/src/sap/suite/ui/commons/statusindicator/Rectangle.js +1 -1
  95. package/src/sap/suite/ui/commons/statusindicator/Shape.js +1 -1
  96. package/src/sap/suite/ui/commons/statusindicator/ShapeGroup.js +1 -1
  97. package/src/sap/suite/ui/commons/statusindicator/SimpleShape.js +1 -1
  98. package/src/sap/suite/ui/commons/statusindicator/StatusIndicator.js +1 -1
  99. package/src/sap/suite/ui/commons/statusindicator/StatusIndicatorRenderer.js +6 -2
  100. package/src/sap/suite/ui/commons/taccount/TAccount.js +57 -6
  101. package/src/sap/suite/ui/commons/taccount/TAccountGroup.js +1 -1
  102. package/src/sap/suite/ui/commons/taccount/TAccountItem.js +4 -3
  103. package/src/sap/suite/ui/commons/taccount/TAccountItemProperty.js +1 -1
  104. package/src/sap/suite/ui/commons/taccount/TAccountPanel.js +1 -1
  105. package/src/sap/suite/ui/commons/themes/base/TAccount.less +28 -5
  106. package/src/sap/suite/ui/commons/windowmessages/CollaborationMessageBroker.js +5 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sapui5/sap.suite.ui.commons",
3
- "version": "1.138.0",
3
+ "version": "1.140.0",
4
4
  "description": "SAPUI5 Library sap.suite.ui.commons",
5
5
  "homepage": "https://sap.github.io/ui5-tooling/pages/SAPUI5/",
6
6
  "author": "SAP SE (https://www.sap.com)",
@@ -7,7 +7,7 @@
7
7
  SAP UI development toolkit for HTML5 (SAPUI5)
8
8
  (c) Copyright 2009-2015 SAP SE. All rights reserved
9
9
  </copyright>
10
- <version>1.138.0</version>
10
+ <version>1.140.0</version>
11
11
 
12
12
  <documentation>SAP UI library: sap.suite.ui.commons</documentation>
13
13
 
@@ -19,7 +19,7 @@ sap.ui.define([
19
19
  * @extends sap.ui.core.Element
20
20
  *
21
21
  * @author SAP SE
22
- * @version 1.138.0
22
+ * @version 1.140.0
23
23
  * @since 1.65.0
24
24
  *
25
25
  * @constructor
@@ -134,7 +134,7 @@ sap.ui.define([
134
134
  * @extends sap.ui.core.Control
135
135
  *
136
136
  * @author SAP SE
137
- * @version 1.138.0
137
+ * @version 1.140.0
138
138
  * @since 1.56.0
139
139
  *
140
140
  * @constructor
@@ -148,7 +148,7 @@ sap.ui.define([
148
148
  * @extends sap.ui.core.Control
149
149
  *
150
150
  * @author SAP SE
151
- * @version 1.138.0
151
+ * @version 1.140.0
152
152
  * @since 1.56.0
153
153
  *
154
154
  * @constructor
@@ -26,7 +26,7 @@ sap.ui.define([
26
26
  * @extends sap.ui.core.Control
27
27
  *
28
28
  * @author SAP SE
29
- * @version 1.138.0
29
+ * @version 1.140.0
30
30
  * @since 1.56.0
31
31
  *
32
32
  * @constructor
@@ -22,7 +22,7 @@ sap.ui.define([
22
22
  * @extends sap.ui.core.Control
23
23
  *
24
24
  * @author SAP SE
25
- * @version 1.138.0
25
+ * @version 1.140.0
26
26
  * @since 1.60.0
27
27
  *
28
28
  * @constructor
@@ -39,7 +39,7 @@ sap.ui.define([
39
39
  * @extends sap.ui.core.Control
40
40
  *
41
41
  * @author SAP SE
42
- * @version 1.138.0
42
+ * @version 1.140.0
43
43
  * @since 1.56.0
44
44
  *
45
45
  * @constructor
@@ -21,7 +21,7 @@ sap.ui.define([
21
21
  * @extends sap.ui.base.ManagedObject
22
22
  *
23
23
  * @author SAP SE
24
- * @version 1.138.0
24
+ * @version 1.140.0
25
25
  * @since 1.56.0
26
26
  *
27
27
  * @constructor
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @extends sap.ui.core.Control
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.138.0
26
+ * @version 1.140.0
27
27
  * @since 1.56.0
28
28
  *
29
29
  * @constructor
@@ -901,7 +901,6 @@ sap.ui.define([
901
901
  }
902
902
  oButtonIcon = new SegmentedButtonItem({
903
903
  icon: aCharts[i].getIcon(),
904
- type: ButtonType.Transparent,
905
904
  tooltip: aCharts[i].getTitle(),
906
905
  customData: [new CustomData({
907
906
  key: 'chartId',
@@ -33,8 +33,8 @@ sap.ui.define([
33
33
  "sap/m/OverflowToolbar",
34
34
  "sap/m/ToolbarSpacer",
35
35
  "sap/m/Title",
36
- "sap/m/ColumnPopoverSelectListItem",
37
- "sap/m/ColumnHeaderPopover",
36
+ "sap/m/table/columnmenu/ActionItem",
37
+ "sap/m/table/columnmenu/Menu",
38
38
  "sap/ui/core/CustomData",
39
39
  "sap/ui/model/Sorter",
40
40
  "sap/m/SearchField",
@@ -77,8 +77,8 @@ sap.ui.define([
77
77
  OverflowToolbar,
78
78
  ToolbarSpacer,
79
79
  Title,
80
- ColumnPopoverSelectListItem,
81
- ColumnHeaderPopover,
80
+ ActionItem,
81
+ Columnmenu,
82
82
  CustomData,
83
83
  Sorter,
84
84
  SearchField,
@@ -118,7 +118,7 @@ sap.ui.define([
118
118
  * @class
119
119
  * @public
120
120
  * @internal
121
- * @version 1.138.0
121
+ * @version 1.140.0
122
122
  */
123
123
  var CloudFilePicker = Dialog.extend("sap.suite.ui.commons.CloudFilePicker", {
124
124
  metadata: {
@@ -707,31 +707,31 @@ sap.ui.define([
707
707
  if (sColumnType === "CreatedByUser" || sColumnType === "FileShareItemContentSize" || sColumnType === "FileShareItemContentType") {
708
708
  return;
709
709
  }
710
- var _aSortButton = [
711
- new ColumnPopoverSelectListItem({
712
- icon: "sap-icon://sort-ascending",
713
- action: function() {
714
- this._fHandleSorting(oColumn, true);
715
- }.bind(this)
716
- }),
717
- new ColumnPopoverSelectListItem({
718
- icon: "sap-icon://sort-descending",
719
- action: function() {
720
- this._fHandleSorting(oColumn, false);
721
- }.bind(this)
722
- })
723
- ];
724
- var oHeaderPopOver = new ColumnHeaderPopover({
725
- items: [_aSortButton]
710
+ var oColumnMenu = new Columnmenu({
711
+ items: [
712
+ new ActionItem({
713
+ icon: "sap-icon://sort-ascending",
714
+ press: function() {
715
+ this._fHandleSorting(oColumn, true);
716
+ }.bind(this)
717
+ }),
718
+ new ActionItem({
719
+ icon: "sap-icon://sort-descending",
720
+ press: function() {
721
+ this._fHandleSorting(oColumn, false);
722
+ }.bind(this)
723
+ })
724
+ ]
726
725
  });
727
- oHeaderPopOver.openBy(oColumn);
726
+
727
+ oColumnMenu.openBy(oColumn);
728
728
  }.bind(this));
729
729
 
730
730
  if (this.getFilePickerType() === FilePickerType.Upload && this.getSelectionMode() === SelectionMode.MultiSelect) {
731
731
  var oColumn = new Column({
732
732
  width: "10%",
733
733
  importance: "High"
734
- })
734
+ });
735
735
  this.oTableControl.insertColumn(oColumn, 0);
736
736
  var oTemplate = this.oTableControl.getBindingInfo("items").template;
737
737
  oTemplate.insertCell(
@@ -787,14 +787,14 @@ sap.ui.define([
787
787
  if (oItem.FileShareItemName.includes('(')) {
788
788
  var match = oItem.FileShareItemName.match(regex);
789
789
  var counter = Number(match[0]);
790
- if(counter > fcount) {
790
+ if (counter > fcount) {
791
791
  fcount = counter;
792
792
  }
793
793
  }
794
794
  });
795
795
  if (fcount) {
796
796
  fcount = fcount + 1;
797
- } else{
797
+ } else {
798
798
  fcount = fcount + 2;
799
799
  }
800
800
  oNewFolderInput.setValue(oResourceBundle.getText("CFP_TITLE_NEWFOLDER") + '(' + fcount + ')');
@@ -870,7 +870,7 @@ sap.ui.define([
870
870
  };
871
871
 
872
872
  CloudFilePicker.prototype._checkForDuplicateFileAndFolder = function (sSearchText, sFileShareKey, sDocumentType, sContentType,bNewFolderName) {
873
- if(bNewFolderName) {
873
+ if (bNewFolderName) {
874
874
  var filter = "startswith(FileShareItemName,\'" + sSearchText + "\') and FileShareItemKind eq \'" + sDocumentType + "\'and FileShareItemContentType eq \'" + sContentType + "\'";
875
875
  } else {
876
876
  filter = "FileShareItemName eq \'" + sSearchText + "\'and FileShareItemKind eq \'" + sDocumentType + "\'and FileShareItemContentType eq \'" + sContentType + "\'";
@@ -47,7 +47,7 @@ sap.ui.define([
47
47
  * @extends sap.ui.core.Control
48
48
  *
49
49
  * @author SAP SE
50
- * @version 1.138.0
50
+ * @version 1.140.0
51
51
  *
52
52
  * @constructor
53
53
  * @public
@@ -38,7 +38,7 @@ sap.ui.define([
38
38
  * @extends sap.ui.core.Control
39
39
  *
40
40
  * @author SAP SE
41
- * @version 1.138.0
41
+ * @version 1.140.0
42
42
  *
43
43
  * @constructor
44
44
  * @public
@@ -296,7 +296,14 @@ sap.ui.define([
296
296
 
297
297
  eBarWrapper.addChild(eText);
298
298
  eText.addClass("sapSuiteUiCommonsTimelineGroupHeaderSpan");
299
- eText.addChildEscaped(" " + oTimelineItem.getTitle());
299
+
300
+ // Use the new _getGroupTypeLabel method
301
+ var sGroupTypeLabel = this._getGroupTypeLabel(oTimelineItem);
302
+ if (sGroupTypeLabel) {
303
+ eText.addChildEscaped(" " + sGroupTypeLabel + ": " + oTimelineItem.getTitle());
304
+ } else {
305
+ eText.addChildEscaped(" " + oTimelineItem.getTitle());
306
+ }
300
307
 
301
308
  if (oTimelineItem._orientation === "V") {
302
309
  eTimelineItem.addChild(eIconBarWrapper);
@@ -576,14 +583,50 @@ sap.ui.define([
576
583
  eTimelineItem.setAttribute("aria-setsize", oTimelineItem._callParentFn("_getItemsCount"));
577
584
  }
578
585
  if (bIsGroupHeader) {
586
+ var sGroupTypeLabel = this._getGroupTypeLabel(oTimelineItem);
579
587
  if (!oTimelineItem._isGroupCollapsed()) {
580
- sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_EXPAND");
588
+ if (sGroupTypeLabel) {
589
+ sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + sGroupTypeLabel + " " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_EXPAND");
590
+ } else {
591
+ sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_EXPAND");
592
+ }
581
593
  } else {
582
- sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_COLLAPSE");
594
+ if (sGroupTypeLabel) {
595
+ sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + sGroupTypeLabel + " " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_COLLAPSE");
596
+ } else {
597
+ sGroupHeader = oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_HEADER") + ": " + oTimelineItem.getTitle() + " " + oResBundle.getText("TIMELINE_ACCESSIBILITY_GROUP_COLLAPSE");
598
+ }
583
599
  }
584
600
  eTimelineItem.setAttribute("aria-label", sGroupHeader, false);
585
601
  }
586
602
  };
587
603
 
604
+ /**
605
+ * Returns the localized label for the current Timeline grouping type (Year, Month, Quarter, Week, Day).
606
+ * Looks up the value of the GroupByType property from the parent Timeline control and returns the corresponding
607
+ * localized string from the resource bundle. If the type is not recognized, returns undefined.
608
+ * @param {sap.suite.ui.commons.TimelineItem} oTimelineItem The item to be rendered
609
+ * @returns {string|undefined} The localized label for the group type, or undefined if not found.
610
+ * @private
611
+ */
612
+ TimelineItemRenderer._getGroupTypeLabel = function (oTimelineItem) {
613
+ var oTimeline = oTimelineItem.getParent();
614
+ var sType = oTimeline.getGroupByType();
615
+
616
+ // Compare against enum values from library
617
+ var mTypeToKey = {};
618
+ mTypeToKey[library.TimelineGroupType.Year] = "TIMELINE_YEAR";
619
+ mTypeToKey[library.TimelineGroupType.Month] = "TIMELINE_MONTH";
620
+ mTypeToKey[library.TimelineGroupType.Quarter] = "TIMELINE_QUARTER";
621
+ mTypeToKey[library.TimelineGroupType.Week] = "TIMELINE_WEEK";
622
+ mTypeToKey[library.TimelineGroupType.Day] = "TIMELINE_DAY";
623
+
624
+ var sKey = mTypeToKey[sType];
625
+ if (sKey && oResBundle.hasText(sKey)) {
626
+ return oResBundle.getText(sKey);
627
+ }
628
+ return undefined;
629
+ };
630
+
588
631
  return TimelineItemRenderer;
589
632
  }, true);
@@ -1117,7 +1117,7 @@ sap.ui.define([
1117
1117
  that._filterDialogRangePage.setFilterCount(0);
1118
1118
  that._objects.getTimestampFilterPicker().clearDates();
1119
1119
  if (that._rangeFilterType == "None") {
1120
- that.toggleGroupTypeSelector();
1120
+ that.toggleGroupTypeSelector(that._rangeFilterType);
1121
1121
  }
1122
1122
  },
1123
1123
  filterDetailPageOpened: function (oItem) {
@@ -13,6 +13,10 @@ sap.ui.define(
13
13
  var PARAM_SAP_STAGEVIEW_HASH = "&sap-stageview-hash";
14
14
  var PARAM_SAP_CARD_ID = "&sap-ui-cardId";
15
15
  var PARAM_SAP_XX_CARD_ID = "&sap-ui-xx-cardId";
16
+ var PARAM_SAP_CARD_INFO = "&info=";
17
+ var PARAM_SAP_USHELL_CONFIG = "sap-ushell-config";
18
+ var PARAM_SAP_COLLABORATION_TEAMS = "sap-collaboration-teams";
19
+ var PARAM_SAP_UI_FESR_ENV = "sap-ui-fesr-env";
16
20
  var TRANSIENT_KEY = "transient";
17
21
  var oLogger = Log.getLogger("sap.suite.ui.commons.collaboration.CollaborationHelper");
18
22
 
@@ -140,19 +144,112 @@ sap.ui.define(
140
144
  const sUrl = sCurrentUrl.split(PARAM_SAP_CARD_ID)[0];
141
145
  window.location.replace(sUrl);
142
146
  } else if (sCurrentUrl.indexOf(PARAM_SAP_CARD_TITLE) > -1) {
143
- const UshellContainer = sap.ui.require("sap/ushell/Container");
144
147
  const sUrl = sCurrentUrl.split(PARAM_SAP_CARD_TITLE)[0];
145
- // Get indication is if we are in AppRuntime (for special use cases handling, e.g. BTP Fiori App in S/Cube)
146
- if (UshellContainer?.inAppRuntime()){
147
- await CollaborationMessageConsumer.updateTopLevelURLforAppRuntime(sUrl);
148
- } else {
149
- window.location.replace(sUrl);
150
- }
148
+ await this._redirectBasedOnRuntime(sUrl);
149
+ } else if (sCurrentUrl.includes(PARAM_SAP_CARD_INFO) && this._isFromTeams(sCurrentUrl)) {
150
+ const sUrl = sCurrentUrl.split(PARAM_SAP_CARD_INFO)[0];
151
+ await this._redirectBasedOnRuntime(sUrl);
151
152
  }
152
153
  return Promise.resolve();
153
154
  }.bind(this));
154
155
  };
155
156
 
157
+ /**
158
+ * Checks whether the given URL indicates that it originated from a Microsoft Teams environment.
159
+ *
160
+ * This is determined by the presence of the query parameter `sap-collaboration-teams=true`.
161
+ *
162
+ * @param {string} sCurrentUrl - The full URL to inspect.
163
+ * @returns {boolean} True if the URL contains `sap-collaboration-teams=true`; otherwise, false.
164
+ */
165
+ CollaborationHelper._isFromTeams = function (sCurrentUrl) {
166
+ const urlObj = new URL(sCurrentUrl);
167
+ const bIsFromTeams = urlObj.searchParams.get("sap-collaboration-teams");
168
+ return bIsFromTeams === "true";
169
+ };
170
+
171
+ /**
172
+ * Handles URL redirection according to the runtime environment.
173
+ *
174
+ * - In AppRuntime (e.g., BTP Fiori App in S/Cube), updates the top-level URL.
175
+ * - Otherwise, performs a standard window location redirect.
176
+ *
177
+ * @param {string} sUrl - The target URL for redirection.
178
+ * @private
179
+ */
180
+ CollaborationHelper._redirectBasedOnRuntime = async function (sUrl) {
181
+ const UshellContainer = sap.ui.require("sap/ushell/Container");
182
+
183
+ // Get indication is if we are in AppRuntime (for special use cases handling, e.g. BTP Fiori App in S/Cube)
184
+ if (UshellContainer && UshellContainer.inAppRuntime()) {
185
+ await CollaborationMessageConsumer.updateTopLevelURLforAppRuntime(sUrl);
186
+ } else {
187
+ const targetUrl = this._stripTeamsParams(sUrl);
188
+ window.location.replace(targetUrl);
189
+ }
190
+ };
191
+
192
+ /**
193
+ * Removes 'sap-ushell-config' and 'sap-collaboration-teams' query parameters
194
+ * from the given URL while preserving the hash fragment.
195
+ *
196
+ * @param {string} sUrl - The original full URL
197
+ * @returns {string} - The cleaned URL
198
+ * @private
199
+ */
200
+ CollaborationHelper._removeTeamsParams = function (sUrl) {
201
+ try {
202
+ const urlParts = sUrl.split("#");
203
+ const baseUrl = urlParts[0];
204
+ const hashPart = urlParts[1] ? "#" + urlParts[1] : "";
205
+
206
+ const [path, queryString] = baseUrl.split("?");
207
+ if (!queryString) {
208
+ return sUrl;
209
+ }
210
+
211
+ const params = new URLSearchParams(queryString);
212
+ params.delete(PARAM_SAP_USHELL_CONFIG);
213
+ params.delete(PARAM_SAP_COLLABORATION_TEAMS);
214
+ params.delete(PARAM_SAP_UI_FESR_ENV);
215
+
216
+ const newBaseUrl = params.toString()
217
+ ? `${path}?${params.toString()}`
218
+ : path;
219
+
220
+ return newBaseUrl + hashPart;
221
+ } catch (e) {
222
+ return sUrl;
223
+ }
224
+ };
225
+
226
+ /**
227
+ * If the current window is the top window, we assume it's not running inside an iframe, e.g. Microsoft Teams.
228
+ * In this case, we remove the Teams parameters from the URL.
229
+ *
230
+ * @param {string} sUrl The URL to be cleaned of Teams parameters.
231
+ * @returns {string} - The cleaned URL
232
+ * @private
233
+ */
234
+ CollaborationHelper._stripTeamsParams = function (sUrl) {
235
+ if (this._isTopWindow()) {
236
+ return this._removeTeamsParams(sUrl);
237
+ }
238
+ return sUrl;
239
+ };
240
+
241
+ /**
242
+ * Determines whether the current window is the top-level window.
243
+ * This is typically used to detect if the application is running inside an iframe (e.g., in Microsoft Teams).
244
+ *
245
+ * @returns {boolean} - Returns true if the current window is not inside an iframe, false otherwise.
246
+ * @private
247
+ */
248
+ CollaborationHelper._isTopWindow = function () {
249
+ return window.self === window.top;
250
+ };
251
+
252
+
156
253
  /**
157
254
  * Hides the avatar of the user if the app is running in the Microsoft Teams application.
158
255
  * @private
@@ -7,11 +7,11 @@
7
7
  class="sapUiContentPadding"
8
8
  placement="Auto"
9
9
  showHeader="false"
10
- contentWidth="25rem"
10
+ contentWidth="21.875rem"
11
11
  afterClose="afterClose"
12
12
  afterOpen="afterOpen">
13
13
  <VBox visible="{userData>/isUserExistsInTeams}">
14
- <HBox class="sapUiSmallMarginBeginEnd sapUiSmallMarginTopBottom" >
14
+ <HBox>
15
15
  <Avatar id="avatar" src="{= ${userData>/photo} ? ${userData>/photo} : 'sap-icon://person-placeholder' }"
16
16
  displaySize="M" class="sapUiSmallMarginEnd" displayShape="Circle" macrodata:email="{userData>/mail}" fesr:press="MST:ContactAction"
17
17
  macrodata:type="chat" tooltip="{userData>/badgeTooltip}" badgeValueState="{userData>/badgeValueState}" badgeTooltip="{userData>/badgeTooltip}" badgeIcon="{userData>/badgeIcon}"/>
@@ -20,9 +20,8 @@
20
20
  <Text text="{userData>/jobtitle}"/>
21
21
  </VBox>
22
22
  </HBox>
23
- <Toolbar width="100%" height="1px" visible="{userData>/isDirectCommunicationEnabled}"/>
24
- <OverflowToolbar visible="{userData>/isDirectCommunicationEnabled}">
25
- <Title text="{i18n>COLLABORATION_MSTEAMS_SHARE}" level="H5" class="sapUiTinyMarginBegin"/>
23
+ <OverflowToolbar visible="{userData>/isDirectCommunicationEnabled}" class="sapMFlexItem sapUiNoContentPadding sapUiTinyMarginTop">
24
+ <Title text="{i18n>COLLABORATION_MSTEAMS_SHARE}" level="H5"/>
26
25
  <ToolbarSpacer/>
27
26
  <Button
28
27
  press="handleMSTeamsPress"
@@ -30,8 +29,8 @@
30
29
  macrodata:type="chat"
31
30
  tooltip="{i18n>CHAT_BUTTON_TOOLTIP}"
32
31
  icon="sap-icon://discussion"
33
- type="Ghost"
34
- class="sapUiSmallMarginEnd"
32
+ type="Transparent"
33
+ class="sapUiTinyMarginEnd"
35
34
  fesr:press="MST:ContactAction"
36
35
  />
37
36
  <Button
@@ -40,8 +39,8 @@
40
39
  macrodata:type="videoCall"
41
40
  tooltip="{i18n>VIDEOCALL_BUTTON_TOOLTIP}"
42
41
  icon="sap-icon://video"
43
- type="Ghost"
44
- class="sapUiSmallMarginEnd"
42
+ type="Transparent"
43
+ class="sapUiTinyMarginEnd"
45
44
  fesr:press="MST:ContactAction"
46
45
  />
47
46
  <Button
@@ -50,31 +49,32 @@
50
49
  macrodata:type="call"
51
50
  tooltip="{i18n>CALL_BUTTON_TOOLTIP}"
52
51
  icon="sap-icon://call"
53
- type="Ghost"
52
+ type="Transparent"
53
+ class="sapUiTinyMarginEnd"
54
54
  fesr:press="MST:ContactAction"
55
55
  />
56
56
  </OverflowToolbar >
57
-
58
- <VBox class="sapUiSmallMarginBeginEnd sapUiSmallMarginTopBottom">
57
+
58
+ <VBox class="sapMFlexItem sapUiNoContentPadding sapUiSmallMarginTop">
59
59
 
60
60
  <Title text="{i18n>POPOVER_CONTACT_DETAILS}" level="H5" class="sapUiTinyMarginBottom sapUiTinyMarginTop" />
61
61
 
62
- <VBox visible="{= !!${userData>/mobilephone}}" class="sapUiTinyMarginBottom" >
62
+ <VBox visible="{= !!${userData>/mobilephone}}" class="sapUiTinyMarginTop sapUiTinyMarginBottom" >
63
63
  <Label id="UserMobile" text="{i18n>POPOVER_CONTACT_SECTION_MOBILE}:" />
64
64
  <Link text="{userData>/mobilephone}" href="{path: 'userData>/mobilephone', formatter: '.formatUri'}" ariaLabelledBy="UserMobile"/>
65
65
  </VBox>
66
66
 
67
- <VBox visible="{= !!${userData>/businessphone}}" class="sapUiTinyMarginBottom" >
67
+ <VBox visible="{= !!${userData>/businessphone}}" class="sapUiTinyMarginTop sapUiTinyMarginBottom" >
68
68
  <Label id="UserPhone" text="{i18n>POPOVER_CONTACT_SECTION_PHONE}:" />
69
69
  <Link text="{userData>/businessphone}" href="{path: 'userData>/businessphone', formatter: '.formatUri'}" ariaLabelledBy="UserPhone"/>
70
70
  </VBox>
71
71
 
72
- <VBox visible="{= !!${userData>/mail}}" class="sapUiTinyMarginBottom" >
72
+ <VBox visible="{= !!${userData>/mail}}" class="sapUiTinyMarginTop sapUiTinyMarginBottom" >
73
73
  <Label id="UserEmail" text="{i18n>POPOVER_CONTACT_SECTION_EMAIL}:" />
74
74
  <Link text="{userData>/mail}" href="{path: 'userData>/mail', formatter: '.formatUri'}" ariaLabelledBy="UserEmail"/>
75
75
  </VBox>
76
76
 
77
- <VBox visible="{= !!${userData>/officelocation}}" class="sapUiTinyMarginBottom" >
77
+ <VBox visible="{= !!${userData>/officelocation}}" class="sapUiTinyMarginTop sapUiTinyMarginBottom" >
78
78
  <Label text="{i18n>POPOVER_CONTACT_SECTION_OFFICE_LOCATION}:" />
79
79
  <Text text="{userData>/officelocation}" />
80
80
  </VBox>
@@ -90,4 +90,4 @@
90
90
  </IllustratedMessage >
91
91
  </HBox>
92
92
  </Popover>
93
- </core:FragmentDefinition>
93
+ </core:FragmentDefinition>