Simplify JsMacroImpl and add support for case classes with a single custom generic field.

Prior to this, a compile-time error would be thrown when trying to create a formatter
for a case class with a single field that is of a custom type-parameterised type.

This change fixes that and simplifies some of the logic when trying to get unapplyTypes.