@xelto.npm/xc2-lib 0.0.37 → 0.0.38

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/cjs/index.js CHANGED
@@ -81441,12 +81441,12 @@ var StyledTextField = styled(TextField$1)(function (_a) {
81441
81441
  });
81442
81442
  });
81443
81443
  var TextField = function (_a) {
81444
- var _b = _a.label, label = _b === void 0 ? 'Textfield' : _b, _c = _a.error, error = _c === void 0 ? false : _c, _d = _a.icon, icon = _d === void 0 ? 'icon_wf_keyboard' : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e, _f = _a.fluid, fluid = _f === void 0 ? false : _f, _g = _a.type, type = _g === void 0 ? 'text' : _g, _h = _a.min, min = _h === void 0 ? '' : _h, _j = _a.max, max = _j === void 0 ? '' : _j, _k = _a.small, small = _k === void 0 ? false : _k, _l = _a.helperText, helperText = _l === void 0 ? 'fill in the field correctly' : _l, _m = _a.value, value = _m === void 0 ? '' : _m, _o = _a.onChange, onChange = _o === void 0 ? function (event) { return null; } : _o, _p = _a.onBlur, onBlur = _p === void 0 ? function (event) { return null; } : _p, _q = _a.forwardedRef, forwardedRef = _q === void 0 ? null : _q, _r = _a.endAdornment, endAdornment = _r === void 0 ? '' : _r, props = __rest(_a, ["label", "error", "icon", "disabled", "fluid", "type", "min", "max", "small", "helperText", "value", "onChange", "onBlur", "forwardedRef", "endAdornment"]);
81445
- var handleChange = function (event) {
81446
- return onChange(event);
81444
+ var label = _a.label, error = _a.error, icon = _a.icon, disabled = _a.disabled, fluid = _a.fluid, type = _a.type, min = _a.min, max = _a.max, small = _a.small, helperText = _a.helperText, value = _a.value, onChange = _a.onChange, onBlur = _a.onBlur, forwardedRef = _a.forwardedRef, endAdornment = _a.endAdornment, props = __rest(_a, ["label", "error", "icon", "disabled", "fluid", "type", "min", "max", "small", "helperText", "value", "onChange", "onBlur", "forwardedRef", "endAdornment"]);
81445
+ var handleChange = function (e) {
81446
+ return onChange(e);
81447
81447
  };
81448
- var handleBlur = function (event) {
81449
- return onBlur(event);
81448
+ var handleBlur = function (e) {
81449
+ return onBlur(e);
81450
81450
  };
81451
81451
  return (jsxRuntime.exports.jsx(StyledTextField, __assign({}, props, { value: value, onChange: function (e) { return handleChange(e); }, label: label, type: type, variant: "outlined", error: error, onBlur: function (e) { return handleBlur(e); }, disabled: disabled, helperText: error ? helperText : '', fluid: fluid === true ? 'true' : 'false', ref: forwardedRef, small: small, InputProps: {
81452
81452
  inputProps: {
@@ -81468,6 +81468,25 @@ TextField.propTypes = {
81468
81468
  disabled: propTypes.exports.bool,
81469
81469
  endAdornment: propTypes.exports.string,
81470
81470
  small: propTypes.exports.bool,
81471
+ onChange: propTypes.exports.func,
81472
+ onBlur: propTypes.exports.func,
81473
+ };
81474
+ TextField.defaultProps = {
81475
+ label: 'Textfield',
81476
+ icon: 'icon_wf_keyboard',
81477
+ type: 'text',
81478
+ fluid: false,
81479
+ helperText: 'fill in the field correctly',
81480
+ min: '',
81481
+ max: '',
81482
+ error: false,
81483
+ disabled: false,
81484
+ endAdornment: '',
81485
+ small: false,
81486
+ value: '',
81487
+ forwardedRef: null,
81488
+ onChange: function () { return null; },
81489
+ onBlur: function () { return null; },
81471
81490
  };
81472
81491
 
81473
81492
  exports.AppTile = AppTileComponent;