imaNNeo / imaNNeo/fl_chart

Above/Below graph positioning of tooltips

Open
#890 1 comment 0 reactions 0 assignees View on GitHub
enhancement good first issue Line Chart
Dominant language
Dart
Stars
7.6k
Forks
2k
Avg merge
9d 1h
Merged PRs (30d)
2

Description

** Don't make a duplicate issue.
Didn't see any other request for this

**Is your feature request related to a problem? Please describe.**
Currently labels often cover the line graph making it hard to see.

**Describe the solution you'd like**
I'd like to be able to, on a per-tooltip basis, specify whether the tooltip should be shown *above* or *below* the line graph.

**Describe alternatives you've considered**
I've tried messing around with the padding/margin but that doesn't give me enough control and is not specified per-tooltip. I also considered using `showOnTopOfTheChartBoxArea` but in this particular case, where I want a tooltip for the max and min value, it is much more clear what the label means if the `min` tooltip is on bottom.

**Additional context**
See attached image.
![Screenshot_20220202-160400](https://user-images.githubusercontent.com/2635181/152252950-92c91339-5a75-4622-a676-37fbaad46682.png)

**Suggestion**
Perhaps a counterpart to `ShowOnTopOfTheChartBoxArea` and also making those values settable on a per-tooltip basis would be a good approach.

Contributor guide

Open the contributing guide

Research direction

Start by locating the line-chart tooltip implementation and the existing `showOnTopOfTheChartBoxArea` option. Trace how tooltip settings are applied, then determine how a per-tooltip above/below setting would fit the current API. Done means max and min tooltips can be positioned independently without relying on global padding or margins, with coverage in the relevant chart tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart
Domain
data-visualization
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.