House Democratic Leader Nancy Pelosi (D-Calif.) speaks during a news conference on Capitol Hill on Thursday. (Yuri Gripas/Reuters)

Congress sent President Trump a short-term spending bill Thursday to move back the deadline for a partial government shutdown, setting up a high-stakes fight over Trump’s U.S.-Mexico border wall just before Christmas.

The legislation sets a new deadline of Dec. 21 for Trump and Democrats to resolve their standoff over funding for the wall, which is holding up action on spending bills to fund the Department of Homeland Security and other federal agencies.

If the dispute is not resolved, funding for those agencies will expire, causing them to begin to shut down and furlough workers in the middle of the holiday season.

“We don’t want to see the government shut down over Christmas, even though President Trump seems to brag that he wants one,” Senate Minority Leader Charles E. Schumer (D-N.Y.) said Thursday on the Senate floor. But, Schumer said, “The wall request is a nonstarter.”

Without the short-term bill, the spending deadline would be Friday at midnight. But lawmakers this weekend agreed to a two-week extension as Congress participated in memorial events for former president George H.W. Bush.

Both the House and the Senate passed the legislation by voice vote Thursday. Trump is expected to sign the measure.

But the bill does nothing to resolve the central dispute looming over the final days of the 115th Congress: Trump’s demand for $5 billion to fund his long-promised wall along the border with Mexico.

In their waning days in control of the House, Republicans know it’s their last shot to get Trump the money for the wall that was the signature promise of his presidential campaign. Trump long claimed Mexico would pay for the wall, but he is now asking that U.S. taxpayers pay for it.

“I do believe it’s become more and more of a line in the sand, especially when you have just a week or two left to be able to finalize things and get it across the finish line,” said Rep. Mark Walker (R-N.C.). “This is a huge issue that not only the president campaigned on, but many other members said, ‘Hey, this Congress we’re going to get this done.’ ”

Schumer and House Minority Leader Nancy Pelosi (D-Calif.) are set to meet with Trump on Tuesday. But the party leaders have repeatedly rejected Trump’s $5 billion demand, especially as Democrats prepare to take over the House in January.

Schumer and Pelosi on Thursday proposed extending funding at current levels for the Department of Homeland Security through the end of the budget year — which would allocate about $1.3 billion for border security and fencing for 2019.

Schumer said Trump’s other option would be to accept a bipartisan bill negotiated in the Senate providing $1.6 billion for border security and fencing, a deal that has been on the table for months.

“The one and only way we approach a shutdown is if President Trump refuses both of our proposals and demands $5 billion or more for a border wall,” Schumer said.

Pelosi, speaking at a Capitol Hill news conference Thursday, said the border wall is “immoral, ineffective and expensive, and the president . . . He also promised that Mexico would pay for it. Even if they did, it’s immoral still, and they’re not going to pay for it.”

Pelosi also rejected the idea that the standoff could be resolved with a broader immigration deal, saying she would not trade wall funding for protections for immigrants brought illegally to the country as children, because “they’re two different subjects.”

Trump is showing no signs of backing off his demand for wall money. Instead, in a tweet this week, he returned to an earlier demand of $25 billion for the wall.

The president has repeatedly threatened to shut down the government over wall funding, and he was ready to do so in October. But GOP leaders, fearful of a messy clash days away from the midterm elections, persuaded him to wait, in part by promising to fight for wall funds in December.

Sen. John Cornyn (Tex.), the No 2. Senate Republican, said he “can’t believe” the president would take Democrats’ deal to extend the $1.3 billion level.

“He wants money for border security, and we’re not going to give him anything other than current level of funding?” Cornyn said. “I can’t see how in the world that would be acceptable.”

Senate Appropriations Committee Chairman Richard C. Shelby (R-Ala.) said that the last time he talked to Trump, the president was “steadfast” on getting the $5 billion he wants for the wall.

“Somebody’ll have to blink,” Shelby said, adding: “I think the president’s going to have to get something. He is the president. He has sent some strong messages to most everybody. What that’ll be, we’re not sure yet.”

The White House Office of Management and Budget said in a statement Thursday: “It’s disappointing, yet not surprising, that Democratic leadership puts border security on the bottom of their priority list. They’d rather shut down the government than protect the men and women who put their lives on the line to protect our borders and our sovereignty. The president has been clear about his priorities from the beginning and we’re eager to continue working with Congress to reach a deal.”

Adding to the complications, lawmakers are planning to approve a large disaster relief package for recent wildfires and hurricanes and attach it to whatever spending legislation moves. They are also hashing out disputes on a handful of other issues, including an attempt by Democrats to add language to the spending package to block the Commerce Department from adding a question to the 2020 Census asking whether people are U.S. citizens.

Earlier this year Congress passed spending bills funding about 75 percent of the government through next September, agreeing to big increases for the Pentagon, the Department of Health and Human Services and other agencies. That means any shutdown would be limited in scope, affecting only the agencies whose 2019 budgets have not yet been approved and whose funding is set to expire Dec. 21.

Nevertheless, the impacts would be widespread. In addition to Homeland Security, other agencies that would be affected include the Interior and Agriculture departments, the Justice Department, NASA, the Commerce Department, the Department of Housing and Urban Development, and the Transportation Department, as well as many smaller agencies. These agencies employ more than 600,000 federal workers.

The impact of a partial shutdown would depend on whether it stretched into the following workweek. There were two brief partial government shutdowns this year, one of which was resolved within hours.

A partial funding lapse could lead U.S. embassies overseas to cut back on staffing temporarily, because the State Department’s budget would be held in limbo, and it could also force the Justice Department to slow or suspend a number of federal prosecutions.

The shutdown would not, however, suspend special counsel Robert S. Mueller III’s Russia investigation, as that probe has a separate, permanent funding source that cannot be changed by lawmakers.

Similarly, it would not have a direct impact on military operations or the pay of service members, as the Pentagon’s budget was approved in September. Medicare and Social Security benefits would similarly continue to be paid and unaffected.

Federal employees labeled “nonessential” personnel probably would be sent home without pay for the duration of any shutdown if they work for agencies affected by the budget lapse. These employees tend to be those whose jobs don’t directly interface with national security or public health.

And a shutdown that lasts more than several days could force Border Patrol officers who are deemed “essential” to continue working, but without pay until Congress and the White House reach an agreement.

Damian Paletta and Lisa Rein contributed to this report.