mirror of
https://github.com/gorhill/uBlock.git
synced 2024-11-07 03:12:33 +01:00
Use type="search"
for search input fields
Related issue: - https://github.com/uBlockOrigin/uBlock-issues/issues/768 So that the input fields can gain extra built-in browser widgets useful in search fields.
This commit is contained in:
parent
3dc0686ba5
commit
da253bf80c
@ -122,21 +122,16 @@ body[dir="rtl"] #pageSelector {
|
||||
opacity: 1;
|
||||
}
|
||||
#netInspector #filterInput {
|
||||
border: 1px solid gray;
|
||||
display: inline-flex;
|
||||
}
|
||||
#netInspector #filterInput > input {
|
||||
min-width: 18em;
|
||||
border: 0;
|
||||
min-width: 16em;
|
||||
}
|
||||
#netInspector #filterExprButton {
|
||||
position: absolute;
|
||||
transform: scaleY(-1);
|
||||
}
|
||||
body[dir="ltr"] #netInspector #filterExprButton {
|
||||
right: 0;
|
||||
}
|
||||
body[dir="rtl"] #netInspector #filterExprButton {
|
||||
left: 0;
|
||||
}
|
||||
#netInspector #filterExprButton:hover {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
@ -32,7 +32,7 @@
|
||||
<button type="button" class="custom iconifiable" id="importButton"><span class="fa"></span><span data-i18n="rulesImport"></span></button>
|
||||
<button type="button" class="custom iconifiable important disabled" id="editSaveButton"><span class="fa"></span><span data-i18n="rulesEditSave"></span></button>
|
||||
</div>
|
||||
<div id="ruleFilter"><span class="fa"></span> <input type="text" size="20"></div>
|
||||
<div id="ruleFilter"><span class="fa"></span> <input type="search" size="20"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -96,11 +96,11 @@
|
||||
}
|
||||
|
||||
function queryTextFromSearchWidget(cm) {
|
||||
return getSearchState(cm).widget.querySelector('input[type="text"]').value;
|
||||
return getSearchState(cm).widget.querySelector('input[type="search"]').value;
|
||||
}
|
||||
|
||||
function queryTextToSearchWidget(cm, q) {
|
||||
var input = getSearchState(cm).widget.querySelector('input[type="text"]');
|
||||
var input = getSearchState(cm).widget.querySelector('input[type="search"]');
|
||||
if ( typeof q === 'string' && q !== input.value ) {
|
||||
input.value = q;
|
||||
}
|
||||
@ -310,7 +310,7 @@
|
||||
'<div class="cm-search-widget">' +
|
||||
'<span class="fa-icon fa-icon-ro">search</span> ' +
|
||||
'<span class="cm-search-widget-input">' +
|
||||
'<input type="text">' +
|
||||
'<input type="search">' +
|
||||
'<span class="cm-search-widget-count">' +
|
||||
'<span><!-- future use --></span><span>0</span>' +
|
||||
'</span>' +
|
||||
|
@ -54,7 +54,7 @@
|
||||
<span id="filterExprGroup">
|
||||
<span id="filterButton" class="button fa-icon" data-i18n-title="loggerRowFiltererButtonTip">filter</span>
|
||||
<span id="filterInput">
|
||||
<input type="text" placeholder="logFilterPrompt">
|
||||
<input type="search" placeholder="logFilterPrompt">
|
||||
<span id="filterExprButton" class="button fa-icon expanded" data-i18n-title="loggerRowFiltererBuiltinTip">angle-up</span>
|
||||
<div id="filterExprPicker">
|
||||
<div><span data-filtex="!" data-i18n="loggerRowFiltererBuiltinNot"></span><span data-filtex="\t--\t|\t<<\t|\t##" data-i18n="loggerRowFiltererBuiltinBlocked"></span><span data-filtex="\t\+\+\t|\t\*\*\t|\t#@#" data-i18n="loggerRowFiltererBuiltinAllowed"></span></div>
|
||||
|
Loading…
Reference in New Issue
Block a user