@punks/backend-entity-manager 0.0.411 → 0.0.412
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
|
@@ -41011,7 +41011,9 @@ const fieldTextValidator = (item, selector, params) => {
|
|
|
41011
41011
|
payload: { current: length, expected: params.maxLength },
|
|
41012
41012
|
},
|
|
41013
41013
|
]),
|
|
41014
|
-
...(isRegexValid
|
|
41014
|
+
...(isRegexValid
|
|
41015
|
+
? []
|
|
41016
|
+
: [{ errorCode: params.regexErrorCode ?? "regex" }]),
|
|
41015
41017
|
],
|
|
41016
41018
|
};
|
|
41017
41019
|
};
|
|
@@ -41019,6 +41021,7 @@ const fieldEmailValidator = (item, selector, params) => {
|
|
|
41019
41021
|
return fieldTextValidator(item, selector, {
|
|
41020
41022
|
...params,
|
|
41021
41023
|
regex: /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/,
|
|
41024
|
+
regexErrorCode: "email",
|
|
41022
41025
|
});
|
|
41023
41026
|
};
|
|
41024
41027
|
const fieldOptionValidator = (item, selector, { availableOptions, required, }) => {
|