import getMaxScroll from "../../state/get-max-scroll";
import getDocumentElement from "../get-document-element";

const getMaxWindowScroll = () => {
  const doc = getDocumentElement();
  return getMaxScroll({
    // clipped padding box, with scrollbar
    scrollHeight: doc.scrollHeight,
    scrollWidth: doc.scrollWidth,
    // clipped padding box, without scrollbar
    width: doc.clientWidth,
    height: doc.clientHeight
  });
};

export default getMaxWindowScroll;
