if (
        next.page.top >= offsetPosition.top + offsetBorder.top &&
        next.page.bottom >= offsetPosition.bottom
      ) {
        if (