Dishwasher detergent is full of chlorine and is therefore very corrosive. I have no problem with aquaeous cleaning of almost any electronics (mind anything that is mechanical though, like a relay unless it is sealed) but I prefer to use liquid dish-washing soap rather than dishwasher detergent. The key is to rinse and let everything dry thoughly. I even used this on a laptop keyboard when my dad spilled cough syrup into it (yech).
It is always best if you can totally disassemble it - this usually means a housing, a circuit board, a rubber sheet full of domes, and the keys themselves (usually held captive by the top cover). Disassembled like this, you can do a better job of cleaning, rinsing and air drying. With assembled cleaning, there is always that danger that water got in some place under pressure that it will take ages to air-dry out of.