nextcloud / calendar

📆 Calendar app for Nextcloud
https://apps.nextcloud.com/apps/calendar
GNU Affero General Public License v3.0
953 stars 235 forks source link

fix: delay initializing the resize observer until FC is ready #5995

Closed st3iny closed 2 months ago

st3iny commented 2 months ago

The calendar options are resolved asynchronously but the ref was accessed in mounted() which led the resize observer to not getting set up.

Now, the resize observer is started after the options were resolved and the FullCalendar component is actually mounted.

Before

https://github.com/nextcloud/calendar/assets/1479486/885dbe8b-dc68-43cf-b270-c57dab648862

After

https://github.com/nextcloud/calendar/assets/1479486/87e5c0dc-01d7-413f-b05b-d92a9777ec6d

st3iny commented 2 months ago

/backport to stable4.7

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 0% with 18 lines in your changes are missing coverage. Please review.

Project coverage is 23.50%. Comparing base (397c78e) to head (a40a200). Report is 2 commits behind head on main.

Files Patch % Lines
src/components/CalendarGrid.vue 0.00% 18 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #5995 +/- ## ============================================ - Coverage 23.51% 23.50% -0.02% Complexity 455 455 ============================================ Files 246 246 Lines 11722 11727 +5 Branches 2156 2157 +1 ============================================ Hits 2756 2756 - Misses 8650 8656 +6 + Partials 316 315 -1 ``` | [Flag](https://app.codecov.io/gh/nextcloud/calendar/pull/5995/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nextcloud) | Coverage Δ | | |---|---|---| | [javascript](https://app.codecov.io/gh/nextcloud/calendar/pull/5995/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nextcloud) | `15.14% <0.00%> (-0.01%)` | :arrow_down: | | [php](https://app.codecov.io/gh/nextcloud/calendar/pull/5995/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nextcloud) | `58.46% <ø> (ø)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nextcloud#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.