handleIntersectionChange method

bool handleIntersectionChange(
  1. IntersectionObserverEntry entry
)

Implementation

bool handleIntersectionChange(IntersectionObserverEntry entry) {
  final double intersectionRatio = entry.intersectionRatio;
  dispatchEvent(IntersectionChangeEvent(intersectionRatio));
  if (intersectionRatio > 0) {
    handleAppear();
  } else {
    handleDisappear();
  }
  return false;
}