Open Eagle3386 opened 2 weeks ago
I'd like to do a PR to add those 4 types, if the maintainers would agree with me. 😉
Please go for it! Just as a heads up, I did an initial quick try a while back and quickly ran into some issues...Don't say you were not warned!! (😂)
🐛 Bug Report
I chose "bug" over "feature request" since a component named
FluentNumberField
should have supported the unsigned equivalents ofint
,long
,sbyte
&short
right from the start. Because I can't imagine a reason to not enable developers to limit sliders, steppers, etc. to positive values only (talking mostly age, RGB color & range pickers here, but applies to customer ID fields as well).On a more personal note, I'm really having a hard time understanding why (C#) developers still prefer
int CustomerId
overuint CustomerId
since such a property never really contains a negative integer. But I assume it's just like withdecimal
which - besides scientific calculations - should always be preferred overfloat
&double
(AFAIK, even the C# docs explicitly state this).. 😅💻 Repro or Code Sample
🤔 Expected Behavior
As I explicitly declared
HideStep="true"
above, the following method shouldn't even get called. However, if it's necessary for some reason, this code insideFluentNumberField.razor.cs
:should include the 4 unsigned numerics, too.
😯 Current Behavior
A
InvalidOperationException
is thrown:💁 Possible Solution
I'd like to do a PR to add those 4 types, if the maintainers would agree with me. 😉
🔦 Context
Provide my app's users with a couple of numeric input fields which are completely preventing any negative value.
On a side note, the XML Doc for
Max
&Min
should clarify ifMaxlength
&Minlength
are needed anyway or if the former already take care of that.🌍 Your Environment