react-survey-builder 1.0.28 → 1.0.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/lib/survey-elements/index.js +9 -6
- package/package.json +1 -1
@@ -34,6 +34,7 @@ var _componentErrorMessage = _interopRequireDefault(require("./component-error-m
|
|
34
34
|
var _ipUtils = require("../utils/ipUtils");
|
35
35
|
var _momentTimezone = _interopRequireDefault(require("moment-timezone"));
|
36
36
|
var _ri = require("react-icons/ri");
|
37
|
+
var _UUID = _interopRequireDefault(require("../UUID"));
|
37
38
|
var _excluded = ["onChange"],
|
38
39
|
_excluded2 = ["onChange", "formatMask"]; // eslint-disable-next-line max-classes-per-file
|
39
40
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
@@ -1222,7 +1223,6 @@ var Checkbox = /*#__PURE__*/function (_React$Component16) {
|
|
1222
1223
|
key: "render",
|
1223
1224
|
value: function render() {
|
1224
1225
|
var _this22 = this,
|
1225
|
-
_this$props$item$inli,
|
1226
1226
|
_this$props$checkboxB;
|
1227
1227
|
var baseClasses = 'SortableItem rfb-item';
|
1228
1228
|
if (this.props.item.pageBreakBefore) {
|
@@ -1230,21 +1230,24 @@ var Checkbox = /*#__PURE__*/function (_React$Component16) {
|
|
1230
1230
|
}
|
1231
1231
|
var props = {};
|
1232
1232
|
// eslint-disable-next-line no-undef
|
1233
|
-
props.name = this.props.name;
|
1233
|
+
props.name = this.props.name + '-' + _UUID["default"].uuid();
|
1234
1234
|
props.onChange = function (event) {
|
1235
|
-
_this22.props.onChange
|
1235
|
+
if (_this22.props.onChange) {
|
1236
|
+
_this22.props.onChange(event.target.checked);
|
1237
|
+
}
|
1236
1238
|
};
|
1237
|
-
props.isInvalid = this.props.isInvalid;
|
1239
|
+
//props.isInvalid = this.props.isInvalid;
|
1238
1240
|
props.onBlur = this.props.onBlur;
|
1239
1241
|
props.autoComplete = "new-password";
|
1240
1242
|
if (this.props.item.disabled) {
|
1241
1243
|
props.disabled = 'disabled';
|
1242
1244
|
}
|
1243
1245
|
if (this.props.item.mutable) {
|
1244
|
-
props.
|
1246
|
+
props.inputRef = this.inputField;
|
1245
1247
|
}
|
1246
1248
|
props.checked = this.props.value;
|
1247
|
-
props.inline =
|
1249
|
+
//props.inline = this.props.item.inline ?? false;
|
1250
|
+
|
1248
1251
|
if (this.props.item.print === true) {
|
1249
1252
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
1250
1253
|
style: _objectSpread({}, this.props.style),
|