-
Notifications
You must be signed in to change notification settings - Fork 405
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
KeyboardExtensions #1064
KeyboardExtensions #1064
Conversation
samples/CommunityToolkit.Maui.Sample/Pages/Extensions/KeyboardManagerExtensionsPage.xaml
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardManager.android.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardManager.android.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardManager.android.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardManager.android.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardManager.android.cs
Outdated
Show resolved
Hide resolved
samples/CommunityToolkit.Maui.Sample/Pages/Extensions/KeyboardExtensionsPage.xaml
Outdated
Show resolved
Hide resolved
samples/CommunityToolkit.Maui.Sample/ViewModels/Extensions/KeyboardExtensionsViewModel.cs
Outdated
Show resolved
Hide resolved
samples/CommunityToolkit.Maui.Sample/ViewModels/Extensions/KeyboardExtensionsViewModel.cs
Outdated
Show resolved
Hide resolved
samples/CommunityToolkit.Maui.Sample/ViewModels/Extensions/KeyboardExtensionsViewModel.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardExtensions.net.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardExtensions.shared.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've one suggestion
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardExtensions.shared.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardExtensions.shared.cs
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui.Core/Platform/KeyboardManager/KeyboardExtensions.shared.cs
Outdated
Show resolved
Hide resolved
…rdExtensions.shared.cs Co-authored-by: Vladislav Antonyuk <33021114+VladislavAntonyuk@users.noreply.github.com>
…rdExtensions.shared.cs Co-authored-by: Vladislav Antonyuk <33021114+VladislavAntonyuk@users.noreply.github.com>
Just did some initial testing - ran the sample on Windows and Android, and I'm not sure if the behavior I'm seeing is what we're expecting. (From what I've looked of the code so far (haven't looked at it all yet), this doesn't seem like the intended behavior)
|
Yea :-/ this is because of the automatically closing |
samples/CommunityToolkit.Maui.Sample/Pages/Extensions/KeyboardExtensionsPage.xaml.cs
Show resolved
Hide resolved
@PureWeen is this PR ready for review? |
@pictos marked as ready for review and talked to Shane for the docs, so ready to go! |
src/CommunityToolkit.Maui.Core/Platform/KeyboardExtensions/KeyboardExtensions.shared.cs
Show resolved
Hide resolved
How is this meant to be working? The documentation here makes no comment on the token functionality https://learn.microsoft.com/en-us/dotnet/api/microsoft.maui.itextinput.keyboard?view=net-maui-7.0 |
@al3xmeister entry.HideKeyboardAsync(); You can find our documentation here: https://learn.microsoft.com/dotnet/communitytoolkit/maui/extensions/keyboard-extensions And you can read more about the detailed API design and the motivation for adding this feature here: #1055 |
@brminnick Thanks Brandon, but doesnt answer my question. The microsoft documentation makes no reference to a cancellation token. It is a required parameter to HideKeyboardAsync();. I presume it's likely after activity.CurrentFocus?.WindowToken, however you can't access it from the return command of an entry. The sample does it from a button. Could this be updated or revisited? |
This video will be made public later today that goes over it: https://youtu.be/bIsGFx7jGcM the sample that goes with it is here: https://github.com/jfversluis/MauiToolkitKeyboardExtensionsSample If you don't plan on using the cancellation token you can pass in |
Description of Change
Linked Issues
PR Checklist
approved
(bug) orChampioned
(feature/proposal)main
at time of PR