diff options
author | Michał Gołębiowski-Owczarek <m.goleb@gmail.com> | 2024-10-27 00:04:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-27 00:04:00 +0200 |
commit | af8adca5481d0ac5db0865032b6c4c7e21421be7 (patch) | |
tree | 6219d2b51ca29f3dc6899959e81da0ba00c19005 /tests/unit/tabs/helper.js | |
parent | ebdcd0d866a5d318c5255c2d6404867878d06d47 (diff) | |
download | jquery-ui-af8adca5481d0ac5db0865032b6c4c7e21421be7.tar.gz jquery-ui-af8adca5481d0ac5db0865032b6c4c7e21421be7.zip |
Tabs: Use `CSS.escape` for sanitizing selectors
The previous private `_sanitizeSelector` API was not correctly escaping
backslashes and is now removed. The native API should always be correct.
Closes gh-2307
Diffstat (limited to 'tests/unit/tabs/helper.js')
-rw-r--r-- | tests/unit/tabs/helper.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/unit/tabs/helper.js b/tests/unit/tabs/helper.js index b3fb1d6fd..4043d86d8 100644 --- a/tests/unit/tabs/helper.js +++ b/tests/unit/tabs/helper.js @@ -58,8 +58,7 @@ return $.extend( helper, { var expected = $.makeArray( arguments ).slice( 2 ), actual = tabs.find( ".ui-tabs-nav li" ).map( function() { var tab = $( this ), - panel = $( $.ui.tabs.prototype._sanitizeSelector( - "#" + tab.attr( "aria-controls" ) ) ), + panel = $( "#" + CSS.escape( tab.attr( "aria-controls" ) ) ), tabIsActive = tab.hasClass( "ui-state-active" ), panelIsActive = panel.css( "display" ) !== "none"; |