@formio/js 5.0.0-dev.5913.cb0bb4a → 5.0.0-dev.5913.d415fcc

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/Changelog.md +5 -0
  2. package/dist/formio.form.js +7 -7
  3. package/dist/formio.form.min.js +1 -1
  4. package/dist/formio.full.js +9 -9
  5. package/dist/formio.full.min.js +1 -1
  6. package/lib/cjs/WebformBuilder.js +5 -17
  7. package/lib/cjs/Wizard.d.ts +1 -2
  8. package/lib/cjs/Wizard.js +19 -27
  9. package/lib/cjs/components/_classes/component/Component.js +1 -1
  10. package/lib/cjs/components/_classes/component/editForm/Component.edit.validation.js +1 -1
  11. package/lib/cjs/components/_classes/nested/NestedComponent.js +1 -1
  12. package/lib/cjs/components/hidden/Hidden.d.ts +0 -1
  13. package/lib/cjs/components/hidden/Hidden.js +1 -1
  14. package/lib/cjs/components/select/editForm/Select.edit.data.d.ts +1 -1
  15. package/lib/cjs/components/select/editForm/Select.edit.data.js +1 -0
  16. package/lib/cjs/components/selectboxes/SelectBoxes.js +1 -0
  17. package/lib/cjs/components/signature/Signature.js +3 -1
  18. package/lib/mjs/WebformBuilder.js +5 -17
  19. package/lib/mjs/Wizard.d.ts +1 -2
  20. package/lib/mjs/Wizard.js +18 -26
  21. package/lib/mjs/components/_classes/component/Component.js +1 -1
  22. package/lib/mjs/components/_classes/component/editForm/Component.edit.validation.js +1 -1
  23. package/lib/mjs/components/_classes/nested/NestedComponent.js +1 -1
  24. package/lib/mjs/components/hidden/Hidden.d.ts +0 -1
  25. package/lib/mjs/components/hidden/Hidden.js +1 -1
  26. package/lib/mjs/components/select/editForm/Select.edit.data.d.ts +1 -1
  27. package/lib/mjs/components/select/editForm/Select.edit.data.js +1 -0
  28. package/lib/mjs/components/selectboxes/SelectBoxes.js +1 -0
  29. package/lib/mjs/components/signature/Signature.js +3 -1
  30. package/package.json +1 -1
