What elements were in the atomic bomb in world war 2?

As the physics of nuclear explosives has not changed, pretty much the same elements as are used now. The main changes are not the elements, but the compounds that contain them (e.g. the chemical explosives have been replaced with safer ones, but both the old and new chemical explosives contain the same elements just in different arrangements.

Polonium is an element used in the neutron sources of all 4 atomic bombs built during world war 2 (Gadget, Little Boy, Fat Man, and an unnamed bomb that was never used) that is no longer used in modern nuclear explosives. Polonium based neutron sources have a shelf life of roughly 180 days due to radioactive decay. These were replaced by electrically activated tritium fusion based neutron sources sometime in the middle 1950s which have a shelf life of roughly 12 years due to radioactive decay.

Lithium is an element used in some modern nuclear explosives that was not used in world war 2, it is converted to tritium in those bombs for use as fusion fuel. The first use of lithium in a nuclear explosive was in 1953 by the USSR.

It is important to realize that many many elements other than the nuclear fuels must be used in a nuclear explosive to make it work.