@portnet/ui 0.0.113 → 0.0.114

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.
@@ -113,8 +113,7 @@ const PuiStandardDateField = /*#__PURE__*/React.forwardRef((_ref, ref) => {
113
113
  onBlur: onBlur,
114
114
  helperText: helperText
115
115
  }, params), {}, {
116
- error: required && meta.touched && Boolean(meta.error),
117
- helperText: meta.touched && meta.error ? meta.error : helperText,
116
+ error: params.error || error,
118
117
  inputProps: _objectSpread({
119
118
  name
120
119
  }, params.inputProps)
@@ -149,13 +148,12 @@ const PuiFormikDateField = /*#__PURE__*/React.forwardRef((_ref2, ref) => {
149
148
  const formikContext = (0, _formik.useFormikContext)();
150
149
  const [hasError, setHasError] = React.useState(false);
151
150
  const handleChange = value => {
152
- if (value && (0, _moment.default)(value, inputFormat, true).isValid()) {
151
+ if (value) {
153
152
  formikContext.setFieldValue(name, value);
154
153
  onChange(value);
155
154
  } else {
156
- // Set the field value to undefined when the input is invalid or empty
157
- formikContext.setFieldValue(name, undefined);
158
- onChange(undefined);
155
+ formikContext.setFieldValue(name, null);
156
+ onChange(null);
159
157
  }
160
158
  };
161
159
  const handleBlur = event => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@portnet/ui",
3
- "version": "0.0.113",
3
+ "version": "0.0.114",
4
4
  "description": "Portnet UI",
5
5
  "keywords": [
6
6
  "react",