President Obama on Wednesday jabbed at Republican presidential candidate Donald TrumpDonald John TrumpHouse Freedom Caucus calls for Congress to work on shutdown through break Democrat previews Mueller questions for Trump’s AG nominee Trump inaugural committee spent ,000 on makeup for aides: report MORE over his proposal to ban Muslims from entering the United States. 

Speaking at an event at the U.S. Capitol commemorating the 150th anniversary of the abolition of slavery, Obama said, “We betray the efforts of the past if we fail to push back against bigotry in all its forms.”

ADVERTISEMENT

Obama called on Americans to “hold fast to our values” and advance the work done by abolitionists and civil rights leaders.

"All it requires is that our generation be willing to do what those who came before us have done: to rise above the cynicism and rise above the fear,” Obama said. “To remember that our freedom is bound up in the freedom of others, regardless of what they look like, or where they come from, or what their last name is, or what faith they practice.” 

The president’s line about faith, a clear shot at Trump, received a standing ovation from the sizable crowd gathered in the Capitol Visitors Center.  

Congressional leaders from both parties were on hand to watch the speech, but Speaker Paul RyanPaul Davis RyanAnti-Defamation League calls on House leaders to censure Steve King over white supremacy comments Former Ryan fundraisers launch firm Romney writes new chapter in his like-hate relationship with Trump MORE (R-Wis.) and Senate Majority Leader Mitch McConnellAddison (Mitch) Mitchell McConnellRomney calls on Steve King to resign after comments on white supremacy Don't underestimate the power of nationwide outrage born from financial desperation Top Dem introduces short-term spending bills to reopen government MORE (R-Ky.) did not stand after Obama delivered the blow to Trump. Senate Minority Leader Harry ReidHarry Mason ReidOvernight Defense: Trump rejects Graham call to end shutdown | Coast Guard on track to miss Tuesday paychecks | Dems eye Trump, Russia probes | Trump talks with Erdogan after making threat to Turkey's economy Harry Reid on Iraq War vote: 'It tainted my heart' Harry Reid urges senators to push for more UFO research MORE (D-Nev.) also stayed seated.

On the heels of terrorist attacks in Paris and San Bernardino, Calif., Trump said Monday he would “shut the door” on all Muslims who want to enter the United States.

The proposal drew condemnation from Democrats and Republicans alike and has consumed the attention of the media and the country.

Top Republicans, including Ryan and McConnell, rushed to distance the GOP from his remarks, a sign the party fears his mere presence in the race could endanger their chances of taking back the White House next fall.

The White House did not deny that the president’s comments were a shot at Trump. 

“I’m not going to wave you off consideration of the idea” that Obama’s message “stands in stark contrast to message from a variety of Republican presidential candidates,” White House press secretary Josh Earnest said.

Earnest only offered that nothing was “newly inserted” into the speech to rebuff the billionaire real estate magnate. 

But the White House has been eager to fan the political flames.

Vice President Joe BidenJoseph (Joe) Robinette BidenGillibrand to kickstart 2020 White House bid before weekend Iowa trip Harry Reid on Iraq War vote: 'It tainted my heart' New Hampshire is ‘must-win’ state for Warren, says veteran political reporter MORE said Tuesday that if Trump is the Republican Party’s presidential nominee, Democratic front-runner Hillary ClintonHillary Diane Rodham ClintonTrump boasts about checking gas prices while in motorcade: 'You think Hillary Clinton would've done that?' Harry Reid on Iraq War vote: 'It tainted my heart' New Hampshire is ‘must-win’ state for Warren, says veteran political reporter MORE will “win in a walk.”

Earnest said earlier Tuesday that Trump's proposal should disqualify him from serving as president. He accused GOP leaders of not going far enough to condemn Trump, calling on them to pledge not to support him if he is the party’s nominee. 

Trump's plan was a rejection of Obama's plea to the nation Sunday night, where he warned against conflating terrorism and religion.  

"We cannot turn against one another by letting this fight be defined as a war between America and Islam," Obama said in the Oval Office.

Reflecting on the accomplishments of the civil rights movement, such as the defeat of Jim Crow laws across the South and the Voting Rights Act, Obama on Wednesday expressed confidence the nation would continue to make progress toward equality. 

“That’s what we celebrate today, the long arc of progress. Progress that is never assured or guaranteed, but it is possible,” he said. “No matter how divided or despairing, no matter what ugliness might bubble up, progress as long as we are willing to push for it.”

Scott Wong contributed.

- Updated at 1:28 p.m.