added clear selection option
js compile and whitespace changes