@syncfusion/ej2-ribbon 25.2.3 → 26.1.35

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 (117) hide show
  1. package/.eslintrc.json +3 -2
  2. package/dist/ej2-ribbon.umd.min.js +2 -2
  3. package/dist/ej2-ribbon.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-ribbon.es2015.js +884 -599
  5. package/dist/es6/ej2-ribbon.es2015.js.map +1 -1
  6. package/dist/es6/ej2-ribbon.es5.js +941 -584
  7. package/dist/es6/ej2-ribbon.es5.js.map +1 -1
  8. package/dist/global/ej2-ribbon.min.js +2 -2
  9. package/dist/global/ej2-ribbon.min.js.map +1 -1
  10. package/dist/global/index.d.ts +1 -1
  11. package/package.json +13 -13
  12. package/src/ribbon/base/interface.d.ts +14 -0
  13. package/src/ribbon/base/ribbon-model.d.ts +1 -1
  14. package/src/ribbon/base/ribbon.d.ts +4 -1
  15. package/src/ribbon/base/ribbon.js +222 -95
  16. package/src/ribbon/items/ribbon-button.js +22 -2
  17. package/src/ribbon/items/ribbon-checkbox.js +19 -1
  18. package/src/ribbon/items/ribbon-colorpicker.js +16 -1
  19. package/src/ribbon/items/ribbon-combobox.js +19 -1
  20. package/src/ribbon/items/ribbon-dropdown.js +16 -1
  21. package/src/ribbon/items/ribbon-gallery.d.ts +15 -6
  22. package/src/ribbon/items/ribbon-gallery.js +164 -96
  23. package/src/ribbon/items/ribbon-groupbutton.d.ts +1 -0
  24. package/src/ribbon/items/ribbon-groupbutton.js +11 -3
  25. package/src/ribbon/items/ribbon-splitbutton.js +16 -1
  26. package/src/ribbon/models/ribbon-contextual-tab-settings-model.d.ts +1 -1
  27. package/src/ribbon/models/ribbon-gallery-group-model.d.ts +5 -5
  28. package/src/ribbon/models/ribbon-gallery-group.d.ts +2 -2
  29. package/src/ribbon/models/ribbon-gallery-group.js +2 -2
  30. package/src/ribbon/models/ribbon-gallery-item-model.d.ts +5 -5
  31. package/src/ribbon/models/ribbon-gallery-item.d.ts +1 -1
  32. package/src/ribbon/models/ribbon-gallery-item.js +1 -1
  33. package/src/ribbon/models/ribbon-gallery-settings-model.d.ts +1 -1
  34. package/src/ribbon/models/ribbon-gallery-settings.d.ts +3 -3
  35. package/src/ribbon/models/ribbon-gallery-settings.js +2 -2
  36. package/src/ribbon/modules/ribbon-backstage.d.ts +6 -3
  37. package/src/ribbon/modules/ribbon-backstage.js +65 -12
  38. package/src/ribbon/modules/ribbon-contextualtab.js +5 -2
  39. package/src/ribbon/modules/ribbon-keytip.d.ts +1 -0
  40. package/src/ribbon/modules/ribbon-keytip.js +58 -46
  41. package/styles/bootstrap-dark.css +452 -269
  42. package/styles/bootstrap-dark.scss +18 -1
  43. package/styles/bootstrap.css +456 -276
  44. package/styles/bootstrap.scss +18 -1
  45. package/styles/bootstrap4.css +455 -272
  46. package/styles/bootstrap4.scss +18 -1
  47. package/styles/bootstrap5-dark.css +470 -278
  48. package/styles/bootstrap5-dark.scss +18 -1
  49. package/styles/bootstrap5.css +470 -278
  50. package/styles/bootstrap5.scss +18 -1
  51. package/styles/fabric-dark.css +451 -269
  52. package/styles/fabric-dark.scss +18 -1
  53. package/styles/fabric.css +450 -272
  54. package/styles/fabric.scss +18 -1
  55. package/styles/fluent-dark.css +472 -277
  56. package/styles/fluent-dark.scss +18 -1
  57. package/styles/fluent.css +472 -277
  58. package/styles/fluent.scss +18 -1
  59. package/styles/fluent2.css +3868 -0
  60. package/styles/fluent2.scss +18 -0
  61. package/styles/highcontrast-light.css +445 -263
  62. package/styles/highcontrast-light.scss +17 -1
  63. package/styles/highcontrast.css +451 -273
  64. package/styles/highcontrast.scss +18 -1
  65. package/styles/material-dark.css +540 -283
  66. package/styles/material-dark.scss +18 -1
  67. package/styles/material.css +539 -289
  68. package/styles/material.scss +18 -1
  69. package/styles/material3-dark.css +496 -280
  70. package/styles/material3-dark.scss +18 -1
  71. package/styles/material3.css +496 -280
  72. package/styles/material3.scss +18 -1
  73. package/styles/ribbon/_bds-definition.scss +56 -20
  74. package/styles/ribbon/_bootstrap-dark-definition.scss +56 -20
  75. package/styles/ribbon/_bootstrap-definition.scss +57 -21
  76. package/styles/ribbon/_bootstrap4-definition.scss +57 -21
  77. package/styles/ribbon/_bootstrap5-definition.scss +57 -21
  78. package/styles/ribbon/_bootstrap5.3-definition.scss +396 -0
  79. package/styles/ribbon/_fabric-dark-definition.scss +55 -19
  80. package/styles/ribbon/_fabric-definition.scss +56 -20
  81. package/styles/ribbon/_fluent-definition.scss +59 -23
  82. package/styles/ribbon/_fluent2-definition.scss +396 -0
  83. package/styles/ribbon/_fusionnew-definition.scss +50 -14
  84. package/styles/ribbon/_highcontrast-definition.scss +58 -22
  85. package/styles/ribbon/_highcontrast-light-definition.scss +49 -13
  86. package/styles/ribbon/_layout.scss +359 -399
  87. package/styles/ribbon/_material-dark-definition.scss +56 -20
  88. package/styles/ribbon/_material-definition.scss +56 -20
  89. package/styles/ribbon/_material3-definition.scss +56 -19
  90. package/styles/ribbon/_tailwind-definition.scss +56 -20
  91. package/styles/ribbon/_theme.scss +118 -170
  92. package/styles/ribbon/bootstrap-dark.css +452 -269
  93. package/styles/ribbon/bootstrap.css +456 -276
  94. package/styles/ribbon/bootstrap4.css +455 -272
  95. package/styles/ribbon/bootstrap5-dark.css +470 -278
  96. package/styles/ribbon/bootstrap5.css +470 -278
  97. package/styles/ribbon/fabric-dark.css +451 -269
  98. package/styles/ribbon/fabric.css +450 -272
  99. package/styles/ribbon/fluent-dark.css +472 -277
  100. package/styles/ribbon/fluent.css +472 -277
  101. package/styles/ribbon/fluent2.css +3868 -0
  102. package/styles/ribbon/fluent2.scss +18 -0
  103. package/styles/ribbon/highcontrast-light.css +445 -263
  104. package/styles/ribbon/highcontrast.css +451 -273
  105. package/styles/ribbon/icons/_bootstrap5.3.scss +9 -0
  106. package/styles/ribbon/icons/_fluent2.scss +9 -0
  107. package/styles/ribbon/material-dark.css +540 -283
  108. package/styles/ribbon/material.css +539 -289
  109. package/styles/ribbon/material3-dark.css +496 -280
  110. package/styles/ribbon/material3.css +496 -280
  111. package/styles/ribbon/tailwind-dark.css +506 -280
  112. package/styles/ribbon/tailwind.css +506 -280
  113. package/styles/tailwind-dark.css +506 -280
  114. package/styles/tailwind-dark.scss +18 -1
  115. package/styles/tailwind.css +506 -280
  116. package/styles/tailwind.scss +18 -1
  117. package/CHANGELOG.md +0 -93
@@ -1,10 +1,10 @@
1
- import { ChildProperty, Collection, Complex, Component, Event, EventHandler, KeyboardEvents, NotifyPropertyChanges, Property, addClass, append, closest, compile, formatUnit, getComponent, getInstance, getUniqueID, isNullOrUndefined, isUndefined, merge, remove, removeClass, select } from '@syncfusion/ej2-base';
2
- import { HScroll, Menu, MenuAnimationSettings, MenuItem, Tab, TabAnimationSettings, Toolbar } from '@syncfusion/ej2-navigations';
3
- import { ComboBox, FieldSettings } from '@syncfusion/ej2-dropdowns';
4
- import { DropDownButton, Item, SplitButton } from '@syncfusion/ej2-splitbuttons';
1
+ import { ChildProperty, Property, Event, Complex, Collection, getComponent, merge, EventHandler, isNullOrUndefined, closest, remove, select, compile, addClass, setValue, formatUnit, append, Component, getUniqueID, KeyboardEvents, getInstance, isUndefined, removeClass, NotifyPropertyChanges } from '@syncfusion/ej2-base';
2
+ import { MenuItem, MenuAnimationSettings, Tab, Toolbar, HScroll, TabAnimationSettings, Menu } from '@syncfusion/ej2-navigations';
3
+ import { FieldSettings, ComboBox } from '@syncfusion/ej2-dropdowns';
4
+ import { Item, DropDownButton, SplitButton } from '@syncfusion/ej2-splitbuttons';
5
5
  import { Button, CheckBox } from '@syncfusion/ej2-buttons';
6
6
  import { ColorPicker } from '@syncfusion/ej2-inputs';
7
- import { Popup, Tooltip } from '@syncfusion/ej2-popups';
7
+ import { Tooltip, Popup } from '@syncfusion/ej2-popups';
8
8
 
9
9
  /**
10
10
  * Defines the layout types of ribbon.
@@ -135,7 +135,7 @@ var RibbonGroupButtonSelection;
135
135
  RibbonGroupButtonSelection["Multiple"] = "Multiple";
136
136
  })(RibbonGroupButtonSelection || (RibbonGroupButtonSelection = {}));
137
137
 
138
- var __decorate$5 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
138
+ var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
139
139
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
140
140
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
141
141
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -155,32 +155,32 @@ class RibbonButtonSettings extends ChildProperty {
155
155
  super.setProperties(prop, muteOnChange);
156
156
  }
157
157
  }
158
- __decorate$5([
158
+ __decorate([
159
159
  Property('')
160
160
  ], RibbonButtonSettings.prototype, "content", void 0);
161
- __decorate$5([
161
+ __decorate([
162
162
  Property('')
163
163
  ], RibbonButtonSettings.prototype, "cssClass", void 0);
164
- __decorate$5([
164
+ __decorate([
165
165
  Property('')
166
166
  ], RibbonButtonSettings.prototype, "iconCss", void 0);
167
- __decorate$5([
167
+ __decorate([
168
168
  Property(false)
169
169
  ], RibbonButtonSettings.prototype, "isToggle", void 0);
170
- __decorate$5([
170
+ __decorate([
171
171
  Property(false)
172
172
  ], RibbonButtonSettings.prototype, "isPrimary", void 0);
173
- __decorate$5([
173
+ __decorate([
174
174
  Property({})
175
175
  ], RibbonButtonSettings.prototype, "htmlAttributes", void 0);
176
- __decorate$5([
176
+ __decorate([
177
177
  Event()
178
178
  ], RibbonButtonSettings.prototype, "created", void 0);
179
- __decorate$5([
179
+ __decorate([
180
180
  Event()
181
181
  ], RibbonButtonSettings.prototype, "clicked", void 0);
182
182
 
183
- var __decorate$6 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
183
+ var __decorate$1 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
184
184
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
185
185
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
186
186
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -200,29 +200,29 @@ class RibbonCheckBoxSettings extends ChildProperty {
200
200
  super.setProperties(prop, muteOnChange);
201
201
  }
202
202
  }
203
- __decorate$6([
203
+ __decorate$1([
204
204
  Property(false)
205
205
  ], RibbonCheckBoxSettings.prototype, "checked", void 0);
206
- __decorate$6([
206
+ __decorate$1([
207
207
  Property('')
208
208
  ], RibbonCheckBoxSettings.prototype, "cssClass", void 0);
209
- __decorate$6([
209
+ __decorate$1([
210
210
  Property('')
211
211
  ], RibbonCheckBoxSettings.prototype, "label", void 0);
212
- __decorate$6([
212
+ __decorate$1([
213
213
  Property('After')
214
214
  ], RibbonCheckBoxSettings.prototype, "labelPosition", void 0);
215
- __decorate$6([
215
+ __decorate$1([
216
216
  Property({})
217
217
  ], RibbonCheckBoxSettings.prototype, "htmlAttributes", void 0);
218
- __decorate$6([
218
+ __decorate$1([
219
219
  Event()
220
220
  ], RibbonCheckBoxSettings.prototype, "created", void 0);
221
- __decorate$6([
221
+ __decorate$1([
222
222
  Event()
223
223
  ], RibbonCheckBoxSettings.prototype, "change", void 0);
224
224
 
225
- var __decorate$7 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
225
+ var __decorate$2 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
226
226
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
227
227
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
228
228
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -242,62 +242,62 @@ class RibbonColorPickerSettings extends ChildProperty {
242
242
  super.setProperties(prop, muteOnChange);
243
243
  }
244
244
  }
245
- __decorate$7([
245
+ __decorate$2([
246
246
  Property(10)
247
247
  ], RibbonColorPickerSettings.prototype, "columns", void 0);
248
- __decorate$7([
248
+ __decorate$2([
249
249
  Property('')
250
250
  ], RibbonColorPickerSettings.prototype, "cssClass", void 0);
251
- __decorate$7([
251
+ __decorate$2([
252
252
  Property('')
253
253
  ], RibbonColorPickerSettings.prototype, "label", void 0);
254
- __decorate$7([
254
+ __decorate$2([
255
255
  Property(true)
256
256
  ], RibbonColorPickerSettings.prototype, "enableOpacity", void 0);
257
- __decorate$7([
257
+ __decorate$2([
258
258
  Property('Palette')
259
259
  ], RibbonColorPickerSettings.prototype, "mode", void 0);
260
- __decorate$7([
260
+ __decorate$2([
261
261
  Property(true)
262
262
  ], RibbonColorPickerSettings.prototype, "modeSwitcher", void 0);
263
- __decorate$7([
263
+ __decorate$2([
264
264
  Property(false)
265
265
  ], RibbonColorPickerSettings.prototype, "noColor", void 0);
266
- __decorate$7([
266
+ __decorate$2([
267
267
  Property(null)
268
268
  ], RibbonColorPickerSettings.prototype, "presetColors", void 0);
269
- __decorate$7([
269
+ __decorate$2([
270
270
  Property(true)
271
271
  ], RibbonColorPickerSettings.prototype, "showButtons", void 0);
272
- __decorate$7([
272
+ __decorate$2([
273
273
  Property('#008000ff')
274
274
  ], RibbonColorPickerSettings.prototype, "value", void 0);
275
- __decorate$7([
275
+ __decorate$2([
276
276
  Property({})
277
277
  ], RibbonColorPickerSettings.prototype, "htmlAttributes", void 0);
278
- __decorate$7([
278
+ __decorate$2([
279
279
  Event()
280
280
  ], RibbonColorPickerSettings.prototype, "beforeClose", void 0);
281
- __decorate$7([
281
+ __decorate$2([
282
282
  Event()
283
283
  ], RibbonColorPickerSettings.prototype, "beforeOpen", void 0);
284
- __decorate$7([
284
+ __decorate$2([
285
285
  Event()
286
286
  ], RibbonColorPickerSettings.prototype, "beforeTileRender", void 0);
287
- __decorate$7([
287
+ __decorate$2([
288
288
  Event()
289
289
  ], RibbonColorPickerSettings.prototype, "created", void 0);
290
- __decorate$7([
290
+ __decorate$2([
291
291
  Event()
292
292
  ], RibbonColorPickerSettings.prototype, "change", void 0);
293
- __decorate$7([
293
+ __decorate$2([
294
294
  Event()
295
295
  ], RibbonColorPickerSettings.prototype, "open", void 0);
296
- __decorate$7([
296
+ __decorate$2([
297
297
  Event()
298
298
  ], RibbonColorPickerSettings.prototype, "select", void 0);
299
299
 
300
- var __decorate$8 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
300
+ var __decorate$3 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
301
301
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
302
302
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
303
303
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -317,95 +317,95 @@ class RibbonComboBoxSettings extends ChildProperty {
317
317
  super.setProperties(prop, muteOnChange);
318
318
  }
319
319
  }
320
- __decorate$8([
320
+ __decorate$3([
321
321
  Property(false)
322
322
  ], RibbonComboBoxSettings.prototype, "allowFiltering", void 0);
323
- __decorate$8([
323
+ __decorate$3([
324
324
  Property(true)
325
325
  ], RibbonComboBoxSettings.prototype, "autofill", void 0);
326
- __decorate$8([
326
+ __decorate$3([
327
327
  Property('')
328
328
  ], RibbonComboBoxSettings.prototype, "cssClass", void 0);
329
- __decorate$8([
329
+ __decorate$3([
330
330
  Property('')
331
331
  ], RibbonComboBoxSettings.prototype, "label", void 0);
332
- __decorate$8([
332
+ __decorate$3([
333
333
  Property([])
334
334
  ], RibbonComboBoxSettings.prototype, "dataSource", void 0);
335
- __decorate$8([
335
+ __decorate$3([
336
336
  Complex({ text: null, value: null, iconCss: null, groupBy: null }, FieldSettings)
337
337
  ], RibbonComboBoxSettings.prototype, "fields", void 0);
338
- __decorate$8([
338
+ __decorate$3([
339
339
  Property('Contains')
340
340
  ], RibbonComboBoxSettings.prototype, "filterType", void 0);
341
- __decorate$8([
341
+ __decorate$3([
342
342
  Property(null)
343
343
  ], RibbonComboBoxSettings.prototype, "footerTemplate", void 0);
344
- __decorate$8([
344
+ __decorate$3([
345
345
  Property(null)
346
346
  ], RibbonComboBoxSettings.prototype, "groupTemplate", void 0);
347
- __decorate$8([
347
+ __decorate$3([
348
348
  Property(null)
349
349
  ], RibbonComboBoxSettings.prototype, "headerTemplate", void 0);
350
- __decorate$8([
350
+ __decorate$3([
351
351
  Property(null)
352
352
  ], RibbonComboBoxSettings.prototype, "index", void 0);
353
- __decorate$8([
353
+ __decorate$3([
354
354
  Property(null)
355
355
  ], RibbonComboBoxSettings.prototype, "itemTemplate", void 0);
356
- __decorate$8([
356
+ __decorate$3([
357
357
  Property('No records found')
358
358
  ], RibbonComboBoxSettings.prototype, "noRecordsTemplate", void 0);
359
- __decorate$8([
359
+ __decorate$3([
360
360
  Property(null)
361
361
  ], RibbonComboBoxSettings.prototype, "placeholder", void 0);
362
- __decorate$8([
362
+ __decorate$3([
363
363
  Property('300px')
364
364
  ], RibbonComboBoxSettings.prototype, "popupHeight", void 0);
365
- __decorate$8([
365
+ __decorate$3([
366
366
  Property('100%')
367
367
  ], RibbonComboBoxSettings.prototype, "popupWidth", void 0);
368
- __decorate$8([
368
+ __decorate$3([
369
369
  Property(true)
370
370
  ], RibbonComboBoxSettings.prototype, "showClearButton", void 0);
371
- __decorate$8([
371
+ __decorate$3([
372
372
  Property('None')
373
373
  ], RibbonComboBoxSettings.prototype, "sortOrder", void 0);
374
- __decorate$8([
374
+ __decorate$3([
375
375
  Property(null)
376
376
  ], RibbonComboBoxSettings.prototype, "text", void 0);
377
- __decorate$8([
377
+ __decorate$3([
378
378
  Property(null)
379
379
  ], RibbonComboBoxSettings.prototype, "value", void 0);
380
- __decorate$8([
380
+ __decorate$3([
381
381
  Property('150px')
382
382
  ], RibbonComboBoxSettings.prototype, "width", void 0);
383
- __decorate$8([
383
+ __decorate$3([
384
384
  Property({})
385
385
  ], RibbonComboBoxSettings.prototype, "htmlAttributes", void 0);
386
- __decorate$8([
386
+ __decorate$3([
387
387
  Event()
388
388
  ], RibbonComboBoxSettings.prototype, "beforeOpen", void 0);
389
- __decorate$8([
389
+ __decorate$3([
390
390
  Event()
391
391
  ], RibbonComboBoxSettings.prototype, "change", void 0);
392
- __decorate$8([
392
+ __decorate$3([
393
393
  Event()
394
394
  ], RibbonComboBoxSettings.prototype, "close", void 0);
395
- __decorate$8([
395
+ __decorate$3([
396
396
  Event()
397
397
  ], RibbonComboBoxSettings.prototype, "created", void 0);
398
- __decorate$8([
398
+ __decorate$3([
399
399
  Event()
400
400
  ], RibbonComboBoxSettings.prototype, "filtering", void 0);
401
- __decorate$8([
401
+ __decorate$3([
402
402
  Event()
403
403
  ], RibbonComboBoxSettings.prototype, "open", void 0);
404
- __decorate$8([
404
+ __decorate$3([
405
405
  Event()
406
406
  ], RibbonComboBoxSettings.prototype, "select", void 0);
407
407
 
408
- var __decorate$9 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
408
+ var __decorate$4 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
409
409
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
410
410
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
411
411
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -425,53 +425,53 @@ class RibbonDropDownSettings extends ChildProperty {
425
425
  super.setProperties(prop, muteOnChange);
426
426
  }
427
427
  }
428
- __decorate$9([
428
+ __decorate$4([
429
429
  Property('')
430
430
  ], RibbonDropDownSettings.prototype, "closeActionEvents", void 0);
431
- __decorate$9([
431
+ __decorate$4([
432
432
  Property('')
433
433
  ], RibbonDropDownSettings.prototype, "content", void 0);
434
- __decorate$9([
434
+ __decorate$4([
435
435
  Property('')
436
436
  ], RibbonDropDownSettings.prototype, "cssClass", void 0);
437
- __decorate$9([
437
+ __decorate$4([
438
438
  Property('')
439
439
  ], RibbonDropDownSettings.prototype, "iconCss", void 0);
440
- __decorate$9([
440
+ __decorate$4([
441
441
  Collection([], Item)
442
442
  ], RibbonDropDownSettings.prototype, "items", void 0);
443
- __decorate$9([
443
+ __decorate$4([
444
444
  Property('')
445
445
  ], RibbonDropDownSettings.prototype, "target", void 0);
446
- __decorate$9([
446
+ __decorate$4([
447
447
  Property(false)
448
448
  ], RibbonDropDownSettings.prototype, "createPopupOnClick", void 0);
449
- __decorate$9([
449
+ __decorate$4([
450
450
  Property({})
451
451
  ], RibbonDropDownSettings.prototype, "htmlAttributes", void 0);
452
- __decorate$9([
452
+ __decorate$4([
453
453
  Event()
454
454
  ], RibbonDropDownSettings.prototype, "beforeClose", void 0);
455
- __decorate$9([
455
+ __decorate$4([
456
456
  Event()
457
457
  ], RibbonDropDownSettings.prototype, "beforeItemRender", void 0);
458
- __decorate$9([
458
+ __decorate$4([
459
459
  Event()
460
460
  ], RibbonDropDownSettings.prototype, "beforeOpen", void 0);
461
- __decorate$9([
461
+ __decorate$4([
462
462
  Event()
463
463
  ], RibbonDropDownSettings.prototype, "close", void 0);
464
- __decorate$9([
464
+ __decorate$4([
465
465
  Event()
466
466
  ], RibbonDropDownSettings.prototype, "created", void 0);
467
- __decorate$9([
467
+ __decorate$4([
468
468
  Event()
469
469
  ], RibbonDropDownSettings.prototype, "open", void 0);
470
- __decorate$9([
470
+ __decorate$4([
471
471
  Event()
472
472
  ], RibbonDropDownSettings.prototype, "select", void 0);
473
473
 
474
- var __decorate$10 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
474
+ var __decorate$5 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
475
475
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
476
476
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
477
477
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -491,53 +491,53 @@ class RibbonSplitButtonSettings extends ChildProperty {
491
491
  super.setProperties(prop, muteOnChange);
492
492
  }
493
493
  }
494
- __decorate$10([
494
+ __decorate$5([
495
495
  Property('')
496
496
  ], RibbonSplitButtonSettings.prototype, "closeActionEvents", void 0);
497
- __decorate$10([
497
+ __decorate$5([
498
498
  Property('')
499
499
  ], RibbonSplitButtonSettings.prototype, "content", void 0);
500
- __decorate$10([
500
+ __decorate$5([
501
501
  Property('')
502
502
  ], RibbonSplitButtonSettings.prototype, "cssClass", void 0);
503
- __decorate$10([
503
+ __decorate$5([
504
504
  Property('')
505
505
  ], RibbonSplitButtonSettings.prototype, "iconCss", void 0);
506
- __decorate$10([
506
+ __decorate$5([
507
507
  Collection([], Item)
508
508
  ], RibbonSplitButtonSettings.prototype, "items", void 0);
509
- __decorate$10([
509
+ __decorate$5([
510
510
  Property('')
511
511
  ], RibbonSplitButtonSettings.prototype, "target", void 0);
512
- __decorate$10([
512
+ __decorate$5([
513
513
  Property({})
514
514
  ], RibbonSplitButtonSettings.prototype, "htmlAttributes", void 0);
515
- __decorate$10([
515
+ __decorate$5([
516
516
  Event()
517
517
  ], RibbonSplitButtonSettings.prototype, "beforeClose", void 0);
518
- __decorate$10([
518
+ __decorate$5([
519
519
  Event()
520
520
  ], RibbonSplitButtonSettings.prototype, "beforeItemRender", void 0);
521
- __decorate$10([
521
+ __decorate$5([
522
522
  Event()
523
523
  ], RibbonSplitButtonSettings.prototype, "beforeOpen", void 0);
524
- __decorate$10([
524
+ __decorate$5([
525
525
  Event()
526
526
  ], RibbonSplitButtonSettings.prototype, "close", void 0);
527
- __decorate$10([
527
+ __decorate$5([
528
528
  Event()
529
529
  ], RibbonSplitButtonSettings.prototype, "click", void 0);
530
- __decorate$10([
530
+ __decorate$5([
531
531
  Event()
532
532
  ], RibbonSplitButtonSettings.prototype, "created", void 0);
533
- __decorate$10([
533
+ __decorate$5([
534
534
  Event()
535
535
  ], RibbonSplitButtonSettings.prototype, "open", void 0);
536
- __decorate$10([
536
+ __decorate$5([
537
537
  Event()
538
538
  ], RibbonSplitButtonSettings.prototype, "select", void 0);
539
539
 
540
- var __decorate$11 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
540
+ var __decorate$6 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
541
541
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
542
542
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
543
543
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -548,23 +548,23 @@ var __decorate$11 = (undefined && undefined.__decorate) || function (decorators,
548
548
  */
