_search.scss 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. // import react-bootstrap-typeahead
  2. @import "~react-bootstrap-typeahead/css/Typeahead";
  3. @import "./page_list";
  4. .search-listpage-icon {
  5. font-size: 16px;
  6. color: #999;
  7. }
  8. .search-listpage-clear {
  9. z-index: 3;
  10. display: none;
  11. position: absolute;
  12. right: 8px;
  13. z-index: 10;
  14. font-size: 0.6em;
  15. width: 22px;
  16. height: 22px;
  17. color: #ccc;
  18. padding: 8px;
  19. }
  20. .search-input-group {
  21. display: inline-block;
  22. margin-left: 20px;
  23. margin-bottom: 0;
  24. width: 200px;
  25. vertical-align: bottom;
  26. }
  27. .search-top {
  28. .search-top-input-group {
  29. .search-top-clear {
  30. position: absolute;
  31. right: 40px;
  32. z-index: 10;
  33. width: 22px;
  34. height: 22px;
  35. top: 7px;
  36. color: #ccc;
  37. padding: 0;
  38. }
  39. }
  40. // using react-bootstrap-typeahead
  41. // see: https://github.com/ericgio/react-bootstrap-typeahead
  42. .rbt-menu {
  43. li a span {
  44. .picture {
  45. width: 14px;
  46. height: 14px;
  47. }
  48. .page-path {
  49. display: inline;
  50. padding: 0 4px;
  51. color: inherit;
  52. }
  53. .page-list-meta {
  54. font-size: .9em;
  55. color: #999;
  56. >span {
  57. margin-right: .3rem;
  58. }
  59. }
  60. }
  61. }
  62. // hide loading icon
  63. .rbt-aux {
  64. display: none;
  65. }
  66. }
  67. .search-result {
  68. .search-result-list {
  69. nav {
  70. &.affix {
  71. top: 8px;
  72. width: 32%;
  73. padding-right: 0;
  74. padding-bottom: 50px;
  75. height: 100%;
  76. overflow-y: scroll;
  77. }
  78. .nav {
  79. > li {
  80. padding: 0px 10px 0 0;
  81. &.active {
  82. padding-right: 7px;
  83. border-right: solid 3px #666;
  84. background: #f0f0f0;
  85. }
  86. }
  87. }
  88. }
  89. .search-result-meta {
  90. margin-bottom: 16px;
  91. font-weight: bold;
  92. }
  93. .search-result-list-delete-checkbox {
  94. margin: 0 10px 0 0;
  95. vertical-align: middle;
  96. }
  97. }
  98. .search-result-content {
  99. padding-bottom: 32px;
  100. .search-result-page {
  101. > h2 {
  102. font-size: 20px;
  103. }
  104. &:first-child > h2 {
  105. margin-top: 0;
  106. }
  107. .wiki {
  108. border: solid 1px #ccc;
  109. padding: 16px;
  110. border-radius: 3px;
  111. font-size: 13px;
  112. }
  113. }
  114. }
  115. }
  116. // Smartphone and Tablet
  117. @media (max-width: $screen-xs-max) {
  118. .search-top {
  119. margin-top: 4px 0 0 0;
  120. padding: 0;
  121. border-style: none !important;
  122. box-shadow: none !important;
  123. -webkit-box-shadow: none !important;
  124. }
  125. .search-result {
  126. .search-result-content {
  127. .search-result-page {
  128. .wiki {
  129. h1, h2, h3, h4, h5, h6 {
  130. font-size: medium;
  131. }
  132. height: 250px;
  133. overflow: scroll;
  134. }
  135. }
  136. }
  137. }
  138. }
  139. .search-top .search-form {
  140. @media (min-width: $screen-sm-max) {
  141. // using react-bootstrap-typeahead
  142. // see: https://github.com/ericgio/react-bootstrap-typeahead
  143. .rbt-input input {
  144. width: 500px !important;
  145. }
  146. }
  147. @media (min-width: $screen-sm-min) and (max-width: $screen-sm-max) {
  148. background-color: #0f0;
  149. // using react-bootstrap-typeahead
  150. // see: https://github.com/ericgio/react-bootstrap-typeahead
  151. .rbt-input input {
  152. width: 270px !important;
  153. }
  154. }
  155. @media (min-width: $screen-xs-min) and (max-width: $screen-xs-max) {
  156. width: 70%;
  157. }
  158. @media (min-width: $screen-xs-min*2/3) and (max-width: $screen-xs-min) {
  159. width: 58%;
  160. }
  161. @media (max-width: $screen-xs-min*2/3) {
  162. width: 40%;
  163. min-width: 120px;
  164. }
  165. }