After defiantly rejecting calls for his resignation, Boris Johnson said Thursday that he would step down as leader.
The monarch met with the Prime Minister on Wednesday at Buckingham Palace, where the snapshot could be seen in the background.
A spokesman for the couple said both mother and child were doing well.
Johnson said he owes hospital staff his life.
Johnson was admitted "for tests" after displaying "persistent symptoms."