549
549
  class RibbonTooltip extends ChildProperty {
550
550
  }
551
- __decorate$11([
551
+ __decorate$6([
552
552
  Property('')
553
553
  ], RibbonTooltip.prototype, "cssClass", void 0);
554
- __decorate$11([
554
+ __decorate$6([
555
555
  Property('')
556
556
  ], RibbonTooltip.prototype, "id", void 0);
557
- __decorate$11([
557
+ __decorate$6([
558
558
  Property('')
559
559
  ], RibbonTooltip.prototype, "title", void 0);
560
- __decorate$11([
560
+ __decorate$6([
561
561
  Property('')
562
562
  ], RibbonTooltip.prototype, "content", void 0);
563
- __decorate$11([
563
+ __decorate$6([
564
564
  Property('')
565
565
  ], RibbonTooltip.prototype, "iconCss", void 0);
566
566
 
567
- var __decorate$13 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
567
+ var __decorate$7 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
568
568
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
569
569
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
570
570
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -584,32 +584,32 @@ class RibbonGroupButtonItem extends ChildProperty {
584
584
  super.setProperties(prop, muteOnChange);
585
585
  }
586
586
  }
587
- __decorate$13([
587
+ __decorate$7([
588
588
  Property('')
589
589
  ], RibbonGroupButtonItem.prototype, "content", void 0);
590
- __decorate$13([
590
+ __decorate$7([
591
591
  Property('')
592
592
  ], RibbonGroupButtonItem.prototype, "iconCss", void 0);
593
- __decorate$13([
593
+ __decorate$7([
594
594
  Property('')
595
595
  ], RibbonGroupButtonItem.prototype, "keyTip", void 0);
596
- __decorate$13([
596
+ __decorate$7([
597
597
  Complex({}, RibbonTooltip)
598
598
  ], RibbonGroupButtonItem.prototype, "ribbonTooltipSettings", void 0);
599
- __decorate$13([
599
+ __decorate$7([
600
600
  Property(false)
601
601
  ], RibbonGroupButtonItem.prototype, "selected", void 0);
602
- __decorate$13([
602
+ __decorate$7([
603
603
  Property({})
604
604
  ], RibbonGroupButtonItem.prototype, "htmlAttributes", void 0);
605
- __decorate$13([
605
+ __decorate$7([
606
606
  Event()
607
607
  ], RibbonGroupButtonItem.prototype, "beforeClick", void 0);
608
- __decorate$13([
608
+ __decorate$7([
609
609
  Event()
610
610
  ], RibbonGroupButtonItem.prototype, "click", void 0);
611
611
 
612
- var __decorate$12 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
612
+ var __decorate$8 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
613
613
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
614
614
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
615
615
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -620,17 +620,17 @@ var __decorate$12 = (undefined && undefined.__decorate) || function (decorators,
620
620
  */
621
621
  class RibbonGroupButtonSettings extends ChildProperty {
622
622
  }
623
- __decorate$12([
623
+ __decorate$8([
624
624
  Property('')
625
625
  ], RibbonGroupButtonSettings.prototype, "header", void 0);
626
- __decorate$12([
626
+ __decorate$8([
627
627
  Property('Single')
628
628
  ], RibbonGroupButtonSettings.prototype, "selection", void 0);
629
- __decorate$12([
629
+ __decorate$8([
630
630
  Collection([], RibbonGroupButtonItem)
631
631
  ], RibbonGroupButtonSettings.prototype, "items", void 0);
632
632
 
633
- var __decorate$16 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
633
+ var __decorate$9 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
634
634
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
635
635
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
636
636
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -641,23 +641,23 @@ var __decorate$16 = (undefined && undefined.__decorate) || function (decorators,
641
641
  */
642
642
  class RibbonGalleryItem extends ChildProperty {
643
643
  }
644
- __decorate$16([
644
+ __decorate$9([
645
645
  Property('')
646
646
  ], RibbonGalleryItem.prototype, "content", void 0);
647
- __decorate$16([
647
+ __decorate$9([
648
648
  Property('')
649
649
  ], RibbonGalleryItem.prototype, "iconCss", void 0);
650
- __decorate$16([
650
+ __decorate$9([
651
651
  Property({})
652
652
  ], RibbonGalleryItem.prototype, "htmlAttributes", void 0);
653
- __decorate$16([
653
+ __decorate$9([
654
654
  Property('')
655
655
  ], RibbonGalleryItem.prototype, "cssClass", void 0);
656
- __decorate$16([
656
+ __decorate$9([
657
657
  Property(false)
658
658
  ], RibbonGalleryItem.prototype, "disabled", void 0);
659
659
 
660
- var __decorate$15 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
660
+ var __decorate$a = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
661
661
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
662
662
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
663
663
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -668,23 +668,23 @@ var __decorate$15 = (undefined && undefined.__decorate) || function (decorators,
668
668
  */
669
669
  class RibbonGalleryGroup extends ChildProperty {
670
670
  }
671
- __decorate$15([
671
+ __decorate$a([
672
672
  Collection([], RibbonGalleryItem)
673
673
  ], RibbonGalleryGroup.prototype, "items", void 0);
674
- __decorate$15([
674
+ __decorate$a([
675
675
  Property('')
676
676
  ], RibbonGalleryGroup.prototype, "header", void 0);
677
- __decorate$15([
677
+ __decorate$a([
678
678
  Property('auto')
679
679
  ], RibbonGalleryGroup.prototype, "itemWidth", void 0);
680
- __decorate$15([
680
+ __decorate$a([
681
681
  Property('auto')
682
682
  ], RibbonGalleryGroup.prototype, "itemHeight", void 0);
683
- __decorate$15([
683
+ __decorate$a([
684
684
  Property('')
685
685
  ], RibbonGalleryGroup.prototype, "cssClass", void 0);
686
686
 
687
- var __decorate$14 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
687
+ var __decorate$b = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
688
688
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
689
689
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
690
690
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -695,47 +695,47 @@ var __decorate$14 = (undefined && undefined.__decorate) || function (decorators,
695
695
  */
696
696
  class RibbonGallerySettings extends ChildProperty {
697
697
  }
698
- __decorate$14([
698
+ __decorate$b([
699
699
  Collection([], RibbonGalleryGroup)
700
700
  ], RibbonGallerySettings.prototype, "groups", void 0);
701
- __decorate$14([
701
+ __decorate$b([
702
702
  Property(3)
703
703
  ], RibbonGallerySettings.prototype, "itemCount", void 0);
704
- __decorate$14([
704
+ __decorate$b([
705
705
  Property(null)
706
706
  ], RibbonGallerySettings.prototype, "selectedItemIndex", void 0);
707
- __decorate$14([
707
+ __decorate$b([
708
708
  Property('auto')
709
709
  ], RibbonGallerySettings.prototype, "popupHeight", void 0);
710
- __decorate$14([
710
+ __decorate$b([
711
711
  Property('auto')
712
712
  ], RibbonGallerySettings.prototype, "popupWidth", void 0);
713
- __decorate$14([
713
+ __decorate$b([
714
714
  Property('')
715
715
  ], RibbonGallerySettings.prototype, "template", void 0);
716
- __decorate$14([
716
+ __decorate$b([
717
717
  Property('')
718
718
  ], RibbonGallerySettings.prototype, "popupTemplate", void 0);
719
- __decorate$14([
719
+ __decorate$b([
720
720
  Event()
721
721
  ], RibbonGallerySettings.prototype, "popupOpen", void 0);
722
- __decorate$14([
722
+ __decorate$b([
723
723
  Event()
724
724
  ], RibbonGallerySettings.prototype, "popupClose", void 0);
725
- __decorate$14([
725
+ __decorate$b([
726
726
  Event()
727
727
  ], RibbonGallerySettings.prototype, "itemHover", void 0);
728
- __decorate$14([
728
+ __decorate$b([
729
729
  Event()
730
730
  ], RibbonGallerySettings.prototype, "beforeItemRender", void 0);
731
- __decorate$14([
731
+ __decorate$b([
732
732
  Event()
733
733
  ], RibbonGallerySettings.prototype, "beforeSelect", void 0);
734
- __decorate$14([
734
+ __decorate$b([
735
735
  Event()
736
736
  ], RibbonGallerySettings.prototype, "select", void 0);
737
737
 
738
- var __decorate$4 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
738
+ var __decorate$c = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
739
739
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
740
740
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
741
741
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -755,62 +755,62 @@ class RibbonItem extends ChildProperty {
755
755
  super.setProperties(prop, muteOnChange);
756
756
  }
757
757
  }
758
- __decorate$4([
758
+ __decorate$c([
759
759
  Property('')
760
760
  ], RibbonItem.prototype, "keyTip", void 0);
761
- __decorate$4([
761
+ __decorate$c([
762
762
  Property(RibbonItemSize.Medium)
763
763
  ], RibbonItem.prototype, "activeSize", void 0);
764
- __decorate$4([
764
+ __decorate$c([
765
765
  Property(RibbonItemSize.Small | RibbonItemSize.Medium | RibbonItemSize.Large)
766
766
  ], RibbonItem.prototype, "allowedSizes", void 0);
767
- __decorate$4([
767
+ __decorate$c([
768
768
  Property('')
769
769
  ], RibbonItem.prototype, "id", void 0);
770
- __decorate$4([
770
+ __decorate$c([
771
771
  Property('')
772
772
  ], RibbonItem.prototype, "cssClass", void 0);
773
- __decorate$4([
773
+ __decorate$c([
774
774
  Property(false)
775
775
  ], RibbonItem.prototype, "disabled", void 0);
776
- __decorate$4([
776
+ __decorate$c([
777
777
  Property('')
778
778
  ], RibbonItem.prototype, "itemTemplate", void 0);
779
- __decorate$4([
779
+ __decorate$c([
780
780
  Property('Button')
781
781
  ], RibbonItem.prototype, "type", void 0);
782
- __decorate$4([
782
+ __decorate$c([
783
783
  Property(DisplayMode.Auto)
784
784
  ], RibbonItem.prototype, "displayOptions", void 0);
785
- __decorate$4([
785
+ __decorate$c([
786
786
  Complex({}, RibbonTooltip)
787
787
  ], RibbonItem.prototype, "ribbonTooltipSettings", void 0);
788
- __decorate$4([
788
+ __decorate$c([
789
789
  Complex({}, RibbonButtonSettings)
790
790
  ], RibbonItem.prototype, "buttonSettings", void 0);
791
- __decorate$4([
791
+ __decorate$c([
792
792
  Complex({}, RibbonDropDownSettings)
793
793
  ], RibbonItem.prototype, "dropDownSettings", void 0);
794
- __decorate$4([
794
+ __decorate$c([
795
795
  Complex({}, RibbonCheckBoxSettings)
796
796
  ], RibbonItem.prototype, "checkBoxSettings", void 0);
797
- __decorate$4([
797
+ __decorate$c([
798
798
  Complex({}, RibbonColorPickerSettings)
799
799
  ], RibbonItem.prototype, "colorPickerSettings", void 0);
800
- __decorate$4([
800
+ __decorate$c([
801
801
  Complex({}, RibbonComboBoxSettings)
802
802
  ], RibbonItem.prototype, "comboBoxSettings", void 0);
803
- __decorate$4([
803
+ __decorate$c([
804
804
  Complex({}, RibbonSplitButtonSettings)
805
805
  ], RibbonItem.prototype, "splitButtonSettings", void 0);
806
- __decorate$4([
806
+ __decorate$c([
807
807
  Complex({}, RibbonGroupButtonSettings)
808
808
  ], RibbonItem.prototype, "groupButtonSettings", void 0);
809
- __decorate$4([
809
+ __decorate$c([
810
810
  Complex({}, RibbonGallerySettings)
811
811
  ], RibbonItem.prototype, "gallerySettings", void 0);
812
812
 
813
- var __decorate$3 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
813
+ var __decorate$d = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
814
814
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
815
815
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
816
816
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -830,17 +830,17 @@ class RibbonCollection extends ChildProperty {
830
830
  super.setProperties(prop, muteOnChange);
831
831
  }
832
832
  }
833
- __decorate$3([
833
+ __decorate$d([
834
834
  Property('')
835
835
  ], RibbonCollection.prototype, "id", void 0);
836
- __decorate$3([
836
+ __decorate$d([
837
837
  Property('')
838
838
  ], RibbonCollection.prototype, "cssClass", void 0);
839
- __decorate$3([
839
+ __decorate$d([
840
840
  Collection([], RibbonItem)
841
841
  ], RibbonCollection.prototype, "items", void 0);
842
842
 
843
- var __decorate$2 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
843
+ var __decorate$e = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
844
844
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
845
845
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
846
846
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -860,50 +860,50 @@ class RibbonGroup extends ChildProperty {
860
860
  super.setProperties(prop, muteOnChange);
861
861
  }
862
862
  }
863
- __decorate$2([
863
+ __decorate$e([
864
864
  Property('')
865
865
  ], RibbonGroup.prototype, "keyTip", void 0);
866
- __decorate$2([
866
+ __decorate$e([
867
867
  Property('')
868
868
  ], RibbonGroup.prototype, "launcherIconKeyTip", void 0);
869
- __decorate$2([
869
+ __decorate$e([
870
870
  Collection([], RibbonCollection)
871
871
  ], RibbonGroup.prototype, "collections", void 0);
872
- __decorate$2([
872
+ __decorate$e([
873
873
  Property('')
874
874
  ], RibbonGroup.prototype, "cssClass", void 0);
875
- __decorate$2([
875
+ __decorate$e([
876
876
  Property('')
877
877
  ], RibbonGroup.prototype, "id", void 0);
878
- __decorate$2([
878
+ __decorate$e([
879
879
  Property(false)
880
880
  ], RibbonGroup.prototype, "isCollapsed", void 0);
881
- __decorate$2([
881
+ __decorate$e([
882
882
  Property(true)
883
883
  ], RibbonGroup.prototype, "isCollapsible", void 0);
884
- __decorate$2([
884
+ __decorate$e([
885
885
  Property(false)
886
886
  ], RibbonGroup.prototype, "enableGroupOverflow", void 0);
887
- __decorate$2([
887
+ __decorate$e([
888
888
  Property('')
889
889
  ], RibbonGroup.prototype, "groupIconCss", void 0);
890
- __decorate$2([
890
+ __decorate$e([
891
891
  Property('')
892
892
  ], RibbonGroup.prototype, "header", void 0);
893
- __decorate$2([
893
+ __decorate$e([
894
894
  Property('Column')
895
895
  ], RibbonGroup.prototype, "orientation", void 0);
896
- __decorate$2([
896
+ __decorate$e([
897
897
  Property('')
898
898
  ], RibbonGroup.prototype, "overflowHeader", void 0);
899
- __decorate$2([
899
+ __decorate$e([
900
900
  Property(0)
901
901
  ], RibbonGroup.prototype, "priority", void 0);
902
- __decorate$2([
902
+ __decorate$e([
903
903
  Property(false)
904
904
  ], RibbonGroup.prototype, "showLauncherIcon", void 0);
905
905
 
906
- var __decorate$1 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
906
+ var __decorate$f = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
907
907
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
908
908
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
909
909
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -923,23 +923,23 @@ class RibbonTab extends ChildProperty {
923
923
  super.setProperties(prop, muteOnChange);
924
924
  }
925
925
  }
926
- __decorate$1([
926
+ __decorate$f([
927
927
  Property('')
928
928
  ], RibbonTab.prototype, "keyTip", void 0);
929
- __decorate$1([
929
+ __decorate$f([
930
930
  Property('')
931
931
  ], RibbonTab.prototype, "id", void 0);
932
- __decorate$1([
932
+ __decorate$f([
933
933
  Property('')
934
934
  ], RibbonTab.prototype, "cssClass", void 0);
935
- __decorate$1([
935
+ __decorate$f([
936
936
  Collection([], RibbonGroup)
937
937
  ], RibbonTab.prototype, "groups", void 0);
938
- __decorate$1([
938
+ __decorate$f([
939
939
  Property('')
940
940
  ], RibbonTab.prototype, "header", void 0);
941
941
 
942
- var __decorate$17 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
942
+ var __decorate$g = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
943
943
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
944
944
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
945
945
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -959,53 +959,53 @@ class FileMenuSettings extends ChildProperty {
959
959
  super.setProperties(prop, muteOnChange);
960
960
  }
961
961
  }
962
- __decorate$17([
962
+ __decorate$g([
963
963
  Property('File')
964
964
  ], FileMenuSettings.prototype, "text", void 0);
965
- __decorate$17([
965
+ __decorate$g([
966
966
  Property(false)
967
967
  ], FileMenuSettings.prototype, "visible", void 0);
968
- __decorate$17([
968
+ __decorate$g([
969
969
  Collection([], MenuItem)
970
970
  ], FileMenuSettings.prototype, "menuItems", void 0);
971
- __decorate$17([
971
+ __decorate$g([
972
972
  Property(false)
973
973
  ], FileMenuSettings.prototype, "showItemOnClick", void 0);
974
- __decorate$17([
974
+ __decorate$g([
975
975
  Complex({}, MenuAnimationSettings)
976
976
  ], FileMenuSettings.prototype, "animationSettings", void 0);
977
- __decorate$17([
977
+ __decorate$g([
978
978
  Property('')
979
979
  ], FileMenuSettings.prototype, "itemTemplate", void 0);
980
- __decorate$17([
980
+ __decorate$g([
981
981
  Property('')
982
982
  ], FileMenuSettings.prototype, "popupTemplate", void 0);
983
- __decorate$17([
983
+ __decorate$g([
984
984
  Complex({}, RibbonTooltip)
985
985
  ], FileMenuSettings.prototype, "ribbonTooltipSettings", void 0);
986
- __decorate$17([
986
+ __decorate$g([
987
987
  Event()
988
988
  ], FileMenuSettings.prototype, "beforeClose", void 0);
989
- __decorate$17([
989
+ __decorate$g([
990
990
  Event()
991
991
  ], FileMenuSettings.prototype, "beforeOpen", void 0);
992
- __decorate$17([
992
+ __decorate$g([
993
993
  Event()
994
994
  ], FileMenuSettings.prototype, "beforeItemRender", void 0);
995
- __decorate$17([
995
+ __decorate$g([
996
996
  Event()
997
997
  ], FileMenuSettings.prototype, "close", void 0);
998
- __decorate$17([
998
+ __decorate$g([
999
999
  Event()
1000
1000
  ], FileMenuSettings.prototype, "open", void 0);
1001
- __decorate$17([
1001
+ __decorate$g([
1002
1002
  Event()
1003
1003
  ], FileMenuSettings.prototype, "select", void 0);
1004
- __decorate$17([
1004
+ __decorate$g([
1005
1005
  Property('')
1006
1006
  ], FileMenuSettings.prototype, "keyTip", void 0);
1007
1007
 
1008
- var __decorate$19 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1008
+ var __decorate$h = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1009
1009
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1010
1010
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1011
1011
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -1016,17 +1016,17 @@ var __decorate$19 = (undefined && undefined.__decorate) || function (decorators,
1016
1016
  */
1017
1017
  class BackstageBackButton extends ChildProperty {
1018
1018
  }
1019
- __decorate$19([
1019
+ __decorate$h([
1020
1020
  Property('')
1021
1021
  ], BackstageBackButton.prototype, "text", void 0);
1022
- __decorate$19([
1022
+ __decorate$h([
1023
1023
  Property('')
1024
1024
  ], BackstageBackButton.prototype, "iconCss", void 0);
1025
- __decorate$19([
1025
+ __decorate$h([
1026
1026
  Property(true)
1027
1027
  ], BackstageBackButton.prototype, "visible", void 0);
1028
1028
 
1029
- var __decorate$20 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1029
+ var __decorate$i = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1030
1030
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1031
1031
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1032
1032
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -1037,32 +1037,32 @@ var __decorate$20 = (undefined && undefined.__decorate) || function (decorators,
1037
1037
  */
1038
1038
  class BackstageItem extends ChildProperty {
1039
1039
  }
1040
- __decorate$20([
1040
+ __decorate$i([
1041
1041
  Property('')
1042
1042
  ], BackstageItem.prototype, "text", void 0);
1043
- __decorate$20([
1043
+ __decorate$i([
1044
1044
  Property('')
1045
1045
  ], BackstageItem.prototype, "id", void 0);
1046
- __decorate$20([
1046
+ __decorate$i([
1047
1047
  Property('')
1048
1048
  ], BackstageItem.prototype, "keyTip", void 0);
1049
- __decorate$20([
1049
+ __decorate$i([
1050
1050
  Property('')
1051
1051
  ], BackstageItem.prototype, "content", void 0);
1052
- __decorate$20([
1052
+ __decorate$i([
1053
1053
  Property('')
1054
1054
  ], BackstageItem.prototype, "iconCss", void 0);
1055
- __decorate$20([
1055
+ __decorate$i([
1056
1056
  Property(false)
1057
1057
  ], BackstageItem.prototype, "separator", void 0);
1058
- __decorate$20([
1058
+ __decorate$i([
1059
1059
  Property(false)
1060
1060
  ], BackstageItem.prototype, "isFooter", void 0);
1061
- __decorate$20([
1061
+ __decorate$i([
1062
1062
  Event()
1063
1063
  ], BackstageItem.prototype, "backStageItemClick", void 0);
1064
1064
 
1065
- var __decorate$18 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1065
+ var __decorate$j = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1066
1066
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1067
1067
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1068
1068
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -1082,38 +1082,38 @@ class BackStageMenu extends ChildProperty {
1082
1082
  super.setProperties(prop, muteOnChange);
1083
1083
  }
1084
1084
  }
1085
- __decorate$18([
1085
+ __decorate$j([
1086
1086
  Property('File')
1087
1087
  ], BackStageMenu.prototype, "text", void 0);
1088
- __decorate$18([
1088
+ __decorate$j([
1089
1089
  Property('')
1090
1090
  ], BackStageMenu.prototype, "keyTip", void 0);
1091
- __decorate$18([
1091
+ __decorate$j([
1092
1092
  Property(false)
1093
1093
  ], BackStageMenu.prototype, "visible", void 0);
1094
- __decorate$18([
1094
+ __decorate$j([
1095
1095
  Property('auto')
1096
1096
  ], BackStageMenu.prototype, "height", void 0);
1097
- __decorate$18([
1097
+ __decorate$j([
1098
1098
  Property('auto')
1099
1099
  ], BackStageMenu.prototype, "width", void 0);
1100
- __decorate$18([
1100
+ __decorate$j([
1101
1101
  Property(null)
1102
1102
  ], BackStageMenu.prototype, "target", void 0);
1103
- __decorate$18([
1103
+ __decorate$j([
1104
1104
  Complex({}, BackstageBackButton)
1105
1105
  ], BackStageMenu.prototype, "backButton", void 0);
1106
- __decorate$18([
1106
+ __decorate$j([
1107
1107
  Collection([], BackstageItem)
1108
1108
  ], BackStageMenu.prototype, "items", void 0);
1109
- __decorate$18([
1109
+ __decorate$j([
1110
1110
  Property('')
1111
1111
  ], BackStageMenu.prototype, "template", void 0);
1112
- __decorate$18([
1112
+ __decorate$j([
1113
1113
  Complex({}, RibbonTooltip)
1114
1114
  ], BackStageMenu.prototype, "ribbonTooltipSettings", void 0);
1115
1115
 
1116
- var __decorate$21 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1116
+ var __decorate$k = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
1117
1117
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1118
1118
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
1119
1119
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -1133,18 +1133,16 @@ class RibbonContextualTabSettings extends ChildProperty {
1133
1133
  super.setProperties(prop, muteOnChange);
1134
1134
  }
1135
1135
  }
1136
- __decorate$21([
1136
+ __decorate$k([
1137
1137
  Property(false)
1138
1138
  ], RibbonContextualTabSettings.prototype, "visible", void 0);
1139
- __decorate$21([
1139
+ __decorate$k([
1140
1140
  Property(false)
1141
1141
  ], RibbonContextualTabSettings.prototype, "isSelected", void 0);
1142
- __decorate$21([
1142
+ __decorate$k([
1143
1143
  Collection([], RibbonTab)
1144
1144
  ], RibbonContextualTabSettings.prototype, "tabs", void 0);
1145
1145
 
1146
- // export * from './file-menu';
1147
-
1148
1146
  /**
1149
1147
  * Specifies the File Manager internal ID's
1150
1148
  */
@@ -1388,14 +1386,23 @@ class RibbonButton {
1388
1386
  created: btnSettings.created
1389
1387
  }, buttonEle);
1390
1388
  if (btnSettings.htmlAttributes) {
1391
- setCustomAttributes(buttonEle, btnSettings.htmlAttributes);
1389
+ const htmlAttr = Object.assign({}, btnSettings.htmlAttributes);
1390
+ if (htmlAttr.id) {
1391
+ delete htmlAttr.id;
1392
+ }
1393
+ setCustomAttributes(buttonEle, htmlAttr);
1392
1394
  }
1393
1395
  buttonEle.onclick = (e) => {
1394
1396
  if (btnSettings.clicked) {
1395
1397
  btnSettings.clicked.call(this, e);
1396
1398
  }
1397
1399
  };
1398
- buttonEle.setAttribute('aria-label', btnSettings.content);
1400
+ if (btnSettings.content) {
1401
+ buttonEle.setAttribute('aria-label', btnSettings.content);
1402
+ }
1403
+ else {
1404
+ buttonEle.setAttribute('aria-label', 'button');
1405
+ }
1399
1406
  }
1400
1407
  /**
1401
1408
  * Adds the additional event handlers as the item moved into overflow popup.
@@ -1527,6 +1534,13 @@ class RibbonCheckBox {
1527
1534
  });
1528
1535
  itemEle.appendChild(inputEle);
1529
1536
  const checkBoxSettings = item.checkBoxSettings;
1537
+ let htmlAttr = {};
1538
+ if (checkBoxSettings.htmlAttributes) {
1539
+ htmlAttr = Object.assign({}, checkBoxSettings.htmlAttributes);
1540
+ if (htmlAttr.id) {
1541
+ delete htmlAttr.id;
1542
+ }
1543
+ }
1530
1544
  new CheckBox({
1531
1545
  locale: this.parent.locale,
1532
1546
  enableRtl: this.parent.enableRtl,
@@ -1537,7 +1551,7 @@ class RibbonCheckBox {
1537
1551
  labelPosition: checkBoxSettings.labelPosition,
1538
1552
  disabled: item.disabled,
1539
1553
  created: checkBoxSettings.created,
1540
- htmlAttributes: checkBoxSettings.htmlAttributes,
1554
+ htmlAttributes: htmlAttr,
1541
1555
  change: (e) => {
1542
1556
  if (checkBoxSettings.change) {
1543
1557
  checkBoxSettings.change.call(this, e);
@@ -1693,7 +1707,11 @@ class RibbonColorPicker {
1693
1707
  select: colorPickerSettings.select
1694
1708
  }, inputEle);
1695
1709
  if (colorPickerSettings.htmlAttributes) {
1696
- setCustomAttributes(inputEle, colorPickerSettings.htmlAttributes);
1710
+ const htmlAttr = Object.assign({}, colorPickerSettings.htmlAttributes);
1711
+ if (htmlAttr.id) {
1712
+ delete htmlAttr.id;
1713
+ }
1714
+ setCustomAttributes(inputEle, htmlAttr);
1697
1715
  }
1698
1716
  const wrapper = colorPicker.element.parentElement;
1699
1717
  EventHandler.add(wrapper, 'mouseenter', this.toggleWrapperHover.bind(this, wrapper, true), this);
@@ -1717,7 +1735,7 @@ class RibbonColorPicker {
1717
1735
  * @hidden
1718
1736
  */
1719
1737
  addOverFlowEvents(item, itemEle, overflowButton) {
1720
- let colorPickerSettings = item.colorPickerSettings;
1738
+ const colorPickerSettings = item.colorPickerSettings;
1721
1739
  if (colorPickerSettings.label && this.parent.activeLayout === 'Simplified') {
1722
1740
  const label = this.parent.createElement('div', {
1723
1741
  className: 'e-ribbon-colorpicker-label',
@@ -1755,7 +1773,7 @@ class RibbonColorPicker {
1755
1773
  * @hidden
1756
1774
  */
1757
1775
  removeOverFlowEvents(item, itemEle) {
1758
- let colorPickerSettings = item.colorPickerSettings;
1776
+ const colorPickerSettings = item.colorPickerSettings;
1759
1777
  if (colorPickerSettings.label) {
1760
1778
  const label = itemEle.querySelector('#' + item.id + '_label');
1761
1779
  if (label) {
@@ -1871,6 +1889,13 @@ class RibbonComboBox {
1871
1889
  });
1872
1890
  itemEle.appendChild(inputEle);
1873
1891
  const comboBoxSettings = item.comboBoxSettings;
1892
+ let htmlAttr = {};
1893
+ if (comboBoxSettings.htmlAttributes) {
1894
+ htmlAttr = Object.assign({}, comboBoxSettings.htmlAttributes);
1895
+ if (htmlAttr.id) {
1896
+ delete htmlAttr.id;
1897
+ }
1898
+ }
1874
1899
  new ComboBox({
1875
1900
  locale: this.parent.locale,
1876
1901
  enableRtl: this.parent.enableRtl,
@@ -1902,7 +1927,7 @@ class RibbonComboBox {
1902
1927
  width: comboBoxSettings.width,
1903
1928
  beforeOpen: comboBoxSettings.beforeOpen,
1904
1929
  open: comboBoxSettings.open,
1905
- htmlAttributes: comboBoxSettings.htmlAttributes,
1930
+ htmlAttributes: htmlAttr,
1906
1931
  close: (e) => {
1907
1932
  if (comboBoxSettings.close) {
1908
1933
  comboBoxSettings.close.call(this, e);
@@ -2101,7 +2126,11 @@ class RibbonDropDown {
2101
2126
  select: dropDownSettings.select
2102
2127
  }).appendTo(buttonEle);
2103
2128
  if (dropDownSettings.htmlAttributes) {
2104
- setCustomAttributes(buttonEle, dropDownSettings.htmlAttributes);
2129
+ const htmlAttr = Object.assign({}, dropDownSettings.htmlAttributes);
2130
+ if (htmlAttr.id) {
2131
+ delete htmlAttr.id;
2132
+ }
2133
+ setCustomAttributes(buttonEle, htmlAttr);
2105
2134
  }
2106
2135
  }
2107
2136
  /**
@@ -2543,7 +2572,11 @@ class RibbonSplitButton {
2543
2572
  }
2544
2573
  }, buttonEle);
2545
2574
  if (splitButtonSettings.htmlAttributes) {
2546
- setCustomAttributes(buttonEle, splitButtonSettings.htmlAttributes);
2575
+ const htmlAttr = Object.assign({}, splitButtonSettings.htmlAttributes);
2576
+ if (htmlAttr.id) {
2577
+ delete htmlAttr.id;
2578
+ }
2579
+ setCustomAttributes(buttonEle, htmlAttr);
2547
2580
  }
2548
2581
  const dropdownEle = buttonEle.parentElement.querySelector('.e-dropdown-btn');
2549
2582
  dropdownEle.onkeydown = (e) => {
@@ -3120,6 +3153,10 @@ class RibbonGroupButton {
3120
3153
  }
3121
3154
  if (groupBtnSettings.items[parseInt(i.toString(), 10)].content) {
3122
3155
  groupButtonEle.classList.add(RIBBON_GROUP_BUTTON_CONTENT);
3156
+ groupButtonEle.setAttribute('aria-label', groupBtnSettings.items[parseInt(i.toString(), 10)].content);
3157
+ }
3158
+ else {
3159
+ groupButtonEle.setAttribute('aria-label', 'groupbuttonitem');
3123
3160
  }
3124
3161
  const buttonEle = itemElement.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + i);
3125
3162
  if (groupBtnSettings.selection === RibbonGroupButtonSelection.Single) {
@@ -3238,7 +3275,8 @@ class RibbonGroupButton {
3238
3275
  for (let j = 0; j < grpBtnSettings.items.length; j++) {
3239
3276
  if (document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + j) && document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + j).classList.contains('e-active')) {
3240
3277
  document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + j).classList.remove('e-active');
3241
- grpBtnSettings.items[parseInt(j.toString(), 10)].setProperties({ selected: false }, true);
3278
+ grpBtnSettings.items[parseInt(j.toString(), 10)].
3279
+ setProperties({ selected: false }, true);
3242
3280
  }
3243
3281
  }
3244
3282
  document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + itemIndex).classList.toggle('e-active');
@@ -3259,10 +3297,12 @@ class RibbonGroupButton {
3259
3297
  }
3260
3298
  document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + itemIndex).classList.toggle('e-active');
3261
3299
  if (document.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID + itemIndex).classList.contains('e-active')) {
3262
- grpBtnSettings.items[parseInt(itemIndex.toString(), 10)].setProperties({ selected: true }, true);
3300
+ grpBtnSettings.items[parseInt(itemIndex.toString(), 10)].
3301
+ setProperties({ selected: true }, true);
3263
3302
  }
3264
3303
  else {
3265
- grpBtnSettings.items[parseInt(itemIndex.toString(), 10)].setProperties({ selected: false }, true);
3304
+ grpBtnSettings.items[parseInt(itemIndex.toString(), 10)].
3305
+ setProperties({ selected: false }, true);
3266
3306
  }
3267
3307
  let activeEleCount = 0;
3268
3308
  for (let n = 0; n < grpBtnSettings.items.length; n++) {
@@ -3464,6 +3504,7 @@ class RibbonGroupButton {
3464
3504
  *
3465
3505
  * @param {RibbonItemModel} item - Gets the ribbon item model.
3466
3506
  * @param {HTMLElement} itemEle - Gets the ribbon item element.
3507
+ * @param {DropDownButton} overflowButton - Gets the overflow button.
3467
3508
  * @returns {void}
3468
3509
  * @hidden
3469
3510
  */
@@ -3567,7 +3608,12 @@ class RibbonGallery {
3567
3608
  this.count = 0;
3568
3609
  this.isAdded = false;
3569
3610
  this.galleryItemsIndex = 0;
3611
+ this.registeredTemplate = {};
3570
3612
  this.parent = parent;
3613
+ const ref = 'viewContainerRef';
3614
+ setValue('registeredTemplate', this.registeredTemplate, this);
3615
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
3616
+ setValue(ref, this.parent[`${ref}`], this);
3571
3617
  }
3572
3618
  getModuleName() {
3573
3619
  return 'ribbonGallery';
@@ -3590,21 +3636,27 @@ class RibbonGallery {
3590
3636
  id: item.id + '_popupButton',
3591
3637
  className: 'e-ribbon-gallery-button e-icons e-drop-icon'
3592
3638
  });
3639
+ buttonEle.setAttribute('aria-label', 'gallerydropdownbutton');
3593
3640
  itemEle.appendChild(buttonEle);
3594
3641
  this.createPopup(item, buttonEle);
3595
3642
  buttonEle.onclick = (args) => {
3596
- let popupEle = document.querySelector('#' + item.id + '_galleryPopup');
3643
+ const popupEle = document.querySelector('#' + item.id + '_galleryPopup');
3597
3644
  if (popupEle) {
3598
- let popup = getComponent(popupEle, Popup);
3599
- popupEle.classList.contains('e-popup-close') ? this.showPopup(popup, popupEle, args, gallerySettings, item.id) : this.hidePopup(popup, popupEle, args, gallerySettings, item.id);
3645
+ const popup = getComponent(popupEle, Popup);
3646
+ if (popupEle.classList.contains('e-popup-close')) {
3647
+ this.showPopup(popup, popupEle, args, gallerySettings, item.id);
3648
+ }
3649
+ else {
3650
+ this.hidePopup(popup, popupEle, args, gallerySettings, item.id);
3651
+ }
3600
3652
  }
3601
3653
  };
3602
3654
  document.onclick = (args) => {
3603
- let popupEle = document.querySelectorAll('.e-ribbon-gallery-popup.e-popup-open');
3655
+ const popupEle = document.querySelectorAll('.e-ribbon-gallery-popup.e-popup-open');
3604
3656
  let popupID;
3605
3657
  let itemProp;
3606
3658
  for (let i = 0; i < popupEle.length; i++) {
3607
- let popup = getComponent(popupEle[parseInt(i.toString(), 10)], Popup);
3659
+ const popup = getComponent(popupEle[parseInt(i.toString(), 10)], Popup);
3608
3660
  if (args.target.classList.contains('e-ribbon-gallery-button')) {
3609
3661
  popupID = (popupEle[parseInt(i.toString(), 10)].id).replace(/_galleryPopup/g, '');
3610
3662
  if ((args.target.id).replace(/_popupButton/g, '') !== popupID) {
@@ -3629,7 +3681,7 @@ class RibbonGallery {
3629
3681
  if (itemProp && itemProp.group) {
3630
3682
  itemProp.group.isCollapsible = false;
3631
3683
  }
3632
- let galleryWrapper = this.parent.createElement('div', {
3684
+ const galleryWrapper = this.parent.createElement('div', {
3633
3685
  className: 'e-ribbon-gallery-wrapper',
3634
3686
  id: id + '_galleryWrapper'
3635
3687
  });
@@ -3651,7 +3703,7 @@ class RibbonGallery {
3651
3703
  for (let j = 0; j < gallerySettings.groups[parseInt(i.toString(), 10)].items.length; j++) {
3652
3704
  galleryEle = this.parent.createElement('li', {
3653
3705
  className: 'e-ribbon-gallery-item',
3654
- id: galleryContainerEle.id + '_gallery' + j,
3706
+ id: (isPopup ? 'popup_' : '') + galleryContainerEle.id + '_gallery' + j,
3655
3707
  attrs: { 'tabindex': '0' }
3656
3708
  });
3657
3709
  const itemEventArgs = { name: 'beforeItemRender', item: gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)] };
@@ -3670,11 +3722,11 @@ class RibbonGallery {
3670
3722
  }
3671
3723
  this.count = this.count + 1;
3672
3724
  galleryEle.onclick = (e) => {
3673
- this.setActiveState(e.currentTarget, gallerySettings, id, true, e);
3725
+ this.setActiveState(e.currentTarget, gallerySettings, id, true, e, isPopup);
3674
3726
  };
3675
3727
  galleryEle.onkeydown = (e) => {
3676
3728
  if (e.key === 'Enter' || e.key === ' ') {
3677
- this.setActiveState(e.currentTarget, gallerySettings, id, true, e);
3729
+ this.setActiveState(e.currentTarget, gallerySettings, id, true, e, isPopup);
3678
3730
  }
3679
3731
  };
3680
3732
  galleryEle.onmouseover = (e) => {
@@ -3694,9 +3746,12 @@ class RibbonGallery {
3694
3746
  galleryContainerEle.style.flexFlow = 'wrap';
3695
3747
  }
3696
3748
  }
3697
- if ((!gallerySettings.template && !gallerySettings.popupTemplate) || ((gallerySettings.template && !gallerySettings.popupTemplate) && isPopup) || ((gallerySettings.popupTemplate && !gallerySettings.template) && !isPopup)) {
3749
+ if ((!gallerySettings.template && !gallerySettings.popupTemplate) ||
3750
+ ((gallerySettings.template && !gallerySettings.popupTemplate) && isPopup) ||
3751
+ ((gallerySettings.popupTemplate && !gallerySettings.template) && !isPopup)) {
3698
3752
  if (gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)].htmlAttributes) {
3699
- setCustomAttributes(galleryEle, gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)].htmlAttributes);
3753
+ setCustomAttributes(galleryEle, gallerySettings.groups[parseInt(i.toString(), 10)]
3754
+ .items[parseInt(j.toString(), 10)].htmlAttributes);
3700
3755
  }
3701
3756
  if (gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)].iconCss) {
3702
3757
  const iconEle = this.parent.createElement('span', {
@@ -3735,9 +3790,14 @@ class RibbonGallery {
3735
3790
  if (this.isAdded && !isPopup) {
3736
3791
  break;
3737
3792
  }
3738
- !isPopup ? galleryWrapper.appendChild(galleryContainerEle) : itemEle.appendChild(galleryContainerEle);
3793
+ if (!isPopup) {
3794
+ galleryWrapper.appendChild(galleryContainerEle);
3795
+ }
3796
+ else {
3797
+ itemEle.appendChild(galleryContainerEle);
3798
+ }
3739
3799
  if (isPopup && gallerySettings.groups[parseInt(i.toString(), 10)].header) {
3740
- let headerEle = (this.parent.createElement('div', {
3800
+ const headerEle = (this.parent.createElement('div', {
3741
3801
  className: 'e-ribbon-gallery-header',
3742
3802
  innerHTML: gallerySettings.groups[parseInt(i.toString(), 10)].header
3743
3803
  }));
@@ -3746,6 +3806,14 @@ class RibbonGallery {
3746
3806
  }
3747
3807
  this.count = 0;
3748
3808
  this.isAdded = false;
3809
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
3810
+ if (this.parent.isReact) {
3811
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
3812
+ this.parent.portals = this.parent.portals.concat(this['portals']);
3813
+ this.parent['renderReactTemplates']();
3814
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
3815
+ this['portals'] = undefined;
3816
+ }
3749
3817
  }
3750
3818
  setWrapperWidth(itemCount, galleryWrapper, gallerySettings, itemID) {
3751
3819
  let count = 1;
@@ -3753,74 +3821,77 @@ class RibbonGallery {
3753
3821
  let isWidthApplied = false;
3754
3822
  for (let i = 0; i < gallerySettings.groups.length; i++) {
3755
3823
  for (let j = 0; j < gallerySettings.groups[parseInt(i.toString(), 10)].items.length; j++) {
3756
- if (gallerySettings.groups[parseInt(i.toString(), 10)].itemHeight && gallerySettings.groups[parseInt(i.toString(), 10)].itemHeight !== 'auto') {
3757
- if (itemCount >= count) {
3758
- let galleryItemEle = galleryWrapper.querySelector('#' + itemID + '_galleryContainer' + i + '_gallery' + j);
3759
- if (galleryItemEle) {
3760
- itemsWidth += galleryItemEle.offsetWidth;
3761
- let itemStyles = window.getComputedStyle(galleryItemEle);
3762
- if (itemStyles) {
3763
- let paddingWidth = parseFloat(itemStyles.paddingLeft) + parseFloat(itemStyles.paddingRight);
3764
- if (!(isNullOrUndefined(paddingWidth)))
3765
- itemsWidth += paddingWidth;
3766
- let marginWidth = parseFloat(itemStyles.marginLeft) + parseFloat(itemStyles.marginRight);
3767
- if (!(isNullOrUndefined(marginWidth)))
3768
- itemsWidth += marginWidth;
3824
+ if (itemCount >= count) {
3825
+ const galleryItemEle = galleryWrapper.querySelector('#' + itemID + '_galleryContainer' + i + '_gallery' + j);
3826
+ if (galleryItemEle) {
3827
+ itemsWidth += galleryItemEle.offsetWidth;
3828
+ const itemStyles = window.getComputedStyle(galleryItemEle);
3829
+ if (itemStyles) {
3830
+ const paddingWidth = parseFloat(itemStyles.paddingLeft) + parseFloat(itemStyles.paddingRight);
3831
+ if (!(isNullOrUndefined(paddingWidth))) {
3832
+ itemsWidth += paddingWidth;
3833
+ }
3834
+ const marginWidth = parseFloat(itemStyles.marginLeft) + parseFloat(itemStyles.marginRight);
3835
+ if (!(isNullOrUndefined(marginWidth))) {
3836
+ itemsWidth += marginWidth;
3769
3837
  }
3770
3838
  }
3771
3839
  }
3772
- else {
3773
- isWidthApplied = true;
3774
- break;
3775
- }
3776
- count++;
3777
3840
  }
3841
+ else {
3842
+ isWidthApplied = true;
3843
+ break;
3844
+ }
3845
+ count++;
3778
3846
  }
3779
3847
  if (isWidthApplied) {
3780
3848
  break;
3781
3849
  }
3782
3850
  }
3783
- if (itemsWidth > 0)
3851
+ if (itemsWidth > 0) {
3784
3852
  galleryWrapper.style.width = itemsWidth + 'px';
3853
+ }
3785
3854
  }
3786
3855
  /**
3787
3856
  * Checks the gallery items height.
3788
3857
  *
3789
- * @param {number} selectedTab - Gets the current selected tab.
3790
3858
  * @param {HTMLElement} activeContent - Gets the current active content.
3791
3859
  * @returns {void}
3792
3860
  * @hidden
3793
3861
  */
3794
- checkAvailableHeight(selectedTab, activeContent) {
3795
- let galleryWrapperItems = activeContent.querySelectorAll('.e-ribbon-gallery-wrapper');
3862
+ checkAvailableHeight(activeContent) {
3863
+ const galleryWrapperItems = activeContent.querySelectorAll('.e-ribbon-gallery-wrapper');
3796
3864
  for (let n = 0; n < galleryWrapperItems.length; n++) {
3865
+ let count = 0;
3866
+ let simplifiedItemsCount = 0;
3797
3867
  let isHeight = false;
3798
- let itemsCount = 0;
3799
- let galleryWrapper = galleryWrapperItems[parseInt(n.toString(), 10)];
3868
+ const galleryWrapper = galleryWrapperItems[parseInt(n.toString(), 10)];
3869
+ const itemID = galleryWrapper.id.replace(/_galleryWrapper/g, '');
3800
3870
  let galleryWrapperHeight = galleryWrapper.offsetHeight;
3801
- let itemID = galleryWrapper.id.replace(/_galleryWrapper/g, '');
3802
3871
  const itemProp = getItem(this.parent.tabs, itemID);
3803
3872
  if (itemProp) {
3804
3873
  this.setWrapperWidth(itemProp.item.gallerySettings.itemCount, galleryWrapper, itemProp.item.gallerySettings, itemID);
3805
3874
  for (let i = 0; i < itemProp.item.gallerySettings.groups.length; i++) {
3806
- if (itemProp.item.gallerySettings.groups[parseInt(i.toString(), 10)].itemHeight && itemProp.item.gallerySettings.groups[parseInt(i.toString(), 10)].itemHeight !== 'auto') {
3807
- for (let j = 0; j < itemProp.item.gallerySettings.groups[parseInt(i.toString(), 10)].items.length; j++) {
3808
- let galleryItemEle = galleryWrapper.querySelector('#' + itemID + '_galleryContainer' + i + '_gallery' + j);
3809
- if (galleryItemEle) {
3810
- itemsCount++;
3875
+ for (let j = 0; j < itemProp.item.gallerySettings.groups[parseInt(i.toString(), 10)].items.length; j++) {
3876
+ const galleryItemEle = galleryWrapper.querySelector('#' + itemID + '_galleryContainer' + i + '_gallery' + j);
3877
+ if (galleryItemEle) {
3878
+ if (this.parent.activeLayout === 'Classic') {
3879
+ if (galleryItemEle.classList.contains('e-hidden')) {
3880
+ galleryItemEle.classList.remove('e-hidden');
3881
+ }
3811
3882
  if (!isHeight) {
3812
- if (itemsCount === 1) {
3813
- let itemsValues = 0;
3814
- let itemStyles = window.getComputedStyle(galleryItemEle);
3815
- if (itemStyles) {
3816
- let paddingWidth = parseFloat(itemStyles.paddingTop) + parseFloat(itemStyles.paddingBottom);
3817
- if (!(isNullOrUndefined(paddingWidth)))
3818
- itemsValues += paddingWidth;
3819
- let marginWidth = parseFloat(itemStyles.marginTop) + parseFloat(itemStyles.marginBottom);
3820
- if (!(isNullOrUndefined(marginWidth)))
3821
- itemsValues += marginWidth;
3883
+ let itemsValues = 0;
3884
+ const itemStyles = window.getComputedStyle(galleryItemEle);
3885
+ if (itemStyles) {
3886
+ const marginWidth = parseFloat(itemStyles.marginTop) + parseFloat(itemStyles.marginBottom);
3887
+ if (!(isNullOrUndefined(marginWidth))) {
3888
+ itemsValues += marginWidth;
3822
3889
  }
3823
- if (galleryWrapperHeight > (galleryItemEle.offsetHeight + itemsValues)) {
3890
+ }
3891
+ count++;
3892
+ if (itemProp.item.gallerySettings.itemCount === count) {
3893
+ count = 0;
3894
+ if (galleryWrapperHeight >= (galleryItemEle.offsetHeight + itemsValues)) {
3824
3895
  galleryWrapperHeight -= (galleryItemEle.offsetHeight + itemsValues);
3825
3896
  }
3826
3897
  else {
@@ -3828,32 +3899,50 @@ class RibbonGallery {
3828
3899
  galleryItemEle.remove();
3829
3900
  }
3830
3901
  }
3831
- if (itemsCount === itemProp.item.gallerySettings.itemCount) {
3832
- itemsCount = 0;
3902
+ else if (galleryWrapperHeight < (galleryItemEle.offsetHeight + itemsValues)) {
3903
+ isHeight = true;
3904
+ galleryItemEle.remove();
3833
3905
  }
3834
3906
  }
3835
3907
  else {
3836
3908
  galleryItemEle.remove();
3837
3909
  }
3838
3910
  }
3911
+ else {
3912
+ simplifiedItemsCount++;
3913
+ if (simplifiedItemsCount > itemProp.item.gallerySettings.itemCount) {
3914
+ galleryItemEle.classList.add('e-hidden');
3915
+ }
3916
+ }
3839
3917
  }
3840
3918
  }
3841
3919
  }
3842
3920
  }
3843
3921
  }
3844
3922
  }
3845
- checkCollision(popup, popupEle) {
3923
+ /**
3924
+ * Checks the popup collision.
3925
+ *
3926
+ * @param {Popup} popup - Gets the popup.
3927
+ * @param {HTMLElement} popupEle - Gets the popup element.
3928
+ * @param {number} offsetValue - Gets the offset value of gallery popup button.
3929
+ * @returns {void}
3930
+ * @hidden
3931
+ */
3932
+ checkCollision(popup, popupEle, offsetValue = 0) {
3846
3933
  let paddingWidth = 0;
3847
3934
  let marginWidth = 0;
3848
3935
  if (popupEle) {
3849
- let screenWidth = window.innerWidth;
3850
- let paddingStyles = window.getComputedStyle(popupEle);
3936
+ const windowWidth = window.innerWidth;
3937
+ let screenWidth = offsetValue === 0 ? windowWidth : Math.abs(windowWidth - (windowWidth - offsetValue));
3938
+ const paddingStyles = window.getComputedStyle(popupEle);
3851
3939
  if (paddingStyles) {
3852
3940
  paddingWidth = parseFloat(paddingStyles.paddingLeft) + parseFloat(paddingStyles.paddingRight);
3853
- if (!(isNullOrUndefined(paddingWidth)))
3941
+ if (!(isNullOrUndefined(paddingWidth))) {
3854
3942
  screenWidth = screenWidth - paddingWidth;
3943
+ }
3855
3944
  }
3856
- let popupContainerItems = popupEle.querySelectorAll('.e-ribbon-gallery-container');
3945
+ const popupContainerItems = popupEle.querySelectorAll('.e-ribbon-gallery-container');
3857
3946
  if (popup.width !== 'auto') {
3858
3947
  popupContainerItems.forEach((ele) => {
3859
3948
  ele.style.flexFlow = 'wrap';
@@ -3863,15 +3952,16 @@ class RibbonGallery {
3863
3952
  for (let i = 0; i < popupContainerItems.length; i++) {
3864
3953
  let itemsWidth = 0;
3865
3954
  for (let j = 0; j < popupContainerItems[parseInt(i.toString(), 10)].querySelectorAll('.e-ribbon-gallery-item').length; j++) {
3866
- let marginStyles = window.getComputedStyle(popupContainerItems[parseInt(i.toString(), 10)].querySelectorAll('.e-ribbon-gallery-item')[parseInt(j.toString(), 10)]);
3867
- if (marginStyles) {
3868
- marginWidth = parseFloat(marginStyles.marginLeft) + parseFloat(marginStyles.marginRight);
3869
- if (!(isNullOrUndefined(marginWidth)))
3955
+ const popupItemStyles = window.getComputedStyle(popupContainerItems[parseInt(i.toString(), 10)].querySelectorAll('.e-ribbon-gallery-item')[parseInt(j.toString(), 10)]);
3956
+ if (popupItemStyles) {
3957
+ marginWidth = parseFloat(popupItemStyles.marginLeft) + parseFloat(popupItemStyles.marginRight);
3958
+ if (!(isNullOrUndefined(marginWidth))) {
3870
3959
  itemsWidth += marginWidth;
3960
+ }
3871
3961
  }
3872
- itemsWidth += popupContainerItems[parseInt(i.toString(), 10)].querySelectorAll('.e-ribbon-gallery-item')[parseInt(j.toString(), 10)].offsetWidth;
3962
+ itemsWidth += Math.round(parseFloat(popupItemStyles.width));
3873
3963
  if (((screenWidth <= itemsWidth) && popup.width === 'auto') || ((popup.width !== 'auto') && (screenWidth <= parseInt(popup.width.toString(), 10)) && (screenWidth <= itemsWidth))) {
3874
- popupEle.style.width = ((itemsWidth + Math.abs(paddingWidth - marginWidth)) - popupContainerItems[parseInt(i.toString(), 10)].querySelectorAll('.e-ribbon-gallery-item')[parseInt(j.toString(), 10)].offsetWidth) + 'px';
3964
+ popupEle.style.width = ((itemsWidth + Math.abs(paddingWidth - marginWidth)) - Math.round(parseFloat(popupItemStyles.width))) + 'px';
3875
3965
  isCollideOccurs = true;
3876
3966
  break;
3877
3967
  }
@@ -3880,6 +3970,9 @@ class RibbonGallery {
3880
3970
  popupContainerItems.forEach((ele) => {
3881
3971
  ele.style.flexFlow = 'wrap';
3882
3972
  });
3973
+ if (popup.height === 'auto') {
3974
+ this.setGalleryPopupHeight(popupEle, parseFloat(paddingStyles.height), parseFloat(paddingStyles.top));
3975
+ }
3883
3976
  break;
3884
3977
  }
3885
3978
  }
@@ -3893,11 +3986,22 @@ class RibbonGallery {
3893
3986
  else {
3894
3987
  popupEle.style.width = (popup.width).toString();
3895
3988
  }
3989
+ if (popup.height === 'auto') {
3990
+ this.setGalleryPopupHeight(popupEle, parseFloat(paddingStyles.height), parseFloat(paddingStyles.top));
3991
+ }
3896
3992
  }
3897
3993
  }
3898
3994
  }
3995
+ setGalleryPopupHeight(popupEle, popupHeight, popupTop) {
3996
+ if (window.innerHeight < popupHeight || window.innerHeight < Math.round(popupHeight + popupTop)) {
3997
+ popupEle.style.height = (window.innerHeight - popupTop) + 'px';
3998
+ }
3999
+ else {
4000
+ popupEle.style.height = 'auto';
4001
+ }
4002
+ }
3899
4003
  createPopup(item, buttonEle) {
3900
- let popupContainer = this.parent.createElement('div', {
4004
+ const popupContainer = this.parent.createElement('div', {
3901
4005
  className: 'e-ribbon-popup-container',
3902
4006
  id: item.id + '_popupContainer'
3903
4007
  });
@@ -3929,16 +4033,19 @@ class RibbonGallery {
3929
4033
  * @hidden
3930
4034
  */
3931
4035
  switchGalleryItems(activeLayout, itemID) {
3932
- let itemEle = this.parent.element.querySelector('#' + itemID + CONTAINER_ID);
3933
- let count = 0;
4036
+ const itemEle = this.parent.element.querySelector('#' + itemID + CONTAINER_ID);
3934
4037
  const itemProp = getItem(this.parent.tabs, itemID);
3935
4038
  if (itemEle) {
3936
- let galleryWrapper = itemEle.querySelector('.e-ribbon-gallery-wrapper');
3937
- let galleryIcons = itemEle.querySelectorAll('.e-ribbon-gallery-icons');
3938
- let galleryContainer = itemEle.querySelectorAll('.e-ribbon-gallery-container');
4039
+ const galleryIcons = itemEle.querySelectorAll('.e-ribbon-gallery-icons');
4040
+ const galleryContainer = itemEle.querySelectorAll('.e-ribbon-gallery-container');
3939
4041
  if (galleryIcons.length) {
3940
4042
  for (let i = 0; i < galleryIcons.length; i++) {
3941
- activeLayout === 'Simplified' ? galleryIcons[parseInt(i.toString(), 10)].classList.add('e-hidden') : galleryIcons[parseInt(i.toString(), 10)].classList.remove('e-hidden');
4043
+ if (activeLayout === 'Simplified') {
4044
+ galleryIcons[parseInt(i.toString(), 10)].classList.add('e-hidden');
4045
+ }
4046
+ else {
4047
+ galleryIcons[parseInt(i.toString(), 10)].classList.remove('e-hidden');
4048
+ }
3942
4049
  }
3943
4050
  }
3944
4051
  if (galleryContainer.length && itemProp) {
@@ -3946,24 +4053,20 @@ class RibbonGallery {
3946
4053
  for (let i = 0; i < galleryContainer.length; i++) {
3947
4054
  if (itemProp.item.gallerySettings.groups[parseInt(n.toString(), 10)].itemHeight && itemProp.item.gallerySettings.groups[parseInt(n.toString(), 10)].itemHeight !== 'auto') {
3948
4055
  if (itemID + '_galleryContainer' + n === galleryContainer[parseInt(i.toString(), 10)].id) {
3949
- activeLayout === 'Simplified' ? galleryContainer[parseInt(i.toString(), 10)].style.flexFlow = 'nowrap' : galleryContainer[parseInt(i.toString(), 10)].style.flexFlow = 'wrap';
4056
+ if (activeLayout === 'Simplified') {
4057
+ galleryContainer[parseInt(i.toString(), 10)].style.flexFlow = 'nowrap';
4058
+ }
4059
+ else {
4060
+ galleryContainer[parseInt(i.toString(), 10)].style.flexFlow = 'wrap';
4061
+ }
3950
4062
  }
3951
4063
  }
3952
4064
  }
3953
4065
  }
3954
4066
  }
3955
- if (galleryWrapper) {
3956
- for (let n = 0; n < itemProp.item.gallerySettings.groups.length; n++) {
3957
- for (let i = 0; i < itemProp.item.gallerySettings.groups[parseInt(n.toString(), 10)].items.length; i++) {
3958
- count++;
3959
- if (count > itemProp.item.gallerySettings.itemCount) {
3960
- let galleryItemEle = galleryWrapper.querySelector('#' + itemID + '_galleryContainer' + n + '_gallery' + i);
3961
- if (galleryItemEle) {
3962
- activeLayout === 'Simplified' ? galleryItemEle.classList.add('e-hidden') : galleryItemEle.classList.remove('e-hidden');
3963
- }
3964
- }
3965
- }
3966
- }
4067
+ const activeContent = this.parent.tabObj.element.querySelector('#' + this.parent.tabs[this.parent.selectedTab].id + CONTENT_ID);
4068
+ if (activeContent) {
4069
+ this.checkAvailableHeight(activeContent);
3967
4070
  }
3968
4071
  }
3969
4072
  }
@@ -3972,26 +4075,26 @@ class RibbonGallery {
3972
4075
  *
3973
4076
  * @param {RibbonItemModel} item - Gets the ribbon item model.
3974
4077
  * @param {HTMLElement} itemEle - Gets the ribbon item element.
3975
- * @param {DropDownButton} overflowButton - Gets the overflow button.
3976
4078
  * @returns {void}
3977
4079
  * @hidden
3978
4080
  */
3979
- addOverFlowEvents(item, itemEle, overflowButton) {
4081
+ addOverFlowEvents(item, itemEle) {
3980
4082
  if (itemEle.closest('.e-ribbon-overflow-target')) {
3981
4083
  const buttonEle = this.parent.createElement('button', {
3982
- id: item.id,
4084
+ id: item.id
3983
4085
  });
3984
4086
  itemEle.appendChild(buttonEle);
3985
4087
  itemEle.querySelector('.e-ribbon-gallery-wrapper').classList.add('e-hidden');
3986
4088
  itemEle.querySelectorAll('.e-ribbon-gallery-container').forEach((ele) => {
3987
4089
  ele.classList.add('e-hidden');
3988
4090
  });
3989
- let popupButton = itemEle.querySelector('#' + item.id + '_popupButton');
3990
- if (popupButton)
4091
+ const popupButton = itemEle.querySelector('#' + item.id + '_popupButton');
4092
+ if (popupButton) {
3991
4093
  popupButton.classList.add('e-hidden');
4094
+ }
3992
4095
  const itemProp = getItem(this.parent.tabs, item.id);
3993
4096
  let iconCss = itemProp && itemProp.group.groupIconCss ? itemProp.group.groupIconCss : '';
3994
- let content = itemProp && itemProp.group.header ? itemProp.group.header : '';
4097
+ const content = itemProp && itemProp.group.header ? itemProp.group.header : '';
3995
4098
  if (!iconCss) {
3996
4099
  for (let i = 0; i < item.gallerySettings.groups.length; i++) {
3997
4100
  for (let j = 0; j < item.gallerySettings.groups[parseInt(i.toString(), 10)].items.length; j++) {
@@ -4005,9 +4108,9 @@ class RibbonGallery {
4005
4108
  }
4006
4109
  }
4007
4110
  }
4008
- let popupEle = document.querySelector('#' + item.id + '_galleryPopup');
4009
- let popup = getComponent(popupEle, Popup);
4010
- let popupContainerEle = document.querySelector('#' + item.id + '_galleryPopup .e-ribbon-popup-container');
4111
+ const popupEle = document.querySelector('#' + item.id + '_galleryPopup');
4112
+ const popup = getComponent(popupEle, Popup);
4113
+ const popupContainerEle = document.querySelector('#' + item.id + '_galleryPopup .e-ribbon-popup-container');
4011
4114
  const dropdown = new DropDownButton({
4012
4115
  iconCss: iconCss,
4013
4116
  content: content,
@@ -4017,7 +4120,6 @@ class RibbonGallery {
4017
4120
  disabled: item.disabled,
4018
4121
  open: () => {
4019
4122
  this.setFoucsToFirstItem(popupContainerEle, true, item.id);
4020
- this.checkCollision(dropdown.dropDown, dropdown.dropDown.element);
4021
4123
  },
4022
4124
  beforeClose: (args) => {
4023
4125
  const isCancelled = this.popupEvents(args.event, item.gallerySettings, 'popupClose', false);
@@ -4044,7 +4146,7 @@ class RibbonGallery {
4044
4146
  * @hidden
4045
4147
  */
4046
4148
  removeOverFlowEvents(item, itemEle) {
4047
- let popupButton = itemEle.querySelector('#' + item.id + '_popupButton');
4149
+ const popupButton = itemEle.querySelector('#' + item.id + '_popupButton');
4048
4150
  if (popupButton) {
4049
4151
  popupButton.classList.remove('e-hidden');
4050
4152
  }
@@ -4054,20 +4156,20 @@ class RibbonGallery {
4054
4156
  });
4055
4157
  const galleryDDBEle = document.querySelector('#' + item.id);
4056
4158
  if (galleryDDBEle) {
4057
- let popupEle = document.querySelector('#' + item.id + '_galleryPopup');
4159
+ const popupEle = document.querySelector('#' + item.id + '_galleryPopup');
4058
4160
  const dropdown = getComponent(galleryDDBEle, DropDownButton);
4059
4161
  popupEle.appendChild(dropdown.target);
4060
4162
  dropdown.destroy();
4061
4163
  remove(galleryDDBEle);
4062
4164
  }
4063
4165
  }
4064
- setActiveState(galleryEle, gallerySettings, itemID, isInteracted, event) {
4166
+ setActiveState(galleryEle, gallerySettings, itemID, isInteracted, event, isPopup) {
4065
4167
  let previousItem;
4066
4168
  let currentItem;
4067
- let itemEle = document.querySelector('#' + itemID + CONTAINER_ID);
4169
+ const itemEle = document.querySelector('#' + itemID + CONTAINER_ID);
4068
4170
  let selctedGalleryItem = Array.prototype.slice.call(itemEle.querySelectorAll('.e-ribbon-gallery-selected'));
4069
- let popupEle = document.querySelector('#' + itemID + '_popupContainer');
4070
- let popupGalleryItem = Array.prototype.slice.call(popupEle.querySelectorAll('.e-ribbon-gallery-selected'));
4171
+ const popupEle = document.querySelector('#' + itemID + '_popupContainer');
4172
+ const popupGalleryItem = Array.prototype.slice.call(popupEle.querySelectorAll('.e-ribbon-gallery-selected'));
4071
4173
  if (popupGalleryItem.length) {
4072
4174
  selctedGalleryItem = selctedGalleryItem.concat(popupGalleryItem);
4073
4175
  }
@@ -4076,12 +4178,13 @@ class RibbonGallery {
4076
4178
  if (selctedGalleryItem[0].id === itemID + '_galleryContainer' + i + '_gallery' + j) {
4077
4179
  previousItem = gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)];
4078
4180
  }
4079
- if (galleryEle.id === itemID + '_galleryContainer' + i + '_gallery' + j) {
4181
+ if (galleryEle.id === (isPopup ? 'popup_' : '') + itemID + '_galleryContainer' + i + '_gallery' + j) {
4080
4182
  currentItem = gallerySettings.groups[parseInt(i.toString(), 10)].items[parseInt(j.toString(), 10)];
4081
4183
  }
4082
4184
  }
4083
4185
  }
4084
- let galleryItem = document.querySelectorAll('#' + galleryEle.id);
4186
+ const galleryItem = document.getElementById(galleryEle.id);
4187
+ let galleryItemPopup;
4085
4188
  const selectingEventArgs = { cancel: false, name: 'beforeSelect', previousItem: previousItem, currentItem: currentItem, isInteracted: isInteracted, event: event };
4086
4189
  if (gallerySettings.beforeSelect) {
4087
4190
  gallerySettings.beforeSelect.call(this, selectingEventArgs);
@@ -4093,11 +4196,18 @@ class RibbonGallery {
4093
4196
  for (let i = 0; i < selctedGalleryItem.length; i++) {
4094
4197
  selctedGalleryItem[parseInt(i.toString(), 10)].classList.remove('e-ribbon-gallery-selected');
4095
4198
  }
4096
- for (let i = 0; i < galleryItem.length; i++) {
4097
- galleryItem[parseInt(i.toString(), 10)].classList.add('e-ribbon-gallery-selected');
4199
+ if (!galleryItem.id.startsWith('popup_')) {
4200
+ galleryItemPopup = document.getElementById('popup_' + galleryEle.id);
4201
+ }
4202
+ else if (document.getElementById(galleryItem.id.slice(6))) {
4203
+ galleryItemPopup = document.getElementById(galleryItem.id.slice(6));
4098
4204
  }
4205
+ if (galleryItemPopup) {
4206
+ galleryItemPopup.classList.add('e-ribbon-gallery-selected');
4207
+ }
4208
+ galleryItem.classList.add('e-ribbon-gallery-selected');
4099
4209
  const selectedEventArgs = { previousItem: previousItem, currentItem: currentItem, name: 'select', isInteracted: isInteracted, event: event };
4100
- let galleryPopupItems = document.querySelectorAll('#' + itemID + '_popupContainer .e-ribbon-gallery-item');
4210
+ const galleryPopupItems = document.querySelectorAll('#' + itemID + '_popupContainer .e-ribbon-gallery-item');
4101
4211
  for (let i = 0; i < galleryPopupItems.length; i++) {
4102
4212
  if (galleryPopupItems[parseInt(i.toString(), 10)].id === galleryEle.id) {
4103
4213
  gallerySettings.selectedItemIndex = i;
@@ -4132,6 +4242,9 @@ class RibbonGallery {
4132
4242
  const buttonEle = document.querySelector('#' + itemID + '_popupButton');
4133
4243
  buttonEle.classList.add('e-gallery-button-active');
4134
4244
  const buttonPosition = buttonEle.getBoundingClientRect();
4245
+ if (popupEle.offsetWidth > buttonPosition.left) {
4246
+ this.checkCollision(popup, popupEle, buttonPosition.left);
4247
+ }
4135
4248
  const offsetX = Math.abs((popupEle.offsetWidth - buttonPosition.left)) + buttonEle.offsetWidth;
4136
4249
  popupEle.style.left = offsetX + 'px';
4137
4250
  popupEle.style.top = popupEle.getBoundingClientRect().top + 2 + 'px';
@@ -4154,8 +4267,8 @@ class RibbonGallery {
4154
4267
  */
4155
4268
  showGalleryPopup(id) {
4156
4269
  const itemProp = getItem(this.parent.tabs, id);
4157
- let popupEle = document.querySelector('#' + id + '_galleryPopup');
4158
- let popup = getComponent(popupEle, Popup);
4270
+ const popupEle = document.querySelector('#' + id + '_galleryPopup');
4271
+ const popup = getComponent(popupEle, Popup);
4159
4272
  this.showPopup(popup, popupEle, null, itemProp.item.gallerySettings, id);
4160
4273
  }
4161
4274
  /**
@@ -4166,8 +4279,8 @@ class RibbonGallery {
4166
4279
  */
4167
4280
  hideGalleryPopup(id) {
4168
4281
  const itemProp = getItem(this.parent.tabs, id);
4169
- let popupEle = document.querySelector('#' + id + '_galleryPopup');
4170
- let popup = getComponent(popupEle, Popup);
4282
+ const popupEle = document.querySelector('#' + id + '_galleryPopup');
4283
+ const popup = getComponent(popupEle, Popup);
4171
4284
  this.hidePopup(popup, popupEle, null, itemProp.item.gallerySettings, id);
4172
4285
  }
4173
4286
  setFoucsToFirstItem(popupEle, isDropdown, itemID, popup, gallerySettings) {
@@ -4178,7 +4291,7 @@ class RibbonGallery {
4178
4291
  };
4179
4292
  }
4180
4293
  handleGalleryPopupNavigation(e, popupEle, isDropdown, itemID, popup, gallerySettings) {
4181
- let galleryPopupEle = popupEle.querySelectorAll('.e-ribbon-gallery-item');
4294
+ const galleryPopupEle = popupEle.querySelectorAll('.e-ribbon-gallery-item');
4182
4295
  if (galleryPopupEle) {
4183
4296
  if (e.key === 'Home') {
4184
4297
  this.galleryItemsIndex = 0;
@@ -4212,10 +4325,7 @@ class RibbonGallery {
4212
4325
  galleryPopupEle[this.galleryItemsIndex].focus();
4213
4326
  }
4214
4327
  }
4215
- else if (e.key === 'Enter' || e.code === 'Space') {
4216
- galleryPopupEle[this.galleryItemsIndex].click();
4217
- }
4218
- else if (e.key === 'Escape' && !isDropdown) {
4328
+ else if ((e.key === 'Enter' || e.code === 'Space') || (e.key === 'Escape' && !isDropdown)) {
4219
4329
  this.hidePopup(popup, popupEle, e, gallerySettings, itemID);
4220
4330
  }
4221
4331
  }
@@ -4231,8 +4341,7 @@ class RibbonGallery {
4231
4341
  if (items.cssClass) {
4232
4342
  galleryItemEle.classList.add(items.cssClass);
4233
4343
  }
4234
- append(templateFunction({ items: items }, this, templateName, (id + 'galleryTemplate'), this.parent.isStringTemplate), galleryItemEle);
4235
- this.parent['renderReactTemplates']();
4344
+ append(templateFunction({ items: items }, this, templateName, (id + 'galleryTemplate'), this.parent.isStringTemplate, null, null, this.parent), galleryItemEle);
4236
4345
  }
4237
4346
  createGalleryPopupTemplate(galleryItemEle, gallerySettings, id, items) {
4238
4347
  galleryItemEle.classList.add('e-ribbon-gallery-popup-template');
@@ -4245,12 +4354,11 @@ class RibbonGallery {
4245
4354
  if (items.cssClass) {
4246
4355
  galleryItemEle.classList.add(items.cssClass);
4247
4356
  }
4248
- append(templateFunction({ items: items }, this, templateName, (id + 'galleryPopupTemplate'), this.parent.isStringTemplate), galleryItemEle);
4249
- this.parent['renderReactTemplates']();
4357
+ append(templateFunction({ items: items }, this, templateName, (id + 'galleryPopupTemplate'), this.parent.isStringTemplate, null, null, this.parent), galleryItemEle);
4250
4358
  }
4251
4359
  }
4252
4360
 
4253
- var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
4361
+ var __decorate$l = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
4254
4362
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4255
4363
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4256
4364
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
@@ -4625,16 +4733,16 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
4625
4733
  }
4626
4734
  }
4627
4735
  }
4628
- let galleryPopupEle = document.querySelector('.e-ribbon-gallery-popup.e-popup-open');
4736
+ const galleryPopupEle = document.querySelector('.e-ribbon-gallery-popup.e-popup-open');
4629
4737
  if (galleryPopupEle) {
4630
- let popup = getComponent(galleryPopupEle, Popup);
4738
+ const popup = getComponent(galleryPopupEle, Popup);
4631
4739
  popup.hide();
4632
4740
  }
4633
4741
  if (this.ribbonKeyTipModule && this.enableKeyTips) {
4634
4742
  this.ribbonKeyTipModule.removeKeytip();
4635
4743
  }
4636
4744
  }
4637
- mouseEventHandler(e) {
4745
+ mouseEventHandler() {
4638
4746
  if (this.ribbonKeyTipModule && this.enableKeyTips) {
4639
4747
  this.ribbonKeyTipModule.removeKeytip();
4640
4748
  }
@@ -4710,25 +4818,24 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
4710
4818
  addKeyTip(tabIndex, keyTip, id, type) {
4711
4819
  if (this.keyTipElements && this.keyTipElements[parseInt(tabIndex.toString(), 10)]) {
4712
4820
  let isKeyTipExist = false;
4713
- /* eslint-disable */
4714
- if (!(this.keyTipElements[parseInt(tabIndex.toString(), 10)][type])) {
4715
- this.keyTipElements[parseInt(tabIndex.toString(), 10)][type] = [];
4821
+ if (!(this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`])) {
4822
+ this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`] = [];
4716
4823
  }
4717
- if (Object.keys(this.keyTipElements[tabIndex][type]).length) {
4718
- let keytipData = this.keyTipElements[tabIndex][type];
4719
- for (let i = 0; i < Object.keys(this.keyTipElements[tabIndex][type]).length; i++) {
4824
+ if (Object.keys(this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`]).length) {
4825
+ const keytipData = this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`];
4826
+ for (let i = 0; i < Object.keys(this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`]).length; i++) {
4720
4827
  if (keytipData[parseInt(i.toString(), 10)].id === id) {
4721
4828
  isKeyTipExist = true;
4722
4829
  }
4723
4830
  }
4724
4831
  if (!isKeyTipExist) {
4725
- this.keyTipElements[tabIndex][type].push({ id: id, type: type, keyTip: keyTip });
4832
+ this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`].
4833
+ push({ id: id, type: type, keyTip: keyTip });
4726
4834
  }
4727
4835
  }
4728
4836
  else {
4729
- this.keyTipElements[tabIndex][type].push({ id: id, type: type, keyTip: keyTip });
4837
+ this.keyTipElements[parseInt(tabIndex.toString(), 10)][`${type}`].push({ id: id, type: type, keyTip: keyTip });
4730
4838
  }
4731
- /* eslint-enable */
4732
4839
  }
4733
4840
  }
4734
4841
  renderTabs() {
@@ -4796,7 +4903,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
4796
4903
  const selectedTabId = e.selectedItem.getAttribute('data-id');
4797
4904
  let selectedIndex = getIndex(this.tabs, ((tab) => (tab.id === selectedTabId)));
4798
4905
  selectedIndex = selectedIndex === -1 ? this.selectedTab : selectedIndex;
4799
- let isContextual = this.isContextualTab(selectedTabId);
4906
+ const isContextual = this.isContextualTab(selectedTabId);
4800
4907
  this.updateSelectedState(selectedTabId);
4801
4908
  const eventArgs = { previousIndex: this.selectedTab, selectedIndex: selectedIndex, isContextual: isContextual };
4802
4909
  this.setProperties({ selectedTab: selectedIndex }, true);
@@ -4814,10 +4921,10 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
4814
4921
  this.isUpdateItems = false;
4815
4922
  }
4816
4923
  }
4817
- this.checkOverflow(selectedIndex, e.selectedContent.firstChild);
4818
- if (this.activeLayout === 'Classic' && this.ribbonGalleryModule) {
4819
- this.ribbonGalleryModule.checkAvailableHeight(selectedIndex, e.selectedContent.firstChild);
4924
+ if (this.ribbonGalleryModule) {
4925
+ this.ribbonGalleryModule.checkAvailableHeight(e.selectedContent.firstChild);
4820
4926
  }
4927
+ this.checkOverflow(selectedIndex, e.selectedContent.firstChild);
4821
4928
  if (this.activeLayout === 'Simplified' && this.overflowDDB) {
4822
4929
  const overflowTarget = this.overflowDDB.target;
4823
4930
  const ofTabContainer = overflowTarget.querySelector('.' + RIBBON_TAB_ACTIVE);
@@ -4846,7 +4953,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
4846
4953
  break;
4847
4954
  }
4848
4955
  }
4849
- this.contextualTabs[parseInt(i.toString(), 10)].setProperties({ isSelected: isSelected }, true);
4956
+ this.contextualTabs[parseInt(i.toString(), 10)].
4957
+ setProperties({ isSelected: isSelected }, true);
4850
4958
  }
4851
4959
  }
4852
4960
  }
@@ -5044,7 +5152,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5044
5152
  item.setProperties({ activeSize: RibbonItemSize.Medium }, true);
5045
5153
  this.setItemSize(itemEle, item);
5046
5154
  }
5047
- if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) || (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
5155
+ if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) ||
5156
+ (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
5048
5157
  this.updatePopupItems(item, itemContainer, group.enableGroupOverflow, true);
5049
5158
  }
5050
5159
  }
@@ -5053,7 +5162,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5053
5162
  if (!(group.enableGroupOverflow || groupEle.querySelector('.' + RIBBON_ITEM))) {
5054
5163
  groupEle.classList.add('e-ribbon-emptyCollection');
5055
5164
  }
5056
- let itemsLength = groupEle.querySelectorAll('.' + RIBBON_ITEM);
5165
+ const itemsLength = groupEle.querySelectorAll('.' + RIBBON_ITEM);
5057
5166
  if (itemsLength && !group.enableGroupOverflow) {
5058
5167
  isEmptyCollection = this.checkEmptyCollection(itemsLength);
5059
5168
  if (isEmptyCollection) {
@@ -5085,6 +5194,9 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5085
5194
  if (isMenu) {
5086
5195
  dropdown.beforeOpen = () => {
5087
5196
  if (isLeft) {
5197
+ if (item.type === RibbonItemType.Gallery && this.ribbonGalleryModule) {
5198
+ this.ribbonGalleryModule.checkCollision(dropDownPopup, dropDownPopup.element);
5199
+ }
5088
5200
  dropDownPopup.element.style.setProperty('visibility', 'hidden');
5089
5201
  dropDownPopup.element.style.setProperty('display', 'block');
5090
5202
  dropDownPopup.setProperties({ offsetX: -1 * dropDownPopup.element.offsetWidth });
@@ -5139,7 +5251,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5139
5251
  break;
5140
5252
  }
5141
5253
  const groupEle = tabContent.querySelector('#' + collection.id);
5142
- if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) || (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
5254
+ if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) ||
5255
+ (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
5143
5256
  this.updatePopupItems(item, itemContainer, group.enableGroupOverflow, false);
5144
5257
  }
5145
5258
  groupEle.append(itemContainer);
@@ -5171,7 +5284,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5171
5284
  const groupElement = tabContent.querySelector('#' + group.id);
5172
5285
  const itemEle = groupElement.querySelector('.' + RIBBON_ITEM);
5173
5286
  if (groupElement.classList.contains('e-ribbon-emptyCollection') && itemEle !== null) {
5174
- let itemsLength = groupElement.querySelectorAll('.' + RIBBON_ITEM);
5287
+ const itemsLength = groupElement.querySelectorAll('.' + RIBBON_ITEM);
5175
5288
  if (itemsLength) {
5176
5289
  isEmptyCollection = this.checkEmptyCollection(itemsLength);
5177
5290
  if (!isEmptyCollection) {
@@ -5184,7 +5297,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5184
5297
  }
5185
5298
  if (overflowDDB) {
5186
5299
  if (group.enableGroupOverflow) {
5187
- if (overflowtarget.childElementCount === 0 || (overflowtarget.childElementCount === 1 && this.isHeaderVisible(overflowtarget, group.id))) {
5300
+ if (overflowtarget.childElementCount === 0 ||
5301
+ (overflowtarget.childElementCount === 1 && this.isHeaderVisible(overflowtarget, group.id))) {
5188
5302
  this.removeOverflowButton(overflowDDB);
5189
5303
  }
5190
5304
  }
@@ -5218,7 +5332,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5218
5332
  if (overflowDDB) {
5219
5333
  const overflowButton = getInstance(overflowDDB, DropDownButton);
5220
5334
  const overflowBtnTarget = overflowButton.target;
5221
- let itemEle = overflowBtnTarget.querySelectorAll('.e-ribbon-item');
5335
+ const itemEle = overflowBtnTarget.querySelectorAll('.e-ribbon-item');
5222
5336
  let isHidden = true;
5223
5337
  for (let i = 0; i < itemEle.length; i++) {
5224
5338
  if (!(itemEle[parseInt(i.toString(), 10)].classList.contains('e-hidden'))) {
@@ -5239,7 +5353,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5239
5353
  for (let k = 0; k < ofTabContainer.children.length; k++) {
5240
5354
  isItemHidden = true;
5241
5355
  const overflowTab = ofTabContainer.children[parseInt(k.toString(), 10)];
5242
- let groupTabContainer = overflowTab.querySelectorAll('.e-ribbon-item');
5356
+ const groupTabContainer = overflowTab.querySelectorAll('.e-ribbon-item');
5243
5357
  for (let n = 0; n < groupTabContainer.length; n++) {
5244
5358
  if (!(groupTabContainer[parseInt(n.toString(), 10)].classList.contains('e-hidden'))) {
5245
5359
  isItemHidden = false;
@@ -5275,7 +5389,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5275
5389
  this.addKeyTip(tabIndex, '0' + (itemProp.groupIndex + 1), overflowButton.element.id, 'grpofbtn');
5276
5390
  overflowtarget = overflowButton.target;
5277
5391
  const overflowBtnTarget = overflowButton.target;
5278
- let headerEle = overflowBtnTarget.querySelector('#' + groupId + GROUPOF_BUTTON_ID + HEADER_ID);
5392
+ const headerEle = overflowBtnTarget.querySelector('#' + groupId + GROUPOF_BUTTON_ID + HEADER_ID);
5279
5393
  if (!headerEle) {
5280
5394
  if (itemProp.group.overflowHeader) {
5281
5395
  const groupHeader = this.createElement('div', {
@@ -5297,8 +5411,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5297
5411
  overflowBtnTarget.classList.add('e-hide-group');
5298
5412
  }
5299
5413
  }
5300
- isResize ? overflowBtnTarget.insertBefore(itemEle, overflowBtnTarget.querySelector('.' + RIBBON_ITEM))
5301
- : overflowBtnTarget.append(itemEle);
5414
+ if (isResize) {
5415
+ overflowBtnTarget.insertBefore(itemEle, overflowBtnTarget.querySelector('.' + RIBBON_ITEM));
5416
+ }
5417
+ else {
5418
+ overflowBtnTarget.append(itemEle);
5419
+ }
5302
5420
  }
5303
5421
  else {
5304
5422
  if (!this.overflowDDB) {
@@ -5310,7 +5428,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5310
5428
  else {
5311
5429
  this.overflowDDB.element.classList.remove(HIDE_CSS);
5312
5430
  const overflowEle = this.overflowDDB.target;
5313
- const ofTabContainer = overflowEle.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
5431
+ const ofTabContainer = overflowEle.querySelector('#' +
5432
+ this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
5314
5433
  if (ofTabContainer) {
5315
5434
  let ofGroupContainer = overflowEle.querySelector('#' + groupId + CONTAINER_ID);
5316
5435
  if (!ofGroupContainer) {
@@ -5328,7 +5447,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5328
5447
  }
5329
5448
  ofTabContainer.append(ofGroupContainer);
5330
5449
  }
5331
- isResize ? ofGroupContainer.insertBefore(itemEle, ofGroupContainer.querySelector('.' + RIBBON_ITEM)) : ofGroupContainer.append(itemEle);
5450
+ if (isResize) {
5451
+ ofGroupContainer.insertBefore(itemEle, ofGroupContainer.querySelector('.' + RIBBON_ITEM));
5452
+ }
5453
+ else {
5454
+ ofGroupContainer.append(itemEle);
5455
+ }
5332
5456
  }
5333
5457
  else {
5334
5458
  this.createOfTabContainer(groupId, groupHeader, itemEle, tabIndex);
@@ -5368,7 +5492,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5368
5492
  break;
5369
5493
  case 'Gallery':
5370
5494
  if (this.activeLayout === 'Simplified') {
5371
- this.ribbonGalleryModule.addOverFlowEvents(item, itemEle, overflowButton);
5495
+ this.ribbonGalleryModule.addOverFlowEvents(item, itemEle);
5372
5496
  }
5373
5497
  break;
5374
5498
  case 'GroupButton':
@@ -5386,13 +5510,14 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5386
5510
  const overflowtarget = this.overflowDDB.target;
5387
5511
  overflowtarget.append(ofTabContainer);
5388
5512
  const itemProp = getGroup(this.tabs, groupId);
5389
- let ofGroupContainer = itemProp.group.overflowHeader ? this.createGroupContainer(groupId, itemProp.group.overflowHeader) : this.createGroupContainer(groupId, groupHeader);
5513
+ const ofGroupContainer = itemProp.group.overflowHeader ?
5514
+ this.createGroupContainer(groupId, itemProp.group.overflowHeader) : this.createGroupContainer(groupId, groupHeader);
5390
5515
  ofGroupContainer.append(itemEle);
5391
5516
  ofTabContainer.append(ofGroupContainer);
5392
5517
  if (tabIndex === this.selectedTab) {
5393
5518
  ofTabContainer.classList.add(RIBBON_TAB_ACTIVE);
5394
5519
  }
5395
- let groupEle = document.querySelector('#' + groupId);
5520
+ const groupEle = document.querySelector('#' + groupId);
5396
5521
  if (groupEle) {
5397
5522
  if (groupEle.classList.contains('e-disabled')) {
5398
5523
  ofGroupContainer.classList.add('e-disabled');
@@ -5738,7 +5863,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5738
5863
  }
5739
5864
  const item = collection.items[parseInt(l.toString(), 10)];
5740
5865
  if (canReduceItem(item)) {
5741
- item.type !== RibbonItemType.GroupButton ? setWidth(item.id) : setWidth(item.id + RIBBON_GROUP_BUTTON_ID);
5866
+ if (item.type !== RibbonItemType.GroupButton) {
5867
+ setWidth(item.id);
5868
+ }
5869
+ else {
5870
+ setWidth(item.id + RIBBON_GROUP_BUTTON_ID);
5871
+ }
5742
5872
  reduceItemsToSmall(k, l, l);
5743
5873
  if (!shouldSkip && (tabContent.offsetWidth > activeContent.offsetWidth)) {
5744
5874
  return true;
@@ -5989,7 +6119,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
5989
6119
  }
5990
6120
  handleContentSize(itemEle, isRemoveOverflow) {
5991
6121
  const itemContainer = itemEle.closest('.' + RIBBON_GROUP_CONTENT);
5992
- (isRemoveOverflow ? (itemContainer.classList.add(RIBBON_CONTENT_HEIGHT)) : (itemContainer.classList.remove(RIBBON_CONTENT_HEIGHT)));
6122
+ if (isRemoveOverflow) {
6123
+ itemContainer.classList.add(RIBBON_CONTENT_HEIGHT);
6124
+ }
6125
+ else {
6126
+ itemContainer.classList.remove(RIBBON_CONTENT_HEIGHT);
6127
+ }
5993
6128
  }
5994
6129
  setItemSize(itemEle, item) {
5995
6130
  if (itemEle) {
@@ -6179,11 +6314,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6179
6314
  const nextTabId = e.selectingItem.getAttribute('data-id');
6180
6315
  const previousTabId = e.previousItem.getAttribute('data-id');
6181
6316
  let nextIndex = getIndex(this.tabs, ((tab) => (tab.id === nextTabId)));
6182
- let isContextual = this.isContextualTab(nextTabId);
6317
+ const isContextual = this.isContextualTab(nextTabId);
6183
6318
  const previousIndex = getIndex(this.tabs, ((tab) => (tab.id === previousTabId)));
6184
6319
  nextIndex = nextIndex === -1 ? this.selectedTab : nextIndex;
6185
6320
  const eventArgs = {
6186
- cancel: e.cancel, isInteracted: e.isInteracted, previousIndex: previousIndex, selectedIndex: nextIndex, isContextual: isContextual
6321
+ cancel: e.cancel, isInteracted: e.isInteracted, previousIndex: previousIndex,
6322
+ selectedIndex: nextIndex, isContextual: isContextual
6187
6323
  };
6188
6324
  this.trigger('tabSelecting', eventArgs, (args) => {
6189
6325
  if (args.cancel) {
@@ -6236,9 +6372,10 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6236
6372
  this.element.classList.add(RIBBON_SIMPLIFIED_MODE);
6237
6373
  }
6238
6374
  const activeContent = this.tabObj.element.querySelector('#' + this.tabs[this.selectedTab].id + CONTENT_ID);
6375
+ if (this.ribbonGalleryModule) {
6376
+ this.ribbonGalleryModule.checkAvailableHeight(activeContent);
6377
+ }
6239
6378
  this.checkOverflow(this.selectedTab, activeContent);
6240
- if (this.activeLayout === 'Classic' && this.ribbonGalleryModule)
6241
- this.ribbonGalleryModule.checkAvailableHeight(this.selectedTab, activeContent);
6242
6379
  }
6243
6380
  addOverflowButton(btnId, isGroupOF) {
6244
6381
  const overflowButton = this.createElement('button', {
@@ -6295,7 +6432,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6295
6432
  items = currentList.getElementsByClassName('e-ribbon-item');
6296
6433
  }
6297
6434
  const control = items[(!this.itemIndex || this.itemIndex < 0) ? 0 : this.itemIndex].querySelector('.e-control');
6298
- const comboBoxEle = control && control.classList.contains('e-combobox') ? items[(!this.itemIndex || this.itemIndex < 0) ? 0 : this.itemIndex].querySelector('.e-combobox') : null;
6435
+ const comboBoxEle = control && control.classList.contains('e-combobox') ?
6436
+ items[(!this.itemIndex || this.itemIndex < 0) ? 0 : this.itemIndex].querySelector('.e-combobox') : null;
6299
6437
  let ribbonItem;
6300
6438
  let templateEle;
6301
6439
  if (comboBoxEle === null || (e.key === 'Tab') || this.itemIndex < 0) {
@@ -6352,7 +6490,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6352
6490
  target.setAttribute('index', this.itemIndex.toString());
6353
6491
  }
6354
6492
  const currentItemIndex = parseInt(target.getAttribute('index'), 10);
6355
- let itemType = "";
6493
+ let itemType = '';
6356
6494
  const controlItem = items[parseInt(currentItemIndex.toString(), 10)] ? items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-control') : null;
6357
6495
  if (controlItem) {
6358
6496
  itemType = controlItem.getAttribute('data-control');
@@ -6382,12 +6520,20 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6382
6520
  }
6383
6521
  if (((itemType === 'SplitButton') && (e.key === 'ArrowRight' || e.key === 'ArrowLeft'))) {
6384
6522
  if (e.key === 'ArrowRight') {
6385
- this.enableRtl ? items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-control').focus() :
6523
+ if (this.enableRtl) {
6524
+ items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-control').focus();
6525
+ }
6526
+ else {
6386
6527
  items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-dropdown-btn').focus();
6528
+ }
6387
6529
  }
6388
6530
  if (e.key === 'ArrowLeft') {
6389
- this.enableRtl ? items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-dropdown-btn').focus() :
6531
+ if (this.enableRtl) {
6532
+ items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-dropdown-btn').focus();
6533
+ }
6534
+ else {
6390
6535
  items[parseInt(currentItemIndex.toString(), 10)].querySelector('.e-control').focus();
6536
+ }
6391
6537
  }
6392
6538
  }
6393
6539
  if (e.key === 'Enter') {
@@ -6496,11 +6642,11 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6496
6642
  reRenderTabs(tabs) {
6497
6643
  this.destroyScroll();
6498
6644
  this.checkID(this.tabs, 'tab', this.element.id);
6499
- for (const key in tabs) {
6645
+ for (const key of Object.keys(tabs)) {
6500
6646
  const index = parseInt(key, 10);
6501
6647
  const tab = tabs[parseInt(index.toString(), 10)];
6502
6648
  let isNewTab = false;
6503
- for (var j = 0; j < (this.tabObj.items.length); j++) {
6649
+ for (let j = 0; j < (this.tabObj.items.length); j++) {
6504
6650
  if (this.tabs[parseInt(index.toString(), 10)].id === this.tabObj.items[parseInt(j.toString(), 10)].id) {
6505
6651
  isNewTab = true;
6506
6652
  break;
@@ -6642,7 +6788,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6642
6788
  itemEle = groupContainer.querySelector('#' + item.id + CONTAINER_ID);
6643
6789
  if (item.displayOptions === (DisplayMode.Classic | DisplayMode.Overflow)) {
6644
6790
  this.createOverflowPopup(item, tabIndex, group.enableGroupOverflow, group.id, group.header, itemEle, groupContainer);
6645
- if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) || (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
6791
+ if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) ||
6792
+ (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
6646
6793
  this.updatePopupItems(item, itemEle, group.enableGroupOverflow, true);
6647
6794
  }
6648
6795
  }
@@ -6741,7 +6888,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6741
6888
  let itemEle = groupContainer.querySelector('#' + item.id + CONTAINER_ID);
6742
6889
  if (!itemEle && overflowtarget) {
6743
6890
  itemEle = overflowtarget.querySelector('#' + item.id + CONTAINER_ID);
6744
- if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) || (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
6891
+ if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) ||
6892
+ (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
6745
6893
  this.updatePopupItems(item, itemEle, group.enableGroupOverflow, false);
6746
6894
  }
6747
6895
  this.removeOverflowEvent(item, itemEle);
@@ -6766,7 +6914,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6766
6914
  }
6767
6915
  }
6768
6916
  if (group.enableGroupOverflow && overflowDDB) {
6769
- if (overflowtarget.childElementCount === 0 || (overflowtarget.childElementCount === 1 && this.isHeaderVisible(overflowtarget, group.id))) {
6917
+ if (overflowtarget.childElementCount === 0 ||
6918
+ (overflowtarget.childElementCount === 1 && this.isHeaderVisible(overflowtarget, group.id))) {
6770
6919
  this.removeOverflowButton(overflowDDB);
6771
6920
  }
6772
6921
  }
@@ -6878,7 +7027,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
6878
7027
  // eslint-disable-next-line
6879
7028
  let groupIndex = initialProps[key].indexOf(groupEle.id);
6880
7029
  if (groupIndex !== -1) {
6881
- key === 'hiddenGroups' ? groupEle.classList.add('e-hidden') : groupEle.classList.add('e-disabled');
7030
+ if (key === 'hiddenGroups') {
7031
+ groupEle.classList.add('e-hidden');
7032
+ }
7033
+ else {
7034
+ groupEle.classList.add('e-disabled');
7035
+ }
6882
7036
  }
6883
7037
  }
6884
7038
  validateItemSize() {
@@ -7002,7 +7156,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7002
7156
  }
7003
7157
  if (item.type === RibbonItemType.GroupButton) {
7004
7158
  for (let i = 0; i < item.groupButtonSettings.items.length; i++) {
7005
- if (this.keyTipElements[parseInt(tabIndex.toString(), 10)] && item.groupButtonSettings.items[parseInt(i.toString(), 10)].keyTip) {
7159
+ if (this.keyTipElements[parseInt(tabIndex.toString(), 10)] &&
7160
+ item.groupButtonSettings.items[parseInt(i.toString(), 10)].keyTip) {
7006
7161
  this.addKeyTip(tabIndex, item.groupButtonSettings.items[parseInt(i.toString(), 10)].keyTip, item.id + (RIBBON_GROUP_BUTTON_ID + i), 'item');
7007
7162
  }
7008
7163
  }
@@ -7039,7 +7194,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7039
7194
  this.createRibbonItem(item, itemEle);
7040
7195
  if ((this.activeLayout === 'Simplified') && ((item.displayOptions === DisplayMode.Overflow) || (item.displayOptions === (DisplayMode.Classic | DisplayMode.Overflow)))) {
7041
7196
  this.createOverflowPopup(item, tabIndex, isGroupOF, groupId, groupHeader, itemEle, groupContainer);
7042
- if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) || (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
7197
+ if ((item.type === RibbonItemType.DropDown) || (item.type === RibbonItemType.SplitButton) ||
7198
+ (item.type === RibbonItemType.GroupButton) || (item.type === RibbonItemType.Gallery)) {
7043
7199
  this.updatePopupItems(item, itemEle, isGroupOF, true);
7044
7200
  }
7045
7201
  }
@@ -7096,7 +7252,11 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7096
7252
  for (let i = 0; i < list.length; i++) {
7097
7253
  const listitem = list[parseInt(i.toString(), 10)];
7098
7254
  if (!listitem.id) {
7099
- listitem.setProperties({ id: initId + key + (this.idIndex++) }, true);
7255
+ let htmlAttrID;
7256
+ if (type === 'item') {
7257
+ htmlAttrID = this.hasHtmlAtrrID(listitem);
7258
+ }
7259
+ listitem.setProperties({ id: htmlAttrID ? htmlAttrID : initId + key + (this.idIndex++) }, true);
7100
7260
  }
7101
7261
  switch (type) {
7102
7262
  case 'tab':
@@ -7108,12 +7268,32 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7108
7268
  case 'collection':
7109
7269
  listitem.setProperties({ items: this.checkID(listitem.items, 'item', listitem.id) }, true);
7110
7270
  break;
7111
- default:
7112
- break;
7113
7271
  }
7114
7272
  }
7115
7273
  return list;
7116
7274
  }
7275
+ hasHtmlAtrrID(listItem) {
7276
+ let id = '';
7277
+ if (listItem.buttonSettings.htmlAttributes.id) {
7278
+ id = listItem.buttonSettings.htmlAttributes.id;
7279
+ }
7280
+ else if (listItem.checkBoxSettings.htmlAttributes.id) {
7281
+ id = listItem.checkBoxSettings.htmlAttributes.id;
7282
+ }
7283
+ else if (listItem.colorPickerSettings.htmlAttributes.id) {
7284
+ id = listItem.colorPickerSettings.htmlAttributes.id;
7285
+ }
7286
+ else if (listItem.comboBoxSettings.htmlAttributes.id) {
7287
+ id = listItem.comboBoxSettings.htmlAttributes.id;
7288
+ }
7289
+ else if (listItem.dropDownSettings.htmlAttributes.id) {
7290
+ id = listItem.dropDownSettings.htmlAttributes.id;
7291
+ }
7292
+ else if (listItem.splitButtonSettings.htmlAttributes.id) {
7293
+ id = listItem.splitButtonSettings.htmlAttributes.id;
7294
+ }
7295
+ return id;
7296
+ }
7117
7297
  updateCommonProperty(commonProp) {
7118
7298
  this.tabObj.setProperties(commonProp);
7119
7299
  if (this.ribbonFileMenuModule) {
@@ -7227,8 +7407,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7227
7407
  ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id) :
7228
7408
  contentEle.querySelector('#' + item.id);
7229
7409
  if (item.type === RibbonItemType.GroupButton) {
7230
- ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id + RIBBON_GROUP_BUTTON_ID) :
7231
- contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
7410
+ ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id +
7411
+ RIBBON_GROUP_BUTTON_ID) : contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
7232
7412
  }
7233
7413
  if (item.type === RibbonItemType.Gallery) {
7234
7414
  ele = contentEle.querySelector('#' + item.id + CONTAINER_ID);
@@ -7295,22 +7475,22 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7295
7475
  else if (moduleName === 'gallery') {
7296
7476
  if (ele.closest('.e-ribbon-overflow-target')) {
7297
7477
  destroyControl(ele, 'dropdown-btn');
7298
- let galleryPopupEle = Array.prototype.slice.call(document.querySelectorAll('#' + item.id + '_galleryPopup'));
7478
+ const galleryPopupEle = Array.prototype.slice.call(document.querySelectorAll('#' + item.id + '_galleryPopup'));
7299
7479
  galleryPopupEle.concat(Array.prototype.slice.call(document.querySelectorAll('#' + item.id + '-popup')));
7300
7480
  for (let i = 0; i < galleryPopupEle.length; i++) {
7301
7481
  galleryPopupEle[parseInt(i.toString(), 10)].remove();
7302
7482
  }
7303
7483
  }
7304
7484
  else {
7305
- let galleryEle = ele.querySelectorAll('.e-ribbon-gallery-item');
7306
- let galleryPopupBtn = ele.querySelector('#' + item.id + '_popupButton');
7485
+ const galleryEle = ele.querySelectorAll('.e-ribbon-gallery-item');
7486
+ const galleryPopupBtn = ele.querySelector('#' + item.id + '_popupButton');
7307
7487
  if (galleryPopupBtn) {
7308
7488
  galleryPopupBtn.remove();
7309
7489
  }
7310
7490
  for (let i = 0; i < galleryEle.length; i++) {
7311
7491
  galleryEle[parseInt(i.toString(), 10)].remove();
7312
7492
  }
7313
- let galleryPopupEle = document.querySelectorAll('#' + item.id + '_galleryPopup');
7493
+ const galleryPopupEle = document.querySelectorAll('#' + item.id + '_galleryPopup');
7314
7494
  for (let i = 0; i < galleryPopupEle.length; i++) {
7315
7495
  galleryPopupEle[parseInt(i.toString(), 10)].remove();
7316
7496
  }
@@ -7391,6 +7571,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7391
7571
  * Shows a specific tab in the ribbon.
7392
7572
  *
7393
7573
  * @param {string} tabId - The ID of the tab to be shown.
7574
+ * @param {boolean} isContextual - The boolean if the rendering is contextual.
7394
7575
  * @returns {void}
7395
7576
  */
7396
7577
  showTab(tabId, isContextual = false) {
@@ -7400,6 +7581,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7400
7581
  * Hides a specific tab in the ribbon.
7401
7582
  *
7402
7583
  * @param {string} tabId - The ID of the tab to be hidden.
7584
+ * @param {boolean} isContextual - The boolean if the rendering is contextual.
7403
7585
  * @returns {void}
7404
7586
  */
7405
7587
  hideTab(tabId, isContextual = false) {
@@ -7424,7 +7606,9 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7424
7606
  if (contextualTab) {
7425
7607
  let isTabHidden = true;
7426
7608
  for (let i = 0; i < contextualTab.tabs.length; i++) {
7427
- const index = getIndex(this.tabs, (e) => { return e.id === contextualTab.tabs[parseInt(i.toString(), 10)].id; });
7609
+ const index = getIndex(this.tabs, (e) => {
7610
+ return e.id === contextualTab.tabs[parseInt(i.toString(), 10)].id;
7611
+ });
7428
7612
  if (index !== -1) {
7429
7613
  const toolbarEle = tabEle.querySelectorAll('.e-toolbar-item')[parseInt(index.toString(), 10)];
7430
7614
  if (!(toolbarEle.classList.contains('e-hidden'))) {
@@ -7506,8 +7690,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7506
7690
  for (const item of collection.items) {
7507
7691
  let ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id) : contentEle.querySelector('#' + item.id);
7508
7692
  if (item.type === RibbonItemType.GroupButton && this.activeLayout === 'Classic') {
7509
- ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id + RIBBON_GROUP_BUTTON_ID) :
7510
- contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
7693
+ ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id +
7694
+ RIBBON_GROUP_BUTTON_ID) : contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
7511
7695
  }
7512
7696
  if (ele) {
7513
7697
  this.destroyFunction(item, ele);
@@ -7603,7 +7787,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7603
7787
  }
7604
7788
  if (this.activeLayout === RibbonLayout.Simplified) {
7605
7789
  if (itemProp.group.enableGroupOverflow) {
7606
- if (dropdown.target.childElementCount === 0 || (dropdown.target.childElementCount === 1 && this.isHeaderVisible(dropdown.target, itemProp.group.id))) {
7790
+ if (dropdown.target.childElementCount === 0 || (dropdown.target.childElementCount
7791
+ === 1 && this.isHeaderVisible(dropdown.target, itemProp.group.id))) {
7607
7792
  this.removeOverflowButton(dropdown);
7608
7793
  }
7609
7794
  }
@@ -7676,13 +7861,23 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7676
7861
  overflowtarget = overflowDDB.target;
7677
7862
  }
7678
7863
  if (overflowtarget) {
7679
- isHidden ? overflowtarget.classList.add('e-hidden') : overflowtarget.classList.remove('e-hidden');
7864
+ if (isHidden) {
7865
+ overflowtarget.classList.add('e-hidden');
7866
+ }
7867
+ else {
7868
+ overflowtarget.classList.remove('e-hidden');
7869
+ }
7680
7870
  }
7681
7871
  }
7682
7872
  else if (ofTabContainer) {
7683
7873
  const grpContainer = ofTabContainer.querySelector('#' + groupID + CONTAINER_ID);
7684
7874
  if (grpContainer) {
7685
- isHidden ? grpContainer.classList.add('e-hidden') : grpContainer.classList.remove('e-hidden');
7875
+ if (isHidden) {
7876
+ grpContainer.classList.add('e-hidden');
7877
+ }
7878
+ else {
7879
+ grpContainer.classList.remove('e-hidden');
7880
+ }
7686
7881
  }
7687
7882
  }
7688
7883
  }
@@ -7720,38 +7915,35 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7720
7915
  hiddenProps = this.hiddenElements[parseInt(tabIndex.toString(), 10)];
7721
7916
  }
7722
7917
  if (hiddenProps) {
7723
- /* eslint-disable */
7724
- if (!hiddenProps[key]) {
7725
- hiddenProps[key] = [];
7918
+ if (!hiddenProps[`${key}`]) {
7919
+ hiddenProps[`${key}`] = [];
7726
7920
  }
7727
- if (hiddenProps[key].length) {
7728
- let index = hiddenProps[key].indexOf(id);
7921
+ if (hiddenProps[`${key}`].length) {
7922
+ const index = hiddenProps[`${key}`].indexOf(id);
7729
7923
  if (index === -1) {
7730
- hiddenProps[key].push(id);
7924
+ hiddenProps[`${key}`].push(id);
7731
7925
  }
7732
7926
  }
7733
7927
  else {
7734
- hiddenProps[key].push(id);
7928
+ hiddenProps[`${key}`].push(id);
7735
7929
  }
7736
- /* eslint-enable */
7737
7930
  }
7738
7931
  }
7739
7932
  }
7740
7933
  updateItemsSimplifiedWidth(tabIndex, key) {
7741
- let hiddenProps = this.hiddenElements[parseInt(tabIndex.toString(), 10)];
7742
- /* eslint-disable */
7743
- if (hiddenProps && hiddenProps[key] && hiddenProps[key].length) {
7744
- for (let i = 0; i < hiddenProps[key].length; i++) {
7745
- const contentEle = this.tabObj.items[tabIndex].content;
7934
+ const hiddenProps = this.hiddenElements[parseInt(tabIndex.toString(), 10)];
7935
+ if (hiddenProps && hiddenProps[`${key}`] && hiddenProps[`${key}`].length) {
7936
+ for (let i = 0; i < hiddenProps[`${key}`].length; i++) {
7937
+ const contentEle = this.tabObj.items[parseInt(tabIndex.toString(), 10)].content;
7746
7938
  let hiddenEle;
7747
7939
  let groupEle;
7748
7940
  let isGroupHidden = false;
7749
7941
  let widthDifference = 0;
7750
7942
  if (key === 'hideGroup' || key === 'showGroup') {
7751
- hiddenEle = contentEle.querySelector('#' + hiddenProps[key][i]);
7943
+ hiddenEle = contentEle.querySelector('#' + hiddenProps[`${key}`][parseInt(i.toString(), 10)]);
7752
7944
  }
7753
7945
  else {
7754
- hiddenEle = contentEle.querySelector('#' + hiddenProps[key][i] + CONTAINER_ID);
7946
+ hiddenEle = contentEle.querySelector('#' + hiddenProps[`${key}`][parseInt(i.toString(), 10)] + CONTAINER_ID);
7755
7947
  }
7756
7948
  if (hiddenEle) {
7757
7949
  if (key === 'hideGroup' || key === 'hideItem') {
@@ -7787,7 +7979,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7787
7979
  }
7788
7980
  else {
7789
7981
  if (this.hiddenGroups.indexOf(groupEle.id) !== -1) {
7790
- let hiddenItems = groupEle.querySelectorAll('.e-ribbon-item:not(.e-hidden)');
7982
+ const hiddenItems = groupEle.querySelectorAll('.e-ribbon-item:not(.e-hidden)');
7791
7983
  hiddenItems.forEach((item) => {
7792
7984
  if (item.id !== hiddenEle.id) {
7793
7985
  item.classList.add('e-hidden');
@@ -7811,12 +8003,11 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7811
8003
  groupEle.classList.add('e-ribbon-emptyCollection');
7812
8004
  }
7813
8005
  }
7814
- let index = hiddenProps[key].indexOf(hiddenProps[key][i]);
8006
+ const index = hiddenProps[`${key}`].indexOf(hiddenProps[`${key}`][parseInt(i.toString(), 10)]);
7815
8007
  if (index !== -1) {
7816
- hiddenProps[key].splice(index, 1);
8008
+ hiddenProps[`${key}`].splice(index, 1);
7817
8009
  i--;
7818
8010
  }
7819
- /* eslint-enable */
7820
8011
  }
7821
8012
  }
7822
8013
  }
@@ -7838,7 +8029,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7838
8029
  }
7839
8030
  calculateHiddenElementsWidth(tabIndex) {
7840
8031
  if (tabIndex === this.selectedTab && this.activeLayout === 'Simplified') {
7841
- let hiddenProps = this.hiddenElements[parseInt(tabIndex.toString(), 10)];
8032
+ const hiddenProps = this.hiddenElements[parseInt(tabIndex.toString(), 10)];
7842
8033
  if (hiddenProps) {
7843
8034
  for (let i = 0; i < Object.keys(hiddenProps).length; i++) {
7844
8035
  this.updateItemsSimplifiedWidth(tabIndex, Object.keys(hiddenProps)[parseInt(i.toString(), 10)]);
@@ -7849,23 +8040,23 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7849
8040
  calculateMediumDataWidth(hiddenWidth, tabIndex, isHidden) {
7850
8041
  if (this.selectedTab === tabIndex && this.activeLayout === 'Simplified') {
7851
8042
  const activeContent = this.tabObj.element.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + CONTENT_ID);
7852
- let mediumDataItems = Array.prototype.slice.call(activeContent.querySelectorAll('.e-ribbon-item'));
8043
+ const mediumDataItems = Array.prototype.slice.call(activeContent.querySelectorAll('.e-ribbon-item'));
7853
8044
  if (this.overflowDDB) {
7854
8045
  const overflowEle = this.overflowDDB.target;
7855
- let overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
7856
- let selectedOFTab = document.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
8046
+ const overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
8047
+ const selectedOFTab = document.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
7857
8048
  for (let i = 0; i < overflowItems.length; i++) {
7858
- let ofTab = overflowItems[parseInt(i.toString(), 10)].closest('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
8049
+ const ofTab = overflowItems[parseInt(i.toString(), 10)].closest('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
7859
8050
  if (selectedOFTab && ofTab && selectedOFTab.id === ofTab.id && overflowItems[parseInt(i.toString(), 10)].hasAttribute('data-medium-width')) {
7860
8051
  mediumDataItems.push(overflowItems[parseInt(i.toString(), 10)]);
7861
8052
  }
7862
8053
  }
7863
8054
  }
7864
- let groupOFButton = activeContent.querySelectorAll('.e-ribbon-group-of-btn');
8055
+ const groupOFButton = activeContent.querySelectorAll('.e-ribbon-group-of-btn');
7865
8056
  for (let i = 0; i < groupOFButton.length; i++) {
7866
- let overflowButton = getInstance(groupOFButton[parseInt(i.toString(), 10)], DropDownButton);
8057
+ const overflowButton = getInstance(groupOFButton[parseInt(i.toString(), 10)], DropDownButton);
7867
8058
  const overflowBtnTarget = overflowButton.target;
7868
- let overflowItems = overflowBtnTarget.querySelectorAll('.e-ribbon-item');
8059
+ const overflowItems = overflowBtnTarget.querySelectorAll('.e-ribbon-item');
7869
8060
  for (let i = 0; i < overflowItems.length; i++) {
7870
8061
  if (overflowItems[parseInt(i.toString(), 10)].hasAttribute('data-medium-width')) {
7871
8062
  mediumDataItems.push(overflowItems[parseInt(i.toString(), 10)]);
@@ -7874,7 +8065,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7874
8065
  }
7875
8066
  for (let i = 0; i < mediumDataItems.length; i++) {
7876
8067
  if (mediumDataItems[parseInt(i.toString(), 10)].hasAttribute('data-medium-width')) {
7877
- let previousWidth = parseInt(mediumDataItems[parseInt(i.toString(), 10)].getAttribute('data-medium-width'), 10);
8068
+ const previousWidth = parseInt(mediumDataItems[parseInt(i.toString(), 10)].getAttribute('data-medium-width'), 10);
7878
8069
  mediumDataItems[parseInt(i.toString(), 10)].setAttribute('data-medium-width', isHidden ? (previousWidth - hiddenWidth).toString() : (previousWidth + hiddenWidth).toString());
7879
8070
  }
7880
8071
  }
@@ -7886,7 +8077,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7886
8077
  for (let i = 0; i < groupList.length; i++) {
7887
8078
  const group = groupList[parseInt(i.toString(), 10)];
7888
8079
  if (group.enableGroupOverflow) {
7889
- let groupContainer = document.querySelector('#' + group.id);
8080
+ const groupContainer = document.querySelector('#' + group.id);
7890
8081
  let overflowButton;
7891
8082
  const overflowDDB = groupContainer.querySelector('#' + group.id + GROUPOF_BUTTON_ID);
7892
8083
  if (overflowDDB) {
@@ -7894,9 +8085,9 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7894
8085
  }
7895
8086
  if (overflowButton) {
7896
8087
  const overflowEle = overflowButton.target;
7897
- let overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
8088
+ const overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
7898
8089
  for (let i = 0; i < overflowItems.length; i++) {
7899
- let previousWidth = parseInt(overflowItems[parseInt(i.toString(), 10)].getAttribute('data-simplified-width'), 10);
8090
+ const previousWidth = parseInt(overflowItems[parseInt(i.toString(), 10)].getAttribute('data-simplified-width'), 10);
7900
8091
  if (previousWidth) {
7901
8092
  overflowItems[parseInt(i.toString(), 10)].setAttribute('data-simplified-width', isHidden ? (previousWidth - hiddenItem).toString() : (previousWidth + hiddenItem).toString());
7902
8093
  }
@@ -7906,13 +8097,13 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7906
8097
  }
7907
8098
  }
7908
8099
  if (this.overflowDDB) {
7909
- let selectedOFTab = document.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
8100
+ const selectedOFTab = document.querySelector('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
7910
8101
  const overflowEle = this.overflowDDB.target;
7911
- let overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
8102
+ const overflowItems = overflowEle.querySelectorAll('.e-ribbon-item');
7912
8103
  for (let i = 0; i < overflowItems.length; i++) {
7913
- let ofTab = overflowItems[parseInt(i.toString(), 10)].closest('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
8104
+ const ofTab = overflowItems[parseInt(i.toString(), 10)].closest('#' + this.tabs[parseInt(tabIndex.toString(), 10)].id + OVERFLOW_ID);
7914
8105
  if (selectedOFTab && ofTab && selectedOFTab.id === ofTab.id) {
7915
- let previousWidth = parseInt(overflowItems[parseInt(i.toString(), 10)].getAttribute('data-simplified-width'), 10);
8106
+ const previousWidth = parseInt(overflowItems[parseInt(i.toString(), 10)].getAttribute('data-simplified-width'), 10);
7916
8107
  if (previousWidth) {
7917
8108
  overflowItems[parseInt(i.toString(), 10)].setAttribute('data-simplified-width', isHidden ? (previousWidth - hiddenItem).toString() : (previousWidth + hiddenItem).toString());
7918
8109
  }
@@ -7948,7 +8139,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7948
8139
  const contentEle = this.tabObj.items[itemProp.tabIndex].content;
7949
8140
  const groupEle = contentEle.querySelector('#' + groupID);
7950
8141
  if (groupEle) {
7951
- isDisabled ? groupEle.classList.add('e-disabled') : groupEle.classList.remove('e-disabled');
8142
+ if (isDisabled) {
8143
+ groupEle.classList.add('e-disabled');
8144
+ }
8145
+ else {
8146
+ groupEle.classList.remove('e-disabled');
8147
+ }
7952
8148
  }
7953
8149
  else {
7954
8150
  this.updateInitialProps(itemProp.tabIndex, groupID, 'disabledGroups', isDisabled);
@@ -7963,13 +8159,23 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
7963
8159
  overflowtarget = overflowDDB.target;
7964
8160
  }
7965
8161
  if (overflowtarget) {
7966
- isDisabled ? overflowtarget.classList.add('e-disabled') : overflowtarget.classList.remove('e-disabled');
8162
+ if (isDisabled) {
8163
+ overflowtarget.classList.add('e-disabled');
8164
+ }
8165
+ else {
8166
+ overflowtarget.classList.remove('e-disabled');
8167
+ }
7967
8168
  }
7968
8169
  }
7969
8170
  else if (ofTabContainer) {
7970
8171
  const grpContainer = ofTabContainer.querySelector('#' + groupID + CONTAINER_ID);
7971
8172
  if (grpContainer) {
7972
- isDisabled ? grpContainer.classList.add('e-disabled') : grpContainer.classList.remove('e-disabled');
8173
+ if (isDisabled) {
8174
+ grpContainer.classList.add('e-disabled');
8175
+ }
8176
+ else {
8177
+ grpContainer.classList.remove('e-disabled');
8178
+ }
7973
8179
  }
7974
8180
  }
7975
8181
  }
@@ -8194,19 +8400,22 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8194
8400
  initialProps = this.initialPropsData[parseInt(tabIndex.toString(), 10)];
8195
8401
  }
8196
8402
  if (initialProps) {
8197
- /* eslint-disable */
8198
- if (!initialProps[key])
8199
- initialProps[key] = [];
8200
- const itemIndex = initialProps[key].indexOf(id);
8403
+ if (!initialProps[`${key}`]) {
8404
+ initialProps[`${key}`] = [];
8405
+ }
8406
+ const itemIndex = initialProps[`${key}`].indexOf(id);
8201
8407
  if (isInsert) {
8202
- if (itemIndex === -1)
8203
- initialProps[key].push(id);
8408
+ if (itemIndex === -1) {
8409
+ initialProps[`${key}`].push(id);
8410
+ }
8204
8411
  }
8205
8412
  else {
8206
- if (itemIndex !== -1)
8207
- initialProps[key].splice(itemIndex, 1);
8208
- initialProps[key].length === 0 && delete initialProps[key];
8209
- /* eslint-enable */
8413
+ if (itemIndex !== -1) {
8414
+ initialProps[`${key}`].splice(itemIndex, 1);
8415
+ }
8416
+ if (initialProps[`${key}`].length === 0) {
8417
+ delete initialProps[`${key}`];
8418
+ }
8210
8419
  if (Object.keys(initialProps).length === 0) {
8211
8420
  delete this.initialPropsData[parseInt(tabIndex.toString(), 10)];
8212
8421
  }
@@ -8232,7 +8441,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8232
8441
  else {
8233
8442
  itemEle = getItemElement(this, item.id);
8234
8443
  }
8235
- let itemContainer = itemEle ? itemEle.closest('.e-ribbon-item') : null;
8444
+ const itemContainer = itemEle ? itemEle.closest('.e-ribbon-item') : null;
8236
8445
  if (!(itemContainer.classList.contains('e-hidden'))) {
8237
8446
  isItemsHidden = false;
8238
8447
  break;
@@ -8250,7 +8459,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8250
8459
  this.checkOverflowItems(isHidden, contentEle, group.enableGroupOverflow, tabIndex, group.id);
8251
8460
  }
8252
8461
  if (this.activeLayout === 'Simplified' && !group.enableGroupOverflow) {
8253
- let itemsLength = groupEle.querySelectorAll('.' + RIBBON_ITEM);
8462
+ const itemsLength = groupEle.querySelectorAll('.' + RIBBON_ITEM);
8254
8463
  if (itemsLength) {
8255
8464
  isEmptyCollection = this.checkEmptyCollection(itemsLength);
8256
8465
  groupEle.classList[isEmptyCollection ? 'add' : 'remove']('e-ribbon-emptyCollection');
@@ -8267,7 +8476,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8267
8476
  overflowtarget = overflowDDB.target;
8268
8477
  }
8269
8478
  if (overflowtarget) {
8270
- isHidden ? overflowtarget.classList.add('e-hide-group') : overflowtarget.classList.remove('e-hide-group');
8479
+ if (isHidden) {
8480
+ overflowtarget.classList.add('e-hide-group');
8481
+ }
8482
+ else {
8483
+ overflowtarget.classList.remove('e-hide-group');
8484
+ }
8271
8485
  }
8272
8486
  }
8273
8487
  else {
@@ -8277,7 +8491,12 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8277
8491
  if (ofTabContainer) {
8278
8492
  const grpContainer = ofTabContainer.querySelector('#' + groupID + CONTAINER_ID);
8279
8493
  if (grpContainer) {
8280
- isHidden ? grpContainer.classList.add('e-hide-group') : grpContainer.classList.remove('e-hide-group');
8494
+ if (isHidden) {
8495
+ grpContainer.classList.add('e-hide-group');
8496
+ }
8497
+ else {
8498
+ grpContainer.classList.remove('e-hide-group');
8499
+ }
8281
8500
  }
8282
8501
  }
8283
8502
  }
@@ -8314,8 +8533,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8314
8533
  for (const item of collection.items) {
8315
8534
  let ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id) : contentEle.querySelector('#' + item.id);
8316
8535
  if (item.type === RibbonItemType.GroupButton && this.activeLayout === 'Classic') {
8317
- ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id + RIBBON_GROUP_BUTTON_ID) :
8318
- contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
8536
+ ele = dropdownElement ? this.ribbonDropDownModule.getDDBItemElement(dropdownElement, item.id +
8537
+ RIBBON_GROUP_BUTTON_ID) : contentEle.querySelector('#' + item.id + RIBBON_GROUP_BUTTON_ID);
8319
8538
  }
8320
8539
  if (ele) {
8321
8540
  this.destroyFunction(item, ele);
@@ -8419,7 +8638,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8419
8638
  }
8420
8639
  if (this.activeLayout === RibbonLayout.Simplified) {
8421
8640
  if (itemProp.group.enableGroupOverflow) {
8422
- if (dropdown.target.childElementCount === 0 || (dropdown.target.childElementCount === 1 && this.isHeaderVisible(dropdown.target, itemProp.group.id))) {
8641
+ if (dropdown.target.childElementCount === 0 || (dropdown.target.childElementCount
8642
+ === 1 && this.isHeaderVisible(dropdown.target, itemProp.group.id))) {
8423
8643
  this.removeOverflowButton(dropdown);
8424
8644
  }
8425
8645
  }
@@ -8716,7 +8936,7 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8716
8936
  * Gets the Ribbon item model associated with the specified item ID.
8717
8937
  *
8718
8938
  * @param {string} itemId - The unique ID of the Ribbon item.
8719
- * @returns {RibbonItemModel}
8939
+ * @returns {RibbonItemModel} - Returns the Ribbon item model.
8720
8940
  */
8721
8941
  getItem(itemId) {
8722
8942
  return getItem(this.tabs, itemId).item;
@@ -8738,7 +8958,8 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8738
8958
  if (ele) {
8739
8959
  const itemEle = closest(ele, '.e-ribbon-item');
8740
8960
  const moduleName = this.getItemModuleName(itemProp.item);
8741
- isUpdated = isDisabled ? !itemEle.classList.contains(DISABLED_CSS) : itemEle.classList.contains(DISABLED_CSS);
8961
+ isUpdated = isDisabled ? !itemEle.classList.contains(DISABLED_CSS) :
8962
+ itemEle.classList.contains(DISABLED_CSS);
8742
8963
  if (moduleName !== 'template') {
8743
8964
  if (isUpdated) {
8744
8965
  if (moduleName === 'group-btn' && this.activeLayout === 'Simplified') {
@@ -8876,13 +9097,14 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8876
9097
  }
8877
9098
  }
8878
9099
  break;
8879
- case 'selectedTab':
9100
+ case 'selectedTab': {
8880
9101
  const tabEle = this.tabObj.element;
8881
9102
  const toolbarItem = tabEle.querySelectorAll('.e-toolbar-item')[parseInt(newProp.selectedTab.toString(), 10)];
8882
9103
  if (!(toolbarItem.classList.contains('e-hidden') || toolbarItem.classList.contains('e-disable'))) {
8883
9104
  this.tabObj.setProperties({ selectedItem: newProp.selectedTab });
8884
9105
  }
8885
9106
  break;
9107
+ }
8886
9108
  case 'tabAnimation':
8887
9109
  this.tabObj.setProperties({ animation: newProp.tabAnimation });
8888
9110
  break;
@@ -8900,21 +9122,23 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8900
9122
  this.element.style.width = formatUnit(newProp.width);
8901
9123
  this.refreshLayout();
8902
9124
  break;
8903
- case 'fileMenu':
9125
+ case 'fileMenu': {
8904
9126
  if (this.ribbonFileMenuModule) {
8905
9127
  this.ribbonFileMenuModule.updateFileMenu(this.fileMenu);
8906
9128
  }
8907
9129
  const toolbarEle = this.tabObj['tbObj'];
8908
9130
  toolbarEle.refreshOverflow();
8909
9131
  break;
8910
- case 'backStageMenu':
9132
+ }
9133
+ case 'backStageMenu': {
8911
9134
  if (this.ribbonBackstageModule) {
8912
9135
  this.ribbonBackstageModule.updateBackStageMenu(this.backStageMenu);
8913
9136
  }
8914
9137
  const toolbarElement = this.tabObj['tbObj'];
8915
9138
  toolbarElement.refreshOverflow();
8916
9139
  break;
8917
- case 'helpPaneTemplate':
9140
+ }
9141
+ case 'helpPaneTemplate': {
8918
9142
  if (this.ribbonTempEle) {
8919
9143
  remove(this.ribbonTempEle);
8920
9144
  this.ribbonTempEle = null;
@@ -8926,93 +9150,95 @@ let Ribbon = Ribbon_1 = class Ribbon extends Component {
8926
9150
  const toolbar = this.tabObj['tbObj'];
8927
9151
  toolbar.refreshOverflow();
8928
9152
  break;
9153
+ }
8929
9154
  case 'hideLayoutSwitcher':
8930
- this.hideLayoutSwitcher ? this.removeExpandCollapse() : this.addExpandCollapse();
9155
+ if (this.hideLayoutSwitcher) {
9156
+ this.removeExpandCollapse();
9157
+ }
9158
+ else {
9159
+ this.addExpandCollapse();
9160
+ }
8931
9161
  break;
8932
9162
  }
8933
9163
  }
8934
9164
  }
8935
9165
  };
8936
- __decorate([
9166
+ __decorate$l([
8937
9167
  Property('Classic')
8938
9168
  ], Ribbon.prototype, "activeLayout", void 0);
8939
- __decorate([
9169
+ __decorate$l([
8940
9170
  Property('')
8941
9171
  ], Ribbon.prototype, "cssClass", void 0);
8942
- __decorate([
9172
+ __decorate$l([
8943
9173
  Property(false)
8944
9174
  ], Ribbon.prototype, "enableKeyTips", void 0);
8945
- __decorate([
9175
+ __decorate$l([
8946
9176
  Property('')
8947
9177
  ], Ribbon.prototype, "layoutSwitcherKeyTip", void 0);
8948
- __decorate([
9178
+ __decorate$l([
8949
9179
  Complex({}, FileMenuSettings)
8950
9180
  ], Ribbon.prototype, "fileMenu", void 0);
8951
- __decorate([
9181
+ __decorate$l([
8952
9182
  Complex({}, BackStageMenu)
8953
9183
  ], Ribbon.prototype, "backStageMenu", void 0);
8954
- __decorate([
9184
+ __decorate$l([
8955
9185
  Property('')
8956
9186
  ], Ribbon.prototype, "launcherIconCss", void 0);
8957
- __decorate([
9187
+ __decorate$l([
8958
9188
  Property(false)
8959
9189
  ], Ribbon.prototype, "isMinimized", void 0);
8960
- __decorate([
9190
+ __decorate$l([
8961
9191
  Property('en-us')
8962
9192
  ], Ribbon.prototype, "locale", void 0);
8963
- __decorate([
9193
+ __decorate$l([
8964
9194
  Property(0)
8965
9195
  ], Ribbon.prototype, "selectedTab", void 0);
8966
- __decorate([
9196
+ __decorate$l([
8967
9197
  Complex({}, TabAnimationSettings)
8968
9198
  ], Ribbon.prototype, "tabAnimation", void 0);
8969
- __decorate([
9199
+ __decorate$l([
8970
9200
  Collection([], RibbonTab)
8971
9201
  ], Ribbon.prototype, "tabs", void 0);
8972
- __decorate([
9202
+ __decorate$l([
8973
9203
  Collection([], RibbonContextualTabSettings)
8974
9204
  ], Ribbon.prototype, "contextualTabs", void 0);
8975
- __decorate([
9205
+ __decorate$l([
8976
9206
  Property('100%')
8977
9207
  ], Ribbon.prototype, "width", void 0);
8978
- __decorate([
9208
+ __decorate$l([
8979
9209
  Property('')
8980
9210
  ], Ribbon.prototype, "helpPaneTemplate", void 0);
8981
- __decorate([
9211
+ __decorate$l([
8982
9212
  Property(false)
8983
9213
  ], Ribbon.prototype, "hideLayoutSwitcher", void 0);
8984
- __decorate([
9214
+ __decorate$l([
8985
9215
  Event()
8986
9216
  ], Ribbon.prototype, "tabSelecting", void 0);
8987
- __decorate([
9217
+ __decorate$l([
8988
9218
  Event()
8989
9219
  ], Ribbon.prototype, "tabSelected", void 0);
8990
- __decorate([
9220
+ __decorate$l([
8991
9221
  Event()
8992
9222
  ], Ribbon.prototype, "ribbonExpanding", void 0);
8993
- __decorate([
9223
+ __decorate$l([
8994
9224
  Event()
8995
9225
  ], Ribbon.prototype, "ribbonCollapsing", void 0);
8996
- __decorate([
9226
+ __decorate$l([
8997
9227
  Event()
8998
9228
  ], Ribbon.prototype, "launcherIconClick", void 0);
8999
- __decorate([
9229
+ __decorate$l([
9000
9230
  Event()
9001
9231
  ], Ribbon.prototype, "created", void 0);
9002
- __decorate([
9232
+ __decorate$l([
9003
9233
  Event()
9004
9234
  ], Ribbon.prototype, "overflowPopupOpen", void 0);
9005
- __decorate([
9235
+ __decorate$l([
9006
9236
  Event()
9007
9237
  ], Ribbon.prototype, "overflowPopupClose", void 0);
9008
- Ribbon = Ribbon_1 = __decorate([
9238
+ Ribbon = Ribbon_1 = __decorate$l([
9009
9239
  NotifyPropertyChanges
9010
9240
  ], Ribbon);
9011
9241
 
9012
- /**
9013
- * Ribbon modules
9014
- */
9015
-
9016
9242
  /**
9017
9243
  * Defines the items of Ribbon.
9018
9244
  */
@@ -9351,9 +9577,9 @@ class RibbonBackstage extends Component {
9351
9577
  this.parent = parent;
9352
9578
  }
9353
9579
  /**
9354
- * @private
9355
- * @returns {void}
9356
- */
9580
+ * @private
9581
+ * @returns {void}
9582
+ */
9357
9583
  render() {
9358
9584
  // render code
9359
9585
  }
@@ -9454,6 +9680,8 @@ class RibbonBackstage extends Component {
9454
9680
  if (firstMenuEle) {
9455
9681
  firstMenuEle.classList.add('e-selected');
9456
9682
  firstMenuEle.focus();
9683
+ this.menuIndex = 0;
9684
+ this.isCloseBtn = false;
9457
9685
  }
9458
9686
  this.createBackStageContent(this.menuCtrl.items[0].id, item.content);
9459
9687
  break;
@@ -9517,7 +9745,8 @@ class RibbonBackstage extends Component {
9517
9745
  });
9518
9746
  let targetEle;
9519
9747
  if (backStageOptions.target) {
9520
- targetEle = backStageOptions.target instanceof HTMLElement ? backStageOptions.target : document.querySelector(backStageOptions.target);
9748
+ targetEle = backStageOptions.target instanceof HTMLElement ? backStageOptions.target :
9749
+ document.querySelector(backStageOptions.target);
9521
9750
  targetEle.appendChild(this.popupHTMLElement);
9522
9751
  }
9523
9752
  else {
@@ -9532,10 +9761,47 @@ class RibbonBackstage extends Component {
9532
9761
  if (this.parent.enableRtl) {
9533
9762
  this.updatePopupPositionOnRtl(this.parent.enableRtl);
9534
9763
  }
9535
- this.popupHTMLElement.onkeydown = (e) => { if (e.code === 'Escape') {
9536
- this.hideBackstage();
9537
- } };
9538
9764
  this.hideBackstage();
9765
+ EventHandler.add(this.popupHTMLElement, 'keyup', (e) => {
9766
+ if (e.code === 'Escape') {
9767
+ this.hideBackstage();
9768
+ }
9769
+ this.handleNavigation(e);
9770
+ }, this);
9771
+ }
9772
+ handleNavigation(e) {
9773
+ const closeBtnEle = this.popupHTMLElement.querySelector('.e-ribbon-close-btn');
9774
+ const menuItems = this.popupHTMLElement.querySelectorAll('.e-menu-item');
9775
+ const arrowUp = e.key === 'ArrowUp';
9776
+ const arrowDown = e.key === 'ArrowDown';
9777
+ if (arrowUp || arrowDown) {
9778
+ if ((arrowUp && this.menuIndex > 0) || (arrowDown && this.menuIndex < menuItems.length - 1 && !this.isCloseBtn)) {
9779
+ this.menuIndex = arrowUp ? this.menuIndex - 1 : this.menuIndex + 1;
9780
+ }
9781
+ else {
9782
+ if (closeBtnEle && !this.isCloseBtn) {
9783
+ closeBtnEle.focus();
9784
+ this.isCloseBtn = true;
9785
+ }
9786
+ else {
9787
+ this.menuIndex = arrowUp ? menuItems.length - 1 : 0;
9788
+ this.isCloseBtn = false;
9789
+ }
9790
+ }
9791
+ for (let i = 0; i < menuItems.length; i++) {
9792
+ menuItems[parseInt(i.toString(), 10)].classList.remove('e-focused');
9793
+ }
9794
+ if (!this.isCloseBtn) {
9795
+ if (arrowUp && menuItems[this.menuIndex].classList.contains('e-separator')) {
9796
+ this.menuIndex--;
9797
+ }
9798
+ else if (arrowDown && menuItems[this.menuIndex].classList.contains('e-separator')) {
9799
+ this.menuIndex++;
9800
+ }
9801
+ menuItems[this.menuIndex].classList.add('e-focused');
9802
+ menuItems[this.menuIndex].focus();
9803
+ }
9804
+ }
9539
9805
  }
9540
9806
  updatePopupPositionOnRtl(enableRtl) {
9541
9807
  const popupStyle = this.popupHTMLElement.style;
@@ -9689,11 +9955,13 @@ class RibbonBackstage extends Component {
9689
9955
  const item = menuOptions.items[parseInt(i.toString(), 10)];
9690
9956
  if (item.text === args.item.text) {
9691
9957
  this.contentItem = item;
9958
+ this.menuIndex = i;
9692
9959
  break;
9693
9960
  }
9694
9961
  }
9695
9962
  this.createBackStageContent(args.item.id, this.contentItem.content);
9696
- const eventArgs = { cancel: false, target: args.element, item: this.contentItem, isBackButton: this.isBackButtonClicked };
9963
+ const eventArgs = { cancel: false, target: args.element,
9964
+ item: this.contentItem, isBackButton: this.isBackButtonClicked };
9697
9965
  if (this.contentItem.backStageItemClick) {
9698
9966
  this.contentItem.backStageItemClick.call(this, eventArgs);
9699
9967
  }
@@ -9713,8 +9981,9 @@ class RibbonBackstage extends Component {
9713
9981
  this.backstageButton.setProperties(commonProp);
9714
9982
  if (this.popupEle) {
9715
9983
  this.popupEle.setProperties(commonProp);
9716
- if (this.popupHTMLElement)
9984
+ if (this.popupHTMLElement) {
9717
9985
  this.updatePopupPositionOnRtl(commonProp.enableRtl);
9986
+ }
9718
9987
  if (this.menuCtrl) {
9719
9988
  this.menuCtrl.setProperties(commonProp);
9720
9989
  if (this.closeBtn) {
@@ -9747,7 +10016,7 @@ class RibbonBackstage extends Component {
9747
10016
  this.popupEle.setProperties({
9748
10017
  height: backStageOptions.height,
9749
10018
  width: backStageOptions.width,
9750
- target: backStageOptions.target || this.parent.element,
10019
+ target: backStageOptions.target || this.parent.element
9751
10020
  });
9752
10021
  }
9753
10022
  if (backStageOptions.template) {
@@ -9854,10 +10123,20 @@ class RibbonBackstage extends Component {
9854
10123
  for (let i = 0; i < items.length; i++) {
9855
10124
  const item = items[parseInt(i.toString(), 10)];
9856
10125
  if (item.isFooter) {
9857
- isAfter ? this.footerMenuCtrl.insertAfter(items, target, isUniqueId) : this.footerMenuCtrl.insertBefore(items, target, isUniqueId);
10126
+ if (isAfter) {
10127
+ this.footerMenuCtrl.insertAfter(items, target, isUniqueId);
10128
+ }
10129
+ else {
10130
+ this.footerMenuCtrl.insertBefore(items, target, isUniqueId);
10131
+ }
9858
10132
  }
9859
10133
  else {
9860
- isAfter ? this.menuCtrl.insertAfter(items, target, isUniqueId) : this.menuCtrl.insertBefore(items, target, isUniqueId);
10134
+ if (isAfter) {
10135
+ this.menuCtrl.insertAfter(items, target, isUniqueId);
10136
+ }
10137
+ else {
10138
+ this.menuCtrl.insertBefore(items, target, isUniqueId);
10139
+ }
9861
10140
  }
9862
10141
  }
9863
10142
  const backstageItems = [].concat(this.menuCtrl.items, this.footerMenuCtrl.items);
@@ -9982,8 +10261,8 @@ class RibbonContextualTab {
9982
10261
  }
9983
10262
  }
9984
10263
  if (newProp.tabs) {
9985
- for (const key in newProp.tabs) {
9986
- let index = parseInt(key, 10);
10264
+ for (const key of Object.keys(newProp.tabs)) {
10265
+ const index = parseInt(key, 10);
9987
10266
  const tab = this.parent.tabs.filter((e) => e.id === contextualTab.tabs[parseInt(index.toString(), 10)].id)[0];
9988
10267
  this.parent.updateTab(tab);
9989
10268
  }
@@ -10018,8 +10297,7 @@ class RibbonKeyTip {
10018
10297
  if (key === 'tab') {
10019
10298
  for (let i = 0; i < this.parent.tabs.length; i++) {
10020
10299
  if (this.parent.keyTipElements[parseInt(i.toString(), 10)]) {
10021
- // eslint-disable-next-line
10022
- keytipData = this.parent.keyTipElements[i][key];
10300
+ keytipData = this.parent.keyTipElements[parseInt(i.toString(), 10)][`${key}`];
10023
10301
  this.createKeyTipElement((keytipData[0].id), keytipData[0].keyTip, 'tab', 'center', 'bottom', true);
10024
10302
  }
10025
10303
  }
@@ -10101,15 +10379,12 @@ class RibbonKeyTip {
10101
10379
  calculateItemPosition(key, isMethod = false, keyTip) {
10102
10380
  let xOffset;
10103
10381
  let yOffset;
10104
- let keytipData;
10105
- /* eslint-disable */
10106
- keytipData = this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)][key];
10382
+ const keytipData = this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)][`${key}`];
10107
10383
  if (keytipData) {
10108
- for (let i = 0; i < Object.keys(this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)][key]).length; i++) {
10109
- /* eslint-enable */
10384
+ for (let i = 0; i < Object.keys(this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)][`${key}`]).length; i++) {
10110
10385
  if ((isMethod && (keytipData[parseInt(i.toString(), 10)].keyTip === keyTip)) || !isMethod) {
10111
10386
  let itemID = keytipData[parseInt(i.toString(), 10)].id;
10112
- if (keytipData[parseInt(i.toString(), 10)].id.includes("_grpbtn")) {
10387
+ if (keytipData[parseInt(i.toString(), 10)].id.indexOf('_grpbtn') !== -1) {
10113
10388
  itemID = keytipData[parseInt(i.toString(), 10)].id.replace(/_grpbtn\d+/, '');
10114
10389
  }
10115
10390
  const itemProp = getItem(this.parent.tabs, itemID);
@@ -10137,7 +10412,12 @@ class RibbonKeyTip {
10137
10412
  yOffset = 'bottom';
10138
10413
  }
10139
10414
  }
10140
- key === 'item' ? this.createKeyTipElement((keytipData[parseInt(i.toString(), 10)].id), keytipData[parseInt(i.toString(), 10)].keyTip, key, xOffset, yOffset) : this.createKeyTipElement((keytipData[parseInt(i.toString(), 10)].id), keytipData[parseInt(i.toString(), 10)].keyTip, key, xOffset, yOffset, false, true);
10415
+ if (key === 'item') {
10416
+ this.createKeyTipElement((keytipData[parseInt(i.toString(), 10)].id), keytipData[parseInt(i.toString(), 10)].keyTip, key, xOffset, yOffset);
10417
+ }
10418
+ else {
10419
+ this.createKeyTipElement((keytipData[parseInt(i.toString(), 10)].id), keytipData[parseInt(i.toString(), 10)].keyTip, key, xOffset, yOffset, false, true);
10420
+ }
10141
10421
  }
10142
10422
  }
10143
10423
  }
@@ -10157,7 +10437,7 @@ class RibbonKeyTip {
10157
10437
  isPopUpPresent = true;
10158
10438
  }
10159
10439
  if (keyEle.closest('.e-split-btn-wrapper')) {
10160
- let splitBtn = keyEle.closest('.e-split-btn-wrapper');
10440
+ const splitBtn = keyEle.closest('.e-split-btn-wrapper');
10161
10441
  splitBtnID = splitBtn.closest('.e-ribbon-item').id;
10162
10442
  }
10163
10443
  else {
@@ -10183,12 +10463,12 @@ class RibbonKeyTip {
10183
10463
  enableRtl: this.parent.enableRtl
10184
10464
  });
10185
10465
  keytipPopup.show();
10186
- this.calculateKeyTipPosition(keyEle, keytipElement, type, yOffset, (isTab && isPopUpItem));
10466
+ this.calculateKeyTipPosition(keyEle, keytipElement, type, yOffset);
10187
10467
  this.parent.isKeytipOpen = true;
10188
10468
  }
10189
10469
  }
10190
10470
  }
10191
- calculateKeyTipPosition(itemEle, keytipElement, type, yOffset, isTabOverflow = false) {
10471
+ calculateKeyTipPosition(itemEle, keytipElement, type, yOffset) {
10192
10472
  const position = itemEle.getBoundingClientRect();
10193
10473
  if (type === 'backstageMenu') {
10194
10474
  keytipElement.style.top = position.top + ((keytipElement.offsetHeight) / 2) + 'px';
@@ -10210,6 +10490,7 @@ class RibbonKeyTip {
10210
10490
  * Performs keytip action.
10211
10491
  *
10212
10492
  * @param {string} keyPress - Gets the keytip text.
10493
+ * @param {boolean} isMethod - Gets the isMethod.
10213
10494
  * @returns {void}
10214
10495
  * @hidden
10215
10496
  */
@@ -10217,9 +10498,11 @@ class RibbonKeyTip {
10217
10498
  this.isKeytipPresent = false;
10218
10499
  for (let i = 0; ((i < Object.keys(this.parent.keyTipElements).length) && !this.isKeytipPresent); i++) {
10219
10500
  if (this.parent.keyTipElements[parseInt(i.toString(), 10)]) {
10220
- for (let j = 0; ((j < Object.keys(this.parent.keyTipElements[parseInt(i.toString(), 10)]).length) && !this.isKeytipPresent); j++) {
10221
- let keytipData = this.parent.keyTipElements[parseInt(i.toString(), 10)][Object.keys(this.parent.keyTipElements[parseInt(i.toString(), 10)])[parseInt(j.toString(), 10)]];
10222
- for (let k = 0; ((k < keytipData.length) && !this.isKeytipPresent); k++) {
10501
+ for (let j = 0; ((j < Object.keys(this.parent.keyTipElements[parseInt(i.toString(), 10)]).length) &&
10502
+ !this.isKeytipPresent); j++) {
10503
+ const keytipData = this.parent.keyTipElements[parseInt(i.toString(), 10)][Object.
10504
+ keys(this.parent.keyTipElements[parseInt(i.toString(), 10)])[parseInt(j.toString(), 10)]];
10505
+ for (let k = 0; ((k < Object.keys(keytipData).length) && !this.isKeytipPresent); k++) {
10223
10506
  if (keyPress.toUpperCase() === keytipData[parseInt(k.toString(), 10)].keyTip) {
10224
10507
  const keyTipElement = document.querySelector('#' + keytipData[parseInt(k.toString(), 10)].id + RIBBON_KEYTIP_ID);
10225
10508
  if (keyTipElement || isMethod) {
@@ -10230,8 +10513,9 @@ class RibbonKeyTip {
10230
10513
  this.parent.tabObj.select(i);
10231
10514
  setTimeout(() => {
10232
10515
  const tabOverflow = this.parent.tabObj.element.querySelector('.e-nav-active');
10233
- if (tabOverflow)
10516
+ if (tabOverflow) {
10234
10517
  tabOverflow.click();
10518
+ }
10235
10519
  this.createKeytip('item');
10236
10520
  }, 600);
10237
10521
  }
@@ -10246,7 +10530,7 @@ class RibbonKeyTip {
10246
10530
  }
10247
10531
  else {
10248
10532
  let itemProp;
10249
- if ((keytipData[parseInt(k.toString(), 10)].id).includes("_popupButton")) {
10533
+ if ((keytipData[parseInt(k.toString(), 10)].id).indexOf('_popupButton') !== -1) {
10250
10534
  const galleryID = keytipData[parseInt(k.toString(), 10)].id.replace(/_popupButton/g, '');
10251
10535
  itemProp = getItem(this.parent.tabs, galleryID);
10252
10536
  }
@@ -10264,7 +10548,7 @@ class RibbonKeyTip {
10264
10548
  if (keyEle) {
10265
10549
  let groupID = keytipData[parseInt(k.toString(), 10)].id;
10266
10550
  if (isMethod) {
10267
- if (keytipData[parseInt(k.toString(), 10)].id.includes("_launcher") || keytipData[parseInt(k.toString(), 10)].id.includes("_sim_grp_overflow") || keytipData[parseInt(k.toString(), 10)].id.includes("_overflow_dropdown")) {
10551
+ if (keytipData[parseInt(k.toString(), 10)].id.indexOf('_launcher') !== -1 || keytipData[parseInt(k.toString(), 10)].id.indexOf('_sim_grp_overflow') !== -1 || keytipData[parseInt(k.toString(), 10)].id.indexOf('_overflow_dropdown') !== -1) {
10268
10552
  groupID = keytipData[parseInt(k.toString(), 10)].id.replace(/_launcher|_sim_grp_overflow|_overflow_dropdown/g, '');
10269
10553
  const itemProp = getGroup(this.parent.tabs, groupID);
10270
10554
  if (itemProp.tabIndex === this.parent.selectedTab) {
@@ -10295,11 +10579,16 @@ class RibbonKeyTip {
10295
10579
  keyEle.click();
10296
10580
  if (!(keytipData[parseInt(k.toString(), 10)].type === 'launcher')) {
10297
10581
  this.isKeytipPopupOpen = true;
10298
- keytipData[parseInt(k.toString(), 10)].type === 'grpoverflow' ? this.createKeytip('grpoverflowpopup') : this.createKeytip('popupitem');
10582
+ if (keytipData[parseInt(k.toString(), 10)].type === 'grpoverflow') {
10583
+ this.createKeytip('grpoverflowpopup');
10584
+ }
10585
+ else {
10586
+ this.createKeytip('popupitem');
10587
+ }
10299
10588
  }
10300
10589
  }
10301
10590
  else {
10302
- let itemID = keytipData[parseInt(k.toString(), 10)].id;
10591
+ const itemID = keytipData[parseInt(k.toString(), 10)].id;
10303
10592
  if (document.querySelector('#' + itemID) && isMethod) {
10304
10593
  if (this.parent.activeLayout === 'Simplified') {
10305
10594
  if (document.querySelector('#' + itemID).closest('#' + itemProp.group.id + '_sim_grp_overflow-popup') && document.querySelector('#' + itemID).closest('#' + itemProp.group.id + '_sim_grp_overflow-popup').classList.contains('e-popup-close')) {
@@ -10332,21 +10621,24 @@ class RibbonKeyTip {
10332
10621
  case 'colorpicker':
10333
10622
  this.parent.ribbonColorPickerModule.toggle(itemID);
10334
10623
  break;
10335
- case 'combobox':
10624
+ case 'combobox': {
10336
10625
  const itemEle = document.querySelector('#' + itemID);
10337
10626
  setTimeout(() => {
10338
10627
  itemEle.focus();
10339
10628
  }, 100);
10340
10629
  break;
10341
- case 'gallery':
10630
+ }
10631
+ case 'gallery': {
10342
10632
  const galleryEle = document.querySelector('#' + itemID);
10343
10633
  galleryEle.click();
10344
10634
  break;
10345
- case 'template':
10635
+ }
10636
+ case 'template': {
10346
10637
  const templateEle = document.querySelector('#' + itemID);
10347
10638
  templateEle.focus();
10348
10639
  break;
10349
- case 'group-btn':
10640
+ }
10641
+ case 'group-btn': {
10350
10642
  const itemElement = document.querySelector('#' + itemID);
10351
10643
  if (itemElement) {
10352
10644
  const item = getInstance(itemElement, DropDownButton);
@@ -10358,20 +10650,19 @@ class RibbonKeyTip {
10358
10650
  }
10359
10651
  }
10360
10652
  break;
10653
+ }
10361
10654
  }
10362
10655
  }
10363
10656
  }
10364
10657
  commonItemsKeyTipPress(keyPress, key, isMethod) {
10365
- /* eslint-disable */
10366
- if (this.parent.keyTipElements[key]) {
10658
+ if (this.parent.keyTipElements[`${key}`]) {
10367
10659
  let isKeyPressed = false;
10368
- let keytipData = this.parent.keyTipElements[key];
10660
+ const keytipData = this.parent.keyTipElements[`${key}`];
10369
10661
  let keyEle;
10370
10662
  let keytipElement;
10371
10663
  if (keytipData) {
10372
10664
  if (key === 'backstageMenu') {
10373
- for (let i = 0; i < Object.keys(this.parent.keyTipElements[key]).length; i++) {
10374
- /* eslint-enable */
10665
+ for (let i = 0; i < Object.keys(this.parent.keyTipElements[`${key}`]).length; i++) {
10375
10666
  if (keytipData[parseInt(i.toString(), 10)].keyTip === keyPress.toUpperCase()) {
10376
10667
  keyEle = document.querySelector('#' + keytipData[parseInt(i.toString(), 10)].id);
10377
10668
  keytipElement = document.querySelector('#' + keyEle.id + RIBBON_KEYTIP_ID);
@@ -10411,7 +10702,7 @@ class RibbonKeyTip {
10411
10702
  setTimeout(() => {
10412
10703
  for (let i = 0; i < Object.keys(this.parent.keyTipElements).length; i++) {
10413
10704
  if (this.parent.keyTipElements[parseInt(i.toString(), 10)]) {
10414
- let keytipData = this.parent.keyTipElements[parseInt(i.toString(), 10)]['tab'];
10705
+ const keytipData = this.parent.keyTipElements[parseInt(i.toString(), 10)]['tab'];
10415
10706
  this.createKeyTipElement((keytipData[0].id), keytipData[0].keyTip, 'tab', 'center', 'bottom', true, true);
10416
10707
  }
10417
10708
  }
@@ -10435,34 +10726,34 @@ class RibbonKeyTip {
10435
10726
  for (let i = 0; i < keyTipItems.length; i++) {
10436
10727
  const keyTipItem = keyTipItems[parseInt(i.toString(), 10)];
10437
10728
  if (key === 'Escape' && this.parent.keyTipElements && this.parent.keyTipElements[this.parent.selectedTab]) {
10438
- /* eslint-disable */
10439
10729
  for (let j = 0; j < Object.keys(this.parent.keyTipElements[this.parent.selectedTab]).length; j++) {
10440
- let keyText = (Object.keys(this.parent.keyTipElements[this.parent.selectedTab]))[j];
10441
- if (this.parent.keyTipElements[this.parent.selectedTab][keyText]) {
10442
- const index = getIndex(this.parent.keyTipElements[this.parent.selectedTab][keyText], (e) => { return e.id + RIBBON_KEYTIP_ID === keyTipItems[parseInt(i.toString(), 10)].id; });
10443
- /* eslint-enable */
10444
- if (index !== -1) {
10445
- if ((keyText === 'item' && !(this.isKeytipPopupOpen)) || (keyText === 'grpoverflow' && this.parent.activeLayout === 'Classic')) {
10446
- this.createKeytip('tab');
10730
+ const keyText = (Object.keys(this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)]))[parseInt(j.toString(), 10)];
10731
+ const keyTipElement = this.parent.keyTipElements[parseInt(this.parent.selectedTab.toString(), 10)];
10732
+ const index = getIndex(keyTipElement[`${keyText}`], (e) => {
10733
+ return e.id +
10734
+ RIBBON_KEYTIP_ID === keyTipItems[parseInt(i.toString(), 10)].id;
10735
+ });
10736
+ if (index !== -1) {
10737
+ if ((keyText === 'item' && !(this.isKeytipPopupOpen)) || (keyText === 'grpoverflow' && this.parent.activeLayout === 'Classic')) {
10738
+ this.createKeytip('tab');
10739
+ key = '';
10740
+ isKeyTipExist = true;
10741
+ break;
10742
+ }
10743
+ else if (this.isKeytipPopupOpen) {
10744
+ if ((keyText === 'popupitem' && this.parent.activeLayout === 'Simplified') || (keyText === 'grpoverflowpopup' && this.parent.activeLayout === 'Classic')) {
10745
+ this.createKeytip('item');
10447
10746
  key = '';
10448
10747
  isKeyTipExist = true;
10449
10748
  break;
10450
10749
  }
10451
- else if (this.isKeytipPopupOpen) {
10452
- if ((keyText === 'popupitem' && this.parent.activeLayout === 'Simplified') || (keyText === 'grpoverflowpopup' && this.parent.activeLayout === 'Classic')) {
10453
- this.createKeytip('item');
10454
- key = '';
10455
- isKeyTipExist = true;
10456
- break;
10457
- }
10458
- }
10459
10750
  }
10460
10751
  }
10461
10752
  }
10462
10753
  for (let n = 0; n < Object.keys(this.parent.keyTipElements).length; n++) {
10463
10754
  if (this.parent.keyTipElements[parseInt(n.toString(), 10)]) {
10464
- let keytipData = this.parent.keyTipElements[parseInt(n.toString(), 10)]['tab'];
10465
- for (let j = 0; j < keytipData.length; j++) {
10755
+ const keytipData = this.parent.keyTipElements[parseInt(n.toString(), 10)]['tab'];
10756
+ for (let j = 0; j < Object.keys(keytipData).length; j++) {
10466
10757
  if (keyTipItem.id === keytipData[0].id + RIBBON_KEYTIP_ID) {
10467
10758
  if (document.querySelector('#' + keytipData[0].id + HEADER_ID).closest('.e-toolbar-pop')) {
10468
10759
  const tabOverflow = this.parent.tabObj.element.querySelector('.e-nav-active');
@@ -10495,8 +10786,9 @@ class RibbonKeyTip {
10495
10786
  }
10496
10787
  }
10497
10788
  this.isKeytipPopupOpen = false;
10498
- if (!isKeyTipExist)
10789
+ if (!isKeyTipExist) {
10499
10790
  this.parent.isKeytipOpen = false;
10791
+ }
10500
10792
  }
10501
10793
  /**
10502
10794
  * Shows the Keytip dynamically.
@@ -10524,12 +10816,5 @@ class RibbonKeyTip {
10524
10816
  }
10525
10817
  }
10526
10818
 
10527
- /**
10528
- * Ribbon modules
10529
- */
10530
-
10531
- // export all modules from current location
10532
- // example: export * from './module'
10533
-
10534
- export { Ribbon, RibbonLayout, ItemOrientation, RibbonItemSize, DisplayMode, RibbonItemType, RibbonGroupButtonSelection, ITEM_VERTICAL_CENTER, EXPAND_COLLAPSE_ICON, BACKSTAGE_CLOSE_ICON, OVERFLOW_ICON, VERTICAL_DDB, DISABLED_CSS, RTL_CSS, RIBBON_HOVER, RIBBON_CONTROL, RIBBON_POPUP_CONTROL, RIBBON_POPUP_OPEN, RIBBON_KEYTIP, SPACE, HORIZONTAL_SCROLLBAR, HIDE_CSS, RIBBON_TAB, RIBBON_CONTEXTUAL_TAB, RIBBON_TAB_ACTIVE, RIBBON_TAB_ITEM, RIBBON_COLLAPSE_BUTTON, RIBBON_EXPAND_BUTTON, RIBBON_COLLAPSIBLE, RIBBON_OVERALL_OF_BUTTON, RIBBON_GROUP_OF_BUTTON, RIBBON_OVERFLOW_TARGET, RIBBON_OVERFLOW, TAB_CONTENT, RIBBON_MINIMIZE, RIBBON_GROUP, RIBBON_SINGLE_BUTTON_SELECTION, RIBBON_MULTIPLE_BUTTON_SELECTION, RIBBON_GROUP_BUTTON, RIBBON_GROUP_BUTTON_OVERFLOW_POPUP, RIBBON_GROUP_BUTTON_CONTENT, RIBBON_GROUP_CONTAINER, RIBBON_OF_TAB_CONTAINER, RIBBON_OF_GROUP_CONTAINER, RIBBON_GROUP_CONTENT, RIBBON_GROUP_HEADER, RIBBON_OVERFLOW_HEADER, RIBBON_GROUP_OVERFLOW, RIBBON_GROUP_OVERFLOW_DDB, RIBBON_LAUNCHER, RIBBON_LAUNCHER_ICON_ELE, RIBBON_LAUNCHER_ICON, RIBBON_COLLECTION, RIBBON_ITEM, RIBBON_ROW, RIBBON_COLUMN, RIBBON_LARGE_ITEM, RIBBON_MEDIUM_ITEM, RIBBON_SMALL_ITEM, RIBBON_CONTENT_HEIGHT, DROPDOWNBUTTON, DROPDOWNBUTTON_HIDE, RIBBON_TEMPLATE, RIBBON_HELP_TEMPLATE, RIBBON_TOOLTIP, RIBBON_TOOLTIP_TARGET, RIBBON_TOOLTIP_TITLE, RIBBON_TOOLTIP_CONTENT, RIBBON_TOOLTIP_ICON, RIBBON_TOOLTIP_CONTAINER, RIBBON_TEXT_CONTAINER, RIBBON_SIMPLIFIED_MODE, RIBBON_BACKSTAGE_POPUP, RIBBON_BACKSTAGE_OPEN, RIBBON_BACKSTAGE_CONTENT, RIBBON_SELECTED_CONTENT, RIBBON_BACKSTAGE, RIBBON_BACKSTAGE_MENU, RIBBON_BACKSTAGE_TEMPLATE, RIBBON_BACKSTAGE_MENU_WRAPPER, RIBBON_BACKSTAGE_ITEMS_WRAPPER, RIBBON_BACKSTAGE_TEXT_MENU, TAB_ID, GROUP_ID, COLLECTION_ID, ITEM_ID, COLLAPSE_BUTTON_ID, OVRLOF_BUTTON_ID, GROUPOF_BUTTON_ID, HEADER_ID, LAUNCHER_ID, CONTENT_ID, CONTAINER_ID, OVERFLOW_ID, DROPDOWN_ID, RIBBON_FILE_MENU_ID, RIBBON_BACKSTAGE_MENU_ID, RIBBON_BACKSTAGE_POPUP_ID, RIBBON_FILE_MENU_LIST, RIBBON_MENU_LIST, RIBBON_FOOTER_MENU_LIST, RIBBON_HELP_PANE_TEMPLATE_ID, RIBBON_GROUP_BUTTON_ID, RIBBON_KEYTIP_ID, RIBBON_FILE_MENU_WIDTH, RIBBON_HELP_PANE_TEMPLATE_WIDTH, getIndex, getTemplateFunction, getItem, getCollection, getGroup, destroyControl, updateCommonProperty, updateControlDisabled, getItemElement, isTooltipPresent, setToolTipContent, createTooltip, destroyTooltip, updateTooltipProp, setCustomAttributes, RibbonTab, RibbonGroup, RibbonCollection, RibbonItem, RibbonButtonSettings, RibbonCheckBoxSettings, RibbonColorPickerSettings, RibbonComboBoxSettings, RibbonDropDownSettings, RibbonSplitButtonSettings, FileMenuSettings, BackStageMenu, BackstageBackButton, BackstageItem, RibbonTooltip, RibbonGroupButtonSettings, RibbonGroupButtonItem, RibbonContextualTabSettings, RibbonGalleryGroup, RibbonGalleryItem, RibbonGallerySettings, RibbonButton, RibbonCheckBox, RibbonColorPicker, RibbonComboBox, RibbonDropDown, RibbonSplitButton, RibbonGroupButton, RibbonGallery, RibbonFileMenu, RibbonBackstage, RibbonContextualTab, RibbonKeyTip };
10819
+ export { BACKSTAGE_CLOSE_ICON, BackStageMenu, BackstageBackButton, BackstageItem, COLLAPSE_BUTTON_ID, COLLECTION_ID, CONTAINER_ID, CONTENT_ID, DISABLED_CSS, DROPDOWNBUTTON, DROPDOWNBUTTON_HIDE, DROPDOWN_ID, DisplayMode, EXPAND_COLLAPSE_ICON, FileMenuSettings, GROUPOF_BUTTON_ID, GROUP_ID, HEADER_ID, HIDE_CSS, HORIZONTAL_SCROLLBAR, ITEM_ID, ITEM_VERTICAL_CENTER, ItemOrientation, LAUNCHER_ID, OVERFLOW_ICON, OVERFLOW_ID, OVRLOF_BUTTON_ID, RIBBON_BACKSTAGE, RIBBON_BACKSTAGE_CONTENT, RIBBON_BACKSTAGE_ITEMS_WRAPPER, RIBBON_BACKSTAGE_MENU, RIBBON_BACKSTAGE_MENU_ID, RIBBON_BACKSTAGE_MENU_WRAPPER, RIBBON_BACKSTAGE_OPEN, RIBBON_BACKSTAGE_POPUP, RIBBON_BACKSTAGE_POPUP_ID, RIBBON_BACKSTAGE_TEMPLATE, RIBBON_BACKSTAGE_TEXT_MENU, RIBBON_COLLAPSE_BUTTON, RIBBON_COLLAPSIBLE, RIBBON_COLLECTION, RIBBON_COLUMN, RIBBON_CONTENT_HEIGHT, RIBBON_CONTEXTUAL_TAB, RIBBON_CONTROL, RIBBON_EXPAND_BUTTON, RIBBON_FILE_MENU_ID, RIBBON_FILE_MENU_LIST, RIBBON_FILE_MENU_WIDTH, RIBBON_FOOTER_MENU_LIST, RIBBON_GROUP, RIBBON_GROUP_BUTTON, RIBBON_GROUP_BUTTON_CONTENT, RIBBON_GROUP_BUTTON_ID, RIBBON_GROUP_BUTTON_OVERFLOW_POPUP, RIBBON_GROUP_CONTAINER, RIBBON_GROUP_CONTENT, RIBBON_GROUP_HEADER, RIBBON_GROUP_OF_BUTTON, RIBBON_GROUP_OVERFLOW, RIBBON_GROUP_OVERFLOW_DDB, RIBBON_HELP_PANE_TEMPLATE_ID, RIBBON_HELP_PANE_TEMPLATE_WIDTH, RIBBON_HELP_TEMPLATE, RIBBON_HOVER, RIBBON_ITEM, RIBBON_KEYTIP, RIBBON_KEYTIP_ID, RIBBON_LARGE_ITEM, RIBBON_LAUNCHER, RIBBON_LAUNCHER_ICON, RIBBON_LAUNCHER_ICON_ELE, RIBBON_MEDIUM_ITEM, RIBBON_MENU_LIST, RIBBON_MINIMIZE, RIBBON_MULTIPLE_BUTTON_SELECTION, RIBBON_OF_GROUP_CONTAINER, RIBBON_OF_TAB_CONTAINER, RIBBON_OVERALL_OF_BUTTON, RIBBON_OVERFLOW, RIBBON_OVERFLOW_HEADER, RIBBON_OVERFLOW_TARGET, RIBBON_POPUP_CONTROL, RIBBON_POPUP_OPEN, RIBBON_ROW, RIBBON_SELECTED_CONTENT, RIBBON_SIMPLIFIED_MODE, RIBBON_SINGLE_BUTTON_SELECTION, RIBBON_SMALL_ITEM, RIBBON_TAB, RIBBON_TAB_ACTIVE, RIBBON_TAB_ITEM, RIBBON_TEMPLATE, RIBBON_TEXT_CONTAINER, RIBBON_TOOLTIP, RIBBON_TOOLTIP_CONTAINER, RIBBON_TOOLTIP_CONTENT, RIBBON_TOOLTIP_ICON, RIBBON_TOOLTIP_TARGET, RIBBON_TOOLTIP_TITLE, RTL_CSS, Ribbon, RibbonBackstage, RibbonButton, RibbonButtonSettings, RibbonCheckBox, RibbonCheckBoxSettings, RibbonCollection, RibbonColorPicker, RibbonColorPickerSettings, RibbonComboBox, RibbonComboBoxSettings, RibbonContextualTab, RibbonContextualTabSettings, RibbonDropDown, RibbonDropDownSettings, RibbonFileMenu, RibbonGallery, RibbonGalleryGroup, RibbonGalleryItem, RibbonGallerySettings, RibbonGroup, RibbonGroupButton, RibbonGroupButtonItem, RibbonGroupButtonSelection, RibbonGroupButtonSettings, RibbonItem, RibbonItemSize, RibbonItemType, RibbonKeyTip, RibbonLayout, RibbonSplitButton, RibbonSplitButtonSettings, RibbonTab, RibbonTooltip, SPACE, TAB_CONTENT, TAB_ID, VERTICAL_DDB, createTooltip, destroyControl, destroyTooltip, getCollection, getGroup, getIndex, getItem, getItemElement, getTemplateFunction, isTooltipPresent, setCustomAttributes, setToolTipContent, updateCommonProperty, updateControlDisabled, updateTooltipProp };
10535
10820
  //# sourceMappingURL=ej2-ribbon.es2015.js.map