An iPhone liquid detected alert blocks charging until the port is dry, so unplug the cable, let it air dry for at least 30 ...
If you’ve had your phone for some time, a blocked charging port might well be a problem.