Heat during wireless charging is pretty normal because the process is less efficient than using a cable. Energy gets lost as heat during the transfer, especially if the charger or phone has low-quality coils or they don't line up properly. That said, if it's "uncomfortable to touch" you're probably overdoing it. Ideally it should be warm, not hot. Try removing the case if you have one on (sometimes it traps more heat), make sure the phone and charger are properly aligned, and there's nothing metal in between.
If it's still really hot after that, the problem could be that specific Anker charger. Not all wireless chargers are equally efficient, and some cheap ones generate too much heat. It's also possible the Galaxy A54's coil is damaged, but that's less likely. Best thing to do is use Samsung's USB-C cable while you investigate. Extreme heat can affect the battery long-term, so you're not being paranoid. If you have another wireless charger lying around, try it to see if the problem is the Anker or the phone.