Socket
Socket
Sign inDemoInstall

@floating-ui/dom

Package Overview
Dependencies
Maintainers
2
Versions
75
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@floating-ui/dom - npm Package Compare versions

Comparing version 1.4.1 to 1.4.2

4

dist/floating-ui.dom.esm.js

@@ -592,3 +592,3 @@ import { rectToClientRect, computePosition as computePosition$1 } from '@floating-ui/core';

}
if (ratio === 0) {
if (!ratio) {
timeoutId = setTimeout(() => {

@@ -604,3 +604,3 @@ refresh(false, 1e-7);

rootMargin,
threshold
threshold: max(0, min(1, threshold)) || 1
});

@@ -607,0 +607,0 @@ io.observe(element);

@@ -595,3 +595,3 @@ (function (global, factory) {

}
if (ratio === 0) {
if (!ratio) {
timeoutId = setTimeout(() => {

@@ -607,3 +607,3 @@ refresh(false, 1e-7);

rootMargin,
threshold
threshold: max(0, min(1, threshold)) || 1
});

@@ -610,0 +610,0 @@ io.observe(element);

@@ -1,1 +0,1 @@

!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@floating-ui/core")):"function"==typeof define&&define.amd?define(["exports","@floating-ui/core"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).FloatingUIDOM={},t.FloatingUICore)}(this,(function(t,e){"use strict";function n(t){var e;return(null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function o(t){return n(t).getComputedStyle(t)}function i(t){return t instanceof n(t).Node}function r(t){return i(t)?(t.nodeName||"").toLowerCase():"#document"}function c(t){return t instanceof n(t).HTMLElement}function l(t){return t instanceof n(t).Element}function f(t){return"undefined"!=typeof ShadowRoot&&(t instanceof n(t).ShadowRoot||t instanceof ShadowRoot)}function s(t){const{overflow:e,overflowX:n,overflowY:i,display:r}=o(t);return/auto|scroll|overlay|hidden|clip/.test(e+i+n)&&!["inline","contents"].includes(r)}function u(t){return["table","td","th"].includes(r(t))}function d(t){const e=a(),n=o(t);return"none"!==n.transform||"none"!==n.perspective||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((t=>(n.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(n.contain||"").includes(t)))}function a(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function h(t){return["html","body","#document"].includes(r(t))}const p=Math.min,g=Math.max,m=Math.round,y=Math.floor,w=t=>({x:t,y:t});function x(t){const e=o(t);let n=parseFloat(e.width)||0,i=parseFloat(e.height)||0;const r=c(t),l=r?t.offsetWidth:n,f=r?t.offsetHeight:i,s=m(n)!==l||m(i)!==f;return s&&(n=l,i=f),{width:n,height:i,$:s}}function b(t){return l(t)?t:t.contextElement}function v(t){const e=b(t);if(!c(e))return w(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:r}=x(e);let l=(r?m(n.width):n.width)/o,f=(r?m(n.height):n.height)/i;return l&&Number.isFinite(l)||(l=1),f&&Number.isFinite(f)||(f=1),{x:l,y:f}}const T=w(0);function L(t,e,o){var i,r;if(void 0===e&&(e=!0),!a())return T;const c=t?n(t):window;return!o||e&&o!==c?T:{x:(null==(i=c.visualViewport)?void 0:i.offsetLeft)||0,y:(null==(r=c.visualViewport)?void 0:r.offsetTop)||0}}function O(t,o,i,r){void 0===o&&(o=!1),void 0===i&&(i=!1);const c=t.getBoundingClientRect(),f=b(t);let s=w(1);o&&(r?l(r)&&(s=v(r)):s=v(t));const u=L(f,i,r);let d=(c.left+u.x)/s.x,a=(c.top+u.y)/s.y,h=c.width/s.x,p=c.height/s.y;if(f){const t=n(f),e=r&&l(r)?n(r):r;let o=t.frameElement;for(;o&&r&&e!==t;){const t=v(o),e=o.getBoundingClientRect(),i=getComputedStyle(o),r=e.left+(o.clientLeft+parseFloat(i.paddingLeft))*t.x,c=e.top+(o.clientTop+parseFloat(i.paddingTop))*t.y;d*=t.x,a*=t.y,h*=t.x,p*=t.y,d+=r,a+=c,o=n(o).frameElement}}return e.rectToClientRect({width:h,height:p,x:d,y:a})}function R(t){return((i(t)?t.ownerDocument:t.document)||window.document).documentElement}function P(t){return l(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function C(t){return O(R(t)).left+P(t).scrollLeft}function S(t){if("html"===r(t))return t;const e=t.assignedSlot||t.parentNode||f(t)&&t.host||R(t);return f(e)?e.host:e}function E(t){const e=S(t);return h(e)?t.ownerDocument?t.ownerDocument.body:t.body:c(e)&&s(e)?e:E(e)}function F(t,e){var o;void 0===e&&(e=[]);const i=E(t),r=i===(null==(o=t.ownerDocument)?void 0:o.body),c=n(i);return r?e.concat(c,c.visualViewport||[],s(i)?i:[]):e.concat(i,F(i))}function j(t,i,r){let f;if("viewport"===i)f=function(t,e){const o=n(t),i=R(t),r=o.visualViewport;let c=i.clientWidth,l=i.clientHeight,f=0,s=0;if(r){c=r.width,l=r.height;const t=a();(!t||t&&"fixed"===e)&&(f=r.offsetLeft,s=r.offsetTop)}return{width:c,height:l,x:f,y:s}}(t,r);else if("document"===i)f=function(t){const e=R(t),n=P(t),i=t.ownerDocument.body,r=g(e.scrollWidth,e.clientWidth,i.scrollWidth,i.clientWidth),c=g(e.scrollHeight,e.clientHeight,i.scrollHeight,i.clientHeight);let l=-n.scrollLeft+C(t);const f=-n.scrollTop;return"rtl"===o(i).direction&&(l+=g(e.clientWidth,i.clientWidth)-r),{width:r,height:c,x:l,y:f}}(R(t));else if(l(i))f=function(t,e){const n=O(t,!0,"fixed"===e),o=n.top+t.clientTop,i=n.left+t.clientLeft,r=c(t)?v(t):w(1);return{width:t.clientWidth*r.x,height:t.clientHeight*r.y,x:i*r.x,y:o*r.y}}(i,r);else{const e=L(t);f={...i,x:i.x-e.x,y:i.y-e.y}}return e.rectToClientRect(f)}function D(t,e){const n=S(t);return!(n===e||!l(n)||h(n))&&("fixed"===o(n).position||D(n,e))}function W(t,e){return c(t)&&"fixed"!==o(t).position?e?e(t):t.offsetParent:null}function H(t,e){const i=n(t);if(!c(t))return i;let l=W(t,e);for(;l&&u(l)&&"static"===o(l).position;)l=W(l,e);return l&&("html"===r(l)||"body"===r(l)&&"static"===o(l).position&&!d(l))?i:l||function(t){let e=S(t);for(;c(e)&&!h(e);){if(d(e))return e;e=S(e)}return null}(t)||i}function M(t,e,n){const o=c(e),i=R(e),l="fixed"===n,f=O(t,!0,l,e);let u={scrollLeft:0,scrollTop:0};const d=w(0);if(o||!o&&!l)if(("body"!==r(e)||s(i))&&(u=P(e)),c(e)){const t=O(e,!0,l,e);d.x=t.x+e.clientLeft,d.y=t.y+e.clientTop}else i&&(d.x=C(i));return{x:f.left+u.scrollLeft-d.x,y:f.top+u.scrollTop-d.y,width:f.width,height:f.height}}const z={getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:i,strategy:c}=t;const f="clippingAncestors"===n?function(t,e){const n=e.get(t);if(n)return n;let i=F(t).filter((t=>l(t)&&"body"!==r(t))),c=null;const f="fixed"===o(t).position;let u=f?S(t):t;for(;l(u)&&!h(u);){const e=o(u),n=d(u);n||"fixed"!==e.position||(c=null),(f?!n&&!c:!n&&"static"===e.position&&c&&["absolute","fixed"].includes(c.position)||s(u)&&!n&&D(t,u))?i=i.filter((t=>t!==u)):c=e,u=S(u)}return e.set(t,i),i}(e,this._c):[].concat(n),u=[...f,i],a=u[0],m=u.reduce(((t,n)=>{const o=j(e,n,c);return t.top=g(o.top,t.top),t.right=p(o.right,t.right),t.bottom=p(o.bottom,t.bottom),t.left=g(o.left,t.left),t}),j(e,a,c));return{width:m.right-m.left,height:m.bottom-m.top,x:m.left,y:m.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:e,offsetParent:n,strategy:o}=t;const i=c(n),l=R(n);if(n===l)return e;let f={scrollLeft:0,scrollTop:0},u=w(1);const d=w(0);if((i||!i&&"fixed"!==o)&&(("body"!==r(n)||s(l))&&(f=P(n)),c(n))){const t=O(n);u=v(n),d.x=t.x+n.clientLeft,d.y=t.y+n.clientTop}return{width:e.width*u.x,height:e.height*u.y,x:e.x*u.x-f.scrollLeft*u.x+d.x,y:e.y*u.y-f.scrollTop*u.y+d.y}},isElement:l,getDimensions:function(t){return x(t)},getOffsetParent:H,getDocumentElement:R,getScale:v,async getElementRects(t){let{reference:e,floating:n,strategy:o}=t;const i=this.getOffsetParent||H,r=this.getDimensions;return{reference:M(e,await i(n),o),floating:{x:0,y:0,...await r(n)}}},getClientRects:t=>Array.from(t.getClientRects()),isRTL:t=>"rtl"===o(t).direction};Object.defineProperty(t,"arrow",{enumerable:!0,get:function(){return e.arrow}}),Object.defineProperty(t,"autoPlacement",{enumerable:!0,get:function(){return e.autoPlacement}}),Object.defineProperty(t,"detectOverflow",{enumerable:!0,get:function(){return e.detectOverflow}}),Object.defineProperty(t,"flip",{enumerable:!0,get:function(){return e.flip}}),Object.defineProperty(t,"hide",{enumerable:!0,get:function(){return e.hide}}),Object.defineProperty(t,"inline",{enumerable:!0,get:function(){return e.inline}}),Object.defineProperty(t,"limitShift",{enumerable:!0,get:function(){return e.limitShift}}),Object.defineProperty(t,"offset",{enumerable:!0,get:function(){return e.offset}}),Object.defineProperty(t,"shift",{enumerable:!0,get:function(){return e.shift}}),Object.defineProperty(t,"size",{enumerable:!0,get:function(){return e.size}}),t.autoUpdate=function(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:i=!0,ancestorResize:r=!0,elementResize:c=!0,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:f=!1}=o,s=b(t),u=i||r?[...s?F(s):[],...F(e)]:[];u.forEach((t=>{i&&t.addEventListener("scroll",n,{passive:!0}),r&&t.addEventListener("resize",n)}));const d=s&&l?function(t,e){let n,o=null;const i=R(t);function r(){clearTimeout(n),o&&o.disconnect(),o=null}return function c(l,f){void 0===l&&(l=!1),void 0===f&&(f=1),r();const{left:s,top:u,width:d,height:a}=t.getBoundingClientRect();if(l||e(),!d||!a)return;const h=y(u),p=y(i.clientWidth-(s+d)),g=y(i.clientHeight-(u+a)),m=y(s);let w=!0;o=new IntersectionObserver((t=>{const e=t[0].intersectionRatio;if(e!==f){if(!w)return c();0===e?n=setTimeout((()=>{c(!1,1e-7)}),100):c(!1,e)}w=!1}),{rootMargin:-h+"px "+-p+"px "+-g+"px "+-m+"px",threshold:f}),o.observe(t)}(!0),r}(s,n):null;let a,h=null;c&&(h=new ResizeObserver(n),s&&!f&&h.observe(s),h.observe(e));let p=f?O(t):null;return f&&function e(){const o=O(t);!p||o.x===p.x&&o.y===p.y&&o.width===p.width&&o.height===p.height||n();p=o,a=requestAnimationFrame(e)}(),n(),()=>{u.forEach((t=>{i&&t.removeEventListener("scroll",n),r&&t.removeEventListener("resize",n)})),d&&d(),h&&h.disconnect(),h=null,f&&cancelAnimationFrame(a)}},t.computePosition=(t,n,o)=>{const i=new Map,r={platform:z,...o},c={...r.platform,_c:i};return e.computePosition(t,n,{...r,platform:c})},t.getOverflowAncestors=F,t.platform=z,Object.defineProperty(t,"__esModule",{value:!0})}));
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@floating-ui/core")):"function"==typeof define&&define.amd?define(["exports","@floating-ui/core"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).FloatingUIDOM={},t.FloatingUICore)}(this,(function(t,e){"use strict";function n(t){var e;return(null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function o(t){return n(t).getComputedStyle(t)}function i(t){return t instanceof n(t).Node}function r(t){return i(t)?(t.nodeName||"").toLowerCase():"#document"}function c(t){return t instanceof n(t).HTMLElement}function l(t){return t instanceof n(t).Element}function f(t){return"undefined"!=typeof ShadowRoot&&(t instanceof n(t).ShadowRoot||t instanceof ShadowRoot)}function s(t){const{overflow:e,overflowX:n,overflowY:i,display:r}=o(t);return/auto|scroll|overlay|hidden|clip/.test(e+i+n)&&!["inline","contents"].includes(r)}function u(t){return["table","td","th"].includes(r(t))}function d(t){const e=a(),n=o(t);return"none"!==n.transform||"none"!==n.perspective||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((t=>(n.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(n.contain||"").includes(t)))}function a(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function h(t){return["html","body","#document"].includes(r(t))}const p=Math.min,g=Math.max,m=Math.round,y=Math.floor,w=t=>({x:t,y:t});function x(t){const e=o(t);let n=parseFloat(e.width)||0,i=parseFloat(e.height)||0;const r=c(t),l=r?t.offsetWidth:n,f=r?t.offsetHeight:i,s=m(n)!==l||m(i)!==f;return s&&(n=l,i=f),{width:n,height:i,$:s}}function b(t){return l(t)?t:t.contextElement}function v(t){const e=b(t);if(!c(e))return w(1);const n=e.getBoundingClientRect(),{width:o,height:i,$:r}=x(e);let l=(r?m(n.width):n.width)/o,f=(r?m(n.height):n.height)/i;return l&&Number.isFinite(l)||(l=1),f&&Number.isFinite(f)||(f=1),{x:l,y:f}}const T=w(0);function L(t,e,o){var i,r;if(void 0===e&&(e=!0),!a())return T;const c=t?n(t):window;return!o||e&&o!==c?T:{x:(null==(i=c.visualViewport)?void 0:i.offsetLeft)||0,y:(null==(r=c.visualViewport)?void 0:r.offsetTop)||0}}function O(t,o,i,r){void 0===o&&(o=!1),void 0===i&&(i=!1);const c=t.getBoundingClientRect(),f=b(t);let s=w(1);o&&(r?l(r)&&(s=v(r)):s=v(t));const u=L(f,i,r);let d=(c.left+u.x)/s.x,a=(c.top+u.y)/s.y,h=c.width/s.x,p=c.height/s.y;if(f){const t=n(f),e=r&&l(r)?n(r):r;let o=t.frameElement;for(;o&&r&&e!==t;){const t=v(o),e=o.getBoundingClientRect(),i=getComputedStyle(o),r=e.left+(o.clientLeft+parseFloat(i.paddingLeft))*t.x,c=e.top+(o.clientTop+parseFloat(i.paddingTop))*t.y;d*=t.x,a*=t.y,h*=t.x,p*=t.y,d+=r,a+=c,o=n(o).frameElement}}return e.rectToClientRect({width:h,height:p,x:d,y:a})}function R(t){return((i(t)?t.ownerDocument:t.document)||window.document).documentElement}function P(t){return l(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function C(t){return O(R(t)).left+P(t).scrollLeft}function S(t){if("html"===r(t))return t;const e=t.assignedSlot||t.parentNode||f(t)&&t.host||R(t);return f(e)?e.host:e}function E(t){const e=S(t);return h(e)?t.ownerDocument?t.ownerDocument.body:t.body:c(e)&&s(e)?e:E(e)}function F(t,e){var o;void 0===e&&(e=[]);const i=E(t),r=i===(null==(o=t.ownerDocument)?void 0:o.body),c=n(i);return r?e.concat(c,c.visualViewport||[],s(i)?i:[]):e.concat(i,F(i))}function j(t,i,r){let f;if("viewport"===i)f=function(t,e){const o=n(t),i=R(t),r=o.visualViewport;let c=i.clientWidth,l=i.clientHeight,f=0,s=0;if(r){c=r.width,l=r.height;const t=a();(!t||t&&"fixed"===e)&&(f=r.offsetLeft,s=r.offsetTop)}return{width:c,height:l,x:f,y:s}}(t,r);else if("document"===i)f=function(t){const e=R(t),n=P(t),i=t.ownerDocument.body,r=g(e.scrollWidth,e.clientWidth,i.scrollWidth,i.clientWidth),c=g(e.scrollHeight,e.clientHeight,i.scrollHeight,i.clientHeight);let l=-n.scrollLeft+C(t);const f=-n.scrollTop;return"rtl"===o(i).direction&&(l+=g(e.clientWidth,i.clientWidth)-r),{width:r,height:c,x:l,y:f}}(R(t));else if(l(i))f=function(t,e){const n=O(t,!0,"fixed"===e),o=n.top+t.clientTop,i=n.left+t.clientLeft,r=c(t)?v(t):w(1);return{width:t.clientWidth*r.x,height:t.clientHeight*r.y,x:i*r.x,y:o*r.y}}(i,r);else{const e=L(t);f={...i,x:i.x-e.x,y:i.y-e.y}}return e.rectToClientRect(f)}function D(t,e){const n=S(t);return!(n===e||!l(n)||h(n))&&("fixed"===o(n).position||D(n,e))}function W(t,e){return c(t)&&"fixed"!==o(t).position?e?e(t):t.offsetParent:null}function H(t,e){const i=n(t);if(!c(t))return i;let l=W(t,e);for(;l&&u(l)&&"static"===o(l).position;)l=W(l,e);return l&&("html"===r(l)||"body"===r(l)&&"static"===o(l).position&&!d(l))?i:l||function(t){let e=S(t);for(;c(e)&&!h(e);){if(d(e))return e;e=S(e)}return null}(t)||i}function M(t,e,n){const o=c(e),i=R(e),l="fixed"===n,f=O(t,!0,l,e);let u={scrollLeft:0,scrollTop:0};const d=w(0);if(o||!o&&!l)if(("body"!==r(e)||s(i))&&(u=P(e)),c(e)){const t=O(e,!0,l,e);d.x=t.x+e.clientLeft,d.y=t.y+e.clientTop}else i&&(d.x=C(i));return{x:f.left+u.scrollLeft-d.x,y:f.top+u.scrollTop-d.y,width:f.width,height:f.height}}const z={getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:i,strategy:c}=t;const f="clippingAncestors"===n?function(t,e){const n=e.get(t);if(n)return n;let i=F(t).filter((t=>l(t)&&"body"!==r(t))),c=null;const f="fixed"===o(t).position;let u=f?S(t):t;for(;l(u)&&!h(u);){const e=o(u),n=d(u);n||"fixed"!==e.position||(c=null),(f?!n&&!c:!n&&"static"===e.position&&c&&["absolute","fixed"].includes(c.position)||s(u)&&!n&&D(t,u))?i=i.filter((t=>t!==u)):c=e,u=S(u)}return e.set(t,i),i}(e,this._c):[].concat(n),u=[...f,i],a=u[0],m=u.reduce(((t,n)=>{const o=j(e,n,c);return t.top=g(o.top,t.top),t.right=p(o.right,t.right),t.bottom=p(o.bottom,t.bottom),t.left=g(o.left,t.left),t}),j(e,a,c));return{width:m.right-m.left,height:m.bottom-m.top,x:m.left,y:m.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:e,offsetParent:n,strategy:o}=t;const i=c(n),l=R(n);if(n===l)return e;let f={scrollLeft:0,scrollTop:0},u=w(1);const d=w(0);if((i||!i&&"fixed"!==o)&&(("body"!==r(n)||s(l))&&(f=P(n)),c(n))){const t=O(n);u=v(n),d.x=t.x+n.clientLeft,d.y=t.y+n.clientTop}return{width:e.width*u.x,height:e.height*u.y,x:e.x*u.x-f.scrollLeft*u.x+d.x,y:e.y*u.y-f.scrollTop*u.y+d.y}},isElement:l,getDimensions:function(t){return x(t)},getOffsetParent:H,getDocumentElement:R,getScale:v,async getElementRects(t){let{reference:e,floating:n,strategy:o}=t;const i=this.getOffsetParent||H,r=this.getDimensions;return{reference:M(e,await i(n),o),floating:{x:0,y:0,...await r(n)}}},getClientRects:t=>Array.from(t.getClientRects()),isRTL:t=>"rtl"===o(t).direction};Object.defineProperty(t,"arrow",{enumerable:!0,get:function(){return e.arrow}}),Object.defineProperty(t,"autoPlacement",{enumerable:!0,get:function(){return e.autoPlacement}}),Object.defineProperty(t,"detectOverflow",{enumerable:!0,get:function(){return e.detectOverflow}}),Object.defineProperty(t,"flip",{enumerable:!0,get:function(){return e.flip}}),Object.defineProperty(t,"hide",{enumerable:!0,get:function(){return e.hide}}),Object.defineProperty(t,"inline",{enumerable:!0,get:function(){return e.inline}}),Object.defineProperty(t,"limitShift",{enumerable:!0,get:function(){return e.limitShift}}),Object.defineProperty(t,"offset",{enumerable:!0,get:function(){return e.offset}}),Object.defineProperty(t,"shift",{enumerable:!0,get:function(){return e.shift}}),Object.defineProperty(t,"size",{enumerable:!0,get:function(){return e.size}}),t.autoUpdate=function(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:i=!0,ancestorResize:r=!0,elementResize:c=!0,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:f=!1}=o,s=b(t),u=i||r?[...s?F(s):[],...F(e)]:[];u.forEach((t=>{i&&t.addEventListener("scroll",n,{passive:!0}),r&&t.addEventListener("resize",n)}));const d=s&&l?function(t,e){let n,o=null;const i=R(t);function r(){clearTimeout(n),o&&o.disconnect(),o=null}return function c(l,f){void 0===l&&(l=!1),void 0===f&&(f=1),r();const{left:s,top:u,width:d,height:a}=t.getBoundingClientRect();if(l||e(),!d||!a)return;const h=y(u),m=y(i.clientWidth-(s+d)),w=y(i.clientHeight-(u+a)),x=y(s);let b=!0;o=new IntersectionObserver((t=>{const e=t[0].intersectionRatio;if(e!==f){if(!b)return c();e?c(!1,e):n=setTimeout((()=>{c(!1,1e-7)}),100)}b=!1}),{rootMargin:-h+"px "+-m+"px "+-w+"px "+-x+"px",threshold:g(0,p(1,f))||1}),o.observe(t)}(!0),r}(s,n):null;let a,h=null;c&&(h=new ResizeObserver(n),s&&!f&&h.observe(s),h.observe(e));let m=f?O(t):null;return f&&function e(){const o=O(t);!m||o.x===m.x&&o.y===m.y&&o.width===m.width&&o.height===m.height||n();m=o,a=requestAnimationFrame(e)}(),n(),()=>{u.forEach((t=>{i&&t.removeEventListener("scroll",n),r&&t.removeEventListener("resize",n)})),d&&d(),h&&h.disconnect(),h=null,f&&cancelAnimationFrame(a)}},t.computePosition=(t,n,o)=>{const i=new Map,r={platform:z,...o},c={...r.platform,_c:i};return e.computePosition(t,n,{...r,platform:c})},t.getOverflowAncestors=F,t.platform=z,Object.defineProperty(t,"__esModule",{value:!0})}));
{
"name": "@floating-ui/dom",
"version": "1.4.1",
"version": "1.4.2",
"@rollingversions": {

@@ -5,0 +5,0 @@ "baseVersion": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc