Called Liquid Contact Indicators (LCI), these are tiny color-changing stickers that are placed in various places inside a device -- usually near ports, SIM card slots, and other ingress points for water.
Not only are these used to indicate that water has actually made its way into a device, but also to know how far the water spread.
LCIs are used in a variety of devices, from smartphones and tablets to portable game consoles.
Anything people are likely to drop down the toilet.
Here are the LCI stickers that Apple used in iPhones a few years ago (these were used from the iPhone 8 to iPhone X). Apple still uses LCI stickers in its devices, but they vary in size and location.
These things are tiny, smaller than a grain of rice.
When they encounter water, they change from white to red. What's happening here is that exposure to water causes the white coating on the top of the sticker to melt, which in turn reveals the red color beneath.
Over the years, I've had a few questions about LCIs, and what will and won't trigger them.
First, note that the process is irreversible, and drying an LCI will not make it white again.
Another question is whether solvents like isopropyl alcohol will trigger the LCI. I've tested both 99% and 70% isopropyl alcohol, and neither triggers the LCI.
Some people think that if you soak an LCI in isopropyl alcohol, it will no longer turn red when exposed to water. This is not true; the LCI remains active.
Do fizzy drinks trigger LCIs? You bet they do!
Finally, does being in a humid environment trigger LCIs? I placed one in a bag, breathed into it so that there was condensation in the bag, and set it so that the LCI didn't touch a surface with condensation. After over an hour, the LCI remained white.
If you own an iPhone, you can see one LCI by removing the SIM tray and looking into the slot for the white dot (hopefully, it's still white, anyway!)