Each digit must belong to the source base. “f” is legal in base 16 and illegal in base 10. The value is read as an integer, so a decimal point is rejected.
The result uses lowercase letters for digits above 9. A leading minus is kept. Very long inputs are refused so a pasted blob is not treated as a number.