API Reference
carveTextLineSlots()
Subtract obstacle intervals from a horizontal text band.
Import
import { carveTextLineSlots } from "@graphrefly/ts/solutions/reactive-layout";
Signature
function carveTextLineSlots(
base: Interval,
blocked: readonly Interval[],
minSlotWidth = 0,
): Interval[]
Parameters
| Parameter | Type | Description |
|---|---|---|
base | Interval | base value used by the helper. |
blocked | readonly Interval[] | blocked value used by the helper. |
minSlotWidth | unknown | min slot width value used by the helper. |
Returns
A Interval[] value.
Example
import { carveTextLineSlots } from "@graphrefly/ts/solutions/reactive-layout";
Source
packages/ts/src/solutions/reactive-layout/line.ts