Make formatMessage aware if min and max rules were created from Javascript (and not markup)

Closes #385