Skip to content

Commit

Permalink
Merge pull request #5051 from antlionguard/master
Browse files Browse the repository at this point in the history
feat(Calendar): close calendar overlay if pressed enter, input value …
  • Loading branch information
tugcekucukoglu committed Jan 11, 2024
2 parents eb2575c + 9759913 commit 6e1ee87
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions components/lib/calendar/Calendar.vue
Expand Up @@ -2665,6 +2665,14 @@ export default {
if (this.overlayVisible) {
this.overlayVisible = false;
}
} else if (this.overlayVisible && event.code === 'Enter' && this.manualInput && event.target.value !== null && event.target.value?.trim() !== '') {
try {
if (this.isValidSelection(this.parseValue(event.target.value))) {
this.overlayVisible = false;
}
} catch (err) {
/* NoOp */
}
}
},
overlayRef(el) {
Expand Down

0 comments on commit 6e1ee87

Please sign in to comment.