Bartosz Dziewoński has uploaded a new change for review. https://gerrit.wikimedia.org/r/133186
Change subject: mediawiki.searchSuggest: Adjust font size for all inputs, not just magic ones ...................................................................... mediawiki.searchSuggest: Adjust font size for all inputs, not just magic ones I have no idea why the fix was limited, this issue affects every single input on every single page (including ones that are part of MediaWiki interface itself, not skins, see If4ae687b). Change-Id: I7a6dfbcced64dbfce5d1ab31201c98a134f72fe9 --- M resources/src/mediawiki/mediawiki.searchSuggest.js 1 file changed, 11 insertions(+), 9 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/86/133186/1 diff --git a/resources/src/mediawiki/mediawiki.searchSuggest.js b/resources/src/mediawiki/mediawiki.searchSuggest.js index ea7c0c5..cbdf666 100644 --- a/resources/src/mediawiki/mediawiki.searchSuggest.js +++ b/resources/src/mediawiki/mediawiki.searchSuggest.js @@ -115,6 +115,7 @@ '#powerSearchText', '#searchText', // Generic selector for skins with multiple searchboxes (used by CologneBlue) + // and for MediaWiki itself (special pages with page title inputs) '.mw-searchInput' ]; $( searchboxesSelectors.join( ', ' ) ) @@ -156,6 +157,16 @@ // make sure paste and cut events from the mouse and drag&drop events // trigger the keypress handler and cause the suggestions to update $( this ).trigger( 'keypress' ); + } ) + // In most skins (at least Monobook and Vector), the font-size is messed up in <body>. + // (they use 2 elements to get a sane font-height). So, instead of making exceptions for + // each skin or adding more stylesheets, just copy it from the active element so auto-fit. + .each( function () { + var $this = $( this ); + $this + .data( 'suggestions-context' ) + .data.$container + .css( 'fontSize', $this.css( 'fontSize' ) ); } ); // Ensure that the thing is actually present! @@ -181,15 +192,6 @@ // If the form includes any fallback fulltext search buttons, remove them $searchInput.closest( 'form' ).find( '.mw-fallbackSearchButton' ).remove(); - - // In most skins (at least Monobook and Vector), the font-size is messed up in <body>. - // (they use 2 elements to get a sane font-height). So, instead of making exceptions for - // each skin or adding more stylesheets, just copy it from the active element so auto-fit. - $searchInput - .data( 'suggestions-context' ) - .data.$container - .css( 'fontSize', $searchInput.css( 'fontSize' ) ); - } ); }( mediaWiki, jQuery ) ); -- To view, visit https://gerrit.wikimedia.org/r/133186 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7a6dfbcced64dbfce5d1ab31201c98a134f72fe9 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Bartosz Dziewoński <matma....@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits