After the 1.2 update, there's a random Solar Eclipse event that causes hordes of powerful enemies to spawn. These enemies occasionally drop Hero's Broken Sword, which can be crafted with Excalibur and Night's Edge to create True Excalibur and True Night's Edge, then these 2 blades can be crafted with another Hero's Broken Blade to create the Terra Blade, the most powerful blade in the game. All 3 of these blades release energy projectiles when swung. Are these projectiles considered melee, ranged or magic damage for purposes of equipment bonuses and buffs?
They are considered magic damage by the game. The terraria wiki states that the Terra Blade "is a Sword/Magic Weapon that fires sword-shaped projectiles." Also, if you kill a player with the projectile, it gives a death message that does not contain the word "terra blade" (or similar), rather it gives the name of the projectile, though this is not necessarily related
Just tested this by using different headgears with the terra blade. I can confirm that melee damage boosts the terra blade projectiles, not mage damage.
After it shows the base damage it should say magic, melee, or ranged. For instance X sword would say 74 melee damage. This would mean that all damage done by the sword, whether it's a projectile or the blade, it would do melee damage. Hope this helps!