jQuery 2.0.2, HTML, CSS, JavaScript
jQuery 1.7.2, HTML, CSS, JavaScript
Uses check boxes and custom functions to display checked legend items in color, and the others in grey.
This is a simple Bootstrap skeleton. You can fork it to get a ready to use Bootstrap fiddle.
No-Library (pure JS), HTML, CSS, JavaScript