|
Last change
on this file since ba17441 was a762898, checked in by istevanoska <ilinastevanoska@…>, 5 months ago |
|
Added visualizations
|
-
Property mode
set to
100644
|
|
File size:
727 bytes
|
| Line | |
|---|
| 1 | "use strict";
|
|---|
| 2 |
|
|---|
| 3 | Object.defineProperty(exports, "__esModule", {
|
|---|
| 4 | value: true
|
|---|
| 5 | });
|
|---|
| 6 | exports.getRadialCursorPoints = getRadialCursorPoints;
|
|---|
| 7 | var _PolarUtils = require("../PolarUtils");
|
|---|
| 8 | /**
|
|---|
| 9 | * Only applicable for radial layouts
|
|---|
| 10 | * @param {Object} activeCoordinate ChartCoordinate
|
|---|
| 11 | * @returns {Object} RadialCursorPoints
|
|---|
| 12 | */
|
|---|
| 13 | function getRadialCursorPoints(activeCoordinate) {
|
|---|
| 14 | var {
|
|---|
| 15 | cx,
|
|---|
| 16 | cy,
|
|---|
| 17 | radius,
|
|---|
| 18 | startAngle,
|
|---|
| 19 | endAngle
|
|---|
| 20 | } = activeCoordinate;
|
|---|
| 21 | var startPoint = (0, _PolarUtils.polarToCartesian)(cx, cy, radius, startAngle);
|
|---|
| 22 | var endPoint = (0, _PolarUtils.polarToCartesian)(cx, cy, radius, endAngle);
|
|---|
| 23 | return {
|
|---|
| 24 | points: [startPoint, endPoint],
|
|---|
| 25 | cx,
|
|---|
| 26 | cy,
|
|---|
| 27 | radius,
|
|---|
| 28 | startAngle,
|
|---|
| 29 | endAngle
|
|---|
| 30 | };
|
|---|
| 31 | } |
|---|
Note:
See
TracBrowser
for help on using the repository browser.