From 8af16939fd737a929fac4044fb6915778a87960f Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Fri, 16 Dec 2016 17:22:52 -0800 Subject: [PATCH] mediawiki.searchSuggest: Remove inline browser compat check Introduced in 1f987fb5eea4. This is quite dated and obsolete since then. The current code in the 'mediawiki.searchSuggest' and 'jquery.suggestions' works fine in all currently supported Grade A browsers (per startup.js). Change-Id: I6d281459e230fa6a2971a31314f9e963dc83ff2b --- resources/Resources.php | 1 - .../src/mediawiki/mediawiki.searchSuggest.js | 19 +------------------ 2 files changed, 1 insertion(+), 19 deletions(-) diff --git a/resources/Resources.php b/resources/Resources.php index d490414c8b..2cb1b864d8 100644 --- a/resources/Resources.php +++ b/resources/Resources.php @@ -1174,7 +1174,6 @@ return [ 'searchsuggest-containing', ], 'dependencies' => [ - 'jquery.client', 'jquery.placeholder', 'jquery.suggestions', 'jquery.getAttrs', diff --git a/resources/src/mediawiki/mediawiki.searchSuggest.js b/resources/src/mediawiki/mediawiki.searchSuggest.js index fa1a78c5cb..ac03911db4 100644 --- a/resources/src/mediawiki/mediawiki.searchSuggest.js +++ b/resources/src/mediawiki/mediawiki.searchSuggest.js @@ -22,7 +22,7 @@ }; $( function () { - var api, map, searchboxesSelectors, + var api, searchboxesSelectors, // Region where the suggestions box will appear directly below // (using the same width). Can be a container element or the input // itself, depending on what suits best in the environment. @@ -34,23 +34,6 @@ $searchInput = $( '#searchInput' ), previousSearchText = $searchInput.val(); - // Compatibility map - map = { - // SimpleSearch is broken in Opera < 9.6 - opera: [ [ '>=', 9.6 ] ], - // Older Konquerors are unable to position the suggestions correctly (bug 50805) - konqueror: [ [ '>=', '4.11' ] ], - docomo: false, - blackberry: false, - // Support for iOS 6 or higher. It has not been tested on iOS 5 or lower - ipod: [ [ '>=', 6 ] ], - iphone: [ [ '>=', 6 ] ] - }; - - if ( !$.client.test( map ) ) { - return; - } - // Compute form data for search suggestions functionality. function getFormData( context ) { var $form, baseHref, linkParams; -- 2.20.1