| 1 |
// Defined as `div`. |
| 2 |
// Provide extra element for gadgets due to `form` already carrying an `id`. |
| 3 |
.vector-search-box-inner { |
| 4 |
position: relative; |
| 5 |
height: 100%; |
| 6 |
} |
| 7 |
|
| 8 |
// The search input. |
| 9 |
// Note that these rules only apply to the non-Vue enabled search input field. |
| 10 |
// When Vue.js has loaded this element will no longer be in the page and substituted with |
| 11 |
// a Codex element. |
| 12 |
.vector-search-box-input { |
| 13 |
background-color: rgba( 255, 255, 255, 0.5 ); |
| 14 |
color: @color-emphasized; |
| 15 |
width: 100%; |
| 16 |
// Reduce height slightly from standard to match legacy Vector tabs. |
| 17 |
height: unit( 28 / @font-size-browser / @font-size-search-input, em ); // Equals `2.15384615em`. |
| 18 |
box-sizing: border-box; |
| 19 |
border: @border-base; |
| 20 |
border-radius: @border-radius-base; |
| 21 |
// `padding-right` equals to `#searchbutton` width below. |
| 22 |
padding: 5px @width-search-button 5px 0.4em; |
| 23 |
box-shadow: @box-shadow-inset-small @box-shadow-color-transparent; |
| 24 |
// Match Codex. |
| 25 |
font-family: inherit; |
| 26 |
direction: ltr; |
| 27 |
transition-property: border-color, box-shadow; |
| 28 |
transition-duration: @transition-duration-medium; |
| 29 |
|
| 30 |
// Undo the proprietary styles, we provide our own. |
| 31 |
// Support: Safari/iOS `none` needed, Chrome would accept `textfield` as well. See T247299. |
| 32 |
-webkit-appearance: none; |
| 33 |
// Support: Firefox. |
| 34 |
-moz-appearance: textfield; |
| 35 |
|
| 36 |
.vector-search-box-inner:hover & { |
| 37 |
border-color: #72777d; |
| 38 |
} |
| 39 |
|
| 40 |
&:focus, |
| 41 |
.vector-search-box-inner:hover &:focus { |
| 42 |
outline: 0; |
| 43 |
border-color: @border-color-progressive--focus; |
| 44 |
box-shadow: @box-shadow-inset-small @box-shadow-color-progressive--focus; |
| 45 |
} |
| 46 |
|
| 47 |
.mixin-placeholder( { |
| 48 |
color: @color-placeholder; |
| 49 |
opacity: @opacity-base; |
| 50 |
} ); |
| 51 |
|
| 52 |
&::-webkit-search-decoration, |
| 53 |
&::-webkit-search-cancel-button, |
| 54 |
&::-webkit-search-results-button, |
| 55 |
&::-webkit-search-results-decoration { |
| 56 |
display: none; |
| 57 |
} |
| 58 |
} |
| 59 |
|
| 60 |
// The search buttons. Fallback and search button are displayed in the same position, |
| 61 |
// and if both are present the fulltext search one obscures the 'Go' one. |
| 62 |
.searchButton { |
| 63 |
background-color: transparent; |
| 64 |
position: absolute; |
| 65 |
top: @border-width-base; |
| 66 |
bottom: @border-width-base; |
| 67 |
// `@border-width-base * 2` is in regards to harmonize position start and end. |
| 68 |
right: @border-width-base; |
| 69 |
min-width: @min-width-search-button; |
| 70 |
width: @width-search-button; |
| 71 |
border: 0; |
| 72 |
padding: 0; |
| 73 |
cursor: pointer; |
| 74 |
// Equal `font-size` to search input for `padding` calculation. |
| 75 |
font-size: @font-size-search-input; |
| 76 |
/* Opera 12 on RTL flips the text in a funny way without this. */ |
| 77 |
/* @noflip */ |
| 78 |
direction: ltr; |
| 79 |
/* Hide button text and replace it with the image. */ |
| 80 |
text-indent: -99999px; |
| 81 |
white-space: nowrap; |
| 82 |
overflow: hidden; |
| 83 |
z-index: @z-index-search-button; |
| 84 |
} |
| 85 |
|
| 86 |
.searchButton[ name='go' ] { |
| 87 |
background: no-repeat center/unit( 16 / @font-size-browser / @font-size-search-input, em ) url( images/search.svg ); |
| 88 |
opacity: 0.67; |
| 89 |
} |
| 90 |
|
| 91 |
// Search portlet. |
| 92 |
.vector-search-box h3 { |
| 93 |
.mixin-screen-reader-text(); |
| 94 |
} |