@openui5/sap.ui.webc.common 1.111.6 → 1.112.1

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 (154) hide show
  1. package/package.json +2 -2
  2. package/src/sap/ui/webc/common/.library +2 -2
  3. package/src/sap/ui/webc/common/Configuration.js +6 -0
  4. package/src/sap/ui/webc/common/Icons.js +6 -0
  5. package/src/sap/ui/webc/common/WebComponent.js +1 -1
  6. package/src/sap/ui/webc/common/WebComponentMetadata.js +1 -1
  7. package/src/sap/ui/webc/common/library.js +3 -3
  8. package/src/sap/ui/webc/common/thirdparty/base/Boot.js +2 -11
  9. package/src/sap/ui/webc/common/thirdparty/base/CSP.js +3 -14
  10. package/src/sap/ui/webc/common/thirdparty/base/CustomElementsRegistry.js +0 -21
  11. package/src/sap/ui/webc/common/thirdparty/base/CustomElementsScopeUtils.js +5 -22
  12. package/src/sap/ui/webc/common/thirdparty/base/DOMObserver.js +5 -18
  13. package/src/sap/ui/webc/common/thirdparty/base/Device.js +2 -35
  14. package/src/sap/ui/webc/common/thirdparty/base/EventProvider.js +2 -21
  15. package/src/sap/ui/webc/common/thirdparty/base/FeaturesRegistry.js +0 -4
  16. package/src/sap/ui/webc/common/thirdparty/base/FontFace.js +4 -8
  17. package/src/sap/ui/webc/common/thirdparty/base/InitialConfiguration.js +13 -42
  18. package/src/sap/ui/webc/common/thirdparty/base/Keys.js +3 -138
  19. package/src/sap/ui/webc/common/thirdparty/base/ManagedStyles.js +0 -19
  20. package/src/sap/ui/webc/common/thirdparty/base/MediaRange.js +4 -8
  21. package/src/sap/ui/webc/common/thirdparty/base/PropertiesFileFormat.js +2 -16
  22. package/src/sap/ui/webc/common/thirdparty/base/Render.js +14 -35
  23. package/src/sap/ui/webc/common/thirdparty/base/RenderQueue.js +1 -16
  24. package/src/sap/ui/webc/common/thirdparty/base/RenderScheduler.js +2 -10
  25. package/src/sap/ui/webc/common/thirdparty/base/Runtimes.js +18 -34
  26. package/src/sap/ui/webc/common/thirdparty/base/StaticAreaItem.js +4 -25
  27. package/src/sap/ui/webc/common/thirdparty/base/SystemCSSVars.js +0 -3
  28. package/src/sap/ui/webc/common/thirdparty/base/UI5Element.js +104 -246
  29. package/src/sap/ui/webc/common/thirdparty/base/UI5ElementMetadata.js +39 -84
  30. package/src/sap/ui/webc/common/thirdparty/base/animations/AnimationQueue.js +0 -11
  31. package/src/sap/ui/webc/common/thirdparty/base/animations/animate.js +0 -8
  32. package/src/sap/ui/webc/common/thirdparty/base/animations/scroll.js +0 -4
  33. package/src/sap/ui/webc/common/thirdparty/base/animations/slideDown.js +9 -10
  34. package/src/sap/ui/webc/common/thirdparty/base/animations/slideUp.js +4 -7
  35. package/src/sap/ui/webc/common/thirdparty/base/asset-registries/Icons.js +9 -34
  36. package/src/sap/ui/webc/common/thirdparty/base/asset-registries/Illustrations.js +0 -8
  37. package/src/sap/ui/webc/common/thirdparty/base/asset-registries/LocaleData.js +36 -57
  38. package/src/sap/ui/webc/common/thirdparty/base/asset-registries/Themes.js +4 -27
  39. package/src/sap/ui/webc/common/thirdparty/base/asset-registries/i18n.js +12 -37
  40. package/src/sap/ui/webc/common/thirdparty/base/assets-meta/IconCollectionsAlias.js +0 -1
  41. package/src/sap/ui/webc/common/thirdparty/base/config/AnimationMode.js +0 -7
  42. package/src/sap/ui/webc/common/thirdparty/base/config/CalendarType.js +2 -7
  43. package/src/sap/ui/webc/common/thirdparty/base/config/FormatSettings.js +2 -4
  44. package/src/sap/ui/webc/common/thirdparty/base/config/Icons.js +3 -11
  45. package/src/sap/ui/webc/common/thirdparty/base/config/Language.js +4 -14
  46. package/src/sap/ui/webc/common/thirdparty/base/config/NoConflict.js +4 -14
  47. package/src/sap/ui/webc/common/thirdparty/base/config/RTL.js +2 -8
  48. package/src/sap/ui/webc/common/thirdparty/base/config/Theme.js +4 -15
  49. package/src/sap/ui/webc/common/thirdparty/base/delegate/ItemNavigation.js +8 -72
  50. package/src/sap/ui/webc/common/thirdparty/base/delegate/ResizeHandler.js +8 -23
  51. package/src/sap/ui/webc/common/thirdparty/base/delegate/ScrollEnablement.js +9 -34
  52. package/src/sap/ui/webc/common/thirdparty/base/features/F6Navigation.js +1 -20
  53. package/src/sap/ui/webc/common/thirdparty/base/features/OpenUI5Enablement.js +0 -17
  54. package/src/sap/ui/webc/common/thirdparty/base/features/OpenUI5Support.js +0 -32
  55. package/src/sap/ui/webc/common/thirdparty/base/generated/VersionInfo.js +1 -1
  56. package/src/sap/ui/webc/common/thirdparty/base/getSharedResource.js +1 -9
  57. package/src/sap/ui/webc/common/thirdparty/base/i18nBundle.js +4 -18
  58. package/src/sap/ui/webc/common/thirdparty/base/locale/Locale.js +0 -25
  59. package/src/sap/ui/webc/common/thirdparty/base/locale/RTLAwareRegistry.js +0 -4
  60. package/src/sap/ui/webc/common/thirdparty/base/locale/applyDirection.js +0 -2
  61. package/src/sap/ui/webc/common/thirdparty/base/locale/directionChange.js +2 -9
  62. package/src/sap/ui/webc/common/thirdparty/base/locale/getEffectiveDir.js +4 -9
  63. package/src/sap/ui/webc/common/thirdparty/base/locale/getLocale.js +3 -11
  64. package/src/sap/ui/webc/common/thirdparty/base/locale/languageChange.js +0 -8
  65. package/src/sap/ui/webc/common/thirdparty/base/locale/nextFallbackLocale.js +4 -8
  66. package/src/sap/ui/webc/common/thirdparty/base/locale/normalizeLocale.js +8 -14
  67. package/src/sap/ui/webc/common/thirdparty/base/renderer/LitRenderer.js +0 -11
  68. package/src/sap/ui/webc/common/thirdparty/base/renderer/directives/style-map.js +7 -21
  69. package/src/sap/ui/webc/common/thirdparty/base/renderer/executeTemplate.js +1 -6
  70. package/src/sap/ui/webc/common/thirdparty/base/theming/CustomStyle.js +2 -16
  71. package/src/sap/ui/webc/common/thirdparty/base/theming/ThemeLoaded.js +0 -8
  72. package/src/sap/ui/webc/common/thirdparty/base/theming/applyTheme.js +6 -21
  73. package/src/sap/ui/webc/common/thirdparty/base/theming/getConstructableStyle.js +1 -6
  74. package/src/sap/ui/webc/common/thirdparty/base/theming/getEffectiveLinksHrefs.js +0 -7
  75. package/src/sap/ui/webc/common/thirdparty/base/theming/getEffectiveStyle.js +0 -8
  76. package/src/sap/ui/webc/common/thirdparty/base/theming/getStylesString.js +0 -4
  77. package/src/sap/ui/webc/common/thirdparty/base/theming/getThemeDesignerTheme.js +4 -22
  78. package/src/sap/ui/webc/common/thirdparty/base/theming/preloadLinks.js +0 -5
  79. package/src/sap/ui/webc/common/thirdparty/base/thirdparty/_merge.js +10 -20
  80. package/src/sap/ui/webc/common/thirdparty/base/thirdparty/isPlainObject.js +0 -6
  81. package/src/sap/ui/webc/common/thirdparty/base/thirdparty/merge.js +0 -3
  82. package/src/sap/ui/webc/common/thirdparty/base/types/CSSColor.js +0 -4
  83. package/src/sap/ui/webc/common/thirdparty/base/types/CSSSize.js +0 -4
  84. package/src/sap/ui/webc/common/thirdparty/base/types/CalendarType.js +0 -5
  85. package/src/sap/ui/webc/common/thirdparty/base/types/DataType.js +0 -8
  86. package/src/sap/ui/webc/common/thirdparty/base/types/Float.js +0 -5
  87. package/src/sap/ui/webc/common/thirdparty/base/types/Integer.js +0 -5
  88. package/src/sap/ui/webc/common/thirdparty/base/types/InvisibleMessageMode.js +0 -6
  89. package/src/sap/ui/webc/common/thirdparty/base/types/ItemNavigationBehavior.js +0 -2
  90. package/src/sap/ui/webc/common/thirdparty/base/types/PopupState.js +0 -8
  91. package/src/sap/ui/webc/common/thirdparty/base/types/ValueState.js +0 -5
  92. package/src/sap/ui/webc/common/thirdparty/base/updateShadowRoot.js +0 -5
  93. package/src/sap/ui/webc/common/thirdparty/base/util/AriaLabelHelper.js +1 -9
  94. package/src/sap/ui/webc/common/thirdparty/base/util/Caret.js +0 -6
  95. package/src/sap/ui/webc/common/thirdparty/base/util/ColorConversion.js +29 -46
  96. package/src/sap/ui/webc/common/thirdparty/base/util/FetchHelper.js +0 -10
  97. package/src/sap/ui/webc/common/thirdparty/base/util/FocusableElements.js +2 -19
  98. package/src/sap/ui/webc/common/thirdparty/base/util/InvisibleMessage.js +3 -9
  99. package/src/sap/ui/webc/common/thirdparty/base/util/PopupUtils.js +0 -28
  100. package/src/sap/ui/webc/common/thirdparty/base/util/SlotsHelper.js +4 -15
  101. package/src/sap/ui/webc/common/thirdparty/base/util/StringHelper.js +0 -7
  102. package/src/sap/ui/webc/common/thirdparty/base/util/TabbableElements.js +0 -12
  103. package/src/sap/ui/webc/common/thirdparty/base/util/arraysAreEqual.js +0 -4
  104. package/src/sap/ui/webc/common/thirdparty/base/util/clamp.js +0 -2
  105. package/src/sap/ui/webc/common/thirdparty/base/util/createLinkInHead.js +0 -2
  106. package/src/sap/ui/webc/common/thirdparty/base/util/createStyleInHead.js +0 -2
  107. package/src/sap/ui/webc/common/thirdparty/base/util/debounce.js +1 -3
  108. package/src/sap/ui/webc/common/thirdparty/base/util/detectNavigatorLanguage.js +0 -4
  109. package/src/sap/ui/webc/common/thirdparty/base/util/escapeRegex.js +0 -2
  110. package/src/sap/ui/webc/common/thirdparty/base/util/findNodeOwner.js +0 -6
  111. package/src/sap/ui/webc/common/thirdparty/base/util/formatMessage.js +2 -7
  112. package/src/sap/ui/webc/common/thirdparty/base/util/generateHighlightedMarkup.js +9 -17
  113. package/src/sap/ui/webc/common/thirdparty/base/util/getActiveElement.js +0 -4
  114. package/src/sap/ui/webc/common/thirdparty/base/util/getClassCopy.js +0 -3
  115. package/src/sap/ui/webc/common/thirdparty/base/util/getDesigntimePropertyAsArray.js +0 -2
  116. package/src/sap/ui/webc/common/thirdparty/base/util/getEffectiveContentDensity.js +0 -2
  117. package/src/sap/ui/webc/common/thirdparty/base/util/getFileExtension.js +0 -4
  118. package/src/sap/ui/webc/common/thirdparty/base/util/getNormalizedTarget.js +0 -4
  119. package/src/sap/ui/webc/common/thirdparty/base/util/getSingletonElementInstance.js +0 -4
  120. package/src/sap/ui/webc/common/thirdparty/base/util/isDefaultSlotProvided.js +0 -2
  121. package/src/sap/ui/webc/common/thirdparty/base/util/isDescendantOf.js +0 -6
  122. package/src/sap/ui/webc/common/thirdparty/base/util/isElementInView.js +0 -2
  123. package/src/sap/ui/webc/common/thirdparty/base/util/isNodeClickable.js +0 -5
  124. package/src/sap/ui/webc/common/thirdparty/base/util/isNodeHidden.js +0 -3
  125. package/src/sap/ui/webc/common/thirdparty/base/util/isNodeTabbable.js +0 -9
  126. package/src/sap/ui/webc/common/thirdparty/base/util/isValidPropertyName.js +1 -3
  127. package/src/sap/ui/webc/common/thirdparty/base/util/setToArray.js +0 -2
  128. package/src/sap/ui/webc/common/thirdparty/base/util/whenDOMReady.js +0 -2
  129. package/src/sap/ui/webc/common/thirdparty/icons/generated/json-imports/i18n.js +0 -52
  130. package/src/sap/ui/webc/common/thirdparty/icons/json-imports/Icons.js +0 -5
  131. package/src/sap/ui/webc/common/thirdparty/icons-business-suite/json-imports/Icons.js +0 -3
  132. package/src/sap/ui/webc/common/thirdparty/icons-tnt/json-imports/Icons.js +0 -3
  133. package/src/sap/ui/webc/common/thirdparty/lit-html/directive-helpers.js +62 -70
  134. package/src/sap/ui/webc/common/thirdparty/lit-html/directive.js +11 -20
  135. package/src/sap/ui/webc/common/thirdparty/lit-html/directives/class-map.js +0 -10
  136. package/src/sap/ui/webc/common/thirdparty/lit-html/directives/if-defined.js +0 -2
  137. package/src/sap/ui/webc/common/thirdparty/lit-html/directives/repeat.js +55 -71
  138. package/src/sap/ui/webc/common/thirdparty/lit-html/directives/unsafe-html.js +0 -4
  139. package/src/sap/ui/webc/common/thirdparty/lit-html/lit-html.js +96 -171
  140. package/src/sap/ui/webc/common/thirdparty/lit-html/static.js +34 -40
  141. package/src/sap/ui/webc/common/thirdparty/localization/DateFormat.js +0 -2
  142. package/src/sap/ui/webc/common/thirdparty/localization/LocaleData.js +0 -2
  143. package/src/sap/ui/webc/common/thirdparty/localization/dates/CalendarDate.js +13 -56
  144. package/src/sap/ui/webc/common/thirdparty/localization/dates/ExtremeDates.js +0 -11
  145. package/src/sap/ui/webc/common/thirdparty/localization/dates/calculateWeekNumber.js +5 -8
  146. package/src/sap/ui/webc/common/thirdparty/localization/dates/getRoundedTimestamp.js +0 -3
  147. package/src/sap/ui/webc/common/thirdparty/localization/dates/getTodayUTCTimestamp.js +0 -3
  148. package/src/sap/ui/webc/common/thirdparty/localization/dates/modifyDateBy.js +0 -9
  149. package/src/sap/ui/webc/common/thirdparty/localization/getCachedLocaleDataInstance.js +0 -5
  150. package/src/sap/ui/webc/common/thirdparty/localization/locale/getLocaleData.js +1 -6
  151. package/src/sap/ui/webc/common/thirdparty/theming/generated/json-imports/Themes.js +0 -16
  152. package/ui5.yaml +7 -7
  153. package/src/sap/ui/webc/common/thirdparty/icons-business-suite/main-milestone.js +0 -25
  154. package/src/sap/ui/webc/common/thirdparty/icons-business-suite/main-sequence.js +0 -25
