New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: datetime wheel picker does not auto select first item #25839
Comments
@liamdebeasi Hi Liam, thanks for all the support so far. Did you have time to take a look at this issue? any workaround until a complete fix is release? |
Any updates about this issue? Still happening in Ionic 6.3.4. |
Any updates on this issue? Stil happening on Ionic 6.4.1. Thanks |
@RRGT19 @baartho @shaifulborhan The below work around worked for me: Until this bug gets resolved we can do the following as a workaround to make this behaviour work: ion-datetime triggers ionChange event only when there's a change in the value of ion-datetime.
With the above steps, the default value population without interaction will work correctly without a lot of code change. |
This comment was marked as outdated.
This comment was marked as outdated.
Hello everyone 👋 My previous dev-build has been updated: |
Issue number: resolves #25839 --------- <!-- Please do not submit updates to dependencies unless it fixes an issue. --> <!-- Please try to limit your pull request to one type (bugfix, feature, etc). Submit multiple pull requests if needed. --> ## What is the current behavior? <!-- Please describe the current behavior that you are modifying. --> Confirming the working day when a datetime using a wheel picker without an initial value will result in a value of `undefined` instead of the displayed working day the user sees. ## What is the new behavior? <!-- Please describe the behavior or changes that are being added by this PR. --> - `preferWheel` uses the working value on confirmation ## Does this introduce a breaking change? - [ ] Yes - [x] No <!-- If this introduces a breaking change, please describe the impact and migration path for existing applications below. --> ## Other information <!-- Any other information that is important to this PR such as screenshots of how the component looks before and after the change. --> Dev-build: `7.5.7-dev.11701896424.13d40ac9` Co-authored-by: liamdebeasi <liamdebeasi@users.noreply.github.com>
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Prerequisites
Ionic Framework Version
Current Behavior
When using the
ion-datetime
withpreferWheel
, I cannot choose the first date presented.The demo above shows
today
date by default, if the date that the user wants to select is today, he cannot do it.The same happens if I use a
max
date:Expected Behavior
The user should be able to select the first date that is presented.
Steps to Reproduce
Implement an
ion-datetime
withpreferWheel
as is and try to select the first date available shown on the wheel.Code Reproduction URL
https://github.com/RRGT19/ionic-test-datetime-with-no-initial-value
Ionic Info
Additional Information
The demo repo uses the dev build
6.2.5-dev.11661540078.1d2af6ea
that was provided here.The text was updated successfully, but these errors were encountered: