@openui5/sap.ui.table 1.94.0 → 1.97.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 (52) hide show
  1. package/.reuse/dep5 +12 -12
  2. package/THIRDPARTY.txt +21 -17
  3. package/package.json +3 -3
  4. package/src/sap/ui/table/.library +1 -1
  5. package/src/sap/ui/table/AnalyticalColumn.js +1 -1
  6. package/src/sap/ui/table/AnalyticalColumnMenu.js +1 -1
  7. package/src/sap/ui/table/AnalyticalTable.js +4 -4
  8. package/src/sap/ui/table/Column.js +29 -6
  9. package/src/sap/ui/table/ColumnMenu.js +3 -1
  10. package/src/sap/ui/table/CreationRow.js +1 -1
  11. package/src/sap/ui/table/Row.js +1 -1
  12. package/src/sap/ui/table/RowAction.js +1 -1
  13. package/src/sap/ui/table/RowActionItem.js +1 -1
  14. package/src/sap/ui/table/RowSettings.js +3 -2
  15. package/src/sap/ui/table/Table.js +7 -11
  16. package/src/sap/ui/table/TablePersoController.js +1 -1
  17. package/src/sap/ui/table/TableRenderer.js +2 -2
  18. package/src/sap/ui/table/TreeTable.js +2 -2
  19. package/src/sap/ui/table/extensions/Accessibility.js +45 -26
  20. package/src/sap/ui/table/extensions/AccessibilityRender.js +1 -1
  21. package/src/sap/ui/table/extensions/DragAndDrop.js +1 -1
  22. package/src/sap/ui/table/extensions/ExtensionBase.js +1 -1
  23. package/src/sap/ui/table/extensions/Keyboard.js +6 -2
  24. package/src/sap/ui/table/extensions/KeyboardDelegate.js +1 -1
  25. package/src/sap/ui/table/extensions/Pointer.js +1 -1
  26. package/src/sap/ui/table/extensions/Scrolling.js +136 -129
  27. package/src/sap/ui/table/extensions/ScrollingIOS.js +2 -2
  28. package/src/sap/ui/table/extensions/Synchronization.js +1 -1
  29. package/src/sap/ui/table/library.js +10 -10
  30. package/src/sap/ui/table/messagebundle_fr.properties +1 -1
  31. package/src/sap/ui/table/messagebundle_it.properties +3 -3
  32. package/src/sap/ui/table/plugins/BindingSelection.js +1 -1
  33. package/src/sap/ui/table/plugins/PluginBase.js +1 -1
  34. package/src/sap/ui/table/plugins/SelectionModelSelection.js +1 -1
  35. package/src/sap/ui/table/plugins/SelectionPlugin.js +1 -1
  36. package/src/sap/ui/table/plugins/V4Aggregation.js +1 -1
  37. package/src/sap/ui/table/rowmodes/AutoRowMode.js +16 -1
  38. package/src/sap/ui/table/rowmodes/FixedRowMode.js +16 -1
  39. package/src/sap/ui/table/rowmodes/InteractiveRowMode.js +23 -9
  40. package/src/sap/ui/table/rowmodes/RowMode.js +5 -4
  41. package/src/sap/ui/table/rowmodes/VariableRowMode.js +1 -1
  42. package/src/sap/ui/table/themes/base/Cell.less +4 -13
  43. package/src/sap/ui/table/themes/base/Grouping.less +22 -3
  44. package/src/sap/ui/table/themes/base/Table.less +2 -2
  45. package/src/sap/ui/table/themes/base/library.source.less +2 -1
  46. package/src/sap/ui/table/utils/TableUtils.js +19 -5
  47. package/src/sap/ui/table/utils/_BindingUtils.js +1 -1
  48. package/src/sap/ui/table/utils/_ColumnUtils.js +1 -1
  49. package/src/sap/ui/table/utils/_GroupingUtils.js +7 -1
  50. package/src/sap/ui/table/utils/_HookUtils.js +1 -1
  51. package/src/sap/ui/table/utils/_MenuUtils.js +1 -1
  52. package/ui5.yaml +4 -1
