fix safari resizing issue