@@ -7,7 +7,6 @@ sap.ui.define(["exports"], function (_exports) {
7
7
  _exports.setResizeHandlerUnobserveFn = _exports.setResizeHandlerObserveFn = _exports.default = void 0;
8
8
  let resizeObserver;
9
9
  const observedElements = new Map();
10
-
11
10
  const getResizeObserver = () => {
12
11
  if (!resizeObserver) {
13
12
  resizeObserver = new window.ResizeObserver(entries => {
@@ -17,30 +16,25 @@ sap.ui.define(["exports"], function (_exports) {
17
16
  });
18
17
  });
19
18
  }
20
-
21
19
  return resizeObserver;
22
20
  };
23
-
24
21
  let observe = (element, callback) => {
25
- const callbacks = observedElements.get(element) || []; // if no callbacks have been added for this element - start observing it
22
+ const callbacks = observedElements.get(element) || [];
26
23
 
24
+ // if no callbacks have been added for this element - start observing it
27
25
  if (!callbacks.length) {
28
26
  getResizeObserver().observe(element);
29
- } // save the callbacks in an array
30
-
27
+ }
31
28
 
29
+ // save the callbacks in an array
32
30
  observedElements.set(element, [...callbacks, callback]);
33
31
  };
34
-
35
32
  let unobserve = (element, callback) => {
36
33
  const callbacks = observedElements.get(element) || [];
37
-
38
34
  if (callbacks.length === 0) {
39
35
  return;
40
36
  }
41
-
42
37
  const filteredCallbacks = callbacks.filter(fn => fn !== callback);
43
-
44
38
  if (filteredCallbacks.length === 0) {
45
39
  getResizeObserver().unobserve(element);
46
40
  observedElements.delete(element);
@@ -48,14 +42,13 @@ sap.ui.define(["exports"], function (_exports) {
48
42
  observedElements.set(element, filteredCallbacks);
49
43
  }
50
44
  };
45
+
51
46
  /**
52
47
  * Allows to register/deregister resize observers for a DOM element
53
48
  *
54
49
  * @public
55
50
  * @class
56
51
  */
57
-
58
-
59
52
  class ResizeHandler {
60
53
  /**
61
54
  * @static
@@ -67,57 +60,49 @@ sap.ui.define(["exports"], function (_exports) {
67
60
  if (element.isUI5Element) {
68
61
  element = element.getDomRef();
69
62
  }
70
-
71
63
  if (element instanceof HTMLElement) {
72
64
  observe(element, callback);
73
65
  } else {
74
66
  console.warn("Cannot register ResizeHandler for element", element); // eslint-disable-line
75
67
  }
76
68
  }
69
+
77
70
  /**
78
71
  * @static
79
72
  * @public
80
73
  * @param {*} element UI5 Web Component or DOM Element to be unobserved
81
74
  * @param {*} callback Callback to be removed
82
75
  */
83
-
84
-
85
76
  static deregister(element, callback) {
86
77
  if (element.isUI5Element) {
87
78
  element = element.getDomRef();
88
79
  }
89
-
90
80
  if (element instanceof HTMLElement) {
91
81
  unobserve(element, callback);
92
82
  } else {
93
83
  console.warn("Cannot deregister ResizeHandler for element", element); // eslint-disable-line
94
84
  }
95
85
  }
96
-
97
86
  }
87
+
98
88
  /**
99
89
  * Set a function to be executed whenever a DOM node needs to be observed for size change.
100
90
  * @public
101
91
  * @param fn
102
92
  */
103
-
104
-
105
93
  const setResizeHandlerObserveFn = fn => {
106
94
  observe = fn;
107
95
  };
96
+
108
97
  /**
109
98
  * Set a function to be executed whenever a DOM node needs to no longer be observed for size changes
110
99
  * @public
111
100
  * @param fn
112
101
  */
113
-
114
-
115
102
  _exports.setResizeHandlerObserveFn = setResizeHandlerObserveFn;
116
-
117
103
  const setResizeHandlerUnobserveFn = fn => {
118
104
  unobserve = fn;
119
105
  };
120
-
121
106
  _exports.setResizeHandlerUnobserveFn = setResizeHandlerUnobserveFn;
122
107
  var _default = ResizeHandler;
123
108
  _exports.default = _default;
@@ -7,12 +7,9 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
7
7
  _exports.default = void 0;
8
8
  _EventProvider = _interopRequireDefault(_EventProvider);
9
9
  _scroll = _interopRequireDefault(_scroll);
10
-
11
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
12
-
13
11
  const scrollEventName = "scroll";
14
12
  const touchEndEventName = (0, _Device.supportsTouch)() ? "touchend" : "mouseup";
15
-
16
13
  class ScrollEnablement extends _EventProvider.default {
17
14
  constructor(containerComponent) {
18
15
  super();
@@ -20,16 +17,17 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
20
17
  this.mouseMove = this.ontouchmove.bind(this);
21
18
  this.mouseUp = this.ontouchend.bind(this);
22
19
  this.touchStart = this.ontouchstart.bind(this);
23
- this.supportsTouch = (0, _Device.supportsTouch)(); // On Android devices touchmove is thrown one more time than neccessary (together with touchend)
20
+ this.supportsTouch = (0, _Device.supportsTouch)();
21
+
22
+ // On Android devices touchmove is thrown one more time than neccessary (together with touchend)
24
23
  // so we have to cache the previus coordinates in order to provide correct parameters in the
25
24
  // event for Android
25
+ this.cachedValue = {};
26
26
 
27
- this.cachedValue = {}; // In components like Carousel you need to know if the user has clicked on something or swiped
27
+ // In components like Carousel you need to know if the user has clicked on something or swiped
28
28
  // in order to throw the needed event or not
29
-
30
29
  this.startX = 0;
31
30
  this.startY = 0;
32
-
33
31
  if (this.supportsTouch) {
34
32
  containerComponent.addEventListener("touchstart", this.touchStart, {
35
33
  passive: true
@@ -46,14 +44,13 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
46
44
  });
47
45
  }
48
46
  }
49
-
50
47
  set scrollContainer(container) {
51
48
  this._container = container;
52
49
  }
53
-
54
50
  get scrollContainer() {
55
51
  return this._container;
56
52
  }
53
+
57
54
  /**
58
55
  * Scrolls the container to the left/top position, retrying retryCount times, if the container is not yet painted
59
56
  *
@@ -63,12 +60,10 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
63
60
  * @param retryInterval
64
61
  * @returns {Promise<void>} resolved when scrolled successfully
65
62
  */
66
-
67
-
68
63
  async scrollTo(left, top, retryCount = 0, retryInterval = 0) {
69
64
  let containerPainted = this.scrollContainer.clientHeight > 0 && this.scrollContainer.clientWidth > 0;
70
- /* eslint-disable no-loop-func, no-await-in-loop */
71
65
 
66
+ /* eslint-disable no-loop-func, no-await-in-loop */
72
67
  while (!containerPainted && retryCount > 0) {
73
68
  await new Promise(resolve => {
74
69
  setTimeout(() => {
@@ -80,44 +75,35 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
80
75
  }
81
76
  /* eslint-disable no-loop-func, no-await-in-loop */
82
77
 
83
-
84
78
  this._container.scrollLeft = left;
85
79
  this._container.scrollTop = top;
86
80
  }
87
-
88
81
  move(dx, dy, disableAnimation) {
89
82
  if (disableAnimation) {
90
83
  this._container.scrollLeft += dx;
91
84
  this._container.scrollTop += dy;
92
85
  return;
93
86
  }
94
-
95
87
  return (0, _scroll.default)({
96
88
  element: this._container,
97
89
  dx,
98
90
  dy
99
91
  });
100
92
  }
101
-
102
93
  getScrollLeft() {
103
94
  return this._container.scrollLeft;
104
95
  }
105
-
106
96
  getScrollTop() {
107
97
  return this._container.scrollTop;
108
98
  }
109
-
110
99
  _isTouchInside(touch) {
111
100
  const rect = this._container.getBoundingClientRect();
112
-
113
101
  const x = this.supportsTouch ? touch.clientX : touch.x;
114
102
  const y = this.supportsTouch ? touch.clientY : touch.y;
115
103
  return x >= rect.left && x <= rect.right && y >= rect.top && y <= rect.bottom;
116
104
  }
117
-
118
105
  ontouchstart(event) {
119
106
  const touch = this.supportsTouch ? event.touches[0] : null;
120
-
121
107
  if (!this.supportsTouch) {
122
108
  document.addEventListener("mouseup", this.mouseUp, {
123
109
  passive: true
@@ -130,17 +116,14 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
130
116
  this.startX = touch.pageX;
131
117
  this.startY = touch.pageY;
132
118
  }
133
-
134
119
  this._prevDragX = this.supportsTouch ? touch.pageX : event.x;
135
120
  this._prevDragY = this.supportsTouch ? touch.pageY : event.y;
136
121
  this._canScroll = this._isTouchInside(this.supportsTouch ? touch : event);
137
122
  }
138
-
139
123
  ontouchmove(event) {
140
124
  if (!this._canScroll) {
141
125
  return;
142
126
  }
143
-
144
127
  const container = this._container;
145
128
  const touch = this.supportsTouch ? event.touches[0] : null;
146
129
  const dragX = this.supportsTouch ? touch.pageX : event.x;
@@ -156,30 +139,25 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
156
139
  this._prevDragX = dragX;
157
140
  this._prevDragY = dragY;
158
141
  }
159
-
160
142
  ontouchend(event) {
161
143
  if (this.supportsTouch) {
162
144
  const deltaX = Math.abs(event.changedTouches[0].pageX - this.startX);
163
145
  const deltaY = Math.abs(event.changedTouches[0].pageY - this.startY);
164
-
165
146
  if (deltaX < 10 && deltaY < 10) {
166
147
  return;
167
148
  }
168
149
  }
169
-
170
150
  if (!this._canScroll) {
171
151
  return;
172
152
  }
173
-
174
153
  const container = this._container;
175
154
  const dragX = this.supportsTouch ? event.changedTouches[0].pageX : event.x;
176
155
  const dragY = this.supportsTouch ? event.changedTouches[0].pageY : event.y;
177
156
  container.scrollLeft += this._prevDragX - dragX;
178
157
  container.scrollTop += this._prevDragY - dragY;
179
158
  const useCachedValues = dragX === this._prevDragX;
180
-
181
- const _dragX = useCachedValues ? this.cachedValue.dragX : dragX; // const _dragY = useCachedValues ? this.cachedValue.dragY : dragY; add if needed
182
-
159
+ const _dragX = useCachedValues ? this.cachedValue.dragX : dragX;
160
+ // const _dragY = useCachedValues ? this.cachedValue.dragY : dragY; add if needed
183
161
 
184
162
  this.fireEvent(touchEndEventName, {
185
163
  isLeft: _dragX < this._prevDragX,
@@ -187,7 +165,6 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
187
165
  });
188
166
  this._prevDragX = dragX;
189
167
  this._prevDragY = dragY;
190
-
191
168
  if (!this.supportsTouch) {
192
169
  document.removeEventListener("mousemove", this.mouseMove, {
193
170
  passive: true
@@ -195,9 +172,7 @@ sap.ui.define(["exports", "../Device", "../EventProvider", "../animations/scroll
195
172
  document.removeEventListener("mouseup", this.mouseUp);
196
173
  }
197
174
  }
198
-
199
175
  }
200
-
201
176
  var _default = ScrollEnablement;
202
177
  _exports.default = _default;
203
178
  });
@@ -5,7 +5,6 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../Keys", "../util/FocusableEl
5
5
  value: true
6
6
  });
7
7
  _exports.default = void 0;
8
-
9
8
  class F6Navigation {
10
9
  init() {
11
10
  this.keydownHandler = this._keydownHandler.bind(this);
@@ -13,23 +12,18 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../Keys", "../util/FocusableEl
13
12
  this.selectedGroup = null;
14
13
  this.groups = [];
15
14
  }
16
-
17
15
  attachEventListeners() {
18
16
  document.addEventListener("keydown", this.keydownHandler);
19
17
  }
20
-
21
18
  async _keydownHandler(event) {
22
19
  if ((0, _Keys.isF6Next)(event)) {
23
20
  this.updateGroups();
24
-
25
21
  if (this.groups.length < 1) {
26
22
  return;
27
23
  }
28
-
29
24
  event.preventDefault();
30
25
  const nextIndex = this.groups.indexOf(this.selectedGroup);
31
26
  let nextElement = null;
32
-
33
27
  if (nextIndex > -1) {
34
28
  if (nextIndex + 1 >= this.groups.length) {
35
29
  nextElement = this.groups[0];
@@ -39,22 +33,17 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../Keys", "../util/FocusableEl
39
33
  } else {
40
34
  nextElement = this.groups[0];
41
35
  }
42
-
43
36
  const elementToFocus = await (0, _FocusableElements.getFirstFocusableElement)(nextElement.isUI5Element ? nextElement.getDomRef() : nextElement, true);
44
37
  elementToFocus.focus();
45
38
  }
46
-
47
39
  if ((0, _Keys.isF6Previous)(event)) {
48
40
  this.updateGroups();
49
-
50
41
  if (this.groups.length < 1) {
51
42
  return;
52
43
  }
53
-
54
44
  event.preventDefault();
55
45
  const nextIndex = this.groups.indexOf(this.selectedGroup);
56
46
  let nextElement = null;
57
-
58
47
  if (nextIndex > -1) {
59
48
  if (nextIndex - 1 < 0) {
60
49
  nextElement = this.groups[this.groups.length - 1];
@@ -67,6 +56,7 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../Keys", "../util/FocusableEl
67
56
  // </ui5-list>
68
57
  // </ui5-flexible-column-layout>
69
58
  // Here for both FCL & List the firstFoccusableElement is the same (the ui5-li)
59
+
70
60
  const firstFocusable = await (0, _FocusableElements.getFirstFocusableElement)(this.groups[nextIndex - 1], true);
71
61
  const shouldSkipParent = firstFocusable === (await (0, _FocusableElements.getFirstFocusableElement)(this.groups[nextIndex], true));
72
62
  nextElement = this.groups[shouldSkipParent ? nextIndex - 2 : nextIndex - 1];
@@ -74,39 +64,30 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../Keys", "../util/FocusableEl
74
64
  } else {
75
65
  nextElement = this.groups[this.groups.length - 1];
76
66
  }
77
-
78
67
  const elementToFocus = await (0, _FocusableElements.getFirstFocusableElement)(nextElement.isUI5Element ? nextElement.getDomRef() : nextElement, true);
79
68
  elementToFocus.focus();
80
69
  }
81
70
  }
82
-
83
71
  removeEventListeners() {
84
72
  document.removeEventListener("keydown", this.keydownHandler);
85
73
  }
86
-
87
74
  updateGroups() {
88
75
  this.setSelectedGroup(document.activeElement);
89
76
  this.setGroups();
90
77
  }
91
-
92
78
  setGroups() {
93
79
  this.groups = Array.from(document.querySelectorAll("[data-sap-ui-fastnavgroup='true']")).filter(group => group.clientWidth && window.getComputedStyle(group).visibility !== "hidden");
94
80
  }
95
-
96
81
  setSelectedGroup(element) {
97
82
  while (element && element.getAttribute("data-sap-ui-fastnavgroup") !== "true" && element !== document.querySelector("html")) {
98
83
  element = element.parentElement ? element.parentNode : element.parentNode.host;
99
84
  }
100
-
101
85
  this.selectedGroup = element;
102
86
  }
103
-
104
87
  destroy() {
105
88
  this.removeEventListeners();
106
89
  }
107
-
108
90
  }
109
-
110
91
  const F6HelperInstance = new F6Navigation();
111
92
  (0, _FeaturesRegistry.registerFeature)("F6Navigation", F6HelperInstance);
112
93
  var _default = F6Navigation;
@@ -7,9 +7,7 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
7
7
  _exports.default = void 0;
8
8
  _BusyIndicator = _interopRequireDefault(_BusyIndicator);
9
9
  _merge = _interopRequireDefault(_merge);
10
-
11
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
12
-
13
11
  const busyIndicatorMetadata = {
14
12
  properties: {
15
13
  __isBusy: {
@@ -17,11 +15,9 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
17
15
  }
18
16
  }
19
17
  };
20
-
21
18
  const getBusyIndicatorStyles = () => {
22
19
  return _BusyIndicator.default;
23
20
  };
24
-
25
21
  const wrapTemplateResultInBusyMarkup = (html, host, templateResult) => {
26
22
  if (host.isOpenUI5Component && host.__isBusy) {
27
23
  templateResult = html`
@@ -45,14 +41,11 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
45
41
  </div>
46
42
  </div>`;
47
43
  }
48
-
49
44
  return templateResult;
50
45
  };
51
-
52
46
  const enrichBusyIndicatorMetadata = UI5Element => {
53
47
  UI5Element.metadata = (0, _merge.default)(UI5Element.metadata, busyIndicatorMetadata);
54
48
  };
55
-
56
49
  const enrichBusyIndicatorMethods = UI5ElementPrototype => {
57
50
  Object.defineProperties(UI5ElementPrototype, {
58
51
  "__redirectFocus": {
@@ -75,7 +68,6 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
75
68
  passive: false
76
69
  };
77
70
  }
78
-
79
71
  },
80
72
  "isOpenUI5Component": {
81
73
  get: () => {
@@ -83,27 +75,21 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
83
75
  }
84
76
  }
85
77
  });
86
-
87
78
  UI5ElementPrototype.__suppressFocusIn = function handleFocusIn() {
88
79
  const busyIndicator = this.shadowRoot.querySelector("[busy-indicator]");
89
-
90
80
  if (busyIndicator && this.__redirectFocus) {
91
81
  busyIndicator.focus();
92
82
  }
93
83
  };
94
-
95
84
  UI5ElementPrototype.getDomRef = function getDomRef() {
96
85
  // If a component set _getRealDomRef to its children, use the return value of this function
97
86
  if (typeof this._getRealDomRef === "function") {
98
87
  return this._getRealDomRef();
99
88
  }
100
-
101
89
  if (!this.shadowRoot || this.shadowRoot.children.length === 0) {
102
90
  return;
103
91
  }
104
-
105
92
  const children = [...this.shadowRoot.children].filter(child => !["link", "style"].includes(child.localName));
106
-
107
93
  if (children.length !== 1) {
108
94
  console.warn(`The shadow DOM for ${this.constructor.getMetadata().getTag()} does not have a top level element, the getDomRef() method might not work as expected`); // eslint-disable-line
109
95
  }
@@ -111,16 +97,13 @@ sap.ui.define(["exports", "../FeaturesRegistry", "../generated/css/BusyIndicator
111
97
  if (this.__isBusy) {
112
98
  return children[0].querySelector(".busy-indicator-wrapper > :not([busy-indicator-before-span]):not(.busy-indicator-overlay):not(.busy-indicator-busy-area)");
113
99
  }
114
-
115
100
  return children[0];
116
101
  };
117
102
  };
118
-
119
103
  const enrichBusyIndicatorSettings = UI5Element => {
120
104
  enrichBusyIndicatorMetadata(UI5Element);
121
105
  enrichBusyIndicatorMethods(UI5Element.prototype);
122
106
  };
123
-
124
107
  const OpenUI5Enablement = {
125
108
  enrichBusyIndicatorSettings,
126
109
  wrapTemplateResultInBusyMarkup,
@@ -6,18 +6,14 @@ sap.ui.define(["../FeaturesRegistry", "../config/Theme", "../util/PopupUtils"],
6
6
  const core = sap && sap.ui && typeof sap.ui.getCore === "function" && sap.ui.getCore();
7
7
  return core;
8
8
  };
9
-
10
9
  const isLoaded = () => {
11
10
  return !!getCore();
12
11
  };
13
-
14
12
  const init = () => {
15
13
  const core = getCore();
16
-
17
14
  if (!core) {
18
15
  return Promise.resolve();
19
16
  }
20
-
21
17
  return new Promise(resolve => {
22
18
  core.attachInit(() => {
23
19
  window.sap.ui.require(["sap/ui/core/LocaleData", "sap/ui/core/Popup"], (LocaleData, Popup) => {
@@ -27,18 +23,13 @@ sap.ui.define(["../FeaturesRegistry", "../config/Theme", "../util/PopupUtils"],
27
23
  });
28
24
  });
29
25
  };
30
-
31
26
  const getConfigurationSettingsObject = () => {
32
27
  const core = getCore();
33
-
34
28
  if (!core) {
35
29
  return;
36
30
  }
37
-
38
31
  const config = core.getConfiguration();
39
-
40
32
  const LocaleData = window.sap.ui.require("sap/ui/core/LocaleData");
41
-
42
33
  return {
43
34
  animationMode: config.getAnimationMode(),
44
35
  language: config.getLanguage(),
@@ -50,21 +41,15 @@ sap.ui.define(["../FeaturesRegistry", "../config/Theme", "../util/PopupUtils"],
50
41
  }
51
42
  };
52
43
  };
53
-
54
44
  const getLocaleDataObject = () => {
55
45
  const core = getCore();
56
-
57
46
  if (!core) {
58
47
  return;
59
48
  }
60
-
61
49
  const config = core.getConfiguration();
62
-
63
50
  const LocaleData = window.sap.ui.require("sap/ui/core/LocaleData");
64
-
65
51
  return LocaleData.getInstance(config.getLocale())._get();
66
52
  };
67
-
68
53
  const listenForThemeChange = () => {
69
54
  const core = getCore();
70
55
  const config = core.getConfiguration();
@@ -72,57 +57,40 @@ sap.ui.define(["../FeaturesRegistry", "../config/Theme", "../util/PopupUtils"],
72
57
  await (0, _Theme.setTheme)(config.getTheme());
73
58
  });
74
59
  };
75
-
76
60
  const attachListeners = () => {
77
61
  const core = getCore();
78
-
79
62
  if (!core) {
80
63
  return;
81
64
  }
82
-
83
65
  listenForThemeChange();
84
66
  };
85
-
86
67
  const cssVariablesLoaded = () => {
87
68
  const core = getCore();
88
-
89
69
  if (!core) {
90
70
  return;
91
71
  }
92
-
93
72
  const link = [...document.head.children].find(el => el.id === "sap-ui-theme-sap.ui.core"); // more reliable than querySelector early
94
-
95
73
  if (!link) {
96
74
  return;
97
75
  }
98
-
99
76
  return !!link.href.match(/\/css(-|_)variables\.css/);
100
77
  };
101
-
102
78
  const getNextZIndex = () => {
103
79
  const core = getCore();
104
-
105
80
  if (!core) {
106
81
  return;
107
82
  }
108
-
109
83
  const Popup = window.sap.ui.require("sap/ui/core/Popup");
110
-
111
84
  return Popup.getNextZIndex();
112
85
  };
113
-
114
86
  const setInitialZIndex = () => {
115
87
  const core = getCore();
116
-
117
88
  if (!core) {
118
89
  return;
119
90
  }
120
-
121
91
  const Popup = window.sap.ui.require("sap/ui/core/Popup");
122
-
123
92
  Popup.setInitialZIndex((0, _PopupUtils.getCurrentZIndex)());
124
93
  };
125
-
126
94
  const OpenUI5Support = {
127
95
  isLoaded,
128
96
  init,
@@ -12,7 +12,7 @@ sap.ui.define(["exports"], function (_exports) {
12
12
  patch: 0,
13
13
  suffix: "",
14
14
  isNext: false,
15
- buildTime: 1657807887
15
+ buildTime: 1656937916
16
16
  };
17
17
  var _default = VersionInfo;
18
18
  _exports.default = _default;
@@ -6,10 +6,9 @@ sap.ui.define(["exports", "./util/getSingletonElementInstance"], function (_expo
6
6
  });
7
7
  _exports.default = void 0;
8
8
  _getSingletonElementInstance = _interopRequireDefault(_getSingletonElementInstance);
9
-
10
9
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
-
12
10
  const getSharedResourcesInstance = () => (0, _getSingletonElementInstance.default)("ui5-shared-resources", document.head);
11
+
13
12
  /**
14
13
  * Use this method to initialize/get resources that you would like to be shared among UI5 Web Components runtime instances.
15
14
  * The data will be accessed via a singleton "ui5-shared-resources" HTML element in the "head" element of the page.
@@ -19,26 +18,19 @@ sap.ui.define(["exports", "./util/getSingletonElementInstance"], function (_expo
19
18
  * @param initialValue Object or primitive that will be used as an initial value if the resource does not exist
20
19
  * @returns {*}
21
20
  */
22
-
23
-
24
21
  const getSharedResource = (namespace, initialValue) => {
25
22
  const parts = namespace.split(".");
26
23
  let current = getSharedResourcesInstance();
27
-
28
24
  for (let i = 0; i < parts.length; i++) {
29
25
  const part = parts[i];
30
26
  const lastPart = i === parts.length - 1;
31
-
32
27
  if (!Object.prototype.hasOwnProperty.call(current, part)) {
33
28
  current[part] = lastPart ? initialValue : {};
34
29
  }
35
-
36
30
  current = current[part];
37
31
  }
38
-
39
32
  return current;
40
33
  };
41
-
42
34
  var _default = getSharedResource;
43
35
  _exports.default = _default;
44
36
  });