The photons produced in nuclear fusion reactions travel less than a mm before they are absorbed inside the Sun. They don't "fight their way out". New photons are emitted continuously by the hot plasma (by thermal bremsstralung and other processes), but they too are quicky absorbed. However, there is a gradual diffusion of radiation and energy outwards because there is a temperature gradient that exists between the inside and outside of the Sun. As the plasma temperature decreases, the dominant photon wavelengths in the (approximately) blackbody radiation field get longer and longer, but individual photons still do not escape the Sun. 

The photons we do receive at the Earth are mostly visible and infrared photons produced in the photosphere, which is where the Sun's atmosphere finally becomes thin enough and cool enough to be transparent to the photons *produced locally*. Hence they escape and may travel to the Earth and we see radiation that is characteristic of the solar photospheric temperature, not that of the solar interior.

As to what exactly produces that visible light, there are a variety of mechanisms. However, the dominant one at most wavelengths through the visible and near infrared regimes is the photo-recombination continuum radiation (free-bound radiation) produced when free electrons (made available by ionising sodium and potassium atoms) attach themselves to hydrogen atoms to form H$^{-}$ ions (the inverse process dominates the continuum photospheric opacity in a star like the Sun, e.g., [Wildt 1939][1] [the original paper to identify this]; [John 1992][2]; and [these lecture notes][3]). 


  [1]: https://ui.adsabs.harvard.edu/abs/1939ApJ....90..611W
  [2]: https://ui.adsabs.harvard.edu/abs/1992MNRAS.256...69J/abstract
  [3]: https://www.ucolick.org/~woosley/ay112-14/useful/opacityshu.pdf