Hockey legend Wayne Gretzky appeared to roil social media last week after photos surfaced of him and his family at an election party for President-elect Donald Trump.

Photos of Gretzky wearing a white Make America Great Again cap while at the party in Mar-a-Lago surfaced over the last week. "The Great One" was also seen with his wife Janet, daughter Paulina and his son-in-law Dustin Johnson.

CLICK HERE FOR MORE SPORTS COVERAGE ON FOXNEWS.COM

Wayne Gretzky in 2020

Wayne Gretzky smokes a cigar on the third hole during the third round of the AT&T Pebble Beach Pro-Am golf tournament at Pebble Beach Golf Links in Pebble Beach, California, on Feb. 8, 2020. (Michael Madrid-USA TODAY Sports)

The Canadian hockey legend received backlash on social media for his outfit choice.

Gretzky joined several athletes who have outwardly supported Trump on his way to defeating Vice President Kamala Harris in the presidential election last week.

Athletes like Nick Bosa, Harrison Butker, James Winchester, Brett Favre, Danica Patrick, Jake Paul, Antonio Brown, Le’Veon Bell and a slew of UFC fighters have come out in support of Trump over the last few months.

Wayne Gretzky at the draft

Wayne Gretzky on stage as Philip Broberg is selected as the number eight overall pick of the Edmonton Oilers in the first round of the 2019 NHL Draft at Rogers Arena in Vancouver, British Columbia, on June 21, 2019. (Anne-Marie Sorvin-USA TODAY Sports)

TRUMP WANTS NFL TO DITCH 'RIDICULOUS' KICKOFF RULE

Trump put on a dominating performance in the general election. He nearly swept all the battleground states. He claimed Wisconsin, Michigan and Pennsylvania – the states he needed to get through the supposed "blue wall" of Democrat-favored states.

He received 312 electoral votes and led the popular vote as well.

Trump speaks in California

Former President Donald Trump speaks during a news conference held at Trump National Golf Club Los Angeles in Rancho Palos Verdes, California, on Friday, Sept. 13, 2024. (AP/Jae C. Hong)

CLICK HERE TO GET THE FOX NEWS APP

Trump had received nearly 75 million votes as of early Monday. Harris had more than 71.2 million votes.

Follow Fox News Digital’s sports coverage on X, and subscribe to the Fox News Sports Huddle newsletter.