Ion-datetime keyboard input

Hi,
I have used Ionic to build a simple web page app. This project I don’t package as a mobile app, but just deploy it to be served from a server.

Now the app will sometimes be displayed on mobile device and sometimes on a PC.

My specific problem is the ion-datetime element. The date picker works nice on touch devices, but is cumbersome to use on laptops and such. Is there any way, I can get it working with keyboard? After reading the docs for the element, I haven’t found any mention regarding keyboard input whatsoever.

If not, could I somehow conditionally show a different element (regular text fields maybe?) if this is a device without a touch screen?

Thanks for any suggestions!

version I use:


    "@angular/common": "~12.1.1",
    "@angular/core": "~12.1.1",
    "@angular/forms": "~12.1.1",
    "@angular/platform-browser": "~12.1.1",
    "@angular/platform-browser-dynamic": "~12.1.1",
    "@angular/router": "~12.1.1",
    "@ionic/angular": "^5.5.2",

Keyboard support in the Ionic 5 datetime picker is a known limitation. Ionic 6 has a new datetime picker that is compatible with the keyboard. Check out ionic-framework/BETA.md at 3c4f9fd2d5ed0d378cae6ef7c33a1b2d21d82e38 · ionic-team/ionic-framework · GitHub if you are interested in trying the Ionic 6 RC.

Hi, thanks for the info.

// edit: Oh, sorry. The migration guide is on the very link you posted. OK, will give it a try.