-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvement/bartooltip item with text span children #554
Improvement/bartooltip item with text span children #554
Conversation
information on a bar chart tooltip item
8d98eec
to
3e3d11d
Compare
/// content of the tooltip, is a [text] String with a [textStyle]. | ||
BarTooltipItem(String text, TextStyle textStyle) | ||
BarTooltipItem(String text, TextStyle textStyle, [List<InlineSpan> children]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you put List around [ ] ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i figured this is the easiest way to do it without breaking any compatibility. could have also done named. i have no preference
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so you can still call BarTooltipItem('something', TextStyle(fontSize: 12))
with no issue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay please change it to named parameter.
Also, it will be great if you do the same in LineTooltipItem
, and ScatterTooltipItem
.
Also please update one of our samples and use |
And the last step is updating the documents. Thanks! |
…oltip-item-with-text-span-children
15c9364
to
3d18dd0
Compare
Hi. I think you forgot to update the docs. |
opening again for null-safety merge |
redo of #544
This is a hold over for #72 in that you are able to better customize the text on the tooltip. I tried to change the code as little as possible by making the List field optional.