diff options
Diffstat (limited to 'resources/src/jquery/jquery.accessKeyLabel.js')
-rw-r--r-- | resources/src/jquery/jquery.accessKeyLabel.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/resources/src/jquery/jquery.accessKeyLabel.js b/resources/src/jquery/jquery.accessKeyLabel.js index 867c25e7..92f8eb9c 100644 --- a/resources/src/jquery/jquery.accessKeyLabel.js +++ b/resources/src/jquery/jquery.accessKeyLabel.js @@ -112,7 +112,7 @@ function getAccessKeyLabel( element ) { */ function updateTooltipOnElement( element, titleElement ) { var array = ( mw.msg( 'word-separator' ) + mw.msg( 'brackets' ) ).split( '$1' ), - regexp = new RegExp( $.map( array, $.escapeRE ).join( '.*?' ) + '$' ), + regexp = new RegExp( $.map( array, mw.RegExp.escape ).join( '.*?' ) + '$' ), oldTitle = titleElement.title, rawTitle = oldTitle.replace( regexp, '' ), newTitle = rawTitle, @@ -150,14 +150,14 @@ function updateTooltip( element ) { if ( id ) { $label = $( 'label[for="' + id + '"]' ); if ( $label.length === 1 ) { - updateTooltipOnElement( element, $label[0] ); + updateTooltipOnElement( element, $label[ 0 ] ); } } // Search it as parent, because the form control can also be inside the label element itself $labelParent = $element.parents( 'label' ); if ( $labelParent.length === 1 ) { - updateTooltipOnElement( element, $labelParent[0] ); + updateTooltipOnElement( element, $labelParent[ 0 ] ); } } } |