@7shifts/sous-chef 3.67.0 → 3.67.1
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 +8 -5
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +8 -5
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -11778,11 +11778,14 @@ const DateField = ({
|
|
|
11778
11778
|
setInputValue(event.target.value);
|
|
11779
11779
|
},
|
|
11780
11780
|
onBlur: event => {
|
|
11781
|
-
|
|
11782
|
-
|
|
11783
|
-
|
|
11784
|
-
|
|
11785
|
-
|
|
11781
|
+
// This is to give some time for calendar click to set the date value. Otherwise, this `undefined` will override the selected date in mobile devices.
|
|
11782
|
+
setTimeout(() => {
|
|
11783
|
+
controllers.onBlur();
|
|
11784
|
+
if (event.target.value === '') {
|
|
11785
|
+
// @ts-expect-error the types will be changed on the next major release https://github.com/7shifts/sous-chef/pull/356
|
|
11786
|
+
controllers.onChange(undefined);
|
|
11787
|
+
}
|
|
11788
|
+
}, 10);
|
|
11786
11789
|
},
|
|
11787
11790
|
maxLength: _format.length,
|
|
11788
11791
|
value: inputValue
|