@luomus/laji-form 15.1.73 → 15.1.74

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.
@@ -49,7 +49,6 @@ class CheckboxWidget extends React.Component {
49
49
  return;
50
50
  }
51
51
  const inputs = this.containerRef.current.querySelectorAll("input");
52
- console.log(inputs, document.activeElement);
53
52
  if (["ArrowRight", "ArrowDown"].includes(e.key) && document.activeElement === inputs[inputs.length - 1]) {
54
53
  e.preventDefault();
55
54
  }
@@ -61,7 +60,6 @@ class CheckboxWidget extends React.Component {
61
60
  if (value !== undefined && this.getOptions(this.props).invert) {
62
61
  value = !value;
63
62
  }
64
- console.log("change", value);
65
63
  this.props.onChange(value);
66
64
  };
67
65
  this.onChangeTrue = () => this.onChange(true);
@@ -83,15 +81,15 @@ class CheckboxWidget extends React.Component {
83
81
  const displayUndefined = (allowUndefined && showUndefined);
84
82
  const _disabled = disabled || readonly;
85
83
  const tabTargetClass = "laji-form-checkbox-widget-tab-target";
86
- const checkbox = (React.createElement("div", { ref: this.containerRef, className: "checkbox-container", disabled: _disabled },
84
+ const checkbox = (React.createElement("div", { ref: this.containerRef, className: "checkbox-container" },
87
85
  React.createElement("label", null,
88
- React.createElement("input", { type: "radio", value: "true", checked: _value === true, onChange: this.onChangeTrue, className: tabTargetClass, onKeyDown: this.onKeyDown }),
86
+ React.createElement("input", { type: "radio", value: "true", checked: _value === true, onChange: this.onChangeTrue, className: tabTargetClass, onKeyDown: this.onKeyDown, disabled: _disabled }),
89
87
  trueLabel),
90
88
  React.createElement("label", null,
91
- React.createElement("input", { type: "radio", value: "false", checked: _value === false, onChange: this.onChangeFalse, onKeyDown: this.onKeyDown }),
89
+ React.createElement("input", { type: "radio", value: "false", checked: _value === false, onChange: this.onChangeFalse, onKeyDown: this.onKeyDown, disabled: _disabled }),
92
90
  falseLabel),
93
91
  displayUndefined && (React.createElement("label", null,
94
- React.createElement("input", { type: "radio", value: "undefined", checked: _value === undefined, onChange: this.onChangeUndefined, onKeyDown: this.onKeyDown }),
92
+ React.createElement("input", { type: "radio", value: "undefined", checked: _value === undefined, onChange: this.onChangeUndefined, onKeyDown: this.onKeyDown, disabled: _disabled }),
95
93
  unknownLabel))));
96
94
  const { Label } = this.props.formContext;
97
95
  return !hasLabel ? checkbox : React.createElement(React.Fragment, null,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luomus/laji-form",
3
- "version": "15.1.73",
3
+ "version": "15.1.74",
4
4
  "description": "React module capable of building dynamic forms from Laji form json schemas",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",