_search.scss 4.5 KB

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