“The Supreme Court is probably the choice that will have the single most long-term effect on the nation,” said Representative Jason Chaffetz, Republican of Utah, where Mr. Trump is struggling to win over an overwhelmingly Republican state.

Congressional Republicans who are up for re-election — especially the handful like Senators John McCain of Arizona and Kelly Ayotte of New Hampshire who still face primaries — have made a basic calculation. They have criticized Mr. Trump, but not withdrawn their endorsements. And party leaders have decided the more distance they put between themselves and Mr. Trump, the more likely they are to lose their congressional majorities.

Alienating Mr. Trump’s supporters would cost them just enough votes to lose their seats. Their fears at this point appear justified. A poll conducted the last week of July by CBS News found that support for Mr. Trump among Republican voters rose to 81 percent from 79 percent.

So the leaders largely responded to Mr. Trump’s attacks with feigned indifference.

“Republican elected officials are in a tough spot,” said Nathan L. Gonzales, the editor of The Rothenberg & Gonzales Political Report, a nonpartisan newsletter. “They are criticized for not listening to the grass roots and criticized for not denouncing the nominee chosen by the grass roots. Some Republicans are reluctant to attack Donald Trump because they’d risk alienating 35 to 40 percent of the party who supported him in the primaries.”