Several users have reported an issue in which plugged in iPhones or iPads will charge to 100% and then slowly drain down while it is still plugged in.
Calibrate your battery. Basically use the device until the battery has completely drained so that device turns itself off. Recharge the battery fully to 100%. Do this once a month.
Restart your device by pressing and holding the Sleep/Wake button for a few seconds until you see the red “slide to power off” then slide the slider.