@syncfusion/ej2-ribbon 21.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 (188) hide show
  1. package/.eslintrc.json +259 -0
  2. package/.github/PULL_REQUEST_TEMPLATE/Bug.md +60 -0
  3. package/.github/PULL_REQUEST_TEMPLATE/feature.md +37 -0
  4. package/CHANGELOG.md +19 -0
  5. package/README.md +3 -0
  6. package/dist/ej2-ribbon.umd.min.js +11 -0
  7. package/dist/ej2-ribbon.umd.min.js.map +1 -0
  8. package/dist/es6/ej2-ribbon.es2015.js +4946 -0
  9. package/dist/es6/ej2-ribbon.es2015.js.map +1 -0
  10. package/dist/es6/ej2-ribbon.es5.js +5253 -0
  11. package/dist/es6/ej2-ribbon.es5.js.map +1 -0
  12. package/dist/global/ej2-ribbon.min.js +11 -0
  13. package/dist/global/ej2-ribbon.min.js.map +1 -0
  14. package/dist/global/index.d.ts +14 -0
  15. package/index.d.ts +4 -0
  16. package/index.js +4 -0
  17. package/license +10 -0
  18. package/package.json +67 -0
  19. package/ribbon.d.ts +4 -0
  20. package/ribbon.js +4 -0
  21. package/src/global.js +3 -0
  22. package/src/index.d.ts +1 -0
  23. package/src/index.js +3 -0
  24. package/src/ribbon/base/constant.d.ts +151 -0
  25. package/src/ribbon/base/constant.js +151 -0
  26. package/src/ribbon/base/index.d.ts +8 -0
  27. package/src/ribbon/base/index.js +7 -0
  28. package/src/ribbon/base/interface.d.ts +194 -0
  29. package/src/ribbon/base/interface.js +106 -0
  30. package/src/ribbon/base/ribbon-model.d.ts +129 -0
  31. package/src/ribbon/base/ribbon.d.ts +357 -0
  32. package/src/ribbon/base/ribbon.js +2413 -0
  33. package/src/ribbon/base/utils.d.ts +113 -0
  34. package/src/ribbon/base/utils.js +288 -0
  35. package/src/ribbon/index.d.ts +7 -0
  36. package/src/ribbon/index.js +7 -0
  37. package/src/ribbon/items/index.d.ts +6 -0
  38. package/src/ribbon/items/index.js +6 -0
  39. package/src/ribbon/items/ribbon-button.d.ts +65 -0
  40. package/src/ribbon/items/ribbon-button.js +153 -0
  41. package/src/ribbon/items/ribbon-checkbox.d.ts +56 -0
  42. package/src/ribbon/items/ribbon-checkbox.js +134 -0
  43. package/src/ribbon/items/ribbon-colorpicker.d.ts +66 -0
  44. package/src/ribbon/items/ribbon-colorpicker.js +163 -0
  45. package/src/ribbon/items/ribbon-combobox.d.ts +78 -0
  46. package/src/ribbon/items/ribbon-combobox.js +185 -0
  47. package/src/ribbon/items/ribbon-dropdown.d.ts +123 -0
  48. package/src/ribbon/items/ribbon-dropdown.js +268 -0
  49. package/src/ribbon/items/ribbon-splitbutton.d.ts +86 -0
  50. package/src/ribbon/items/ribbon-splitbutton.js +227 -0
  51. package/src/ribbon/models/index.d.ts +24 -0
  52. package/src/ribbon/models/index.js +13 -0
  53. package/src/ribbon/models/ribbon-button-settings-model.d.ts +57 -0
  54. package/src/ribbon/models/ribbon-button-settings.d.ts +55 -0
  55. package/src/ribbon/models/ribbon-button-settings.js +61 -0
  56. package/src/ribbon/models/ribbon-checkbox-settings-model.d.ts +50 -0
  57. package/src/ribbon/models/ribbon-checkbox-settings.d.ts +50 -0
  58. package/src/ribbon/models/ribbon-checkbox-settings.js +58 -0
  59. package/src/ribbon/models/ribbon-collection-model.d.ts +30 -0
  60. package/src/ribbon/models/ribbon-collection.d.ts +33 -0
  61. package/src/ribbon/models/ribbon-collection.js +50 -0
  62. package/src/ribbon/models/ribbon-colorpicker-settings-model.d.ts +123 -0
  63. package/src/ribbon/models/ribbon-colorpicker-settings.d.ts +115 -0
  64. package/src/ribbon/models/ribbon-colorpicker-settings.js +88 -0
  65. package/src/ribbon/models/ribbon-combobox-settings-model.d.ts +241 -0
  66. package/src/ribbon/models/ribbon-combobox-settings.d.ts +223 -0
  67. package/src/ribbon/models/ribbon-combobox-settings.js +122 -0
  68. package/src/ribbon/models/ribbon-dropdown-settings-model.d.ts +100 -0
  69. package/src/ribbon/models/ribbon-dropdown-settings.d.ts +93 -0
  70. package/src/ribbon/models/ribbon-dropdown-settings.js +80 -0
  71. package/src/ribbon/models/ribbon-file-menu-settings-model.d.ts +108 -0
  72. package/src/ribbon/models/ribbon-file-menu-settings.d.ts +159 -0
  73. package/src/ribbon/models/ribbon-file-menu-settings.js +84 -0
  74. package/src/ribbon/models/ribbon-group-model.d.ts +91 -0
  75. package/src/ribbon/models/ribbon-group.d.ts +87 -0
  76. package/src/ribbon/models/ribbon-group.js +74 -0
  77. package/src/ribbon/models/ribbon-item-model.d.ts +120 -0
  78. package/src/ribbon/models/ribbon-item.d.ts +118 -0
  79. package/src/ribbon/models/ribbon-item.js +93 -0
  80. package/src/ribbon/models/ribbon-splitbutton-settings-model.d.ts +107 -0
  81. package/src/ribbon/models/ribbon-splitbutton-settings.d.ts +99 -0
  82. package/src/ribbon/models/ribbon-splitbutton-settings.js +83 -0
  83. package/src/ribbon/models/ribbon-tab-model.d.ts +37 -0
  84. package/src/ribbon/models/ribbon-tab.d.ts +39 -0
  85. package/src/ribbon/models/ribbon-tab.js +53 -0
  86. package/src/ribbon/models/ribbon-tooltip-model.d.ts +43 -0
  87. package/src/ribbon/models/ribbon-tooltip.d.ts +36 -0
  88. package/src/ribbon/models/ribbon-tooltip.js +46 -0
  89. package/src/ribbon/modules/index.d.ts +1 -0
  90. package/src/ribbon/modules/index.js +1 -0
  91. package/src/ribbon/modules/ribbon-filemenu.d.ts +94 -0
  92. package/src/ribbon/modules/ribbon-filemenu.js +318 -0
  93. package/styles/bootstrap-dark.css +1502 -0
  94. package/styles/bootstrap-dark.scss +1 -0
  95. package/styles/bootstrap.css +1507 -0
  96. package/styles/bootstrap.scss +1 -0
  97. package/styles/bootstrap4.css +1557 -0
  98. package/styles/bootstrap4.scss +1 -0
  99. package/styles/bootstrap5-dark.css +1586 -0
  100. package/styles/bootstrap5-dark.scss +1 -0
  101. package/styles/bootstrap5.css +1586 -0
  102. package/styles/bootstrap5.scss +1 -0
  103. package/styles/fabric-dark.css +1478 -0
  104. package/styles/fabric-dark.scss +1 -0
  105. package/styles/fabric.css +1476 -0
  106. package/styles/fabric.scss +1 -0
  107. package/styles/fluent-dark.css +1562 -0
  108. package/styles/fluent-dark.scss +1 -0
  109. package/styles/fluent.css +1562 -0
  110. package/styles/fluent.scss +1 -0
  111. package/styles/highcontrast-light.css +1485 -0
  112. package/styles/highcontrast-light.scss +1 -0
  113. package/styles/highcontrast.css +1494 -0
  114. package/styles/highcontrast.scss +1 -0
  115. package/styles/material-dark.css +1548 -0
  116. package/styles/material-dark.scss +1 -0
  117. package/styles/material.css +1581 -0
  118. package/styles/material.scss +1 -0
  119. package/styles/ribbon/_all.scss +2 -0
  120. package/styles/ribbon/_bootstrap-dark-definition.scss +206 -0
  121. package/styles/ribbon/_bootstrap-definition.scss +206 -0
  122. package/styles/ribbon/_bootstrap4-definition.scss +206 -0
  123. package/styles/ribbon/_bootstrap5-dark-definition.scss +1 -0
  124. package/styles/ribbon/_bootstrap5-definition.scss +206 -0
  125. package/styles/ribbon/_fabric-dark-definition.scss +206 -0
  126. package/styles/ribbon/_fabric-definition.scss +206 -0
  127. package/styles/ribbon/_fluent-dark-definition.scss +1 -0
  128. package/styles/ribbon/_fluent-definition.scss +206 -0
  129. package/styles/ribbon/_fusionnew-definition.scss +206 -0
  130. package/styles/ribbon/_highcontrast-definition.scss +206 -0
  131. package/styles/ribbon/_highcontrast-light-definition.scss +206 -0
  132. package/styles/ribbon/_layout.scss +1040 -0
  133. package/styles/ribbon/_material-dark-definition.scss +206 -0
  134. package/styles/ribbon/_material-definition.scss +206 -0
  135. package/styles/ribbon/_tailwind-dark-definition.scss +1 -0
  136. package/styles/ribbon/_tailwind-definition.scss +206 -0
  137. package/styles/ribbon/_theme.scss +343 -0
  138. package/styles/ribbon/bootstrap-dark.css +1502 -0
  139. package/styles/ribbon/bootstrap-dark.scss +17 -0
  140. package/styles/ribbon/bootstrap.css +1507 -0
  141. package/styles/ribbon/bootstrap.scss +17 -0
  142. package/styles/ribbon/bootstrap4.css +1557 -0
  143. package/styles/ribbon/bootstrap4.scss +17 -0
  144. package/styles/ribbon/bootstrap5-dark.css +1586 -0
  145. package/styles/ribbon/bootstrap5-dark.scss +17 -0
  146. package/styles/ribbon/bootstrap5.css +1586 -0
  147. package/styles/ribbon/bootstrap5.scss +17 -0
  148. package/styles/ribbon/fabric-dark.css +1478 -0
  149. package/styles/ribbon/fabric-dark.scss +17 -0
  150. package/styles/ribbon/fabric.css +1476 -0
  151. package/styles/ribbon/fabric.scss +17 -0
  152. package/styles/ribbon/fluent-dark.css +1562 -0
  153. package/styles/ribbon/fluent-dark.scss +17 -0
  154. package/styles/ribbon/fluent.css +1562 -0
  155. package/styles/ribbon/fluent.scss +17 -0
  156. package/styles/ribbon/highcontrast-light.css +1485 -0
  157. package/styles/ribbon/highcontrast-light.scss +16 -0
  158. package/styles/ribbon/highcontrast.css +1494 -0
  159. package/styles/ribbon/highcontrast.scss +17 -0
  160. package/styles/ribbon/icons/_bootstrap-dark.scss +9 -0
  161. package/styles/ribbon/icons/_bootstrap.scss +9 -0
  162. package/styles/ribbon/icons/_bootstrap4.scss +9 -0
  163. package/styles/ribbon/icons/_bootstrap5-dark.scss +1 -0
  164. package/styles/ribbon/icons/_bootstrap5.scss +9 -0
  165. package/styles/ribbon/icons/_fabric-dark.scss +9 -0
  166. package/styles/ribbon/icons/_fabric.scss +9 -0
  167. package/styles/ribbon/icons/_fluent-dark.scss +1 -0
  168. package/styles/ribbon/icons/_fluent.scss +9 -0
  169. package/styles/ribbon/icons/_fusionnew.scss +9 -0
  170. package/styles/ribbon/icons/_highcontrast.scss +9 -0
  171. package/styles/ribbon/icons/_material-dark.scss +9 -0
  172. package/styles/ribbon/icons/_material.scss +9 -0
  173. package/styles/ribbon/icons/_material3.scss +9 -0
  174. package/styles/ribbon/icons/_tailwind-dark.scss +9 -0
  175. package/styles/ribbon/icons/_tailwind.scss +9 -0
  176. package/styles/ribbon/material-dark.css +1548 -0
  177. package/styles/ribbon/material-dark.scss +17 -0
  178. package/styles/ribbon/material.css +1581 -0
  179. package/styles/ribbon/material.scss +17 -0
  180. package/styles/ribbon/tailwind-dark.css +1560 -0
  181. package/styles/ribbon/tailwind-dark.scss +17 -0
  182. package/styles/ribbon/tailwind.css +1560 -0
  183. package/styles/ribbon/tailwind.scss +17 -0
  184. package/styles/tailwind-dark.css +1560 -0
  185. package/styles/tailwind-dark.scss +1 -0
  186. package/styles/tailwind.css +1560 -0
  187. package/styles/tailwind.scss +1 -0
  188. package/tslint.json +111 -0
