@bryntum/scheduler-react-thin 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 (56) hide show
  1. package/README.md +52 -0
  2. package/lib/BryntumEventColorField.d.ts +232 -0
  3. package/lib/BryntumEventColorField.js +169 -0
  4. package/lib/BryntumEventColorField.js.map +1 -0
  5. package/lib/BryntumProjectCombo.d.ts +268 -0
  6. package/lib/BryntumProjectCombo.js +203 -0
  7. package/lib/BryntumProjectCombo.js.map +1 -0
  8. package/lib/BryntumResourceCombo.d.ts +268 -0
  9. package/lib/BryntumResourceCombo.js +203 -0
  10. package/lib/BryntumResourceCombo.js.map +1 -0
  11. package/lib/BryntumResourceFilter.d.ts +215 -0
  12. package/lib/BryntumResourceFilter.js +154 -0
  13. package/lib/BryntumResourceFilter.js.map +1 -0
  14. package/lib/BryntumScheduler.d.ts +2039 -0
  15. package/lib/BryntumScheduler.js +642 -0
  16. package/lib/BryntumScheduler.js.map +1 -0
  17. package/lib/BryntumSchedulerBase.d.ts +2038 -0
  18. package/lib/BryntumSchedulerBase.js +641 -0
  19. package/lib/BryntumSchedulerBase.js.map +1 -0
  20. package/lib/BryntumSchedulerDatePicker.d.ts +314 -0
  21. package/lib/BryntumSchedulerDatePicker.js +216 -0
  22. package/lib/BryntumSchedulerDatePicker.js.map +1 -0
  23. package/lib/BryntumSchedulerProjectModel.d.ts +91 -0
  24. package/lib/BryntumSchedulerProjectModel.js +98 -0
  25. package/lib/BryntumSchedulerProjectModel.js.map +1 -0
  26. package/lib/BryntumTimelineHistogram.d.ts +1185 -0
  27. package/lib/BryntumTimelineHistogram.js +448 -0
  28. package/lib/BryntumTimelineHistogram.js.map +1 -0
  29. package/lib/BryntumUndoRedo.d.ts +190 -0
  30. package/lib/BryntumUndoRedo.js +152 -0
  31. package/lib/BryntumUndoRedo.js.map +1 -0
  32. package/lib/BryntumViewPresetCombo.d.ts +216 -0
  33. package/lib/BryntumViewPresetCombo.js +158 -0
  34. package/lib/BryntumViewPresetCombo.js.map +1 -0
  35. package/lib/WrapperHelper.d.ts +26 -0
  36. package/lib/WrapperHelper.js +569 -0
  37. package/lib/WrapperHelper.js.map +1 -0
  38. package/lib/index.d.ts +11 -0
  39. package/lib/index.js +12 -0
  40. package/lib/index.js.map +1 -0
  41. package/license.pdf +0 -0
  42. package/licenses.md +310 -0
  43. package/package.json +25 -0
  44. package/src/BryntumEventColorField.tsx +996 -0
  45. package/src/BryntumProjectCombo.tsx +1233 -0
  46. package/src/BryntumResourceCombo.tsx +1236 -0
  47. package/src/BryntumResourceFilter.tsx +931 -0
  48. package/src/BryntumScheduler.tsx +5184 -0
  49. package/src/BryntumSchedulerBase.tsx +5182 -0
  50. package/src/BryntumSchedulerDatePicker.tsx +1365 -0
  51. package/src/BryntumSchedulerProjectModel.tsx +424 -0
  52. package/src/BryntumTimelineHistogram.tsx +3427 -0
  53. package/src/BryntumUndoRedo.tsx +886 -0
  54. package/src/BryntumViewPresetCombo.tsx +915 -0
  55. package/src/WrapperHelper.tsx +1125 -0
  56. package/src/index.ts +15 -0
