"use strict";
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const createProjectionNode = require("./create-projection-node.js");
const DocumentProjectionNode = require("./DocumentProjectionNode.js");
var rootProjectionNode = {
  current: void 0
};
var HTMLProjectionNode = createProjectionNode.createProjectionNode({
  measureScroll: function(instance) {
    return {
      x: instance.scrollLeft,
      y: instance.scrollTop
    };
  },
  defaultParent: function() {
    if (!rootProjectionNode.current) {
      var documentNode = new DocumentProjectionNode.DocumentProjectionNode(0, {});
      documentNode.mount(window);
      documentNode.setOptions({ layoutScroll: true });
      rootProjectionNode.current = documentNode;
    }
    return rootProjectionNode.current;
  },
  resetTransform: function(instance, value) {
    instance.style.transform = value !== null && value !== void 0 ? value : "none";
  },
  checkIsScrollRoot: function(instance) {
    return Boolean(window.getComputedStyle(instance).position === "fixed");
  }
});
exports.HTMLProjectionNode = HTMLProjectionNode;
exports.rootProjectionNode = rootProjectionNode;
//# sourceMappingURL=HTMLProjectionNode.js.map
