@bryntum/scheduler-react 7.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (296) hide show
  1. package/README.md +52 -0
  2. package/lib/BryntumAIFilterField.d.ts +231 -0
  3. package/lib/BryntumAIFilterField.js +168 -0
  4. package/lib/BryntumAIFilterField.js.map +1 -0
  5. package/lib/BryntumButton.d.ts +206 -0
  6. package/lib/BryntumButton.js +148 -0
  7. package/lib/BryntumButton.js.map +1 -0
  8. package/lib/BryntumButtonGroup.d.ts +201 -0
  9. package/lib/BryntumButtonGroup.js +154 -0
  10. package/lib/BryntumButtonGroup.js.map +1 -0
  11. package/lib/BryntumChatPanel.d.ts +246 -0
  12. package/lib/BryntumChatPanel.js +178 -0
  13. package/lib/BryntumChatPanel.js.map +1 -0
  14. package/lib/BryntumCheckbox.d.ts +239 -0
  15. package/lib/BryntumCheckbox.js +168 -0
  16. package/lib/BryntumCheckbox.js.map +1 -0
  17. package/lib/BryntumCheckboxGroup.d.ts +249 -0
  18. package/lib/BryntumCheckboxGroup.js +182 -0
  19. package/lib/BryntumCheckboxGroup.js.map +1 -0
  20. package/lib/BryntumChecklistFilterCombo.d.ts +268 -0
  21. package/lib/BryntumChecklistFilterCombo.js +205 -0
  22. package/lib/BryntumChecklistFilterCombo.js.map +1 -0
  23. package/lib/BryntumChipView.d.ts +208 -0
  24. package/lib/BryntumChipView.js +152 -0
  25. package/lib/BryntumChipView.js.map +1 -0
  26. package/lib/BryntumCodeEditor.d.ts +237 -0
  27. package/lib/BryntumCodeEditor.js +176 -0
  28. package/lib/BryntumCodeEditor.js.map +1 -0
  29. package/lib/BryntumColorField.d.ts +231 -0
  30. package/lib/BryntumColorField.js +169 -0
  31. package/lib/BryntumColorField.js.map +1 -0
  32. package/lib/BryntumCombo.d.ts +266 -0
  33. package/lib/BryntumCombo.js +202 -0
  34. package/lib/BryntumCombo.js.map +1 -0
  35. package/lib/BryntumContainer.d.ts +185 -0
  36. package/lib/BryntumContainer.js +148 -0
  37. package/lib/BryntumContainer.js.map +1 -0
  38. package/lib/BryntumDateField.d.ts +241 -0
  39. package/lib/BryntumDateField.js +178 -0
  40. package/lib/BryntumDateField.js.map +1 -0
  41. package/lib/BryntumDatePicker.d.ts +310 -0
  42. package/lib/BryntumDatePicker.js +213 -0
  43. package/lib/BryntumDatePicker.js.map +1 -0
  44. package/lib/BryntumDateRangeField.d.ts +242 -0
  45. package/lib/BryntumDateRangeField.js +179 -0
  46. package/lib/BryntumDateRangeField.js.map +1 -0
  47. package/lib/BryntumDateTimeField.d.ts +222 -0
  48. package/lib/BryntumDateTimeField.js +158 -0
  49. package/lib/BryntumDateTimeField.js.map +1 -0
  50. package/lib/BryntumDemoCodeEditor.d.ts +240 -0
  51. package/lib/BryntumDemoCodeEditor.js +179 -0
  52. package/lib/BryntumDemoCodeEditor.js.map +1 -0
  53. package/lib/BryntumDemoHeader.d.ts +30 -0
  54. package/lib/BryntumDemoHeader.js +84 -0
  55. package/lib/BryntumDemoHeader.js.map +1 -0
  56. package/lib/BryntumDisplayField.d.ts +227 -0
  57. package/lib/BryntumDisplayField.js +163 -0
  58. package/lib/BryntumDisplayField.js.map +1 -0
  59. package/lib/BryntumDurationField.d.ts +234 -0
  60. package/lib/BryntumDurationField.js +175 -0
  61. package/lib/BryntumDurationField.js.map +1 -0
  62. package/lib/BryntumEditor.d.ts +249 -0
  63. package/lib/BryntumEditor.js +167 -0
  64. package/lib/BryntumEditor.js.map +1 -0
  65. package/lib/BryntumEventColorField.d.ts +231 -0
  66. package/lib/BryntumEventColorField.js +169 -0
  67. package/lib/BryntumEventColorField.js.map +1 -0
  68. package/lib/BryntumFieldFilterPicker.d.ts +202 -0
  69. package/lib/BryntumFieldFilterPicker.js +161 -0
  70. package/lib/BryntumFieldFilterPicker.js.map +1 -0
  71. package/lib/BryntumFieldFilterPickerGroup.d.ts +207 -0
  72. package/lib/BryntumFieldFilterPickerGroup.js +164 -0
  73. package/lib/BryntumFieldFilterPickerGroup.js.map +1 -0
  74. package/lib/BryntumFieldSet.d.ts +235 -0
  75. package/lib/BryntumFieldSet.js +174 -0
  76. package/lib/BryntumFieldSet.js.map +1 -0
  77. package/lib/BryntumFileField.d.ts +228 -0
  78. package/lib/BryntumFileField.js +164 -0
  79. package/lib/BryntumFileField.js.map +1 -0
  80. package/lib/BryntumFilePicker.d.ts +192 -0
  81. package/lib/BryntumFilePicker.js +153 -0
  82. package/lib/BryntumFilePicker.js.map +1 -0
  83. package/lib/BryntumFilterField.d.ts +234 -0
  84. package/lib/BryntumFilterField.js +171 -0
  85. package/lib/BryntumFilterField.js.map +1 -0
  86. package/lib/BryntumFullscreenButton.d.ts +8 -0
  87. package/lib/BryntumFullscreenButton.js +37 -0
  88. package/lib/BryntumFullscreenButton.js.map +1 -0
  89. package/lib/BryntumGrid.d.ts +844 -0
  90. package/lib/BryntumGrid.js +335 -0
  91. package/lib/BryntumGrid.js.map +1 -0
  92. package/lib/BryntumGridBase.d.ts +842 -0
  93. package/lib/BryntumGridBase.js +333 -0
  94. package/lib/BryntumGridBase.js.map +1 -0
  95. package/lib/BryntumGridChartDesigner.d.ts +162 -0
  96. package/lib/BryntumGridChartDesigner.js +127 -0
  97. package/lib/BryntumGridChartDesigner.js.map +1 -0
  98. package/lib/BryntumGridFieldFilterPicker.d.ts +203 -0
  99. package/lib/BryntumGridFieldFilterPicker.js +162 -0
  100. package/lib/BryntumGridFieldFilterPicker.js.map +1 -0
  101. package/lib/BryntumGridFieldFilterPickerGroup.d.ts +206 -0
  102. package/lib/BryntumGridFieldFilterPickerGroup.js +163 -0
  103. package/lib/BryntumGridFieldFilterPickerGroup.js.map +1 -0
  104. package/lib/BryntumGroupBar.d.ts +208 -0
  105. package/lib/BryntumGroupBar.js +152 -0
  106. package/lib/BryntumGroupBar.js.map +1 -0
  107. package/lib/BryntumHint.d.ts +260 -0
  108. package/lib/BryntumHint.js +184 -0
  109. package/lib/BryntumHint.js.map +1 -0
  110. package/lib/BryntumLabel.d.ts +161 -0
  111. package/lib/BryntumLabel.js +126 -0
  112. package/lib/BryntumLabel.js.map +1 -0
  113. package/lib/BryntumList.d.ts +205 -0
  114. package/lib/BryntumList.js +149 -0
  115. package/lib/BryntumList.js.map +1 -0
  116. package/lib/BryntumMenu.d.ts +264 -0
  117. package/lib/BryntumMenu.js +187 -0
  118. package/lib/BryntumMenu.js.map +1 -0
  119. package/lib/BryntumMonthPicker.d.ts +240 -0
  120. package/lib/BryntumMonthPicker.js +173 -0
  121. package/lib/BryntumMonthPicker.js.map +1 -0
  122. package/lib/BryntumNumberField.d.ts +234 -0
  123. package/lib/BryntumNumberField.js +170 -0
  124. package/lib/BryntumNumberField.js.map +1 -0
  125. package/lib/BryntumPagingToolbar.d.ts +210 -0
  126. package/lib/BryntumPagingToolbar.js +156 -0
  127. package/lib/BryntumPagingToolbar.js.map +1 -0
  128. package/lib/BryntumPanel.d.ts +231 -0
  129. package/lib/BryntumPanel.js +170 -0
  130. package/lib/BryntumPanel.js.map +1 -0
  131. package/lib/BryntumPasswordField.d.ts +226 -0
  132. package/lib/BryntumPasswordField.js +162 -0
  133. package/lib/BryntumPasswordField.js.map +1 -0
  134. package/lib/BryntumProjectCombo.d.ts +267 -0
  135. package/lib/BryntumProjectCombo.js +203 -0
  136. package/lib/BryntumProjectCombo.js.map +1 -0
  137. package/lib/BryntumRadio.d.ts +239 -0
  138. package/lib/BryntumRadio.js +168 -0
  139. package/lib/BryntumRadio.js.map +1 -0
  140. package/lib/BryntumRadioGroup.d.ts +239 -0
  141. package/lib/BryntumRadioGroup.js +178 -0
  142. package/lib/BryntumRadioGroup.js.map +1 -0
  143. package/lib/BryntumResourceCombo.d.ts +267 -0
  144. package/lib/BryntumResourceCombo.js +203 -0
  145. package/lib/BryntumResourceCombo.js.map +1 -0
  146. package/lib/BryntumResourceFilter.d.ts +214 -0
  147. package/lib/BryntumResourceFilter.js +154 -0
  148. package/lib/BryntumResourceFilter.js.map +1 -0
  149. package/lib/BryntumScheduler.d.ts +2037 -0
  150. package/lib/BryntumScheduler.js +642 -0
  151. package/lib/BryntumScheduler.js.map +1 -0
  152. package/lib/BryntumSchedulerBase.d.ts +2036 -0
  153. package/lib/BryntumSchedulerBase.js +641 -0
  154. package/lib/BryntumSchedulerBase.js.map +1 -0
  155. package/lib/BryntumSchedulerDatePicker.d.ts +313 -0
  156. package/lib/BryntumSchedulerDatePicker.js +216 -0
  157. package/lib/BryntumSchedulerDatePicker.js.map +1 -0
  158. package/lib/BryntumSchedulerProjectModel.d.ts +90 -0
  159. package/lib/BryntumSchedulerProjectModel.js +98 -0
  160. package/lib/BryntumSchedulerProjectModel.js.map +1 -0
  161. package/lib/BryntumSlideToggle.d.ts +239 -0
  162. package/lib/BryntumSlideToggle.js +168 -0
  163. package/lib/BryntumSlideToggle.js.map +1 -0
  164. package/lib/BryntumSlider.d.ts +184 -0
  165. package/lib/BryntumSlider.js +142 -0
  166. package/lib/BryntumSlider.js.map +1 -0
  167. package/lib/BryntumSplitter.d.ts +174 -0
  168. package/lib/BryntumSplitter.js +130 -0
  169. package/lib/BryntumSplitter.js.map +1 -0
  170. package/lib/BryntumTabPanel.d.ts +249 -0
  171. package/lib/BryntumTabPanel.js +178 -0
  172. package/lib/BryntumTabPanel.js.map +1 -0
  173. package/lib/BryntumTextAreaField.d.ts +228 -0
  174. package/lib/BryntumTextAreaField.js +164 -0
  175. package/lib/BryntumTextAreaField.js.map +1 -0
  176. package/lib/BryntumTextAreaPickerField.d.ts +232 -0
  177. package/lib/BryntumTextAreaPickerField.js +170 -0
  178. package/lib/BryntumTextAreaPickerField.js.map +1 -0
  179. package/lib/BryntumTextField.d.ts +229 -0
  180. package/lib/BryntumTextField.js +166 -0
  181. package/lib/BryntumTextField.js.map +1 -0
  182. package/lib/BryntumThemeCombo.d.ts +17 -0
  183. package/lib/BryntumThemeCombo.js +75 -0
  184. package/lib/BryntumThemeCombo.js.map +1 -0
  185. package/lib/BryntumTimeField.d.ts +238 -0
  186. package/lib/BryntumTimeField.js +175 -0
  187. package/lib/BryntumTimeField.js.map +1 -0
  188. package/lib/BryntumTimePicker.d.ts +192 -0
  189. package/lib/BryntumTimePicker.js +154 -0
  190. package/lib/BryntumTimePicker.js.map +1 -0
  191. package/lib/BryntumTimelineHistogram.d.ts +1183 -0
  192. package/lib/BryntumTimelineHistogram.js +448 -0
  193. package/lib/BryntumTimelineHistogram.js.map +1 -0
  194. package/lib/BryntumToolbar.d.ts +209 -0
  195. package/lib/BryntumToolbar.js +155 -0
  196. package/lib/BryntumToolbar.js.map +1 -0
  197. package/lib/BryntumTreeCombo.d.ts +266 -0
  198. package/lib/BryntumTreeCombo.js +202 -0
  199. package/lib/BryntumTreeCombo.js.map +1 -0
  200. package/lib/BryntumTreeGrid.d.ts +843 -0
  201. package/lib/BryntumTreeGrid.js +334 -0
  202. package/lib/BryntumTreeGrid.js.map +1 -0
  203. package/lib/BryntumUndoRedo.d.ts +189 -0
  204. package/lib/BryntumUndoRedo.js +152 -0
  205. package/lib/BryntumUndoRedo.js.map +1 -0
  206. package/lib/BryntumViewPresetCombo.d.ts +215 -0
  207. package/lib/BryntumViewPresetCombo.js +158 -0
  208. package/lib/BryntumViewPresetCombo.js.map +1 -0
  209. package/lib/BryntumWidget.d.ts +160 -0
  210. package/lib/BryntumWidget.js +125 -0
  211. package/lib/BryntumWidget.js.map +1 -0
  212. package/lib/BryntumYearPicker.d.ts +240 -0
  213. package/lib/BryntumYearPicker.js +177 -0
  214. package/lib/BryntumYearPicker.js.map +1 -0
  215. package/lib/WrapperHelper.d.ts +26 -0
  216. package/lib/WrapperHelper.js +569 -0
  217. package/lib/WrapperHelper.js.map +1 -0
  218. package/lib/index.d.ts +71 -0
  219. package/lib/index.js +72 -0
  220. package/lib/index.js.map +1 -0
  221. package/license.pdf +0 -0
  222. package/licenses.md +310 -0
  223. package/package.json +25 -0
  224. package/src/BryntumAIFilterField.tsx +998 -0
  225. package/src/BryntumButton.tsx +887 -0
  226. package/src/BryntumButtonGroup.tsx +902 -0
  227. package/src/BryntumChatPanel.tsx +1082 -0
  228. package/src/BryntumCheckbox.tsx +1000 -0
  229. package/src/BryntumCheckboxGroup.tsx +1116 -0
  230. package/src/BryntumChecklistFilterCombo.tsx +1241 -0
  231. package/src/BryntumChipView.tsx +914 -0
  232. package/src/BryntumCodeEditor.tsx +1065 -0
  233. package/src/BryntumColorField.tsx +995 -0
  234. package/src/BryntumCombo.tsx +1230 -0
  235. package/src/BryntumContainer.tsx +861 -0
  236. package/src/BryntumDateField.tsx +1055 -0
  237. package/src/BryntumDatePicker.tsx +1340 -0
  238. package/src/BryntumDateRangeField.tsx +1057 -0
  239. package/src/BryntumDateTimeField.tsx +942 -0
  240. package/src/BryntumDemoCodeEditor.tsx +1081 -0
  241. package/src/BryntumDemoHeader.tsx +160 -0
  242. package/src/BryntumDisplayField.tsx +979 -0
  243. package/src/BryntumDurationField.tsx +1038 -0
  244. package/src/BryntumEditor.tsx +1013 -0
  245. package/src/BryntumEventColorField.tsx +995 -0
  246. package/src/BryntumFieldFilterPicker.tsx +943 -0
  247. package/src/BryntumFieldFilterPickerGroup.tsx +976 -0
  248. package/src/BryntumFieldSet.tsx +1058 -0
  249. package/src/BryntumFileField.tsx +982 -0
  250. package/src/BryntumFilePicker.tsx +888 -0
  251. package/src/BryntumFilterField.tsx +1023 -0
  252. package/src/BryntumFullscreenButton.tsx +45 -0
  253. package/src/BryntumGrid.tsx +2402 -0
  254. package/src/BryntumGridBase.tsx +2399 -0
  255. package/src/BryntumGridChartDesigner.tsx +728 -0
  256. package/src/BryntumGridFieldFilterPicker.tsx +956 -0
  257. package/src/BryntumGridFieldFilterPickerGroup.tsx +970 -0
  258. package/src/BryntumGroupBar.tsx +914 -0
  259. package/src/BryntumHint.tsx +1125 -0
  260. package/src/BryntumLabel.tsx +720 -0
  261. package/src/BryntumList.tsx +891 -0
  262. package/src/BryntumMenu.tsx +1143 -0
  263. package/src/BryntumMonthPicker.tsx +1056 -0
  264. package/src/BryntumNumberField.tsx +1025 -0
  265. package/src/BryntumPagingToolbar.tsx +924 -0
  266. package/src/BryntumPanel.tsx +1035 -0
  267. package/src/BryntumPasswordField.tsx +969 -0
  268. package/src/BryntumProjectCombo.tsx +1232 -0
  269. package/src/BryntumRadio.tsx +1000 -0
  270. package/src/BryntumRadioGroup.tsx +1088 -0
  271. package/src/BryntumResourceCombo.tsx +1235 -0
  272. package/src/BryntumResourceFilter.tsx +930 -0
  273. package/src/BryntumScheduler.tsx +5182 -0
  274. package/src/BryntumSchedulerBase.tsx +5180 -0
  275. package/src/BryntumSchedulerDatePicker.tsx +1364 -0
  276. package/src/BryntumSchedulerProjectModel.tsx +423 -0
  277. package/src/BryntumSlideToggle.tsx +1000 -0
  278. package/src/BryntumSlider.tsx +815 -0
  279. package/src/BryntumSplitter.tsx +754 -0
  280. package/src/BryntumTabPanel.tsx +1087 -0
  281. package/src/BryntumTextAreaField.tsx +981 -0
  282. package/src/BryntumTextAreaPickerField.tsx +1002 -0
  283. package/src/BryntumTextField.tsx +987 -0
  284. package/src/BryntumThemeCombo.tsx +101 -0
  285. package/src/BryntumTimeField.tsx +1036 -0
  286. package/src/BryntumTimePicker.tsx +893 -0
  287. package/src/BryntumTimelineHistogram.tsx +3425 -0
  288. package/src/BryntumToolbar.tsx +917 -0
  289. package/src/BryntumTreeCombo.tsx +1230 -0
  290. package/src/BryntumTreeGrid.tsx +2401 -0
  291. package/src/BryntumUndoRedo.tsx +885 -0
  292. package/src/BryntumViewPresetCombo.tsx +914 -0
  293. package/src/BryntumWidget.tsx +715 -0
  294. package/src/BryntumYearPicker.tsx +1070 -0
  295. package/src/WrapperHelper.tsx +1125 -0
  296. package/src/index.ts +76 -0
