cleaned up js, first pass at filters