import { isHTMLElement, isLastTraversableNode, getParentNode } from "../../../../../@floating-ui/utils/dist/floating-ui.utils.dom.js";
function findRootOwnerId(node) {
  if (isHTMLElement(node) && node.hasAttribute("data-rootownerid")) {
    return node.getAttribute("data-rootownerid") ?? void 0;
  }
  if (isLastTraversableNode(node)) {
    return void 0;
  }
  return findRootOwnerId(getParentNode(node));
}
export {
  findRootOwnerId
};
//# sourceMappingURL=findRootOwnerId.js.map