@@ -33,7 +33,7 @@ sap.ui.define([
33
33
  * @ui5-restricted sap.ui.mdc
34
34
  *
35
35
  * @author SAP SE
36
- * @version 1.94.0
36
+ * @version 1.97.0
37
37
  *
38
38
  * @ui5-metamodel This control/element also will be described in the UI5 (legacy) designtime metamodel
39
39
  */
@@ -168,7 +168,11 @@ sap.ui.define([
168
168
  * @inheritDoc
169
169
  */
170
170
  InteractiveRowMode.prototype.getComputedRowCounts = function() {
171
- return this.computeStandardizedRowCounts(this.getConfiguredRowCount(), this.getFixedTopRowCount(), this.getFixedBottomRowCount());
171
+ var iRowCount = this.getConfiguredRowCount();
172
+ var iFixedTopRowCount = this.getFixedTopRowCount();
173
+ var iFixedBottomRowCount = this.getFixedBottomRowCount();
174
+
175
+ return this.computeStandardizedRowCounts(iRowCount, iFixedTopRowCount, iFixedBottomRowCount);
172
176
  };
173
177
 
174
178
  /**
@@ -315,13 +319,23 @@ sap.ui.define([
315
319
  var width = $Splitter.width();
316
320
  var bTouch = oTable._isTouchEvent(oEvent);
317
321
 
318
- $Body.append(
319
- "<div id=\"" + oTable.getId() + "-ghost\" class=\"sapUiTableInteractiveResizerGhost\" style =\" height:" + height + "px; width:"
320
- + width + "px; left:" + offset.left + "px; top:" + offset.top + "px\" ></div>");
321
-
322
- // Append overlay over splitter to enable correct functionality of moving the splitter
323
- $Splitter.append(
324
- "<div id=\"" + oTable.getId() + "-rzoverlay\" style =\"left: 0px; right: 0px; bottom: 0px; top: 0px; position:absolute\" ></div>");
322
+ var oGhostDiv = document.createElement("div");
323
+ oGhostDiv.style.width = width + "px";
324
+ oGhostDiv.style.height = height + "px";
325
+ oGhostDiv.style.left = offset.left + "px";
326
+ oGhostDiv.style.top = offset.top + "px";
327
+ oGhostDiv.className = "sapUiTableInteractiveResizerGhost";
328
+ oGhostDiv.id = oTable.getId() + "-ghost";
329
+ $Body.append(oGhostDiv);
330
+
331
+ var oOverlayDiv = document.createElement("div");
332
+ oOverlayDiv.style.top = "0px";
333
+ oOverlayDiv.style.bottom = "0px";
334
+ oOverlayDiv.style.left = "0px";
335
+ oOverlayDiv.style.right = "0px";
336
+ oOverlayDiv.style.position = "absolute";
337
+ oOverlayDiv.id = oTable.getId() + "-rzoverlay";
338
+ $Splitter.append(oOverlayDiv);
325
339
 
326
340
  $Document.on((bTouch ? "touchend" : "mouseup") + ".sapUiTableInteractiveResize",
327
341
  ResizeHelper.exitInteractiveResizing.bind(oTable, oMode));
@@ -36,7 +36,7 @@ sap.ui.define([
36
36
  * @ui5-restricted sap.ui.mdc
37
37
  *
38
38
  * @author SAP SE
39
- * @version 1.94.0
39
+ * @version 1.97.0
40
40
  * @ui5-metamodel This control/element also will be described in the UI5 (legacy) designtime metamodel
41
41
  */
42
42
  var RowMode = Element.extend("sap.ui.table.rowmodes.RowMode", /** @lends sap.ui.table.rowmodes.RowMode.prototype */ {
@@ -578,9 +578,9 @@ sap.ui.define([
578
578
  // There is no need to have rows in the aggregation if the NoData overlay is enabled and no binding is available.
579
579
  if (TableUtils.isNoDataVisible(oTable) && !oTable.getBinding()) {
580
580
  iNewNumberOfRows = 0;
581
- } else if (TableUtils.isVariableRowHeightEnabled(oTable)) {
581
+ } else if (TableUtils.isVariableRowHeightEnabled(oTable) && iNewNumberOfRows > 0) {
582
582
  // TODO: Move this to VariableRowMode#getComputedRowCounts
583
- iNewNumberOfRows = iNewNumberOfRows + 1; // Create one additional row for partial row scrolling.
583
+ iNewNumberOfRows++; // Create one additional row for partial row scrolling.
584
584
  }
585
585
 
586
586
  // Destroy rows if they are invalid, but keep the DOM in case the table is going to render.
@@ -785,12 +785,13 @@ sap.ui.define([
785
785
  */
786
786
  function updateBindingContextsOfRows(oMode, aRows) {
787
787
  var oTable = oMode.getTable();
788
- var aContexts = oMode.getRowContexts(aRows.length);
789
788
 
790
789
  if (!oTable || aRows.length === 0) {
791
790
  return;
792
791
  }
793
792
 
793
+ var aContexts = oMode.getRowContexts(aRows.length);
794
+
794
795
  for (var i = 0; i < aRows.length; i++) {
795
796
  aRows[i].setRowBindingContext(aContexts[i], oTable);
796
797
  }
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @extends sap.ui.table.rowmodes.RowMode
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.94.0
26
+ * @version 1.97.0
27
27
  *
28
28
  * @constructor
29
29
  * @private
@@ -3,8 +3,8 @@
3
3
  /* Base theme */
4
4
  /* ========================== */
5
5
 
6
- @_sap_ui_table_Cell_FocusOutlineOffset: -1px;
7
- @_sap_ui_table_Cell_FocusOutlineOffsetInZoomedChrome: -2px;
6
+ @_sap_ui_table_Cell_FocusOutlineOffset: -@sapUiContentFocusWidth;
7
+ @_sap_ui_table_Cell_FocusOutlineOffsetInZoomedChrome: calc(-@sapUiContentFocusWidth ~"- 0.0625rem");
8
8
  @_sap_ui_table_Cell_Padding: 0 0.5rem;
9
9
  @_sap_ui_table_Cell_TouchMenuIconSize: 1.375rem;
10
10
  @_sap_ui_table_Cell_ColumnIconSize: 0.75rem;
@@ -24,7 +24,7 @@
24
24
  position: absolute;
25
25
  inset: 0;
26
26
  pointer-events: none;
27
- outline: @_sap_ui_table_FocusOutlineWidth dotted @sapUiContentFocusColor;
27
+ outline: @_sap_ui_table_FocusOutlineWidth @sapUiContentFocusStyle @sapUiContentFocusColor;
28
28
  outline-offset: @_sap_ui_table_Cell_FocusOutlineOffset;
29
29
 
30
30
  .sapUiTableZoomout & {
@@ -337,15 +337,6 @@
337
337
  overflow: hidden;
338
338
  padding: @_sap_ui_table_Cell_Padding;
339
339
  white-space: nowrap;
340
-
341
- .sapUiSizeCondensed & {
342
- padding: 0;
343
-
344
- > * {
345
- box-sizing: border-box;
346
- padding: @_sap_ui_table_Cell_Padding;
347
- }
348
- }
349
340
  }
350
341
  }
351
342
 
@@ -390,7 +381,7 @@
390
381
  border-left: @_sap_ui_table_BaseBorderWidth solid @sapUiListVerticalBorderColor;
391
382
  pointer-events: none;
392
383
  .sapUiTableContentRow & {
393
- background-color: @sapUiListBackground !important;
384
+ background-color: @sapBackgroundColor !important;
394
385
  }
395
386
  }
396
387
 
@@ -29,7 +29,7 @@
29
29
  }
30
30
 
31
31
  &:focus {
32
- outline: @_sap_ui_table_Grouping_GroupOutlineWidth dotted @sapUiContentFocusColor;
32
+ outline: @_sap_ui_table_Grouping_GroupOutlineWidth @sapUiContentFocusStyle @sapUiContentFocusColor;
33
33
  outline-offset: -2px;
34
34
  }
35
35
  }
@@ -42,7 +42,7 @@
42
42
  position: absolute;
43
43
  left: 1px;
44
44
  top: @_sap_ui_table_Grouping_GroupOutlineWidth;
45
- bottom: 0;
45
+ bottom: @_sap_ui_table_Grouping_GroupOutlineWidth;
46
46
  white-space: nowrap;
47
47
  font-weight: normal;
48
48
  color: @sapUiListTextColor;
@@ -80,6 +80,7 @@
80
80
  text-align: center;
81
81
  vertical-align: middle;
82
82
  margin-left: -2px;
83
+ margin-right: 2px;
83
84
  }
84
85
 
85
86
  .sapUiSizeCozy .sapUiTableGroupIcon::before {
@@ -103,6 +104,10 @@ html[dir=rtl] {
103
104
  }
104
105
  }
105
106
 
107
+ .sapUiTableTreeIcon.sapUiTableTreeIconLeaf {
108
+ visibility: hidden;
109
+ }
110
+
106
111
  .sapUiTableGroupHeaderFading(@color) {
107
112
  box-shadow: inset @_sap_ui_table_Grouping_GroupHeaderFadingWidth 0 @_sap_ui_table_Grouping_GroupHeaderFadingWidth / 2 -@_sap_ui_table_Grouping_GroupHeaderFadingWidth / 2 @color;
108
113
  }
@@ -121,11 +126,21 @@ html[dir=rtl] {
121
126
 
122
127
  .sapUiTableGroupHeaderRow > .sapUiTableRowSelectionCell:focus .sapUiTableGroupIcon {
123
128
  outline-width: @_sap_ui_table_Grouping_GroupOutlineWidth;
124
- outline-style: dotted;
129
+ outline-style: @sapUiContentFocusStyle;
125
130
  outline-offset: 0;
126
131
  outline-color: @sapUiContentFocusColor;
127
132
  }
128
133
 
134
+ .sapUiTableGroupHeaderRow > .sapUiTableRowSelectionCell:focus::before {
135
+ outline: none;
136
+ }
137
+
138
+ .sapUiTableGroupHeaderRow > .sapUiTableCell.sapUiTableCellFirst:focus::before,
139
+ .sapUiTableGroupMode .sapUiTableRowIndented > .sapUiTableCell.sapUiTableCellFirst:focus::before {
140
+ z-index: 2;
141
+ left: var(--CalculatedGroupIndent, 0);
142
+ }
143
+
129
144
  // Override row background and cell borders in group header rows.
130
145
  .sapUiTableGroupHeaderRow {
131
146
  &.sapUiTableRow {
@@ -181,6 +196,10 @@ html[dir=rtl] {
181
196
  pointer-events: none;
182
197
  }
183
198
 
199
+ .sapUiTableRowHidden > .sapUiTableCell > .sapUiTableGroupShield {
200
+ display: block;
201
+ }
202
+
184
203
  .sapUiTableGroupHeaderRow > .sapUiTableRowSelectionCell:focus {
185
204
  outline: 0;
186
205
  }
@@ -63,7 +63,7 @@
63
63
  border-left: @_sap_ui_table_BaseBorderWidth solid @sapUiListVerticalBorderColor;
64
64
  border-right: @_sap_ui_table_BaseBorderWidth solid @sapUiListVerticalBorderColor;
65
65
  border-top: @_sap_ui_table_BaseBorderWidth solid @sapUiListBorderColor;
66
- background-color: @sapUiListBackground;
66
+ background-color: @sapBackgroundColor;
67
67
  ._sap_ui_table_Table_Table();
68
68
  }
69
69
 
@@ -183,7 +183,7 @@
183
183
  .sapUiTableCtrlEmpty:focus,
184
184
  .sapUiTableCnt > .sapUiLocalBusyIndicator:focus {
185
185
  outline-width: @_sap_ui_table_FocusOutlineWidth;
186
- outline-style: dotted;
186
+ outline-style: @sapUiContentFocusStyle;
187
187
  outline-offset: -3px;
188
188
  outline-color: @sapUiContentFocusColor;
189
189
  }
@@ -45,7 +45,8 @@
45
45
  @_sap_ui_table_DeleteIcon: sys-cancel;
46
46
  @_sap_ui_table_ClearSelectionIcon: clear-all;
47
47
 
48
- @_sap_ui_table_FocusOutlineWidth: 1px;
48
+ /*TBD: Table specific parameter should be removed and replaced with sapUiContentFocusWidth*/
49
+ @_sap_ui_table_FocusOutlineWidth: @sapUiContentFocusWidth;
49
50
 
50
51
  @import "Table.less";
51
52
  @import "Row.less";
@@ -209,7 +209,7 @@ sap.ui.define([
209
209
  * Static collection of utility functions related to the sap.ui.table.Table, ...
210
210
  *
211
211
  * @author SAP SE
212
- * @version 1.94.0
212
+ * @version 1.97.0
213
213
  * @namespace
214
214
  * @alias sap.ui.table.utils.TableUtils
215
215
  * @private
@@ -1392,8 +1392,22 @@ sap.ui.define([
1392
1392
  // Converting the row height CSS parameters (e.g. _sap_ui_table_RowHeight) is too complex (CSS calc()).
1393
1393
  // Therefore, the base sizes are used and calculation is done in JavaScript.
1394
1394
 
1395
+ var mParams = ThemeParameters.get({
1396
+ name: [
1397
+ "_sap_ui_table_BaseSize",
1398
+ "_sap_ui_table_BaseSizeCozy",
1399
+ "_sap_ui_table_BaseSizeCompact",
1400
+ "_sap_ui_table_BaseSizeCondensed",
1401
+ "_sap_ui_table_BaseBorderWidth",
1402
+ "_sap_ui_table_NavigationIcon",
1403
+ "_sap_ui_table_DeleteIcon",
1404
+ "_sap_ui_table_ClearSelectionIcon",
1405
+ "_sap_ui_table_NavIndicatorWidth"
1406
+ ]
1407
+ });
1408
+
1395
1409
  function getPixelValue(sThemeParameterName) {
1396
- return TableUtils.convertCSSSizeToPixel(ThemeParameters.get(sThemeParameterName));
1410
+ return TableUtils.convertCSSSizeToPixel(mParams[sThemeParameterName]);
1397
1411
  }
1398
1412
 
1399
1413
  mBaseSize.undefined = getPixelValue("_sap_ui_table_BaseSize");
@@ -1408,9 +1422,9 @@ sap.ui.define([
1408
1422
  mDefaultRowHeight.sapUiSizeCompact = mBaseSize.sapUiSizeCompact + iRowHorizontalFrameSize;
1409
1423
  mDefaultRowHeight.sapUiSizeCondensed = mBaseSize.sapUiSizeCondensed + iRowHorizontalFrameSize;
1410
1424
 
1411
- mThemeParameters.navigationIcon = ThemeParameters.get("_sap_ui_table_NavigationIcon");
1412
- mThemeParameters.deleteIcon = ThemeParameters.get("_sap_ui_table_DeleteIcon");
1413
- mThemeParameters.clearSelectionIcon = ThemeParameters.get("_sap_ui_table_ClearSelectionIcon");
1425
+ mThemeParameters.navigationIcon = mParams["_sap_ui_table_NavigationIcon"];
1426
+ mThemeParameters.deleteIcon = mParams["_sap_ui_table_DeleteIcon"];
1427
+ mThemeParameters.clearSelectionIcon = mParams["_sap_ui_table_ClearSelectionIcon"];
1414
1428
  mThemeParameters.navIndicatorWidth = getPixelValue("_sap_ui_table_NavIndicatorWidth");
1415
1429
  },
1416
1430
 
@@ -14,7 +14,7 @@ sap.ui.define([], function() {
14
14
  * Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Binding...</code>
15
15
  *
16
16
  * @author SAP SE
17
- * @version 1.94.0
17
+ * @version 1.97.0
18
18
  * @namespace
19
19
  * @alias sap.ui.table.utils._BindingUtils
20
20
  * @private
@@ -18,7 +18,7 @@ sap.ui.define([
18
18
  * Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Column...</code>
19
19
  *
20
20
  * @author SAP SE
21
- * @version 1.94.0
21
+ * @version 1.97.0
22
22
  * @namespace
23
23
  * @alias sap.ui.table.utils._ColumnUtils
24
24
  * @private
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Grouping...</code>
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.94.0
26
+ * @version 1.97.0
27
27
  * @namespace
28
28
  * @alias sap.ui.table.utils._GroupingUtils
29
29
  * @private
@@ -273,12 +273,14 @@ sap.ui.define([
273
273
  $RowHdr.css(bRTL ? "right" : "left", "");
274
274
  $Shield.css("width", "").css(bRTL ? "margin-right" : "margin-left", "");
275
275
  $FirstCellContentInRow.css(bRTL ? "padding-right" : "padding-left", "");
276
+ $Row.css("--CalculatedGroupIndent", "0");
276
277
  } else {
277
278
  // Apply indent on table row
278
279
  $RowHdr.css(bRTL ? "right" : "left", iIndent + "px");
279
280
  $Shield.css("width", iIndent + "px").css(bRTL ? "margin-right" : "margin-left", ((-1) * iIndent) + "px");
280
281
  $FirstCellContentInRow.css(bRTL ? "padding-right" : "padding-left",
281
282
  (iIndent + 8/* +8px standard padding .sapUiTableCellInner */) + "px");
283
+ $Row.css("--CalculatedGroupIndent", iIndent + "px");
282
284
  }
283
285
  },
284
286
 
@@ -338,6 +340,10 @@ sap.ui.define([
338
340
  if (GroupingUtils.isInTreeMode(oTable)) {
339
341
  var $TreeIcon = $Row.find(".sapUiTableTreeIcon");
340
342
 
343
+ if (!bIsExpandable && document.activeElement === $TreeIcon[0]) {
344
+ GroupingUtils.TableUtils.getParentCell(oTable, $TreeIcon[0]).trigger("focus");
345
+ }
346
+
341
347
  $TreeIcon.toggleClass("sapUiTableTreeIconLeaf", !bIsExpandable)
342
348
  .toggleClass("sapUiTableTreeIconNodeOpen", bIsExpandable && bIsExpanded)
343
349
  .toggleClass("sapUiTableTreeIconNodeClosed", bIsExpandable && !bIsExpanded);
@@ -22,7 +22,7 @@ sap.ui.define(["sap/ui/base/DataType", "sap/base/Log"], function(DataType, Log)
22
22
  * - There is no concept for public or protected hooks. Never expose a hook directly, only indirectly as can be seen in the examples.
23
23
  *
24
24
  * @author SAP SE
25
- * @version 1.94.0
25
+ * @version 1.97.0
26
26
  * @namespace
27
27
  * @alias sap.ui.table.utils._HookUtils
28
28
  *
@@ -42,7 +42,7 @@ sap.ui.define([
42
42
  * Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Menu...</code>
43
43
  *
44
44
  * @author SAP SE
45
- * @version 1.94.0
45
+ * @version 1.97.0
46
46
  * @namespace
47
47
  * @alias sap.ui.table.utils._MenuUtils
48
48
  * @private
package/ui5.yaml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
- specVersion: "1.1"
2
+ specVersion: "2.0"
3
3
  type: library
4
4
  metadata:
5
5
  name: sap.ui.table
@@ -7,3 +7,6 @@ metadata:
7
7
  OpenUI5
8
8
  * (c) Copyright 2009-${currentYear} SAP SE or an SAP affiliate company.
9
9
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
10
+ resources:
11
+ configuration:
12
+ propertiesFileSourceEncoding: ISO-8859-1