web-ridge / react-native-paper-dates

Smooth and fast cross platform Material Design date and time picker for React Native Paper
https://www.reactnativepaperdates.com
MIT License
657 stars 170 forks source link

Typing time from keyboard displays random minutes after selection, when I type 0 in minutes #412

Closed suprith7771 closed 3 days ago

suprith7771 commented 1 month ago

Current behaviour

Typing time from keyboard displays random minutes after selection, when I type 0 in minutes Like typing, 9 in hour is fine, 00 in minutes is fine 0 in minutes appends random trailing number.

Expected behaviour

0 minutes should take 00 minutes in selected time

How to reproduce?

running it in android platform, or android web ..

      <TimePickerModal
          use24HourClock={false}
          visible={modalVisible}
          onDismiss={toggleModal}
          onConfirm={(selectedDate) => {
            console.log(selectedDate);
            setSelectedTime(moment(selectedDate).format('HH:mm:ss.SSS[Z]'));
            toggleModal();
          }}
          hours={selectedTime ? moment(selectedTime).hours() : moment().hours()}
          minutes={
            selectedTime ? moment(selectedTime).minutes() : moment().minutes()
          }
        />

Is the module usage with my random data/entries

Preview

(Screenshot 2024-07-31 at 12 41 57 PM))

What have you tried so far?

Tried with different times

Your Environment

software version
ios x
android x
react-native 0.73.6
react-native-paper 0.20.5
node 20
npm or yarn x.x.x
expo sdk 50.0.15
iM-GeeKy commented 1 month ago

PRs are welcome!

github-actions[bot] commented 1 month ago

Hey! Thanks for opening the issue. Can you provide more information about the issue? Please fill the issue template when opening the issue without deleting any section. We need all the information we can, to be able to help. Make sure to at least provide - Current behaviour, Expected behaviour, A way to reproduce the issue with minimal code (link to snack.expo.dev) or a repo on GitHub, and the information about your environment (such as the platform of the device, versions of all the packages etc.).

github-actions[bot] commented 1 month ago

Hey! Thanks for opening the issue. Can you provide a minimal repro which demonstrates the issue? Posting a snippet of your code in the issue is useful, but it's not usually straightforward to run. A repro will help us debug the issue faster. Please try to keep the repro as small as possible. The easiest way to provide a repro is on snack.expo.dev. If it's not possible to repro it on snack.expo.dev, then you can also provide the repro in a GitHub repository.

github-actions[bot] commented 1 week ago

Hello 👋, this issue has been open for more than a month without a repro or any activity. If the issue is still present in the latest version, please provide a repro or leave a comment within 7 days to keep it open, otherwise it will be closed automatically. If you found a solution or workaround for the issue, please comment here for others to find. If this issue is critical for you, please consider sending a pull request to fix it.