@bpmn-io/form-js-playground 1.0.0-alpha.2 → 1.0.0-alpha.3
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/LICENSE +22 -22
- package/dist/assets/form-js-playground.css +259 -259
- package/dist/form-playground.umd.js +590 -577
- package/dist/index.cjs +6 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.es.js +6 -6
- package/dist/index.es.js.map +1 -1
- package/package.json +4 -4
|
@@ -49278,26 +49278,26 @@
|
|
|
49278
49278
|
}(simpleExpressionTree);
|
|
49279
49279
|
};
|
|
49280
49280
|
|
|
49281
|
-
/**
|
|
49282
|
-
* Get the variable name at the specified index in a given path expression.
|
|
49283
|
-
*
|
|
49284
|
-
* @param {Object} root - The root node of the path expression tree.
|
|
49285
|
-
* @param {number} index - The index of the variable name to retrieve.
|
|
49286
|
-
* @returns {string|null} The variable name at the specified index or null if index is out of bounds.
|
|
49281
|
+
/**
|
|
49282
|
+
* Get the variable name at the specified index in a given path expression.
|
|
49283
|
+
*
|
|
49284
|
+
* @param {Object} root - The root node of the path expression tree.
|
|
49285
|
+
* @param {number} index - The index of the variable name to retrieve.
|
|
49286
|
+
* @returns {string|null} The variable name at the specified index or null if index is out of bounds.
|
|
49287
49287
|
*/
|
|
49288
49288
|
const _getVariableNameAtPathIndex = (root, index) => {
|
|
49289
49289
|
const accessors = _deconstructPathExpression(root);
|
|
49290
49290
|
return accessors[index] || null;
|
|
49291
49291
|
};
|
|
49292
49292
|
|
|
49293
|
-
/**
|
|
49294
|
-
* Extracts the variables which are required of the external context for a given path expression.
|
|
49295
|
-
* This is done by traversing the path expression tree and keeping track of the current depth relative to the external context.
|
|
49296
|
-
*
|
|
49297
|
-
* @param {Object} node - The root node of the path expression tree.
|
|
49298
|
-
* @param {number} initialDepth - The depth at which the root node is located in the outer context.
|
|
49299
|
-
* @param {Object} specialDepthAccessors - Definitions of special keywords which represent more complex accesses of the outer context.
|
|
49300
|
-
* @returns {Set} - A set containing the extracted variable names.
|
|
49293
|
+
/**
|
|
49294
|
+
* Extracts the variables which are required of the external context for a given path expression.
|
|
49295
|
+
* This is done by traversing the path expression tree and keeping track of the current depth relative to the external context.
|
|
49296
|
+
*
|
|
49297
|
+
* @param {Object} node - The root node of the path expression tree.
|
|
49298
|
+
* @param {number} initialDepth - The depth at which the root node is located in the outer context.
|
|
49299
|
+
* @param {Object} specialDepthAccessors - Definitions of special keywords which represent more complex accesses of the outer context.
|
|
49300
|
+
* @returns {Set} - A set containing the extracted variable names.
|
|
49301
49301
|
*/
|
|
49302
49302
|
const _smartExtractVariableNames = (node, initialDepth, specialDepthAccessors) => {
|
|
49303
49303
|
// depth info represents the previous (initialised as null) and current depth of the current accessor in the path expression
|
|
@@ -49343,11 +49343,11 @@
|
|
|
49343
49343
|
return new Set(extractedVariables);
|
|
49344
49344
|
};
|
|
49345
49345
|
|
|
49346
|
-
/**
|
|
49347
|
-
* Deconstructs a path expression tree into an array of components.
|
|
49348
|
-
*
|
|
49349
|
-
* @param {Object} root - The root node of the path expression tree.
|
|
49350
|
-
* @returns {Array<string>} An array of components in the path expression, in the correct order.
|
|
49346
|
+
/**
|
|
49347
|
+
* Deconstructs a path expression tree into an array of components.
|
|
49348
|
+
*
|
|
49349
|
+
* @param {Object} root - The root node of the path expression tree.
|
|
49350
|
+
* @returns {Array<string>} An array of components in the path expression, in the correct order.
|
|
49351
49351
|
*/
|
|
49352
49352
|
const _deconstructPathExpression = root => {
|
|
49353
49353
|
let node = root;
|
|
@@ -49366,13 +49366,13 @@
|
|
|
49366
49366
|
return parts.reverse();
|
|
49367
49367
|
};
|
|
49368
49368
|
|
|
49369
|
-
/**
|
|
49370
|
-
* Builds a simplified feel structure tree from the given parse tree and feel string.
|
|
49371
|
-
* The nodes follow this structure: `{ name: string, children: Array, variableName?: string }`
|
|
49372
|
-
*
|
|
49373
|
-
* @param {Object} parseTree - The parse tree generated by a parser.
|
|
49374
|
-
* @param {string} feelString - The feel string used for parsing.
|
|
49375
|
-
* @returns {Object} The simplified feel structure tree.
|
|
49369
|
+
/**
|
|
49370
|
+
* Builds a simplified feel structure tree from the given parse tree and feel string.
|
|
49371
|
+
* The nodes follow this structure: `{ name: string, children: Array, variableName?: string }`
|
|
49372
|
+
*
|
|
49373
|
+
* @param {Object} parseTree - The parse tree generated by a parser.
|
|
49374
|
+
* @param {string} feelString - The feel string used for parsing.
|
|
49375
|
+
* @returns {Object} The simplified feel structure tree.
|
|
49376
49376
|
*/
|
|
49377
49377
|
const _buildSimpleFeelStructureTree = (parseTree, feelString) => {
|
|
49378
49378
|
const stack = [{
|
|
@@ -49402,25 +49402,25 @@
|
|
|
49402
49402
|
this._eventBus = eventBus;
|
|
49403
49403
|
}
|
|
49404
49404
|
|
|
49405
|
-
/**
|
|
49406
|
-
* Determines if the given value is a FEEL expression.
|
|
49407
|
-
*
|
|
49408
|
-
* @param {any} value
|
|
49409
|
-
* @returns {boolean}
|
|
49410
|
-
*
|
|
49405
|
+
/**
|
|
49406
|
+
* Determines if the given value is a FEEL expression.
|
|
49407
|
+
*
|
|
49408
|
+
* @param {any} value
|
|
49409
|
+
* @returns {boolean}
|
|
49410
|
+
*
|
|
49411
49411
|
*/
|
|
49412
49412
|
isExpression(value) {
|
|
49413
49413
|
return isString$4(value) && value.startsWith('=');
|
|
49414
49414
|
}
|
|
49415
49415
|
|
|
49416
|
-
/**
|
|
49417
|
-
* Retrieve variable names from a given FEEL expression.
|
|
49418
|
-
*
|
|
49419
|
-
* @param {string} expression
|
|
49420
|
-
* @param {object} [options]
|
|
49421
|
-
* @param {string} [options.type]
|
|
49422
|
-
*
|
|
49423
|
-
* @returns {string[]}
|
|
49416
|
+
/**
|
|
49417
|
+
* Retrieve variable names from a given FEEL expression.
|
|
49418
|
+
*
|
|
49419
|
+
* @param {string} expression
|
|
49420
|
+
* @param {object} [options]
|
|
49421
|
+
* @param {string} [options.type]
|
|
49422
|
+
*
|
|
49423
|
+
* @returns {string[]}
|
|
49424
49424
|
*/
|
|
49425
49425
|
getVariableNames(expression, options = {}) {
|
|
49426
49426
|
const {
|
|
@@ -49435,13 +49435,13 @@
|
|
|
49435
49435
|
return getFlavouredFeelVariableNames(expression, type);
|
|
49436
49436
|
}
|
|
49437
49437
|
|
|
49438
|
-
/**
|
|
49439
|
-
* Evaluate an expression.
|
|
49440
|
-
*
|
|
49441
|
-
* @param {string} expression
|
|
49442
|
-
* @param {import('../../types').Data} [data]
|
|
49443
|
-
*
|
|
49444
|
-
* @returns {any}
|
|
49438
|
+
/**
|
|
49439
|
+
* Evaluate an expression.
|
|
49440
|
+
*
|
|
49441
|
+
* @param {string} expression
|
|
49442
|
+
* @param {import('../../types').Data} [data]
|
|
49443
|
+
*
|
|
49444
|
+
* @returns {any}
|
|
49445
49445
|
*/
|
|
49446
49446
|
evaluate(expression, data = {}) {
|
|
49447
49447
|
if (!expression) {
|
|
@@ -49465,23 +49465,23 @@
|
|
|
49465
49465
|
class FeelersTemplating {
|
|
49466
49466
|
constructor() {}
|
|
49467
49467
|
|
|
49468
|
-
/**
|
|
49469
|
-
* Determines if the given value is a feelers template.
|
|
49470
|
-
*
|
|
49471
|
-
* @param {any} value
|
|
49472
|
-
* @returns {boolean}
|
|
49473
|
-
*
|
|
49468
|
+
/**
|
|
49469
|
+
* Determines if the given value is a feelers template.
|
|
49470
|
+
*
|
|
49471
|
+
* @param {any} value
|
|
49472
|
+
* @returns {boolean}
|
|
49473
|
+
*
|
|
49474
49474
|
*/
|
|
49475
49475
|
isTemplate(value) {
|
|
49476
49476
|
return isString$4(value) && (value.startsWith('=') || /{{.*?}}/.test(value));
|
|
49477
49477
|
}
|
|
49478
49478
|
|
|
49479
|
-
/**
|
|
49480
|
-
* Retrieve variable names from a given feelers template.
|
|
49481
|
-
*
|
|
49482
|
-
* @param {string} template
|
|
49483
|
-
*
|
|
49484
|
-
* @returns {string[]}
|
|
49479
|
+
/**
|
|
49480
|
+
* Retrieve variable names from a given feelers template.
|
|
49481
|
+
*
|
|
49482
|
+
* @param {string} template
|
|
49483
|
+
*
|
|
49484
|
+
* @returns {string[]}
|
|
49485
49485
|
*/
|
|
49486
49486
|
getVariableNames(template) {
|
|
49487
49487
|
if (!this.isTemplate(template)) {
|
|
@@ -49507,17 +49507,17 @@
|
|
|
49507
49507
|
}, []);
|
|
49508
49508
|
}
|
|
49509
49509
|
|
|
49510
|
-
/**
|
|
49511
|
-
* Evaluate a template.
|
|
49512
|
-
*
|
|
49513
|
-
* @param {string} template
|
|
49514
|
-
* @param {Object<string, any>} context
|
|
49515
|
-
* @param {Object} options
|
|
49516
|
-
* @param {boolean} [options.debug = false]
|
|
49517
|
-
* @param {boolean} [options.strict = false]
|
|
49518
|
-
* @param {Function} [options.buildDebugString]
|
|
49519
|
-
*
|
|
49520
|
-
* @returns
|
|
49510
|
+
/**
|
|
49511
|
+
* Evaluate a template.
|
|
49512
|
+
*
|
|
49513
|
+
* @param {string} template
|
|
49514
|
+
* @param {Object<string, any>} context
|
|
49515
|
+
* @param {Object} options
|
|
49516
|
+
* @param {boolean} [options.debug = false]
|
|
49517
|
+
* @param {boolean} [options.strict = false]
|
|
49518
|
+
* @param {Function} [options.buildDebugString]
|
|
49519
|
+
*
|
|
49520
|
+
* @returns
|
|
49521
49521
|
*/
|
|
49522
49522
|
evaluate(template, context = {}, options = {}) {
|
|
49523
49523
|
const {
|
|
@@ -49532,22 +49532,22 @@
|
|
|
49532
49532
|
});
|
|
49533
49533
|
}
|
|
49534
49534
|
|
|
49535
|
-
/**
|
|
49536
|
-
* @typedef {Object} ExpressionWithDepth
|
|
49537
|
-
* @property {number} depth - The depth of the expression in the syntax tree.
|
|
49538
|
-
* @property {string} expression - The extracted expression
|
|
49535
|
+
/**
|
|
49536
|
+
* @typedef {Object} ExpressionWithDepth
|
|
49537
|
+
* @property {number} depth - The depth of the expression in the syntax tree.
|
|
49538
|
+
* @property {string} expression - The extracted expression
|
|
49539
49539
|
*/
|
|
49540
49540
|
|
|
49541
|
-
/**
|
|
49542
|
-
* Extracts all feel expressions in the template along with their depth in the syntax tree.
|
|
49543
|
-
* The depth is incremented for child expressions of loops to account for context drilling.
|
|
49544
|
-
|
|
49545
|
-
* @param {string} template - A feelers template string.
|
|
49546
|
-
* @returns {Array<ExpressionWithDepth>} An array of objects, each containing the depth and the extracted expression.
|
|
49547
|
-
*
|
|
49548
|
-
* @example
|
|
49549
|
-
* const template = "Hello {{user}}, you have:{{#loop items}}\n- {{amount}} {{name}}{{/loop}}.";
|
|
49550
|
-
* const extractedExpressions = _extractExpressionsWithDepth(template);
|
|
49541
|
+
/**
|
|
49542
|
+
* Extracts all feel expressions in the template along with their depth in the syntax tree.
|
|
49543
|
+
* The depth is incremented for child expressions of loops to account for context drilling.
|
|
49544
|
+
* @name extractExpressionsWithDepth
|
|
49545
|
+
* @param {string} template - A feelers template string.
|
|
49546
|
+
* @returns {Array<ExpressionWithDepth>} An array of objects, each containing the depth and the extracted expression.
|
|
49547
|
+
*
|
|
49548
|
+
* @example
|
|
49549
|
+
* const template = "Hello {{user}}, you have:{{#loop items}}\n- {{amount}} {{name}}{{/loop}}.";
|
|
49550
|
+
* const extractedExpressions = _extractExpressionsWithDepth(template);
|
|
49551
49551
|
*/
|
|
49552
49552
|
_extractExpressionsWithDepth(template) {
|
|
49553
49553
|
// build simplified feelers syntax tree
|
|
@@ -49578,9 +49578,9 @@
|
|
|
49578
49578
|
}
|
|
49579
49579
|
FeelersTemplating.$inject = [];
|
|
49580
49580
|
|
|
49581
|
-
/**
|
|
49582
|
-
* @typedef {object} Condition
|
|
49583
|
-
* @property {string} [hide]
|
|
49581
|
+
/**
|
|
49582
|
+
* @typedef {object} Condition
|
|
49583
|
+
* @property {string} [hide]
|
|
49584
49584
|
*/
|
|
49585
49585
|
|
|
49586
49586
|
class ConditionChecker {
|
|
@@ -49589,11 +49589,11 @@
|
|
|
49589
49589
|
this._eventBus = eventBus;
|
|
49590
49590
|
}
|
|
49591
49591
|
|
|
49592
|
-
/**
|
|
49593
|
-
* For given data, remove properties based on condition.
|
|
49594
|
-
*
|
|
49595
|
-
* @param {Object<string, any>} properties
|
|
49596
|
-
* @param {Object<string, any>} data
|
|
49592
|
+
/**
|
|
49593
|
+
* For given data, remove properties based on condition.
|
|
49594
|
+
*
|
|
49595
|
+
* @param {Object<string, any>} properties
|
|
49596
|
+
* @param {Object<string, any>} data
|
|
49597
49597
|
*/
|
|
49598
49598
|
applyConditions(properties, data = {}) {
|
|
49599
49599
|
const conditions = this._getConditions();
|
|
@@ -49612,13 +49612,13 @@
|
|
|
49612
49612
|
return newProperties;
|
|
49613
49613
|
}
|
|
49614
49614
|
|
|
49615
|
-
/**
|
|
49616
|
-
* Check if given condition is met. Returns null for invalid/missing conditions.
|
|
49617
|
-
*
|
|
49618
|
-
* @param {string} condition
|
|
49619
|
-
* @param {import('../../types').Data} [data]
|
|
49620
|
-
*
|
|
49621
|
-
* @returns {boolean|null}
|
|
49615
|
+
/**
|
|
49616
|
+
* Check if given condition is met. Returns null for invalid/missing conditions.
|
|
49617
|
+
*
|
|
49618
|
+
* @param {string} condition
|
|
49619
|
+
* @param {import('../../types').Data} [data]
|
|
49620
|
+
*
|
|
49621
|
+
* @returns {boolean|null}
|
|
49622
49622
|
*/
|
|
49623
49623
|
check(condition, data = {}) {
|
|
49624
49624
|
if (!condition) {
|
|
@@ -49639,12 +49639,12 @@
|
|
|
49639
49639
|
}
|
|
49640
49640
|
}
|
|
49641
49641
|
|
|
49642
|
-
/**
|
|
49643
|
-
* Check if hide condition is met.
|
|
49644
|
-
*
|
|
49645
|
-
* @param {Condition} condition
|
|
49646
|
-
* @param {Object<string, any>} data
|
|
49647
|
-
* @returns {boolean}
|
|
49642
|
+
/**
|
|
49643
|
+
* Check if hide condition is met.
|
|
49644
|
+
*
|
|
49645
|
+
* @param {Condition} condition
|
|
49646
|
+
* @param {Object<string, any>} data
|
|
49647
|
+
* @returns {boolean}
|
|
49648
49648
|
*/
|
|
49649
49649
|
_checkHideCondition(condition, data) {
|
|
49650
49650
|
if (!condition.hide) {
|
|
@@ -49685,12 +49685,12 @@
|
|
|
49685
49685
|
this._converter = new showdownExports.Converter();
|
|
49686
49686
|
}
|
|
49687
49687
|
|
|
49688
|
-
/**
|
|
49689
|
-
* Render markdown to HTML.
|
|
49690
|
-
*
|
|
49691
|
-
* @param {string} markdown - The markdown to render
|
|
49692
|
-
*
|
|
49693
|
-
* @returns {string} HTML
|
|
49688
|
+
/**
|
|
49689
|
+
* Render markdown to HTML.
|
|
49690
|
+
*
|
|
49691
|
+
* @param {string} markdown - The markdown to render
|
|
49692
|
+
*
|
|
49693
|
+
* @returns {string} HTML
|
|
49694
49694
|
*/
|
|
49695
49695
|
render(markdown) {
|
|
49696
49696
|
return this._converter.makeHtml(markdown);
|
|
@@ -50341,23 +50341,23 @@
|
|
|
50341
50341
|
};
|
|
50342
50342
|
FormFieldRegistry$1.$inject = ['eventBus'];
|
|
50343
50343
|
|
|
50344
|
-
/**
|
|
50345
|
-
* @typedef { { id: String, components: Array<String> } } FormRow
|
|
50346
|
-
* @typedef { { formFieldId: String, rows: Array<FormRow> } } FormRows
|
|
50344
|
+
/**
|
|
50345
|
+
* @typedef { { id: String, components: Array<String> } } FormRow
|
|
50346
|
+
* @typedef { { formFieldId: String, rows: Array<FormRow> } } FormRows
|
|
50347
50347
|
*/
|
|
50348
50348
|
|
|
50349
|
-
/**
|
|
50350
|
-
* Maintains the Form layout in a given structure, for example
|
|
50351
|
-
*
|
|
50352
|
-
* [
|
|
50353
|
-
* {
|
|
50354
|
-
* formFieldId: 'FormField_1',
|
|
50355
|
-
* rows: [
|
|
50356
|
-
* { id: 'Row_1', components: [ 'Text_1', 'Textdield_1', ... ] }
|
|
50357
|
-
* ]
|
|
50358
|
-
* }
|
|
50359
|
-
* ]
|
|
50360
|
-
*
|
|
50349
|
+
/**
|
|
50350
|
+
* Maintains the Form layout in a given structure, for example
|
|
50351
|
+
*
|
|
50352
|
+
* [
|
|
50353
|
+
* {
|
|
50354
|
+
* formFieldId: 'FormField_1',
|
|
50355
|
+
* rows: [
|
|
50356
|
+
* { id: 'Row_1', components: [ 'Text_1', 'Textdield_1', ... ] }
|
|
50357
|
+
* ]
|
|
50358
|
+
* }
|
|
50359
|
+
* ]
|
|
50360
|
+
*
|
|
50361
50361
|
*/
|
|
50362
50362
|
class FormLayouter {
|
|
50363
50363
|
constructor(eventBus) {
|
|
@@ -50367,8 +50367,8 @@
|
|
|
50367
50367
|
this._eventBus = eventBus;
|
|
50368
50368
|
}
|
|
50369
50369
|
|
|
50370
|
-
/**
|
|
50371
|
-
* @param {FormRow} row
|
|
50370
|
+
/**
|
|
50371
|
+
* @param {FormRow} row
|
|
50372
50372
|
*/
|
|
50373
50373
|
addRow(formFieldId, row) {
|
|
50374
50374
|
let rowsPerComponent = this._rows.find(r => r.formFieldId === formFieldId);
|
|
@@ -50382,18 +50382,18 @@
|
|
|
50382
50382
|
rowsPerComponent.rows.push(row);
|
|
50383
50383
|
}
|
|
50384
50384
|
|
|
50385
|
-
/**
|
|
50386
|
-
* @param {String} id
|
|
50387
|
-
* @returns {FormRow}
|
|
50385
|
+
/**
|
|
50386
|
+
* @param {String} id
|
|
50387
|
+
* @returns {FormRow}
|
|
50388
50388
|
*/
|
|
50389
50389
|
getRow(id) {
|
|
50390
50390
|
const rows = allRows(this._rows);
|
|
50391
50391
|
return rows.find(r => r.id === id);
|
|
50392
50392
|
}
|
|
50393
50393
|
|
|
50394
|
-
/**
|
|
50395
|
-
* @param {any} formField
|
|
50396
|
-
* @returns {FormRow}
|
|
50394
|
+
/**
|
|
50395
|
+
* @param {any} formField
|
|
50396
|
+
* @returns {FormRow}
|
|
50397
50397
|
*/
|
|
50398
50398
|
getRowForField(formField) {
|
|
50399
50399
|
return allRows(this._rows).find(r => {
|
|
@@ -50404,9 +50404,9 @@
|
|
|
50404
50404
|
});
|
|
50405
50405
|
}
|
|
50406
50406
|
|
|
50407
|
-
/**
|
|
50408
|
-
* @param {String} formFieldId
|
|
50409
|
-
* @returns { Array<FormRow> }
|
|
50407
|
+
/**
|
|
50408
|
+
* @param {String} formFieldId
|
|
50409
|
+
* @returns { Array<FormRow> }
|
|
50410
50410
|
*/
|
|
50411
50411
|
getRows(formFieldId) {
|
|
50412
50412
|
const rowsForField = this._rows.find(r => formFieldId === r.formFieldId);
|
|
@@ -50416,15 +50416,15 @@
|
|
|
50416
50416
|
return rowsForField.rows;
|
|
50417
50417
|
}
|
|
50418
50418
|
|
|
50419
|
-
/**
|
|
50420
|
-
* @returns {string}
|
|
50419
|
+
/**
|
|
50420
|
+
* @returns {string}
|
|
50421
50421
|
*/
|
|
50422
50422
|
nextRowId() {
|
|
50423
50423
|
return this._ids.nextPrefixed('Row_');
|
|
50424
50424
|
}
|
|
50425
50425
|
|
|
50426
|
-
/**
|
|
50427
|
-
* @param {any} formField
|
|
50426
|
+
/**
|
|
50427
|
+
* @param {any} formField
|
|
50428
50428
|
*/
|
|
50429
50429
|
calculateLayout(formField) {
|
|
50430
50430
|
const {
|
|
@@ -50478,9 +50478,9 @@
|
|
|
50478
50478
|
});
|
|
50479
50479
|
}
|
|
50480
50480
|
|
|
50481
|
-
/**
|
|
50482
|
-
* @param {Array<FormRows>} formRows
|
|
50483
|
-
* @returns {Array<FormRow>}
|
|
50481
|
+
/**
|
|
50482
|
+
* @param {Array<FormRows>} formRows
|
|
50483
|
+
* @returns {Array<FormRow>}
|
|
50484
50484
|
*/
|
|
50485
50485
|
function allRows(formRows) {
|
|
50486
50486
|
return flatten$3(formRows.map(c => c.rows));
|
|
@@ -50556,10 +50556,10 @@
|
|
|
50556
50556
|
return injector;
|
|
50557
50557
|
}
|
|
50558
50558
|
|
|
50559
|
-
/**
|
|
50560
|
-
* @param {string?} prefix
|
|
50561
|
-
*
|
|
50562
|
-
* @returns Element
|
|
50559
|
+
/**
|
|
50560
|
+
* @param {string?} prefix
|
|
50561
|
+
*
|
|
50562
|
+
* @returns Element
|
|
50563
50563
|
*/
|
|
50564
50564
|
function createFormContainer(prefix = 'fjs') {
|
|
50565
50565
|
const container = document.createElement('div');
|
|
@@ -50590,22 +50590,22 @@
|
|
|
50590
50590
|
return `${type}${generateIndexForType(type)}`;
|
|
50591
50591
|
}
|
|
50592
50592
|
|
|
50593
|
-
/**
|
|
50594
|
-
* @template T
|
|
50595
|
-
* @param {T} data
|
|
50596
|
-
* @param {(this: any, key: string, value: any) => any} [replacer]
|
|
50597
|
-
* @return {T}
|
|
50593
|
+
/**
|
|
50594
|
+
* @template T
|
|
50595
|
+
* @param {T} data
|
|
50596
|
+
* @param {(this: any, key: string, value: any) => any} [replacer]
|
|
50597
|
+
* @return {T}
|
|
50598
50598
|
*/
|
|
50599
50599
|
function clone(data, replacer) {
|
|
50600
50600
|
return JSON.parse(JSON.stringify(data, replacer));
|
|
50601
50601
|
}
|
|
50602
50602
|
|
|
50603
|
-
/**
|
|
50604
|
-
* Parse the schema for input variables a form might make use of
|
|
50605
|
-
*
|
|
50606
|
-
* @param {any} schema
|
|
50607
|
-
*
|
|
50608
|
-
* @return {string[]}
|
|
50603
|
+
/**
|
|
50604
|
+
* Parse the schema for input variables a form might make use of
|
|
50605
|
+
*
|
|
50606
|
+
* @param {any} schema
|
|
50607
|
+
*
|
|
50608
|
+
* @return {string[]}
|
|
50609
50609
|
*/
|
|
50610
50610
|
function getSchemaVariables(schema, expressionLanguage = new FeelExpressionLanguage(null), templating = new FeelersTemplating()) {
|
|
50611
50611
|
if (!schema.components) {
|
|
@@ -50656,11 +50656,11 @@
|
|
|
50656
50656
|
return Array.from(new Set(variables));
|
|
50657
50657
|
}
|
|
50658
50658
|
let Importer$1 = class Importer {
|
|
50659
|
-
/**
|
|
50660
|
-
* @constructor
|
|
50661
|
-
* @param { import('../core').FormFieldRegistry } formFieldRegistry
|
|
50662
|
-
* @param { import('../render/FormFields').default } formFields
|
|
50663
|
-
* @param { import('../core').FormLayouter } formLayouter
|
|
50659
|
+
/**
|
|
50660
|
+
* @constructor
|
|
50661
|
+
* @param { import('../core').FormFieldRegistry } formFieldRegistry
|
|
50662
|
+
* @param { import('../render/FormFields').default } formFields
|
|
50663
|
+
* @param { import('../core').FormLayouter } formLayouter
|
|
50664
50664
|
*/
|
|
50665
50665
|
constructor(formFieldRegistry, formFields, formLayouter) {
|
|
50666
50666
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -50668,15 +50668,15 @@
|
|
|
50668
50668
|
this._formLayouter = formLayouter;
|
|
50669
50669
|
}
|
|
50670
50670
|
|
|
50671
|
-
/**
|
|
50672
|
-
* Import schema adding `id`, `_parent` and `_path`
|
|
50673
|
-
* information to each field and adding it to the
|
|
50674
|
-
* form field registry.
|
|
50675
|
-
*
|
|
50676
|
-
* @param {any} schema
|
|
50677
|
-
* @param {any} [data]
|
|
50678
|
-
*
|
|
50679
|
-
* @return { { warnings: Array<any>, schema: any, data: any } }
|
|
50671
|
+
/**
|
|
50672
|
+
* Import schema adding `id`, `_parent` and `_path`
|
|
50673
|
+
* information to each field and adding it to the
|
|
50674
|
+
* form field registry.
|
|
50675
|
+
*
|
|
50676
|
+
* @param {any} schema
|
|
50677
|
+
* @param {any} [data]
|
|
50678
|
+
*
|
|
50679
|
+
* @return { { warnings: Array<any>, schema: any, data: any } }
|
|
50680
50680
|
*/
|
|
50681
50681
|
importSchema(schema, data = {}) {
|
|
50682
50682
|
// TODO: Add warnings - https://github.com/bpmn-io/form-js/issues/289
|
|
@@ -50697,11 +50697,11 @@
|
|
|
50697
50697
|
}
|
|
50698
50698
|
}
|
|
50699
50699
|
|
|
50700
|
-
/**
|
|
50701
|
-
* @param {any} formField
|
|
50702
|
-
* @param {string} [parentId]
|
|
50703
|
-
*
|
|
50704
|
-
* @return {any} importedField
|
|
50700
|
+
/**
|
|
50701
|
+
* @param {any} formField
|
|
50702
|
+
* @param {string} [parentId]
|
|
50703
|
+
*
|
|
50704
|
+
* @return {any} importedField
|
|
50705
50705
|
*/
|
|
50706
50706
|
importFormField(formField, parentId) {
|
|
50707
50707
|
const {
|
|
@@ -50752,10 +50752,10 @@
|
|
|
50752
50752
|
});
|
|
50753
50753
|
}
|
|
50754
50754
|
|
|
50755
|
-
/**
|
|
50756
|
-
* @param {Object} data
|
|
50757
|
-
*
|
|
50758
|
-
* @return {Object} initializedData
|
|
50755
|
+
/**
|
|
50756
|
+
* @param {Object} data
|
|
50757
|
+
*
|
|
50758
|
+
* @return {Object} initializedData
|
|
50759
50759
|
*/
|
|
50760
50760
|
initializeFieldValues(data) {
|
|
50761
50761
|
return this._formFieldRegistry.getAll().reduce((initializedData, formField) => {
|
|
@@ -50889,11 +50889,11 @@
|
|
|
50889
50889
|
});
|
|
50890
50890
|
var FormRenderContext$1 = FormRenderContext;
|
|
50891
50891
|
|
|
50892
|
-
/**
|
|
50893
|
-
* @param {string} type
|
|
50894
|
-
* @param {boolean} [strict]
|
|
50895
|
-
*
|
|
50896
|
-
* @returns {any}
|
|
50892
|
+
/**
|
|
50893
|
+
* @param {string} type
|
|
50894
|
+
* @param {boolean} [strict]
|
|
50895
|
+
*
|
|
50896
|
+
* @returns {any}
|
|
50897
50897
|
*/
|
|
50898
50898
|
function getService$1(type, strict) {}
|
|
50899
50899
|
const FormContext = D$1({
|
|
@@ -50908,10 +50908,10 @@
|
|
|
50908
50908
|
return getService(type, strict);
|
|
50909
50909
|
}
|
|
50910
50910
|
|
|
50911
|
-
/**
|
|
50912
|
-
* Returns the conditionally filtered data of a form reactively.
|
|
50913
|
-
* Memoised to minimize re-renders
|
|
50914
|
-
*
|
|
50911
|
+
/**
|
|
50912
|
+
* Returns the conditionally filtered data of a form reactively.
|
|
50913
|
+
* Memoised to minimize re-renders
|
|
50914
|
+
*
|
|
50915
50915
|
*/
|
|
50916
50916
|
function useFilteredFormData() {
|
|
50917
50917
|
const {
|
|
@@ -50928,12 +50928,12 @@
|
|
|
50928
50928
|
}, [conditionChecker, data, initialData]);
|
|
50929
50929
|
}
|
|
50930
50930
|
|
|
50931
|
-
/**
|
|
50932
|
-
* Evaluate if condition is met reactively based on the conditionChecker and form data.
|
|
50933
|
-
*
|
|
50934
|
-
* @param {string | undefined} condition
|
|
50935
|
-
*
|
|
50936
|
-
* @returns {boolean} true if condition is met or no condition or condition checker exists
|
|
50931
|
+
/**
|
|
50932
|
+
* Evaluate if condition is met reactively based on the conditionChecker and form data.
|
|
50933
|
+
*
|
|
50934
|
+
* @param {string | undefined} condition
|
|
50935
|
+
*
|
|
50936
|
+
* @returns {boolean} true if condition is met or no condition or condition checker exists
|
|
50937
50937
|
*/
|
|
50938
50938
|
function useCondition(condition) {
|
|
50939
50939
|
const conditionChecker = useService$1('conditionChecker', false);
|
|
@@ -50943,13 +50943,13 @@
|
|
|
50943
50943
|
}, [conditionChecker, condition, filteredData]);
|
|
50944
50944
|
}
|
|
50945
50945
|
|
|
50946
|
-
/**
|
|
50947
|
-
* Evaluate a string reactively based on the expressionLanguage and form data.
|
|
50948
|
-
* If the string is not an expression, it is returned as is.
|
|
50949
|
-
* Memoised to minimize re-renders.
|
|
50950
|
-
*
|
|
50951
|
-
* @param {string} value
|
|
50952
|
-
*
|
|
50946
|
+
/**
|
|
50947
|
+
* Evaluate a string reactively based on the expressionLanguage and form data.
|
|
50948
|
+
* If the string is not an expression, it is returned as is.
|
|
50949
|
+
* Memoised to minimize re-renders.
|
|
50950
|
+
*
|
|
50951
|
+
* @param {string} value
|
|
50952
|
+
*
|
|
50953
50953
|
*/
|
|
50954
50954
|
function useExpressionEvaluation(value) {
|
|
50955
50955
|
const formData = useFilteredFormData();
|
|
@@ -50977,16 +50977,16 @@
|
|
|
50977
50977
|
});
|
|
50978
50978
|
}
|
|
50979
50979
|
|
|
50980
|
-
/**
|
|
50981
|
-
* Retrieve readonly value of a form field, given it can be an
|
|
50982
|
-
* expression optionally or configured globally.
|
|
50983
|
-
*
|
|
50984
|
-
* @typedef { import('../../types').FormProperties } FormProperties
|
|
50985
|
-
*
|
|
50986
|
-
* @param {any} formField
|
|
50987
|
-
* @param {FormProperties} properties
|
|
50988
|
-
*
|
|
50989
|
-
* @returns {boolean}
|
|
50980
|
+
/**
|
|
50981
|
+
* Retrieve readonly value of a form field, given it can be an
|
|
50982
|
+
* expression optionally or configured globally.
|
|
50983
|
+
*
|
|
50984
|
+
* @typedef { import('../../types').FormProperties } FormProperties
|
|
50985
|
+
*
|
|
50986
|
+
* @param {any} formField
|
|
50987
|
+
* @param {FormProperties} properties
|
|
50988
|
+
*
|
|
50989
|
+
* @returns {boolean}
|
|
50990
50990
|
*/
|
|
50991
50991
|
function useReadonly(formField, properties = {}) {
|
|
50992
50992
|
const expressionLanguage = useService$1('expressionLanguage');
|
|
@@ -51004,16 +51004,16 @@
|
|
|
51004
51004
|
return readonly || false;
|
|
51005
51005
|
}
|
|
51006
51006
|
|
|
51007
|
-
/**
|
|
51008
|
-
* Template a string reactively based on form data. If the string is not a template, it is returned as is.
|
|
51009
|
-
* Memoised to minimize re-renders
|
|
51010
|
-
*
|
|
51011
|
-
* @param {string} value
|
|
51012
|
-
* @param {Object} options
|
|
51013
|
-
* @param {boolean} [options.debug = false]
|
|
51014
|
-
* @param {boolean} [options.strict = false]
|
|
51015
|
-
* @param {Function} [options.buildDebugString]
|
|
51016
|
-
*
|
|
51007
|
+
/**
|
|
51008
|
+
* Template a string reactively based on form data. If the string is not a template, it is returned as is.
|
|
51009
|
+
* Memoised to minimize re-renders
|
|
51010
|
+
*
|
|
51011
|
+
* @param {string} value
|
|
51012
|
+
* @param {Object} options
|
|
51013
|
+
* @param {boolean} [options.debug = false]
|
|
51014
|
+
* @param {boolean} [options.strict = false]
|
|
51015
|
+
* @param {Function} [options.buildDebugString]
|
|
51016
|
+
*
|
|
51017
51017
|
*/
|
|
51018
51018
|
function useTemplateEvaluation(value, options) {
|
|
51019
51019
|
const filteredData = useFilteredFormData();
|
|
@@ -51026,17 +51026,17 @@
|
|
|
51026
51026
|
}, [filteredData, templating, value, options]);
|
|
51027
51027
|
}
|
|
51028
51028
|
|
|
51029
|
-
/**
|
|
51030
|
-
* Template a string reactively based on form data. If the string is not a template, it is returned as is.
|
|
51031
|
-
* If the string contains multiple lines, only the first line is returned.
|
|
51032
|
-
* Memoised to minimize re-renders
|
|
51033
|
-
*
|
|
51034
|
-
* @param {string} value
|
|
51035
|
-
* @param {Object} [options]
|
|
51036
|
-
* @param {boolean} [options.debug = false]
|
|
51037
|
-
* @param {boolean} [options.strict = false]
|
|
51038
|
-
* @param {Function} [options.buildDebugString]
|
|
51039
|
-
*
|
|
51029
|
+
/**
|
|
51030
|
+
* Template a string reactively based on form data. If the string is not a template, it is returned as is.
|
|
51031
|
+
* If the string contains multiple lines, only the first line is returned.
|
|
51032
|
+
* Memoised to minimize re-renders
|
|
51033
|
+
*
|
|
51034
|
+
* @param {string} value
|
|
51035
|
+
* @param {Object} [options]
|
|
51036
|
+
* @param {boolean} [options.debug = false]
|
|
51037
|
+
* @param {boolean} [options.strict = false]
|
|
51038
|
+
* @param {Function} [options.buildDebugString]
|
|
51039
|
+
*
|
|
51040
51040
|
*/
|
|
51041
51041
|
function useSingleLineTemplateEvaluation(value, options = {}) {
|
|
51042
51042
|
const evaluatedTemplate = useTemplateEvaluation(value, options);
|
|
@@ -51219,8 +51219,8 @@
|
|
|
51219
51219
|
return value || value === 0 || value === false;
|
|
51220
51220
|
}
|
|
51221
51221
|
|
|
51222
|
-
/**
|
|
51223
|
-
* @enum { String }
|
|
51222
|
+
/**
|
|
51223
|
+
* @enum { String }
|
|
51224
51224
|
*/
|
|
51225
51225
|
const LOAD_STATES = {
|
|
51226
51226
|
LOADING: 'loading',
|
|
@@ -51228,17 +51228,17 @@
|
|
|
51228
51228
|
ERROR: 'error'
|
|
51229
51229
|
};
|
|
51230
51230
|
|
|
51231
|
-
/**
|
|
51232
|
-
* @typedef {Object} ValuesGetter
|
|
51233
|
-
* @property {Object[]} values - The values data
|
|
51234
|
-
* @property {(LOAD_STATES)} state - The values data's loading state, to use for conditional rendering
|
|
51231
|
+
/**
|
|
51232
|
+
* @typedef {Object} ValuesGetter
|
|
51233
|
+
* @property {Object[]} values - The values data
|
|
51234
|
+
* @property {(LOAD_STATES)} state - The values data's loading state, to use for conditional rendering
|
|
51235
51235
|
*/
|
|
51236
51236
|
|
|
51237
|
-
/**
|
|
51238
|
-
* A hook to load values for single and multiselect components.
|
|
51239
|
-
*
|
|
51240
|
-
* @param {Object} field - The form field to handle values for
|
|
51241
|
-
* @return {ValuesGetter} valuesGetter - A values getter object providing loading state and values
|
|
51237
|
+
/**
|
|
51238
|
+
* A hook to load values for single and multiselect components.
|
|
51239
|
+
*
|
|
51240
|
+
* @param {Object} field - The form field to handle values for
|
|
51241
|
+
* @return {ValuesGetter} valuesGetter - A values getter object providing loading state and values
|
|
51242
51242
|
*/
|
|
51243
51243
|
function useValuesAsync(field) {
|
|
51244
51244
|
const {
|
|
@@ -52368,10 +52368,10 @@
|
|
|
52368
52368
|
}
|
|
52369
52369
|
};
|
|
52370
52370
|
|
|
52371
|
-
/**
|
|
52372
|
-
* This file must not be changed or exchanged.
|
|
52373
|
-
*
|
|
52374
|
-
* @see http://bpmn.io/license for more information.
|
|
52371
|
+
/**
|
|
52372
|
+
* This file must not be changed or exchanged.
|
|
52373
|
+
*
|
|
52374
|
+
* @see http://bpmn.io/license for more information.
|
|
52375
52375
|
*/
|
|
52376
52376
|
function Logo() {
|
|
52377
52377
|
return e$1("svg", {
|
|
@@ -52501,11 +52501,11 @@
|
|
|
52501
52501
|
|
|
52502
52502
|
const FORM_ELEMENT = document.createElement('form');
|
|
52503
52503
|
|
|
52504
|
-
/**
|
|
52505
|
-
* Sanitize a HTML string and return the cleaned, safe version.
|
|
52506
|
-
*
|
|
52507
|
-
* @param {string} html
|
|
52508
|
-
* @return {string}
|
|
52504
|
+
/**
|
|
52505
|
+
* Sanitize a HTML string and return the cleaned, safe version.
|
|
52506
|
+
*
|
|
52507
|
+
* @param {string} html
|
|
52508
|
+
* @return {string}
|
|
52509
52509
|
*/
|
|
52510
52510
|
|
|
52511
52511
|
// see https://github.com/developit/snarkdown/issues/70
|
|
@@ -52523,29 +52523,29 @@
|
|
|
52523
52523
|
}
|
|
52524
52524
|
}
|
|
52525
52525
|
|
|
52526
|
-
/**
|
|
52527
|
-
* Sanitizes an image source to ensure we only allow for data URI and links
|
|
52528
|
-
* that start with http(s).
|
|
52529
|
-
*
|
|
52530
|
-
* Note: Most browsers anyway do not support script execution in <img> elements.
|
|
52531
|
-
*
|
|
52532
|
-
* @param {string} src
|
|
52533
|
-
* @returns {string}
|
|
52526
|
+
/**
|
|
52527
|
+
* Sanitizes an image source to ensure we only allow for data URI and links
|
|
52528
|
+
* that start with http(s).
|
|
52529
|
+
*
|
|
52530
|
+
* Note: Most browsers anyway do not support script execution in <img> elements.
|
|
52531
|
+
*
|
|
52532
|
+
* @param {string} src
|
|
52533
|
+
* @returns {string}
|
|
52534
52534
|
*/
|
|
52535
52535
|
function sanitizeImageSource(src) {
|
|
52536
52536
|
const valid = ALLOWED_IMAGE_SRC_PATTERN.test(src);
|
|
52537
52537
|
return valid ? src : '';
|
|
52538
52538
|
}
|
|
52539
52539
|
|
|
52540
|
-
/**
|
|
52541
|
-
* Recursively sanitize a HTML node, potentially
|
|
52542
|
-
* removing it, its children or attributes.
|
|
52543
|
-
*
|
|
52544
|
-
* Inspired by https://github.com/developit/snarkdown/issues/70
|
|
52545
|
-
* and https://github.com/cure53/DOMPurify. Simplified
|
|
52546
|
-
* for our use-case.
|
|
52547
|
-
*
|
|
52548
|
-
* @param {Element} node
|
|
52540
|
+
/**
|
|
52541
|
+
* Recursively sanitize a HTML node, potentially
|
|
52542
|
+
* removing it, its children or attributes.
|
|
52543
|
+
*
|
|
52544
|
+
* Inspired by https://github.com/developit/snarkdown/issues/70
|
|
52545
|
+
* and https://github.com/cure53/DOMPurify. Simplified
|
|
52546
|
+
* for our use-case.
|
|
52547
|
+
*
|
|
52548
|
+
* @param {Element} node
|
|
52549
52549
|
*/
|
|
52550
52550
|
function sanitizeNode(node) {
|
|
52551
52551
|
// allow text nodes
|
|
@@ -52589,13 +52589,13 @@
|
|
|
52589
52589
|
}
|
|
52590
52590
|
}
|
|
52591
52591
|
|
|
52592
|
-
/**
|
|
52593
|
-
* Validates attributes for validity.
|
|
52594
|
-
*
|
|
52595
|
-
* @param {string} lcTag
|
|
52596
|
-
* @param {string} lcName
|
|
52597
|
-
* @param {string} value
|
|
52598
|
-
* @return {boolean}
|
|
52592
|
+
/**
|
|
52593
|
+
* Validates attributes for validity.
|
|
52594
|
+
*
|
|
52595
|
+
* @param {string} lcTag
|
|
52596
|
+
* @param {string} lcName
|
|
52597
|
+
* @param {string} value
|
|
52598
|
+
* @return {boolean}
|
|
52599
52599
|
*/
|
|
52600
52600
|
function isValidAttribute(lcTag, lcName, value) {
|
|
52601
52601
|
// disallow most attributes based on whitelist
|
|
@@ -58558,10 +58558,10 @@
|
|
|
58558
58558
|
return fn.apply(null, args);
|
|
58559
58559
|
}
|
|
58560
58560
|
|
|
58561
|
-
/**
|
|
58562
|
-
* A factory to create a configurable debouncer.
|
|
58563
|
-
*
|
|
58564
|
-
* @param {number|boolean} [config=true]
|
|
58561
|
+
/**
|
|
58562
|
+
* A factory to create a configurable debouncer.
|
|
58563
|
+
*
|
|
58564
|
+
* @param {number|boolean} [config=true]
|
|
58565
58565
|
*/
|
|
58566
58566
|
function DebounceFactory(config = true) {
|
|
58567
58567
|
const timeout = typeof config === 'number' ? config : config ? 300 : 0;
|
|
@@ -58573,11 +58573,11 @@
|
|
|
58573
58573
|
}
|
|
58574
58574
|
DebounceFactory.$inject = ['config.debounce'];
|
|
58575
58575
|
class FieldFactory {
|
|
58576
|
-
/**
|
|
58577
|
-
* @constructor
|
|
58578
|
-
*
|
|
58579
|
-
* @param { import('./FormFieldRegistry').default } formFieldRegistry
|
|
58580
|
-
* @param { import('@bpmn-io/form-js-viewer').FormFields } formFields
|
|
58576
|
+
/**
|
|
58577
|
+
* @constructor
|
|
58578
|
+
*
|
|
58579
|
+
* @param { import('./FormFieldRegistry').default } formFieldRegistry
|
|
58580
|
+
* @param { import('@bpmn-io/form-js-viewer').FormFields } formFields
|
|
58581
58581
|
*/
|
|
58582
58582
|
constructor(formFieldRegistry, formFields) {
|
|
58583
58583
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -58639,11 +58639,11 @@
|
|
|
58639
58639
|
}
|
|
58640
58640
|
FieldFactory.$inject = ['formFieldRegistry', 'formFields'];
|
|
58641
58641
|
class FormFieldRegistry extends FormFieldRegistry$1 {
|
|
58642
|
-
/**
|
|
58643
|
-
* Updates a form fields id.
|
|
58644
|
-
*
|
|
58645
|
-
* @param {Object} formField
|
|
58646
|
-
* @param {string} newId
|
|
58642
|
+
/**
|
|
58643
|
+
* Updates a form fields id.
|
|
58644
|
+
*
|
|
58645
|
+
* @param {Object} formField
|
|
58646
|
+
* @param {string} newId
|
|
58647
58647
|
*/
|
|
58648
58648
|
updateId(formField, newId) {
|
|
58649
58649
|
this._validateId(newId);
|
|
@@ -58664,13 +58664,13 @@
|
|
|
58664
58664
|
}
|
|
58665
58665
|
}
|
|
58666
58666
|
|
|
58667
|
-
/**
|
|
58668
|
-
* Validate the suitability of the given id and signals a problem
|
|
58669
|
-
* with an exception.
|
|
58670
|
-
*
|
|
58671
|
-
* @param {string} id
|
|
58672
|
-
*
|
|
58673
|
-
* @throws {Error} if id is empty or already assigned
|
|
58667
|
+
/**
|
|
58668
|
+
* Validate the suitability of the given id and signals a problem
|
|
58669
|
+
* with an exception.
|
|
58670
|
+
*
|
|
58671
|
+
* @param {string} id
|
|
58672
|
+
*
|
|
58673
|
+
* @throws {Error} if id is empty or already assigned
|
|
58674
58674
|
*/
|
|
58675
58675
|
_validateId(id) {
|
|
58676
58676
|
if (!id) {
|
|
@@ -58686,11 +58686,11 @@
|
|
|
58686
58686
|
const MIN_COLUMNS = 2;
|
|
58687
58687
|
const MAX_FIELDS_PER_ROW = 4;
|
|
58688
58688
|
class FormLayoutValidator {
|
|
58689
|
-
/**
|
|
58690
|
-
* @constructor
|
|
58691
|
-
*
|
|
58692
|
-
* @param { import('./FormLayouter').default } formLayouter
|
|
58693
|
-
* @param { import('./FormFieldRegistry').default } formFieldRegistry
|
|
58689
|
+
/**
|
|
58690
|
+
* @constructor
|
|
58691
|
+
*
|
|
58692
|
+
* @param { import('./FormLayouter').default } formLayouter
|
|
58693
|
+
* @param { import('./FormFieldRegistry').default } formFieldRegistry
|
|
58694
58694
|
*/
|
|
58695
58695
|
constructor(formLayouter, formFieldRegistry) {
|
|
58696
58696
|
this._formLayouter = formLayouter;
|
|
@@ -58749,11 +58749,11 @@
|
|
|
58749
58749
|
return MAX_COLUMNS_PER_ROW - autoCols * 2;
|
|
58750
58750
|
}
|
|
58751
58751
|
class Importer {
|
|
58752
|
-
/**
|
|
58753
|
-
* @constructor
|
|
58754
|
-
* @param { import('../core/FormFieldRegistry').default } formFieldRegistry
|
|
58755
|
-
* @param { import('../core/FieldFactory').default } fieldFactory
|
|
58756
|
-
* @param { import('../core/FormLayouter').default } formLayouter
|
|
58752
|
+
/**
|
|
58753
|
+
* @constructor
|
|
58754
|
+
* @param { import('../core/FormFieldRegistry').default } formFieldRegistry
|
|
58755
|
+
* @param { import('../core/FieldFactory').default } fieldFactory
|
|
58756
|
+
* @param { import('../core/FormLayouter').default } formLayouter
|
|
58757
58757
|
*/
|
|
58758
58758
|
constructor(formFieldRegistry, fieldFactory, formLayouter) {
|
|
58759
58759
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -58761,21 +58761,21 @@
|
|
|
58761
58761
|
this._formLayouter = formLayouter;
|
|
58762
58762
|
}
|
|
58763
58763
|
|
|
58764
|
-
/**
|
|
58765
|
-
* Import schema creating rows, fields, attaching additional
|
|
58766
|
-
* information to each field and adding fields to the
|
|
58767
|
-
* field registry.
|
|
58768
|
-
*
|
|
58769
|
-
* Additional information attached:
|
|
58770
|
-
*
|
|
58771
|
-
* * `id` (unless present)
|
|
58772
|
-
* * `_parent`
|
|
58773
|
-
* * `_path`
|
|
58774
|
-
*
|
|
58775
|
-
* @param {any} schema
|
|
58776
|
-
*
|
|
58777
|
-
* @typedef {{ warnings: Error[], schema: any }} ImportResult
|
|
58778
|
-
* @returns {ImportResult}
|
|
58764
|
+
/**
|
|
58765
|
+
* Import schema creating rows, fields, attaching additional
|
|
58766
|
+
* information to each field and adding fields to the
|
|
58767
|
+
* field registry.
|
|
58768
|
+
*
|
|
58769
|
+
* Additional information attached:
|
|
58770
|
+
*
|
|
58771
|
+
* * `id` (unless present)
|
|
58772
|
+
* * `_parent`
|
|
58773
|
+
* * `_path`
|
|
58774
|
+
*
|
|
58775
|
+
* @param {any} schema
|
|
58776
|
+
*
|
|
58777
|
+
* @typedef {{ warnings: Error[], schema: any }} ImportResult
|
|
58778
|
+
* @returns {ImportResult}
|
|
58779
58779
|
*/
|
|
58780
58780
|
importSchema(schema) {
|
|
58781
58781
|
// TODO: Add warnings
|
|
@@ -58793,12 +58793,12 @@
|
|
|
58793
58793
|
}
|
|
58794
58794
|
}
|
|
58795
58795
|
|
|
58796
|
-
/**
|
|
58797
|
-
* @param {{[x: string]: any}} fieldAttrs
|
|
58798
|
-
* @param {String} [parentId]
|
|
58799
|
-
* @param {number} [index]
|
|
58800
|
-
*
|
|
58801
|
-
* @return {any} field
|
|
58796
|
+
/**
|
|
58797
|
+
* @param {{[x: string]: any}} fieldAttrs
|
|
58798
|
+
* @param {String} [parentId]
|
|
58799
|
+
* @param {number} [index]
|
|
58800
|
+
*
|
|
58801
|
+
* @return {any} field
|
|
58802
58802
|
*/
|
|
58803
58803
|
importFormField(fieldAttrs, parentId, index) {
|
|
58804
58804
|
const {
|
|
@@ -58835,11 +58835,11 @@
|
|
|
58835
58835
|
return field;
|
|
58836
58836
|
}
|
|
58837
58837
|
|
|
58838
|
-
/**
|
|
58839
|
-
* @param {Array<any>} components
|
|
58840
|
-
* @param {string} parentId
|
|
58841
|
-
*
|
|
58842
|
-
* @return {Array<any>} imported components
|
|
58838
|
+
/**
|
|
58839
|
+
* @param {Array<any>} components
|
|
58840
|
+
* @param {string} parentId
|
|
58841
|
+
*
|
|
58842
|
+
* @return {Array<any>} imported components
|
|
58843
58843
|
*/
|
|
58844
58844
|
importFormFields(components, parentId) {
|
|
58845
58845
|
return components.map((component, index) => {
|
|
@@ -58862,22 +58862,22 @@
|
|
|
58862
58862
|
});
|
|
58863
58863
|
}
|
|
58864
58864
|
|
|
58865
|
-
/**
|
|
58866
|
-
* Add a dragger that calls back the passed function with
|
|
58867
|
-
* { event, delta } on drag.
|
|
58868
|
-
*
|
|
58869
|
-
* @example
|
|
58870
|
-
*
|
|
58871
|
-
* function dragMove(event, delta) {
|
|
58872
|
-
* // we are dragging (!!)
|
|
58873
|
-
* }
|
|
58874
|
-
*
|
|
58875
|
-
* domElement.addEventListener('dragstart', dragger(dragMove));
|
|
58876
|
-
*
|
|
58877
|
-
* @param {Function} fn
|
|
58878
|
-
* @param {Element} dragPreview
|
|
58879
|
-
*
|
|
58880
|
-
* @return {Function} drag start callback function
|
|
58865
|
+
/**
|
|
58866
|
+
* Add a dragger that calls back the passed function with
|
|
58867
|
+
* { event, delta } on drag.
|
|
58868
|
+
*
|
|
58869
|
+
* @example
|
|
58870
|
+
*
|
|
58871
|
+
* function dragMove(event, delta) {
|
|
58872
|
+
* // we are dragging (!!)
|
|
58873
|
+
* }
|
|
58874
|
+
*
|
|
58875
|
+
* domElement.addEventListener('dragstart', dragger(dragMove));
|
|
58876
|
+
*
|
|
58877
|
+
* @param {Function} fn
|
|
58878
|
+
* @param {Element} dragPreview
|
|
58879
|
+
*
|
|
58880
|
+
* @return {Function} drag start callback function
|
|
58881
58881
|
*/
|
|
58882
58882
|
function createDragger(fn, dragPreview) {
|
|
58883
58883
|
let self;
|
|
@@ -58918,12 +58918,12 @@
|
|
|
58918
58918
|
return onDragStart;
|
|
58919
58919
|
}
|
|
58920
58920
|
|
|
58921
|
-
/**
|
|
58922
|
-
* Throttle function call according UI update cycle.
|
|
58923
|
-
*
|
|
58924
|
-
* @param {Function} fn
|
|
58925
|
-
*
|
|
58926
|
-
* @return {Function} throttled fn
|
|
58921
|
+
/**
|
|
58922
|
+
* Throttle function call according UI update cycle.
|
|
58923
|
+
*
|
|
58924
|
+
* @param {Function} fn
|
|
58925
|
+
*
|
|
58926
|
+
* @return {Function} throttled fn
|
|
58927
58927
|
*/
|
|
58928
58928
|
function throttle(fn) {
|
|
58929
58929
|
let active = false;
|
|
@@ -58951,11 +58951,11 @@
|
|
|
58951
58951
|
});
|
|
58952
58952
|
var DragAndDropContext$1 = DragAndDropContext;
|
|
58953
58953
|
|
|
58954
|
-
/**
|
|
58955
|
-
* @param {string} type
|
|
58956
|
-
* @param {boolean} [strict]
|
|
58957
|
-
*
|
|
58958
|
-
* @returns {any}
|
|
58954
|
+
/**
|
|
58955
|
+
* @param {string} type
|
|
58956
|
+
* @param {boolean} [strict]
|
|
58957
|
+
*
|
|
58958
|
+
* @returns {any}
|
|
58959
58959
|
*/
|
|
58960
58960
|
function getService(type, strict) {}
|
|
58961
58961
|
const FormEditorContext = D$1({
|
|
@@ -59197,10 +59197,12 @@
|
|
|
59197
59197
|
eventBus.on(`${section}.attach`, onAttach);
|
|
59198
59198
|
eventBus.on(`${section}.detach`, onDetach);
|
|
59199
59199
|
eventBus.on(`${section}.reset`, onReset);
|
|
59200
|
+
eventBus.fire(`${section}.section.rendered`);
|
|
59200
59201
|
return () => {
|
|
59201
59202
|
eventBus.off(`${section}.attach`, onAttach);
|
|
59202
59203
|
eventBus.off(`${section}.detach`, onDetach);
|
|
59203
59204
|
eventBus.off(`${section}.reset`, onReset);
|
|
59205
|
+
eventBus.fire(`${section}.section.destroyed`);
|
|
59204
59206
|
};
|
|
59205
59207
|
}, [eventBus, section]);
|
|
59206
59208
|
y(() => {
|
|
@@ -59279,23 +59281,23 @@
|
|
|
59279
59281
|
return fillsAndSeparators;
|
|
59280
59282
|
};
|
|
59281
59283
|
|
|
59282
|
-
/**
|
|
59283
|
-
* Creates a Fragment for a fill.
|
|
59284
|
-
*
|
|
59285
|
-
* @param {Object} fill Fill to be rendered
|
|
59286
|
-
* @returns {Object} Preact Fragment containing fill's children
|
|
59284
|
+
/**
|
|
59285
|
+
* Creates a Fragment for a fill.
|
|
59286
|
+
*
|
|
59287
|
+
* @param {Object} fill Fill to be rendered
|
|
59288
|
+
* @returns {Object} Preact Fragment containing fill's children
|
|
59287
59289
|
*/
|
|
59288
59290
|
const FillFragment = fill => e$1(d$1, {
|
|
59289
59291
|
children: fill.children
|
|
59290
59292
|
}, fill.id);
|
|
59291
59293
|
|
|
59292
|
-
/**
|
|
59293
|
-
* Creates an array of fills, with separators inserted between groups.
|
|
59294
|
-
*
|
|
59295
|
-
* @param {Array} groups Groups of fills
|
|
59296
|
-
* @param {Function} fillRenderer Function to create a fill
|
|
59297
|
-
* @param {Function} separatorRenderer Function to create a separator
|
|
59298
|
-
* @returns {Array} Array of fills and separators
|
|
59294
|
+
/**
|
|
59295
|
+
* Creates an array of fills, with separators inserted between groups.
|
|
59296
|
+
*
|
|
59297
|
+
* @param {Array} groups Groups of fills
|
|
59298
|
+
* @param {Function} fillRenderer Function to create a fill
|
|
59299
|
+
* @param {Function} separatorRenderer Function to create a separator
|
|
59300
|
+
* @returns {Array} Array of fills and separators
|
|
59299
59301
|
*/
|
|
59300
59302
|
const buildFills = (groups, fillRenderer, separatorRenderer) => {
|
|
59301
59303
|
const result = [];
|
|
@@ -59313,8 +59315,8 @@
|
|
|
59313
59315
|
return result;
|
|
59314
59316
|
};
|
|
59315
59317
|
|
|
59316
|
-
/**
|
|
59317
|
-
* Groups fills by group name property.
|
|
59318
|
+
/**
|
|
59319
|
+
* Groups fills by group name property.
|
|
59318
59320
|
*/
|
|
59319
59321
|
const _groupByGroupName = fills => {
|
|
59320
59322
|
const groups = [];
|
|
@@ -59334,8 +59336,8 @@
|
|
|
59334
59336
|
return Object.keys(groupsById).sort().map(id => groupsById[id]);
|
|
59335
59337
|
};
|
|
59336
59338
|
|
|
59337
|
-
/**
|
|
59338
|
-
* Compares fills by priority.
|
|
59339
|
+
/**
|
|
59340
|
+
* Compares fills by priority.
|
|
59339
59341
|
*/
|
|
59340
59342
|
const _comparePriority = (a, b) => {
|
|
59341
59343
|
return (b.priority || 0) - (a.priority || 0);
|
|
@@ -62085,10 +62087,10 @@
|
|
|
62085
62087
|
return `bio-properties-panel-${id}`;
|
|
62086
62088
|
}
|
|
62087
62089
|
|
|
62088
|
-
/**
|
|
62089
|
-
* Retrieve list of variables from the form schema.
|
|
62090
|
-
*
|
|
62091
|
-
* @returns { string[] } list of variables used in form schema
|
|
62090
|
+
/**
|
|
62091
|
+
* Retrieve list of variables from the form schema.
|
|
62092
|
+
*
|
|
62093
|
+
* @returns { string[] } list of variables used in form schema
|
|
62092
62094
|
*/
|
|
62093
62095
|
function useVariables() {
|
|
62094
62096
|
const form = useService('formEditor');
|
|
@@ -62175,8 +62177,8 @@
|
|
|
62175
62177
|
}
|
|
62176
62178
|
};
|
|
62177
62179
|
|
|
62178
|
-
/**
|
|
62179
|
-
* Provide placeholders for empty and multiple state.
|
|
62180
|
+
/**
|
|
62181
|
+
* Provide placeholders for empty and multiple state.
|
|
62180
62182
|
*/
|
|
62181
62183
|
const PropertiesPanelPlaceholderProvider = {
|
|
62182
62184
|
getEmpty: () => {
|
|
@@ -63663,14 +63665,14 @@
|
|
|
63663
63665
|
|
|
63664
63666
|
// helpers //////////
|
|
63665
63667
|
|
|
63666
|
-
/**
|
|
63667
|
-
* Returns copy of object with updated value.
|
|
63668
|
-
*
|
|
63669
|
-
* @param {Object} properties
|
|
63670
|
-
* @param {string} key
|
|
63671
|
-
* @param {string} value
|
|
63672
|
-
*
|
|
63673
|
-
* @returns {Object}
|
|
63668
|
+
/**
|
|
63669
|
+
* Returns copy of object with updated value.
|
|
63670
|
+
*
|
|
63671
|
+
* @param {Object} properties
|
|
63672
|
+
* @param {string} key
|
|
63673
|
+
* @param {string} value
|
|
63674
|
+
*
|
|
63675
|
+
* @returns {Object}
|
|
63674
63676
|
*/
|
|
63675
63677
|
function updateValue(properties, key, value) {
|
|
63676
63678
|
return {
|
|
@@ -63679,14 +63681,14 @@
|
|
|
63679
63681
|
};
|
|
63680
63682
|
}
|
|
63681
63683
|
|
|
63682
|
-
/**
|
|
63683
|
-
* Returns copy of object with updated key.
|
|
63684
|
-
*
|
|
63685
|
-
* @param {Object} properties
|
|
63686
|
-
* @param {string} oldKey
|
|
63687
|
-
* @param {string} newKey
|
|
63688
|
-
*
|
|
63689
|
-
* @returns {Object}
|
|
63684
|
+
/**
|
|
63685
|
+
* Returns copy of object with updated key.
|
|
63686
|
+
*
|
|
63687
|
+
* @param {Object} properties
|
|
63688
|
+
* @param {string} oldKey
|
|
63689
|
+
* @param {string} newKey
|
|
63690
|
+
*
|
|
63691
|
+
* @returns {Object}
|
|
63690
63692
|
*/
|
|
63691
63693
|
function updateKey(properties, oldKey, newKey) {
|
|
63692
63694
|
return Object.entries(properties).reduce((newProperties, entry) => {
|
|
@@ -64369,8 +64371,8 @@
|
|
|
64369
64371
|
};
|
|
64370
64372
|
const valuesSourceId = `${fieldId}-valuesSource`;
|
|
64371
64373
|
|
|
64372
|
-
/**
|
|
64373
|
-
* @type {Array<Group|ListGroup>}
|
|
64374
|
+
/**
|
|
64375
|
+
* @type {Array<Group|ListGroup>}
|
|
64374
64376
|
*/
|
|
64375
64377
|
const groups = [{
|
|
64376
64378
|
id: valuesSourceId,
|
|
@@ -64471,13 +64473,13 @@
|
|
|
64471
64473
|
|
|
64472
64474
|
// helpers //////////
|
|
64473
64475
|
|
|
64474
|
-
/**
|
|
64475
|
-
* Returns copy of object without key.
|
|
64476
|
-
*
|
|
64477
|
-
* @param {Object} properties
|
|
64478
|
-
* @param {string} oldKey
|
|
64479
|
-
*
|
|
64480
|
-
* @returns {Object}
|
|
64476
|
+
/**
|
|
64477
|
+
* Returns copy of object without key.
|
|
64478
|
+
*
|
|
64479
|
+
* @param {Object} properties
|
|
64480
|
+
* @param {string} oldKey
|
|
64481
|
+
*
|
|
64482
|
+
* @returns {Object}
|
|
64481
64483
|
*/
|
|
64482
64484
|
function removeKey(properties, oldKey) {
|
|
64483
64485
|
return Object.entries(properties).reduce((newProperties, entry) => {
|
|
@@ -64585,9 +64587,9 @@
|
|
|
64585
64587
|
}, []);
|
|
64586
64588
|
h(() => {
|
|
64587
64589
|
const onFieldChanged = () => {
|
|
64588
|
-
/**
|
|
64589
|
-
* TODO(pinussilvestrus): update with actual updated element,
|
|
64590
|
-
* once we have a proper updater/change support
|
|
64590
|
+
/**
|
|
64591
|
+
* TODO(pinussilvestrus): update with actual updated element,
|
|
64592
|
+
* once we have a proper updater/change support
|
|
64591
64593
|
*/
|
|
64592
64594
|
_update(selection.get() || schema);
|
|
64593
64595
|
};
|
|
@@ -64655,19 +64657,19 @@
|
|
|
64655
64657
|
const DRAG_NO_MOVE_CLS = 'fjs-no-move';
|
|
64656
64658
|
const ERROR_DROP_CLS = 'fjs-error-drop';
|
|
64657
64659
|
|
|
64658
|
-
/**
|
|
64659
|
-
* @typedef { { id: String, components: Array<any> } } FormRow
|
|
64660
|
+
/**
|
|
64661
|
+
* @typedef { { id: String, components: Array<any> } } FormRow
|
|
64660
64662
|
*/
|
|
64661
64663
|
|
|
64662
64664
|
class Dragging {
|
|
64663
|
-
/**
|
|
64664
|
-
* @constructor
|
|
64665
|
-
*
|
|
64666
|
-
* @param { import('../../core/FormFieldRegistry').default } formFieldRegistry
|
|
64667
|
-
* @param { import('../../core/FormLayouter').default } formLayouter
|
|
64668
|
-
* @param { import('../../core/FormLayoutValidator').default } formLayoutValidator
|
|
64669
|
-
* @param { import('../../core/EventBus').default } eventBus
|
|
64670
|
-
* @param { import('../modeling/Modeling').default } modeling
|
|
64665
|
+
/**
|
|
64666
|
+
* @constructor
|
|
64667
|
+
*
|
|
64668
|
+
* @param { import('../../core/FormFieldRegistry').default } formFieldRegistry
|
|
64669
|
+
* @param { import('../../core/FormLayouter').default } formLayouter
|
|
64670
|
+
* @param { import('../../core/FormLayoutValidator').default } formLayoutValidator
|
|
64671
|
+
* @param { import('../../core/EventBus').default } eventBus
|
|
64672
|
+
* @param { import('../modeling/Modeling').default } modeling
|
|
64671
64673
|
*/
|
|
64672
64674
|
constructor(formFieldRegistry, formLayouter, formLayoutValidator, eventBus, modeling) {
|
|
64673
64675
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -64677,13 +64679,13 @@
|
|
|
64677
64679
|
this._modeling = modeling;
|
|
64678
64680
|
}
|
|
64679
64681
|
|
|
64680
|
-
/**
|
|
64681
|
-
* Calculcates position in form schema given the dropped place.
|
|
64682
|
-
*
|
|
64683
|
-
* @param { FormRow } targetRow
|
|
64684
|
-
* @param { any } targetFormField
|
|
64685
|
-
* @param { HTMLElement } sibling
|
|
64686
|
-
* @returns { number }
|
|
64682
|
+
/**
|
|
64683
|
+
* Calculcates position in form schema given the dropped place.
|
|
64684
|
+
*
|
|
64685
|
+
* @param { FormRow } targetRow
|
|
64686
|
+
* @param { any } targetFormField
|
|
64687
|
+
* @param { HTMLElement } sibling
|
|
64688
|
+
* @returns { number }
|
|
64687
64689
|
*/
|
|
64688
64690
|
getTargetIndex(targetRow, targetFormField, sibling) {
|
|
64689
64691
|
/** @type HTMLElement */
|
|
@@ -64785,8 +64787,8 @@
|
|
|
64785
64787
|
}
|
|
64786
64788
|
}
|
|
64787
64789
|
|
|
64788
|
-
/**
|
|
64789
|
-
* @param { { container: Array<string>, direction: string, mirrorContainer: string } } options
|
|
64790
|
+
/**
|
|
64791
|
+
* @param { { container: Array<string>, direction: string, mirrorContainer: string } } options
|
|
64790
64792
|
*/
|
|
64791
64793
|
createDragulaInstance(options) {
|
|
64792
64794
|
const {
|
|
@@ -65180,7 +65182,7 @@
|
|
|
65180
65182
|
return null;
|
|
65181
65183
|
}
|
|
65182
65184
|
return e$1("div", {
|
|
65183
|
-
style: "width: fit-content
|
|
65185
|
+
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;",
|
|
65184
65186
|
class: "fjs-debug-columns",
|
|
65185
65187
|
children: (field.layout || {}).columns || 'auto'
|
|
65186
65188
|
});
|
|
@@ -66214,10 +66216,10 @@
|
|
|
66214
66216
|
return formField;
|
|
66215
66217
|
}
|
|
66216
66218
|
class AddFormFieldHandler {
|
|
66217
|
-
/**
|
|
66218
|
-
* @constructor
|
|
66219
|
-
* @param { import('../../../FormEditor').default } formEditor
|
|
66220
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66219
|
+
/**
|
|
66220
|
+
* @constructor
|
|
66221
|
+
* @param { import('../../../FormEditor').default } formEditor
|
|
66222
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66221
66223
|
*/
|
|
66222
66224
|
constructor(formEditor, formFieldRegistry) {
|
|
66223
66225
|
this._formEditor = formEditor;
|
|
@@ -66277,10 +66279,10 @@
|
|
|
66277
66279
|
}
|
|
66278
66280
|
AddFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
|
|
66279
66281
|
class EditFormFieldHandler {
|
|
66280
|
-
/**
|
|
66281
|
-
* @constructor
|
|
66282
|
-
* @param { import('../../../FormEditor').default } formEditor
|
|
66283
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66282
|
+
/**
|
|
66283
|
+
* @constructor
|
|
66284
|
+
* @param { import('../../../FormEditor').default } formEditor
|
|
66285
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66284
66286
|
*/
|
|
66285
66287
|
constructor(formEditor, formFieldRegistry) {
|
|
66286
66288
|
this._formEditor = formEditor;
|
|
@@ -66342,10 +66344,10 @@
|
|
|
66342
66344
|
}
|
|
66343
66345
|
EditFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
|
|
66344
66346
|
class MoveFormFieldHandler {
|
|
66345
|
-
/**
|
|
66346
|
-
* @constructor
|
|
66347
|
-
* @param { import('../../../FormEditor').default } formEditor
|
|
66348
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66347
|
+
/**
|
|
66348
|
+
* @constructor
|
|
66349
|
+
* @param { import('../../../FormEditor').default } formEditor
|
|
66350
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66349
66351
|
*/
|
|
66350
66352
|
constructor(formEditor, formFieldRegistry) {
|
|
66351
66353
|
this._formEditor = formEditor;
|
|
@@ -66433,10 +66435,10 @@
|
|
|
66433
66435
|
}
|
|
66434
66436
|
MoveFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
|
|
66435
66437
|
class RemoveFormFieldHandler {
|
|
66436
|
-
/**
|
|
66437
|
-
* @constructor
|
|
66438
|
-
* @param { import('../../../FormEditor').default } formEditor
|
|
66439
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66438
|
+
/**
|
|
66439
|
+
* @constructor
|
|
66440
|
+
* @param { import('../../../FormEditor').default } formEditor
|
|
66441
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66440
66442
|
*/
|
|
66441
66443
|
constructor(formEditor, formFieldRegistry) {
|
|
66442
66444
|
this._formEditor = formEditor;
|
|
@@ -66495,9 +66497,9 @@
|
|
|
66495
66497
|
}
|
|
66496
66498
|
RemoveFormFieldHandler.$inject = ['formEditor', 'formFieldRegistry'];
|
|
66497
66499
|
class UpdateIdClaimHandler {
|
|
66498
|
-
/**
|
|
66499
|
-
* @constructor
|
|
66500
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66500
|
+
/**
|
|
66501
|
+
* @constructor
|
|
66502
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66501
66503
|
*/
|
|
66502
66504
|
constructor(formFieldRegistry) {
|
|
66503
66505
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -66529,9 +66531,9 @@
|
|
|
66529
66531
|
}
|
|
66530
66532
|
UpdateIdClaimHandler.$inject = ['formFieldRegistry'];
|
|
66531
66533
|
class UpdateKeyClaimHandler {
|
|
66532
|
-
/**
|
|
66533
|
-
* @constructor
|
|
66534
|
-
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66534
|
+
/**
|
|
66535
|
+
* @constructor
|
|
66536
|
+
* @param { import('../../../core/FormFieldRegistry').default } formFieldRegistry
|
|
66535
66537
|
*/
|
|
66536
66538
|
constructor(formFieldRegistry) {
|
|
66537
66539
|
this._formFieldRegistry = formFieldRegistry;
|
|
@@ -66992,8 +66994,8 @@
|
|
|
66992
66994
|
constructor(eventBus) {
|
|
66993
66995
|
super(eventBus);
|
|
66994
66996
|
|
|
66995
|
-
/**
|
|
66996
|
-
* Remove custom validation if <validationType> is about to be added.
|
|
66997
|
+
/**
|
|
66998
|
+
* Remove custom validation if <validationType> is about to be added.
|
|
66997
66999
|
*/
|
|
66998
67000
|
// @ts-ignore-next-line
|
|
66999
67001
|
this.preExecute('formField.edit', function (context) {
|
|
@@ -67568,51 +67570,62 @@
|
|
|
67568
67570
|
selectionBehavior: ['type', SelectionBehavior]
|
|
67569
67571
|
};
|
|
67570
67572
|
|
|
67571
|
-
/**
|
|
67572
|
-
* Base class for sectionable UI modules.
|
|
67573
|
-
*
|
|
67574
|
-
* @property {EventBus} _eventBus - EventBus instance used for event handling.
|
|
67575
|
-
* @property {string} managerType - Type of the render manager. Used to form event names.
|
|
67576
|
-
*
|
|
67577
|
-
* @class SectionModuleBase
|
|
67573
|
+
/**
|
|
67574
|
+
* Base class for sectionable UI modules.
|
|
67575
|
+
*
|
|
67576
|
+
* @property {EventBus} _eventBus - EventBus instance used for event handling.
|
|
67577
|
+
* @property {string} managerType - Type of the render manager. Used to form event names.
|
|
67578
|
+
*
|
|
67579
|
+
* @class SectionModuleBase
|
|
67578
67580
|
*/
|
|
67579
67581
|
class SectionModuleBase {
|
|
67580
|
-
/**
|
|
67581
|
-
* Create a SectionModuleBase instance.
|
|
67582
|
-
*
|
|
67583
|
-
* @param {any} eventBus - The EventBus instance used for event handling.
|
|
67584
|
-
* @param {string} sectionKey - The type of render manager. Used to form event names.
|
|
67585
|
-
*
|
|
67586
|
-
* @constructor
|
|
67582
|
+
/**
|
|
67583
|
+
* Create a SectionModuleBase instance.
|
|
67584
|
+
*
|
|
67585
|
+
* @param {any} eventBus - The EventBus instance used for event handling.
|
|
67586
|
+
* @param {string} sectionKey - The type of render manager. Used to form event names.
|
|
67587
|
+
*
|
|
67588
|
+
* @constructor
|
|
67587
67589
|
*/
|
|
67588
67590
|
constructor(eventBus, sectionKey) {
|
|
67589
67591
|
this._eventBus = eventBus;
|
|
67590
|
-
this.
|
|
67592
|
+
this._sectionKey = sectionKey;
|
|
67593
|
+
this._eventBus.on(`${this._sectionKey}.section.rendered`, () => this.isSectionRendered = true);
|
|
67594
|
+
this._eventBus.on(`${this._sectionKey}.section.destroyed`, () => this.isSectionRendered = false);
|
|
67591
67595
|
}
|
|
67592
67596
|
|
|
67593
|
-
/**
|
|
67594
|
-
* Attach the managed section to a parent node.
|
|
67595
|
-
*
|
|
67596
|
-
* @param {HTMLElement} container - The parent node to attach to.
|
|
67597
|
+
/**
|
|
67598
|
+
* Attach the managed section to a parent node.
|
|
67599
|
+
*
|
|
67600
|
+
* @param {HTMLElement} container - The parent node to attach to.
|
|
67597
67601
|
*/
|
|
67598
67602
|
attachTo(container) {
|
|
67599
|
-
this._eventBus.fire(`${this.
|
|
67603
|
+
this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.attach`, {
|
|
67600
67604
|
container
|
|
67601
|
-
});
|
|
67605
|
+
}));
|
|
67602
67606
|
}
|
|
67603
67607
|
|
|
67604
|
-
/**
|
|
67605
|
-
* Detach the managed section from its parent node.
|
|
67608
|
+
/**
|
|
67609
|
+
* Detach the managed section from its parent node.
|
|
67606
67610
|
*/
|
|
67607
67611
|
detach() {
|
|
67608
|
-
this._eventBus.fire(`${this.
|
|
67612
|
+
this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.detach`));
|
|
67609
67613
|
}
|
|
67610
67614
|
|
|
67611
|
-
/**
|
|
67612
|
-
* Reset the managed section to its initial state.
|
|
67615
|
+
/**
|
|
67616
|
+
* Reset the managed section to its initial state.
|
|
67613
67617
|
*/
|
|
67614
67618
|
reset() {
|
|
67615
|
-
this._eventBus.fire(`${this.
|
|
67619
|
+
this._onceSectionRendered(() => this._eventBus.fire(`${this._sectionKey}.reset`));
|
|
67620
|
+
}
|
|
67621
|
+
|
|
67622
|
+
/**
|
|
67623
|
+
* Circumvents timing issues.
|
|
67624
|
+
*/
|
|
67625
|
+
_onceSectionRendered(callback) {
|
|
67626
|
+
this.isSectionRendered ? callback() : this._eventBus.once(`${this._sectionKey}.section.rendered`, () => {
|
|
67627
|
+
callback();
|
|
67628
|
+
});
|
|
67616
67629
|
}
|
|
67617
67630
|
}
|
|
67618
67631
|
let PaletteModule$1 = class PaletteModule extends SectionModuleBase {
|
|
@@ -67635,10 +67648,10 @@
|
|
|
67635
67648
|
propertiesPanel: ['type', PropertiesPanelModule$1]
|
|
67636
67649
|
};
|
|
67637
67650
|
|
|
67638
|
-
/**
|
|
67639
|
-
* Manages the rendering of visual plugins.
|
|
67640
|
-
* @constructor
|
|
67641
|
-
* @param {Object} eventBus - Event bus for the application.
|
|
67651
|
+
/**
|
|
67652
|
+
* Manages the rendering of visual plugins.
|
|
67653
|
+
* @constructor
|
|
67654
|
+
* @param {Object} eventBus - Event bus for the application.
|
|
67642
67655
|
*/
|
|
67643
67656
|
class RenderInjector extends SectionModuleBase {
|
|
67644
67657
|
constructor(eventBus) {
|
|
@@ -67647,10 +67660,10 @@
|
|
|
67647
67660
|
this.registeredRenderers = [];
|
|
67648
67661
|
}
|
|
67649
67662
|
|
|
67650
|
-
/**
|
|
67651
|
-
* Inject a new renderer into the injector.
|
|
67652
|
-
* @param {string} identifier - Identifier for the renderer.
|
|
67653
|
-
* @param {Function} Renderer - The renderer function.
|
|
67663
|
+
/**
|
|
67664
|
+
* Inject a new renderer into the injector.
|
|
67665
|
+
* @param {string} identifier - Identifier for the renderer.
|
|
67666
|
+
* @param {Function} Renderer - The renderer function.
|
|
67654
67667
|
*/
|
|
67655
67668
|
attachRenderer(identifier, Renderer) {
|
|
67656
67669
|
this.registeredRenderers = [...this.registeredRenderers, {
|
|
@@ -67659,17 +67672,17 @@
|
|
|
67659
67672
|
}];
|
|
67660
67673
|
}
|
|
67661
67674
|
|
|
67662
|
-
/**
|
|
67663
|
-
* Detach a renderer from the by key injector.
|
|
67664
|
-
* @param {string} identifier - Identifier for the renderer.
|
|
67675
|
+
/**
|
|
67676
|
+
* Detach a renderer from the by key injector.
|
|
67677
|
+
* @param {string} identifier - Identifier for the renderer.
|
|
67665
67678
|
*/
|
|
67666
67679
|
detachRenderer(identifier) {
|
|
67667
67680
|
this.registeredRenderers = this.registeredRenderers.filter(r => r.identifier !== identifier);
|
|
67668
67681
|
}
|
|
67669
67682
|
|
|
67670
|
-
/**
|
|
67671
|
-
* Returns the registered renderers.
|
|
67672
|
-
* @returns {Array} Array of registered renderers.
|
|
67683
|
+
/**
|
|
67684
|
+
* Returns the registered renderers.
|
|
67685
|
+
* @returns {Array} Array of registered renderers.
|
|
67673
67686
|
*/
|
|
67674
67687
|
fetchRenderers() {
|
|
67675
67688
|
return this.registeredRenderers;
|
|
@@ -67699,48 +67712,48 @@
|
|
|
67699
67712
|
};
|
|
67700
67713
|
const ids = new Ids([32, 36, 1]);
|
|
67701
67714
|
|
|
67702
|
-
/**
|
|
67703
|
-
* @typedef { import('./types').Injector } Injector
|
|
67704
|
-
* @typedef { import('./types').Module } Module
|
|
67705
|
-
* @typedef { import('./types').Schema } Schema
|
|
67706
|
-
*
|
|
67707
|
-
* @typedef { import('./types').FormEditorOptions } FormEditorOptions
|
|
67708
|
-
* @typedef { import('./types').FormEditorProperties } FormEditorProperties
|
|
67709
|
-
*
|
|
67710
|
-
* @typedef { {
|
|
67711
|
-
* properties: FormEditorProperties,
|
|
67712
|
-
* schema: Schema
|
|
67713
|
-
* } } State
|
|
67714
|
-
*
|
|
67715
|
-
* @typedef { (type:string, priority:number, handler:Function) => void } OnEventWithPriority
|
|
67716
|
-
* @typedef { (type:string, handler:Function) => void } OnEventWithOutPriority
|
|
67717
|
-
* @typedef { OnEventWithPriority & OnEventWithOutPriority } OnEventType
|
|
67715
|
+
/**
|
|
67716
|
+
* @typedef { import('./types').Injector } Injector
|
|
67717
|
+
* @typedef { import('./types').Module } Module
|
|
67718
|
+
* @typedef { import('./types').Schema } Schema
|
|
67719
|
+
*
|
|
67720
|
+
* @typedef { import('./types').FormEditorOptions } FormEditorOptions
|
|
67721
|
+
* @typedef { import('./types').FormEditorProperties } FormEditorProperties
|
|
67722
|
+
*
|
|
67723
|
+
* @typedef { {
|
|
67724
|
+
* properties: FormEditorProperties,
|
|
67725
|
+
* schema: Schema
|
|
67726
|
+
* } } State
|
|
67727
|
+
*
|
|
67728
|
+
* @typedef { (type:string, priority:number, handler:Function) => void } OnEventWithPriority
|
|
67729
|
+
* @typedef { (type:string, handler:Function) => void } OnEventWithOutPriority
|
|
67730
|
+
* @typedef { OnEventWithPriority & OnEventWithOutPriority } OnEventType
|
|
67718
67731
|
*/
|
|
67719
67732
|
|
|
67720
|
-
/**
|
|
67721
|
-
* The form editor.
|
|
67733
|
+
/**
|
|
67734
|
+
* The form editor.
|
|
67722
67735
|
*/
|
|
67723
67736
|
class FormEditor {
|
|
67724
|
-
/**
|
|
67725
|
-
* @constructor
|
|
67726
|
-
* @param {FormEditorOptions} options
|
|
67737
|
+
/**
|
|
67738
|
+
* @constructor
|
|
67739
|
+
* @param {FormEditorOptions} options
|
|
67727
67740
|
*/
|
|
67728
67741
|
constructor(options = {}) {
|
|
67729
|
-
/**
|
|
67730
|
-
* @public
|
|
67731
|
-
* @type {OnEventType}
|
|
67742
|
+
/**
|
|
67743
|
+
* @public
|
|
67744
|
+
* @type {OnEventType}
|
|
67732
67745
|
*/
|
|
67733
67746
|
this.on = this._onEvent;
|
|
67734
67747
|
|
|
67735
|
-
/**
|
|
67736
|
-
* @public
|
|
67737
|
-
* @type {String}
|
|
67748
|
+
/**
|
|
67749
|
+
* @public
|
|
67750
|
+
* @type {String}
|
|
67738
67751
|
*/
|
|
67739
67752
|
this._id = ids.next();
|
|
67740
67753
|
|
|
67741
|
-
/**
|
|
67742
|
-
* @private
|
|
67743
|
-
* @type {Element}
|
|
67754
|
+
/**
|
|
67755
|
+
* @private
|
|
67756
|
+
* @type {Element}
|
|
67744
67757
|
*/
|
|
67745
67758
|
this._container = createFormContainer();
|
|
67746
67759
|
this._container.setAttribute('input-handle-modified-keys', 'z,y');
|
|
@@ -67751,15 +67764,15 @@
|
|
|
67751
67764
|
properties = {}
|
|
67752
67765
|
} = options;
|
|
67753
67766
|
|
|
67754
|
-
/**
|
|
67755
|
-
* @private
|
|
67756
|
-
* @type {any}
|
|
67767
|
+
/**
|
|
67768
|
+
* @private
|
|
67769
|
+
* @type {any}
|
|
67757
67770
|
*/
|
|
67758
67771
|
this.exporter = exporter;
|
|
67759
67772
|
|
|
67760
|
-
/**
|
|
67761
|
-
* @private
|
|
67762
|
-
* @type {State}
|
|
67773
|
+
/**
|
|
67774
|
+
* @private
|
|
67775
|
+
* @type {State}
|
|
67763
67776
|
*/
|
|
67764
67777
|
this._state = {
|
|
67765
67778
|
properties,
|
|
@@ -67788,10 +67801,10 @@
|
|
|
67788
67801
|
this._detach(false);
|
|
67789
67802
|
}
|
|
67790
67803
|
|
|
67791
|
-
/**
|
|
67792
|
-
* @param {Schema} schema
|
|
67793
|
-
*
|
|
67794
|
-
* @return {Promise<{ warnings: Array<any> }>}
|
|
67804
|
+
/**
|
|
67805
|
+
* @param {Schema} schema
|
|
67806
|
+
*
|
|
67807
|
+
* @return {Promise<{ warnings: Array<any> }>}
|
|
67795
67808
|
*/
|
|
67796
67809
|
importSchema(schema) {
|
|
67797
67810
|
return new Promise((resolve, reject) => {
|
|
@@ -67820,15 +67833,15 @@
|
|
|
67820
67833
|
});
|
|
67821
67834
|
}
|
|
67822
67835
|
|
|
67823
|
-
/**
|
|
67824
|
-
* @returns {Schema}
|
|
67836
|
+
/**
|
|
67837
|
+
* @returns {Schema}
|
|
67825
67838
|
*/
|
|
67826
67839
|
saveSchema() {
|
|
67827
67840
|
return this.getSchema();
|
|
67828
67841
|
}
|
|
67829
67842
|
|
|
67830
|
-
/**
|
|
67831
|
-
* @returns {Schema}
|
|
67843
|
+
/**
|
|
67844
|
+
* @returns {Schema}
|
|
67832
67845
|
*/
|
|
67833
67846
|
getSchema() {
|
|
67834
67847
|
const {
|
|
@@ -67837,8 +67850,8 @@
|
|
|
67837
67850
|
return exportSchema(schema, this.exporter, schemaVersion);
|
|
67838
67851
|
}
|
|
67839
67852
|
|
|
67840
|
-
/**
|
|
67841
|
-
* @param {Element|string} parentNode
|
|
67853
|
+
/**
|
|
67854
|
+
* @param {Element|string} parentNode
|
|
67842
67855
|
*/
|
|
67843
67856
|
attachTo(parentNode) {
|
|
67844
67857
|
if (!parentNode) {
|
|
@@ -67856,10 +67869,10 @@
|
|
|
67856
67869
|
this._detach();
|
|
67857
67870
|
}
|
|
67858
67871
|
|
|
67859
|
-
/**
|
|
67860
|
-
* @internal
|
|
67861
|
-
*
|
|
67862
|
-
* @param {boolean} [emit]
|
|
67872
|
+
/**
|
|
67873
|
+
* @internal
|
|
67874
|
+
*
|
|
67875
|
+
* @param {boolean} [emit]
|
|
67863
67876
|
*/
|
|
67864
67877
|
_detach(emit = true) {
|
|
67865
67878
|
const container = this._container,
|
|
@@ -67873,9 +67886,9 @@
|
|
|
67873
67886
|
parentNode.removeChild(container);
|
|
67874
67887
|
}
|
|
67875
67888
|
|
|
67876
|
-
/**
|
|
67877
|
-
* @param {any} property
|
|
67878
|
-
* @param {any} value
|
|
67889
|
+
/**
|
|
67890
|
+
* @param {any} property
|
|
67891
|
+
* @param {any} value
|
|
67879
67892
|
*/
|
|
67880
67893
|
setProperty(property, value) {
|
|
67881
67894
|
const properties = set$1(this._getState().properties, [property], value);
|
|
@@ -67884,21 +67897,21 @@
|
|
|
67884
67897
|
});
|
|
67885
67898
|
}
|
|
67886
67899
|
|
|
67887
|
-
/**
|
|
67888
|
-
* @param {string} type
|
|
67889
|
-
* @param {Function} handler
|
|
67900
|
+
/**
|
|
67901
|
+
* @param {string} type
|
|
67902
|
+
* @param {Function} handler
|
|
67890
67903
|
*/
|
|
67891
67904
|
off(type, handler) {
|
|
67892
67905
|
this.get('eventBus').off(type, handler);
|
|
67893
67906
|
}
|
|
67894
67907
|
|
|
67895
|
-
/**
|
|
67896
|
-
* @internal
|
|
67897
|
-
*
|
|
67898
|
-
* @param {FormEditorOptions} options
|
|
67899
|
-
* @param {Element} container
|
|
67900
|
-
*
|
|
67901
|
-
* @returns {Injector}
|
|
67908
|
+
/**
|
|
67909
|
+
* @internal
|
|
67910
|
+
*
|
|
67911
|
+
* @param {FormEditorOptions} options
|
|
67912
|
+
* @param {Element} container
|
|
67913
|
+
*
|
|
67914
|
+
* @returns {Injector}
|
|
67902
67915
|
*/
|
|
67903
67916
|
_createInjector(options, container) {
|
|
67904
67917
|
const {
|
|
@@ -67920,22 +67933,22 @@
|
|
|
67920
67933
|
}, core, ...modules, ...additionalModules]);
|
|
67921
67934
|
}
|
|
67922
67935
|
|
|
67923
|
-
/**
|
|
67924
|
-
* @internal
|
|
67936
|
+
/**
|
|
67937
|
+
* @internal
|
|
67925
67938
|
*/
|
|
67926
67939
|
_emit(type, data) {
|
|
67927
67940
|
this.get('eventBus').fire(type, data);
|
|
67928
67941
|
}
|
|
67929
67942
|
|
|
67930
|
-
/**
|
|
67931
|
-
* @internal
|
|
67943
|
+
/**
|
|
67944
|
+
* @internal
|
|
67932
67945
|
*/
|
|
67933
67946
|
_getState() {
|
|
67934
67947
|
return this._state;
|
|
67935
67948
|
}
|
|
67936
67949
|
|
|
67937
|
-
/**
|
|
67938
|
-
* @internal
|
|
67950
|
+
/**
|
|
67951
|
+
* @internal
|
|
67939
67952
|
*/
|
|
67940
67953
|
_setState(state) {
|
|
67941
67954
|
this._state = {
|
|
@@ -67945,15 +67958,15 @@
|
|
|
67945
67958
|
this._emit('changed', this._getState());
|
|
67946
67959
|
}
|
|
67947
67960
|
|
|
67948
|
-
/**
|
|
67949
|
-
* @internal
|
|
67961
|
+
/**
|
|
67962
|
+
* @internal
|
|
67950
67963
|
*/
|
|
67951
67964
|
_getModules() {
|
|
67952
67965
|
return [ModelingModule, EditorActionsModule, DraggingModule, KeyboardModule, SelectionModule, PaletteModule, ExpressionLanguageModule, MarkdownModule, PropertiesPanelModule, RenderInjectionModule];
|
|
67953
67966
|
}
|
|
67954
67967
|
|
|
67955
|
-
/**
|
|
67956
|
-
* @internal
|
|
67968
|
+
/**
|
|
67969
|
+
* @internal
|
|
67957
67970
|
*/
|
|
67958
67971
|
_onEvent(type, priority, handler) {
|
|
67959
67972
|
this.get('eventBus').on(type, priority, handler);
|
|
@@ -69456,8 +69469,8 @@
|
|
|
69456
69469
|
return new LanguageSupport(jsonLanguage);
|
|
69457
69470
|
}
|
|
69458
69471
|
|
|
69459
|
-
/**
|
|
69460
|
-
* @type {Facet<import('..').Variables>} Variables
|
|
69472
|
+
/**
|
|
69473
|
+
* @type {Facet<import('..').Variables>} Variables
|
|
69461
69474
|
*/
|
|
69462
69475
|
const variablesFacet = Facet.define();
|
|
69463
69476
|
|
|
@@ -69497,8 +69510,8 @@
|
|
|
69497
69510
|
let language = new Compartment().of(json());
|
|
69498
69511
|
let tabSize = new Compartment().of(EditorState.tabSize.of(2));
|
|
69499
69512
|
|
|
69500
|
-
/**
|
|
69501
|
-
* @typedef {Array<string>} Variables
|
|
69513
|
+
/**
|
|
69514
|
+
* @typedef {Array<string>} Variables
|
|
69502
69515
|
*/
|
|
69503
69516
|
|
|
69504
69517
|
const autocompletionConf = new Compartment();
|
|
@@ -69538,8 +69551,8 @@
|
|
|
69538
69551
|
return view.state.doc.toString();
|
|
69539
69552
|
};
|
|
69540
69553
|
|
|
69541
|
-
/**
|
|
69542
|
-
* @param {Variables} variables
|
|
69554
|
+
/**
|
|
69555
|
+
* @param {Variables} variables
|
|
69543
69556
|
*/
|
|
69544
69557
|
this.setVariables = function (variables) {
|
|
69545
69558
|
view.setVariables(variables);
|