_search.scss 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312
  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. height: $navbarHeight;
  23. display: flex;
  24. background-color: $navbarBackground;
  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. .search-item__body-title {
  166. color: $text-color-strong;
  167. }
  168. }
  169. }
  170. .search-item__body {
  171. flex: 1 1 auto;
  172. overflow: hidden;
  173. display: flex;
  174. flex-direction: column;
  175. justify-content: center;
  176. padding: 0 10px;
  177. }
  178. .search-item__body-title {
  179. color: $list-item-link-color;
  180. }
  181. .search-item__body-folder-title {
  182. color: $text-color-weak;
  183. font-size: $font-size-xs;
  184. line-height: 11px;
  185. position: relative;
  186. top: -1px;
  187. }
  188. .search-item__icon {
  189. display: flex;
  190. align-items: center;
  191. flex: 0 0 auto;
  192. font-size: 19px;
  193. padding: 0 2px 0 10px;
  194. }
  195. .search-item__tags {
  196. display: none;
  197. padding: 10px;
  198. }
  199. .search-item__actions {
  200. flex: 0 0 auto;
  201. padding: 0 10px 0 0;
  202. }
  203. .search-item__actions__item {
  204. display: inline-block;
  205. opacity: 0;
  206. width: 0;
  207. transition: all 0.2s ease-in-out;
  208. .fa-star,
  209. .fa-star-o {
  210. color: $orange;
  211. line-height: 37px;
  212. }
  213. }
  214. .search-item:hover {
  215. .search-item__actions__item {
  216. width: 15px;
  217. opacity: 1;
  218. }
  219. }
  220. .search-button-row {
  221. text-align: center;
  222. padding: $spacer*2 $spacer;
  223. background: $panel-bg;
  224. }
  225. @include media-breakpoint-up(sm) {
  226. .search-container {
  227. left: $side-menu-width;
  228. }
  229. .search-item__tags {
  230. display: block;
  231. }
  232. .search-dropdown__col_2 {
  233. display: flex;
  234. margin-bottom: 1rem;
  235. }
  236. }
  237. @include media-breakpoint-up(md) {
  238. .search-dropdown__col_2 {
  239. flex-direction: row;
  240. justify-content: space-between;
  241. max-width: 700px;
  242. height: 260px;
  243. align-items: flex-start;
  244. }
  245. .search-dropdown__col_1 {
  246. height: 100%;
  247. }
  248. .search-filter-box {
  249. margin: 0;
  250. }
  251. }
  252. @include media-breakpoint-up(lg) {
  253. .search-dropdown {
  254. flex-direction: row;
  255. }
  256. .search-dropdown__col_2 {
  257. flex-direction: column;
  258. }
  259. .search-filter-box {
  260. margin-left: $spacer * 1.5;
  261. margin-bottom: $spacer * 1.5;
  262. }
  263. }