Why does chocolate sometimes turn white?
This is called chocolate bloom, and there are two types. Fat bloom is caused by cocoa butter moving through the chocolate and crystallising on its surface. This can happen because of a quick temperature change or from storing chocolate in a warm space. Sugar bloom may happen if your chocolate is stored in a damp area and is caused by moisture collecting on the surface, drawing out the sugar. Once the moisture evaporates, it leaves sugar crystals behind.
To prevent chocolate from blooming, keep it in an airtight container in a cool part of your kitchen; the refrigerator is actually too humid for chocolate.
Although it may not look as appetising, bloomed chocolate is perfectly edible and will taste exactly the same, although the texture might be a little grainier. If it bothers you, you can reverse bloomed chocolate by melting it down and then shaping it again.