blockedIntervalsForBand()
Collect obstacle intervals that intersect a horizontal band.
Import
Section titled “Import”import { blockedIntervalsForBand } from "@graphrefly/ts/solutions/reactive-layout";Signature
Section titled “Signature”function blockedIntervalsForBand( obstacles: readonly Obstacle[], bandTop: number, bandBottom: number,): Interval[]Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
obstacles | readonly Obstacle[] | Obstacles to test. |
bandTop | number | Top edge of the band. |
bandBottom | number | Bottom edge of the band. |
Returns
Section titled “Returns”Sorted blocked intervals inside the band.
Example
Section titled “Example”blockedIntervalsForBand([], 0, 20);Source
Section titled “Source”packages/ts/src/solutions/reactive-layout/flow.ts