@formio/js 5.0.0-dev.5733.849f847 → 5.0.0-dev.5734.79d4f47

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.
@@ -497,6 +497,7 @@ class NestedComponent extends Field_1.default {
497
497
  header: 'single',
498
498
  collapsed: this.collapsed,
499
499
  [this.nestedKey]: 'single',
500
+ messageContainer: 'single-scope',
500
501
  });
501
502
  let childPromise = Promise.resolve();
502
503
  if (this.refs[this.nestedKey]) {
@@ -59,7 +59,6 @@ export default class DataGridComponent extends NestedArrayComponent {
59
59
  getRows(): {}[];
60
60
  getColumns(): any[];
61
61
  hasHeader(): any;
62
- loadRefs(element: any, refs: any): void;
63
62
  dragula: any;
64
63
  getComponentsContainer(): any;
65
64
  /**
@@ -263,13 +263,6 @@ class DataGridComponent extends NestedArrayComponent_1.default {
263
263
  return hasHeader || ((col.label || col.title) && !col.hideLabel);
264
264
  }, false);
265
265
  }
266
- loadRefs(element, refs) {
267
- super.loadRefs(element, refs);
268
- if (refs['messageContainer'] === 'single') {
269
- const container = lodash_1.default.last(element.querySelectorAll(`[${this._referenceAttributeName}=messageContainer]`));
270
- this.refs['messageContainer'] = container || this.refs['messageContainer'];
271
- }
272
- }
273
266
  attach(element) {
274
267
  this.loadRefs(element, {
275
268
  [`${this.datagridKey}-row`]: 'multiple',
@@ -278,7 +271,6 @@ class DataGridComponent extends NestedArrayComponent_1.default {
278
271
  [`${this.datagridKey}-removeRow`]: 'multiple',
279
272
  [`${this.datagridKey}-group-header`]: 'multiple',
280
273
  [this.datagridKey]: 'multiple',
281
- 'messageContainer': 'single'
282
274
  });
283
275
  if (this.allowReorder) {
284
276
  this.refs[`${this.datagridKey}-row`].forEach((row, index) => {
@@ -241,7 +241,7 @@ class DataMapComponent extends DataGrid_1.default {
241
241
  delete dataValue[key];
242
242
  const comp = components[this.valueKey];
243
243
  comp.component.key = newKey;
244
- comp.path = Components_1.default.getComponentPath(comp);
244
+ comp.path = Components_1.default.calculateComponentPath(comp);
245
245
  key = newKey;
246
246
  });
247
247
  const valueComponent = lodash_1.default.clone(this.component.valueComponent);
@@ -490,11 +490,7 @@ class EditGridComponent extends NestedArrayComponent_1.default {
490
490
  else {
491
491
  this.removeClass(this.refs.component, `formio-component-${this.component.type}-row-open`);
492
492
  }
493
- const superAttach = super.attach(element);
494
- this.loadRefs(element, {
495
- messageContainer: 'single-scope',
496
- });
497
- return superAttach;
493
+ return super.attach(element);
498
494
  }
499
495
  flattenRowDataValue(dataValue) {
500
496
  const flattened = {};
@@ -493,6 +493,7 @@ export default class NestedComponent extends Field {
493
493
  header: 'single',
494
494
  collapsed: this.collapsed,
495
495
  [this.nestedKey]: 'single',
496
+ messageContainer: 'single-scope',
496
497
  });
497
498
  let childPromise = Promise.resolve();
498
499
  if (this.refs[this.nestedKey]) {
@@ -59,7 +59,6 @@ export default class DataGridComponent extends NestedArrayComponent {
59
59
  getRows(): {}[];
60
60
  getColumns(): any[];
61
61
  hasHeader(): any;
62
- loadRefs(element: any, refs: any): void;
63
62
  dragula: any;
64
63
  getComponentsContainer(): any;
65
64
  /**
@@ -260,13 +260,6 @@ export default class DataGridComponent extends NestedArrayComponent {
260
260
  return hasHeader || ((col.label || col.title) && !col.hideLabel);
261
261
  }, false);
262
262
  }
263
- loadRefs(element, refs) {
264
- super.loadRefs(element, refs);
265
- if (refs['messageContainer'] === 'single') {
266
- const container = _.last(element.querySelectorAll(`[${this._referenceAttributeName}=messageContainer]`));
267
- this.refs['messageContainer'] = container || this.refs['messageContainer'];
268
- }
269
- }
270
263
  attach(element) {
271
264
  this.loadRefs(element, {
272
265
  [`${this.datagridKey}-row`]: 'multiple',
@@ -275,7 +268,6 @@ export default class DataGridComponent extends NestedArrayComponent {
275
268
  [`${this.datagridKey}-removeRow`]: 'multiple',
276
269
  [`${this.datagridKey}-group-header`]: 'multiple',
277
270
  [this.datagridKey]: 'multiple',
278
- 'messageContainer': 'single'
279
271
  });
280
272
  if (this.allowReorder) {
281
273
  this.refs[`${this.datagridKey}-row`].forEach((row, index) => {
@@ -236,7 +236,7 @@ export default class DataMapComponent extends DataGridComponent {
236
236
  delete dataValue[key];
237
237
  const comp = components[this.valueKey];
238
238
  comp.component.key = newKey;
239
- comp.path = Components.getComponentPath(comp);
239
+ comp.path = Components.calculateComponentPath(comp);
240
240
  key = newKey;
241
241
  });
242
242
  const valueComponent = _.clone(this.component.valueComponent);
@@ -484,11 +484,7 @@ export default class EditGridComponent extends NestedArrayComponent {
484
484
  else {
485
485
  this.removeClass(this.refs.component, `formio-component-${this.component.type}-row-open`);
486
486
  }
487
- const superAttach = super.attach(element);
488
- this.loadRefs(element, {
489
- messageContainer: 'single-scope',
490
- });
491
- return superAttach;
487
+ return super.attach(element);
492
488
  }
493
489
  flattenRowDataValue(dataValue) {
494
490
  const flattened = {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@formio/js",
3
- "version": "5.0.0-dev.5733.849f847",
3
+ "version": "5.0.0-dev.5734.79d4f47",
4
4
  "description": "JavaScript powered Forms with JSON Form Builder",
5
5
  "main": "lib/cjs/index.js",
6
6
  "exports": {