* Helper to get the alignment of a tooltip given the size
(chart, options, size)
| 267 | * Helper to get the alignment of a tooltip given the size |
| 268 | */ |
| 269 | function determineAlignment(chart, options, size) { |
| 270 | const yAlign = size.yAlign || options.yAlign || determineYAlign(chart, size); |
| 271 | |
| 272 | return { |
| 273 | xAlign: size.xAlign || options.xAlign || determineXAlign(chart, options, size, yAlign), |
| 274 | yAlign |
| 275 | }; |
| 276 | } |
| 277 | |
| 278 | function alignX(size, xAlign) { |
| 279 | let {x, width} = size; |
no test coverage detected