How does Hypnotic Pattern work in the dark?

If you cast hypnotic pattern in the dark (assuming the caster has dark vision), does the spell work regardless, or does the target have to be able to actually see (with or without dark vision) for the spell to affect them?