yurkinh / Plugin.Maui.Calendar

.NET MAUI port of XF calendar plugin
MIT License
108 stars 11 forks source link

Eventindicators not rendered when adding new events #52

Closed marcustindab closed 3 months ago

marcustindab commented 3 months ago

Hi,

We're having some issues where new events are added to the Calendar. The indicator "dots" aren't being drawned before we have clicked on a day we know have an event. Then the dots for all events are being displayed/rendered in calendar. How to solve this? Trigger any OnPropertyChanged from our viewmodel?

marcustindab commented 3 months ago

This issue exists in both version 1.1.4 and 1.1.5.

Take a look at this video recording: https://github.com/yurkinh/Plugin.Maui.Calendar/assets/147273496/a1808210-e918-411d-aa10-1a139b01884c

yurkinh commented 3 months ago

Hi @marcustindab Thanks for the report and video. Could you provide some sample for easier debugging?

marcustindab commented 3 months ago

Hi @yurkinh ,

I've created a small reproduction of this. See the attached zip-file. Sandbox.zip

yurkinh commented 3 months ago

Hi @marcustindab I will take a look later today. Thanks for the repro sample

yurkinh commented 3 months ago

@marcustindab Replacing TryAdd with Add has fixed this issue) Events.Add(new DateTime(date.Year, Month, day), new List { new() { Description = "An Event" } });

marcustindab commented 3 months ago

Thank you for your quick repsonse - your suggested change solved the issue for us. Keep up the good work!

Closing the issue.