@@ -0,0 +1,915 @@
1
+ /**
2
+ * React wrapper for Bryntum ViewPresetCombo
3
+ */
4
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
5
+ import React, { RefObject } from 'react';
6
+ import { AlignSpec, Base, Combo, ComboModel, Duration, DurationConfig, Field, KeyMapConfig, List, ListConfig, MaskConfig, Model, Rectangle, TabConfig, TooltipConfig, Widget } from '@bryntum/core-thin';
7
+ import { TimelineBase, ViewPresetCombo, ViewPresetComboListeners } from '@bryntum/scheduler-thin';
8
+
9
+ import { createWidget, shouldComponentUpdate, processWidgetContent } from './WrapperHelper.js';
10
+
11
+ export type BryntumViewPresetComboProps = {
12
+ // Configs
13
+ /**
14
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
15
+ * ...
16
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-align)
17
+ */
18
+ align? : AlignSpec|string
19
+ /**
20
+ * 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
21
+ * flexbox layout. This config allows you to set this widget's
22
+ * [align-self](https://developer.mozilla.org/en-US/docs/Web/CSS/align-self) style.
23
+ */
24
+ alignSelf? : string
25
+ /**
26
+ * *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).*
27
+ * `true` to show a connector arrow pointing to the align target.
28
+ */
29
+ anchor? : boolean
30
+ /**
31
+ * Element (or the id of an element) to append this widget's element to. Can be configured, or set once at
32
+ * runtime. To access the element of a rendered widget, see [element](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-element).
33
+ */
34
+ appendTo? : HTMLElement|string
35
+ /**
36
+ * A localizable string (May contain `'L{}'` tokens which resolve in the locale file) to inject
37
+ * into an element which will be linked using the `aria-describedby` attribute.
38
+ * ...
39
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-ariaDescription)
40
+ */
41
+ ariaDescription? : string
42
+ /**
43
+ * A localizable string (May contain `'L{}'` tokens which resolve in the locale file) to inject as
44
+ * the `aria-label` attribute.
45
+ * ...
46
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-ariaLabel)
47
+ */
48
+ ariaLabel? : string
49
+ /**
50
+ * Initial text to show in badge.
51
+ */
52
+ badge? : string
53
+ /**
54
+ * An object where property names with a truthy value indicate which events should bubble up the ownership
55
+ * hierarchy when triggered.
56
+ * ...
57
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-bubbleEvents)
58
+ */
59
+ bubbleEvents? : object
60
+ /**
61
+ * Enable caching of the last retrieved result until the timeout is reached.
62
+ * ...
63
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-cacheLastResult)
64
+ */
65
+ cacheLastResult? : number|string|Duration|DurationConfig
66
+ /**
67
+ * Set to `false` to not call onXXX method names (e.g. `onShow`, `onClick`), as an easy way to listen for events.
68
+ * ...
69
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-callOnFunctions)
70
+ */
71
+ callOnFunctions? : boolean
72
+ /**
73
+ * By default, if an event handler throws an exception, the error propagates up the stack and the
74
+ * application state is undefined. Code which follows the event handler will *not* be executed.
75
+ * ...
76
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-catchEventHandlerExceptions)
77
+ */
78
+ catchEventHandlerExceptions? : boolean
79
+ /**
80
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
81
+ * Set to `true` to centre the Widget in browser viewport space.
82
+ */
83
+ centered? : boolean
84
+ /**
85
+ * Specify `false` to not clear value typed to a multiselect combo when an item is selected.
86
+ */
87
+ clearTextOnSelection? : boolean
88
+ /**
89
+ * Set to `true` to clear this field when user empties the input element
90
+ */
91
+ clearWhenInputEmpty? : boolean
92
+ /**
93
+ * If not added to a toolbar, provide a Scheduler, SchedulerPro or Gantt component instance to which the
94
+ * ViewPresetCombo should be connected.
95
+ */
96
+ client? : TimelineBase
97
+ /**
98
+ * Custom CSS classes to add to element.
99
+ * May be specified as a space separated string, or as an object in which property names
100
+ * with truthy values are used as the class names:
101
+ * ...
102
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-cls)
103
+ */
104
+ cls? : string|object
105
+ /**
106
+ * Applies the specified color to the widget, by setting the `--b-primary` CSS variable in the widgets
107
+ * `style` block.
108
+ * ...
109
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-color)
110
+ */
111
+ color? : string
112
+ /**
113
+ * Programmatic control over which column to start in when used in a grid layout.
114
+ */
115
+ column? : number
116
+ config? : object
117
+ /**
118
+ * *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).*
119
+ * Element, Widget or Rectangle to which this Widget is constrained.
120
+ */
121
+ constrainTo? : HTMLElement|Widget|Rectangle
122
+ /**
123
+ * Custom CSS classes to add to the [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement).
124
+ * May be specified as a space separated string, or as an object in which property names
125
+ * with truthy values are used as the class names:
126
+ * ...
127
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-contentElementCls)
128
+ */
129
+ contentElementCls? : string|object
130
+ /**
131
+ * When this Widget configuration is used in the Grid's RowExpander feature's `widget` config, provide the
132
+ * field on the expanded record to use for populating this widget's store (if applicable)
133
+ */
134
+ dataField? : string
135
+ /**
136
+ * The name of the property to set when a single value is to be applied to this Widget. Such as when used
137
+ * in a grid WidgetColumn, this is the property to which the column's `field` is applied.
138
+ */
139
+ defaultBindProperty? : string
140
+ /**
141
+ * Check for CSS compatibility issues when upgrading to v7. Performs the following checks:
142
+ * ...
143
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-detectCSSCompatibilityIssues)
144
+ */
145
+ detectCSSCompatibilityIssues? : boolean
146
+ /**
147
+ * 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
148
+ * cannot be focused, uses a different rendition (usually greyish) and does not allow selecting its value.
149
+ * ...
150
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-disabled)
151
+ */
152
+ disabled? : boolean|'inert'
153
+ /**
154
+ * Controls the placement of this widget when it is added to a [panel's ](https://bryntum.com/products/scheduler/docs/api/Core/widget/Panel)
155
+ * [strips collection](https://bryntum.com/products/scheduler/docs/api/Core/widget/Panel#config-strips). Typical values for this config are `'top'`,
156
+ * `'bottom'`, `'left'`, or `'right'`, which cause the widget to be placed on that side of the panel's
157
+ * body. Such widgets are called "edge strips".
158
+ * ...
159
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-dock)
160
+ */
161
+ dock? : 'top'|'bottom'|'left'|'right'|'start'|'end'|'header'|'pre-header'|object
162
+ /**
163
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
164
+ * Set to `true` to be able to drag a widget freely on the page. Or set to an object with a ´handleSelector´
165
+ * property which controls when a drag should start.
166
+ * ...
167
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-draggable)
168
+ */
169
+ draggable? : boolean|{
170
+ handleSelector?: string
171
+ }
172
+ /**
173
+ * User can edit text in text field (otherwise only pick from attached picker)
174
+ */
175
+ editable? : boolean
176
+ /**
177
+ * An object specifying attributes to assign to the root element of this widget.
178
+ * Set `null` value to attribute to remove it.
179
+ * ...
180
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-elementAttributes)
181
+ */
182
+ elementAttributes? : Record<string, string|null>
183
+ extraData? : any
184
+ /**
185
+ * 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
186
+ * flexbox layout. This config allows you to set this widget's
187
+ * [flex](https://developer.mozilla.org/en-US/docs/Web/CSS/flex) style.
188
+ * This may be configured as a single number or a `&lt;flex-grow&gt; &lt;flex-shrink&gt; &lt;flex-basis&gt;` format string.
189
+ * numeric-only values are interpreted as the `flex-grow` value.
190
+ */
191
+ flex? : number|string
192
+ /**
193
+ * Set to `true` to move the widget out of the document flow and position it
194
+ * absolutely in browser viewport space.
195
+ */
196
+ floating? : boolean
197
+ /**
198
+ * Widget's height, used to set element `style.height`. Either specify a valid height string or a number,
199
+ * which will get 'px' appended. We recommend using CSS as the primary way to control height, but in some
200
+ * cases this config is convenient.
201
+ */
202
+ height? : string|number
203
+ /**
204
+ * Configure with true to make widget initially hidden.
205
+ */
206
+ hidden? : boolean
207
+ /**
208
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
209
+ * ...
210
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-hideAnimation)
211
+ */
212
+ hideAnimation? : boolean|object
213
+ /**
214
+ * By default, the picker is hidden on selection in single select mode, and
215
+ * remains to allow more selections when [multiSelect](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-multiSelect) is `true`.
216
+ * Setting this to a `Boolean` value can override that default.
217
+ */
218
+ hidePickerOnSelect? : boolean
219
+ /**
220
+ * An optional string to display inside the input field as an overlay. This can be useful for displaying
221
+ * a field's units.
222
+ * ...
223
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-hint)
224
+ * @param {object} data A data object
225
+ * @param {Core.widget.Field} data.source A reference to the field instance
226
+ * @param {any} data.value The current value of the field
227
+ * @returns {string}
228
+ */
229
+ hint? : string|((data: { source: Field, value: any }) => string)
230
+ /**
231
+ * This config is similar to [hint](https://bryntum.com/products/scheduler/docs/api/Core/widget/Field#config-hint) except that this config is used to display HTML content.
232
+ * Since this can allow malicious content to be executed, be sure not to include user-entered data or to
233
+ * encode such data (see [encodeHtml](https://bryntum.com/products/scheduler/docs/api/Core/helper/StringHelper#function-encodeHtml-static)).
234
+ * ...
235
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-hintHtml)
236
+ * @param {object} data A data object
237
+ * @param {Core.widget.Field} data.source A reference to the field instance
238
+ * @param {any} data.value The current value of the field
239
+ * @returns {string}
240
+ */
241
+ hintHtml? : string|((data: { source: Field, value: any }) => string)
242
+ /**
243
+ * Widget id, if not specified one will be generated. Also used for lookups through Widget.getById
244
+ */
245
+ id? : string
246
+ /**
247
+ * Determines if the widgets read-only state should be controlled by its parent.
248
+ * ...
249
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-ignoreParentReadOnly)
250
+ */
251
+ ignoreParentReadOnly? : boolean
252
+ /**
253
+ * Text alignment for the input field.
254
+ */
255
+ inputAlign? : string
256
+ /**
257
+ * Sets custom attributes of the underlying input element. For more information, please refer to
258
+ * [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes)
259
+ */
260
+ inputAttributes? : Record<string, string>
261
+ /**
262
+ * If you need to use something else than a default `input` element, as the input element, provide the tag
263
+ * name here. Please note that this is used for advanced usage only, for example when using WebComponents
264
+ * (custom elements), and that the configured element must fulfil the same contract as a regular input
265
+ * element.
266
+ */
267
+ inputTag? : string
268
+ /**
269
+ * The width to apply to the `.b-field-inner` element, which encompasses the `input` element and any
270
+ * triggers. If a number is specified, `px` will be used.
271
+ */
272
+ inputWidth? : string|number
273
+ /**
274
+ * 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.
275
+ */
276
+ insertBefore? : HTMLElement|string
277
+ /**
278
+ * 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.
279
+ */
280
+ insertFirst? : HTMLElement|string
281
+ /**
282
+ * An object whose keys are the [key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key) name
283
+ * and optional modifier prefixes: `'Ctrl+'`, `'Alt+'`, `'Meta+'`, and `'Shift+'` (case-insensitive). The values
284
+ * are the name of the instance method to call when the keystroke is received.
285
+ * ...
286
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-keyMap)
287
+ */
288
+ keyMap? : Record<string, KeyMapConfig>
289
+ /**
290
+ * Label, prepended to field
291
+ */
292
+ label? : string
293
+ /**
294
+ * CSS class name or class names to add to any configured [label](https://bryntum.com/products/scheduler/docs/api/Core/widget/mixin/Labelable#config-label)
295
+ */
296
+ labelCls? : string|object
297
+ /**
298
+ * Label position, either 'before' the field or 'above' the field
299
+ * ...
300
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-labelPosition)
301
+ */
302
+ labelPosition? : 'before'|'above'|null
303
+ /**
304
+ * The labels to add either before or after the input field.
305
+ * Each label may have the following properties:
306
+ * ...
307
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-labels)
308
+ */
309
+ labels? : object[]
310
+ /**
311
+ * The width to apply to the `&lt;label&gt;` element. If a number is specified, `px` will be used.
312
+ */
313
+ labelWidth? : string|number
314
+ /**
315
+ * CSS class to add to picker
316
+ */
317
+ listCls? : string
318
+ /**
319
+ * The listener set for this object.
320
+ * ...
321
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-listeners)
322
+ */
323
+ listeners? : ViewPresetComboListeners
324
+ /**
325
+ * Template string used to render the list items in the dropdown list
326
+ * ...
327
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-listItemTpl)
328
+ * @param {Core.data.Model} record The record representing the item being rendered
329
+ * @returns {string,void}
330
+ */
331
+ listItemTpl? : (record: Model|ComboModel) => string|void
332
+ /**
333
+ * A class translations of which are used for translating this entity.
334
+ * This is often used when translations of an item are defined on its container class.
335
+ * For example:
336
+ * ...
337
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-localeClass)
338
+ */
339
+ localeClass? : typeof Base
340
+ /**
341
+ * Set to `false` to disable localization of this object.
342
+ */
343
+ localizable? : boolean
344
+ /**
345
+ * List of properties which values should be translated automatically upon a locale applying.
346
+ * In case there is a need to localize not typical value (not a String value or a field with re-defined setter/getter),
347
+ * you could use 'localeKey' meta configuration.
348
+ * Example:
349
+ * ...
350
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-localizableProperties)
351
+ */
352
+ localizableProperties? : string[]
353
+ /**
354
+ * Widget's margin. This may be configured as a single number or a `TRBL` format string.
355
+ * numeric-only values are interpreted as pixels.
356
+ */
357
+ margin? : number|string
358
+ /**
359
+ * This config object contains the defaults for the [Mask](https://bryntum.com/products/scheduler/docs/api/Core/widget/Mask) created for the
360
+ * [masked](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-masked) config. Any properties specified in the `masked` config will override these
361
+ * values.
362
+ */
363
+ maskDefaults? : MaskConfig
364
+ /**
365
+ * Set to `true` to apply the default mask to the widget. Alternatively, this can be the mask message or a
366
+ * [Mask](https://bryntum.com/products/scheduler/docs/api/Core/widget/Mask) config object.
367
+ */
368
+ masked? : boolean|string|MaskConfig
369
+ /**
370
+ * The element's maxHeight. Can be either a String or a Number (which will have 'px' appended). Note that
371
+ * like [height](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-height), *reading* the value will return the numeric value in pixels.
372
+ */
373
+ maxHeight? : string|number
374
+ /**
375
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
376
+ * ...
377
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-maximizeOnMobile)
378
+ */
379
+ maximizeOnMobile? : number|string
380
+ /**
381
+ * The elements maxWidth. Can be either a String or a Number (which will have 'px' appended). Note that
382
+ * like [width](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-width), *reading* the value will return the numeric value in pixels.
383
+ */
384
+ maxWidth? : string|number
385
+ /**
386
+ * The element's minHeight. Can be either a String or a Number (which will have 'px' appended). Note that
387
+ * like [height](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-height), *reading* the value will return the numeric value in pixels.
388
+ */
389
+ minHeight? : string|number
390
+ /**
391
+ * The elements minWidth. Can be either a String or a Number (which will have 'px' appended). Note that
392
+ * like [width](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-width), *reading* the value will return the numeric value in pixels.
393
+ */
394
+ minWidth? : string|number
395
+ /**
396
+ * When this is configured as `true` a [ResizeObserver](https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver)
397
+ * is used to monitor this element for size changes caused by either style manipulation, or by CSS
398
+ * layout.
399
+ * ...
400
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-monitorResize)
401
+ */
402
+ monitorResize? : boolean|{
403
+ immediate?: boolean
404
+ }
405
+ /**
406
+ * Name of the field which is used as a key to get/set values from/to the field.
407
+ * Used prior to [ref](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-ref) and [id](#Core/widget/Widget#config-id) in
408
+ * [Container.values](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container#property-values).
409
+ * ...
410
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-name)
411
+ */
412
+ name? : string
413
+ /**
414
+ * This implies that the picker will display an anchor pointer, but also means that the picker will align closer
415
+ * to the input field so that the pointer pierces the [pickerAlignElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-pickerAlignElement)
416
+ */
417
+ overlayAnchor? : boolean
418
+ /**
419
+ * The owning Widget of this Widget. If this Widget is directly contained (that is, it is one of the
420
+ * [items](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container#property-items) of a Container), this config will be ignored. In this case
421
+ * the owner is <strong>always</strong> the encapsulating Container.
422
+ * ...
423
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-owner)
424
+ */
425
+ owner? : Widget|any
426
+ /**
427
+ * Width of picker, defaults to this combo's [pickerAlignElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-pickerAlignElement) width
428
+ */
429
+ pickerWidth? : number|string
430
+ /**
431
+ * 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
432
+ * not participate in the standard layout of that widget, and must be positioned relatively to that
433
+ * widget's [contentElement](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-contentElement).
434
+ * ...
435
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-positioned)
436
+ */
437
+ positioned? : boolean
438
+ /**
439
+ * An array containing string [ViewPreset](https://bryntum.com/products/scheduler/docs/api/Scheduler/preset/ViewPreset) ids available for selection. The specified
440
+ * presets must be [available](https://bryntum.com/products/scheduler/docs/api/Scheduler/view/mixin/TimelineViewPresets#config-presets) for the
441
+ * [client](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-client) (Scheduler, SchedulerPro or Gantt) for it to work properly. The selectable presets
442
+ * will be arranged in the order provided here.
443
+ */
444
+ presets? : any[]
445
+ /**
446
+ * Prevent tooltip from being displayed on touch devices. Useful for example for buttons that display a
447
+ * menu on click etc, since the tooltip would be displayed at the same time.
448
+ */
449
+ preventTooltipOnTouch? : boolean
450
+ /**
451
+ * Makes the field unmodifiable by user action. The input area is not editable, and triggers
452
+ * are unresponsive.
453
+ * ...
454
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-readOnly)
455
+ */
456
+ readOnly? : boolean
457
+ relayStoreEvents? : boolean
458
+ /**
459
+ * Predefined style to use for the field. Possible values are:
460
+ * ...
461
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-rendition)
462
+ */
463
+ rendition? : 'outlined'|'filled'|string
464
+ /**
465
+ * Configure as `true` to have the component display a translucent ripple when its
466
+ * [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
467
+ * current theme supports ripples</em>. Out of the box, only the Material theme supports ripples.
468
+ * ...
469
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-ripple)
470
+ */
471
+ ripple? : boolean|{
472
+ delegate?: string
473
+ color?: string
474
+ radius?: number
475
+ clip?: string
476
+ }
477
+ /**
478
+ * 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`
479
+ */
480
+ rootElement? : ShadowRoot|HTMLElement
481
+ /**
482
+ * This may be configured as `true` to make the widget's element use the `direction:rtl` style.
483
+ * ...
484
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-rtl)
485
+ */
486
+ rtl? : boolean
487
+ /**
488
+ * Defines what to do if document is scrolled while Widget is visible (only relevant when floating is set to `true`).
489
+ * Valid values: ´null´: do nothing, ´hide´: hide the widget or ´realign´: realign to the target if possible.
490
+ */
491
+ scrollAction? : 'hide'|'realign'|null
492
+ /**
493
+ * *Only valid if this Widget is [floating](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#config-floating).*
494
+ * ...
495
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-showAnimation)
496
+ */
497
+ showAnimation? : boolean|object
498
+ /**
499
+ * `true` to automatically display a * after the label for this field when it is [required](https://bryntum.com/products/scheduler/docs/api/Core/widget/Field#property-required).
500
+ */
501
+ showRequiredIndicator? : string
502
+ /**
503
+ * 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)
504
+ */
505
+ showTooltipWhenDisabled? : boolean
506
+ /**
507
+ * Set to `true`, completely bypasses validation logic (could be userful if your field is not `editable`
508
+ * to the user).
509
+ */
510
+ skipValidation? : boolean
511
+ /**
512
+ * Programmatic control over how many columns to span when used in a grid layout.
513
+ */
514
+ span? : number
515
+ /**
516
+ * 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
517
+ * [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
518
+ * this widget:
519
+ * ...
520
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-tab)
521
+ */
522
+ tab? : boolean|TabConfig
523
+ /**
524
+ * The tab index of the input field or fields, or `null` for natural tab order (recommended). Setting to `0`
525
+ * is equivalent to natural tab order, but is unnecessary for fields since they are naturally tabbable
526
+ * (i.e., accessible via the TAB key). Setting to `-1` disables tabbability but allows for focus to be set
527
+ * to the element programmatically.
528
+ * ...
529
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-tabIndex)
530
+ */
531
+ tabIndex? : number
532
+ /**
533
+ * Text alignment: 'left', 'center' or 'right'. Also accepts direction neutral 'start' and 'end'.
534
+ * ...
535
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-textAlign)
536
+ */
537
+ textAlign? : 'left'|'center'|'right'|'start'|'end'
538
+ type? : 'viewpresetcombo'
539
+ /**
540
+ * Custom CSS class name suffixes to apply to the elements rendered by this widget. This may be specified
541
+ * as a space separated string, an array of strings, or as an object in which property names with truthy
542
+ * values are used as the class names.
543
+ * ...
544
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-ui)
545
+ */
546
+ ui? : string|object
547
+ /**
548
+ * As default, a preset change by the ViewPresetCombo will result in that the `startDate` will be calculated to
549
+ * the beginning of the [mainUnit](https://bryntum.com/products/scheduler/docs/api/Scheduler/preset/ViewPreset#field-mainUnit) of the
550
+ * [viewportCenterDate](https://bryntum.com/products/scheduler/docs/api/Scheduler/view/mixin/TimelineDateMapper#property-viewportCenterDate). If the ViewPreset has a
551
+ * [start](https://bryntum.com/products/scheduler/docs/api/Scheduler/preset/ViewPreset#field-start) configured, this will be added to the calculation. The
552
+ * `endDate` will then be calculated by adding the ViewPreset's
553
+ * [defaultSpan](https://bryntum.com/products/scheduler/docs/api/Scheduler/preset/ViewPreset#field-defaultSpan) to the `startDate`.
554
+ * ...
555
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-useFixedDuration)
556
+ */
557
+ useFixedDuration? : boolean
558
+ /**
559
+ * A widgets weight determines its position among siblings when added to a [Container](https://bryntum.com/products/scheduler/docs/api/Core/widget/Container).
560
+ * Higher weights go further down.
561
+ */
562
+ weight? : number
563
+ /**
564
+ * Widget's width, used to set element `style.width`. Either specify a valid width string or a number, which
565
+ * will get 'px' appended. We recommend using CSS as the primary way to control width, but in some cases
566
+ * this config is convenient.
567
+ */
568
+ width? : string|number
569
+ /**
570
+ * The x position for the widget.
571
+ * ...
572
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-x)
573
+ */
574
+ x? : number
575
+ /**
576
+ * The y position for the widget.
577
+ * ...
578
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#config-y)
579
+ */
580
+ y? : number
581
+
582
+ // Events
583
+ /**
584
+ * The default action was performed (an item in the list was selected)
585
+ * @param {object} event Event object
586
+ * @param {Core.widget.Combo} event.source The combo
587
+ * @param {any} event.value The [value](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-valueField) of the selected record
588
+ * @param {Core.data.Model} event.record Selected record
589
+ * @param {Core.data.Model[]} event.records Selected records as an array if [multiSelect](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-multiSelect) is `true`
590
+ * @param {boolean} event.userAction `true` if the value change is due to user interaction
591
+ */
592
+ onAction? : ((event: { source: Combo, value: any, record: Model, records: Model[], userAction: boolean }) => void)|string
593
+ /**
594
+ * Fires before an object is destroyed.
595
+ * @param {object} event Event object
596
+ * @param {Core.Base} event.source The Object that is being destroyed.
597
+ */
598
+ onBeforeDestroy? : ((event: { source: Base }) => void)|string
599
+ /**
600
+ * Triggered before a widget is hidden. Return `false` to prevent the action.
601
+ * @param {object} event Event object
602
+ * @param {Core.widget.Widget} event.source The widget being hidden.
603
+ */
604
+ onBeforeHide? : ((event: { source: Widget }) => Promise<boolean>|boolean|void)|string
605
+ /**
606
+ * Triggered before a widget is shown. Return `false` to prevent the action.
607
+ * @param {object} event Event object
608
+ * @param {Core.widget.Widget,any} event.source The widget being shown
609
+ */
610
+ onBeforeShow? : ((event: { source: Widget|any }) => Promise<boolean>|boolean|void)|string
611
+ /**
612
+ * Fires when any other event is fired from the object.
613
+ * ...
614
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#event-catchAll)
615
+ * @param {object} event Event object
616
+ * @param {{[key: string]: any, type: string}} event.event The Object that contains event details
617
+ * @param {string} event.event.type The type of the event which is caught by the listener
618
+ */
619
+ onCatchAll? : ((event: {[key: string]: any, type: string}) => void)|string
620
+ /**
621
+ * Fired when this field's value changes.
622
+ * @param {object} event Event object
623
+ * @param {Core.widget.Field,any} event.source This Field
624
+ * @param {string,number,boolean,any} event.value This field's value
625
+ * @param {string,number,boolean,any} event.oldValue This field's previous value
626
+ * @param {boolean} event.valid True if this field is in a valid state
627
+ * @param {Event} event.event The triggering DOM event if any
628
+ * @param {boolean} event.userAction Triggered by user taking an action (`true`) or by setting a value (`false`)
629
+ * @param {boolean} event.checked
630
+ */
631
+ onChange? : ((event: { source: Field|any, value: string|number|boolean|any, oldValue: string|number|boolean|any, valid: boolean, event: Event, userAction: boolean, checked: boolean }) => void)|string
632
+ /**
633
+ * Fired when this field is [cleared](https://bryntum.com/products/scheduler/docs/api/Core/widget/Field#function-clear).
634
+ * ...
635
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#event-clear)
636
+ * @param {object} event Event object
637
+ * @param {Core.widget.Field,any} event.source This Field
638
+ */
639
+ onClear? : ((event: { source: Field|any }) => void)|string
640
+ /**
641
+ * Fires when an object is destroyed.
642
+ * @param {object} event Event object
643
+ * @param {Core.Base} event.source The Object that is being destroyed.
644
+ */
645
+ onDestroy? : ((event: { source: Base }) => void)|string
646
+ /**
647
+ * Triggered when a widget's [element](https://bryntum.com/products/scheduler/docs/api/Core/widget/Widget#property-element) is available.
648
+ * @param {object} event Event object
649
+ * @param {HTMLElement} event.element The Widget's element.
650
+ */
651
+ onElementCreated? : ((event: { element: HTMLElement }) => void)|string
652
+ /**
653
+ * Fired when focus enters this Widget.
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
+ onFocusIn? : ((event: { source: Widget, fromElement: HTMLElement, toElement: HTMLElement, fromWidget: Widget, toWidget: Widget, backwards: boolean }) => void)|string
663
+ /**
664
+ * Fired when focus exits this Widget's ownership tree. This is different from a `blur` event.
665
+ * focus moving from within this Widget's ownership tree, even if there are floating widgets
666
+ * will not trigger this event. This is when focus exits this widget completely.
667
+ * @param {object} event Event object
668
+ * @param {Core.widget.Widget} event.source This Widget
669
+ * @param {HTMLElement} event.fromElement The element which lost focus.
670
+ * @param {HTMLElement} event.toElement The element which gained focus.
671
+ * @param {Core.widget.Widget} event.fromWidget The widget which lost focus.
672
+ * @param {Core.widget.Widget} event.toWidget The widget which gained focus.
673
+ * @param {boolean} event.backwards `true` if the `toElement` is before the `fromElement` in document order.
674
+ */
675
+ onFocusOut? : ((event: { source: Widget, fromElement: HTMLElement, toElement: HTMLElement, fromWidget: Widget, toWidget: Widget, backwards: boolean }) => void)|string
676
+ /**
677
+ * Triggered after a widget was hidden
678
+ * @param {object} event Event object
679
+ * @param {Core.widget.Widget} event.source The widget
680
+ */
681
+ onHide? : ((event: { source: Widget }) => void)|string
682
+ /**
683
+ * Triggered when a widget which had been in a non-visible state for any reason
684
+ * achieves visibility.
685
+ * ...
686
+ * [View online docs...](https://bryntum.com/products/scheduler/docs/api/Scheduler/widget/ViewPresetCombo#event-paint)
687
+ * @param {object} event Event object
688
+ * @param {Core.widget.Widget} event.source The widget being painted.
689
+ * @param {boolean} event.firstPaint `true` if this is the first paint.
690
+ */
691
+ onPaint? : ((event: { source: Widget, firstPaint: boolean }) => void)|string
692
+ /**
693
+ * Fired when a Widget's read only state is toggled
694
+ * @param {object} event Event object
695
+ * @param {boolean} event.readOnly Read only or not
696
+ */
697
+ onReadOnly? : ((event: { readOnly: boolean }) => void)|string
698
+ /**
699
+ * This event is fired after a widget's elements have been synchronized due to a direct or indirect call
700
+ * 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.
701
+ */
702
+ onRecompose? : (() => void)|string
703
+ /**
704
+ * 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`*.
705
+ * @param {object} event Event object
706
+ * @param {Core.widget.Widget} event.source This Widget
707
+ * @param {number} event.width The new width
708
+ * @param {number} event.height The new height
709
+ * @param {number} event.oldWidth The old width
710
+ * @param {number} event.oldHeight The old height
711
+ */
712
+ onResize? : ((event: { source: Widget, width: number, height: number, oldWidth: number, oldHeight: number }) => void)|string
713
+ /**
714
+ * An item in the list was selected
715
+ * @param {object} event Event object
716
+ * @param {Core.widget.Combo} event.source The combo
717
+ * @param {Core.data.Model} event.record Selected record
718
+ * @param {Core.data.Model[]} event.records Selected records as an array if [multiSelect](https://bryntum.com/products/scheduler/docs/api/Core/widget/Combo#config-multiSelect) is `true`
719
+ * @param {boolean} event.userAction `true` if the value change is due to user interaction
720
+ */
721
+ onSelect? : ((event: { source: Combo, record: Model, records: Model[], userAction: boolean }) => void)|string
722
+ /**
723
+ * Triggered after a widget is shown.
724
+ * @param {object} event Event object
725
+ * @param {Core.widget.Widget} event.source The widget
726
+ */
727
+ onShow? : ((event: { source: Widget }) => void)|string
728
+ /**
729
+ * User clicked one of this field's [triggers](https://bryntum.com/products/scheduler/docs/api/Core/widget/Field#property-triggers)
730
+ * @param {object} event Event object
731
+ * @param {Core.widget.Field,any} event.source This field
732
+ * @param {Core.widget.Widget} event.trigger The trigger activated by click or touch tap.
733
+ */
734
+ onTrigger? : ((event: { source: Field|any, trigger: Widget }) => void)|string
735
+
736
+ }
737
+
738
+ export class BryntumViewPresetCombo extends React.Component<BryntumViewPresetComboProps> {
739
+
740
+ static instanceClass = ViewPresetCombo;
741
+
742
+ static instanceName = 'ViewPresetCombo';
743
+
744
+ processWidgetContent = processWidgetContent;
745
+
746
+ static configNames = [
747
+ 'align',
748
+ 'anchor',
749
+ 'ariaDescription',
750
+ 'ariaLabel',
751
+ 'bubbleEvents',
752
+ 'cacheLastResult',
753
+ 'centered',
754
+ 'clearTextOnSelection',
755
+ 'clearWhenInputEmpty',
756
+ 'client',
757
+ 'color',
758
+ 'config',
759
+ 'constrainTo',
760
+ 'contentElementCls',
761
+ 'dataField',
762
+ 'defaultBindProperty',
763
+ 'detectCSSCompatibilityIssues',
764
+ 'dock',
765
+ 'draggable',
766
+ 'elementAttributes',
767
+ 'floating',
768
+ 'hideAnimation',
769
+ 'hidePickerOnSelect',
770
+ 'hint',
771
+ 'hintHtml',
772
+ 'ignoreParentReadOnly',
773
+ 'inputAlign',
774
+ 'inputAttributes',
775
+ 'inputTag',
776
+ 'inputWidth',
777
+ 'labelCls',
778
+ 'labelPosition',
779
+ 'labels',
780
+ 'labelWidth',
781
+ 'listCls',
782
+ 'listeners',
783
+ 'listItemTpl',
784
+ 'localeClass',
785
+ 'localizable',
786
+ 'localizableProperties',
787
+ 'maskDefaults',
788
+ 'masked',
789
+ 'monitorResize',
790
+ 'name',
791
+ 'overlayAnchor',
792
+ 'owner',
793
+ 'pickerWidth',
794
+ 'positioned',
795
+ 'presets',
796
+ 'preventTooltipOnTouch',
797
+ 'relayStoreEvents',
798
+ 'ripple',
799
+ 'rootElement',
800
+ 'scrollAction',
801
+ 'showAnimation',
802
+ 'showTooltipWhenDisabled',
803
+ 'skipValidation',
804
+ 'tab',
805
+ 'tabIndex',
806
+ 'textAlign',
807
+ 'type',
808
+ 'ui',
809
+ 'useFixedDuration',
810
+ 'weight'
811
+ ];
812
+
813
+ static propertyConfigNames = [
814
+ 'alignSelf',
815
+ 'appendTo',
816
+ 'badge',
817
+ 'callOnFunctions',
818
+ 'catchEventHandlerExceptions',
819
+ 'cls',
820
+ 'column',
821
+ 'disabled',
822
+ 'editable',
823
+ 'extraData',
824
+ 'flex',
825
+ 'height',
826
+ 'hidden',
827
+ 'id',
828
+ 'insertBefore',
829
+ 'insertFirst',
830
+ 'keyMap',
831
+ 'label',
832
+ 'margin',
833
+ 'maxHeight',
834
+ 'maximizeOnMobile',
835
+ 'maxWidth',
836
+ 'minHeight',
837
+ 'minWidth',
838
+ 'onAction',
839
+ 'onBeforeDestroy',
840
+ 'onBeforeHide',
841
+ 'onBeforeShow',
842
+ 'onCatchAll',
843
+ 'onChange',
844
+ 'onClear',
845
+ 'onDestroy',
846
+ 'onElementCreated',
847
+ 'onFocusIn',
848
+ 'onFocusOut',
849
+ 'onHide',
850
+ 'onPaint',
851
+ 'onReadOnly',
852
+ 'onRecompose',
853
+ 'onResize',
854
+ 'onSelect',
855
+ 'onShow',
856
+ 'onTrigger',
857
+ 'readOnly',
858
+ 'rendition',
859
+ 'rtl',
860
+ 'showRequiredIndicator',
861
+ 'span',
862
+ 'width',
863
+ 'x',
864
+ 'y'
865
+ ];
866
+
867
+ static propertyNames = [
868
+ 'anchorSize',
869
+ 'focusVisible',
870
+ 'formula',
871
+ 'input',
872
+ 'multiSelect',
873
+ 'parent',
874
+ 'picker',
875
+ 'placeholder',
876
+ 'required',
877
+ 'tooltip',
878
+ 'value'
879
+ ];
880
+
881
+ // Component instance
882
+ instance!: ViewPresetCombo;
883
+
884
+ // Component element
885
+ element! : HTMLElement;
886
+
887
+ componentDidMount(): void {
888
+ this.instance = createWidget(this);
889
+ }
890
+
891
+ componentWillUnmount(): void {
892
+ // @ts-ignore
893
+ this.instance?.destroy?.();
894
+ }
895
+
896
+ /**
897
+ * Component about to be updated, from changing a prop using state.
898
+ * React to it depending on what changed and prevent react from re-rendering our component.
899
+ * @param nextProps
900
+ * @param nextState
901
+ * @returns {boolean}
902
+ */
903
+ shouldComponentUpdate(nextProps: Readonly<BryntumViewPresetComboProps>, nextState: Readonly<{}>): boolean {
904
+ return shouldComponentUpdate(this, nextProps, nextState);
905
+ }
906
+
907
+ render(): React.ReactNode {
908
+
909
+ const className = `b-react-view-preset-combo-container`;
910
+ return (
911
+ <div className={className} ref={(element) => (this.element = element!)}></div>
912
+ );
913
+
914
+ }
915
+ }