A street assault victim found her attacker sound asleep in her bed when she returned home after the violence.
The woman was battered and bruised, with a shoeprint on her face, after a beating in the street by Jordan Stacey.
Newcastle Crown Court heard when the injured mum realised the 24-year-old was asleep in her bed and could not be woken, she locked him in the house and the police were contacted.
Prosecutor Paul Rowland told the court the victim had been in a previous relationship with Stacey, which had broken up a year before the attack on May 8.
Mr Rowland said the former couple had been on the same night out in Ashington where they had kissed and spent time together.
During the evening, the victim began to suspect Stacey had taken her telephone and a bunch of keys, which sparked violence when she confronted him.
The court heard during an initial attack Stacey knocked his victim unconscious with a blow.
When she came to and asked him for her belongings, the violence flared again.
Mr Rowland said: “He punched her with fists, knocked her to the floor and while on the floor she was kicked and stamped on, numerous times.”
The court heard Stacey ran off from the attack, which happened near a pizza shop and the injured victim eventually made her way home.
Mr Rowland added: “She found her front door open. She found her keys and her mobile phone on the table and the defendant was upstairs in bed, asleep.
“She tried to rouse him to get him out of the house.
“He could not be roused therefore she left and locked the defendant in the house.”
The court heard the victim went to her mother’s house and the police were contacted.
Stacey, of Villette Path, Hendon, Sunderland, was arrested and pleaded guilty to assault.
Stacey, who was on a suspended sentence and a conditional discharge at the time, pleaded guilty to assault.
He has previous convictions for domestic violence.
Judge Penny Moreland jailed him for 22 months.
The judge told him: “I have seen photographs of the injuries, abrasions to her face and a clear shoe mark plus two black eyes.
“It was a sustained attack.
“It seems you had taken her keys and phone from her.
“You used her keys to get back into her house, where you went to bed.”
Jamie Adams, defending, said Stacey accepts his behaviour was wrong and he has been taking positive steps while in custody.
Mr Adams said Stacey has an employment history and is “not without intelligence”.