Overall meaning :
Allah Almighty says: Allah has granted you victory, O believers—the Messenger of Allah’s companions, over your unbelieving enemies in many battles, and also in the Battle of Hunayn when your great numbers made you proud, but they availed you nothing; and the earth, vast as it is, seemed too narrow for you due to the extreme hardship and distress you suffered, then you turned tail and fled from the unbelievers in defeat.
Then Allah sent down inner peace and reassurance on His Messenger and the believers, and He sent armies of angels that you could not see, and inflicted punishment on the unbelievers at the Battle of Hunayn at the hands of the believers. Such was the punishment of the unbelievers.
Then after that Allah turns in His mercy to whomsoever He wills of the unbelievers by guiding them to Islam. Allah is All-Forgiving, All-Merciful.