This is wrong. Unless you're using an OLED screen (pretty unlikely), black usually requires more energy to display.
Also, there's no way to determine screen technology through normal JavaScript (without plugins/addons), so changing it to make the script only apply to OLED screens would be infeasible.
Some people are way too enthusiastic about things they don't totally grasp.
Cf. carbon expenditure, recycling (some forms), hybrid automotives, rails (lot of fakers in the 'community'), etc.
Edit: I would like to add however, that black does save energy on CRTs. But again, detection of screen technology is a fail here and the vast majority of users are using LCDs. Not worth the potential hassle. "Why can't I watch the whole video without the screen going black?!"
Supposing black does take less energy to display, I wonder how often and how long users would need to stay idle to even break even after increased energy is used to load the script (even when it's not used) and fire to the animation when it is.
silly - your computer is much more effective at managing its power usage than a bit of javascript copied to every website in the world (you want this to be effective, right?) is going to be.
I remember reading about someone saying that Google should do this for their home screen. Then someone else proving that black actually costs more than white.
Also, there's no way to determine screen technology through normal JavaScript (without plugins/addons), so changing it to make the script only apply to OLED screens would be infeasible.