dotnet / maui

.NET MAUI is the .NET Multi-platform App UI, a framework for building native device applications spanning mobile, tablet, and desktop.
https://dot.net/maui
MIT License
22.24k stars 1.76k forks source link

Searchbar keyboard is switching back to alphabet characters immediately after entering one numeric character #9594

Closed dusrdev closed 1 year ago

dusrdev commented 2 years ago

Description

Regardless of the type of Keyboard that is set, it tried all (Text, Chat, Default, Url)... when switching the keyboard to use the numeric characters, tapping any key enters that key but then immediately returns the keyboard to show the alphabet characters.

This makes entering consecutive numbers impossibly annoying.

Note

This behavior was seen on Android, both on emulator and after installing a release build on an Android device.

Steps to Reproduce

  1. Create Maui app
  2. In any page add a searchbar
  3. Open the app on the android
  4. Focus on the searchbar and use the virtual keyboard to enter a numeric character.

Version with bug

6.0.400

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 11

Did you find any workaround?

No...

Relevant log output

No response

ghost commented 2 years ago

We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

CodeSetting commented 2 years ago

Wow, I thought I was doing something wrong. I found I had to keep switching the keyboard for every digit I typed of a multi-digit number (on Android). I was surprised to find it's a known issue.

How is this issue not considered more serious? Its triaging has come close to convincing me to abandon MAUI.

In any data entry that involves numbers (e.g. street addresses), this is going to annoy every potential user of MAUI applications. I'm commenting here both to express my disappointment and so that I can track this issue.

Without a fix, I can't develop any MAUI applications that rely on numbers. This includes pretty much every serious application I've ever written.

Basic user interactions, like having the keyboard allow you to enter multi-digit numbers and having it get out of the way when data entry is complete, are the minimum requirements to develop any line-of-business application. Both of these interactions seem broken with some fairly common controls on Android.

I keep returning to MAUI, truly hoping to use it for anything real. However, every time I try, I find basic functionality that is missing or flawed.

It seems that perhaps Microsoft is not committed enough to this framework to provide appropriate staffing levels. This is a shame. I would much prefer to use MAUI than a competitor (e.g. Flutter). It shows tremendous promise!

However, at the current rate, it seems that promise will not be realized for at least a couple of years. Long before then, it will be too late. I'll have committed to a different framework. It's unlikely I'll return at that point. I suspect I am not alone in that regard.

For now, I'll continue to hope Microsoft increases staffing levels so that critical issues like this are not dismissed so quickly.

When tooling for VS 2022 was finally added, I thought it was time to use MAUI. It seems I was still premature.

NonameMissingNo commented 2 years ago

Hey there, I believe that android by default supports the 4th (number) row on the keyboard, so if it's only numbers, you should have that turned on. I do agree that it should be fixed, but it's not as big as some of the other issues (think crashes).

dusrdev commented 2 years ago

Wow, I thought I was doing something wrong. I found I had to keep switching the keyboard for every digit I typed of a multi-digit number (on Android). I was surprised to find it's a known issue.

How is this issue not considered more serious? Its triaging has come close to convincing me to abandon MAUI.

In any data entry that involves numbers (e.g. street addresses), this is going to annoy every potential user of MAUI applications. I'm commenting here both to express my disappointment and so that I can track this issue.

Without a fix, I can't develop any MAUI applications that rely on numbers. This includes pretty much every serious application I've ever written.

Basic user interactions, like having the keyboard allow you to enter multi-digit numbers and having it get out of the way when data entry is complete, are the minimum requirements to develop any line-of-business application. Both of these interactions seem broken with some fairly common controls on Android.

I keep returning to MAUI, truly hoping to use it for anything real. However, every time I try, I find basic functionality that is missing or flawed.

It seems that perhaps Microsoft is not committed enough to this framework to provide appropriate staffing levels. This is a shame. I would much prefer to use MAUI than a competitor (e.g. Flutter). It shows tremendous promise!

However, at the current rate, it seems that promise will not be realized for at least a couple of years. Long before then, it will be too late. I'll have committed to a different framework. It's unlikely I'll return at that point. I suspect I am not alone in that regard.

For now, I'll continue to hope Microsoft increases staffing levels so that critical issues like this are not dismissed so quickly.

When tooling for VS 2022 was finally added, I thought it was time to use MAUI. It seems I was still premature.

I have found a workaround, well, sort of...

Instead of searchbar, I use an entry with ReturnType set to Search and trigger the search with the Completed event, It also has an issue of being broken as when the ReturnType is set to Search and some other ones, tapping it with a finger on android at least does not trigger the event. But I have used a workaround from here and this solved that issue.

Now everything works as expected, and also the entry works with other ReturnTypes and all Keyboard types that I've tried.

As a sidenote, I've found just using entry a bit easier, styling it is easier because it less nested, as Searchbar is a parent of Entry and more stuff, and I don't know if you noticed but Searchbar alignment is also broken, it doesn't position itself well and has issues of filling space.

Basically, this is a very good workaround or alternative, definitely was good enough for me.

Obviously, it still bugs me that they don't prioritize this issue as it makes an entire control and a useful one at that unusable.

Hope this will work for you.

CodeSetting commented 2 years ago

Thank you @dusrdev that sounds promising. Though to be honest, I'm going to give most development on MAUI a rest for now. It's not just this one issue. It seems I need to keep finding "workarounds" for basic things. I'll maybe circle back in a year and hope that things are better then.

jsuarezruiz commented 2 years ago

The issue will be fixed by #9851 image