_search.scss 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. .search-backdrop {
  2. position: fixed;
  3. right: 0;
  4. left: 0;
  5. bottom: 0;
  6. top: $navbarHeight;
  7. z-index: $zindex-modal-backdrop;
  8. background-color: $black;
  9. @include opacity(75);
  10. }
  11. .search-container {
  12. left: 0;
  13. top: 0;
  14. right: 0;
  15. bottom: 0;
  16. z-index: ($zindex-modal-backdrop + 10);
  17. position: fixed;
  18. }
  19. // Search
  20. .search-field-wrapper {
  21. width: 100%;
  22. display: flex;
  23. background-color: $navbarBackground;
  24. box-shadow: $navbarShadow;
  25. position: relative;
  26. & > input {
  27. max-width: 653px;
  28. //padding: 0.5rem 1.5rem 0.5rem 0;
  29. padding: 1rem 1rem 0.75rem 1rem;
  30. height: 51px;
  31. box-sizing: border-box;
  32. outline: none;
  33. background: $side-menu-bg;
  34. background-color: $navbarButtonBackground;
  35. flex-grow: 10;
  36. }
  37. }
  38. .search-field-spacer {
  39. flex-grow: 1;
  40. }
  41. .search-field-icon {
  42. font-size: $font-size-lg;
  43. padding: 1rem 1rem 0.75rem 1.5rem;
  44. }
  45. .search-dropdown {
  46. display: flex;
  47. flex-direction: column;
  48. height: calc(100% - #{$navbarHeight});
  49. }
  50. .search-dropdown__col_1 {
  51. background: $page-bg;
  52. max-width: 700px;
  53. display: flex;
  54. flex-direction: column;
  55. flex-grow: 1;
  56. .search-item--indent {
  57. margin-left: 14px;
  58. }
  59. }
  60. .search-dropdown__col_2 {
  61. flex-grow: 1;
  62. height: 100%;
  63. padding-top: 16px;
  64. display: none;
  65. flex-direction: column;
  66. }
  67. .search-filter-box {
  68. background: $search-filter-box-bg;
  69. border-radius: 2px;
  70. padding: $spacer*1.5;
  71. min-width: 340px;
  72. margin-bottom: $spacer * 1.5;
  73. }
  74. .search-filter-box__header {
  75. border-bottom: 1px solid $dark-5;
  76. margin-bottom: $spacer * 1.5;
  77. }
  78. .search-filter-box-link {
  79. display: block;
  80. margin-bottom: 16px;
  81. &:last-child {
  82. margin-bottom: 0;
  83. }
  84. i,
  85. img {
  86. font-size: 20px;
  87. margin-right: 5px;
  88. }
  89. }
  90. .search-results-scroller {
  91. display: flex;
  92. position: relative;
  93. }
  94. .search-results-container {
  95. display: block;
  96. padding: $spacer;
  97. position: relative;
  98. flex-grow: 10;
  99. margin-bottom: 1rem;
  100. // Fix for search scroller in mobile view
  101. height: unset;
  102. .label-tag {
  103. margin-left: 6px;
  104. font-size: 11px;
  105. padding: 2px 6px;
  106. }
  107. .selected {
  108. .search-result-tag {
  109. opacity: 0.7;
  110. color: white;
  111. }
  112. }
  113. }
  114. .search-section {
  115. background: $panel-bg;
  116. border: $panel-border;
  117. padding: 0px 4px 4px 4px;
  118. margin-bottom: 3px;
  119. border-radius: 5px;
  120. }
  121. .search-section__header {
  122. font-size: $font-size-h6;
  123. padding: 7px 4px 3px 0;
  124. color: $text-color-weak;
  125. display: flex;
  126. flex-grow: 1;
  127. &:hover,
  128. &.selected {
  129. color: $text-color;
  130. }
  131. &:hover {
  132. .search-section__header__link {
  133. opacity: 1;
  134. }
  135. }
  136. }
  137. .search-section__header__icon {
  138. padding: 5px 0px;
  139. width: 43px;
  140. text-align: center;
  141. }
  142. .search-section__header__toggle {
  143. padding: 5px;
  144. }
  145. .search-section__header__text {
  146. flex-grow: 1;
  147. line-height: 24px;
  148. }
  149. .search-section__header__link {
  150. padding: 2px 10px 0;
  151. color: $text-muted;
  152. opacity: 0;
  153. transition: opacity 150ms ease-in-out;
  154. }
  155. .search-item {
  156. @include list-item();
  157. display: flex;
  158. flex-grow: 1;
  159. height: 37px;
  160. white-space: nowrap;
  161. padding: 0px;
  162. &:hover,
  163. &.selected {
  164. background: $list-item-hover-bg;
  165. }
  166. }
  167. .search-item__body {
  168. flex: 1 1 auto;
  169. overflow: hidden;
  170. display: flex;
  171. flex-direction: column;
  172. justify-content: center;
  173. padding: 0 10px;
  174. }
  175. .search-item__body-title {
  176. color: $list-item-link-color;
  177. }
  178. .search-item__icon {
  179. padding: 5px;
  180. flex: 0 0 auto;
  181. font-size: 19px;
  182. padding: 5px 2px 5px 10px;
  183. }
  184. .search-item__tags {
  185. display: none;
  186. padding: 10px;
  187. }
  188. .search-item__actions {
  189. flex: 0 0 auto;
  190. padding: 0 10px 0 0;
  191. }
  192. .search-item__actions__item {
  193. display: inline-block;
  194. opacity: 0;
  195. width: 0;
  196. transition: all 0.2s ease-in-out;
  197. .fa-star,
  198. .fa-star-o {
  199. color: $orange;
  200. line-height: 37px;
  201. }
  202. }
  203. .search-item:hover {
  204. .search-item__actions__item {
  205. width: 15px;
  206. opacity: 1;
  207. }
  208. }
  209. .search-button-row {
  210. text-align: center;
  211. padding: $spacer*2 $spacer;
  212. background: $panel-bg;
  213. }
  214. @include media-breakpoint-up(sm) {
  215. .search-container {
  216. left: $side-menu-width;
  217. }
  218. .search-item__tags {
  219. display: block;
  220. }
  221. .search-dropdown__col_2 {
  222. display: flex;
  223. margin-bottom: 1rem;
  224. }
  225. }
  226. @include media-breakpoint-up(md) {
  227. .search-dropdown__col_2 {
  228. flex-direction: row;
  229. justify-content: space-between;
  230. max-width: 700px;
  231. height: 260px;
  232. align-items: flex-start;
  233. }
  234. .search-dropdown__col_1 {
  235. height: 100%;
  236. }
  237. .search-filter-box {
  238. margin: 0;
  239. }
  240. }
  241. @include media-breakpoint-up(lg) {
  242. .search-dropdown {
  243. flex-direction: row;
  244. }
  245. .search-dropdown__col_2 {
  246. flex-direction: column;
  247. }
  248. .search-filter-box {
  249. margin-left: $spacer * 1.5;
  250. margin-bottom: $spacer * 1.5;
  251. }
  252. }