Making a joke or jokes about the visual difference of black people, is it racism? Why yes, why not?

The other day I made a joke in another social media group about the color of a person's skin. "That one over there is a ""hot chocolate""" my joke was supposed to say that person looks very hot and beautiful, but it seems I had been accused of being racist.
In my real life experience black people some time had told me even more racist jock where I had asked myself "is it ok to joke like that?"
Anyway, should I make absolutely no joke about our differences? I don't come from a former colonizing country, so it's not a problem to make a cute joke there. But in a country with a troubled past, it seems that it is.

Making a joke or jokes about the visual difference of black people, is it racism? Why yes, why not?
Post Opinion