sidebar.css 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315
  1. .sidebar-section {
  2. order: 1;
  3. flex: 20%;
  4. max-width: 20%;
  5. /* background-color: lightsalmon; */
  6. transition: all ease-out 0.5s;
  7. -webkit-transition: all ease-out 0.5s;
  8. }
  9. .sidebar-holder {
  10. top: 2.5rem;
  11. position: sticky;
  12. background-color: #f9fafc;
  13. height: 100vh;
  14. overflow: auto;
  15. box-shadow: 0px 8px 56px rgba(15, 80, 100, 0.16);
  16. transition: all ease-out 0.3s;
  17. -webkit-transition: all ease-out 0.3s;
  18. }
  19. .sidebar {
  20. background: #f9fafc;
  21. height: 100vh;
  22. transition: all ease-out 0.3s;
  23. -webkit-transition: all ease-out 0.3s;
  24. }
  25. .sidebar-tree {
  26. padding-left: 1rem;
  27. position: relative;
  28. width: max-content;
  29. }
  30. #search-box {
  31. margin-left: 5%;
  32. margin-right: 5%;
  33. width: -webkit-fill-available;
  34. height: 35px;
  35. padding-left: 15px;
  36. margin-top: 30px;
  37. margin-bottom: 10px;
  38. border-radius: 5px;
  39. background-color: #e5e9f2;
  40. transition: all 0.3s ease-out;
  41. -webkit-transition: all 0.3s ease-out;
  42. border: 1px solid #c0ccda;
  43. }
  44. #search-box:focus {
  45. border: 1pt solid #248aaa;
  46. outline: none;
  47. }
  48. #list-heading {
  49. padding-left: 0px !important;
  50. }
  51. .tree,
  52. ul {
  53. margin: 0;
  54. padding: 0;
  55. list-style: none;
  56. }
  57. .tree li {
  58. margin: 0;
  59. padding: 0 1em;
  60. line-height: 2em;
  61. color: #3c4858;
  62. position: relative;
  63. }
  64. .tree li a {
  65. text-decoration: none;
  66. color: #131313;
  67. transition: all 0.3s ease-out;
  68. -webkit-transition: all 0.3s ease-out;
  69. }
  70. .tree li a.active {
  71. display: inline;
  72. color: #2098d1;
  73. }
  74. .tree li a:hover {
  75. margin-left: 3px;
  76. color: #2098d1;
  77. transition: all 0.3s ease-out;
  78. -webkit-transition: all 0.3s ease-out;
  79. }
  80. .tree i {
  81. color: #3c4858;
  82. font-size: 12px;
  83. margin-right: 5px;
  84. }
  85. .tree .shift-right {
  86. margin-left: 5px;
  87. }
  88. .tree .active,
  89. .tree .active > ul {
  90. display: block;
  91. }
  92. .subtree {
  93. padding-left: 0.7rem;
  94. }
  95. .subtree:before {
  96. content: "";
  97. display: block;
  98. width: 0;
  99. position: absolute;
  100. top: 2.5rem;
  101. left: 1.5rem;
  102. bottom: 0.9rem;
  103. border-left: 1px solid;
  104. }
  105. .subtree ul,
  106. ul > ul {
  107. position: relative;
  108. padding-left: 0.5rem;
  109. display: none;
  110. }
  111. .subtree ul:before {
  112. content: "";
  113. display: block;
  114. width: 0;
  115. position: absolute;
  116. top: -10px;
  117. left: 0.3rem;
  118. bottom: 0.9rem;
  119. border-left: 1px solid;
  120. }
  121. .subtree li:before {
  122. content: "";
  123. display: block;
  124. width: 20px;
  125. height: 0;
  126. border-top: 1px solid;
  127. margin-top: -1px;
  128. position: absolute;
  129. top: 18px;
  130. left: -3px;
  131. }
  132. .subtree li:last-child:before {
  133. background: #f9fafc;
  134. height: auto;
  135. top: 1.1rem;
  136. bottom: 0;
  137. }
  138. a.focused {
  139. color: #2098d1 !important;
  140. }
  141. /* ============= Device specific fixes ======= */
  142. /* Large screens such as TV */
  143. @media only screen and (min-width: 1824px) {
  144. .sidebar-section {
  145. flex: 15%;
  146. max-width: 15%;
  147. }
  148. .sidebar-holder {
  149. max-width: 100%;
  150. }
  151. }
  152. /* Extra large devices (large desktops, 1200px and up) */
  153. @media (max-width: 1400px) {
  154. .sidebar-holder {
  155. max-width: 20rem;
  156. }
  157. }
  158. @media (max-width: 1200px) {
  159. .sidebar-tree {
  160. margin-left: 1rem;
  161. }
  162. }
  163. /* IPad Pro */
  164. @media (max-width: 1024px) {
  165. .sidebar-section {
  166. flex: 0%;
  167. max-width: 0%;
  168. min-height: 100vh;
  169. transition: all ease-out 0.3s;
  170. -webkit-transition: all ease-out 0.3s;
  171. }
  172. .sidebar-holder {
  173. position: sticky;
  174. top: 2.5rem;
  175. width: 100%;
  176. }
  177. .sidebar-section.hide {
  178. flex: 30%;
  179. max-width: 30%;
  180. margin-right: 0.5rem;
  181. transition: all ease-out 0.3s;
  182. -webkit-transition: all ease-out 0.3s;
  183. }
  184. }
  185. /* Large devices (desktops, 992px and up) */
  186. @media (max-width: 992px) {
  187. }
  188. /* Medium devices (tablets, 768px and up) */
  189. @media only screen and (max-width: 768px) {
  190. .sidebar-section {
  191. flex: 0%;
  192. max-width: 0%;
  193. min-height: 100vh;
  194. transition: all ease-out 0.3s;
  195. -webkit-transition: all ease-out 0.3s;
  196. }
  197. .sidebar-holder {
  198. position: sticky;
  199. top: 2.5rem;
  200. width: 100%;
  201. }
  202. .sidebar-section.hide {
  203. flex: 40%;
  204. max-width: 40%;
  205. margin-right: 0.5rem;
  206. transition: all ease-out 0.3s;
  207. -webkit-transition: all ease-out 0.3s;
  208. }
  209. }
  210. /* Small devices (landscape phones, 576px and up) */
  211. @media only screen and (max-width: 576px) {
  212. .sidebar-section {
  213. width: 100%;
  214. min-height: 0;
  215. max-height: 0;
  216. max-width: 100%;
  217. transition: all ease-out 0.5s;
  218. -webkit-transition: all ease-out 0.5s;
  219. }
  220. .sidebar-section.hide {
  221. margin-top: 2rem;
  222. position: relative;
  223. height: fit-content;
  224. flex: none;
  225. max-height: 300vh;
  226. max-width: 100%;
  227. transition: all ease-out 0.5s;
  228. -webkit-transition: all ease-out 0.5s;
  229. }
  230. .sidebar-holder {
  231. max-height: 0;
  232. height: fit-content;
  233. overflow: hidden;
  234. max-width: 100%;
  235. transition: all ease-out 0.5s;
  236. -webkit-transition: all ease-out 0.5s;
  237. }
  238. .sidebar-section.hide .sidebar-holder {
  239. max-height: 200vh;
  240. transition: all ease-out 0.5s;
  241. -webkit-transition: all ease-out 0.5s;
  242. }
  243. .sidebar {
  244. position: relative;
  245. height: fit-content;
  246. max-height: fit-content;
  247. width: 100vw;
  248. min-height: 0;
  249. overflow: hidden;
  250. transition: all ease-out 0.5s;
  251. -webkit-transition: all ease-out 0.5s;
  252. }
  253. .sidebar-tree {
  254. margin-left: 0rem;
  255. max-height: 0;
  256. transition: all 0.5s ease-out;
  257. -webkit-transition: all 0.5s ease-out;
  258. }
  259. .sidebar-section.hide .sidebar-tree {
  260. max-height: 200vh;
  261. transition: all 0.5s ease-out;
  262. -webkit-transition: all 0.5s ease-out;
  263. }
  264. }
  265. /* iPhoneX, iPhone 6,7,8 */
  266. @media only screen and (max-width: 375px) {
  267. }
  268. /* Galaxy S5, Moto G4 */
  269. @media only screen and (max-width: 360px) {
  270. }
  271. /* iPhone 5 or before */
  272. @media only screen and (max-width: 320px) {
  273. }