-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
jQuery-UI 1.13.0 tooltip bug #1990
Comments
Can you confirm whether this was working in the previous version (1.12.1)? |
Yes, the example works with 1.12.1 but not with 1.13.0 |
Thanks!
Can you post that error here? |
The error that appear in the javascript console is:
|
Thanks, this is the code location causing this error: jquery-ui/ui/widgets/tooltip.js Lines 351 to 357 in 70dae67
However, that @josepsanzcamp Could you verify whether the issue also affects jQuery UI 1.13.0 with other major versions of jQuery, e.g. 1.9.1 or 2.2.4? |
Hi @caugner. I have tested that jquery 1.9.1, jquery 1.12.4 and jquery 2.2.4 works correctly with jquery-ui 1.12.1 but fails with jquery-ui 1.13.0. Josep. |
Hi @caugner. I have detected that the problem is in the widget.js. I recovered the try catch found inside the loop of the $.cleanData and seems that works. Original code in the 1.13.0:
And the merged code using the try catch found in the 1.12.1 and the latest 1.13.0:
Does it help you??? |
@josepsanzcamp Thanks for the report. Nice find! The issue, as I see, is that the Would you like to submit a PR with a fix? |
Hi @mgol I did a PR to recover the old try..catch, it's ok??? Thanks. Josep. |
Commit 1f2011e removed a `try-catch` around triggering the `remove` handlers in the `jQuery.cleanData` override. The `try-catch` was meant for old IE but it was also catching an error coming from the tooltip `remove` handler depending on being able to find a relevant tooltip. The `_find` method returns `null`, though, when the tooltip cotent is empty. Instead of restoring the `try-catch`, handle the `null` case in the `remove` handler. Fixes gh-1990 Closes gh-1994 Co-authored-by: Claas Augner <[email protected]> Co-authored-by: Michał Gołębiowski-Owczarek <[email protected]>
jQuery UI 1.13.1 including a fix for this issue has been released: https://blog.jqueryui.com/2022/01/jquery-ui-1-13-1-released/. |
Hi team.
I have found an issue in the latest release (1.13.0) when my self content function of the tooltip plugin returns an empty string, the problem not appears at the same moment but appear when you try to do something in other widgets of the user interface.
As an example, I have write the proof of concept that creates a datepicker after programs the tooltip plugin, if you use the previous month button, all works fine but when you move the mouse to the next month button, the problem appear and when you try to do a click in the button, a javascript error appear.
Thanks in advance.
Josep.
The text was updated successfully, but these errors were encountered: