Wanda Sykes goes to court in “Drop Dead Diva”

But the key to Diva is its heart — the theme that beauty goes beyond the surface. Much of the first two seasons were about body image, since the premise of the show is that a model who died “before her time” returned to life in the body of plus-sized attorney Jane Bingum (Brooke Elliott).

But as the show has matured, the theme has expanded to encompass the whole of self-acceptance. And no one is more familiar with the struggles embracing identity that the LGBT community.

So, when Diva creator Josh Berman heard Constance McMillen’s story about not being allowed to attend her senior prom with her girlfriend, then saw McMillen present Wanda Sykes with a GLAAD Media Award last year, his imagination went to work.

“The notion of just having to fight just to go to your school dance was something that really resonated with me,” Berman told EW. “As a writer, I couldn’t have come up with some of the plot points in this episode out of thin air. Reading about Constance’s case, and also several other truth life stories about gay men and lesbian women who were denied access to prom that inform this episode, it’s just a head scratcher to me.”

The episode dramatizes McMillen’s experience and features Berman’s dream guest.

“When I wrote the episode, of course, my dream was to cast Wanda, never thinking that she would do it,” he said. “We sent her the pages, and she read the script, and she said yes. It came full circle.”

Sykes plays Judge Yvonne Wright, who is “acerbic, very funny and clever, and doesn’t take any crap from anyone, as we would expect Wanda to be.” Berman told EW that Sykes’ perspective as an African-American woman will cause some verbal sparring with Jane. McMillen herself will cameo as a bailiff.

Berman said that the subject matter has attracted some other guest stars that want to be part of it. Personally, I think Lindsey Shaw would make a great Constance. Of course, I think Shaw would make a great anybody.