Skip to content

Bug: Unable to reopen date/time picker without refreshing #84

@priyanshu1976

Description

@priyanshu1976

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

📌 Issue Overview
When trying to add an appointment using the form, the Select Date and Select Time pickers stop working if I accidentally press the back key after opening them once. Once this happens, the pickers do not open again until I refresh the entire app.

🔍 Steps to Reproduce
Go to the Add Appointment form.
Tap on Select Date or Select Time — the picker opens.
Press the back key (instead of selecting a date/time).
Try opening the Select Date or Select Time again.
The picker does not open anymore.

Expected Behavior
The Select Date and Select Time pickers should open every time the user taps on them, even if they previously pressed the back key.

Actual Behavior
After pressing the back key once while the picker is open, the pickers become unresponsive and cannot be opened again without refreshing the app.

Screenshot

IMG_2396.mp4

Suggested Improvements
Ensure the date/time picker modal resets properly after being dismissed via the back key.
Possibly reset picker state (e.g., isPickerOpen = false) when the modal is closed or the back button is pressed.
Add a try-catch or event listener for the back key to prevent the component from freezing.

Record

  • I agree to follow this project's Code of Conduct
  • I want to work on this issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions