static getDerivedStateFromProps(nextProps, prevState) {
    if (
      nextProps.cellCount === 0 &&
      (prevState.scrollLeft !== 0 || prevState.scrollTop !== 0)
    ) {
      return {
        scrollLeft: 0,
        scrollTop: 0,
        scrollPositionChangeReason: SCROLL_POSITION_CHANGE_REASONS.REQUESTED,
      };
    } else if (
      nextProps.scrollLeft !== prevState.scrollLeft ||
      nextProps.scrollTop !== prevState.scrollTop
    ) {
      return {
        scrollLeft:
          nextProps.scrollLeft != null
            ? nextProps.scrollLeft
            : prevState.scrollLeft,
        scrollTop:
          nextProps.scrollTop != null
            ? nextProps.scrollTop
            : prevState.scrollTop,
        scrollPositionChangeReason: SCROLL_POSITION_CHANGE_REASONS.REQUESTED,
      };
    }

    return null;
  }
@private
This method updates scrollLeft/scrollTop in state for the following conditions:
1) Empty content (0 rows or columns)
2) New scroll props overriding the current state
3) Cells-count or cells-size has changed, making previous scroll offsets invalid