MCPcopy
hub / github.com/graphif/project-graph / getDropLocation

Function getDropLocation

app/src/DropWindowCover.tsx:34–35  ·  view source on GitHub ↗
(y: number)

Source from the content-addressed store, hash-verified

32 const size = await getCurrentWindow().outerSize();
33 const logicalHeight = isMac ? size.height / (await getCurrentWindow().scaleFactor()) : size.height;
34 const getDropLocation = (y: number) =>
35 y <= logicalHeight / 3 ? "top" : y <= (logicalHeight / 3) * 2 ? "middle" : "bottom";
36
37 if (event.payload.type === "over") {
38 cancelAnimation();

Callers 1

DropWindowCoverFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected