From e9efd70763f07f667baf0d57f0e1a8d52814fd84 Mon Sep 17 00:00:00 2001 From: Jeremy Walker Date: Sun, 5 May 2024 10:22:24 -0700 Subject: [PATCH] Update validation.md Clarified that the component requires a `null` value for the validation to treat it as acceptable. As I discovered, a blank string makes the component go into the invalid validation state ... but there's currently no explanation of this behavior in the docs (that I could find). Signed-off-by: Jeremy Walker --- docs/data/date-pickers/validation/validation.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/data/date-pickers/validation/validation.md b/docs/data/date-pickers/validation/validation.md index 1a1d0aee49f1a..ad6c5dc039333 100644 --- a/docs/data/date-pickers/validation/validation.md +++ b/docs/data/date-pickers/validation/validation.md @@ -45,6 +45,9 @@ On the calendar and clock views—the invalid values are displayed as disabled t {{"demo": "ValidationBehaviorView.js", "defaultCodeOpen": false}} +### Empty string considered invalid +Empty string (`''`) values will be considered invalid. Pass `null` instead if you want a blank date-picker. + ## Past and future validation All pickers support the past and future validation.