@@ -0,0 +1,106 @@
1
+ /**
2
+ * Defines the layout types of ribbon.
3
+ */
4
+ export var RibbonLayout;
5
+ (function (RibbonLayout) {
6
+ /**
7
+ * Displays the ribbon tab content in classic layout.
8
+ */
9
+ RibbonLayout["Classic"] = "Classic";
10
+ /**
11
+ * Displays the ribbon tab content in simplified layout.
12
+ */
13
+ RibbonLayout["Simplified"] = "Simplified";
14
+ })(RibbonLayout || (RibbonLayout = {}));
15
+ /**
16
+ * Defines the alignment of the items in the ribbon group.
17
+ */
18
+ export var ItemOrientation;
19
+ (function (ItemOrientation) {
20
+ /**
21
+ * Displays the collection of items in rows.
22
+ */
23
+ ItemOrientation["Row"] = "Row";
24
+ /**
25
+ * Displays the collection of items in column.
26
+ */
27
+ ItemOrientation["Column"] = "Column";
28
+ })(ItemOrientation || (ItemOrientation = {}));
29
+ /**
30
+ * Defines the current size of the ribbon item in normal mode.
31
+ *
32
+ * @aspNumberEnum
33
+ */
34
+ export var RibbonItemSize;
35
+ (function (RibbonItemSize) {
36
+ /**
37
+ * The item appears with large icon and text at the bottom.
38
+ */
39
+ RibbonItemSize[RibbonItemSize["Large"] = 4] = "Large";
40
+ /**
41
+ * The item appears with small icon and text at the right.
42
+ */
43
+ RibbonItemSize[RibbonItemSize["Medium"] = 2] = "Medium";
44
+ /**
45
+ * The item appears with small icon only.
46
+ */
47
+ RibbonItemSize[RibbonItemSize["Small"] = 1] = "Small";
48
+ })(RibbonItemSize || (RibbonItemSize = {}));
49
+ /**
50
+ * Defines how to show an item in ribbon simplified layout.
51
+ *
52
+ * @aspNumberEnum
53
+ */
54
+ export var DisplayMode;
55
+ (function (DisplayMode) {
56
+ /**
57
+ * The item appears in the simplified layout group.
58
+ */
59
+ DisplayMode[DisplayMode["Simplified"] = 2] = "Simplified";
60
+ /**
61
+ * The item appears in overflow popup.
62
+ */
63
+ DisplayMode[DisplayMode["Overflow"] = 1] = "Overflow";
64
+ /**
65
+ * The item appears in both simplified layout group and overflow popup based on ribbon overflow state.
66
+ */
67
+ DisplayMode[DisplayMode["Auto"] = 3] = "Auto";
68
+ /**
69
+ * The item is hidden in simplified mode.
70
+ */
71
+ DisplayMode[DisplayMode["None"] = 0] = "None";
72
+ })(DisplayMode || (DisplayMode = {}));
73
+ /**
74
+ * Defines the type of the ribbon item.
75
+ */
76
+ export var RibbonItemType;
77
+ (function (RibbonItemType) {
78
+ /**
79
+ * Renders button as ribbon item.
80
+ */
81
+ RibbonItemType["Button"] = "Button";
82
+ /**
83
+ * Renders checkbox as ribbon item.
84
+ */
85
+ RibbonItemType["CheckBox"] = "CheckBox";
86
+ /**
87
+ * Renders color picker as ribbon item.
88
+ */
89
+ RibbonItemType["ColorPicker"] = "ColorPicker";
90
+ /**
91
+ * Renders combobox as ribbon item.
92
+ */
93
+ RibbonItemType["ComboBox"] = "ComboBox";
94
+ /**
95
+ * Renders dropdownbutton as ribbon item.
96
+ */
97
+ RibbonItemType["DropDown"] = "DropDown";
98
+ /**
99
+ * Renders splitbutton as ribbon item.
100
+ */
101
+ RibbonItemType["SplitButton"] = "SplitButton";
102
+ /**
103
+ * Renders the template content as ribbon item.
104
+ */
105
+ RibbonItemType["Template"] = "Template";
106
+ })(RibbonItemType || (RibbonItemType = {}));
@@ -0,0 +1,129 @@
1
+ import { addClass, append, Event, Collection, Complex, Component, EmitType, EventHandler, formatUnit, getInstance, getComponent, getUniqueID, closest } from '@syncfusion/ej2-base';import { INotifyPropertyChanged, isNullOrUndefined, isUndefined, ModuleDeclaration, NotifyPropertyChanges, Property, remove, removeClass } from '@syncfusion/ej2-base';import { Tab, TabAnimationSettings, TabAnimationSettingsModel, TabItemModel, SelectEventArgs, SelectingEventArgs, HScroll, Toolbar } from '@syncfusion/ej2-navigations';import { RibbonTab, RibbonTabModel, RibbonGroupModel, RibbonCollectionModel, RibbonItemModel, FileMenuSettings, FileMenuSettingsModel, RibbonItem, RibbonCollection, RibbonGroup } from '../models/index';import { commonProperties, DisplayMode, EJ2Control, ExpandCollapseEventArgs, itemProps, LauncherClickEventArgs, ribbonItemPropsList, RibbonLayout, ribbonTooltipData, TabSelectedEventArgs, TabSelectingEventArgs } from './interface';import { ItemOrientation, RibbonItemSize, RibbonItemType } from './interface';import { RibbonButton, RibbonComboBox, RibbonCheckBox, RibbonDropDown, RibbonColorPicker, RibbonSplitButton } from '../items/index';import { destroyControl, getCollection, getGroup, getIndex, getItem, getItemElement, updateCommonProperty, updateControlDisabled, isTooltipPresent, getTemplateFunction, createTooltip, destroyTooltip, updateTooltipProp } from './utils';import * as constants from './constant';import { RibbonFileMenu } from '../modules/index';import { RibbonTooltipModel } from '../models/ribbon-tooltip-model';import { Popup } from '@syncfusion/ej2-popups';import { BeforeOpenCloseMenuEventArgs, DropDownButton, SplitButton } from '@syncfusion/ej2-splitbuttons';
2
+ import {ComponentModel} from '@syncfusion/ej2-base';
3
+
4
+ /**
5
+ * Interface for a class Ribbon
6
+ */
7
+ export interface RibbonModel extends ComponentModel{
8
+
9
+ /**
10
+ * Specifies the active layout of the ribbon.
11
+ * Accepts one of the below values.
12
+ * * Classic – Renders the ribbon tab contents in classic layout.
13
+ * * Simplified – Renders the ribbon tab contents in single row.
14
+ *
15
+ * @isenumeration true
16
+ * @default RibbonLayout.Classic
17
+ * @asptype RibbonLayout
18
+ */
19
+ activeLayout?: RibbonLayout | string;
20
+
21
+ /**
22
+ * Defines one or more CSS classes to customize the appearance of ribbon.
23
+ *
24
+ * @default ''
25
+ */
26
+ cssClass?: string;
27
+
28
+ /**
29
+ * Defines the properties of ribbon file menu.
30
+ *
31
+ * @default {}
32
+ */
33
+ fileMenu?: FileMenuSettingsModel;
34
+
35
+ /**
36
+ * Defines the icon CSS for the launcher icon button in group header.
37
+ *
38
+ * @default ''
39
+ */
40
+ launcherIconCss?: string;
41
+
42
+ /**
43
+ * Specifies whether the ribbon is minimized or not.
44
+ * When minimized, only the tab header is shown.
45
+ *
46
+ * @default false
47
+ */
48
+ isMinimized?: boolean;
49
+
50
+ /**
51
+ * Provides the localization value for the controls present in ribbon items.
52
+ *
53
+ * @default 'en-us'
54
+ */
55
+ locale?: string;
56
+
57
+ /**
58
+ * Specifies the index of the current active tab.
59
+ *
60
+ * @default 0
61
+ */
62
+ selectedTab?: number;
63
+
64
+ /**
65
+ * Specifies the animation configuration settings for showing the content of the Ribbon Tab.
66
+ *
67
+ * @default { previous: { effect: 'SlideLeftIn', duration: 600, easing: 'ease' },next: { effect: 'SlideRightIn', duration: 600, easing: 'ease' } }
68
+ */
69
+ tabAnimation?: TabAnimationSettingsModel;
70
+
71
+ /**
72
+ * Defines the list of ribbon tabs.
73
+ *
74
+ * @default []
75
+ */
76
+ tabs?: RibbonTabModel[];
77
+
78
+ /**
79
+ * Specifies the width of the ribbon.
80
+ *
81
+ * @default '100%'
82
+ */
83
+ width?: string | number;
84
+
85
+ /**
86
+ * Specifies the template content for the help pane of ribbon.
87
+ * The help pane appears on the right side of the ribbon header row.
88
+ *
89
+ * @default ''
90
+ * @aspType string
91
+ */
92
+ helpPaneTemplate?: string | HTMLElement;
93
+
94
+ /**
95
+ * Event triggers before selecting the tab item.
96
+ *
97
+ * @event tabSelecting
98
+ */
99
+ tabSelecting?: EmitType<TabSelectingEventArgs>;
100
+
101
+ /**
102
+ * Event triggers after selecting the tab item.
103
+ *
104
+ * @event tabSelected
105
+ */
106
+ tabSelected?: EmitType<TabSelectedEventArgs>;
107
+
108
+ /**
109
+ * Event triggers before expanding the ribbon.
110
+ *
111
+ * @event ribbonExpanding
112
+ */
113
+ ribbonExpanding?: EmitType<ExpandCollapseEventArgs>;
114
+
115
+ /**
116
+ * Event triggers before collapsing the ribbon.
117
+ *
118
+ * @event ribbonCollapsing
119
+ */
120
+ ribbonCollapsing?: EmitType<ExpandCollapseEventArgs>;
121
+
122
+ /**
123
+ * Event triggers when the launcher icon of the group is clicked.
124
+ *
125
+ * @event launcherIconClick
126
+ */
127
+ launcherIconClick?: EmitType<LauncherClickEventArgs>;
128
+
129
+ }
@@ -0,0 +1,357 @@
1
+ import { Component, EmitType } from '@syncfusion/ej2-base';
2
+ import { INotifyPropertyChanged, ModuleDeclaration } from '@syncfusion/ej2-base';
3
+ import { Tab, TabAnimationSettingsModel } from '@syncfusion/ej2-navigations';
4
+ import { RibbonTabModel, RibbonGroupModel, RibbonCollectionModel, RibbonItemModel, FileMenuSettingsModel } from '../models/index';
5
+ import { RibbonModel } from './ribbon-model';
6
+ import { ExpandCollapseEventArgs, LauncherClickEventArgs, RibbonLayout, ribbonTooltipData, TabSelectedEventArgs, TabSelectingEventArgs } from './interface';
7
+ import { RibbonButton, RibbonComboBox, RibbonCheckBox, RibbonDropDown, RibbonColorPicker, RibbonSplitButton } from '../items/index';
8
+ import { RibbonFileMenu } from '../modules/index';
9
+ import { DropDownButton } from '@syncfusion/ej2-splitbuttons';
10
+ /**
11
+ * The Ribbon Component is a structured layout to manage tools with tabs and groups.
12
+ */
13
+ export declare class Ribbon extends Component<HTMLElement> implements INotifyPropertyChanged {
14
+ /**
15
+ * Specifies the active layout of the ribbon.
16
+ * Accepts one of the below values.
17
+ * * Classic – Renders the ribbon tab contents in classic layout.
18
+ * * Simplified – Renders the ribbon tab contents in single row.
19
+ *
20
+ * @isenumeration true
21
+ * @default RibbonLayout.Classic
22
+ * @asptype RibbonLayout
23
+ */
24
+ activeLayout: RibbonLayout | string;
25
+ /**
26
+ * Defines one or more CSS classes to customize the appearance of ribbon.
27
+ *
28
+ * @default ''
29
+ */
30
+ cssClass: string;
31
+ /**
32
+ * Defines the properties of ribbon file menu.
33
+ *
34
+ * @default {}
35
+ */
36
+ fileMenu: FileMenuSettingsModel;
37
+ /**
38
+ * Defines the icon CSS for the launcher icon button in group header.
39
+ *
40
+ * @default ''
41
+ */
42
+ launcherIconCss: string;
43
+ /**
44
+ * Specifies whether the ribbon is minimized or not.
45
+ * When minimized, only the tab header is shown.
46
+ *
47
+ * @default false
48
+ */
49
+ isMinimized: boolean;
50
+ /**
51
+ * Provides the localization value for the controls present in ribbon items.
52
+ *
53
+ * @default 'en-us'
54
+ */
55
+ locale: string;
56
+ /**
57
+ * Specifies the index of the current active tab.
58
+ *
59
+ * @default 0
60
+ */
61
+ selectedTab: number;
62
+ /**
63
+ * Specifies the animation configuration settings for showing the content of the Ribbon Tab.
64
+ *
65
+ * @default { previous: { effect: 'SlideLeftIn', duration: 600, easing: 'ease' },next: { effect: 'SlideRightIn', duration: 600, easing: 'ease' } }
66
+ */
67
+ tabAnimation: TabAnimationSettingsModel;
68
+ /**
69
+ * Defines the list of ribbon tabs.
70
+ *
71
+ * @default []
72
+ */
73
+ tabs: RibbonTabModel[];
74
+ /**
75
+ * Specifies the width of the ribbon.
76
+ *
77
+ * @default '100%'
78
+ */
79
+ width: string | number;
80
+ /**
81
+ * Specifies the template content for the help pane of ribbon.
82
+ * The help pane appears on the right side of the ribbon header row.
83
+ *
84
+ * @default ''
85
+ * @aspType string
86
+ */
87
+ helpPaneTemplate: string | HTMLElement;
88
+ /**
89
+ * Event triggers before selecting the tab item.
90
+ *
91
+ * @event tabSelecting
92
+ */
93
+ tabSelecting: EmitType<TabSelectingEventArgs>;
94
+ /**
95
+ * Event triggers after selecting the tab item.
96
+ *
97
+ * @event tabSelected
98
+ */
99
+ tabSelected: EmitType<TabSelectedEventArgs>;
100
+ /**
101
+ * Event triggers before expanding the ribbon.
102
+ *
103
+ * @event ribbonExpanding
104
+ */
105
+ ribbonExpanding: EmitType<ExpandCollapseEventArgs>;
106
+ /**
107
+ * Event triggers before collapsing the ribbon.
108
+ *
109
+ * @event ribbonCollapsing
110
+ */
111
+ ribbonCollapsing: EmitType<ExpandCollapseEventArgs>;
112
+ /**
113
+ * Event triggers when the launcher icon of the group is clicked.
114
+ *
115
+ * @event launcherIconClick
116
+ */
117
+ launcherIconClick: EmitType<LauncherClickEventArgs>;
118
+ /**
119
+ * The `ribbonButtonModule` is used to create and manipulate buttons in ribbon item.
120
+ */
121
+ ribbonButtonModule: RibbonButton;
122
+ /**
123
+ * The `ribbonDropDownModule` is used to create and manipulate dropdown buttons in ribbon item.
124
+ */
125
+ ribbonDropDownModule: RibbonDropDown;
126
+ /**
127
+ * The `ribbonSplitButtonModule` is used to create and manipulate split buttons in ribbon item.
128
+ */
129
+ ribbonSplitButtonModule: RibbonSplitButton;
130
+ /**
131
+ * The `ribbonCheckBoxModule` is used to create and manipulate checkbox in ribbon item.
132
+ */
133
+ ribbonCheckBoxModule: RibbonCheckBox;
134
+ /**
135
+ * The `ribbonColorPickerModule` is used to create and manipulate color picker in ribbon item.
136
+ */
137
+ ribbonColorPickerModule: RibbonColorPicker;
138
+ /**
139
+ * The `ribbonComboBoxModule` is used to create and manipulate combobox in ribbon item.
140
+ */
141
+ ribbonComboBoxModule: RibbonComboBox;
142
+ /**
143
+ * The `ribbonFileMenuModule` is used to create and manipulate the ribbon file menu.
144
+ */
145
+ ribbonFileMenuModule: RibbonFileMenu;
146
+ private idIndex;
147
+ private isAddRemove;
148
+ private collapseButton;
149
+ private ribbonTempEle;
150
+ private scrollModule;
151
+ /** @hidden */
152
+ overflowDDB: DropDownButton;
153
+ /** @hidden */
154
+ tabsInternal: RibbonTabModel[];
155
+ /** @hidden */
156
+ tabObj: Tab;
157
+ /** @hidden */
158
+ tooltipData: ribbonTooltipData[];
159
+ /**
160
+ * Constructor for creating the widget.
161
+ *
162
+ * @param {RibbonModel} options - Specifies the ribbon model
163
+ * @param {string|HTMLDivElement} element - Specifies the target element
164
+ */
165
+ constructor(options?: RibbonModel, element?: string | HTMLElement);
166
+ /**
167
+ * Initialize the control rendering.
168
+ *
169
+ * @returns {void}
170
+ * @private
171
+ */
172
+ protected render(): void;
173
+ protected preRender(): void;
174
+ /**
175
+ * Get the properties to be maintained in the persisted state.
176
+ *
177
+ * @returns {string} - Persist data
178
+ */
179
+ protected getPersistData(): string;
180
+ /**
181
+ * Get component name.
182
+ *
183
+ * @returns {string} - Module name
184
+ * @private
185
+ */
186
+ protected getModuleName(): string;
187
+ /**
188
+ * To provide the array of modules needed for component rendering
189
+ *
190
+ * @returns {ModuleDeclaration[]} - returns module declaration.
191
+ * @hidden
192
+ */
193
+ protected requiredModules(): ModuleDeclaration[];
194
+ private initialize;
195
+ private wireEvents;
196
+ private resizeHandler;
197
+ private renderTabs;
198
+ private minimize;
199
+ private toggleLayout;
200
+ private tabCreated;
201
+ private ribbonTabSelected;
202
+ private checkOverflow;
203
+ private checkSimplifiedItemShrinking;
204
+ private checkSimplifiedItemExpanding;
205
+ private createSimplfiedOverflow;
206
+ private updatePopupItems;
207
+ private removeSimplfiedOverflow;
208
+ private createOverflowPopup;
209
+ private addOverflowEvents;
210
+ private createOfTabContainer;
211
+ private checkGroupShrinking;
212
+ private checkLargeToMedium;
213
+ private checkMediumToSmall;
214
+ private checkGroupExpanding;
215
+ private checkSmallToMedium;
216
+ private checkMediumToLarge;
217
+ private setItemSize;
218
+ private createOverflowDropdown;
219
+ private removeOverflowDropdown;
220
+ private removeDropdown;
221
+ private getGroupResizeOrder;
222
+ private destroyScroll;
223
+ private clearOverflowDropDown;
224
+ private ribbonTabSelecting;
225
+ private createTabItems;
226
+ private renderInitialTab;
227
+ private addOverflowButton;
228
+ private removeOverflowButton;
229
+ private removeOverflowEvent;
230
+ private createGroupContainer;
231
+ private addExpandCollapse;
232
+ private removeExpandCollapse;
233
+ private reRenderTabs;
234
+ private switchLayout;
235
+ private launcherIconClicked;
236
+ private createGroups;
237
+ private validateItemSize;
238
+ private createCollection;
239
+ private createItems;
240
+ private createHelpPaneTemplate;
241
+ private createTemplateContent;
242
+ private renderItemTemplate;
243
+ private checkID;
244
+ private updateCommonProperty;
245
+ private removeLauncherIcon;
246
+ private destroyTabItems;
247
+ private destroyFunction;
248
+ private getItemModuleName;
249
+ private clearOverflowResize;
250
+ /**
251
+ * Refreshes the layout.
252
+ *
253
+ * @returns {void}
254
+ */
255
+ refreshLayout(): void;
256
+ /**
257
+ * Selects the tab
258
+ *
259
+ * @param {string} tabId - Gets the tab ID
260
+ * @returns {void}
261
+ */
262
+ selectTab(tabId: string): void;
263
+ /**
264
+ * Adds the ribbon tab.
265
+ *
266
+ * @param {RibbonTabModel} tab - Gets the ribbon tab model
267
+ * @param {string} targetId - Gets the ID of the target tab to add the new tab.
268
+ * @param {boolean} isAfter - Defines whether the tab is added before or after the target.
269
+ * @returns {void}
270
+ */
271
+ addTab(tab: RibbonTabModel, targetId?: string, isAfter?: boolean): void;
272
+ /**
273
+ * Removes the ribbon tab.
274
+ *
275
+ * @param {string} tabId - Gets the tab ID
276
+ * @returns {void}
277
+ */
278
+ removeTab(tabId: string): void;
279
+ /**
280
+ * Adds the ribbon group.
281
+ *
282
+ * @param {string} tabId - Gets the tab ID.
283
+ * @param {RibbonGroupModel} group - Gets the ribbon group model.
284
+ * @param {string} targetId - Gets the ID of the target group to add the new group.
285
+ * @param {boolean} isAfter - Defines whether the group is added before or after the target.
286
+ * @returns {void}
287
+ */
288
+ addGroup(tabId: string, group: RibbonGroupModel, targetId?: string, isAfter?: boolean): void;
289
+ /**
290
+ * Removes the ribbon group.
291
+ *
292
+ * @param {string} groupId -Gets the group ID.
293
+ * @returns {void}
294
+ */
295
+ removeGroup(groupId: string): void;
296
+ /**
297
+ * adds the ribbon collection.
298
+ *
299
+ * @param {string} groupId - Gets the ribbon group ID.
300
+ * @param {RibbonCollectionModel} collection - Gets the ribbon collection model.
301
+ * @param {string} targetId - Gets the ID of the target collection to add the new collection.
302
+ * @param {boolean} isAfter - Defines whether the collection is added before or after the target.
303
+ * @returns {void}
304
+ */
305
+ addCollection(groupId: string, collection: RibbonCollectionModel, targetId?: string, isAfter?: boolean): void;
306
+ /**
307
+ * Removes the ribbon collection.
308
+ *
309
+ * @param {string} collectionId - Gets the collection ID.
310
+ * @returns {void}
311
+ */
312
+ removeCollection(collectionId: string): void;
313
+ /**
314
+ * Adds ribbon item.
315
+ *
316
+ * @param {string} collectionId - Gets the collection ID.
317
+ * @param {RibbonItemModel} item - Gets the ribbon item model.
318
+ * @param {string} targetId - Gets the ID of the target item to add the new item.
319
+ * @param {boolean} isAfter - Defines whether the item is added before or after the target.
320
+ * @returns {void}
321
+ */
322
+ addItem(collectionId: string, item: RibbonItemModel, targetId?: string, isAfter?: boolean): void;
323
+ /**
324
+ * Removes ribbon item.
325
+ *
326
+ * @param {string} itemId - Gets the item ID.
327
+ * @returns {void}
328
+ */
329
+ removeItem(itemId: string): void;
330
+ private removeItemElement;
331
+ /**
332
+ * Enables ribbon item.
333
+ *
334
+ * @param {string} itemId - Gets the item ID.
335
+ * @returns {void}
336
+ */
337
+ enableItem(itemId: string): void;
338
+ /**
339
+ * Disables ribbon item.
340
+ *
341
+ * @param {string} itemId - Gets the item ID.
342
+ * @returns {void}
343
+ */
344
+ disableItem(itemId: string): void;
345
+ private enableDisableItem;
346
+ private unwireEvents;
347
+ destroy(): void;
348
+ /**
349
+ * Called internally if any of the property value changed.
350
+ *
351
+ * @param {RibbonModel} newProp - Specifies new properties
352
+ * @param {RibbonModel} oldProp - Specifies old properties
353
+ * @returns {void}
354
+ * @private
355
+ */
356
+ onPropertyChanged(newProp: RibbonModel, oldProp?: RibbonModel): void;
357
+ }