Samsung Galaxy S8 - S10 Series, Note 8 - 9 Series and A8/A8+ support water and dust resistance of IP68 level.
IP68 rating means complete protection from dust ingress and temporary immersion in up to 1.5m of freshwater for up to 30 minutes.
However, if the device is charged when the USB port is exposed to water/moisture/humidty, there is a risk of short circuits and device may damage.
To prevent this, the device limits to charge properly and displays the caution notification text with water recognition icon on both notification panel and AOD screen.
To fully resume the charging power, dry the device throughly before use and keep it at a well-ventilated place for a certain period of time.
For faster drying, hold the device with the speaker facing downward and shake gently. Dry the device throughly using cool wind is also helpful.