Function
setCurrentAxis
(options: MarkStagerOptions, stage: Stage, groupType: GroupType)
Source from the content-addressed store, hash-verified
| 89 | }; |
| 90 | |
| 91 | function setCurrentAxis(options: MarkStagerOptions, stage: Stage, groupType: GroupType) { |
| 92 | let axes: Axis[]; |
| 93 | let role: AxisRole; |
| 94 | switch (groupType) { |
| 95 | case GroupType.xAxis: |
| 96 | axes = stage.axes.x; |
| 97 | role = 'x'; |
| 98 | break; |
| 99 | case GroupType.yAxis: |
| 100 | axes = stage.axes.y; |
| 101 | role = 'y'; |
| 102 | break; |
| 103 | case GroupType.zAxis: |
| 104 | axes = stage.axes.z; |
| 105 | role = 'z'; |
| 106 | break; |
| 107 | default: |
| 108 | return; |
| 109 | } |
| 110 | options.currAxis = { |
| 111 | domain: null, |
| 112 | tickText: [], |
| 113 | ticks: [], |
| 114 | role, |
| 115 | }; |
| 116 | axes.push(options.currAxis); |
| 117 | } |
| 118 | |
| 119 | const markStagers: { [id: string]: MarkStager } = { |
| 120 | group, |
Tested by
no test coverage detected