Update javascript to allow categories to be hidden