In the heat of the moment:If you say or do something in the heat of the moment, you say or do it without thinking because you are very angry or excited: (一时冲动、激动之下/盛怒之下)
E.G.1:What seems the obvious course of action in the heat of the moment isn’t necessarily the most effective one.
E.G.2:He lost his cool during the meeting and in the heat of the moment, shouted at his boss and called him names.