White chocolate melts like dark chocolate because the two share a fat, not because they share a color. Cocoa butter does the work. The pale confection contains cocoa butter, milk and sugar, but leaves out the nonfat cocoa solids that give darker chocolate much of its brown color and characteristic flavor.
The texture is a feat of chemistry. Cocoa butter consists largely of triglycerides, whose molecules can arrange themselves into several crystalline forms, a property known as polymorphism. Not all crystals behave alike. When chocolate is tempered, controlled heating and cooling encourage a stable crystal structure that gives a bar its snap and helps it remain firm at room temperature. That structure melts near body temperature, releasing the fat and carrying sugar and milk across the tongue. Dark chocolate uses the same trick, although its cocoa solids add flavor and texture to the experience.
Color, then, is a poor guide to what the mouth will feel. Milk and sugar soften the flavor, while the missing cocoa solids leave little of the roasted bitterness associated with dark chocolate. Recipes vary, and products made with other fats may melt differently; cocoa butter is what gives white chocolate its familiar resemblance to a dark bar. The contrast is almost theatrical. One piece looks pale, the other deep brown, yet both can disappear on the tongue, leaving their differences to linger in the taste.