quasar-ui-qcalendar
quasar-ui-qcalendar copied to clipboard
fix mouse composable overwriting previous listeners (multi calendar)
When having multiple calendars rendered on one page, events would behave incorrectly.
Due to having global variables store the listeners/emit in useMouse.js
, they were dropped, when a new calendar would initialize them.
E.g. Having 2 calendars, both listening to onTimeClick
-Event, now clicking on calendar1 would cause calendar2's listener to fire.
I stored the emit/listeners in the default function, which seems to solve the problem. Not sure if there were other reasons for having these global?