A teenage father who shook his three-week-old daughter to death has been detained for eight years.

21-year-old Thomas Haining pleaded guilty to killing his daughter Mikayla at the Inverness family home on June 8, 2017, but refused the charge of murder.

The Crown accepted its culpable commitment to the lesser offense of culpable murder and was convicted on the High Court in Edinburgh.

The court heard him inflict "catastrophic" brain injury on his daughter in a "momentary loss of control" and leave her in a coma with a broken skull and several broken ribs.

Mikayla's head was hit against a door during the attack.

Haining had got up on the night of June 7, 2017, to take care of Mikayla, who had cried more than usual in the few days before her death and suffered from diarrhea.

With ex-girlfriend Shannon Davies sleeping upstairs in their home in Inverness, Haining claimed to have taken Mikayla out of her Moses basket early in the morning of 8 June to feed her. Afterwards he said she was sleepy and did not react anymore.

Telephone records show that Haining searched four times on the Internet for information about babies in coma and asked, "What happens if a newborn is shaken severely?"

Paramedics were called and taken to the hospital, where they were taken to the intensive care unit with a ventilator after suffering cardiac arrest as a result of head trauma.

Later in the afternoon, the baby was released from life support and placed in the arms of her mother, where she died at 16:46.

After denying killing his daughter for two years, the Crown prosecutors accepted a culpable confession from Haining on September 5 for culpable murder.

Shelagh McCall QC, representing Haining, told the court on Tuesday that he had been in prison for a long time and that he now "hated" himself.

She claimed that the killer had panicked after the incident, but now he wished he had realized his actions earlier.

Ms. McCall said, "He described himself as a reflection of the fact that he should have been manning and telling the truth at this time, as a clear affirmation from Mr. Haining that he alone is responsible for what happened and that he is the one Truth should have said much earlier than he did. "

She added, "He's getting ready for a significant jail sentence, which he believes is justified by the gravity of his actions, disgusted with himself, hating for what he did."

The court heard that the 21-year-old had a problematic education and a history of violence as a teenager, even though he had no previous criminal convictions.

Judge Lord Pentland said: "In the early hours of June 8, 2017, you killed your little daughter Mikayla.

"I use the term" killed "because the Crown has accepted your belated acknowledgment of guilt and does not insist on the original, more serious charge of murder on the basis that you did not intend to kill Mikayla.

"Mikayla was 23 days old. She was in sole charge of her at the time of her death.

"They shook her and hit her head against the door, so she was so badly injured that she later died.

"Everyone knows that shaking a baby is very dangerous.

"It was clearly a violent and serious attack on a very vulnerable baby.

"After the attack, you sought late for help and for a while tried to hide what you did.

"Their immediate response was to protect themselves rather than seek help for Mikayla."

Haining was sentenced to eight years in prison, which was postponed to September 11.

The judge said that the sentence would have been nine years if brought to justice.

Additional reporting Press Association