mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-11-15 03:34:25 +00:00
1e7ed6b2e1
Per T270202#6767750 the input should expand when focused before WVUI loads. However, the input should *only* expand when `showThumbnail` is `true` in `$wgVectorWvuiSearchOptions` to match how its done in WVUI where it takes into account the size of the thumbnails. When `showThumbnail` is false, it should not expand as the input won't match WVUI and the WVUI load transition will be jarring. To test locally, toggle between true/false in your LocalSettings.php: ``` $wgVectorWvuiSearchOptions = [ "showThumbnail" => false, ]; ``` Bug: T270202 Change-Id: I70277c1082a504fbd5f6023e9873e8071de7e35d
25 lines
1.2 KiB
Plaintext
25 lines
1.2 KiB
Plaintext
{{!
|
|
See @typedef SearchData
|
|
}}
|
|
<div id="p-search" role="search" {{#should-search-expand}}class="p-search--show-thumbnail"{{/should-search-expand}}>
|
|
<h3 {{{html-user-language-attributes}}}>
|
|
<label for="searchInput">{{msg-search}}</label>
|
|
</h3>
|
|
<form action="{{form-action}}" id="searchform">
|
|
<div id="simpleSearch"{{#input-location}} data-search-loc="{{.}}"{{/input-location}}>
|
|
{{{html-input}}}
|
|
<input type="hidden" name="title" value="{{page-title}}"/>
|
|
{{! We construct two buttons (for 'go' and 'fulltext' search modes), but only one will be
|
|
visible and actionable at a time (they are overlaid on top of each other in CSS).
|
|
* Browsers will use the 'fulltext' one by default (as it's the first in tree-order),
|
|
which is desirable when they are unable to show search suggestions (either due to being
|
|
broken or having JavaScript turned off).
|
|
* The mediawiki.searchSuggest module, after doing tests for the broken browsers, removes
|
|
the 'fulltext' button and handles 'fulltext' search itself; this will reveal the 'go'
|
|
button and cause it to be used. !}}
|
|
{{{html-button-search-fallback}}}
|
|
{{{html-button-search}}}
|
|
</div>
|
|
</form>
|
|
</div>
|