main.css 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. :root {
  2. --color-blue: #049EF4;
  3. --text-color: #444;
  4. --border-style: 1px solid #EEE;
  5. --header-height: 48px;
  6. }
  7. @font-face {
  8. font-family: 'Roboto Mono';
  9. src: local('Roboto Mono'), url('../files/RobotoMono-Regular.woff2') format('woff2');
  10. font-weight: normal;
  11. font-style: normal;
  12. }
  13. * {
  14. box-sizing: border-box; /* don't let padding modify width */
  15. }
  16. html, body {
  17. height: 100%;
  18. }
  19. body {
  20. margin: 0px;
  21. overflow: hidden;
  22. font-family: 'Roboto Mono', monospace;
  23. font-size: 14px;
  24. line-height: 24px;
  25. background-color: #ffffff;
  26. color: var(--text-color);
  27. }
  28. a {
  29. text-decoration: none;
  30. }
  31. h1 {
  32. font-size: 18px;
  33. font-weight: 500;
  34. }
  35. h2 {
  36. padding: 8px 0;
  37. margin: 6px 0 12px 0;
  38. font-size: 14px;
  39. font-weight: normal;
  40. color: var(--color-blue);
  41. }
  42. h3 {
  43. margin: 4px 0;
  44. font-size: 14px;
  45. line-height: 23px;
  46. font-weight: 500;
  47. text-transform: uppercase;
  48. color: #9E9E9E;
  49. }
  50. h1 a {
  51. color: var(--color-blue);
  52. }
  53. #header {
  54. display: flex;
  55. height: 48px;
  56. border-bottom: var(--border-style);
  57. align-items: center;
  58. }
  59. #header h1 {
  60. margin-left: 15px;
  61. flex: 1;
  62. }
  63. #panel {
  64. position: fixed;
  65. left: 0px;
  66. width: 300px;
  67. height: 100%;
  68. overflow: auto;
  69. border-right: var(--border-style);
  70. display: flex;
  71. flex-direction: column;
  72. transition: 0s 0s height;
  73. }
  74. #panel #expandButton {
  75. margin-right: 14px;
  76. margin-left: 4px;
  77. display: none;
  78. }
  79. #panel #sections {
  80. font-weight: 500;
  81. display: flex;
  82. justify-content: center;
  83. z-index: 1000;
  84. position: relative;
  85. height: 100%;
  86. align-items: center;
  87. }
  88. #panel #sections * {
  89. padding: 0 16px;
  90. height: 100%;
  91. position: relative;
  92. display: flex;
  93. justify-content: center;
  94. align-items: center;
  95. }
  96. #panel #sections .selected:after {
  97. content: "";
  98. position: absolute;
  99. left: 0;
  100. right: 0;
  101. bottom: -1px;
  102. border-bottom: 1px solid black;
  103. }
  104. #panel #sections a {
  105. color: #9E9E9E;
  106. }
  107. #panel #filter {
  108. width: 100%;
  109. height: 48px;
  110. padding: 0px 44px;
  111. font-weight: 500;
  112. font-size: 14px;
  113. color: var(--text-color);
  114. outline: none;
  115. border: 0px;
  116. border-bottom: var(--border-style);
  117. background-size: 20px 20px;
  118. background-image: url(../files/ic_search_black_24dp.svg);
  119. background-position: 14px 50%;
  120. background-repeat: no-repeat;
  121. }
  122. #panel #language {
  123. font-family: 'Roboto Mono', monospace;
  124. position: absolute;
  125. top: 9px;
  126. right: 8px;
  127. border: 0px;
  128. font-size: 14px;
  129. font-weight: 500;
  130. background: url(ic_arrow_drop_down_black_24dp.svg) no-repeat;
  131. background-position: right center;
  132. background-color: white;
  133. padding: 4px 24px 4px 8px;
  134. -webkit-appearance: none;
  135. -moz-appearance: none;
  136. appearance: none;
  137. }
  138. #panel #language:focus {
  139. outline: none;
  140. }
  141. #contentWrapper {
  142. flex: 1;
  143. overflow: hidden;
  144. display: flex;
  145. flex-direction: column;
  146. transform: translate3d(0,0,0);
  147. }
  148. #panel #content {
  149. flex: 1;
  150. overflow: scroll;
  151. padding: 0 16px 24px 16px;
  152. }
  153. #panel #content ul {
  154. list-style-type: none;
  155. padding: 0px;
  156. margin: 0px 0 24px 0;
  157. }
  158. #panel #content ul li {
  159. margin: 2px 0;
  160. }
  161. #panel #content a {
  162. color: var(--text-color);
  163. }
  164. #panel #content a:hover,
  165. #panel #content .selected {
  166. color: var(--color-blue);
  167. }
  168. #panel #content .selected {
  169. text-decoration: underline;
  170. }
  171. #panel #content .hidden {
  172. display: none !important;
  173. }
  174. iframe {
  175. position: absolute;
  176. border: 0px;
  177. left: 300px;
  178. width: calc(100% - 300px);
  179. height: 100%;
  180. overflow: auto;
  181. }
  182. /* mobile */
  183. @media all and ( max-width: 640px ) {
  184. #panel #expandButton {
  185. display: block;
  186. }
  187. #panel {
  188. position: absolute;
  189. left: 0;
  190. top: 0;
  191. width: 100%;
  192. right: 0;
  193. z-index: 100;
  194. overflow-x: hidden;
  195. transition: 0s 0s height;
  196. border: none;
  197. height: var(--header-height);
  198. transition: 0s 0.2s height;
  199. }
  200. #panel.open {
  201. height: 100%;
  202. transition: 0s 0s height;
  203. }
  204. #panelScrim {
  205. pointer-events: none;
  206. background-color: rgba(0,0,0,0);
  207. position: absolute;
  208. left: 0;
  209. right: 0;
  210. top: 0;
  211. bottom: 0;
  212. z-index: 1000;
  213. pointer-events: none;
  214. transition: .2s background-color;
  215. }
  216. #panel.open #panelScrim {
  217. pointer-events: auto;
  218. background-color: rgba(0,0,0,0.4);
  219. }
  220. #contentWrapper {
  221. position: absolute;
  222. right: 0;
  223. top: 0;
  224. bottom: 0;
  225. background: white;
  226. box-shadow: 0 0 8px rgba(0,0,0,.1);
  227. width: calc(100vw - 60px);
  228. max-width: 360px;
  229. z-index: 10000;
  230. transition: .25s transform;
  231. overflow-x: hidden;
  232. margin-right: -380px;
  233. }
  234. #panel.open #contentWrapper {
  235. transform: translate3d(-380px, 0 ,0);
  236. }
  237. iframe {
  238. position: absolute;
  239. left: 0;
  240. top: var(--header-height);
  241. width: 100%;
  242. height: calc(100% - var(--header-height));
  243. }
  244. }
粤ICP备19079148号