they dont all but thats more to do with a very careful diet.
The mothers body cannot get rid of the sugar in the body and so it all transfers through to the baby in the blood. this high blood sugar causes the baby to gain weight.
Gestational diabetes in the mother disappears straight after birth although it does increase the chance of it occuring in further pregnancies.
My neighbour is a diabetic (Insulin Dependent) She's had 4 big baby's. 2 of them weighed over a stone at birth! 2 of them are diabetic theirselves now.