@reachfive/identity-ui 1.32.0 → 1.32.2
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/cjs/identity-ui.js +8 -6
- package/cjs/identity-ui.js.map +1 -1
- package/es/identity-ui.js +8 -6
- package/es/identity-ui.js.map +1 -1
- package/es/identity-ui.min.js +3 -3
- package/es/identity-ui.min.js.map +1 -1
- package/package.json +1 -1
- package/types/identity-ui.d.ts +3 -3
- package/umd/identity-ui.js +25 -20
- package/umd/identity-ui.js.map +1 -1
- package/umd/identity-ui.min.js +4 -4
- package/umd/identity-ui.min.js.map +1 -1
package/es/identity-ui.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @reachfive/identity-ui - v1.32.
|
|
3
|
-
* Compiled
|
|
2
|
+
* @reachfive/identity-ui - v1.32.2
|
|
3
|
+
* Compiled Mon, 10 Feb 2025 15:46:55 UTC
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) ReachFive.
|
|
6
6
|
*
|
|
@@ -6920,26 +6920,28 @@ const datetimeValidator = (locale) => new Validator({
|
|
|
6920
6920
|
parameters: { format: dateFormat$2(locale) }
|
|
6921
6921
|
});
|
|
6922
6922
|
function dateField({
|
|
6923
|
+
format,
|
|
6923
6924
|
key = "date",
|
|
6924
6925
|
label = "date",
|
|
6925
|
-
yearDebounce,
|
|
6926
6926
|
locale,
|
|
6927
|
+
validator,
|
|
6928
|
+
yearDebounce,
|
|
6927
6929
|
...props
|
|
6928
6930
|
}, config) {
|
|
6929
6931
|
return createField({
|
|
6930
6932
|
key,
|
|
6931
6933
|
label,
|
|
6932
6934
|
...props,
|
|
6933
|
-
format: {
|
|
6935
|
+
format: format ?? {
|
|
6934
6936
|
bind: (value) => {
|
|
6935
6937
|
const dt = value ? parseISO(value) : void 0;
|
|
6936
6938
|
return dt && isValid(dt) ? { raw: dt } : void 0;
|
|
6937
6939
|
},
|
|
6938
6940
|
unbind: (value) => {
|
|
6939
|
-
return isRichFormValue(value, "raw") ? formatISO(value.raw) : value ? formatISO(value) : null;
|
|
6941
|
+
return isRichFormValue(value, "raw") ? formatISO(value.raw, { representation: "date" }) : value ? formatISO(value, { representation: "date" }) : null;
|
|
6940
6942
|
}
|
|
6941
6943
|
},
|
|
6942
|
-
validator:
|
|
6944
|
+
validator: validator ? datetimeValidator(config.language).and(validator) : datetimeValidator(config.language),
|
|
6943
6945
|
component: DateField,
|
|
6944
6946
|
extendedParams: {
|
|
6945
6947
|
locale: locale ?? config.language,
|