question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

In Gatsby, in Firefox, all click events close calendar

See original GitHub issue

When react-date-picker is used in a Gatsby app within a Firefox browser all click events (whether on the calendar days or the navigation arrows at the top) all close the calendar instantly. When I click on a day, the calendar closes without inputting a date. All click events seem to trigger react-date-picker--open class to change to react-date-picker--closed before anything else can happen.

To reproduce, spin up a new gatsby project and drop the datepicker in anywhere. I did not see this problem with a create-react-app.

If I mount the react-date-picker component on the DOM via ReactDOM, this fixes the problem, but that doesn’t seem like a good workaround in my use case.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
pedrofsantoscomcommented, Aug 31, 2020

Adding disableEnforceFocus={true} to Material UI Dialog fixed it:

import { Dialog } from '@material-ui/core'

<Dialog disableEnforceFocus={true} ></Dialog>
1reaction
marcoanconacommented, Nov 17, 2020

Facing a similar issue with a custom calendar implementation. Maybe a shouldCalendarClose optional prop that, given the event triggering the close, can return true/false to change the behavior?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Double-clicking calendar event doesn't go directly to the Edit ...
There is another workaround: select an event in the Events & Tasks/Find Events pane, press Enter. Read this answer in context 1. All...
Read more >
1685007 - Double-clicking an event now shows an unwanted ...
In the calendar daily view, add an event stub by clicking and dragging between the starting hour and the end hour. Once the...
Read more >
Unable to save changes to events in calendar - Mozilla Support
I click on Save and Close and when I go back in to the event the changes have not been saved. Any ideas?...
Read more >
How can I "group-move" a large selection of events from one ...
I am trying to segregate out all birthdays and anniversaries from my primary personal "Home" calendar in Lightning and place them into ...
Read more >
Official Florida Keys Tourism Council Calendar of Events
Florida Keys & Key West events calendar from the Official Florida Keys Tourism Council. View Florida Keys events and activities by month and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found