Vitamin A

A bit confused because I got told I’m not meant to have vitamin A while pregnant yet it says to eat some fruit and vege that is high in it?