-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
MudInput: Dispose iOS Blur With Error Handling #11436
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
Conversation
|
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.
Pull Request Overview
This PR refactors the disposal logic in MudInput
to use InvokeVoidAsyncWithErrorHandling
for the iOS blur event teardown, suppressing errors when the Blazor circuit is disconnected, and marks the old helper as obsolete.
- Marks
MudDetachBlurEventWithJS
as obsolete inElementReferenceExtensions
- Replaces the old blur-detach helper call in
MudInput.razor.cs
with an error-handling JS invocation - Retains auto-grow destruction logic under the same error-handling approach
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
ElementReferenceExtensions.cs |
Added [Obsolete] to old blur-detach helper and updated its message |
MudInput.razor.cs |
Moved blur-detach JS call into DisposeAsyncCore using error handling |
Comments suppressed due to low confidence (1)
src/MudBlazor/Components/Input/MudInput.razor.cs:376
- Add or extend unit tests to cover the new disposal path, verifying that
removeOnBlurEvent
is invoked correctly and errors are properly suppressed when the JS runtime is disconnected.
protected override async ValueTask DisposeAsyncCore()
@ScarletKuro Anything I need on this one? |
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 think we could merge this and release v8.8.0 shortly after. Got enough changes ready for it
Description
Resolves #11434
Move actual JS call to DisposeAsync method so I can use InvokeVoidAsyncWithErrorHandling suppressing error messages when circuit is disconnected.
How Has This Been Tested?
BSS with Docs.Server, WASM with UnitTests.Viewer
Type of Changes
Checklist
dev
).