MudNumericField does not fire OnKeyDown event if ReadOnly is set to true
#11.585 aberto em 2 de jul. de 2025
Métricas do repositório
- Stars
- (10.394 estrelas)
- Métricas de merge de PR
- (Mesclagem média 6d 6h) (108 fundiu PRs em 30d)
Description
Things to check
- I have searched the existing issues for this bug
- To rule out a caching problem I made sure the bug also happens in an incognito tab
Bug type
Component
Component name
MudNumericField
What happened?
When a MudNumericField has ReadOnly set to true, it does not fire OnKeyDown events even if a key is pressed and the component has focus.
Expected behavior
When ReadOnly property is set to true, I would expect that the OnKeyDown event is still fired for the component, even if the input is not updated. This happens on MudTextField components, but does not happen in MudNumericField components. I have added a TryMudblazor Snippet where this behaviour happens.
Reproduction link
https://try.mudblazor.com/snippet/GOQJELYmTyFiUcuD
Reproduction steps
1.Run Code Snippet 2.Click on MudNumericField, then any keyboard key, nothing will happen. 3.Click on MudTextField, then any keyboard key, the value will be updated by OnKeyDown event ...
Relevant log output
Version (bug)
8.9.0
Version (working)
No response
What browsers are you seeing the problem on?
Chrome
On which operating systems are you experiencing the issue?
Windows
Blazor rendering mode
WASM
Code of Conduct
- I agree to follow this project's Code of Conduct