Add class to variation generated with display function, missed in #4605