(source)
| 71 | } |
| 72 | |
| 73 | function computeCircularBoundary(source) { |
| 74 | const {scale, fill} = source; |
| 75 | const options = scale.options; |
| 76 | const length = scale.getLabels().length; |
| 77 | const start = options.reverse ? scale.max : scale.min; |
| 78 | const value = _getTargetValue(fill, scale, start); |
| 79 | const target = []; |
| 80 | |
| 81 | if (options.grid.circular) { |
| 82 | const center = scale.getPointPositionForValue(0, start); |
| 83 | return new simpleArc({ |
| 84 | x: center.x, |
| 85 | y: center.y, |
| 86 | radius: scale.getDistanceFromCenterForValue(value) |
| 87 | }); |
| 88 | } |
| 89 | |
| 90 | for (let i = 0; i < length; ++i) { |
| 91 | target.push(scale.getPointPositionForValue(i, value)); |
| 92 | } |
| 93 | return target; |
| 94 | } |
| 95 |
no test coverage detected