Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
_react2.default.createElement(
'div',
null,
this.renderItems()
)
);
}
}]);
return SelectWithMethodComponent;
}(_simpleReactForm.FieldType);
SelectWithMethodComponent.propTypes = propTypes;
SelectWithMethodComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'select-with-method',
component: SelectWithMethodComponent,
description: 'A select input that connects to a Meteor Method to fetch data.'
});
value: this.props.value,
floatingLabelText: this.props.useHint ? null : this.props.label,
hintText: this.props.useHint ? this.props.label : null,
errorText: this.props.errorMessage,
disabled: this.props.disabled,
onChange: function onChange(_, date) {
return _this2.props.onChange(date);
}
}, this.passProps));
}
}]);
return DatePickerComponent;
}(_simpleReactForm.FieldType);
(0, _simpleReactForm.registerType)({
type: 'date-picker',
component: DatePickerComponent,
allowedTypes: [Date],
description: 'Material UI Date picker.'
});
'div',
{ style: { color: 'red' } },
this.props.errorMessage
),
this.renderOptions()
);
}
}]);
return MultipleCheckboxComponent;
}(_simpleReactForm.FieldType);
MultipleCheckboxComponent.propTypes = propTypes;
MultipleCheckboxComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'multiple-checkbox',
component: MultipleCheckboxComponent,
allowedTypes: [[String], [Number]],
description: 'Select multiple values with checkboxes.'
});
_react2.default.createElement(
'div',
{ style: _styles2.default.errorMessage },
this.props.errorMessage
)
);
}
}]);
return Component;
}(_simpleReactForm.FieldType);
exports.default = Component;
(0, _simpleReactForm.registerType)({
type: 'file',
component: Component,
allowedTypes: [Object, [Object]],
description: 'File field.'
});
errorText: this.props.errorMessage,
disabled: this.props.disabled,
onChange: function onChange(event) {
return _this2.props.onChange(event.target.value);
}
}, this.passProps));
}
}]);
return TextareaComponent;
}(_simpleReactForm.FieldType);
TextareaComponent.propTypes = propTypes;
TextareaComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'textarea',
component: TextareaComponent,
allowedTypes: [String],
description: 'Textarea'
});
var NumberFieldComponent = function (_TextFieldComponent2) {
_inherits(NumberFieldComponent, _TextFieldComponent2);
function NumberFieldComponent(props) {
_classCallCheck(this, NumberFieldComponent);
var _this4 = _possibleConstructorReturn(this, Object.getPrototypeOf(NumberFieldComponent).call(this, props));
_this4.type = 'number';
return _this4;
}
return NumberFieldComponent;
}(TextFieldComponent);
(0, _simpleReactForm.registerType)({
type: 'number',
component: NumberFieldComponent
});
var DateFieldComponent = function (_TextFieldComponent3) {
_inherits(DateFieldComponent, _TextFieldComponent3);
function DateFieldComponent(props) {
_classCallCheck(this, DateFieldComponent);
var _this5 = _possibleConstructorReturn(this, Object.getPrototypeOf(DateFieldComponent).call(this, props));
_this5.type = 'date';
return _this5;
}
}]);
return CheckboxComponent;
}(_simpleReactForm.FieldType);
CheckboxComponent.propTypes = propTypes;
CheckboxComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'checkbox',
component: CheckboxComponent,
allowedTypes: [Boolean],
description: 'Simple checkbox field.'
});
(0, _simpleReactForm.registerType)({
type: 'boolean',
component: CheckboxComponent
});
_react2.default.createElement(
'div',
{ style: _styles2.default.errorMessage },
this.props.errorMessage
)
);
}
}]);
return SelectComponent;
}(_simpleReactForm.FieldType);
SelectComponent.propTypes = propTypes;
SelectComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'select',
component: SelectComponent,
allowedTypes: [String, Number],
description: 'Simple select field.'
});
}
}]);
return StringArrayComponent;
}(_simpleReactForm.FieldType);
StringArrayComponent.propTypes = propTypes;
StringArrayComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'string-array',
component: StringArrayComponent,
allowedTypes: [[String]]
});
(0, _simpleReactForm.registerType)({
type: 'tags',
component: StringArrayComponent,
allowedTypes: [[String]],
description: 'Tags input'
});
_react2.default.createElement(
'div',
{ style: styles.errorMessage },
this.props.errorMessage
)
);
}
}]);
return ToggleComponent;
}(_simpleReactForm.FieldType);
ToggleComponent.propTypes = propTypes;
ToggleComponent.defaultProps = defaultProps;
(0, _simpleReactForm.registerType)({
type: 'toggle',
component: ToggleComponent,
allowedTypes: Boolean,
description: 'Material UI toggle.'
});