close when click next to layer