“You have to give him credit: He’s a great distractor,” Ms. Pelosi, Democrat of California, said of Mr. Trump on Wednesday. She waved off questions about whether the Democrats’ policy priorities were being eclipsed by the president, saying, “We’re not having him set our agenda; we’re setting our own agenda.”

But in recent days, thanks to Mr. Trump’s penchant for stirring up the hottest of political controversies and simmering divisions within their own ranks, House Democrats have not seemed to be able to get out of their own way. This week has been a case in point.

Mr. Trump’s tweets prompted a rush by Democratic leaders to press a resolution condemning him. The vote on the measure took place on Tuesday, and the floor debate devolved into an extraordinarily polarizing spectacle as Republicans and Democrats argued about whether it was appropriate for Ms. Pelosi to have branded the president’s tweets “racist.”

Then Mr. Green’s decision to force action on his impeachment resolution stretched the narrative into Wednesday, overshadowing marquee Democratic issues, including a vote this week to raise the minimum wage to $15 and one to repeal a tax on high-cost employer-sponsored health plans.

“It’s time for us to deal with his bigotry,” Mr. Green said on Wednesday. “This president has demonstrated that he’s willing to yell ‘fire’ in a crowded theater, and we have seen what can happen to people when bigotry is allowed to have a free rein. We all ought to go on record. We all ought to let the world know where we stand when we have a bigot in the White House.”

A separate vote on Wednesday evening to hold in contempt William P. Barr, the attorney general, and Wilbur Ross, the commerce secretary, for their refusal to comply with an investigation into the addition of a citizenship question to the census — a move the administration has since abandoned — added to the portrait of a House floor dominated by Mr. Trump and what Democrats consider his misdeeds.

“I wonder, when I watch people campaign and they talk about what they want to achieve here, how many said they wanted to have a week of contempt, of impeach and resolution all after one entity, the president of the United States?” said Representative Kevin McCarthy, Republican of California and the minority leader. “I didn’t have anybody on either side of the aisle ever ask me that question.”