@openui5/sap.ui.unified 1.100.0 → 1.102.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 (110) hide show
  1. package/.eslintrc.json +19 -0
  2. package/THIRDPARTY.txt +5 -5
  3. package/package.json +2 -2
  4. package/src/sap/ui/unified/.library +1 -1
  5. package/src/sap/ui/unified/Calendar.js +8 -249
  6. package/src/sap/ui/unified/CalendarAppointment.js +46 -9
  7. package/src/sap/ui/unified/CalendarDateInterval.js +6 -14
  8. package/src/sap/ui/unified/CalendarLegend.js +1 -1
  9. package/src/sap/ui/unified/CalendarLegendItem.js +1 -1
  10. package/src/sap/ui/unified/CalendarMonthInterval.js +1 -138
  11. package/src/sap/ui/unified/CalendarMonthIntervalRenderer.js +3 -12
  12. package/src/sap/ui/unified/CalendarOneMonthInterval.js +1 -2
  13. package/src/sap/ui/unified/CalendarRenderer.js +3 -14
  14. package/src/sap/ui/unified/CalendarRow.js +58 -23
  15. package/src/sap/ui/unified/CalendarRowRenderer.js +12 -10
  16. package/src/sap/ui/unified/CalendarTimeInterval.js +1 -204
  17. package/src/sap/ui/unified/CalendarTimeIntervalRenderer.js +3 -14
  18. package/src/sap/ui/unified/CalendarWeekInterval.js +1 -1
  19. package/src/sap/ui/unified/ColorPicker.js +2 -2
  20. package/src/sap/ui/unified/ColorPickerPopover.js +1 -1
  21. package/src/sap/ui/unified/ContentSwitcher.js +1 -1
  22. package/src/sap/ui/unified/Currency.js +1 -1
  23. package/src/sap/ui/unified/CurrencyRenderer.js +1 -1
  24. package/src/sap/ui/unified/DateRange.js +1 -1
  25. package/src/sap/ui/unified/DateTypeRange.js +1 -1
  26. package/src/sap/ui/unified/FileUploader.js +26 -4
  27. package/src/sap/ui/unified/FileUploaderParameter.js +1 -1
  28. package/src/sap/ui/unified/FileUploaderXHRSettings.js +1 -1
  29. package/src/sap/ui/unified/Menu.js +11 -7
  30. package/src/sap/ui/unified/MenuItem.js +1 -1
  31. package/src/sap/ui/unified/MenuItemBase.js +1 -1
  32. package/src/sap/ui/unified/MenuRenderer.js +1 -1
  33. package/src/sap/ui/unified/MenuTextFieldItem.js +1 -1
  34. package/src/sap/ui/unified/Shell.js +1 -1
  35. package/src/sap/ui/unified/ShellHeadItem.js +1 -1
  36. package/src/sap/ui/unified/ShellHeadUserItem.js +1 -1
  37. package/src/sap/ui/unified/ShellLayout.js +1 -1
  38. package/src/sap/ui/unified/ShellOverlay.js +1 -1
  39. package/src/sap/ui/unified/SplitContainer.js +1 -1
  40. package/src/sap/ui/unified/calendar/CalendarDate.js +10 -0
  41. package/src/sap/ui/unified/calendar/CalendarUtils.js +19 -2
  42. package/src/sap/ui/unified/calendar/DatesRow.js +1 -1
  43. package/src/sap/ui/unified/calendar/Header.js +1 -1
  44. package/src/sap/ui/unified/calendar/HeaderRenderer.js +0 -2
  45. package/src/sap/ui/unified/calendar/IndexPicker.js +1 -1
  46. package/src/sap/ui/unified/calendar/Month.js +12 -12
  47. package/src/sap/ui/unified/calendar/MonthPicker.js +1 -1
  48. package/src/sap/ui/unified/calendar/MonthRenderer.js +1 -1
  49. package/src/sap/ui/unified/calendar/MonthsRow.js +1 -1
  50. package/src/sap/ui/unified/calendar/OneMonthDatesRow.js +1 -1
  51. package/src/sap/ui/unified/calendar/TimesRow.js +1 -1
  52. package/src/sap/ui/unified/calendar/TimesRowRenderer.js +21 -2
  53. package/src/sap/ui/unified/calendar/YearPicker.js +19 -16
  54. package/src/sap/ui/unified/calendar/YearRangePicker.js +3 -3
  55. package/src/sap/ui/unified/library.js +12 -15
  56. package/src/sap/ui/unified/messagebundle.properties +3 -0
  57. package/src/sap/ui/unified/messagebundle_ar.properties +2 -0
  58. package/src/sap/ui/unified/messagebundle_bg.properties +2 -0
  59. package/src/sap/ui/unified/messagebundle_ca.properties +2 -0
  60. package/src/sap/ui/unified/messagebundle_cs.properties +2 -0
  61. package/src/sap/ui/unified/messagebundle_cy.properties +2 -0
  62. package/src/sap/ui/unified/messagebundle_da.properties +2 -0
  63. package/src/sap/ui/unified/messagebundle_de.properties +2 -0
  64. package/src/sap/ui/unified/messagebundle_el.properties +2 -0
  65. package/src/sap/ui/unified/messagebundle_en.properties +2 -0
  66. package/src/sap/ui/unified/messagebundle_en_GB.properties +2 -0
  67. package/src/sap/ui/unified/messagebundle_en_US_sappsd.properties +2 -0
  68. package/src/sap/ui/unified/messagebundle_en_US_saprigi.properties +6 -0
  69. package/src/sap/ui/unified/messagebundle_en_US_saptrc.properties +2 -0
  70. package/src/sap/ui/unified/messagebundle_es.properties +2 -0
  71. package/src/sap/ui/unified/messagebundle_es_MX.properties +2 -0
  72. package/src/sap/ui/unified/messagebundle_et.properties +2 -0
  73. package/src/sap/ui/unified/messagebundle_fi.properties +2 -0
  74. package/src/sap/ui/unified/messagebundle_fr.properties +2 -0
  75. package/src/sap/ui/unified/messagebundle_fr_CA.properties +2 -0
  76. package/src/sap/ui/unified/messagebundle_hi.properties +2 -0
  77. package/src/sap/ui/unified/messagebundle_hr.properties +2 -0
  78. package/src/sap/ui/unified/messagebundle_hu.properties +2 -0
  79. package/src/sap/ui/unified/messagebundle_id.properties +2 -0
  80. package/src/sap/ui/unified/messagebundle_it.properties +2 -0
  81. package/src/sap/ui/unified/messagebundle_iw.properties +2 -0
  82. package/src/sap/ui/unified/messagebundle_ja.properties +2 -0
  83. package/src/sap/ui/unified/messagebundle_kk.properties +2 -0
  84. package/src/sap/ui/unified/messagebundle_ko.properties +2 -0
  85. package/src/sap/ui/unified/messagebundle_lt.properties +2 -0
  86. package/src/sap/ui/unified/messagebundle_lv.properties +2 -0
  87. package/src/sap/ui/unified/messagebundle_ms.properties +2 -0
  88. package/src/sap/ui/unified/messagebundle_nl.properties +2 -0
  89. package/src/sap/ui/unified/messagebundle_no.properties +2 -0
  90. package/src/sap/ui/unified/messagebundle_pl.properties +2 -0
  91. package/src/sap/ui/unified/messagebundle_pt.properties +2 -0
  92. package/src/sap/ui/unified/messagebundle_pt_PT.properties +2 -0
  93. package/src/sap/ui/unified/messagebundle_ro.properties +2 -0
  94. package/src/sap/ui/unified/messagebundle_ru.properties +2 -0
  95. package/src/sap/ui/unified/messagebundle_sh.properties +2 -0
  96. package/src/sap/ui/unified/messagebundle_sk.properties +2 -0
  97. package/src/sap/ui/unified/messagebundle_sl.properties +2 -0
  98. package/src/sap/ui/unified/messagebundle_sv.properties +2 -0
  99. package/src/sap/ui/unified/messagebundle_th.properties +2 -0
  100. package/src/sap/ui/unified/messagebundle_tr.properties +2 -0
  101. package/src/sap/ui/unified/messagebundle_uk.properties +2 -0
  102. package/src/sap/ui/unified/messagebundle_vi.properties +2 -0
  103. package/src/sap/ui/unified/messagebundle_zh_CN.properties +2 -0
  104. package/src/sap/ui/unified/messagebundle_zh_TW.properties +2 -0
  105. package/src/sap/ui/unified/rules/FileUploader.support.js +3 -3
  106. package/src/sap/ui/unified/themes/base/Calendar.less +3 -1
  107. package/src/sap/ui/unified/themes/base/CalendarLegend.less +1 -0
  108. package/src/sap/ui/unified/themes/base/ColorPicker.less +5 -1
  109. package/src/sap/ui/unified/themes/base/Menu.less +5 -9
  110. package/src/sap/ui/unified/themes/sap_hcb/CalendarLegend.less +4 -0
