visibility problem in js