* Checks if a value is valid against the current date format of the DatePicker. * @public * @param value A value to be tested against the current date format
(value: string)
| 352 | * @param value A value to be tested against the current date format |
| 353 | */ |
| 354 | isValid(value: string): boolean { |
| 355 | const parts = this._splitValueByDelimiter(value).filter(str => str.trim() !== ""); |
| 356 | |
| 357 | if (parts.some(dateString => this._isRelativeValue(dateString, this.getFormat()))) { |
| 358 | return false; |
| 359 | } |
| 360 | |
| 361 | return parts.length <= 2 && parts.every(dateString => super.isValid(dateString)); // must be at most 2 dates and each must be valid |
| 362 | } |
| 363 | |
| 364 | /** |
| 365 | * Checks if a value is valid against the current date format of the DatePicker. |
nothing calls this directly
no test coverage detected