@openui5/sap.uxap 1.113.0 → 1.115.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.
- package/.reuse/dep5 +0 -5
- package/THIRDPARTY.txt +1 -7
- package/package.json +5 -5
- package/src/sap/uxap/.library +1 -1
- package/src/sap/uxap/BlockBase.js +2 -2
- package/src/sap/uxap/BlockBaseMetadata.js +1 -1
- package/src/sap/uxap/HierarchicalSelect.js +2 -4
- package/src/sap/uxap/ObjectPageAccessibleLandmarkInfo.js +1 -1
- package/src/sap/uxap/ObjectPageDynamicHeaderContent.js +1 -1
- package/src/sap/uxap/ObjectPageDynamicHeaderTitle.js +1 -1
- package/src/sap/uxap/ObjectPageLayout.js +36 -18
- package/src/sap/uxap/ObjectPageLazyLoader.js +5 -4
- package/src/sap/uxap/ObjectPageSection.js +21 -4
- package/src/sap/uxap/ObjectPageSectionRenderer.js +9 -4
- package/src/sap/uxap/ObjectPageSubSection.js +60 -15
- package/src/sap/uxap/changeHandler/AddIFrameObjectPageLayout.js +27 -1
- package/src/sap/uxap/changeHandler/MoveObjectPageSection.js +53 -3
- package/src/sap/uxap/changeHandler/RenameObjectPageSection.js +40 -1
- package/src/sap/uxap/changeHandler/UnstashObjectPageSection.js +62 -0
- package/src/sap/uxap/designtime/ObjectPageSection.designtime.js +14 -11
- package/src/sap/uxap/flexibility/ObjectPageSection.flexibility.js +7 -3
- package/src/sap/uxap/library.js +13 -8
- package/src/sap/uxap/rules/ObjectPageLayout.support.js +3 -3
- package/src/sap/uxap/themes/base/ObjectPageSubSection.less +6 -4
package/.reuse/dep5
CHANGED
|
@@ -192,11 +192,6 @@ Copyright: 2012 Matteo Spinelli
|
|
|
192
192
|
License: MIT
|
|
193
193
|
Comment: these files belong to: cubiq.org - swipeview
|
|
194
194
|
|
|
195
|
-
Files: src/sap.ui.core/src/sap/ui/thirdparty/mobify-carousel.js
|
|
196
|
-
Copyright: Mobify R&D Inc.
|
|
197
|
-
License: MIT
|
|
198
|
-
Comment: these files belong to: Mobify.js
|
|
199
|
-
|
|
200
195
|
Files: src/sap.ui.core/src/sap/ui/thirdparty/zyngascroll.js
|
|
201
196
|
Copyright: 2011 Zynga Inc.
|
|
202
197
|
License: MIT
|
package/THIRDPARTY.txt
CHANGED
|
@@ -143,12 +143,6 @@ License: MIT
|
|
|
143
143
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/MIT.txt
|
|
144
144
|
Contained in: src/sap.ui.core/src/sap/ui/thirdparty/swipe-view.js
|
|
145
145
|
|
|
146
|
-
Component: Mobify.js, version: 1.1
|
|
147
|
-
Copyright: Mobify R&D Inc.
|
|
148
|
-
License: MIT
|
|
149
|
-
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/MIT.txt
|
|
150
|
-
Contained in: src/sap.ui.core/src/sap/ui/thirdparty/mobify-carousel.js
|
|
151
|
-
|
|
152
146
|
Component: Zynga Scroller, version: 1.2.1-0-g5d43806
|
|
153
147
|
Copyright: 2011 Zynga Inc.
|
|
154
148
|
License: MIT
|
|
@@ -478,7 +472,7 @@ License: Apache-2.0
|
|
|
478
472
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
|
|
479
473
|
Contained in: lib/jsdoc/ui5/plugin.js
|
|
480
474
|
|
|
481
|
-
Component: SAP Theming Base Content, version: 11.
|
|
475
|
+
Component: SAP Theming Base Content, version: 11.3.0
|
|
482
476
|
Copyright: SAP SE or an SAP affiliate company and Theming Base Content contributors
|
|
483
477
|
License: Apache-2.0
|
|
484
478
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openui5/sap.uxap",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.115.0",
|
|
4
4
|
"description": "OpenUI5 UI Library sap.uxap",
|
|
5
5
|
"author": "SAP SE (https://www.sap.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -14,9 +14,9 @@
|
|
|
14
14
|
"url": "https://github.com/SAP/openui5.git"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@openui5/sap.f": "1.
|
|
18
|
-
"@openui5/sap.m": "1.
|
|
19
|
-
"@openui5/sap.ui.core": "1.
|
|
20
|
-
"@openui5/sap.ui.layout": "1.
|
|
17
|
+
"@openui5/sap.f": "1.115.0",
|
|
18
|
+
"@openui5/sap.m": "1.115.0",
|
|
19
|
+
"@openui5/sap.ui.core": "1.115.0",
|
|
20
|
+
"@openui5/sap.ui.layout": "1.115.0"
|
|
21
21
|
}
|
|
22
22
|
}
|
package/src/sap/uxap/.library
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
<name>sap.uxap</name>
|
|
5
5
|
<vendor>SAP SE</vendor>
|
|
6
|
-
<version>1.
|
|
6
|
+
<version>1.115.0</version>
|
|
7
7
|
<copyright>OpenUI5
|
|
8
8
|
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
9
9
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.</copyright>
|
|
@@ -245,11 +245,11 @@ sap.ui.define([
|
|
|
245
245
|
* @param {*} bSuppressInvalidate invalidate
|
|
246
246
|
*/
|
|
247
247
|
BlockBase.prototype.setParent = function (oParent, sAggregationName, bSuppressInvalidate) {
|
|
248
|
+
Control.prototype.setParent.call(this, oParent, sAggregationName, bSuppressInvalidate);
|
|
249
|
+
|
|
248
250
|
if (oParent instanceof library.ObjectPageSubSection) {
|
|
249
251
|
this._bLazyLoading = true; //we activate the block lazy loading since we are within an objectPageLayout
|
|
250
252
|
this._oParentObjectPageSubSection = oParent;
|
|
251
|
-
} else {
|
|
252
|
-
Control.prototype.setParent.call(this, oParent, sAggregationName, bSuppressInvalidate);
|
|
253
253
|
}
|
|
254
254
|
};
|
|
255
255
|
|
|
@@ -9,10 +9,8 @@ sap.ui.define([
|
|
|
9
9
|
"sap/m/Select",
|
|
10
10
|
"sap/ui/Device",
|
|
11
11
|
"sap/ui/thirdparty/jquery",
|
|
12
|
-
"./
|
|
13
|
-
|
|
14
|
-
"sap/ui/thirdparty/jqueryui/jquery-ui-position"
|
|
15
|
-
], function(Select, Device, jQuery, library, HierarchicalSelectRenderer /*jqueryUiPosition,*/) {
|
|
12
|
+
"./HierarchicalSelectRenderer"
|
|
13
|
+
], function(Select, Device, jQuery, HierarchicalSelectRenderer) {
|
|
16
14
|
"use strict";
|
|
17
15
|
|
|
18
16
|
/**
|
|
@@ -33,7 +33,8 @@ sap.ui.define([
|
|
|
33
33
|
"sap/base/util/merge",
|
|
34
34
|
"sap/ui/events/KeyCodes",
|
|
35
35
|
"sap/ui/dom/getFirstEditableInput",
|
|
36
|
-
'sap/ui/dom/units/Rem'
|
|
36
|
+
'sap/ui/dom/units/Rem',
|
|
37
|
+
"sap/ui/base/Object"
|
|
37
38
|
], function(
|
|
38
39
|
jQuery,
|
|
39
40
|
ManagedObjectObserver,
|
|
@@ -62,7 +63,8 @@ sap.ui.define([
|
|
|
62
63
|
merge,
|
|
63
64
|
KeyCodes,
|
|
64
65
|
getFirstEditableInput,
|
|
65
|
-
DomUnitsRem
|
|
66
|
+
DomUnitsRem,
|
|
67
|
+
BaseObject
|
|
66
68
|
) {
|
|
67
69
|
"use strict";
|
|
68
70
|
|
|
@@ -1193,6 +1195,7 @@ sap.ui.define([
|
|
|
1193
1195
|
clearTimeout(this._iAfterRenderingDomReadyTimeout);
|
|
1194
1196
|
}
|
|
1195
1197
|
this._iAfterRenderingDomReadyTimeout = setTimeout(this._onAfterRenderingDomReady.bind(this), this._getDOMCalculationDelay());
|
|
1198
|
+
this._adjustTitlePositioning(); // adjust early to prevent visual offset/flickering of content
|
|
1196
1199
|
}
|
|
1197
1200
|
|
|
1198
1201
|
if (oHeaderContent && oHeaderContent.supportsPinUnpin()) {
|
|
@@ -1236,7 +1239,7 @@ sap.ui.define([
|
|
|
1236
1239
|
}
|
|
1237
1240
|
// enable scrolling in non-fullscreen-mode only
|
|
1238
1241
|
// (to avoid any scrollbar appearing even for an instance while we snap/unsnap header)
|
|
1239
|
-
this._toggleScrolling(!this._bAllContentFitsContainer || this.
|
|
1242
|
+
this._toggleScrolling(!this._bAllContentFitsContainer || !this._getFirstVisibleSubSection()._hasRestrictedHeight());
|
|
1240
1243
|
|
|
1241
1244
|
this._registerOnContentResize();
|
|
1242
1245
|
|
|
@@ -1834,7 +1837,7 @@ sap.ui.define([
|
|
|
1834
1837
|
|
|
1835
1838
|
var oSubsection;
|
|
1836
1839
|
|
|
1837
|
-
if (oSection
|
|
1840
|
+
if (BaseObject.isA(oSection, "sap.uxap.ObjectPageSubSection")) {
|
|
1838
1841
|
oSubsection = oSection;
|
|
1839
1842
|
oSection = oSection.getParent();
|
|
1840
1843
|
} else {
|
|
@@ -2142,8 +2145,6 @@ sap.ui.define([
|
|
|
2142
2145
|
|
|
2143
2146
|
// the current tab changed => update the <code>this._bAllContentFitsContainer</code> accordingly
|
|
2144
2147
|
this._bAllContentFitsContainer = this._hasSingleVisibleFullscreenSubSection(oToSelect);
|
|
2145
|
-
this._toggleScrolling(!this._bAllContentFitsContainer || this._headerBiggerThanAllowedToBeFixed());
|
|
2146
|
-
|
|
2147
2148
|
bFullscreenModeChanged = this._bAllContentFitsContainer !== bWasFullscreenMode;
|
|
2148
2149
|
if (bFullscreenModeChanged && !this._bHeaderExpanded) {
|
|
2149
2150
|
// call the snapping function again with the *latest* parameter value
|
|
@@ -2540,15 +2541,13 @@ sap.ui.define([
|
|
|
2540
2541
|
|
|
2541
2542
|
this.iFooterHeight = this._getFooterHeight();
|
|
2542
2543
|
|
|
2543
|
-
var iSubSectionIndex = -1
|
|
2544
|
-
iSectionsContainerOffsetTop = this._$sectionsContainer.position().top;
|
|
2544
|
+
var iSubSectionIndex = -1;
|
|
2545
2545
|
|
|
2546
2546
|
this._aSectionBases.forEach(function (oSectionBase) {
|
|
2547
2547
|
var oInfo = this._oSectionInfo[oSectionBase.getId()],
|
|
2548
2548
|
$this = oSectionBase.$(),
|
|
2549
2549
|
bPromoted = false,
|
|
2550
|
-
oSection
|
|
2551
|
-
iSectionsTopMargin;
|
|
2550
|
+
oSection;
|
|
2552
2551
|
|
|
2553
2552
|
if (!oInfo /* sectionBase is visible */ || !$this.length) {
|
|
2554
2553
|
return;
|
|
@@ -2625,9 +2624,8 @@ sap.ui.define([
|
|
|
2625
2624
|
bParentIsFirstVisibleSection = bUseIconTabBar /* there is only single section per tab */ || (oSectionBase.getParent() === this._oFirstVisibleSection);
|
|
2626
2625
|
bIsFirstVisibleSubSection = bParentIsFirstVisibleSection && (iSubSectionIndex === 0); /* index of *visible* subSections is first */
|
|
2627
2626
|
bIsFullscreenSection = oSectionBase.hasStyleClass(ObjectPageSubSection.FIT_CONTAINER_CLASS);
|
|
2628
|
-
iSectionsTopMargin = oSection && oSection.$().length ? parseInt(oSection.$().css("marginTop")) : 0;
|
|
2629
2627
|
|
|
2630
|
-
oSectionBase._setHeight(this._computeSubSectionHeight(bIsFirstVisibleSubSection, bIsFullscreenSection,
|
|
2628
|
+
oSectionBase._setHeight(this._computeSubSectionHeight(bIsFirstVisibleSubSection, bIsFullscreenSection, oSectionBase));
|
|
2631
2629
|
}
|
|
2632
2630
|
|
|
2633
2631
|
}, this);
|
|
@@ -2688,14 +2686,18 @@ sap.ui.define([
|
|
|
2688
2686
|
// => wrong section may have been selected in <code>_updateSelectionOnScroll</code>
|
|
2689
2687
|
// => update the selection using the newly updated DOM positions and the current scrollTop
|
|
2690
2688
|
this._updateSelectionOnScroll(this._$opWrapper.scrollTop());
|
|
2689
|
+
this._toggleScrolling(!this._bAllContentFitsContainer || !this._getFirstVisibleSubSection()._hasRestrictedHeight());
|
|
2691
2690
|
|
|
2692
2691
|
return true; // return success flag
|
|
2693
2692
|
};
|
|
2694
2693
|
|
|
2695
|
-
ObjectPageLayout.prototype._computeSubSectionHeight = function(bFirstVisibleSubSection, bFullscreenSection,
|
|
2696
|
-
iSubSectionOffsetTop, iSectionsContainerOffsetTop, iSectionsTopMargin) {
|
|
2694
|
+
ObjectPageLayout.prototype._computeSubSectionHeight = function(bFirstVisibleSubSection, bFullscreenSection, oSectionBase) {
|
|
2697
2695
|
|
|
2698
2696
|
var iSectionsContainerHeight,
|
|
2697
|
+
oContainerDimentions,
|
|
2698
|
+
oSubSectionDimentons,
|
|
2699
|
+
iOffsetTop,
|
|
2700
|
+
iOffsetBottom,
|
|
2699
2701
|
iRemainingSectionContentHeight;
|
|
2700
2702
|
|
|
2701
2703
|
if (!bFullscreenSection) {
|
|
@@ -2719,7 +2721,11 @@ sap.ui.define([
|
|
|
2719
2721
|
if (this._bAllContentFitsContainer) {
|
|
2720
2722
|
// if we have a single fullscreen subsection [that takes the entire available height within the sections container]
|
|
2721
2723
|
// => subtract the heights above and bellow the subSection to *avoid having a scrollbar*, having in mind the top margin of the Section
|
|
2722
|
-
|
|
2724
|
+
oContainerDimentions = this._$sectionsContainer[0].getBoundingClientRect();
|
|
2725
|
+
oSubSectionDimentons = oSectionBase.getDomRef().getBoundingClientRect();
|
|
2726
|
+
iOffsetTop = oSubSectionDimentons.top - oContainerDimentions.top;
|
|
2727
|
+
iOffsetBottom = this.iFooterHeight + this._iREMSize /* footer-height + space between footer and content */;
|
|
2728
|
+
iRemainingSectionContentHeight = iOffsetTop + iOffsetBottom;
|
|
2723
2729
|
iSectionsContainerHeight -= iRemainingSectionContentHeight;
|
|
2724
2730
|
}
|
|
2725
2731
|
|
|
@@ -2923,7 +2929,10 @@ sap.ui.define([
|
|
|
2923
2929
|
|
|
2924
2930
|
ObjectPageLayout.prototype._getFirstVisibleSubSection = function (oSection) {
|
|
2925
2931
|
if (!oSection) {
|
|
2926
|
-
|
|
2932
|
+
oSection = this.getUseIconTabBar() ? this._oCurrentTabSection : this._oFirstVisibleSection;
|
|
2933
|
+
if (!oSection) {
|
|
2934
|
+
return;
|
|
2935
|
+
}
|
|
2927
2936
|
}
|
|
2928
2937
|
var oFirstSubSection;
|
|
2929
2938
|
this._aSectionBases.every(function (oSectionBase) {
|
|
@@ -3045,7 +3054,9 @@ sap.ui.define([
|
|
|
3045
3054
|
var oWrapperElement = this._$opWrapper.get(0),
|
|
3046
3055
|
oTitleElement = this._$titleArea.get(0),
|
|
3047
3056
|
iTitleHeight = oTitleElement.getBoundingClientRect().height,
|
|
3048
|
-
iTitleWidth = oTitleElement.getBoundingClientRect().width
|
|
3057
|
+
iTitleWidth = oTitleElement.getBoundingClientRect().width,
|
|
3058
|
+
iScrollbarWidth = getScrollbarSize().width,
|
|
3059
|
+
sClipPath;
|
|
3049
3060
|
|
|
3050
3061
|
// the top area of the scroll container is reserved for showing the title element,
|
|
3051
3062
|
// (where the title element is positioned absolutely on top of the scroll container),
|
|
@@ -3062,10 +3073,17 @@ sap.ui.define([
|
|
|
3062
3073
|
// (2) also make the area underneath the title invisible (using clip-path)
|
|
3063
3074
|
// to allow usage of *transparent background* of the title element
|
|
3064
3075
|
// (otherwise content from the scroll *overflow* will show underneath the transparent title element)
|
|
3065
|
-
|
|
3076
|
+
sClipPath = 'polygon(0px ' + iTitleHeight + 'px, '
|
|
3066
3077
|
+ Math.floor(iTitleWidth) + 'px ' + iTitleHeight + 'px, '
|
|
3067
3078
|
+ Math.floor(iTitleWidth) + 'px 0, 100% 0, 100% 100%, 0 100%)';
|
|
3068
3079
|
|
|
3080
|
+
if (this.oCore.getConfiguration().getRTL()) {
|
|
3081
|
+
sClipPath = 'polygon(0px 0px, ' + iScrollbarWidth + 'px 0px, '
|
|
3082
|
+
+ iScrollbarWidth + 'px ' + iTitleHeight + 'px, 100% '
|
|
3083
|
+
+ iTitleHeight + 'px, 100% 100%, 0 100%)';
|
|
3084
|
+
}
|
|
3085
|
+
oWrapperElement.style.clipPath = sClipPath;
|
|
3086
|
+
|
|
3069
3087
|
this.getHeaderTitle() && this._shiftHeaderTitle();
|
|
3070
3088
|
};
|
|
3071
3089
|
|
|
@@ -9,8 +9,9 @@ sap.ui.define([
|
|
|
9
9
|
'./library',
|
|
10
10
|
'sap/ui/core/Element',
|
|
11
11
|
'sap/ui/core/StashedControlSupport',
|
|
12
|
-
"sap/base/assert"
|
|
13
|
-
|
|
12
|
+
"sap/base/assert",
|
|
13
|
+
"sap/ui/base/Object"
|
|
14
|
+
], function (library, Element, StashedControlSupport, assert, BaseObject) {
|
|
14
15
|
"use strict";
|
|
15
16
|
|
|
16
17
|
/**
|
|
@@ -37,7 +38,7 @@ sap.ui.define([
|
|
|
37
38
|
* @extends sap.ui.core.Element
|
|
38
39
|
*
|
|
39
40
|
* @author SAP SE
|
|
40
|
-
* @version 1.
|
|
41
|
+
* @version 1.115.0
|
|
41
42
|
*
|
|
42
43
|
* @constructor
|
|
43
44
|
* @public
|
|
@@ -61,7 +62,7 @@ sap.ui.define([
|
|
|
61
62
|
StashedControlSupport.mixInto(LazyLoader);
|
|
62
63
|
|
|
63
64
|
LazyLoader.prototype.setParent = function (oParent) {
|
|
64
|
-
if (!(oParent === null || oParent
|
|
65
|
+
if (!(oParent === null || BaseObject.isA(oParent, "sap.uxap.ObjectPageSubSection"))) {
|
|
65
66
|
assert(false, "setParent(): oParent must be an instance of sap.uxap.ObjectPageSubSection or null");
|
|
66
67
|
}
|
|
67
68
|
|
|
@@ -190,7 +190,7 @@ sap.ui.define([
|
|
|
190
190
|
this._updateShowHideAllButton(false);
|
|
191
191
|
|
|
192
192
|
oHeaderDOM && oHeaderDOM.classList.toggle("sapUxAPObjectPageSectionHeaderHidden", !this._isTitleVisible());
|
|
193
|
-
oHeaderDOM && oHeaderDOM.setAttribute("aria-hidden", !this.
|
|
193
|
+
oHeaderDOM && oHeaderDOM.setAttribute("aria-hidden", !this._isTitleAriaVisible());
|
|
194
194
|
|
|
195
195
|
if (oObjectPage && this.getDomRef()) {
|
|
196
196
|
oObjectPage._requestAdjustLayout();
|
|
@@ -324,9 +324,26 @@ sap.ui.define([
|
|
|
324
324
|
* @returns {boolean}
|
|
325
325
|
*/
|
|
326
326
|
ObjectPageSection.prototype._isTitleVisible = function () {
|
|
327
|
-
return (this.getShowTitle() && this._getInternalTitleVisible())
|
|
328
|
-
|
|
329
|
-
|
|
327
|
+
return (this.getShowTitle() && this._getInternalTitleVisible()) || this._getInternalTitleForceVisible();
|
|
328
|
+
};
|
|
329
|
+
|
|
330
|
+
/**
|
|
331
|
+
* Determines if the <code>ObjectPageSection</code> title is visible for the aria.
|
|
332
|
+
* @private
|
|
333
|
+
* @returns {boolean}
|
|
334
|
+
*/
|
|
335
|
+
ObjectPageSection.prototype._isTitleAriaVisible = function () {
|
|
336
|
+
return this.getShowTitle() || this._getInternalTitleForceVisible();
|
|
337
|
+
};
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* Determines if the <code>ObjectPageSection</code> title is forced to be visible.
|
|
341
|
+
* This is the case when the <code>ObjectPageSection</code> displays the expand/collapse button or the show/hide all button.
|
|
342
|
+
* @private
|
|
343
|
+
* @returns {boolean}
|
|
344
|
+
*/
|
|
345
|
+
ObjectPageSection.prototype._getInternalTitleForceVisible = function () {
|
|
346
|
+
return this._getShouldDisplayExpandCollapseButton() || this._getShouldDisplayShowHideAllButton();
|
|
330
347
|
};
|
|
331
348
|
|
|
332
349
|
/**
|
|
@@ -16,7 +16,7 @@ sap.ui.define(["sap/ui/core/Configuration"], function (Configuration) {
|
|
|
16
16
|
};
|
|
17
17
|
|
|
18
18
|
ObjectPageSectionRenderer.render = function (oRm, oControl) {
|
|
19
|
-
var sTitle, bTitleVisible,
|
|
19
|
+
var sTitle, bTitleVisible, bTitleAriaHidden,
|
|
20
20
|
bAccessibilityOn = Configuration.getAccessibility(),
|
|
21
21
|
oLabelledBy = oControl.getAggregation("ariaLabelledBy"),
|
|
22
22
|
oHeading = oControl.getHeading(),
|
|
@@ -28,6 +28,7 @@ sap.ui.define(["sap/ui/core/Configuration"], function (Configuration) {
|
|
|
28
28
|
|
|
29
29
|
sTitle = oControl._getTitle();
|
|
30
30
|
bTitleVisible = oControl._isTitleVisible();
|
|
31
|
+
bTitleAriaHidden = !oControl._isTitleAriaVisible();
|
|
31
32
|
|
|
32
33
|
oRm.openStart("section", oControl)
|
|
33
34
|
.class("sapUxAPObjectPageSection");
|
|
@@ -61,10 +62,14 @@ sap.ui.define(["sap/ui/core/Configuration"], function (Configuration) {
|
|
|
61
62
|
oRm.openStart("div", oControl.getId() + "-header")
|
|
62
63
|
.attr("role", "heading")
|
|
63
64
|
.attr("aria-level", oControl._getARIALevel())
|
|
64
|
-
.attr("aria-hidden", !bTitleVisible)
|
|
65
65
|
.class("sapUxAPObjectPageSectionHeader")
|
|
66
|
-
.class(bTitleVisible ? "" : "sapUxAPObjectPageSectionHeaderHidden")
|
|
67
|
-
|
|
66
|
+
.class(bTitleVisible ? "" : "sapUxAPObjectPageSectionHeaderHidden");
|
|
67
|
+
|
|
68
|
+
if (bTitleAriaHidden) {
|
|
69
|
+
oRm.attr("aria-hidden", "true");
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
oRm.openEnd();
|
|
68
73
|
|
|
69
74
|
oRm.openStart("div", oControl.getId() + "-title")
|
|
70
75
|
.class("sapUxAPObjectPageSectionTitle");
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
sap.ui.define([
|
|
9
9
|
"sap/ui/thirdparty/jquery",
|
|
10
10
|
"sap/ui/core/Core",
|
|
11
|
+
"sap/ui/core/ResizeHandler",
|
|
11
12
|
"./ObjectPageSectionBase",
|
|
12
13
|
"./ObjectPageLazyLoader",
|
|
13
14
|
"./BlockBase",
|
|
@@ -26,6 +27,7 @@ sap.ui.define([
|
|
|
26
27
|
], function(
|
|
27
28
|
jQuery,
|
|
28
29
|
Core,
|
|
30
|
+
ResizeHandler,
|
|
29
31
|
ObjectPageSectionBase,
|
|
30
32
|
ObjectPageLazyLoader,
|
|
31
33
|
BlockBase,
|
|
@@ -314,10 +316,26 @@ sap.ui.define([
|
|
|
314
316
|
|
|
315
317
|
oDom = this.getDomRef();
|
|
316
318
|
if (oDom) {
|
|
317
|
-
oDom.style.height =
|
|
319
|
+
oDom.style.height = this._height;
|
|
320
|
+
this._adaptDomHeight();
|
|
318
321
|
}
|
|
319
322
|
};
|
|
320
323
|
|
|
324
|
+
ObjectPageSubSection.prototype._toggleContentResizeListener = function(bEnable) {
|
|
325
|
+
if (bEnable && !this._iResizeId) {
|
|
326
|
+
this._iResizeId = ResizeHandler.register(this._getContentWrapper(), this._adaptDomHeight.bind(this));
|
|
327
|
+
}
|
|
328
|
+
if (!bEnable && this._iResizeId) {
|
|
329
|
+
ResizeHandler.deregister(this._iResizeId);
|
|
330
|
+
this._iResizeId = null;
|
|
331
|
+
}
|
|
332
|
+
};
|
|
333
|
+
|
|
334
|
+
ObjectPageSubSection.prototype._getContentWrapper = function() {
|
|
335
|
+
return this.getAggregation("_grid");
|
|
336
|
+
};
|
|
337
|
+
|
|
338
|
+
|
|
321
339
|
/**
|
|
322
340
|
* Returns the control name text.
|
|
323
341
|
*
|
|
@@ -589,6 +607,10 @@ sap.ui.define([
|
|
|
589
607
|
return;
|
|
590
608
|
}
|
|
591
609
|
|
|
610
|
+
if (this.hasStyleClass(ObjectPageSubSection.FIT_CONTAINER_CLASS)) {
|
|
611
|
+
this._toggleContentResizeListener(true);
|
|
612
|
+
}
|
|
613
|
+
|
|
592
614
|
this._$spacer = oObjectPageLayout.$("spacer");
|
|
593
615
|
|
|
594
616
|
if (this._bShouldFocusSeeMoreLessButton && document.activeElement === document.body) {
|
|
@@ -609,10 +631,32 @@ sap.ui.define([
|
|
|
609
631
|
ObjectPageSectionBase.prototype.onBeforeRendering.call(this);
|
|
610
632
|
}
|
|
611
633
|
|
|
634
|
+
this._toggleContentResizeListener(false);
|
|
635
|
+
|
|
612
636
|
this._setAggregationProxy();
|
|
613
637
|
this._getGrid().removeAllContent();
|
|
614
638
|
this._applyLayout(oObjectPageLayout);
|
|
615
639
|
this.refreshSeeMoreVisibility();
|
|
640
|
+
|
|
641
|
+
this.toggleStyleClass("sapUxAPObjectPageSubSectionStashed", this._aStashedControls.length ? true : false);
|
|
642
|
+
};
|
|
643
|
+
|
|
644
|
+
ObjectPageSubSection.prototype._adaptDomHeight = function() {
|
|
645
|
+
var oDom = this.getDomRef();
|
|
646
|
+
if (!oDom) {
|
|
647
|
+
return;
|
|
648
|
+
}
|
|
649
|
+
if (this.hasStyleClass(ObjectPageSubSection.FIT_CONTAINER_CLASS) && this._height) {
|
|
650
|
+
oDom.style.height = (oDom.scrollHeight > Math.ceil(parseFloat(this._height))) ? "" : this._height;
|
|
651
|
+
}
|
|
652
|
+
};
|
|
653
|
+
|
|
654
|
+
ObjectPageSubSection.prototype._hasRestrictedHeight = function() {
|
|
655
|
+
var oDom = this.getDomRef();
|
|
656
|
+
if (!oDom) {
|
|
657
|
+
return;
|
|
658
|
+
}
|
|
659
|
+
return parseInt(oDom.style.height) > 0;
|
|
616
660
|
};
|
|
617
661
|
|
|
618
662
|
ObjectPageSubSection.prototype._applyLayout = function (oLayoutProvider) {
|
|
@@ -886,7 +930,7 @@ sap.ui.define([
|
|
|
886
930
|
this._setAggregation(sAggregationName, aAggregation, bSuppressInvalidate);
|
|
887
931
|
|
|
888
932
|
if (oObject instanceof BlockBase || oObject instanceof ObjectPageLazyLoader) {
|
|
889
|
-
oObject.setParent(this); //let the block know of its parent subsection
|
|
933
|
+
oObject.setParent(this, "blocks"); //let the block know of its parent subsection
|
|
890
934
|
}
|
|
891
935
|
|
|
892
936
|
} else {
|
|
@@ -953,22 +997,23 @@ sap.ui.define([
|
|
|
953
997
|
return ObjectPageSectionBase.prototype.removeAllAggregation.apply(this, arguments);
|
|
954
998
|
};
|
|
955
999
|
|
|
956
|
-
ObjectPageSubSection.prototype.removeAggregation = function (sAggregationName,
|
|
957
|
-
var bRemoved = false,
|
|
1000
|
+
ObjectPageSubSection.prototype.removeAggregation = function (sAggregationName, vObject) {
|
|
1001
|
+
var bRemoved = false,
|
|
1002
|
+
aInternalAggregation;
|
|
958
1003
|
|
|
959
|
-
if (this.hasProxy(sAggregationName)) {
|
|
1004
|
+
if (this.hasProxy(sAggregationName) && typeof vObject === "object") {
|
|
960
1005
|
aInternalAggregation = this._getAggregation(sAggregationName);
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
1006
|
+
aInternalAggregation.forEach(function (oObjectCandidate, iIndex) {
|
|
1007
|
+
if (oObjectCandidate.getId() === vObject.getId()) {
|
|
1008
|
+
aInternalAggregation.splice(iIndex, 1);
|
|
1009
|
+
this._onRemoveBlock(vObject);
|
|
1010
|
+
this._setAggregation(sAggregationName, aInternalAggregation);
|
|
1011
|
+
bRemoved = true;
|
|
1012
|
+
}
|
|
1013
|
+
return !bRemoved;
|
|
1014
|
+
}, this);
|
|
970
1015
|
|
|
971
|
-
return (bRemoved ?
|
|
1016
|
+
return (bRemoved ? vObject : null);
|
|
972
1017
|
}
|
|
973
1018
|
|
|
974
1019
|
return ObjectPageSectionBase.prototype.removeAggregation.apply(this, arguments);
|
|
@@ -5,10 +5,12 @@
|
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
7
|
sap.ui.define([
|
|
8
|
+
"sap/ui/core/util/reflection/JsControlTreeModifier",
|
|
8
9
|
"sap/ui/fl/changeHandler/AddIFrame",
|
|
9
10
|
"sap/ui/fl/changeHandler/common/getTargetAggregationIndex",
|
|
10
11
|
"sap/ui/fl/changeHandler/common/createIFrame"
|
|
11
12
|
], function (
|
|
13
|
+
JsControlTreeModifier,
|
|
12
14
|
BaseAddIFrame,
|
|
13
15
|
getTargetAggregationIndex,
|
|
14
16
|
createIFrame
|
|
@@ -21,7 +23,7 @@ sap.ui.define([
|
|
|
21
23
|
* @constructor
|
|
22
24
|
* @alias sap.uxap.changeHandler.AddIFrameObjectPageLayout
|
|
23
25
|
* @author SAP SE
|
|
24
|
-
* @version 1.
|
|
26
|
+
* @version 1.115.0
|
|
25
27
|
* @since 1.75
|
|
26
28
|
* @experimental Since 1.75
|
|
27
29
|
*/
|
|
@@ -106,5 +108,29 @@ sap.ui.define([
|
|
|
106
108
|
return oCondenserInfo;
|
|
107
109
|
};
|
|
108
110
|
|
|
111
|
+
AddIFrameObjectPageLayout.getChangeVisualizationInfo = function(oChange, oAppComponent) {
|
|
112
|
+
var oSelector = oChange.getContent().selector;
|
|
113
|
+
var oElement = JsControlTreeModifier.bySelector(oSelector, oAppComponent);
|
|
114
|
+
var oAnchorBar = oElement.getParent().getAggregation("_anchorBar");
|
|
115
|
+
var aAffectedControls = [oSelector];
|
|
116
|
+
var aDisplayControls = [oSelector];
|
|
117
|
+
|
|
118
|
+
oAnchorBar.getAggregation("content").forEach(function(oAnchorBarItem) {
|
|
119
|
+
oAnchorBarItem.getAggregation("customData").some(function(oCustomData) {
|
|
120
|
+
if (
|
|
121
|
+
oCustomData.getKey() === "sectionId" &&
|
|
122
|
+
oElement.getId() === oCustomData.getProperty("value")
|
|
123
|
+
) {
|
|
124
|
+
aDisplayControls.push(oAnchorBarItem.getId());
|
|
125
|
+
}
|
|
126
|
+
});
|
|
127
|
+
});
|
|
128
|
+
|
|
129
|
+
return {
|
|
130
|
+
affectedControls: aAffectedControls,
|
|
131
|
+
displayControls: aDisplayControls
|
|
132
|
+
};
|
|
133
|
+
};
|
|
134
|
+
|
|
109
135
|
return AddIFrameObjectPageLayout;
|
|
110
136
|
}, /* bExport= */true);
|
|
@@ -4,7 +4,17 @@
|
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
sap.ui.define([
|
|
7
|
+
sap.ui.define([
|
|
8
|
+
"sap/base/util/merge",
|
|
9
|
+
"sap/ui/core/Core",
|
|
10
|
+
"sap/ui/core/util/reflection/JsControlTreeModifier",
|
|
11
|
+
"sap/ui/fl/changeHandler/MoveControls"
|
|
12
|
+
], function(
|
|
13
|
+
merge,
|
|
14
|
+
Core,
|
|
15
|
+
JsControlTreeModifier,
|
|
16
|
+
MoveControls
|
|
17
|
+
) {
|
|
8
18
|
"use strict";
|
|
9
19
|
|
|
10
20
|
/**
|
|
@@ -13,11 +23,11 @@ sap.ui.define(["sap/ui/fl/changeHandler/MoveControls", "sap/ui/core/Core", "sap/
|
|
|
13
23
|
* @constructor
|
|
14
24
|
* @alias sap.uxap.changeHandler.MoveObjectPageSection
|
|
15
25
|
* @author SAP SE
|
|
16
|
-
* @version 1.
|
|
26
|
+
* @version 1.115.0
|
|
17
27
|
* @experimental Since 1.54
|
|
18
28
|
*/
|
|
19
29
|
|
|
20
|
-
var MoveObjectPageSection =
|
|
30
|
+
var MoveObjectPageSection = Object.assign({}, MoveControls);
|
|
21
31
|
|
|
22
32
|
MoveObjectPageSection.applyChange = function (oChange, oControl, mPropertyBag) {
|
|
23
33
|
var bJsControllTree = mPropertyBag.modifier.targets === "jsControlTree";
|
|
@@ -77,6 +87,7 @@ sap.ui.define(["sap/ui/fl/changeHandler/MoveControls", "sap/ui/core/Core", "sap/
|
|
|
77
87
|
*
|
|
78
88
|
* @param {object} mSpecificChangeInfo - Information needed to create the change
|
|
79
89
|
* @param {object} mPropertyBag - Object additional properties like modifier or appComponent
|
|
90
|
+
* @returns {Promise} resolves if change could be applied
|
|
80
91
|
* @private
|
|
81
92
|
*/
|
|
82
93
|
MoveObjectPageSection._mapAnchorsToSections = function (mSpecificChangeInfo, mPropertyBag) {
|
|
@@ -123,6 +134,45 @@ sap.ui.define(["sap/ui/fl/changeHandler/MoveControls", "sap/ui/core/Core", "sap/
|
|
|
123
134
|
});
|
|
124
135
|
};
|
|
125
136
|
|
|
137
|
+
/**
|
|
138
|
+
* Retrieves the information required for the change visualization.
|
|
139
|
+
*
|
|
140
|
+
* @param {sap.ui.fl.apply._internal.flexObjects.FlexObject} oChange - Object with change data
|
|
141
|
+
* @param {sap.ui.core.UIComponent} oAppComponent Component in which the change is applied
|
|
142
|
+
* @returns {object} Object with a description payload containing the information required for the change visualization
|
|
143
|
+
* @public
|
|
144
|
+
*/
|
|
145
|
+
MoveObjectPageSection.getChangeVisualizationInfo = function(oChange, oAppComponent) {
|
|
146
|
+
var oChangeContent = oChange.getContent();
|
|
147
|
+
var oRevertData = oChange.getRevertData()[0];
|
|
148
|
+
var oMovedElementSelector = oChangeContent.movedElements[0].selector;
|
|
149
|
+
var oMovedElement = JsControlTreeModifier.bySelector(oMovedElementSelector, oAppComponent);
|
|
150
|
+
var oAnchorBar = oMovedElement.getParent().getAggregation("_anchorBar");
|
|
151
|
+
var aAffectedControls = [oMovedElementSelector];
|
|
152
|
+
var aDisplayControls = [oMovedElementSelector];
|
|
153
|
+
|
|
154
|
+
oAnchorBar.getAggregation("content").forEach(function(oAnchorBarItem) {
|
|
155
|
+
oAnchorBarItem.getAggregation("customData").some(function(oCustomData) {
|
|
156
|
+
if (
|
|
157
|
+
oCustomData.getKey() === "sectionId" &&
|
|
158
|
+
oMovedElement.getId() === oCustomData.getProperty("value")
|
|
159
|
+
) {
|
|
160
|
+
aDisplayControls.push(oAnchorBarItem.getId());
|
|
161
|
+
}
|
|
162
|
+
});
|
|
163
|
+
});
|
|
164
|
+
|
|
165
|
+
return {
|
|
166
|
+
affectedControls: aAffectedControls,
|
|
167
|
+
displayControls: aDisplayControls,
|
|
168
|
+
dependentControls: [oChangeContent.source.selector],
|
|
169
|
+
descriptionPayload: {
|
|
170
|
+
sourceContainer: oRevertData.sourceParent,
|
|
171
|
+
targetContainer: oChangeContent.target.selector
|
|
172
|
+
}
|
|
173
|
+
};
|
|
174
|
+
};
|
|
175
|
+
|
|
126
176
|
return MoveObjectPageSection;
|
|
127
177
|
},
|
|
128
178
|
/* bExport= */true);
|
|
@@ -6,9 +6,11 @@
|
|
|
6
6
|
|
|
7
7
|
sap.ui.define([
|
|
8
8
|
"sap/base/Log",
|
|
9
|
+
"sap/ui/core/util/reflection/JsControlTreeModifier",
|
|
9
10
|
"sap/ui/fl/changeHandler/BaseRename"
|
|
10
11
|
], function (
|
|
11
12
|
Log,
|
|
13
|
+
JsControlTreeModifier,
|
|
12
14
|
BaseRename
|
|
13
15
|
) {
|
|
14
16
|
"use strict";
|
|
@@ -19,7 +21,7 @@ sap.ui.define([
|
|
|
19
21
|
* @constructor
|
|
20
22
|
* @alias sap.uxap.changeHandler.RenameObjectPageSection
|
|
21
23
|
* @author SAP SE
|
|
22
|
-
* @version 1.
|
|
24
|
+
* @version 1.115.0
|
|
23
25
|
* @experimental Since 1.50
|
|
24
26
|
*/
|
|
25
27
|
|
|
@@ -106,6 +108,43 @@ sap.ui.define([
|
|
|
106
108
|
});
|
|
107
109
|
};
|
|
108
110
|
|
|
111
|
+
/**
|
|
112
|
+
* Retrieves the information required for the change visualization.
|
|
113
|
+
*
|
|
114
|
+
* @param {sap.ui.fl.apply._internal.flexObjects.FlexObject} oChange - Object with change data
|
|
115
|
+
* @param {sap.ui.core.UIComponent} oAppComponent Component in which the change is applied
|
|
116
|
+
* @returns {object} Object with a description payload containing the information required for the change visualization
|
|
117
|
+
* @public
|
|
118
|
+
*/
|
|
119
|
+
RenameObjectPageSection.getChangeVisualizationInfo = function(oChange, oAppComponent) {
|
|
120
|
+
var oNewLabel = (
|
|
121
|
+
oChange.getTexts()
|
|
122
|
+
&& oChange.getTexts()[mRenameSettings.changePropertyName]
|
|
123
|
+
);
|
|
124
|
+
var oSelector = oChange.getSelector();
|
|
125
|
+
var oElement = JsControlTreeModifier.bySelector(oSelector, oAppComponent);
|
|
126
|
+
var oAnchorBar = oElement.getParent().getAggregation("_anchorBar");
|
|
127
|
+
var aAffectedControls = [oElement.getId()];
|
|
128
|
+
var aDisplayControls = [oElement.getId()];
|
|
129
|
+
oAnchorBar.getAggregation("content").forEach(function(oAnchorBarItem) {
|
|
130
|
+
oAnchorBarItem.getAggregation("customData").some(function(oCustomData) {
|
|
131
|
+
if (
|
|
132
|
+
oCustomData.getKey() === "sectionId" &&
|
|
133
|
+
oElement.getId() === oCustomData.getProperty("value")
|
|
134
|
+
) {
|
|
135
|
+
aDisplayControls.push(oAnchorBarItem.getId());
|
|
136
|
+
}
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
return {
|
|
140
|
+
descriptionPayload: {
|
|
141
|
+
originalLabel: oChange.getRevertData(),
|
|
142
|
+
newLabel: oNewLabel && oNewLabel.value
|
|
143
|
+
},
|
|
144
|
+
affectedControls: aAffectedControls,
|
|
145
|
+
displayControls: aDisplayControls
|
|
146
|
+
};
|
|
147
|
+
};
|
|
109
148
|
|
|
110
149
|
return RenameObjectPageSection;
|
|
111
150
|
},
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* OpenUI5
|
|
3
|
+
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
sap.ui.define([
|
|
8
|
+
"sap/ui/core/util/reflection/JsControlTreeModifier",
|
|
9
|
+
"sap/ui/fl/changeHandler/UnstashControl"
|
|
10
|
+
], function(
|
|
11
|
+
JsControlTreeModifier,
|
|
12
|
+
UnstashControl
|
|
13
|
+
) {
|
|
14
|
+
"use strict";
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* ObjectPageSection Change Handler for Unstash
|
|
18
|
+
*
|
|
19
|
+
* @constructor
|
|
20
|
+
* @alias sap.uxap.changeHandler.UnstashObjectPageSection
|
|
21
|
+
* @author SAP SE
|
|
22
|
+
* @version 1.115.0
|
|
23
|
+
* @experimental Since 1.115
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
var UnstashObjectPageSection = Object.assign({}, UnstashControl);
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Retrieves the information required for the change visualization.
|
|
30
|
+
*
|
|
31
|
+
* @param {sap.ui.fl.apply._internal.flexObjects.FlexObject} oChange - Object with change data
|
|
32
|
+
* @param {sap.ui.core.UIComponent} oAppComponent Component in which the change is applied
|
|
33
|
+
* @returns {object} Object with a description payload containing the information required for the change visualization
|
|
34
|
+
* @public
|
|
35
|
+
*/
|
|
36
|
+
UnstashObjectPageSection.getChangeVisualizationInfo = function(oChange, oAppComponent) {
|
|
37
|
+
var oStashedElementSelector = oChange.getSelector();
|
|
38
|
+
var oStashedElement = JsControlTreeModifier.bySelector(oStashedElementSelector, oAppComponent);
|
|
39
|
+
var oAnchorBar = oStashedElement.getParent().getAggregation("_anchorBar");
|
|
40
|
+
var aAffectedControls = [oStashedElementSelector];
|
|
41
|
+
var aDisplayControls = [oStashedElementSelector];
|
|
42
|
+
|
|
43
|
+
oAnchorBar.getAggregation("content").forEach(function(oAnchorBarItem) {
|
|
44
|
+
oAnchorBarItem.getAggregation("customData").some(function(oCustomData) {
|
|
45
|
+
if (
|
|
46
|
+
oCustomData.getKey() === "sectionId" &&
|
|
47
|
+
oStashedElement.getId() === oCustomData.getProperty("value")
|
|
48
|
+
) {
|
|
49
|
+
aDisplayControls.push(oAnchorBarItem.getId());
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
|
|
54
|
+
return {
|
|
55
|
+
affectedControls: aAffectedControls,
|
|
56
|
+
displayControls: aDisplayControls
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
return UnstashObjectPageSection;
|
|
61
|
+
},
|
|
62
|
+
/* bExport= */true);
|
|
@@ -9,6 +9,17 @@ sap.ui.define(["sap/uxap/library"],
|
|
|
9
9
|
function(library) {
|
|
10
10
|
"use strict";
|
|
11
11
|
|
|
12
|
+
function fnGetLabel(oObjectPageSection) {
|
|
13
|
+
var sTitle = oObjectPageSection.getTitle();
|
|
14
|
+
var aSubSection = oObjectPageSection.getSubSections();
|
|
15
|
+
// If there is only one SubSection, its title is shown,
|
|
16
|
+
// instead of the title of the Section (if it is available).
|
|
17
|
+
if (aSubSection.length === 1 && aSubSection[0].getTitle().trim() !== "") {
|
|
18
|
+
sTitle = aSubSection[0].getTitle();
|
|
19
|
+
}
|
|
20
|
+
return sTitle || oObjectPageSection.getId();
|
|
21
|
+
}
|
|
22
|
+
|
|
12
23
|
return {
|
|
13
24
|
name : {
|
|
14
25
|
singular : function(){
|
|
@@ -28,29 +39,21 @@ sap.ui.define(["sap/uxap/library"],
|
|
|
28
39
|
svg: "sap/uxap/designtime/ObjectPageSection.icon.svg"
|
|
29
40
|
}
|
|
30
41
|
},
|
|
42
|
+
getLabel: fnGetLabel,
|
|
31
43
|
actions : {
|
|
32
44
|
remove : {
|
|
33
45
|
changeType : "stashControl"
|
|
34
46
|
},
|
|
35
47
|
reveal : {
|
|
36
48
|
changeType : "unstashControl",
|
|
37
|
-
getLabel:
|
|
38
|
-
var sTitle = oControl.getTitle();
|
|
39
|
-
var aSubSection = oControl.getSubSections();
|
|
40
|
-
// If there is only one SubSection, its title is shown in the AnchorBar,
|
|
41
|
-
// instead of the title of the Section (if it is available).
|
|
42
|
-
if (aSubSection.length === 1 && aSubSection[0].getTitle().trim() !== "") {
|
|
43
|
-
sTitle = aSubSection[0].getTitle();
|
|
44
|
-
}
|
|
45
|
-
return sTitle || oControl.getId();
|
|
46
|
-
}
|
|
49
|
+
getLabel: fnGetLabel
|
|
47
50
|
},
|
|
48
51
|
rename: function () {
|
|
49
52
|
return {
|
|
50
53
|
changeType: "rename",
|
|
51
54
|
domRef: ".sapUxAPObjectPageSectionTitle",
|
|
52
55
|
isEnabled: function (oElement) {
|
|
53
|
-
return oElement.
|
|
56
|
+
return oElement._getInternalTitleVisible();
|
|
54
57
|
},
|
|
55
58
|
validators: [
|
|
56
59
|
"noEmptyText"
|
|
@@ -5,8 +5,12 @@
|
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
7
|
sap.ui.define([
|
|
8
|
-
'sap/uxap/changeHandler/RenameObjectPageSection'
|
|
9
|
-
|
|
8
|
+
'sap/uxap/changeHandler/RenameObjectPageSection',
|
|
9
|
+
'sap/uxap/changeHandler/UnstashObjectPageSection'
|
|
10
|
+
], function (
|
|
11
|
+
RenameObjectPageSection,
|
|
12
|
+
UnstashObjectPageSection
|
|
13
|
+
) {
|
|
10
14
|
"use strict";
|
|
11
15
|
|
|
12
16
|
return {
|
|
@@ -31,7 +35,7 @@ sap.ui.define([
|
|
|
31
35
|
}
|
|
32
36
|
},
|
|
33
37
|
"unstashControl": {
|
|
34
|
-
"changeHandler":
|
|
38
|
+
"changeHandler": UnstashObjectPageSection,
|
|
35
39
|
"layers": {
|
|
36
40
|
"USER": true
|
|
37
41
|
}
|
package/src/sap/uxap/library.js
CHANGED
|
@@ -12,11 +12,16 @@ sap.ui.define([
|
|
|
12
12
|
"sap/ui/base/DataType",
|
|
13
13
|
"sap/ui/Device",
|
|
14
14
|
"sap/ui/thirdparty/jquery",
|
|
15
|
-
"sap/ui/
|
|
16
|
-
|
|
17
|
-
"sap/
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
"sap/ui/base/Object",
|
|
16
|
+
// library dependency
|
|
17
|
+
"sap/ui/core/library",
|
|
18
|
+
// library dependency
|
|
19
|
+
"sap/f/library",
|
|
20
|
+
// library dependency
|
|
21
|
+
"sap/m/library",
|
|
22
|
+
// library dependency
|
|
23
|
+
"sap/ui/layout/library"
|
|
24
|
+
], function(Core, DataType, Device, jQuery, BaseObject) {
|
|
20
25
|
"use strict";
|
|
21
26
|
|
|
22
27
|
/**
|
|
@@ -25,7 +30,7 @@ sap.ui.define([
|
|
|
25
30
|
* @namespace
|
|
26
31
|
* @alias sap.uxap
|
|
27
32
|
* @author SAP SE
|
|
28
|
-
* @version 1.
|
|
33
|
+
* @version 1.115.0
|
|
29
34
|
* @since 1.36
|
|
30
35
|
* @public
|
|
31
36
|
*/
|
|
@@ -68,7 +73,7 @@ sap.ui.define([
|
|
|
68
73
|
"sap.uxap.ObjectPageHeaderLayoutData",
|
|
69
74
|
"sap.uxap.ObjectPageLazyLoader"
|
|
70
75
|
],
|
|
71
|
-
version: "1.
|
|
76
|
+
version: "1.115.0",
|
|
72
77
|
extensions: {
|
|
73
78
|
flChangeHandlers: {
|
|
74
79
|
"sap.uxap.ObjectPageHeader": "sap/uxap/flexibility/ObjectPageHeader",
|
|
@@ -299,7 +304,7 @@ sap.ui.define([
|
|
|
299
304
|
*/
|
|
300
305
|
getClosestOPL: function (oControl) {
|
|
301
306
|
|
|
302
|
-
while (oControl && !(oControl
|
|
307
|
+
while (oControl && !(BaseObject.isA(oControl, "sap.uxap.ObjectPageLayout"))) {
|
|
303
308
|
oControl = oControl.getParent();
|
|
304
309
|
}
|
|
305
310
|
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
/**
|
|
7
7
|
* Defines support rules of the ObjectPageHeader control of sap.uxap library.
|
|
8
8
|
*/
|
|
9
|
-
sap.ui.define(["sap/ui/support/library"],
|
|
10
|
-
function (SupportLib) {
|
|
9
|
+
sap.ui.define(["sap/ui/support/library", "sap/ui/base/Object"],
|
|
10
|
+
function (SupportLib, BaseObject) {
|
|
11
11
|
"use strict";
|
|
12
12
|
|
|
13
13
|
// shortcuts
|
|
@@ -44,7 +44,7 @@ sap.ui.define(["sap/ui/support/library"],
|
|
|
44
44
|
|
|
45
45
|
var parent = oControl.getParent();
|
|
46
46
|
while (parent) {
|
|
47
|
-
if (parent
|
|
47
|
+
if (BaseObject.isA(parent, "sap.ui.core.Component")) {
|
|
48
48
|
return parent;
|
|
49
49
|
} else {
|
|
50
50
|
parent = parent.getParent();
|
|
@@ -8,9 +8,9 @@
|
|
|
8
8
|
box-sizing: border-box;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
.sapUxAPObjectPageSubSection .sapUxAPBlockContainer > .sapUiRespGrid:empty,
|
|
11
|
+
.sapUxAPObjectPageSubSection.sapUxAPObjectPageSubSectionStashed .sapUxAPBlockContainer > .sapUiRespGrid:empty,
|
|
12
12
|
/* Blockbase is used */
|
|
13
|
-
.sapUxAPObjectPageSubSection .sapUxAPBlockContainer > .sapUiRespGrid > div > div:empty {
|
|
13
|
+
.sapUxAPObjectPageSubSection.sapUxAPObjectPageSubSectionStashed .sapUxAPBlockContainer > .sapUiRespGrid > div > div:empty {
|
|
14
14
|
height: 20vh;
|
|
15
15
|
}
|
|
16
16
|
|
|
@@ -177,9 +177,11 @@ Doing so will result in less generated CSS, as well as less future maintanance i
|
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
179
|
|
|
180
|
-
.sapUxAPObjectPageSubSectionFitContainer {
|
|
181
|
-
overflow-y: hidden;
|
|
180
|
+
.sapUxAPObjectPageSubSectionFitContainer .sapUxAPBlockContainer .sapUxAPBlockBase {
|
|
181
|
+
overflow-y: hidden;
|
|
182
|
+
}
|
|
182
183
|
|
|
184
|
+
.sapUxAPObjectPageSubSectionFitContainer {
|
|
183
185
|
.sapUxAPBlockContainer,
|
|
184
186
|
.sapUxAPBlockContainer > .sapUiRespGrid,
|
|
185
187
|
.sapUxAPBlockContainer > .sapUiRespGrid > *,
|