@@ -0,0 +1,887 @@
1
+ /**
2
+ * React wrapper for Bryntum Button
3
+ */
4
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
5
+ import React, { RefObject } from 'react';
6
+ import { AlignSpec, Base, Button, ButtonListeners, ContainerItemConfig, DomConfig, KeyMapConfig, MaskConfig, Menu, MenuConfig, MenuItemEntry, PopupConfig, Rectangle, Scroller, ScrollerConfig, TabConfig, TooltipConfig, VueConfig, Widget } from '@bryntum/scheduler';
7
+
8
+ import { createWidget, shouldComponentUpdate, processWidgetContent } from './WrapperHelper.js';
9
+
10
+ export type BryntumButtonProps = {
11
+ // Configs
12
+ /**
13
+ * Element (or element id) to adopt as this Widget's encapsulating element. The widget's
14
+ * content will be placed inside this element.
15
+ * ...
16
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-adopt)
17
+ */
18
+ adopt? : HTMLElement|string
19
+ /**
20
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
21
+ * ...
22
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-align)
23
+ */
24
+ align? : AlignSpec|string
25
+ /**
26
+ * When this widget is a child of a [Container](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container), it will by default be participating in a
27
+ * flexbox layout. This config allows you to set this widget's
28
+ * [align-self](https://developer.mozilla.org/en-US/docs/Web/CSS/align-self) style.
29
+ */
30
+ alignSelf? : string
31
+ /**
32
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating) and being shown through [showBy](#Core/widget/Widget#function-showBy).*
33
+ * `true` to show a connector arrow pointing to the align target.
34
+ */
35
+ anchor? : boolean
36
+ /**
37
+ * Element (or the id of an element) to append this widget's element to. Can be configured, or set once at
38
+ * runtime. To access the element of a rendered widget, see [element](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-element).
39
+ */
40
+ appendTo? : HTMLElement|string
41
+ /**
42
+ * A localizable string (May contain `'L{}'` tokens which resolve in the locale file) to inject
43
+ * into an element which will be linked using the `aria-describedby` attribute.
44
+ * ...
45
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-ariaDescription)
46
+ */
47
+ ariaDescription? : string
48
+ /**
49
+ * A localizable string (May contain `'L{}'` tokens which resolve in the locale file) to inject as
50
+ * the `aria-label` attribute.
51
+ * ...
52
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-ariaLabel)
53
+ */
54
+ ariaLabel? : string
55
+ /**
56
+ * Initial text to show in badge.
57
+ */
58
+ badge? : string
59
+ /**
60
+ * The button behavioral type, will be applied as a `type` attribute to this button's element.
61
+ */
62
+ behaviorType? : 'button'|'submit'|'reset'
63
+ /**
64
+ * An object where property names with a truthy value indicate which events should bubble up the ownership
65
+ * hierarchy when triggered.
66
+ * ...
67
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-bubbleEvents)
68
+ */
69
+ bubbleEvents? : object
70
+ /**
71
+ * Set to `false` to not call onXXX method names (e.g. `onShow`, `onClick`), as an easy way to listen for events.
72
+ * ...
73
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-callOnFunctions)
74
+ */
75
+ callOnFunctions? : boolean
76
+ /**
77
+ * By default, if an event handler throws an exception, the error propagates up the stack and the
78
+ * application state is undefined. Code which follows the event handler will *not* be executed.
79
+ * ...
80
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-catchEventHandlerExceptions)
81
+ */
82
+ catchEventHandlerExceptions? : boolean
83
+ /**
84
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
85
+ * Set to `true` to centre the Widget in browser viewport space.
86
+ */
87
+ centered? : boolean
88
+ /**
89
+ * Custom CSS classes to add to element.
90
+ * May be specified as a space separated string, or as an object in which property names
91
+ * with truthy values are used as the class names:
92
+ * ...
93
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-cls)
94
+ */
95
+ cls? : string|object
96
+ /**
97
+ * Applies the specified color to the widget, by setting the `--b-primary` CSS variable in the widgets
98
+ * `style` block.
99
+ * ...
100
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-color)
101
+ */
102
+ color? : string
103
+ /**
104
+ * Programmatic control over which column to start in when used in a grid layout.
105
+ */
106
+ column? : number
107
+ config? : object
108
+ /**
109
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating) or [positioned](#Core/widget/Widget#config-positioned).*
110
+ * Element, Widget or Rectangle to which this Widget is constrained.
111
+ */
112
+ constrainTo? : HTMLElement|Widget|Rectangle
113
+ /**
114
+ * The HTML content that coexists with sibling elements which may have been added to the
115
+ * [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement) by plugins and features.
116
+ * When specifying html, this widget's element will also have the [htmlCls](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-htmlCls)
117
+ * class added to its classList, to allow targeted styling.
118
+ */
119
+ content? : string
120
+ /**
121
+ * Custom CSS classes to add to the [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement).
122
+ * May be specified as a space separated string, or as an object in which property names
123
+ * with truthy values are used as the class names:
124
+ * ...
125
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-contentElementCls)
126
+ */
127
+ contentElementCls? : string|object
128
+ /**
129
+ * When this Widget configuration is used in the Grid's RowExpander feature's `widget` config, provide the
130
+ * field on the expanded record to use for populating this widget's store (if applicable)
131
+ */
132
+ dataField? : string
133
+ /**
134
+ * Object to apply to elements dataset (each key will be used as a data-attribute on the element)
135
+ */
136
+ dataset? : Record<string, string>
137
+ /**
138
+ * The name of the property to set when a single value is to be applied to this Widget. Such as when used
139
+ * in a grid WidgetColumn, this is the property to which the column's `field` is applied.
140
+ */
141
+ defaultBindProperty? : string
142
+ /**
143
+ * Check for CSS compatibility issues when upgrading to v7. Performs the following checks:
144
+ * ...
145
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-detectCSSCompatibilityIssues)
146
+ */
147
+ detectCSSCompatibilityIssues? : boolean
148
+ /**
149
+ * Disable or enable the widget. It is similar to [readOnly](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-readOnly) except a disabled widget
150
+ * cannot be focused, uses a different rendition (usually greyish) and does not allow selecting its value.
151
+ * ...
152
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-disabled)
153
+ */
154
+ disabled? : boolean|'inert'
155
+ /**
156
+ * Controls the placement of this widget when it is added to a [panel's ](https://bryntum.com/products/scheduler/docs/api/Core/widget/Panel)
157
+ * [strips collection](https://bryntum.com/products/scheduler/docs/api/Core/widget/Panel#config-strips). Typical values for this config are `'top'`,
158
+ * `'bottom'`, `'left'`, or `'right'`, which cause the widget to be placed on that side of the panel's
159
+ * body. Such widgets are called "edge strips".
160
+ * ...
161
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-dock)
162
+ */
163
+ dock? : 'top'|'bottom'|'left'|'right'|'start'|'end'|'header'|'pre-header'|object
164
+ /**
165
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
166
+ * Set to `true` to be able to drag a widget freely on the page. Or set to an object with a ´handleSelector´
167
+ * property which controls when a drag should start.
168
+ * ...
169
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-draggable)
170
+ */
171
+ draggable? : boolean|{
172
+ handleSelector?: string
173
+ }
174
+ /**
175
+ * An object specifying attributes to assign to the root element of this widget.
176
+ * Set `null` value to attribute to remove it.
177
+ * ...
178
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-elementAttributes)
179
+ */
180
+ elementAttributes? : Record<string, string|null>
181
+ extraData? : any
182
+ /**
183
+ * When this widget is a child of a [Container](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container), it will by default be participating in a
184
+ * flexbox layout. This config allows you to set this widget's
185
+ * [flex](https://developer.mozilla.org/en-US/docs/Web/CSS/flex) style.
186
+ * This may be configured as a single number or a `&lt;flex-grow&gt; &lt;flex-shrink&gt; &lt;flex-basis&gt;` format string.
187
+ * numeric-only values are interpreted as the `flex-grow` value.
188
+ */
189
+ flex? : number|string
190
+ /**
191
+ * Set to `true` to move the widget out of the document flow and position it
192
+ * absolutely in browser viewport space.
193
+ */
194
+ floating? : boolean
195
+ /**
196
+ * Widget's height, used to set element `style.height`. Either specify a valid height string or a number,
197
+ * which will get 'px' appended. We recommend using CSS as the primary way to control height, but in some
198
+ * cases this config is convenient.
199
+ */
200
+ height? : string|number
201
+ /**
202
+ * Configure with true to make widget initially hidden.
203
+ */
204
+ hidden? : boolean
205
+ /**
206
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
207
+ * ...
208
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-hideAnimation)
209
+ */
210
+ hideAnimation? : boolean|object
211
+ /**
212
+ * If provided, turns the button into a link.
213
+ * ...
214
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-href)
215
+ */
216
+ href? : string
217
+ /**
218
+ * The HTML to display initially or a function returning the markup (called at widget construction time).
219
+ * ...
220
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-html)
221
+ * @param {Core.widget.Widget} widget The calling Widget
222
+ * @returns {string}
223
+ */
224
+ html? : string|((widget: Widget) => string)|DomConfig|DomConfig[]|VueConfig
225
+ /**
226
+ * The CSS class(es) to add when HTML content is being applied to this widget.
227
+ */
228
+ htmlCls? : string|object
229
+ /**
230
+ * Button icon class, a developer-defined CSS class string which results in the desired icon.
231
+ * ...
232
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-icon)
233
+ */
234
+ icon? : string
235
+ /**
236
+ * Button icon alignment. May be `'start'` or `'end'`. Defaults to `'start'`
237
+ */
238
+ iconAlign? : 'start'|'end'
239
+ /**
240
+ * Widget id, if not specified one will be generated. Also used for lookups through Widget.getById
241
+ */
242
+ id? : string
243
+ /**
244
+ * Determines if the widgets read-only state should be controlled by its parent.
245
+ * ...
246
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-ignoreParentReadOnly)
247
+ */
248
+ ignoreParentReadOnly? : boolean
249
+ /**
250
+ * Element (or element id) to insert this widget before. If provided, [appendTo](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-appendTo) config is ignored.
251
+ */
252
+ insertBefore? : HTMLElement|string
253
+ /**
254
+ * Element (or element id) to append this widget element to, as a first child. If provided, [appendTo](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-appendTo) config is ignored.
255
+ */
256
+ insertFirst? : HTMLElement|string
257
+ /**
258
+ * An object whose keys are the [key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key) name
259
+ * and optional modifier prefixes: `'Ctrl+'`, `'Alt+'`, `'Meta+'`, and `'Shift+'` (case-insensitive). The values
260
+ * are the name of the instance method to call when the keystroke is received.
261
+ * ...
262
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-keyMap)
263
+ */
264
+ keyMap? : Record<string, KeyMapConfig>
265
+ /**
266
+ * The listener set for this object.
267
+ * ...
268
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-listeners)
269
+ */
270
+ listeners? : ButtonListeners
271
+ /**
272
+ * A class translations of which are used for translating this entity.
273
+ * This is often used when translations of an item are defined on its container class.
274
+ * For example:
275
+ * ...
276
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-localeClass)
277
+ */
278
+ localeClass? : typeof Base
279
+ /**
280
+ * Set to `false` to disable localization of this object.
281
+ */
282
+ localizable? : boolean
283
+ /**
284
+ * List of properties which values should be translated automatically upon a locale applying.
285
+ * In case there is a need to localize not typical value (not a String value or a field with re-defined setter/getter),
286
+ * you could use 'localeKey' meta configuration.
287
+ * Example:
288
+ * ...
289
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-localizableProperties)
290
+ */
291
+ localizableProperties? : string[]
292
+ /**
293
+ * Widget's margin. This may be configured as a single number or a `TRBL` format string.
294
+ * numeric-only values are interpreted as pixels.
295
+ */
296
+ margin? : number|string
297
+ /**
298
+ * This config object contains the defaults for the [Mask](https://bryntum.com/products/scheduler/docs/api/Core/widget/Mask) created for the
299
+ * [masked](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-masked) config. Any properties specified in the `masked` config will override these
300
+ * values.
301
+ */
302
+ maskDefaults? : MaskConfig
303
+ /**
304
+ * Set to `true` to apply the default mask to the widget. Alternatively, this can be the mask message or a
305
+ * [Mask](https://bryntum.com/products/scheduler/docs/api/Core/widget/Mask) config object.
306
+ */
307
+ masked? : boolean|string|MaskConfig
308
+ /**
309
+ * The element's maxHeight. Can be either a String or a Number (which will have 'px' appended). Note that
310
+ * like [height](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-height), *reading* the value will return the numeric value in pixels.
311
+ */
312
+ maxHeight? : string|number
313
+ /**
314
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
315
+ * ...
316
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-maximizeOnMobile)
317
+ */
318
+ maximizeOnMobile? : number|string
319
+ /**
320
+ * The elements maxWidth. Can be either a String or a Number (which will have 'px' appended). Note that
321
+ * like [width](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-width), *reading* the value will return the numeric value in pixels.
322
+ */
323
+ maxWidth? : string|number
324
+ /**
325
+ * A submenu configuration object, or an array of MenuItem configuration objects from which to create a
326
+ * submenu which is shown when this button is pressed.
327
+ * ...
328
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-menu)
329
+ */
330
+ menu? : Record<string, MenuItemEntry|ContainerItemConfig>|(MenuItemEntry|ContainerItemConfig)[]|MenuConfig|PopupConfig
331
+ /**
332
+ * The menu icon class to show when the button has a menu. Set to `null` to not show a menu icon.
333
+ * ...
334
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-menuIcon)
335
+ */
336
+ menuIcon? : string
337
+ /**
338
+ * The element's minHeight. Can be either a String or a Number (which will have 'px' appended). Note that
339
+ * like [height](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-height), *reading* the value will return the numeric value in pixels.
340
+ */
341
+ minHeight? : string|number
342
+ /**
343
+ * The elements minWidth. Can be either a String or a Number (which will have 'px' appended). Note that
344
+ * like [width](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-width), *reading* the value will return the numeric value in pixels.
345
+ */
346
+ minWidth? : string|number
347
+ /**
348
+ * When this is configured as `true` a [ResizeObserver](https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver)
349
+ * is used to monitor this element for size changes caused by either style manipulation, or by CSS
350
+ * layout.
351
+ * ...
352
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-monitorResize)
353
+ */
354
+ monitorResize? : boolean|{
355
+ immediate?: boolean
356
+ }
357
+ /**
358
+ * The owning Widget of this Widget. If this Widget is directly contained (that is, it is one of the
359
+ * [items](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container#property-items) of a Container), this config will be ignored. In this case
360
+ * the owner is <strong>always</strong> the encapsulating Container.
361
+ * ...
362
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-owner)
363
+ */
364
+ owner? : Widget|any
365
+ /**
366
+ * Set to `true` when a widget is rendered into another widget's [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement), but must
367
+ * not participate in the standard layout of that widget, and must be positioned relatively to that
368
+ * widget's [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement).
369
+ * ...
370
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-positioned)
371
+ */
372
+ positioned? : boolean
373
+ /**
374
+ * Initially pressed or not. Only applies with `toggleable = true`.
375
+ * ...
376
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-pressed)
377
+ */
378
+ pressed? : boolean
379
+ /**
380
+ * A CSS class to add to the pressed state of the button. A `b-pressed` CSS class is always added,
381
+ * when a button is pressed.
382
+ */
383
+ pressedCls? : string
384
+ /**
385
+ * Icon class for the buttons pressed state, a developer-defined CSS class string which results in the
386
+ * desired icon. Only applies to toggle buttons
387
+ * ...
388
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-pressedIcon)
389
+ */
390
+ pressedIcon? : string
391
+ /**
392
+ * Prevent tooltip from being displayed on touch devices. Useful for example for buttons that display a
393
+ * menu on click etc, since the tooltip would be displayed at the same time.
394
+ */
395
+ preventTooltipOnTouch? : boolean
396
+ /**
397
+ * Whether this widget is read-only. This is only valid if the widget is an input
398
+ * field, <strong>or contains input fields at any depth</strong>.
399
+ * ...
400
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-readOnly)
401
+ */
402
+ readOnly? : boolean
403
+ relayStoreEvents? : boolean
404
+ /**
405
+ * Predefined style to use for the button. Possible values are:
406
+ * ...
407
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-rendition)
408
+ */
409
+ rendition? : 'elevated'|'filled'|'tonal'|'outlined'|'text'|string
410
+ /**
411
+ * Configure as `true` to have the component display a translucent ripple when its
412
+ * [focusElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-focusElement), or [element](#Core/widget/Widget#property-element) is tapped <em>if the
413
+ * current theme supports ripples</em>. Out of the box, only the Material theme supports ripples.
414
+ * ...
415
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-ripple)
416
+ */
417
+ ripple? : boolean|{
418
+ delegate?: string
419
+ color?: string
420
+ radius?: number
421
+ clip?: string
422
+ }
423
+ /**
424
+ * If you are rendering this widget to a shadow root inside a web component, set this config to the shadowRoot. If not inside a web component, set it to `document.body`
425
+ */
426
+ rootElement? : ShadowRoot|HTMLElement
427
+ /**
428
+ * This may be configured as `true` to make the widget's element use the `direction:rtl` style.
429
+ * ...
430
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-rtl)
431
+ */
432
+ rtl? : boolean
433
+ /**
434
+ * Specifies whether (and optionally in which axes) a Widget may scroll. `true` means this widget may scroll
435
+ * in both axes. May be an object containing boolean `overflowX` and `overflowY` properties which are
436
+ * applied to CSS style properties `overflowX` and `overflowY`. If they are boolean, they are translated to
437
+ * CSS overflow properties thus:
438
+ * ...
439
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-scrollable)
440
+ */
441
+ scrollable? : boolean|ScrollerConfig|Scroller
442
+ /**
443
+ * Defines what to do if document is scrolled while Widget is visible (only relevant when floating is set to `true`).
444
+ * Valid values: ´null´: do nothing, ´hide´: hide the widget or ´realign´: realign to the target if possible.
445
+ */
446
+ scrollAction? : 'hide'|'realign'|null
447
+ /**
448
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
449
+ * ...
450
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-showAnimation)
451
+ */
452
+ showAnimation? : boolean|object
453
+ /**
454
+ * Set to `false` to not show the tooltip when this widget is [disabled](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-disabled)
455
+ */
456
+ showTooltipWhenDisabled? : boolean
457
+ /**
458
+ * Programmatic control over how many columns to span when used in a grid layout.
459
+ */
460
+ span? : number
461
+ /**
462
+ * Set to `true` to create a split button. A split button has a main action and a dropdown arrow to show a menu.
463
+ * ...
464
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-split)
465
+ */
466
+ split? : boolean|'mouseover'|'hover'
467
+ /**
468
+ * Set to `true` to perform action on clicking the button if it's already pressed
469
+ * and belongs to a [toggleGroup](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-toggleGroup).
470
+ */
471
+ supportsPressedClick? : boolean
472
+ /**
473
+ * A configuration for the [tab](https://bryntum.com/products/scheduler/docs/api/Core/widget/Tab) created for this widget when it is placed in a
474
+ * [TabPanel](https://bryntum.com/products/scheduler/docs/api/Core/widget/TabPanel). For example, this config can be used to control the icon of the `tab` for
475
+ * this widget:
476
+ * ...
477
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-tab)
478
+ */
479
+ tab? : boolean|TabConfig
480
+ /**
481
+ * The tab index of the button, or `null` for natural tab order (recommended). Setting to `0` is equivalent
482
+ * to natural tab order, but is unnecessary for buttons since they are naturally tabbable (i.e., accessible
483
+ * via the TAB key). Setting to `-1` disables tabbability but allows for focus to be set to the element
484
+ * programmatically.
485
+ * ...
486
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-tabIndex)
487
+ */
488
+ tabIndex? : number
489
+ /**
490
+ * The tag name of this Widget's root element
491
+ */
492
+ tag? : string
493
+ /**
494
+ * The `target` attribute for the [href](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-href) config
495
+ */
496
+ target? : string
497
+ /**
498
+ * The button's text. You can also supply a [DomConfig](https://bryntum.com/products/scheduler/docs/api/Core/helper/DomHelper#typedef-DomConfig) or an array of DomConfigs for complex button
499
+ * content.
500
+ */
501
+ text? : string|DomConfig|DomConfig[]
502
+ /**
503
+ * Text alignment: 'left', 'center' or 'right'. Also accepts direction neutral 'start' and 'end'.
504
+ * ...
505
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-textAlign)
506
+ */
507
+ textAlign? : 'left'|'center'|'right'|'start'|'end'
508
+ /**
509
+ * A title to display for the widget. Only in effect when inside a container that uses it (such as TabPanel)
510
+ */
511
+ title? : string
512
+ /**
513
+ * Enabled toggling of the button (stays pressed when pressed).
514
+ */
515
+ toggleable? : boolean
516
+ /**
517
+ * Indicates that this button is part of a group where only one button can be pressed. Assigning a value
518
+ * also sets `toggleable` to `true`.
519
+ * ...
520
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-toggleGroup)
521
+ */
522
+ toggleGroup? : string
523
+ /**
524
+ * Tooltip for the widget, either as a string or as a Tooltip config object.
525
+ * ...
526
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-tooltip)
527
+ */
528
+ tooltip? : string|TooltipConfig|null
529
+ type? : 'button'
530
+ /**
531
+ * Custom CSS class name suffixes to apply to the elements rendered by this widget. This may be specified
532
+ * as a space separated string, an array of strings, or as an object in which property names with truthy
533
+ * values are used as the class names.
534
+ * ...
535
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-ui)
536
+ */
537
+ ui? : string|object
538
+ /**
539
+ * A widgets weight determines its position among siblings when added to a [Container](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container).
540
+ * Higher weights go further down.
541
+ */
542
+ weight? : number
543
+ /**
544
+ * Widget's width, used to set element `style.width`. Either specify a valid width string or a number, which
545
+ * will get 'px' appended. We recommend using CSS as the primary way to control width, but in some cases
546
+ * this config is convenient.
547
+ */
548
+ width? : string|number
549
+ /**
550
+ * The x position for the widget.
551
+ * ...
552
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-x)
553
+ */
554
+ x? : number
555
+ /**
556
+ * The y position for the widget.
557
+ * ...
558
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-y)
559
+ */
560
+ y? : number
561
+
562
+ // Events
563
+ /**
564
+ * Fires when the default action is performed (the button is clicked)
565
+ * @param {object} event Event object
566
+ * @param {Core.widget.Button} event.source The button
567
+ * @param {Event} event.event DEPRECATED - Use domEvent instead.
568
+ * @param {Event} event.domEvent The triggering DOM event. Using the `pointerType` property of this event can help determine if it was a mouse, touch or pen action.
569
+ */
570
+ onAction? : ((event: { source: Button, event: Event, domEvent: Event }) => void)|string
571
+ /**
572
+ * Fires before an object is destroyed.
573
+ * @param {object} event Event object
574
+ * @param {Core.Base} event.source The Object that is being destroyed.
575
+ */
576
+ onBeforeDestroy? : ((event: { source: Base }) => void)|string
577
+ /**
578
+ * Triggered before a widget is hidden. Return `false` to prevent the action.
579
+ * @param {object} event Event object
580
+ * @param {Core.widget.Widget} event.source The widget being hidden.
581
+ */
582
+ onBeforeHide? : ((event: { source: Widget }) => Promise<boolean>|boolean|void)|string
583
+ /**
584
+ * Triggered before a widget is shown. Return `false` to prevent the action.
585
+ * @param {object} event Event object
586
+ * @param {Core.widget.Widget,any} event.source The widget being shown
587
+ */
588
+ onBeforeShow? : ((event: { source: Widget|any }) => Promise<boolean>|boolean|void)|string
589
+ /**
590
+ * This event is triggered when the button's menu is about to be shown.
591
+ * @param {object} event Event object
592
+ * @param {Core.widget.Button} event.source This Button instance.
593
+ * @param {Core.widget.Menu} event.menu This button's menu instance.
594
+ * @param {boolean} event.userAction `true` if the toggle was triggered by a user action (click), `false` if it was triggered programmatically.
595
+ * @param {Event} event.domEvent The original DOM event that triggered the action, if any. Using the `pointerType` property of this event can help determine if it was a mouse, touch or pen action.
596
+ */
597
+ onBeforeShowMenu? : ((event: { source: Button, menu: Menu, userAction: boolean, domEvent: Event }) => Promise<boolean>|boolean|void)|string
598
+ /**
599
+ * Fires before the button is toggled (the [pressed](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#property-pressed) state is changed). If the button is part of
600
+ * a [toggleGroup](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-toggleGroup) and you need to process the pressed button only, consider using
601
+ * [click](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#event-click) event or [action](#Core/widget/Button#event-action) event.
602
+ * Return `false` to prevent the toggle to the new pressed state.
603
+ * @param {object} event Event object
604
+ * @param {Core.widget.Button} event.source Toggled button
605
+ * @param {boolean} event.pressed New pressed state
606
+ * @param {boolean} event.userAction `true` if the toggle was triggered by a user action (click), `false` if it was triggered programmatically.
607
+ * @param {Event} event.domEvent The original DOM event that triggered the action, if any. Using the `pointerType` property of this event can help determine if it was a mouse, touch or pen action.
608
+ */
609
+ onBeforeToggle? : ((event: { source: Button, pressed: boolean, userAction: boolean, domEvent: Event }) => Promise<boolean>|boolean|void)|string
610
+ /**
611
+ * Fires when any other event is fired from the object.
612
+ * ...
613
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#event-catchAll)
614
+ * @param {object} event Event object
615
+ * @param {{[key: string]: any, type: string}} event.event The Object that contains event details
616
+ * @param {string} event.event.type The type of the event which is caught by the listener
617
+ */
618
+ onCatchAll? : ((event: {[key: string]: any, type: string}) => void)|string
619
+ /**
620
+ * Fires when the button is clicked
621
+ * @param {object} event Event object
622
+ * @param {Core.widget.Button} event.source The button
623
+ * @param {Event} event.event DEPRECATED - Use domEvent instead.
624
+ * @param {Event} event.domEvent The triggering DOM event. Using the `pointerType` property of this event can help determine if it was a mouse, touch or pen action.
625
+ */
626
+ onClick? : ((event: { source: Button, event: Event, domEvent: Event }) => void)|string
627
+ /**
628
+ * Fires when an object is destroyed.
629
+ * @param {object} event Event object
630
+ * @param {Core.Base} event.source The Object that is being destroyed.
631
+ */
632
+ onDestroy? : ((event: { source: Base }) => void)|string
633
+ /**
634
+ * Triggered when a widget's [element](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-element) is available.
635
+ * @param {object} event Event object
636
+ * @param {HTMLElement} event.element The Widget's element.
637
+ */
638
+ onElementCreated? : ((event: { element: HTMLElement }) => void)|string
639
+ /**
640
+ * Fired when focus enters this Widget.
641
+ * @param {object} event Event object
642
+ * @param {Core.widget.Widget} event.source This Widget
643
+ * @param {HTMLElement} event.fromElement The element which lost focus.
644
+ * @param {HTMLElement} event.toElement The element which gained focus.
645
+ * @param {Core.widget.Widget} event.fromWidget The widget which lost focus.
646
+ * @param {Core.widget.Widget} event.toWidget The widget which gained focus.
647
+ * @param {boolean} event.backwards `true` if the `toElement` is before the `fromElement` in document order.
648
+ */
649
+ onFocusIn? : ((event: { source: Widget, fromElement: HTMLElement, toElement: HTMLElement, fromWidget: Widget, toWidget: Widget, backwards: boolean }) => void)|string
650
+ /**
651
+ * Fired when focus exits this Widget's ownership tree. This is different from a `blur` event.
652
+ * focus moving from within this Widget's ownership tree, even if there are floating widgets
653
+ * will not trigger this event. This is when focus exits this widget completely.
654
+ * @param {object} event Event object
655
+ * @param {Core.widget.Widget} event.source This Widget
656
+ * @param {HTMLElement} event.fromElement The element which lost focus.
657
+ * @param {HTMLElement} event.toElement The element which gained focus.
658
+ * @param {Core.widget.Widget} event.fromWidget The widget which lost focus.
659
+ * @param {Core.widget.Widget} event.toWidget The widget which gained focus.
660
+ * @param {boolean} event.backwards `true` if the `toElement` is before the `fromElement` in document order.
661
+ */
662
+ onFocusOut? : ((event: { source: Widget, fromElement: HTMLElement, toElement: HTMLElement, fromWidget: Widget, toWidget: Widget, backwards: boolean }) => void)|string
663
+ /**
664
+ * Triggered after a widget was hidden
665
+ * @param {object} event Event object
666
+ * @param {Core.widget.Widget} event.source The widget
667
+ */
668
+ onHide? : ((event: { source: Widget }) => void)|string
669
+ /**
670
+ * Triggered when a widget which had been in a non-visible state for any reason
671
+ * achieves visibility.
672
+ * ...
673
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#event-paint)
674
+ * @param {object} event Event object
675
+ * @param {Core.widget.Widget} event.source The widget being painted.
676
+ * @param {boolean} event.firstPaint `true` if this is the first paint.
677
+ */
678
+ onPaint? : ((event: { source: Widget, firstPaint: boolean }) => void)|string
679
+ /**
680
+ * Fired when a Widget's read only state is toggled
681
+ * @param {object} event Event object
682
+ * @param {boolean} event.readOnly Read only or not
683
+ */
684
+ onReadOnly? : ((event: { readOnly: boolean }) => void)|string
685
+ /**
686
+ * This event is fired after a widget's elements have been synchronized due to a direct or indirect call
687
+ * to [recompose](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#function-recompose), if this results in some change to the widget's rendered DOM elements.
688
+ */
689
+ onRecompose? : (() => void)|string
690
+ /**
691
+ * Fired when the encapsulating element of a Widget resizes *only when [monitorResize](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-monitorResize) is `true`*.
692
+ * @param {object} event Event object
693
+ * @param {Core.widget.Widget} event.source This Widget
694
+ * @param {number} event.width The new width
695
+ * @param {number} event.height The new height
696
+ * @param {number} event.oldWidth The old width
697
+ * @param {number} event.oldHeight The old height
698
+ */
699
+ onResize? : ((event: { source: Widget, width: number, height: number, oldWidth: number, oldHeight: number }) => void)|string
700
+ /**
701
+ * Triggered after a widget is shown.
702
+ * @param {object} event Event object
703
+ * @param {Core.widget.Widget} event.source The widget
704
+ */
705
+ onShow? : ((event: { source: Widget }) => void)|string
706
+ /**
707
+ * Fires when the button is toggled via a UI interaction (the [pressed](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#property-pressed) state is changed). If the button is part of a
708
+ * [toggleGroup](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#config-toggleGroup) and you need to process the pressed button only, consider using
709
+ * [click](https://bryntum.com/products/scheduler/docs/api/Core/widget/Button#event-click) event or [action](#Core/widget/Button#event-action) event.
710
+ * @param {object} event Event object
711
+ * @param {Core.widget.Button} event.source Toggled button
712
+ * @param {boolean} event.pressed New pressed state
713
+ * @param {boolean} event.userAction `true` if the toggle was triggered by a user action (click), `false` if it was triggered programmatically.
714
+ * @param {Event} event.domEvent The original DOM event that triggered the action, if any. Using the `pointerType` property of this event can help determine if it was a mouse, touch or pen action.
715
+ */
716
+ onToggle? : ((event: { source: Button, pressed: boolean, userAction: boolean, domEvent: Event }) => void)|string
717
+
718
+ }
719
+
720
+ export class BryntumButton extends React.Component<BryntumButtonProps> {
721
+
722
+ static instanceClass = Button;
723
+
724
+ static instanceName = 'Button';
725
+
726
+ processWidgetContent = processWidgetContent;
727
+
728
+ static configNames = [
729
+ 'adopt',
730
+ 'align',
731
+ 'anchor',
732
+ 'ariaDescription',
733
+ 'ariaLabel',
734
+ 'bubbleEvents',
735
+ 'centered',
736
+ 'color',
737
+ 'config',
738
+ 'constrainTo',
739
+ 'contentElementCls',
740
+ 'dataField',
741
+ 'defaultBindProperty',
742
+ 'detectCSSCompatibilityIssues',
743
+ 'dock',
744
+ 'draggable',
745
+ 'elementAttributes',
746
+ 'floating',
747
+ 'hideAnimation',
748
+ 'htmlCls',
749
+ 'ignoreParentReadOnly',
750
+ 'listeners',
751
+ 'localeClass',
752
+ 'localizable',
753
+ 'localizableProperties',
754
+ 'maskDefaults',
755
+ 'masked',
756
+ 'monitorResize',
757
+ 'owner',
758
+ 'positioned',
759
+ 'preventTooltipOnTouch',
760
+ 'relayStoreEvents',
761
+ 'ripple',
762
+ 'rootElement',
763
+ 'scrollAction',
764
+ 'showAnimation',
765
+ 'showTooltipWhenDisabled',
766
+ 'supportsPressedClick',
767
+ 'tab',
768
+ 'tag',
769
+ 'textAlign',
770
+ 'title',
771
+ 'type',
772
+ 'ui',
773
+ 'weight'
774
+ ];
775
+
776
+ static propertyConfigNames = [
777
+ 'alignSelf',
778
+ 'appendTo',
779
+ 'badge',
780
+ 'behaviorType',
781
+ 'callOnFunctions',
782
+ 'catchEventHandlerExceptions',
783
+ 'cls',
784
+ 'column',
785
+ 'content',
786
+ 'dataset',
787
+ 'disabled',
788
+ 'extraData',
789
+ 'flex',
790
+ 'height',
791
+ 'hidden',
792
+ 'href',
793
+ 'html',
794
+ 'icon',
795
+ 'iconAlign',
796
+ 'id',
797
+ 'insertBefore',
798
+ 'insertFirst',
799
+ 'keyMap',
800
+ 'margin',
801
+ 'maxHeight',
802
+ 'maximizeOnMobile',
803
+ 'maxWidth',
804
+ 'menu',
805
+ 'menuIcon',
806
+ 'minHeight',
807
+ 'minWidth',
808
+ 'onAction',
809
+ 'onBeforeDestroy',
810
+ 'onBeforeHide',
811
+ 'onBeforeShow',
812
+ 'onBeforeShowMenu',
813
+ 'onBeforeToggle',
814
+ 'onCatchAll',
815
+ 'onClick',
816
+ 'onDestroy',
817
+ 'onElementCreated',
818
+ 'onFocusIn',
819
+ 'onFocusOut',
820
+ 'onHide',
821
+ 'onPaint',
822
+ 'onReadOnly',
823
+ 'onRecompose',
824
+ 'onResize',
825
+ 'onShow',
826
+ 'onToggle',
827
+ 'pressed',
828
+ 'pressedCls',
829
+ 'pressedIcon',
830
+ 'readOnly',
831
+ 'rendition',
832
+ 'rtl',
833
+ 'scrollable',
834
+ 'span',
835
+ 'split',
836
+ 'tabIndex',
837
+ 'target',
838
+ 'text',
839
+ 'toggleable',
840
+ 'toggleGroup',
841
+ 'tooltip',
842
+ 'width',
843
+ 'x',
844
+ 'y'
845
+ ];
846
+
847
+ static propertyNames = [
848
+ 'anchorSize',
849
+ 'focusVisible',
850
+ 'parent'
851
+ ];
852
+
853
+ // Component instance
854
+ instance!: Button;
855
+
856
+ // Component element
857
+ element! : HTMLElement;
858
+
859
+ componentDidMount(): void {
860
+ this.instance = createWidget(this);
861
+ }
862
+
863
+ componentWillUnmount(): void {
864
+ // @ts-ignore
865
+ this.instance?.destroy?.();
866
+ }
867
+
868
+ /**
869
+ * Component about to be updated, from changing a prop using state.
870
+ * React to it depending on what changed and prevent react from re-rendering our component.
871
+ * @param nextProps
872
+ * @param nextState
873
+ * @returns {boolean}
874
+ */
875
+ shouldComponentUpdate(nextProps: Readonly<BryntumButtonProps>, nextState: Readonly<{}>): boolean {
876
+ return shouldComponentUpdate(this, nextProps, nextState);
877
+ }
878
+
879
+ render(): React.ReactNode {
880
+
881
+ const className = `b-react-button-container`;
882
+ return (
883
+ <div className={className} ref={(element) => (this.element = element!)}></div>
884
+ );
885
+
886
+ }
887
+ }