_search.scss 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. // import react-bootstrap-typeahead
  2. @import "~react-bootstrap-typeahead/css/Typeahead";
  3. .search-listpage-icon {
  4. font-size: 16px;
  5. color: #999;
  6. }
  7. .search-listpage-clear {
  8. display: none;
  9. position: absolute;
  10. right: 8px;
  11. font-size: 0.6em;
  12. width: 22px;
  13. height: 22px;
  14. color: #ccc;
  15. padding: 8px;
  16. }
  17. .search-top, .search-sidebar {
  18. .search-input-group {
  19. .search-top-clear {
  20. position: absolute;
  21. z-index: 2;
  22. right: 28px;
  23. width: 24px;
  24. height: 24px;
  25. top: 3px;
  26. color: #999;
  27. padding: 0;
  28. }
  29. }
  30. .input-group-btn {
  31. position: absolute;
  32. top: 0;
  33. right: 0;
  34. .btn {
  35. padding: 4px 10px;
  36. }
  37. }
  38. // using react-bootstrap-typeahead
  39. // see: https://github.com/ericgio/react-bootstrap-typeahead
  40. .rbt-input.form-control {
  41. background-color: rgba(255, 255, 255, 0.9);
  42. border-radius: 40px;
  43. border-top-right-radius: 40px;
  44. border-bottom-right-radius: 40px;
  45. padding-top: 4px;
  46. height: 30px;
  47. .rbt-input-wrapper {
  48. margin-left: 8px;
  49. }
  50. }
  51. .rbt-menu {
  52. li a span {
  53. .page-path {
  54. display: inline;
  55. padding: 0 4px;
  56. color: inherit;
  57. }
  58. .page-list-meta {
  59. font-size: .9em;
  60. color: #999;
  61. >span {
  62. margin-right: .3rem;
  63. }
  64. }
  65. }
  66. }
  67. }
  68. // layout
  69. .search-top {
  70. margin-top: 10px;
  71. margin-bottom: 10px;
  72. .rbt-input.form-control {
  73. width: 180px;
  74. transition: 0.3s ease-out;
  75. // focus
  76. &.focus {
  77. width: 300px;
  78. }
  79. }
  80. }
  81. .search-sidebar {
  82. .search-form, .form-group, .rbt-input.form-control, .input-group {
  83. width: 100%;
  84. }
  85. .input-group-btn {
  86. right: 30px;
  87. }
  88. }
  89. .search-result {
  90. .search-result-list {
  91. nav {
  92. &.affix {
  93. top: 8px;
  94. width: 32%;
  95. padding-right: 0;
  96. padding-bottom: 50px;
  97. height: 100%;
  98. overflow-y: scroll;
  99. }
  100. .nav {
  101. > li {
  102. padding: 0px 10px 0 0;
  103. &.active {
  104. padding-right: 7px;
  105. border-right: solid 3px #666;
  106. background: #f0f0f0;
  107. }
  108. }
  109. }
  110. }
  111. .search-result-meta {
  112. margin-bottom: 16px;
  113. font-weight: bold;
  114. }
  115. .search-result-list-delete-checkbox {
  116. margin: 0 10px 0 0;
  117. vertical-align: middle;
  118. }
  119. }
  120. .search-result-content {
  121. padding-bottom: 32px;
  122. .search-result-page {
  123. > h2 {
  124. font-size: 20px;
  125. }
  126. &:first-child > h2 {
  127. margin-top: 0;
  128. }
  129. .wiki {
  130. border: solid 1px #ccc;
  131. padding: 16px;
  132. border-radius: 3px;
  133. font-size: 13px;
  134. }
  135. }
  136. }
  137. }