Sensors and custom display classes

I’ve got a sensor that reports [‘connected’, ‘connecting’, ‘disconnected’, ‘disconnecting’] as possible values. I’d like to be able to display this sensor and have different icons/colors for each of the values. Is there a way to accomplish this?