[JENKINS-71148] avoid empty tooltips#8975
Conversation
when the tooltip or html tooltip is empty or whitespace only it is avoided that the tippy is invoked at all which would otherwise just display a small but empty element.
| tooltip != null && | ||
| tooltip.length > 0 && | ||
| (htmlTooltip == null || htmlTooltip.length == 0) |
There was a problem hiding this comment.
Are you doing null checks deliberately not with === etc? (Curiosity more than request for change)
daniel-beck
left a comment
There was a problem hiding this comment.
Seems to work well, thanks 👍
NotMyFault
left a comment
There was a problem hiding this comment.
/label ready-for-merge
This PR is now ready for merge. We will merge it after ~24 hours if there is no negative feedback.
Please see the merge process documentation for more information about the merge process.
Thanks!
IMO not a regression. The tooltip that #8972 addresses has been empty since it was added in 2.220, with the problem existing probably far longer. If you disagree, what release introduced the regression? |
|
I think it is a regression introduced with #6408 when YUI tooltips were replaced by tippy |
|
That was merged in 2.380. Note the screenshot in my issue that I took in 2.220 (and that's just when that tooltip was added). So at least that specific instance is far older. |
* [JENKINS71148] avoid empty tooltips when the tooltip or html tooltip is empty or whitespace only it is avoided that the tippy is invoked at all which would otherwise just display a small but empty element. * better null checks (cherry picked from commit 0675943)
when the tooltip or html tooltip attribute is empty or whitespace only it is avoided that tippy is invoked at all which would otherwise just display a small but empty element.
Before:

After:

See JENKINS-71148.
Solves also JENKINS-72743 but in a generic way that also avoids empty tooltips in other places.
see also #8972
Testing done
Proposed changelog entries
Proposed upgrade guidelines
N/A
Desired reviewers
@mention
Before the changes are marked as
ready-for-merge: