Javascript incarnation of the rotadex