MCPcopy Create free account
hub / github.com/angular/components / isInsideClientRect

Function isInsideClientRect

src/cdk/drag-drop/dom/dom-rect.ts:35–38  ·  view source on GitHub ↗
(clientRect: DOMRect, x: number, y: number)

Source from the content-addressed store, hash-verified

33 * @param y Coordinates along the Y axis.
34 */
35export function isInsideClientRect(clientRect: DOMRect, x: number, y: number) {
36 const {top, bottom, left, right} = clientRect;
37 return y >= top && y <= bottom && x >= left && x <= right;
38}
39
40/**
41 * Checks if the child element is overflowing from its parent.

Callers 4

_isOverContainerMethod · 0.90
_canReceiveMethod · 0.90
sortMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected