I still own a 27" Thunderbolt Display that I have hooked up to a M1 MBA via Apples TB3 to TB2 Adapter. After replacing the frayed TB/MagSafe cable the display performed great without any issues until recently when it started emitting a buzzing or ticking noise from the (integrated) power supply.
I found a post online hinting that a failed filter capacitor might cause this issue so I thought I might give a shot at replacing it.
For me it wasn't the first time tearing open a TBD but if it is for you I can recommend the following guide at Ifixit:
ifixit.com
Here the PSU is out:

The orange capacitor on the top left next to the AC input is the suspect of our problem.

Old and new. It is a 275V 0.22µF X2 capacitor. I chose a Wima MKX21W32204F00KSSD as a replacement which cost me a whopping € 0.86.

It's been a couple of days after replacing the filter capacitor and there has been no buzzing noise since.
I found a post online hinting that a failed filter capacitor might cause this issue so I thought I might give a shot at replacing it.
For me it wasn't the first time tearing open a TBD but if it is for you I can recommend the following guide at Ifixit:
Apple Thunderbolt Display Teardown
Crafted from the fire pits of Hephaestus himself, and thrust down to Earth by the mighty Zeus, the Apple Thunderbolt Display arrived at the...

Here the PSU is out:

The orange capacitor on the top left next to the AC input is the suspect of our problem.

Old and new. It is a 275V 0.22µF X2 capacitor. I chose a Wima MKX21W32204F00KSSD as a replacement which cost me a whopping € 0.86.

It's been a couple of days after replacing the filter capacitor and there has been no buzzing noise since.