today I discovered that dcc.Input treats the float input 1.0 as the integer 1.

In the documentation there is this warning:

There is a limitation when converting numbers like 1.0 or 0.0, the corresponding number type in callbacks is Integer instead of Float . Please add extra guard casting like float() within callbacks if needed.

If I want to distinguish the input 1.0 and 1, how would I do it? I have Regex in mind, but wonder if there are any better solutions.

I would argue itâ€™s not good design to be able to input either fractions or percentage. Just make it clear in the input label which one should be used.