package/.eslintrc.json ADDED
@@ -0,0 +1,19 @@
1
+ {
2
+ "overrides": [
3
+ /*
4
+ * Productive code, sample and unit test code of sap.ui.unified has been cleaned up.
5
+ * No more references to the global jQuery allowed
6
+ */
7
+ {
8
+ "files": [
9
+ "src/**/*.js",
10
+ "test/sap/ui/unified/demokit/**/*.js",
11
+ "test/sap/ui/unified/sample/**/*.js",
12
+ "test/sap/ui/unified/qunit/**/*.js"
13
+ ],
14
+ "globals": {
15
+ "jQuery": "off"
16
+ }
17
+ }
18
+ ]
19
+ }
package/THIRDPARTY.txt CHANGED
@@ -400,7 +400,7 @@ Contained in: src/sap.ui.mdc/test/sap/ui/mdc/sample/field/filterfieldwithoperato
400
400
 
401
401
  Library: sap.ui.webc.common:
402
402
 
403
- Component: UI5 Web Components, version: 1.0.0-rc.12
403
+ Component: UI5 Web Components, version: 1.1.2
404
404
  Copyright: SAP
405
405
  License: Apache-2.0
406
406
  License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
@@ -411,7 +411,7 @@ Contained in: src/sap.ui.webc.common/src/sap/ui/webc/common/thirdparty/base/*.*
411
411
  src/sap.ui.webc.common/src/sap/ui/webc/common/thirdparty/icons-tnt/*.*
412
412
  src/sap.ui.webc.common/src/sap/ui/webc/common/thirdparty/icons-business-suite/*.*
413
413
 
414
- Component: lit-html, version: 1.4.1
414
+ Component: lit-html, version: 2.0.1
415
415
  Copyright: Google LLC
416
416
  License: BSD-3-Clause
417
417
  License Text: https://github.com/SAP/openui5/blob/master/LICENSES/BSD-3-Clause.txt
@@ -420,7 +420,7 @@ Contained in: src/sap.ui.webc.common/src/sap/ui/webc/common/thirdparty/lit-html/
420
420
 
421
421
  Library: sap.ui.webc.fiori:
422
422
 
423
- Component: UI5 Web Components, version: 1.0.0-rc.12
423
+ Component: UI5 Web Components, version: 1.1.2
424
424
  Copyright: SAP
425
425
  License: Apache-2.0
426
426
  License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
@@ -429,7 +429,7 @@ Contained in: src/sap.ui.webc.fiori/src/sap/ui/webc/fiori/thirdparty/*.*
429
429
 
430
430
  Library: sap.ui.webc.main:
431
431
 
432
- Component: UI5 Web Components, version: 1.0.0-rc.12
432
+ Component: UI5 Web Components, version: 1.1.2
433
433
  Copyright: SAP
434
434
  License: Apache-2.0
435
435
  License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
@@ -450,7 +450,7 @@ License: Apache-2.0
450
450
  License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
451
451
  Contained in: lib/jsdoc/ui5/plugin.js
452
452
 
453
- Component: SAP Theming Base Content, version: 11.1.36-SNAPSHOT
453
+ Component: SAP Theming Base Content, version: 11.1.39
454
454
  Copyright: SAP SE or an SAP affiliate company and Theming Base Content contributors
455
455
  License: Apache-2.0
456
456
  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.ui.unified",
3
- "version": "1.100.0",
3
+ "version": "1.102.1",
4
4
  "description": "OpenUI5 UI Library sap.ui.unified",
5
5
  "author": "SAP SE (https://www.sap.com)",
6
6
  "license": "Apache-2.0",
@@ -14,6 +14,6 @@
14
14
  "url": "https://github.com/SAP/openui5.git"
15
15
  },
16
16
  "dependencies": {
17
- "@openui5/sap.ui.core": "1.100.0"
17
+ "@openui5/sap.ui.core": "1.102.1"
18
18
  }
19
19
  }
@@ -6,7 +6,7 @@
6
6
  <copyright>OpenUI5
7
7
  * (c) Copyright 2009-2022 SAP SE or an SAP affiliate company.
8
8
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.</copyright>
9
- <version>1.100.0</version>
9
+ <version>1.102.1</version>
10
10
 
11
11
  <documentation>Unified controls intended for both, mobile and desktop scenarios</documentation>
12
12
 
@@ -70,7 +70,7 @@ sap.ui.define([
70
70
  * Basic Calendar.
71
71
  * This calendar is used for DatePickers
72
72
  * @extends sap.ui.core.Control
73
- * @version 1.100.0
73
+ * @version 1.102.1
74
74
  *
75
75
  * @constructor
76
76
  * @public
@@ -563,6 +563,13 @@ sap.ui.define([
563
563
  }
564
564
  this._bInitMonth = undefined;
565
565
  }
566
+
567
+ var oSecondMonthHeader = this.getAggregation("secondMonthHeader");
568
+ if (oSecondMonthHeader.getDomRef()) {
569
+ // Second month header buttons are unreachable via keyboard
570
+ oSecondMonthHeader.getDomRef("B1").setAttribute("tabindex", "-1");
571
+ oSecondMonthHeader.getDomRef("B2").setAttribute("tabindex", "-1");
572
+ }
566
573
  };
567
574
 
568
575
  Calendar.prototype.removeSelectedDate = function(oSelectedDate) {
@@ -771,22 +778,6 @@ sap.ui.define([
771
778
 
772
779
  };
773
780
 
774
- /**
775
- * sets the Popup mode
776
- * e.G. Tab-chain should not leave calendar
777
- * only for internal use
778
- * @param {boolean} bPoupupMode <code>PopupMode</code>
779
- * @returns {this} <code>this</code> to allow method chaining
780
- * @private
781
- */
782
- Calendar.prototype.setPopupMode = function(bPoupupMode){
783
-
784
- this._bPoupupMode = bPoupupMode;
785
-
786
- return this;
787
-
788
- };
789
-
790
781
  Calendar.prototype.setMonths = function(iMonths){
791
782
 
792
783
  this._bDateRangeChanged = undefined; // to force rerendering
@@ -1197,238 +1188,6 @@ sap.ui.define([
1197
1188
 
1198
1189
  Calendar.prototype.onsaphide = Calendar.prototype.onsapshow;
1199
1190
 
1200
- Calendar.prototype.onsaptabnext = function(oEvent){
1201
- var oHeader = this.getAggregation("header");
1202
-
1203
- if (containsOrEquals(this.getDomRef("content"), oEvent.target)) {
1204
- if (oHeader.getVisibleButton1()) {
1205
- oHeader.getDomRef("B1").focus();
1206
- oEvent.preventDefault();
1207
- } else if (oHeader.getVisibleButton2()) {
1208
- oHeader.getDomRef("B2").focus();
1209
- oEvent.preventDefault();
1210
- } else if (oHeader.getVisibleCurrentDateButton()) {
1211
- oHeader.getDomRef("today").focus();
1212
- oEvent.preventDefault();
1213
- } else if (!this._bPoupupMode) {
1214
- // remove Tabindex from day, month, year - to break cycle
1215
- this._clearTabindex0();
1216
- } else {
1217
- this._clearTabindex0();
1218
- oEvent.preventDefault();
1219
- }
1220
- } else if (oEvent.target.id === oHeader.getId() + "-B1") {
1221
- oHeader.getVisibleButton2() && oHeader.getDomRef("B2").focus();
1222
- oEvent.preventDefault();
1223
- } else if (oEvent.target.id === oHeader.getId() + "-B2") {
1224
- if (oHeader.getVisibleCurrentDateButton()) {
1225
- oHeader.getDomRef("today").focus();
1226
- oEvent.preventDefault();
1227
- } else {
1228
- this._tabNextFinalize(this._bPoupupMode, oEvent);
1229
- }
1230
- } else if (oEvent.target.id === oHeader.getId() + "-today") {
1231
- this._tabNextFinalize(this._bPoupupMode, oEvent);
1232
- }
1233
-
1234
- };
1235
-
1236
- Calendar.prototype._tabNextFinalize = function(bPopupMode, oEvent) {
1237
- if (bPopupMode) {
1238
- this._moveFocusToCalContent();
1239
- oEvent.preventDefault();
1240
- } else {
1241
- // remove Tabindex from day, month, year - to break cycle
1242
- this._clearTabindex0();
1243
- }
1244
- };
1245
-
1246
- Calendar.prototype.onsaptabprevious = function(oEvent){
1247
- var oHeader = this.getAggregation("header");
1248
- if (containsOrEquals(this.getDomRef("content"), oEvent.target)) {
1249
- if (this._bPoupupMode) {
1250
- if (oHeader.getVisibleCurrentDateButton()) {
1251
- oHeader.getDomRef("today").focus();
1252
- } else if (oHeader.getVisibleButton2()) {
1253
- oHeader.getDomRef("B2").focus();
1254
- } else {
1255
- oHeader.getVisibleButton1() && oHeader.getDomRef("B1").focus();
1256
- }
1257
- oEvent.preventDefault();
1258
- } else {
1259
- // remove Tabindex from day, month, year - to break cycle
1260
- this._clearTabindex0();
1261
- }
1262
- } else if (oEvent.target.id === oHeader.getId() + "-B1") {
1263
- this._moveFocusToCalContent();
1264
- oEvent.preventDefault();
1265
- } else if (oEvent.target.id === oHeader.getId() + "-B2") {
1266
- if (oHeader.getVisibleButton1()) {
1267
- oHeader.getDomRef("B1").focus();
1268
- } else {
1269
- this._moveFocusToCalContent();
1270
- }
1271
-
1272
- oEvent.preventDefault();
1273
- } else if (oEvent.target.id === oHeader.getId() + "-today") {
1274
- if (oHeader.getVisibleButton2()) {
1275
- oHeader.getDomRef("B2").focus();
1276
- } else if (oHeader.getVisibleButton1()){
1277
- oHeader.getDomRef("B1").focus();
1278
- } else {
1279
- this._moveFocusToCalContent();
1280
- }
1281
-
1282
- oEvent.preventDefault();
1283
- }
1284
- };
1285
-
1286
- Calendar.prototype._clearTabindex0 = function() {
1287
- var aMonths = this.getAggregation("month"),
1288
- oMonthPicker = this._getMonthPicker(),
1289
- oYearPicker = this.getAggregation("yearPicker"),
1290
- oYearRangePicker = this.getAggregation("yearRangePicker"),
1291
- oMonth, i;
1292
-
1293
- // remove Tabindex from day, month, year - to break cycle
1294
- for (i = 0; i < aMonths.length; i++) {
1295
- oMonth = aMonths[i];
1296
- if (oMonth._oItemNavigation) {
1297
- oMonth._oItemNavigation.getItemDomRefs()[oMonth._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "-1");
1298
- }
1299
- }
1300
- if (!this._getSucessorsPickerPopup()) {
1301
- if (oMonthPicker.getDomRef()) {
1302
- oMonthPicker._oItemNavigation.getItemDomRefs()[oMonthPicker._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "-1");
1303
- }
1304
- if (oYearPicker.getDomRef()) {
1305
- oYearPicker._oItemNavigation.getItemDomRefs()[oYearPicker._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "-1");
1306
- }
1307
- if (oYearRangePicker.getDomRef()) {
1308
- oYearRangePicker._oItemNavigation.getItemDomRefs()[oYearRangePicker._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "-1");
1309
- }
1310
- }
1311
- };
1312
-
1313
- Calendar.prototype._moveFocusToCalContent = function() {
1314
- var oYearPicker = this.getAggregation("yearPicker"),
1315
- oYearRangePicker = this.getAggregation("yearRangePicker"),
1316
- oMonthPicker = this._getMonthPicker(),
1317
- aMonths = this.getAggregation("month"),
1318
- oMonth, oMonthDate,
1319
- oFocusedDate, i;
1320
-
1321
- switch (this._iMode) {
1322
- case 0: // day picker
1323
- oFocusedDate = this._getFocusedDate();
1324
- for (i = 0; i < aMonths.length; i++) {
1325
- oMonth = aMonths[i];
1326
- oMonthDate = CalendarDate.fromLocalJSDate(oMonth.getDate(), this.getPrimaryCalendarType());
1327
- if (oFocusedDate.isSame(oMonthDate)) {
1328
- oMonth.focus();
1329
- } else {
1330
- oMonth._oItemNavigation.getItemDomRefs()[oMonth._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "0");
1331
- }
1332
- }
1333
- break;
1334
-
1335
- case 1: // month picker
1336
- if (!this._getSucessorsPickerPopup()) {
1337
- oMonthPicker.focus();
1338
- }
1339
- break;
1340
-
1341
- case 2: // year picker
1342
- if (!this._getSucessorsPickerPopup()) {
1343
- oYearPicker.focus();
1344
- }
1345
- break;
1346
-
1347
- case 3: // year range picker
1348
- if (!this._getSucessorsPickerPopup()) {
1349
- oYearRangePicker.focus();
1350
- }
1351
- break;
1352
-
1353
- // no default
1354
- }
1355
- };
1356
-
1357
- Calendar.prototype.onfocusin = function(oEvent){
1358
-
1359
- if (oEvent.target.id == this.getId() + "-end") {
1360
- // focus via tab+shift (otherwise not possible to go to this element)
1361
- this._focusOnShiftTab();
1362
-
1363
- if (!this._bPoupupMode) {
1364
- // remove Tabindex from day, month, year - to break cycle
1365
- this._clearTabindex0();
1366
- }
1367
- }
1368
-
1369
- // remove tabindex of dummy element if focus is inside calendar
1370
- this.$("end").attr("tabindex", "-1");
1371
-
1372
- };
1373
-
1374
- Calendar.prototype._focusOnShiftTab = function() {
1375
- var oHeader = this.getAggregation("header"),
1376
- oDomRefB2 = oHeader.getDomRef("B2"),
1377
- oDomRefToday = oHeader.getDomRef("today");
1378
-
1379
- if (oDomRefToday) {
1380
- oDomRefToday.focus();
1381
- } else if (oDomRefB2) {
1382
- oDomRefB2.focus();
1383
- } else {
1384
- this.focus();
1385
- }
1386
- };
1387
-
1388
- Calendar.prototype.onsapfocusleave = function(oEvent){
1389
- var aMonths,
1390
- oMonth,
1391
- oMonthPicker,
1392
- oYearPicker;
1393
-
1394
- if (!oEvent.relatedControlId || !containsOrEquals(this.getDomRef(), sap.ui.getCore().byId(oEvent.relatedControlId).getFocusDomRef())) {
1395
- // put dummy element back to tab-chain
1396
- this.$("end").attr("tabindex", "0");
1397
-
1398
- if (!this._bPoupupMode) {
1399
- // restore Tabindex from day, month, year
1400
- aMonths = this.getAggregation("month");
1401
-
1402
- switch (this._iMode) {
1403
- case 0: // day picker
1404
- for (var i = 0; i < aMonths.length; i++) {
1405
- oMonth = aMonths[i];
1406
- if (oMonth._oItemNavigation) {
1407
- oMonth._oItemNavigation.getItemDomRefs()[oMonth._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "0");
1408
- }
1409
- }
1410
- break;
1411
-
1412
- case 1: // month picker
1413
- if (!this._getSucessorsPickerPopup()) {
1414
- oMonthPicker = this._getMonthPicker();
1415
- oMonthPicker._oItemNavigation.getItemDomRefs()[oMonthPicker._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "0");
1416
- }
1417
- break;
1418
-
1419
- case 2: // year picker
1420
- if (!this._getSucessorsPickerPopup()) {
1421
- oYearPicker = this._getYearPicker();
1422
- oYearPicker._oItemNavigation.getItemDomRefs()[oYearPicker._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "0");
1423
- }
1424
- break;
1425
- // no default
1426
- }
1427
- }
1428
- }
1429
-
1430
- };
1431
-
1432
1191
  Calendar.prototype.getFocusDomRef = function(){
1433
1192
 
1434
1193
  // set focus on the day
@@ -5,8 +5,8 @@
5
5
  */
6
6
 
7
7
  // Provides control sap.ui.unified.CalendarAppointment.
8
- sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/format/NumberFormat', './library', "sap/base/Log"],
9
- function(DateTypeRange, DateFormat, NumberFormat, library, Log) {
8
+ sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/format/NumberFormat', 'sap/ui/core/format/TimezoneUtil', 'sap/ui/core/Core', './calendar/CalendarUtils', './library', "sap/base/Log"],
9
+ function(DateTypeRange, DateFormat, NumberFormat, TimezoneUtil, Core, CalendarUtils, library, Log) {
10
10
  "use strict";
11
11
 
12
12
  /**
@@ -21,7 +21,7 @@ sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/
21
21
  *
22
22
  * Applications could inherit from this element to add own fields.
23
23
  * @extends sap.ui.unified.DateTypeRange
24
- * @version 1.100.0
24
+ * @version 1.102.1
25
25
  *
26
26
  * @constructor
27
27
  * @public
@@ -125,8 +125,8 @@ sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/
125
125
  * @private
126
126
  */
127
127
  CalendarAppointment.prototype._getDateRangeIntersectionText = function (oCurrentlyDisplayedDate) {
128
- var oStartDate = this.getStartDate(),
129
- oEndDate = this.getEndDate() ? this.getEndDate() : new Date(864000000000000), //in case of emergency call this number
128
+ var oStartDate = this._getStartDateWithTimezoneAdaptation(),
129
+ oEndDate = this._getEndDateWithTimezoneAdaptation() ? this._getEndDateWithTimezoneAdaptation() : new Date(864000000000000), //in case of emergency call this number
130
130
  sFirstLineText,
131
131
  sSecondLineText,
132
132
  oCurrentDayStart = new Date(oCurrentlyDisplayedDate.getFullYear(), oCurrentlyDisplayedDate.getMonth(), oCurrentlyDisplayedDate.getDate(), 0, 0, 0),
@@ -185,10 +185,10 @@ sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/
185
185
  iNextDayStart = iCurrentDayStartTime + ONE_DAY;
186
186
 
187
187
  return function(oAppInfo1, oAppInfo2) {
188
- var iStartDateTime1 = oAppInfo1.appointment.getStartDate().getTime(),
189
- iStartDateTime2 = oAppInfo2.appointment.getStartDate().getTime(),
190
- iEndDateTime1 = oAppInfo1.appointment.getEndDate() ? oAppInfo1.appointment.getEndDate().getTime() : 864000000000000, //this is max date in case of no max date
191
- iEndDateTime2 = oAppInfo2.appointment.getEndDate() ? oAppInfo2.appointment.getEndDate().getTime() : 864000000000000,
188
+ var iStartDateTime1 = oAppInfo1.appointment._getStartDateWithTimezoneAdaptation().getTime(),
189
+ iStartDateTime2 = oAppInfo2.appointment._getStartDateWithTimezoneAdaptation().getTime(),
190
+ iEndDateTime1 = oAppInfo1.appointment._getEndDateWithTimezoneAdaptation() ? oAppInfo1.appointment._getEndDateWithTimezoneAdaptation().getTime() : 864000000000000, //this is max date in case of no max date
191
+ iEndDateTime2 = oAppInfo2.appointment._getEndDateWithTimezoneAdaptation() ? oAppInfo2.appointment._getEndDateWithTimezoneAdaptation().getTime() : 864000000000000,
192
192
  bWholeDay1 = iStartDateTime1 <= iCurrentDayStartTime && iEndDateTime1 >= iNextDayStart,
193
193
  bWholeDay2 = iStartDateTime2 <= iCurrentDayStartTime && iEndDateTime2 >= iNextDayStart,
194
194
  iResult;
@@ -253,6 +253,43 @@ sap.ui.define(['./DateTypeRange', 'sap/ui/core/format/DateFormat', 'sap/ui/core/
253
253
  return oAppointmentParts.length > 0 ? oAppointmentParts[0] : null;
254
254
  };
255
255
 
256
+ CalendarAppointment.prototype._getEndDateWithTimezoneAdaptation = function() {
257
+ if (!this.getProperty("endDate")) {
258
+ return null;
259
+ }
260
+
261
+ var oEndDate = this._convertToTimezone(this.getEndDate());
262
+
263
+ return oEndDate;
264
+ };
265
+
266
+ CalendarAppointment.prototype._getStartDateWithTimezoneAdaptation = function() {
267
+ if (!this.getProperty("startDate")) {
268
+ return null;
269
+ }
270
+
271
+ var oStartDate = this._convertToTimezone(this.getStartDate());
272
+
273
+ return oStartDate;
274
+ };
275
+
276
+ /**
277
+ * Aligns a date to the timezone from the configuration.
278
+ *
279
+ * @returns {Object} <code>oNewDate</code> aligned to the configured timezone.
280
+ * @private
281
+ */
282
+ CalendarAppointment.prototype._convertToTimezone = function(oDate) {
283
+ var sTimezone = Core.getConfiguration().getTimezone();
284
+ var oNewDate = CalendarUtils._createUniversalUTCDate(oDate, undefined, true);
285
+
286
+ oNewDate = new Date(oDate.getUTCFullYear(), oDate.getUTCMonth(), oDate.getUTCDate(), oDate.getUTCHours(), oDate.getUTCMinutes(), oDate.getUTCSeconds());
287
+ oNewDate.setUTCFullYear(oDate.getUTCFullYear());
288
+ oNewDate = TimezoneUtil.convertToTimezone(oNewDate, sTimezone);
289
+
290
+ return oNewDate;
291
+ };
292
+
256
293
  return CalendarAppointment;
257
294
 
258
295
  });
@@ -18,6 +18,7 @@ sap.ui.define([
18
18
  "./CalendarDateIntervalRenderer",
19
19
  "sap/base/util/deepEqual",
20
20
  "sap/m/Popover",
21
+ "sap/ui/core/CalendarType",
21
22
  "sap/ui/core/Core",
22
23
  "sap/base/Log",
23
24
  "sap/ui/thirdparty/jquery",
@@ -35,6 +36,7 @@ sap.ui.define([
35
36
  CalendarDateIntervalRenderer,
36
37
  deepEqual,
37
38
  Popover,
39
+ CalendarType,
38
40
  Core,
39
41
  Log,
40
42
  jQuery,
@@ -42,11 +44,10 @@ sap.ui.define([
42
44
  ) {
43
45
  "use strict";
44
46
 
45
- var CalendarType = sap.ui.core.CalendarType;
46
47
  /*
47
- * Inside the CalendarDateInterval CalendarDate objects are used. But in the API JS dates are used.
48
- * So conversion must be done on API functions.
49
- */
48
+ * Inside the CalendarDateInterval CalendarDate objects are used. But in the API JS dates are used.
49
+ * So conversion must be done on API functions.
50
+ */
50
51
 
51
52
  /**
52
53
  * Constructor for a new <code>CalendarDateInterval</code>.
@@ -57,7 +58,7 @@ sap.ui.define([
57
58
  * @class
58
59
  * <code>CalendarDateInterval</code> only visualizes the dates in a one-line interval and allows the selection of a single day.
59
60
  * @extends sap.ui.unified.Calendar
60
- * @version 1.100.0
61
+ * @version 1.102.1
61
62
  *
62
63
  * @constructor
63
64
  * @public
@@ -262,7 +263,6 @@ sap.ui.define([
262
263
 
263
264
  if (!this._oCalendar) {
264
265
  oCalendar = new Calendar(this.getId() + "--Cal");
265
- oCalendar.setPopupMode(true);
266
266
  oCalendar.attachEvent("select", this._handleCalendarPickerDateSelect, this);
267
267
  oCalendar.attachEvent("cancel", function (oEvent) {
268
268
  this._closeCalendarPicker(true);
@@ -388,14 +388,6 @@ sap.ui.define([
388
388
 
389
389
  if (!bSkipFocus) {
390
390
  this._renderMonth(); // to focus date
391
-
392
- // restore tabindex
393
- var aMonths = this.getAggregation("month");
394
-
395
- for (var i = 0; i < aMonths.length; i++) {
396
- var oMonth = aMonths[i];
397
- oMonth._oItemNavigation.getItemDomRefs()[oMonth._oItemNavigation.getFocusedIndex()].setAttribute("tabindex", "0");
398
- }
399
391
  }
400
392
 
401
393
  this._getCalendar()._closePickers();
@@ -33,7 +33,7 @@ sap.ui.define([
33
33
  * @extends sap.ui.core.Control
34
34
  *
35
35
  * @author SAP SE
36
- * @version 1.100.0
36
+ * @version 1.102.1
37
37
  *
38
38
  * @constructor
39
39
  * @public
@@ -21,7 +21,7 @@ sap.ui.define(['sap/ui/core/Element', './library'],
21
21
  * @class
22
22
  * Item to be displayed in a CalendarLegend.
23
23
  * @extends sap.ui.core.Element
24
- * @version 1.100.0
24
+ * @version 1.102.1
25
25
  *
26
26
  * @constructor
27
27
  * @public