A man who threw a two-month-old baby in the air before shaking the child has been told to expect a lengthy jail sentence.

The High Court in Edinburgh heard the little boy is now registered blind and suffers from cerebral palsy after suffering serious brain injuries.

Jay Bell, 23, of Dougall Place, Mayfield, Midlothian, admitted culpable and reckless conduct towards the baby to his severe injury, permanent impairment and to the danger of his life.

He threw the child repeatedly in the air but the baby struck his head on a wall, hit a Moses basket and fell to the floor. Bell then shook the child a number of times. He also admitted wilfully neglecting the baby and failing to seek medical attention.

Defence solicitor advocate John Keenan sought to have Bell remain on bail ahead of sentencing next month but a judge rejected the move.

Judge Paul Arthurson QC said there had been "catastrophic medical sequelae" for the child and told Bell: "These offences are likely to attract a substantial custodial sentence."

The court heard Bell, a joiner, had been looking after the baby on July 26, 2013 at a house in Midlothian.

Advocate depute Andrew Brown QC, prosecuting, said Bell had been lying on a bed and throwing the child up and down, catching him.

He said: "On one occasion he failed to catch him properly and he fell, first striking his head on the wall behind the bed, then striking the Moses basket and finally the floor, landing on his side.

"The accused looked at the child who was staring at him vacantly. [He] picked him up and shook him repeatedly until he began to cry. He then tried to settle the child but without success."

Bell later babysat the child again when the baby suffered fits but did not seek medical help, although at one stage he filmed him in the process of a seizure.

The child was later taken to the Royal Hospital for Sick Children in Edinburgh. He was found to have swelling and bleeding on the brain, retinal haemorrhaging and a fractured rib and ankle.

Mr Brown said: "He was acutely unwell on admission to hospital and had what medical professionals term the 'triad' of injuries that are associated to so-called 'shaken baby syndrome'."

Bell later told police the baby was "staring at me completely lifeless".

"His eyes were looking at me and he was completely straight not doing anything," Bell told officers.

"So I picked him up and tried to shake him to come back round. I [don't know] how long I shook him for - maybe 10 seconds - that's what it felt like to me. He came round and started crying."

A paediatric specialist said a baby of that age should never have been tossed in the air as the child required head support.

Mr Brown said the child, now two and a half, is unable to sit unaided. A consultant had indicated he may be able to walk with the use of a walker if he does well. He is partially sighted and has difficulty seeing more than a metre in front of him.

The prosecutor said the Crown accepted that while Bell's conduct was "plainly culpable and reckless", it lacked the wicked intent for an assault. He said the throwing of a child of that age was "inherently dangerous".

Mr Keenan said Bell had suffered from depression, experienced nightmares and could not sleep.