I am sure that what you are referring to as a 5v transformer is not a transformer at all , but rather a 5vDC power supply. These wall warts us switch power supply technologies because they are small, light and cheap to produce. And while they may be great for cell phone chargers or to power computers, switching supplies are horribly noisy and not suited well for high end audio at all. When you plugged it into your preamp you connected the neutral side of the wall wart to the neutral side of the preamp essentially creating a superhighway for all of the high frequency garbage created by the switching supply to travel right into your preamp circuitry, hence the sonic degradation you are hearing.
There are several thing you can do to minimize the impact of the wall wart. First off the best thing you can do is to eliminate it all together by replacing it with a linear power supply thatdoesn't generate noise in the first place, but that will run you a few bucks.
Next you could use an extension cord try to plug the wall wart into a different outlet that is on another breaker. This is easy from a test point of view as we all have some extension cord laying around, but it may not be practical as a long term solution and I am not sure how much improvement you will get as the noise could double back into the breaker powering your system and some of the noise could be RF and still find its way into your system. It may not help much, but it is easy to try.
If you could plug the wall wart into a Digi or Uberbuss that would probably block most of the noise from making it's way into your system.
A really good source for an upgraded 5v power supplies at reasonable prices is iFi. The sell several models of power supplies (some in a wall wart style case) that employ active noise cancellation technology to eliminate not only switching supply generated noise but also block EMI/RFI on your incoming line . The units start at around &40 and go up to $300 with the higher priced units employing more complex noise cancelling for progressively quieter DC output. Personally I use one of the iFi supplies plugged into a Digibuss to power my Pro-ject DAC and the Raspberry Pi Roon endpoint, and I can hear no ill effects when the wall wart is inserted into the system this way.
The iFi units can be ordered form Audio advisor with their 30 day return policy so if it doesn't help you can get a full refund.
https://www.audioadvisor.com/ssearch.asp?txtsearch=ifi+power+supply