Skip to content

Plots: ensure hover tooltips do not clip near the plot boundaries #910

Description

@jacobvjk

CONTEXT

When approaching the chart boundaries in the MultiLineChart, the tooltip should reposition to avoid clipping (for all plot types and in all relevant views)

Image Image

A/Cs

  • Hovering a point near the MultiLineChart's left/right edge shifts the tooltip
    box horizontally so it never renders past the plot area bounds
  • Hovering a point near the MultiLineChart's's top/bottom edge shifts the tooltip
    box vertically (flips above/below the point) so it never renders
    past the plot area bounds
  • Horizontal and vertical repositioning apply independently, so a point
    near a corner gets both adjustments at once
  • The tooltip's pointer/tail always points at the exact hovered data
    point (no snapping to an axis) — unlike the stacked-area chart, this
    chart's anchor is a point, not the x-axis
  • No visual change for points that already have enough space on
    all sides

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions