Documentation / @ripl/charts / resolveSegmentPadWidth
Function: resolveSegmentPadWidth() ​
resolveSegmentPadWidth(
padWidth?,padAngle?):number|undefined
Defined in: charts/src/core/options.ts:1024
Resolves the constant-width gap a radial chart separates its segments with, honoring a chart's deprecated angular padAngle option where one is still passed.
An explicit padWidth always wins (including 0, which means no gap). Otherwise a chart that was given only the deprecated padAngle resolves to undefined, leaving Arc.padAngle in charge, so migrating to padWidth is opt-in rather than a silent change of look for those charts.
Parameters ​
| Parameter | Type | Description |
|---|---|---|
padWidth? | number | The chart's padWidth option, in logical pixels. |
padAngle? | number | The chart's deprecated padAngle option, in radians. |
Returns ​
number | undefined
The gap to pass as Arc.padWidth, or undefined to fall back to padAngle.