I know this is an old thread and the OP hasn't responded back, but I'd like to address the charger issue in case others run across this thread.
Aftermarket chargers are generally safe. Obviously it's a bit of buyer beware, especially when buying something like a dirt cheap dollar store charger, but the name brand chargers (Anker, Aukey, Chotech, etc.) are fine. There are multiple charging and power supply standards for USB, and chargers and phones will communicate with each other to negotiate the proper protocol to use. With some of the newest protocols, even the cable design comes into play.
The underlying rule of all the different protocols is that they must also be backwards compatible. A QC 4.0 charger will also work with earlier versions, and with traditional 5V charging. You could plug in a phone from 10 years ago and it would charge fine.
We don't even know if the OP was using the OEM or aftermarket charger. We also don't know the age of the batteries in question, or charging/usage habits. If this is a repeating problem, there's a small chance the charger is defective, but there's also a number of other variables that could cause the swelling.