move x to the corner and enable close on overlay