Skip to content

Commit

Permalink
feat: 视图切换时更新禁用日期缓存
Browse files Browse the repository at this point in the history
  • Loading branch information
ArgoZhang committed Sep 28, 2024
1 parent 082b8a5 commit d679c9e
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -665,6 +665,13 @@ private async Task SwitchView(DatePickerViewMode view)
if (AllowSwitchModes[ViewMode].Contains(view))
{
CurrentViewMode = view;
if (view is DatePickerViewMode.Date or DatePickerViewMode.DateTime)
{
// update disabled days cache
_render = false;
await UpdateDisabledDaysCache(false);
_render = true;
}
StateHasChanged();
}
else if (AutoClose)
Expand Down

0 comments on commit d679c9e

Please sign in to comment.