mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-11-27 17:10:19 +00:00
b2705c55f1
- Update SearchBox.mustache markup to use codex styles - Scope old SearchBox markup to LegacySearchBox.mustache - Add handling for thumbnail and autoexpand search variants - Adds a 'Search' button to SearchBox.mustache matching the initial non vue search box with the Codex design - Refactor SearchBox CSS so styles are scoped better Visual changes: A "Search" button now appears on page load when it previously only appeared after loading in Vue Bug: T337966 Change-Id: Ibcffe00292ab4f9f5f9919982d578793cf8594de
33 lines
1.6 KiB
Plaintext
33 lines
1.6 KiB
Plaintext
{{!
|
|
See @typedef SearchData
|
|
}}
|
|
<div{{#is-primary}} id="p-search"{{/is-primary}} role="search" class="{{class}} vector-search-box">
|
|
<h3 {{{html-user-language-attributes}}}>{{msg-search}}</h3>
|
|
<form action="{{form-action}}" id="{{form-id}}" class="vector-search-box-form">
|
|
<div {{#is-primary}}id="simpleSearch"{{/is-primary}}
|
|
class="vector-search-box-inner"
|
|
{{#input-location}} data-search-loc="{{.}}"{{/input-location}}>
|
|
<input class="vector-search-box-input"
|
|
{{#is-primary}}{{{html-input-attributes}}} id="searchInput"{{/is-primary}}
|
|
{{^is-primary}}
|
|
type="search" name="search"
|
|
placeholder="{{msg-searchsuggest-search}}"
|
|
{{/is-primary}}
|
|
>
|
|
<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. !}}
|
|
<input{{#is-primary}} id="mw-searchButton"{{/is-primary}}
|
|
{{{html-button-fulltext-attributes}}} value="{{msg-searchbutton}}">
|
|
<input{{#is-primary}} id="searchButton"{{/is-primary}}
|
|
{{{html-button-go-attributes}}} value="{{msg-searcharticle}}">
|
|
</div>
|
|
</form>
|
|
</div>
|