@bpmn-io/form-js-editor 1.6.0 → 1.6.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.
package/dist/index.cjs CHANGED
@@ -537,10 +537,10 @@ function invokeFunction(fn, args) {
537
537
  return fn.apply(null, args);
538
538
  }
539
539
 
540
- /**
541
- * A factory to create a configurable debouncer.
542
- *
543
- * @param {number|boolean} [config=true]
540
+ /**
541
+ * A factory to create a configurable debouncer.
542
+ *
543
+ * @param {number|boolean} [config=true]
544
544
  */
545
545
  function DebounceFactory(config = true) {
546
546
  const timeout = typeof config === 'number' ? config : config ? 300 : 0;
@@ -553,11 +553,11 @@ function DebounceFactory(config = true) {
553
553
  DebounceFactory.$inject = ['config.debounce'];
554
554
 
555
555
  class FormFieldRegistry extends formJsViewer.FormFieldRegistry {
556
- /**
557
- * Updates a form fields id.
558
- *
559
- * @param {Object} formField
560
- * @param {string} newId
556
+ /**
557
+ * Updates a form fields id.
558
+ *
559
+ * @param {Object} formField
560
+ * @param {string} newId
561
561
  */
562
562
  updateId(formField, newId) {
563
563
  this._validateId(newId);
@@ -578,13 +578,13 @@ class FormFieldRegistry extends formJsViewer.FormFieldRegistry {
578
578
  }
579
579
  }
580
580
 
581
- /**
582
- * Validate the suitability of the given id and signals a problem
583
- * with an exception.
584
- *
585
- * @param {string} id
586
- *
587
- * @throws {Error} if id is empty or already assigned
581
+ /**
582
+ * Validate the suitability of the given id and signals a problem
583
+ * with an exception.
584
+ *
585
+ * @param {string} id
586
+ *
587
+ * @throws {Error} if id is empty or already assigned
588
588
  */
589
589
  _validateId(id) {
590
590
  if (!id) {
@@ -601,11 +601,11 @@ const MAX_COLUMNS = 16;
601
601
  const MIN_COLUMNS = 2;
602
602
  const MAX_FIELDS_PER_ROW = 4;
603
603
  class FormLayoutValidator {
604
- /**
605
- * @constructor
606
- *
607
- * @param { import('./FormLayouter').default } formLayouter
608
- * @param { import('./FormFieldRegistry').default } formFieldRegistry
604
+ /**
605
+ * @constructor
606
+ *
607
+ * @param { import('./FormLayouter').default } formLayouter
608
+ * @param { import('./FormFieldRegistry').default } formFieldRegistry
609
609
  */
610
610
  constructor(formLayouter, formFieldRegistry) {
611
611
  this._formLayouter = formLayouter;
@@ -676,21 +676,21 @@ function editorFormFieldClasses(type, {
676
676
  });
677
677
  }
678
678
 
679
- /**
680
- * Add a dragger that calls back the passed function with
681
- * { event, delta } on drag.
682
- *
683
- * @example
684
- *
685
- * function dragMove(event, delta) {
686
- * // we are dragging (!!)
687
- * }
688
- *
689
- * domElement.addEventListener('dragstart', dragger(dragMove));
690
- *
691
- * @param {Function} fn
692
- *
693
- * @return {Function} drag start callback function
679
+ /**
680
+ * Add a dragger that calls back the passed function with
681
+ * { event, delta } on drag.
682
+ *
683
+ * @example
684
+ *
685
+ * function dragMove(event, delta) {
686
+ * // we are dragging (!!)
687
+ * }
688
+ *
689
+ * domElement.addEventListener('dragstart', dragger(dragMove));
690
+ *
691
+ * @param {Function} fn
692
+ *
693
+ * @return {Function} drag start callback function
694
694
  */
695
695
  function createDragger$1(fn) {
696
696
  let self;
@@ -731,12 +731,12 @@ function createDragger$1(fn) {
731
731
  return onDragStart;
732
732
  }
733
733
 
734
- /**
735
- * Throttle function call according UI update cycle.
736
- *
737
- * @param {Function} fn
738
- *
739
- * @return {Function} throttled fn
734
+ /**
735
+ * Throttle function call according UI update cycle.
736
+ *
737
+ * @param {Function} fn
738
+ *
739
+ * @return {Function} throttled fn
740
740
  */
741
741
  function throttle(fn) {
742
742
  let active = false;
@@ -792,11 +792,11 @@ const DragAndDropContext = preact.createContext({
792
792
  });
793
793
  var DragAndDropContext$1 = DragAndDropContext;
794
794
 
795
- /**
796
- * @param {string} type
797
- * @param {boolean} [strict]
798
- *
799
- * @returns {any}
795
+ /**
796
+ * @param {string} type
797
+ * @param {boolean} [strict]
798
+ *
799
+ * @returns {any}
800
800
  */
801
801
  function getService$1(type, strict) {}
802
802
  const FormEditorContext = preact.createContext({
@@ -1231,23 +1231,23 @@ var Slot = (props => {
1231
1231
  return fillsAndSeparators;
1232
1232
  });
1233
1233
 
1234
- /**
1235
- * Creates a Fragment for a fill.
1236
- *
1237
- * @param {Object} fill Fill to be rendered
1238
- * @returns {Object} Preact Fragment containing fill's children
1234
+ /**
1235
+ * Creates a Fragment for a fill.
1236
+ *
1237
+ * @param {Object} fill Fill to be rendered
1238
+ * @returns {Object} Preact Fragment containing fill's children
1239
1239
  */
1240
1240
  const FillFragment = fill => jsxRuntime.jsx(preact.Fragment, {
1241
1241
  children: fill.children
1242
1242
  }, fill.id);
1243
1243
 
1244
- /**
1245
- * Creates an array of fills, with separators inserted between groups.
1246
- *
1247
- * @param {Array} groups Groups of fills
1248
- * @param {Function} fillRenderer Function to create a fill
1249
- * @param {Function} separatorRenderer Function to create a separator
1250
- * @returns {Array} Array of fills and separators
1244
+ /**
1245
+ * Creates an array of fills, with separators inserted between groups.
1246
+ *
1247
+ * @param {Array} groups Groups of fills
1248
+ * @param {Function} fillRenderer Function to create a fill
1249
+ * @param {Function} separatorRenderer Function to create a separator
1250
+ * @returns {Array} Array of fills and separators
1251
1251
  */
1252
1252
  const buildFills = (groups, fillRenderer, separatorRenderer) => {
1253
1253
  const result = [];
@@ -1265,8 +1265,8 @@ const buildFills = (groups, fillRenderer, separatorRenderer) => {
1265
1265
  return result;
1266
1266
  };
1267
1267
 
1268
- /**
1269
- * Groups fills by group name property.
1268
+ /**
1269
+ * Groups fills by group name property.
1270
1270
  */
1271
1271
  const _groupByGroupName = fills => {
1272
1272
  const groups = [];
@@ -1286,8 +1286,8 @@ const _groupByGroupName = fills => {
1286
1286
  return Object.keys(groupsById).sort().map(id => groupsById[id]);
1287
1287
  };
1288
1288
 
1289
- /**
1290
- * Compares fills by priority.
1289
+ /**
1290
+ * Compares fills by priority.
1291
1291
  */
1292
1292
  const _comparePriority = (a, b) => {
1293
1293
  return (b.priority || 0) - (a.priority || 0);
@@ -1505,11 +1505,11 @@ function groupEntries(entries) {
1505
1505
  return groups.filter(g => g.entries.length);
1506
1506
  }
1507
1507
 
1508
- /**
1509
- * Returns a list of palette entries.
1510
- *
1511
- * @param {FormFields} formFields
1512
- * @returns {Array<PaletteEntry>}
1508
+ /**
1509
+ * Returns a list of palette entries.
1510
+ *
1511
+ * @param {FormFields} formFields
1512
+ * @returns {Array<PaletteEntry>}
1513
1513
  */
1514
1514
  function collectPaletteEntries(formFields) {
1515
1515
  return Object.entries(formFields._formFields).map(([type, formField]) => {
@@ -1528,12 +1528,12 @@ function collectPaletteEntries(formFields) {
1528
1528
  }) => type !== 'default');
1529
1529
  }
1530
1530
 
1531
- /**
1532
- * There are various options to specify an icon for a palette entry.
1533
- *
1534
- * a) via `iconUrl` property in a form field config
1535
- * b) via `icon` property in a form field config
1536
- * c) via statically defined iconsByType (fallback)
1531
+ /**
1532
+ * There are various options to specify an icon for a palette entry.
1533
+ *
1534
+ * a) via `iconUrl` property in a form field config
1535
+ * b) via `icon` property in a form field config
1536
+ * c) via statically defined iconsByType (fallback)
1537
1537
  */
1538
1538
  function getPaletteIcon(entry) {
1539
1539
  const {
@@ -1600,20 +1600,20 @@ const DRAG_NO_DROP_CLS = 'fjs-no-drop';
1600
1600
  const DRAG_NO_MOVE_CLS = 'fjs-no-move';
1601
1601
  const ERROR_DROP_CLS = 'fjs-error-drop';
1602
1602
 
1603
- /**
1604
- * @typedef { { id: String, components: Array<any> } } FormRow
1603
+ /**
1604
+ * @typedef { { id: String, components: Array<any> } } FormRow
1605
1605
  */
1606
1606
 
1607
1607
  class Dragging {
1608
- /**
1609
- * @constructor
1610
- *
1611
- * @param { import('../../core/FormFieldRegistry').default } formFieldRegistry
1612
- * @param { import('../../core/FormLayouter').default } formLayouter
1613
- * @param { import('../../core/FormLayoutValidator').default } formLayoutValidator
1614
- * @param { import('../../core/EventBus').default } eventBus
1615
- * @param { import('../modeling/Modeling').default } modeling
1616
- * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
1608
+ /**
1609
+ * @constructor
1610
+ *
1611
+ * @param { import('../../core/FormFieldRegistry').default } formFieldRegistry
1612
+ * @param { import('../../core/FormLayouter').default } formLayouter
1613
+ * @param { import('../../core/FormLayoutValidator').default } formLayoutValidator
1614
+ * @param { import('../../core/EventBus').default } eventBus
1615
+ * @param { import('../modeling/Modeling').default } modeling
1616
+ * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
1617
1617
  */
1618
1618
  constructor(formFieldRegistry, formLayouter, formLayoutValidator, eventBus, modeling, pathRegistry) {
1619
1619
  this._formFieldRegistry = formFieldRegistry;
@@ -1624,13 +1624,13 @@ class Dragging {
1624
1624
  this._pathRegistry = pathRegistry;
1625
1625
  }
1626
1626
 
1627
- /**
1628
- * Calculates position in form schema given the dropped place.
1629
- *
1630
- * @param { FormRow } targetRow
1631
- * @param { any } targetFormField
1632
- * @param { HTMLElement } sibling
1633
- * @returns { number }
1627
+ /**
1628
+ * Calculates position in form schema given the dropped place.
1629
+ *
1630
+ * @param { FormRow } targetRow
1631
+ * @param { any } targetFormField
1632
+ * @param { HTMLElement } sibling
1633
+ * @returns { number }
1634
1634
  */
1635
1635
  getTargetIndex(targetRow, targetFormField, sibling) {
1636
1636
  /** @type HTMLElement */
@@ -1776,8 +1776,8 @@ class Dragging {
1776
1776
  }
1777
1777
  }
1778
1778
 
1779
- /**
1780
- * @param { { container: Array<string>, direction: string, mirrorContainer: string } } options
1779
+ /**
1780
+ * @param { { container: Array<string>, direction: string, mirrorContainer: string } } options
1781
1781
  */
1782
1782
  createDragulaInstance(options) {
1783
1783
  const {
@@ -2216,7 +2216,7 @@ function DebugColumns(props) {
2216
2216
  return null;
2217
2217
  }
2218
2218
  return jsxRuntime.jsx("div", {
2219
- style: "width: fit-content; padding: 2px 6px; height: 16px; background: var(--color-blue-205-100-95); display: flex; justify-content: center; align-items: center; position: absolute; bottom: -2px; z-index: 2; font-size: 10px; right: 3px;",
2219
+ style: "width: fit-content;\r padding: 2px 6px;\r height: 16px;\r background: var(--color-blue-205-100-95);\r display: flex;\r justify-content: center;\r align-items: center;\r position: absolute;\r bottom: -2px;\r z-index: 2;\r font-size: 10px;\r right: 3px;",
2220
2220
  class: "fjs-debug-columns",
2221
2221
  children: (field.layout || {}).columns || 'auto'
2222
2222
  });
@@ -3343,10 +3343,10 @@ function updateRow(formField, rowId) {
3343
3343
  }
3344
3344
 
3345
3345
  class AddFormFieldHandler {
3346
- /**
3347
- * @constructor
3348
- * @param { import('../../../FormEditor').default } formEditor
3349
- * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3346
+ /**
3347
+ * @constructor
3348
+ * @param { import('../../../FormEditor').default } formEditor
3349
+ * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3350
3350
  */
3351
3351
  constructor(formEditor, formFieldRegistry) {
3352
3352
  this._formEditor = formEditor;
@@ -3407,10 +3407,10 @@ class AddFormFieldHandler {
3407
3407
  AddFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
3408
3408
 
3409
3409
  class EditFormFieldHandler {
3410
- /**
3411
- * @constructor
3412
- * @param { import('../../../FormEditor').default } formEditor
3413
- * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3410
+ /**
3411
+ * @constructor
3412
+ * @param { import('../../../FormEditor').default } formEditor
3413
+ * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3414
3414
  */
3415
3415
  constructor(formEditor, formFieldRegistry) {
3416
3416
  this._formEditor = formEditor;
@@ -3473,12 +3473,12 @@ class EditFormFieldHandler {
3473
3473
  EditFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
3474
3474
 
3475
3475
  class MoveFormFieldHandler {
3476
- /**
3477
- * @constructor
3478
- * @param { import('../../../FormEditor').default } formEditor
3479
- * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3480
- * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3481
- * @param { import('@bpmn-io/form-js-viewer').FormLayouter } formLayouter
3476
+ /**
3477
+ * @constructor
3478
+ * @param { import('../../../FormEditor').default } formEditor
3479
+ * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3480
+ * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3481
+ * @param { import('@bpmn-io/form-js-viewer').FormLayouter } formLayouter
3482
3482
  */
3483
3483
  constructor(formEditor, formFieldRegistry, pathRegistry, formLayouter) {
3484
3484
  this._formEditor = formEditor;
@@ -3589,10 +3589,10 @@ class MoveFormFieldHandler {
3589
3589
  MoveFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry', 'pathRegistry', 'formLayouter'];
3590
3590
 
3591
3591
  class RemoveFormFieldHandler {
3592
- /**
3593
- * @constructor
3594
- * @param { import('../../../FormEditor').default } formEditor
3595
- * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3592
+ /**
3593
+ * @constructor
3594
+ * @param { import('../../../FormEditor').default } formEditor
3595
+ * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3596
3596
  */
3597
3597
  constructor(formEditor, formFieldRegistry) {
3598
3598
  this._formEditor = formEditor;
@@ -3652,9 +3652,9 @@ class RemoveFormFieldHandler {
3652
3652
  RemoveFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
3653
3653
 
3654
3654
  class UpdateIdClaimHandler {
3655
- /**
3656
- * @constructor
3657
- * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3655
+ /**
3656
+ * @constructor
3657
+ * @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
3658
3658
  */
3659
3659
  constructor(formFieldRegistry) {
3660
3660
  this._formFieldRegistry = formFieldRegistry;
@@ -3687,9 +3687,9 @@ class UpdateIdClaimHandler {
3687
3687
  UpdateIdClaimHandler.$inject = ['formFieldRegistry'];
3688
3688
 
3689
3689
  class UpdateKeyClaimHandler {
3690
- /**
3691
- * @constructor
3692
- * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3690
+ /**
3691
+ * @constructor
3692
+ * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3693
3693
  */
3694
3694
  constructor(pathRegistry) {
3695
3695
  this._pathRegistry = pathRegistry;
@@ -3737,9 +3737,9 @@ class UpdateKeyClaimHandler {
3737
3737
  UpdateKeyClaimHandler.$inject = ['pathRegistry'];
3738
3738
 
3739
3739
  class UpdatePathClaimHandler {
3740
- /**
3741
- * @constructor
3742
- * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3740
+ /**
3741
+ * @constructor
3742
+ * @param { import('@bpmn-io/form-js-viewer').PathRegistry } pathRegistry
3743
3743
  */
3744
3744
  constructor(pathRegistry) {
3745
3745
  this._pathRegistry = pathRegistry;
@@ -4326,8 +4326,8 @@ class ValidateBehavior extends CommandInterceptor {
4326
4326
  constructor(eventBus) {
4327
4327
  super(eventBus);
4328
4328
 
4329
- /**
4330
- * Remove custom validation if <validationType> is about to be added.
4329
+ /**
4330
+ * Remove custom validation if <validationType> is about to be added.
4331
4331
  */
4332
4332
  this.preExecute('formField.edit', function (context) {
4333
4333
  const {
@@ -4354,11 +4354,11 @@ class OptionsSourceBehavior extends CommandInterceptor {
4354
4354
  constructor(eventBus) {
4355
4355
  super(eventBus);
4356
4356
 
4357
- /**
4358
- * Cleanup properties on changing the values source.
4359
- *
4360
- * 1) Remove other sources, e.g. set `values` => remove `valuesKey` and `valuesExpression`
4361
- * 2) Remove default values for all other values sources
4357
+ /**
4358
+ * Cleanup properties on changing the values source.
4359
+ *
4360
+ * 1) Remove other sources, e.g. set `values` => remove `valuesKey` and `valuesExpression`
4361
+ * 2) Remove default values for all other values sources
4362
4362
  */
4363
4363
  this.preExecute('formField.edit', function (context) {
4364
4364
  const {
@@ -5018,22 +5018,22 @@ var SelectionModule = {
5018
5018
  selectionBehavior: ['type', SelectionBehavior]
5019
5019
  };
5020
5020
 
5021
- /**
5022
- * Base class for sectionable UI modules.
5023
- *
5024
- * @property {EventBus} _eventBus - EventBus instance used for event handling.
5025
- * @property {string} managerType - Type of the render manager. Used to form event names.
5026
- *
5027
- * @class SectionModuleBase
5021
+ /**
5022
+ * Base class for sectionable UI modules.
5023
+ *
5024
+ * @property {EventBus} _eventBus - EventBus instance used for event handling.
5025
+ * @property {string} managerType - Type of the render manager. Used to form event names.
5026
+ *
5027
+ * @class SectionModuleBase
5028
5028
  */
5029
5029
  class SectionModuleBase {
5030
- /**
5031
- * Create a SectionModuleBase instance.
5032
- *
5033
- * @param {any} eventBus - The EventBus instance used for event handling.
5034
- * @param {string} sectionKey - The type of render manager. Used to form event names.
5035
- *
5036
- * @constructor
5030
+ /**
5031
+ * Create a SectionModuleBase instance.
5032
+ *
5033
+ * @param {any} eventBus - The EventBus instance used for event handling.
5034
+ * @param {string} sectionKey - The type of render manager. Used to form event names.
5035
+ *
5036
+ * @constructor
5037
5037
  */
5038
5038
  constructor(eventBus, sectionKey) {
5039
5039
  this._eventBus = eventBus;
@@ -5046,10 +5046,10 @@ class SectionModuleBase {
5046
5046
  });
5047
5047
  }
5048
5048
 
5049
- /**
5050
- * Attach the managed section to a parent node.
5051
- *
5052
- * @param {HTMLElement} container - The parent node to attach to.
5049
+ /**
5050
+ * Attach the managed section to a parent node.
5051
+ *
5052
+ * @param {HTMLElement} container - The parent node to attach to.
5053
5053
  */
5054
5054
  attachTo(container) {
5055
5055
  this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.attach`, {
@@ -5057,22 +5057,22 @@ class SectionModuleBase {
5057
5057
  }));
5058
5058
  }
5059
5059
 
5060
- /**
5061
- * Detach the managed section from its parent node.
5060
+ /**
5061
+ * Detach the managed section from its parent node.
5062
5062
  */
5063
5063
  detach() {
5064
5064
  this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.detach`));
5065
5065
  }
5066
5066
 
5067
- /**
5068
- * Reset the managed section to its initial state.
5067
+ /**
5068
+ * Reset the managed section to its initial state.
5069
5069
  */
5070
5070
  reset() {
5071
5071
  this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.reset`));
5072
5072
  }
5073
5073
 
5074
- /**
5075
- * Circumvents timing issues.
5074
+ /**
5075
+ * Circumvents timing issues.
5076
5076
  */
5077
5077
  _onceSectionRendered(callback) {
5078
5078
  if (this.isSectionRendered) {
@@ -8750,11 +8750,11 @@ var index = {
8750
8750
  feelPopup: ['type', FeelPopupModule]
8751
8751
  };
8752
8752
 
8753
- /**
8754
- * @param {string} type
8755
- * @param {boolean} [strict]
8756
- *
8757
- * @returns {any}
8753
+ /**
8754
+ * @param {string} type
8755
+ * @param {boolean} [strict]
8756
+ *
8757
+ * @returns {any}
8758
8758
  */
8759
8759
  function getService(type, strict) {}
8760
8760
  const PropertiesPanelContext = preact.createContext({
@@ -8788,8 +8788,8 @@ function textToLabel(text) {
8788
8788
  return null;
8789
8789
  }
8790
8790
 
8791
- /**
8792
- * @param {string} path
8791
+ /**
8792
+ * @param {string} path
8793
8793
  */
8794
8794
  function isValidDotPath(path) {
8795
8795
  return /^\w+(\.\w+)*$/.test(path);
@@ -8815,8 +8815,8 @@ function hasOptionsGroupsConfigured(formFieldDefinition) {
8815
8815
  return propertiesPanelEntries.some(id => id === 'values');
8816
8816
  }
8817
8817
 
8818
- /**
8819
- * @param {string} path
8818
+ /**
8819
+ * @param {string} path
8820
8820
  */
8821
8821
  function hasIntegerPathSegment(path) {
8822
8822
  return path.split('.').some(segment => /^\d+$/.test(segment));
@@ -8829,10 +8829,10 @@ function useService (type, strict) {
8829
8829
  return getService(type, strict);
8830
8830
  }
8831
8831
 
8832
- /**
8833
- * Retrieve list of variables from the form schema.
8834
- *
8835
- * @returns { string[] } list of variables used in form schema
8832
+ /**
8833
+ * Retrieve list of variables from the form schema.
8834
+ *
8835
+ * @returns { string[] } list of variables used in form schema
8836
8836
  */
8837
8837
  function useVariables() {
8838
8838
  const form = useService('formEditor');
@@ -8898,8 +8898,8 @@ const PropertiesPanelHeaderProvider = {
8898
8898
  }
8899
8899
  };
8900
8900
 
8901
- /**
8902
- * Provide placeholders for empty and multiple state.
8901
+ /**
8902
+ * Provide placeholders for empty and multiple state.
8903
8903
  */
8904
8904
  const PropertiesPanelPlaceholderProvider = {
8905
8905
  getEmpty: () => {
@@ -8944,9 +8944,9 @@ function FormPropertiesPanel(props) {
8944
8944
  });
8945
8945
  }, [eventBus, formEditor, selectionModule]);
8946
8946
  hooks.useLayoutEffect(() => {
8947
- /**
8948
- * TODO(pinussilvestrus): update with actual updated element,
8949
- * once we have a proper updater/change support
8947
+ /**
8948
+ * TODO(pinussilvestrus): update with actual updated element,
8949
+ * once we have a proper updater/change support
8950
8950
  */
8951
8951
  eventBus.on('changed', refresh);
8952
8952
  eventBus.on('import.done', refresh);
@@ -8998,17 +8998,17 @@ function FormPropertiesPanel(props) {
8998
8998
 
8999
8999
  const DEFAULT_PRIORITY = 1000;
9000
9000
 
9001
- /**
9002
- * @typedef { { parent: Element } } PropertiesPanelConfig
9003
- * @typedef { import('../../core/EventBus').default } EventBus
9004
- * @typedef { import('../../types').Injector } Injector
9005
- * @typedef { { getGroups: ({ formField, editFormField }) => ({ groups}) => Array } } PropertiesProvider
9001
+ /**
9002
+ * @typedef { { parent: Element } } PropertiesPanelConfig
9003
+ * @typedef { import('../../core/EventBus').default } EventBus
9004
+ * @typedef { import('../../types').Injector } Injector
9005
+ * @typedef { { getGroups: ({ formField, editFormField }) => ({ groups}) => Array } } PropertiesProvider
9006
9006
  */
9007
9007
 
9008
- /**
9009
- * @param {PropertiesPanelConfig} propertiesPanelConfig
9010
- * @param {Injector} injector
9011
- * @param {EventBus} eventBus
9008
+ /**
9009
+ * @param {PropertiesPanelConfig} propertiesPanelConfig
9010
+ * @param {Injector} injector
9011
+ * @param {EventBus} eventBus
9012
9012
  */
9013
9013
  class PropertiesPanelRenderer {
9014
9014
  constructor(propertiesPanelConfig, injector, eventBus) {
@@ -9026,10 +9026,10 @@ class PropertiesPanelRenderer {
9026
9026
  });
9027
9027
  }
9028
9028
 
9029
- /**
9030
- * Attach the properties panel to a parent node.
9031
- *
9032
- * @param {HTMLElement} container
9029
+ /**
9030
+ * Attach the properties panel to a parent node.
9031
+ *
9032
+ * @param {HTMLElement} container
9033
9033
  */
9034
9034
  attachTo(container) {
9035
9035
  if (!container) {
@@ -9049,8 +9049,8 @@ class PropertiesPanelRenderer {
9049
9049
  this._eventBus.fire('propertiesPanel.attach');
9050
9050
  }
9051
9051
 
9052
- /**
9053
- * Detach the properties panel from its parent node.
9052
+ /**
9053
+ * Detach the properties panel from its parent node.
9054
9054
  */
9055
9055
  detach() {
9056
9056
  const parentNode = this._container.parentNode;
@@ -9074,11 +9074,11 @@ class PropertiesPanelRenderer {
9074
9074
  }
9075
9075
  }
9076
9076
 
9077
- /**
9078
- * Register a new properties provider to the properties panel.
9079
- *
9080
- * @param {PropertiesProvider} provider
9081
- * @param {Number} [priority]
9077
+ /**
9078
+ * Register a new properties provider to the properties panel.
9079
+ *
9080
+ * @param {PropertiesProvider} provider
9081
+ * @param {Number} [priority]
9082
9082
  */
9083
9083
  registerProvider(provider, priority) {
9084
9084
  if (!priority) {
@@ -10158,9 +10158,9 @@ function TimeLabel(props) {
10158
10158
 
10159
10159
  // helpers //////////
10160
10160
 
10161
- /**
10162
- * @param {string} type
10163
- * @returns {string}
10161
+ /**
10162
+ * @param {string} type
10163
+ * @returns {string}
10164
10164
  */
10165
10165
  function getLabelText(type) {
10166
10166
  switch (type) {
@@ -10974,14 +10974,14 @@ function Value(props) {
10974
10974
 
10975
10975
  // helpers //////////
10976
10976
 
10977
- /**
10978
- * Returns copy of object with updated value.
10979
- *
10980
- * @param {Object} properties
10981
- * @param {string} key
10982
- * @param {string} value
10983
- *
10984
- * @returns {Object}
10977
+ /**
10978
+ * Returns copy of object with updated value.
10979
+ *
10980
+ * @param {Object} properties
10981
+ * @param {string} key
10982
+ * @param {string} value
10983
+ *
10984
+ * @returns {Object}
10985
10985
  */
10986
10986
  function updateValue(properties, key, value) {
10987
10987
  return {
@@ -10990,14 +10990,14 @@ function updateValue(properties, key, value) {
10990
10990
  };
10991
10991
  }
10992
10992
 
10993
- /**
10994
- * Returns copy of object with updated key.
10995
- *
10996
- * @param {Object} properties
10997
- * @param {string} oldKey
10998
- * @param {string} newKey
10999
- *
11000
- * @returns {Object}
10993
+ /**
10994
+ * Returns copy of object with updated key.
10995
+ *
10996
+ * @param {Object} properties
10997
+ * @param {string} oldKey
10998
+ * @param {string} newKey
10999
+ *
11000
+ * @returns {Object}
11001
11001
  */
11002
11002
  function updateKey(properties, oldKey, newKey) {
11003
11003
  return Object.entries(properties).reduce((newProperties, entry) => {
@@ -11565,9 +11565,9 @@ function Source(props) {
11565
11565
  editField(field, path, value);
11566
11566
  };
11567
11567
 
11568
- /**
11569
- * @param {string|void} value
11570
- * @returns {string|null}
11568
+ /**
11569
+ * @param {string|void} value
11570
+ * @returns {string|null}
11571
11571
  */
11572
11572
  const validate = value => {
11573
11573
  if (!minDash.isString(value) || value.length === 0) {
@@ -11628,8 +11628,8 @@ function Pagination(props) {
11628
11628
  return minDash.isNumber(minDash.get(field, path));
11629
11629
  };
11630
11630
 
11631
- /**
11632
- * @param {boolean} value
11631
+ /**
11632
+ * @param {boolean} value
11633
11633
  */
11634
11634
  const setValue = value => {
11635
11635
  value ? editField(field, path, defaultRowCount) : editField(field, path, undefined);
@@ -11670,10 +11670,10 @@ function RowCount(props) {
11670
11670
  const debounce = useService('debounce');
11671
11671
  const getValue = () => minDash.get(field, path$2);
11672
11672
 
11673
- /**
11674
- * @param {number|void} value
11675
- * @param {string|null} error
11676
- * @returns {void}
11673
+ /**
11674
+ * @param {number|void} value
11675
+ * @param {string|null} error
11676
+ * @returns {void}
11677
11677
  */
11678
11678
  const setValue = (value, error) => {
11679
11679
  if (error) {
@@ -11682,9 +11682,9 @@ function RowCount(props) {
11682
11682
  editField(field, path$2, value);
11683
11683
  };
11684
11684
 
11685
- /**
11686
- * @param {string|void} value
11687
- * @returns {string|null}
11685
+ /**
11686
+ * @param {string|void} value
11687
+ * @returns {string|null}
11688
11688
  */
11689
11689
  const validate = value => {
11690
11690
  if (minDash.isNil(value)) {
@@ -11746,8 +11746,8 @@ function HeadersSourceSelect(props) {
11746
11746
  id
11747
11747
  } = props;
11748
11748
 
11749
- /**
11750
- * @returns {string|void}
11749
+ /**
11750
+ * @returns {string|void}
11751
11751
  */
11752
11752
  const getValue = () => {
11753
11753
  const columns = minDash.get(field, COLUMNS_PATH);
@@ -11760,8 +11760,8 @@ function HeadersSourceSelect(props) {
11760
11760
  }
11761
11761
  };
11762
11762
 
11763
- /**
11764
- * @param {string|void} value
11763
+ /**
11764
+ * @param {string|void} value
11765
11765
  */
11766
11766
  const setValue = value => {
11767
11767
  switch (value) {
@@ -11839,10 +11839,10 @@ function ColumnsExpression(props) {
11839
11839
  return minDash.get(field, PATH);
11840
11840
  };
11841
11841
 
11842
- /**
11843
- * @param {string|void} value
11844
- * @param {string|void} error
11845
- * @returns {void}
11842
+ /**
11843
+ * @param {string|void} value
11844
+ * @param {string|void} error
11845
+ * @returns {void}
11846
11846
  */
11847
11847
  const setValue = (value, error) => {
11848
11848
  if (error) {
@@ -11851,9 +11851,9 @@ function ColumnsExpression(props) {
11851
11851
  editField(field, PATH, value);
11852
11852
  };
11853
11853
 
11854
- /**
11855
- * @param {string|void} value
11856
- * @returns {string|null}
11854
+ /**
11855
+ * @param {string|void} value
11856
+ * @returns {string|null}
11857
11857
  */
11858
11858
  const validate = value => {
11859
11859
  if (!minDash.isString(value) || value.length === 0 || value === '=') {
@@ -11924,10 +11924,10 @@ function Label(props) {
11924
11924
  } = props;
11925
11925
  const debounce = useService('debounce');
11926
11926
 
11927
- /**
11928
- * @param {string|void} value
11929
- * @param {string|void} error
11930
- * @returns {void}
11927
+ /**
11928
+ * @param {string|void} value
11929
+ * @param {string|void} error
11930
+ * @returns {void}
11931
11931
  */
11932
11932
  const setValue = (value, error) => {
11933
11933
  if (error) {
@@ -11957,10 +11957,10 @@ function Key(props) {
11957
11957
  } = props;
11958
11958
  const debounce = useService('debounce');
11959
11959
 
11960
- /**
11961
- * @param {string|void} value
11962
- * @param {string|void} error
11963
- * @returns {void}
11960
+ /**
11961
+ * @param {string|void} value
11962
+ * @param {string|void} error
11963
+ * @returns {void}
11964
11964
  */
11965
11965
  const setValue = (value, error) => {
11966
11966
  if (error) {
@@ -11985,9 +11985,9 @@ function Key(props) {
11985
11985
 
11986
11986
  // helpers //////////////////////
11987
11987
 
11988
- /**
11989
- * @param {string|void} value
11990
- * @returns {string|null}
11988
+ /**
11989
+ * @param {string|void} value
11990
+ * @returns {string|null}
11991
11991
  */
11992
11992
  function validate(value) {
11993
11993
  if (!minDash.isString(value) || value.length === 0) {
@@ -12415,8 +12415,8 @@ function OptionsGroups(field, editField, getService) {
12415
12415
  };
12416
12416
  const id = 'valuesSource';
12417
12417
 
12418
- /**
12419
- * @type {Array<Group|ListGroup>}
12418
+ /**
12419
+ * @type {Array<Group|ListGroup>}
12420
12420
  */
12421
12421
  const groups = [{
12422
12422
  id,
@@ -12537,13 +12537,13 @@ function CustomPropertiesGroup(field, editField) {
12537
12537
 
12538
12538
  // helpers //////////
12539
12539
 
12540
- /**
12541
- * Returns copy of object without key.
12542
- *
12543
- * @param {Object} properties
12544
- * @param {string} oldKey
12545
- *
12546
- * @returns {Object}
12540
+ /**
12541
+ * Returns copy of object without key.
12542
+ *
12543
+ * @param {Object} properties
12544
+ * @param {string} oldKey
12545
+ *
12546
+ * @returns {Object}
12547
12547
  */
12548
12548
  function removeKey(properties, oldKey) {
12549
12549
  return Object.entries(properties).reduce((newProperties, entry) => {
@@ -12628,8 +12628,8 @@ function TableHeaderGroups(field, editField) {
12628
12628
  }
12629
12629
  const areStaticColumnsEnabled = minDash.isArray(minDash.get(field, ['columns']));
12630
12630
 
12631
- /**
12632
- * @type {Array<Group>}
12631
+ /**
12632
+ * @type {Array<Group>}
12633
12633
  */
12634
12634
  const groups = [{
12635
12635
  id: `${fieldId}-columnsSource`,
@@ -12721,10 +12721,10 @@ var PropertiesPanelModule = {
12721
12721
  propertiesProvider: ['type', PropertiesProvider]
12722
12722
  };
12723
12723
 
12724
- /**
12725
- * Manages the rendering of visual plugins.
12726
- * @constructor
12727
- * @param {Object} eventBus - Event bus for the application.
12724
+ /**
12725
+ * Manages the rendering of visual plugins.
12726
+ * @constructor
12727
+ * @param {Object} eventBus - Event bus for the application.
12728
12728
  */
12729
12729
  class RenderInjector extends SectionModuleBase {
12730
12730
  constructor(eventBus) {
@@ -12733,10 +12733,10 @@ class RenderInjector extends SectionModuleBase {
12733
12733
  this.registeredRenderers = [];
12734
12734
  }
12735
12735
 
12736
- /**
12737
- * Inject a new renderer into the injector.
12738
- * @param {string} identifier - Identifier for the renderer.
12739
- * @param {Function} Renderer - The renderer function.
12736
+ /**
12737
+ * Inject a new renderer into the injector.
12738
+ * @param {string} identifier - Identifier for the renderer.
12739
+ * @param {Function} Renderer - The renderer function.
12740
12740
  */
12741
12741
  attachRenderer(identifier, Renderer) {
12742
12742
  this.registeredRenderers = [...this.registeredRenderers, {
@@ -12745,17 +12745,17 @@ class RenderInjector extends SectionModuleBase {
12745
12745
  }];
12746
12746
  }
12747
12747
 
12748
- /**
12749
- * Detach a renderer from the by key injector.
12750
- * @param {string} identifier - Identifier for the renderer.
12748
+ /**
12749
+ * Detach a renderer from the by key injector.
12750
+ * @param {string} identifier - Identifier for the renderer.
12751
12751
  */
12752
12752
  detachRenderer(identifier) {
12753
12753
  this.registeredRenderers = this.registeredRenderers.filter(r => r.identifier !== identifier);
12754
12754
  }
12755
12755
 
12756
- /**
12757
- * Returns the registered renderers.
12758
- * @returns {Array} Array of registered renderers.
12756
+ /**
12757
+ * Returns the registered renderers.
12758
+ * @returns {Array} Array of registered renderers.
12759
12759
  */
12760
12760
  fetchRenderers() {
12761
12761
  return this.registeredRenderers;
@@ -12790,11 +12790,11 @@ class RepeatRenderManager {
12790
12790
  this.RepeatFooter = this.RepeatFooter.bind(this);
12791
12791
  }
12792
12792
 
12793
- /**
12794
- * Checks whether a field should be repeatable.
12795
- *
12796
- * @param {string} id - The id of the field to check
12797
- * @returns {boolean} - True if repeatable, false otherwise
12793
+ /**
12794
+ * Checks whether a field should be repeatable.
12795
+ *
12796
+ * @param {string} id - The id of the field to check
12797
+ * @returns {boolean} - True if repeatable, false otherwise
12798
12798
  */
12799
12799
  isFieldRepeating(id) {
12800
12800
  if (!id) {
@@ -12841,48 +12841,48 @@ var ExpressionLanguageModule = {
12841
12841
 
12842
12842
  const ids = new Ids([32, 36, 1]);
12843
12843
 
12844
- /**
12845
- * @typedef { import('./types').Injector } Injector
12846
- * @typedef { import('./types').Module } Module
12847
- * @typedef { import('./types').Schema } Schema
12848
- *
12849
- * @typedef { import('./types').FormEditorOptions } FormEditorOptions
12850
- * @typedef { import('./types').FormEditorProperties } FormEditorProperties
12851
- *
12852
- * @typedef { {
12853
- * properties: FormEditorProperties,
12854
- * schema: Schema
12855
- * } } State
12856
- *
12857
- * @typedef { (type:string, priority:number, handler:Function) => void } OnEventWithPriority
12858
- * @typedef { (type:string, handler:Function) => void } OnEventWithOutPriority
12859
- * @typedef { OnEventWithPriority & OnEventWithOutPriority } OnEventType
12844
+ /**
12845
+ * @typedef { import('./types').Injector } Injector
12846
+ * @typedef { import('./types').Module } Module
12847
+ * @typedef { import('./types').Schema } Schema
12848
+ *
12849
+ * @typedef { import('./types').FormEditorOptions } FormEditorOptions
12850
+ * @typedef { import('./types').FormEditorProperties } FormEditorProperties
12851
+ *
12852
+ * @typedef { {
12853
+ * properties: FormEditorProperties,
12854
+ * schema: Schema
12855
+ * } } State
12856
+ *
12857
+ * @typedef { (type:string, priority:number, handler:Function) => void } OnEventWithPriority
12858
+ * @typedef { (type:string, handler:Function) => void } OnEventWithOutPriority
12859
+ * @typedef { OnEventWithPriority & OnEventWithOutPriority } OnEventType
12860
12860
  */
12861
12861
 
12862
- /**
12863
- * The form editor.
12862
+ /**
12863
+ * The form editor.
12864
12864
  */
12865
12865
  class FormEditor {
12866
- /**
12867
- * @constructor
12868
- * @param {FormEditorOptions} options
12866
+ /**
12867
+ * @constructor
12868
+ * @param {FormEditorOptions} options
12869
12869
  */
12870
12870
  constructor(options = {}) {
12871
- /**
12872
- * @public
12873
- * @type {OnEventType}
12871
+ /**
12872
+ * @public
12873
+ * @type {OnEventType}
12874
12874
  */
12875
12875
  this.on = this._onEvent;
12876
12876
 
12877
- /**
12878
- * @public
12879
- * @type {String}
12877
+ /**
12878
+ * @public
12879
+ * @type {String}
12880
12880
  */
12881
12881
  this._id = ids.next();
12882
12882
 
12883
- /**
12884
- * @private
12885
- * @type {Element}
12883
+ /**
12884
+ * @private
12885
+ * @type {Element}
12886
12886
  */
12887
12887
  this._container = formJsViewer.createFormContainer();
12888
12888
  this._container.setAttribute('input-handle-modified-keys', 'z,y');
@@ -12893,15 +12893,15 @@ class FormEditor {
12893
12893
  properties = {}
12894
12894
  } = options;
12895
12895
 
12896
- /**
12897
- * @private
12898
- * @type {any}
12896
+ /**
12897
+ * @private
12898
+ * @type {any}
12899
12899
  */
12900
12900
  this.exporter = exporter;
12901
12901
 
12902
- /**
12903
- * @private
12904
- * @type {State}
12902
+ /**
12903
+ * @private
12904
+ * @type {State}
12905
12905
  */
12906
12906
  this._state = {
12907
12907
  properties,
@@ -12930,10 +12930,10 @@ class FormEditor {
12930
12930
  this._detach(false);
12931
12931
  }
12932
12932
 
12933
- /**
12934
- * @param {Schema} schema
12935
- *
12936
- * @return {Promise<{ warnings: Array<any> }>}
12933
+ /**
12934
+ * @param {Schema} schema
12935
+ *
12936
+ * @return {Promise<{ warnings: Array<any> }>}
12937
12937
  */
12938
12938
  importSchema(schema) {
12939
12939
  return new Promise((resolve, reject) => {
@@ -12962,15 +12962,15 @@ class FormEditor {
12962
12962
  });
12963
12963
  }
12964
12964
 
12965
- /**
12966
- * @returns {Schema}
12965
+ /**
12966
+ * @returns {Schema}
12967
12967
  */
12968
12968
  saveSchema() {
12969
12969
  return this.getSchema();
12970
12970
  }
12971
12971
 
12972
- /**
12973
- * @returns {Schema}
12972
+ /**
12973
+ * @returns {Schema}
12974
12974
  */
12975
12975
  getSchema() {
12976
12976
  const {
@@ -12979,8 +12979,8 @@ class FormEditor {
12979
12979
  return exportSchema(schema, this.exporter, formJsViewer.schemaVersion);
12980
12980
  }
12981
12981
 
12982
- /**
12983
- * @param {Element|string} parentNode
12982
+ /**
12983
+ * @param {Element|string} parentNode
12984
12984
  */
12985
12985
  attachTo(parentNode) {
12986
12986
  if (!parentNode) {
@@ -12998,10 +12998,10 @@ class FormEditor {
12998
12998
  this._detach();
12999
12999
  }
13000
13000
 
13001
- /**
13002
- * @internal
13003
- *
13004
- * @param {boolean} [emit]
13001
+ /**
13002
+ * @internal
13003
+ *
13004
+ * @param {boolean} [emit]
13005
13005
  */
13006
13006
  _detach(emit = true) {
13007
13007
  const container = this._container,
@@ -13015,9 +13015,9 @@ class FormEditor {
13015
13015
  parentNode.removeChild(container);
13016
13016
  }
13017
13017
 
13018
- /**
13019
- * @param {any} property
13020
- * @param {any} value
13018
+ /**
13019
+ * @param {any} property
13020
+ * @param {any} value
13021
13021
  */
13022
13022
  setProperty(property, value) {
13023
13023
  const properties = minDash.set(this._getState().properties, [property], value);
@@ -13026,21 +13026,21 @@ class FormEditor {
13026
13026
  });
13027
13027
  }
13028
13028
 
13029
- /**
13030
- * @param {string} type
13031
- * @param {Function} handler
13029
+ /**
13030
+ * @param {string} type
13031
+ * @param {Function} handler
13032
13032
  */
13033
13033
  off(type, handler) {
13034
13034
  this.get('eventBus').off(type, handler);
13035
13035
  }
13036
13036
 
13037
- /**
13038
- * @internal
13039
- *
13040
- * @param {FormEditorOptions} options
13041
- * @param {Element} container
13042
- *
13043
- * @returns {Injector}
13037
+ /**
13038
+ * @internal
13039
+ *
13040
+ * @param {FormEditorOptions} options
13041
+ * @param {Element} container
13042
+ *
13043
+ * @returns {Injector}
13044
13044
  */
13045
13045
  _createInjector(options, container) {
13046
13046
  const {
@@ -13062,22 +13062,22 @@ class FormEditor {
13062
13062
  }, core, ...modules, ...additionalModules]);
13063
13063
  }
13064
13064
 
13065
- /**
13066
- * @internal
13065
+ /**
13066
+ * @internal
13067
13067
  */
13068
13068
  _emit(type, data) {
13069
13069
  this.get('eventBus').fire(type, data);
13070
13070
  }
13071
13071
 
13072
- /**
13073
- * @internal
13072
+ /**
13073
+ * @internal
13074
13074
  */
13075
13075
  _getState() {
13076
13076
  return this._state;
13077
13077
  }
13078
13078
 
13079
- /**
13080
- * @internal
13079
+ /**
13080
+ * @internal
13081
13081
  */
13082
13082
  _setState(state) {
13083
13083
  this._state = {
@@ -13087,15 +13087,15 @@ class FormEditor {
13087
13087
  this._emit('changed', this._getState());
13088
13088
  }
13089
13089
 
13090
- /**
13091
- * @internal
13090
+ /**
13091
+ * @internal
13092
13092
  */
13093
13093
  _getModules() {
13094
13094
  return [ModelingModule, EditorActionsModule, DraggingModule, KeyboardModule, SelectionModule, PaletteModule, ExpressionLanguageModule, formJsViewer.MarkdownModule, PropertiesPanelModule, RenderInjectionModule, RepeatRenderManagerModule];
13095
13095
  }
13096
13096
 
13097
- /**
13098
- * @internal
13097
+ /**
13098
+ * @internal
13099
13099
  */
13100
13100
  _onEvent(type, priority, handler) {
13101
13101
  this.get('eventBus').on(type, priority, handler);