{"version":3,"names":["getMidpoint","element","rect","getBoundingClientRect","x","left","right","y","top","bottom"],"sources":["get-midpoint.ts"],"sourcesContent":["/**\n * 2D coordinate in CSS pixels. Matches the shape used by floating-ui's\n * `Coords` — duplicated here so `slider-utils` has no hidden dependency on\n * floating-ui types.\n */\nexport interface Coords {\n\tx: number;\n\ty: number;\n}\n\n/**\n * Returns the midpoint of `element`'s client rect. Used by the slider thumb\n * collision logic to compute per-thumb hit centers.\n */\nexport function getMidpoint(element: HTMLElement): Coords {\n\tconst rect = element.getBoundingClientRect();\n\treturn {\n\t\tx: (rect.left + rect.right) / 2,\n\t\ty: (rect.top + rect.bottom) / 2,\n\t};\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;;AAMA;AACA;AACA;AACA;AACA,OAAO,SAASA,WAAWA,CAACC,OAAoB,EAAU;EACzD,MAAMC,IAAI,GAAGD,OAAO,CAACE,qBAAqB,CAAC,CAAC;EAC5C,OAAO;IACNC,CAAC,EAAE,CAACF,IAAI,CAACG,IAAI,GAAGH,IAAI,CAACI,KAAK,IAAI,CAAC;IAC/BC,CAAC,EAAE,CAACL,IAAI,CAACM,GAAG,GAAGN,IAAI,CAACO,MAAM,IAAI;EAC/B,CAAC;AACF","ignoreList":[]}