grid resizing fix