Skip to content

Commit

Permalink
fix: correct handling of invalid date inputs
Browse files Browse the repository at this point in the history
Refs: #6602
  • Loading branch information
anicyne committed Jul 19, 2024
1 parent fbb5fbd commit ee726bd
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions packages/components/src/components/input-date/shadow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -438,11 +438,7 @@ export class KolInputDate implements InputDateAPI, FocusableElement {
if (value instanceof Date) {
deprecatedHint('Date type will be removed in v3. Use `Iso8601` instead.');
}
this.controller.validateValueEx(value, (v) => {
if (v === '' && this.inputRef) {
this.inputRef.value = '';
}
});
this.controller.validateValueEx(value);
}

public componentWillLoad(): void {
Expand Down

0 comments on commit ee726bd

Please sign in to comment.