@@ -808,31 +808,18 @@ class WebformBuilder extends Component_1.default {
808
808
  // Show an error if siblings are disabled for a component and such a component already exists.
809
809
  const compKey = (group === 'resource') ? `component-${key}` : key;
810
810
  const draggableComponent = ((_a = this.groups[group]) === null || _a === void 0 ? void 0 : _a.components[compKey]) || {};
811
- if (draggableComponent.disableSiblings) {
811
+ if (draggableComponent.disableSiblings || draggableComponent.uniqueComponent) {
812
812
  let isCompAlreadyExists = false;
813
813
  (0, formUtils_1.eachComponent)(this.webform.components, (component) => {
814
- if (component.type === draggableComponent.schema.type) {
814
+ if ((draggableComponent.disableSiblings && component.type === draggableComponent.schema.type) ||
815
+ (draggableComponent.uniqueComponent && component.component.key === draggableComponent.schema.key)) {
815
816
  isCompAlreadyExists = true;
816
817
  return;
817
818
  }
818
819
  }, true);
819
820
  if (isCompAlreadyExists) {
820
821
  this.webform.redraw();
821
- this.webform.setAlert('danger', `You cannot add more than one ${draggableComponent.key} component to one page.`);
822
- return;
823
- }
824
- }
825
- if (draggableComponent.uniqueComponent) {
826
- let isCompAlreadyExists = false;
827
- (0, formUtils_1.eachComponent)(this.webform.components, (component) => {
828
- if (component.key === draggableComponent.schema.key) {
829
- isCompAlreadyExists = true;
830
- return;
831
- }
832
- }, true);
833
- if (isCompAlreadyExists) {
834
- this.webform.redraw();
835
- this.webform.setAlert('danger', `You cannot add more than one ${draggableComponent.title} component to one page.`);
822
+ this.webform.setAlert('danger', `You cannot add more than one ${lodash_1.default.get(draggableComponent, draggableComponent.uniqueComponent ? 'title' : 'key')} component to one page.`);
836
823
  return;
837
824
  }
838
825
  }
@@ -1188,6 +1175,7 @@ class WebformBuilder extends Component_1.default {
1188
1175
  }
1189
1176
  const rebuild = parentComponent.rebuild() || Promise.resolve();
1190
1177
  return rebuild.then(() => {
1178
+ parentComponent.resetValue();
1191
1179
  const schema = parentContainer ? parentContainer[index] : (comp ? comp.schema : []);
1192
1180
  this.emitSaveComponentEvent(schema, originalComp, parentComponent.schema, path, index, isNew, originalComponentSchema);
1193
1181
  this.emit('change', this.form);
@@ -6,7 +6,6 @@ declare class Wizard extends Webform {
6
6
  originalComponents: any[];
7
7
  page: number;
8
8
  currentPanel: any;
9
- currentPanels: any[] | null;
10
9
  currentNextPage: number;
11
10
  _seenPages: number[];
12
11
  subWizards: any[];
@@ -17,7 +16,7 @@ declare class Wizard extends Webform {
17
16
  originalOptions: any;
18
17
  isLastPage(): any;
19
18
  getPages(args?: {}): any[];
20
- get hasExtraPages(): boolean;
19
+ get hasSubWizards(): boolean;
21
20
  get localData(): any;
22
21
  get wizardKey(): string;
23
22
  set wizard(form: object);
package/lib/cjs/Wizard.js CHANGED
@@ -34,7 +34,6 @@ class Wizard extends Webform_1.default {
34
34
  this.originalComponents = [];
35
35
  this.page = 0;
36
36
  this.currentPanel = null;
37
- this.currentPanels = null;
38
37
  this.currentNextPage = 0;
39
38
  this._seenPages = [0];
40
39
  this.subWizards = [];
@@ -53,12 +52,12 @@ class Wizard extends Webform_1.default {
53
52
  }
54
53
  getPages(args = {}) {
55
54
  const { all = false } = args;
56
- const pages = this.hasExtraPages ? this.components : this.pages;
55
+ const pages = this.hasSubWizards ? this.components : this.pages;
57
56
  const filteredPages = pages
58
57
  .filter(all ? lodash_1.default.identity : (p, index) => this._seenPages.includes(index));
59
58
  return filteredPages;
60
59
  }
61
- get hasExtraPages() {
60
+ get hasSubWizards() {
62
61
  return !lodash_1.default.isEmpty(this.subWizards);
63
62
  }
64
63
  get data() {
@@ -187,9 +186,9 @@ class Wizard extends Webform_1.default {
187
186
  }
188
187
  render() {
189
188
  const ctx = this.renderContext;
190
- if (this.component.key) {
191
- ctx.panels.map(panel => {
192
- if (panel.key === this.component.key && panel.title === this.component.title) {
189
+ if (this.component.id) {
190
+ ctx.panels.forEach(panel => {
191
+ if (panel.id === this.component.id) {
193
192
  this.currentPanel = panel;
194
193
  ctx.wizardPageTooltip = this.getFormattedTooltip(panel.tooltip);
195
194
  }
@@ -587,7 +586,7 @@ class Wizard extends Webform_1.default {
587
586
  this.pageFieldLogic(num);
588
587
  this.getNextPage();
589
588
  let parentNum = num;
590
- if (this.hasExtraPages) {
589
+ if (this.hasSubWizards) {
591
590
  const pageFromPages = this.pages[num];
592
591
  const pageFromComponents = this.components[num];
593
592
  if (!pageFromComponents || (pageFromPages === null || pageFromPages === void 0 ? void 0 : pageFromPages.id) !== pageFromComponents.id) {
@@ -862,33 +861,25 @@ class Wizard extends Webform_1.default {
862
861
  }
863
862
  }
864
863
  onChange(flags, changed, modified, changes) {
865
- var _a, _b;
864
+ var _a;
866
865
  super.onChange(flags, changed, modified, changes);
867
866
  const errors = this.validate(this.localData, { dirty: false });
868
867
  if (this.alert) {
869
868
  this.showErrors(errors, true, true);
870
869
  }
871
870
  // If the pages change, need to redraw the header.
872
- let currentPanels;
873
- let panels;
871
+ const currentPanels = this.pages;
872
+ // calling this.establishPages() updates/mutates this.pages to be the current pages
873
+ this.establishPages();
874
+ const newPanels = this.pages;
874
875
  const currentNextPage = this.currentNextPage;
875
- if (this.hasExtraPages) {
876
- currentPanels = this.pages.map(page => page.component.key);
877
- this.establishPages();
878
- panels = this.pages.map(page => page.component.key);
879
- if (panels.length !== currentPanels.length) {
880
- this.setPage(this.pages.findIndex(page => page.component.title === this.currentPanel.components[0].label));
881
- }
882
- }
883
- else {
884
- currentPanels = this.currentPanels || this.pages.map(page => page.component.key);
885
- panels = this.establishPages().map(panel => panel.key);
886
- this.currentPanels = panels;
887
- if (((_a = this.currentPanel) === null || _a === void 0 ? void 0 : _a.key) && ((_b = this.currentPanels) === null || _b === void 0 ? void 0 : _b.length)) {
888
- this.setPage(this.currentPanels.findIndex(panel => panel === this.currentPanel.key));
889
- }
876
+ const panelsUpdated = !lodash_1.default.isEqual(newPanels, currentPanels);
877
+ if (((_a = this.currentPanel) === null || _a === void 0 ? void 0 : _a.id) && this.pages.length && (!this.hasSubWizards || (this.hasSubWizards && panelsUpdated))) {
878
+ const newIndex = this.pages.findIndex(page => page.id === this.currentPanel.id);
879
+ if (newIndex !== -1)
880
+ this.setPage(newIndex);
890
881
  }
891
- if (!lodash_1.default.isEqual(panels, currentPanels) || (flags && flags.fromSubmission)) {
882
+ if (panelsUpdated || (flags && flags.fromSubmission)) {
892
883
  this.redrawHeader();
893
884
  }
894
885
  // If the next page changes, then make sure to redraw navigation.
@@ -928,13 +919,14 @@ class Wizard extends Webform_1.default {
928
919
  return super.errors;
929
920
  }
930
921
  showErrors(errors, triggerEvent) {
931
- if (this.hasExtraPages) {
922
+ if (this.hasSubWizards) {
932
923
  this.subWizards.forEach((subWizard) => {
933
924
  if (Array.isArray(subWizard.errors)) {
934
925
  errors = [...errors, ...subWizard.errors];
935
926
  }
936
927
  });
937
928
  }
929
+ ;
938
930
  return super.showErrors(errors, triggerEvent);
939
931
  }
940
932
  focusOnComponent(key) {
@@ -2516,7 +2516,7 @@ class Component extends Element_1.default {
2516
2516
  }
2517
2517
  return value;
2518
2518
  };
2519
- if (this.defaultMask) {
2519
+ if (Array.isArray(this.defaultMask) ? this.defaultMask.length > 0 : this.defaultMask) {
2520
2520
  if (Array.isArray(defaultValue)) {
2521
2521
  defaultValue = defaultValue.map(checkMask);
2522
2522
  }
@@ -27,7 +27,7 @@ exports.default = [
27
27
  weight: 100,
28
28
  type: 'checkbox',
29
29
  label: 'Validate When Hidden',
30
- tooltip: 'Validates the component when it is hidden/conditionally hidden. Vaildation errors are displayed in the error alert on the form submission.',
30
+ tooltip: 'Validates the component when it is hidden/conditionally hidden. Vaildation errors are displayed in the error alert on the form submission. Use caution when enabling this setting, as it can cause a hidden component to be invalid with no way for the form user to correct it.',
31
31
  key: 'validateWhenHidden',
32
32
  input: true
33
33
  },
@@ -685,7 +685,7 @@ class NestedComponent extends Field_1.default {
685
685
  validationProcessor({ scope, data, row, instance, component }, flags) {
686
686
  var _a;
687
687
  const { dirty } = flags;
688
- if (this.root.hasExtraPages && this.page !== this.root.page) {
688
+ if (this.root.hasSubWizards && this.page !== this.root.page) {
689
689
  instance = ((_a = this.childComponentsMap) === null || _a === void 0 ? void 0 : _a.hasOwnProperty(component.path))
690
690
  ? this.childComponentsMap[component.path]
691
691
  : this.getComponent(component.path);
@@ -10,7 +10,6 @@ export default class HiddenComponent extends Input {
10
10
  };
11
11
  get inputInfo(): any;
12
12
  labelIsHidden(): boolean;
13
- get emptyValue(): string;
14
13
  setValue(value: any, flags?: {}): boolean;
15
14
  }
16
15
  import Input from '../_classes/input/Input';
@@ -48,7 +48,7 @@ class HiddenComponent extends Input_1.default {
48
48
  return true;
49
49
  }
50
50
  get emptyValue() {
51
- return '';
51
+ return null;
52
52
  }
53
53
  setValue(value, flags = {}) {
54
54
  return this.updateValue(value, flags);
@@ -1099,6 +1099,7 @@ declare const _default: ({
1099
1099
  alwaysEnabled?: undefined;
1100
1100
  } | {
1101
1101
  key: string;
1102
+ type: string;
1102
1103
  conditional: {
1103
1104
  json: {
1104
1105
  and: ({
@@ -1149,7 +1150,6 @@ declare const _default: ({
1149
1150
  };
1150
1151
  };
1151
1152
  data?: undefined;
1152
- type?: undefined;
1153
1153
  weight?: undefined;
1154
1154
  input?: undefined;
1155
1155
  label?: undefined;
@@ -687,6 +687,7 @@ exports.default = [
687
687
  },
688
688
  {
689
689
  key: 'selectData',
690
+ type: 'hidden',
690
691
  conditional: {
691
692
  json: {
692
693
  and: [
@@ -267,6 +267,7 @@ class SelectBoxesComponent extends Radio_1.default {
267
267
  else {
268
268
  return super.setCustomValidity(messages, dirty, external);
269
269
  }
270
+ ;
270
271
  }
271
272
  validateValueAvailability(setting, value) {
272
273
  if (!(0, utils_1.boolValue)(setting) || !value) {
@@ -159,7 +159,9 @@ class SignatureComponent extends Input_1.default {
159
159
  if (this.dataValue) {
160
160
  this.setDataToSigaturePad();
161
161
  }
162
- this.showCanvas(true);
162
+ if (!this.disabled) {
163
+ this.showCanvas(true);
164
+ }
163
165
  }
164
166
  }
165
167
  renderElement(value, index) {
@@ -793,31 +793,18 @@ export default class WebformBuilder extends Component {
793
793
  // Show an error if siblings are disabled for a component and such a component already exists.
794
794
  const compKey = (group === 'resource') ? `component-${key}` : key;
795
795
  const draggableComponent = this.groups[group]?.components[compKey] || {};
796
- if (draggableComponent.disableSiblings) {
796
+ if (draggableComponent.disableSiblings || draggableComponent.uniqueComponent) {
797
797
  let isCompAlreadyExists = false;
798
798
  eachComponent(this.webform.components, (component) => {
799
- if (component.type === draggableComponent.schema.type) {
799
+ if ((draggableComponent.disableSiblings && component.type === draggableComponent.schema.type) ||
800
+ (draggableComponent.uniqueComponent && component.component.key === draggableComponent.schema.key)) {
800
801
  isCompAlreadyExists = true;
801
802
  return;
802
803
  }
803
804
  }, true);
804
805
  if (isCompAlreadyExists) {
805
806
  this.webform.redraw();
806
- this.webform.setAlert('danger', `You cannot add more than one ${draggableComponent.key} component to one page.`);
807
- return;
808
- }
809
- }
810
- if (draggableComponent.uniqueComponent) {
811
- let isCompAlreadyExists = false;
812
- eachComponent(this.webform.components, (component) => {
813
- if (component.key === draggableComponent.schema.key) {
814
- isCompAlreadyExists = true;
815
- return;
816
- }
817
- }, true);
818
- if (isCompAlreadyExists) {
819
- this.webform.redraw();
820
- this.webform.setAlert('danger', `You cannot add more than one ${draggableComponent.title} component to one page.`);
807
+ this.webform.setAlert('danger', `You cannot add more than one ${_.get(draggableComponent, draggableComponent.uniqueComponent ? 'title' : 'key')} component to one page.`);
821
808
  return;
822
809
  }
823
810
  }
@@ -1172,6 +1159,7 @@ export default class WebformBuilder extends Component {
1172
1159
  }
1173
1160
  const rebuild = parentComponent.rebuild() || Promise.resolve();
1174
1161
  return rebuild.then(() => {
1162
+ parentComponent.resetValue();
1175
1163
  const schema = parentContainer ? parentContainer[index] : (comp ? comp.schema : []);
1176
1164
  this.emitSaveComponentEvent(schema, originalComp, parentComponent.schema, path, index, isNew, originalComponentSchema);
1177
1165
  this.emit('change', this.form);
@@ -6,7 +6,6 @@ declare class Wizard extends Webform {
6
6
  originalComponents: any[];
7
7
  page: number;
8
8
  currentPanel: any;
9
- currentPanels: any[] | null;
10
9
  currentNextPage: number;
11
10
  _seenPages: number[];
12
11
  subWizards: any[];
@@ -17,7 +16,7 @@ declare class Wizard extends Webform {
17
16
  originalOptions: any;
18
17
  isLastPage(): any;
19
18
  getPages(args?: {}): any[];
20
- get hasExtraPages(): boolean;
19
+ get hasSubWizards(): boolean;
21
20
  get localData(): any;
22
21
  get wizardKey(): string;
23
22
  set wizard(form: object);
package/lib/mjs/Wizard.js CHANGED
@@ -29,7 +29,6 @@ export default class Wizard extends Webform {
29
29
  this.originalComponents = [];
30
30
  this.page = 0;
31
31
  this.currentPanel = null;
32
- this.currentPanels = null;
33
32
  this.currentNextPage = 0;
34
33
  this._seenPages = [0];
35
34
  this.subWizards = [];
@@ -48,12 +47,12 @@ export default class Wizard extends Webform {
48
47
  }
49
48
  getPages(args = {}) {
50
49
  const { all = false } = args;
51
- const pages = this.hasExtraPages ? this.components : this.pages;
50
+ const pages = this.hasSubWizards ? this.components : this.pages;
52
51
  const filteredPages = pages
53
52
  .filter(all ? _.identity : (p, index) => this._seenPages.includes(index));
54
53
  return filteredPages;
55
54
  }
56
- get hasExtraPages() {
55
+ get hasSubWizards() {
57
56
  return !_.isEmpty(this.subWizards);
58
57
  }
59
58
  get data() {
@@ -177,9 +176,9 @@ export default class Wizard extends Webform {
177
176
  }
178
177
  render() {
179
178
  const ctx = this.renderContext;
180
- if (this.component.key) {
181
- ctx.panels.map(panel => {
182
- if (panel.key === this.component.key && panel.title === this.component.title) {
179
+ if (this.component.id) {
180
+ ctx.panels.forEach(panel => {
181
+ if (panel.id === this.component.id) {
183
182
  this.currentPanel = panel;
184
183
  ctx.wizardPageTooltip = this.getFormattedTooltip(panel.tooltip);
185
184
  }
@@ -580,7 +579,7 @@ export default class Wizard extends Webform {
580
579
  this.pageFieldLogic(num);
581
580
  this.getNextPage();
582
581
  let parentNum = num;
583
- if (this.hasExtraPages) {
582
+ if (this.hasSubWizards) {
584
583
  const pageFromPages = this.pages[num];
585
584
  const pageFromComponents = this.components[num];
586
585
  if (!pageFromComponents || pageFromPages?.id !== pageFromComponents.id) {
@@ -857,26 +856,18 @@ export default class Wizard extends Webform {
857
856
  this.showErrors(errors, true, true);
858
857
  }
859
858
  // If the pages change, need to redraw the header.
860
- let currentPanels;
861
- let panels;
859
+ const currentPanels = this.pages;
860
+ // calling this.establishPages() updates/mutates this.pages to be the current pages
861
+ this.establishPages();
862
+ const newPanels = this.pages;
862
863
  const currentNextPage = this.currentNextPage;
863
- if (this.hasExtraPages) {
864
- currentPanels = this.pages.map(page => page.component.key);
865
- this.establishPages();
866
- panels = this.pages.map(page => page.component.key);
867
- if (panels.length !== currentPanels.length) {
868
- this.setPage(this.pages.findIndex(page => page.component.title === this.currentPanel.components[0].label));
869
- }
870
- }
871
- else {
872
- currentPanels = this.currentPanels || this.pages.map(page => page.component.key);
873
- panels = this.establishPages().map(panel => panel.key);
874
- this.currentPanels = panels;
875
- if (this.currentPanel?.key && this.currentPanels?.length) {
876
- this.setPage(this.currentPanels.findIndex(panel => panel === this.currentPanel.key));
877
- }
864
+ const panelsUpdated = !_.isEqual(newPanels, currentPanels);
865
+ if (this.currentPanel?.id && this.pages.length && (!this.hasSubWizards || (this.hasSubWizards && panelsUpdated))) {
866
+ const newIndex = this.pages.findIndex(page => page.id === this.currentPanel.id);
867
+ if (newIndex !== -1)
868
+ this.setPage(newIndex);
878
869
  }
879
- if (!_.isEqual(panels, currentPanels) || (flags && flags.fromSubmission)) {
870
+ if (panelsUpdated || (flags && flags.fromSubmission)) {
880
871
  this.redrawHeader();
881
872
  }
882
873
  // If the next page changes, then make sure to redraw navigation.
@@ -915,13 +906,14 @@ export default class Wizard extends Webform {
915
906
  return super.errors;
916
907
  }
917
908
  showErrors(errors, triggerEvent) {
918
- if (this.hasExtraPages) {
909
+ if (this.hasSubWizards) {
919
910
  this.subWizards.forEach((subWizard) => {
920
911
  if (Array.isArray(subWizard.errors)) {
921
912
  errors = [...errors, ...subWizard.errors];
922
913
  }
923
914
  });
924
915
  }
916
+ ;
925
917
  return super.showErrors(errors, triggerEvent);
926
918
  }
927
919
  focusOnComponent(key) {
@@ -2482,7 +2482,7 @@ export default class Component extends Element {
2482
2482
  }
2483
2483
  return value;
2484
2484
  };
2485
- if (this.defaultMask) {
2485
+ if (Array.isArray(this.defaultMask) ? this.defaultMask.length > 0 : this.defaultMask) {
2486
2486
  if (Array.isArray(defaultValue)) {
2487
2487
  defaultValue = defaultValue.map(checkMask);
2488
2488
  }
@@ -22,7 +22,7 @@ export default [
22
22
  weight: 100,
23
23
  type: 'checkbox',
24
24
  label: 'Validate When Hidden',
25
- tooltip: 'Validates the component when it is hidden/conditionally hidden. Vaildation errors are displayed in the error alert on the form submission.',
25
+ tooltip: 'Validates the component when it is hidden/conditionally hidden. Vaildation errors are displayed in the error alert on the form submission. Use caution when enabling this setting, as it can cause a hidden component to be invalid with no way for the form user to correct it.',
26
26
  key: 'validateWhenHidden',
27
27
  input: true
28
28
  },
@@ -680,7 +680,7 @@ export default class NestedComponent extends Field {
680
680
  }
681
681
  validationProcessor({ scope, data, row, instance, component }, flags) {
682
682
  const { dirty } = flags;
683
- if (this.root.hasExtraPages && this.page !== this.root.page) {
683
+ if (this.root.hasSubWizards && this.page !== this.root.page) {
684
684
  instance = this.childComponentsMap?.hasOwnProperty(component.path)
685
685
  ? this.childComponentsMap[component.path]
686
686
  : this.getComponent(component.path);
@@ -10,7 +10,6 @@ export default class HiddenComponent extends Input {
10
10
  };
11
11
  get inputInfo(): any;
12
12
  labelIsHidden(): boolean;
13
- get emptyValue(): string;
14
13
  setValue(value: any, flags?: {}): boolean;
15
14
  }
16
15
  import Input from '../_classes/input/Input';
@@ -43,7 +43,7 @@ export default class HiddenComponent extends Input {
43
43
  return true;
44
44
  }
45
45
  get emptyValue() {
46
- return '';
46
+ return null;
47
47
  }
48
48
  setValue(value, flags = {}) {
49
49
  return this.updateValue(value, flags);
@@ -1099,6 +1099,7 @@ declare const _default: ({
1099
1099
  alwaysEnabled?: undefined;
1100
1100
  } | {
1101
1101
  key: string;
1102
+ type: string;
1102
1103
  conditional: {
1103
1104
  json: {
1104
1105
  and: ({
@@ -1149,7 +1150,6 @@ declare const _default: ({
1149
1150
  };
1150
1151
  };
1151
1152
  data?: undefined;
1152
- type?: undefined;
1153
1153
  weight?: undefined;
1154
1154
  input?: undefined;
1155
1155
  label?: undefined;
@@ -681,6 +681,7 @@ export default [
681
681
  },
682
682
  {
683
683
  key: 'selectData',
684
+ type: 'hidden',
684
685
  conditional: {
685
686
  json: {
686
687
  and: [
@@ -268,6 +268,7 @@ export default class SelectBoxesComponent extends RadioComponent {
268
268
  else {
269
269
  return super.setCustomValidity(messages, dirty, external);
270
270
  }
271
+ ;
271
272
  }
272
273
  validateValueAvailability(setting, value) {
273
274
  if (!boolValue(setting) || !value) {
@@ -156,7 +156,9 @@ export default class SignatureComponent extends Input {
156
156
  if (this.dataValue) {
157
157
  this.setDataToSigaturePad();
158
158
  }
159
- this.showCanvas(true);
159
+ if (!this.disabled) {
160
+ this.showCanvas(true);
161
+ }
160
162
  }
161
163
  }
162
164
  renderElement(value, index) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@formio/js",
3
- "version": "5.0.0-dev.5913.cb0bb4a",
3
+ "version": "5.0.0-dev.5913.d415fcc",
4
4
  "description": "JavaScript powered Forms with JSON Form Builder",
5
5
  "main": "lib/cjs/index.js",
6
6
  "exports": {