_wiki.scss 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246
  1. div.body {
  2. padding: 10px;
  3. }
  4. .wiki {
  5. line-height: 1.8em;
  6. font-size: 15px;
  7. h1, h2, h3, h4, h5, h6 {
  8. margin-top: 1.6em;
  9. margin-bottom: .8em;
  10. &:first-child {
  11. margin-top: 0;
  12. }
  13. }
  14. h1 {
  15. margin-top: 2em;
  16. padding-bottom: 0.3em;
  17. font-size: 1.8em;
  18. line-height: 1.1em;
  19. border-bottom: solid 1px transparent;
  20. }
  21. h2 {
  22. padding-bottom: 0.5em;
  23. font-size: 1.4em;
  24. line-height: 1.225;
  25. font-weight: bold;
  26. border-bottom: 1px solid transparent;
  27. }
  28. h3 {
  29. font-size: 1.2em;
  30. font-weight: bold;
  31. }
  32. h4 {
  33. font-size: 1.1em;
  34. font-weight: normal;
  35. }
  36. h5 {
  37. font-size: 1.05em;
  38. font-weight: normal;
  39. }
  40. p {
  41. font-weight: normal;
  42. margin: 15px 0;
  43. }
  44. blockquote {
  45. font-size: .9em;
  46. margin: 0 0 30px 0;
  47. padding: 0 20px;
  48. color: lighten($gray-dark, 35%);
  49. }
  50. img {
  51. margin: 5px 0;
  52. max-width: 100%;
  53. }
  54. img.emojione {
  55. margin-top: -0.3em !important;
  56. margin-bottom: 0 !important;
  57. border: none;
  58. box-shadow: none;
  59. }
  60. ul, ol {
  61. padding-left: 30px;
  62. margin: 20px 0;
  63. li {
  64. margin: 5px 0;
  65. line-height: 1.8em;
  66. }
  67. ul, ol {
  68. margin: 0;
  69. }
  70. }
  71. .task-list {
  72. .task-list-item {
  73. list-style-type: none;
  74. margin: 0 0.2em 0.25em -1.6em;
  75. }
  76. .task-list-item > .task-list {
  77. margin-left: 30px;
  78. }
  79. // use awesome-bootstrap-checkbox
  80. .task-list-item .checkbox input[type="checkbox"] {
  81. // layout
  82. +label {
  83. padding-left: 0.3em;
  84. &:before {
  85. margin-top: 0.4em;
  86. }
  87. }
  88. // styles
  89. cursor: default;
  90. +label {
  91. cursor: default;
  92. opacity: 1;
  93. &:before, &:after {
  94. cursor: default;
  95. }
  96. }
  97. }
  98. }
  99. pre.hljs {
  100. position: relative;
  101. cite {
  102. position: absolute;
  103. top: 0;
  104. right: 0;
  105. padding: 0 4px;
  106. background: #ccc;
  107. color: #333;
  108. font-style: normal;
  109. font-weight: bold;
  110. opacity: 0.6;
  111. }
  112. }
  113. // styles for highlightjs-line-numbers
  114. .hljs-ln td.hljs-ln-numbers {
  115. user-select: none;
  116. text-align: center;
  117. color: #ccc;
  118. border-right: 1px solid #CCC;
  119. vertical-align: top;
  120. padding-right: 5px;
  121. }
  122. .hljs-ln td.hljs-ln-code {
  123. padding-left: 10px;
  124. }
  125. p code { // only inline code blocks
  126. font-family: $font-family-monospace-not-strictly;
  127. }
  128. .page-template-builder {
  129. position: relative;
  130. .template-create-button {
  131. position: absolute;
  132. top: 8px;
  133. right: 8px;
  134. }
  135. }
  136. .highlighted {
  137. background-color: $brand-warning;
  138. }
  139. .revision-head {
  140. a {
  141. text-decoration: none;
  142. }
  143. .revision-head-link,
  144. .revision-head-edit-button {
  145. margin-left: 0.5em;
  146. font-size: 0.6em;
  147. opacity: 0;
  148. }
  149. &:hover .revision-head-link,
  150. &:hover .revision-head-edit-button {
  151. opacity: 1 !important;
  152. }
  153. }
  154. $ratio: 0.95;
  155. &.comment {
  156. line-height: 1.5em;
  157. font-size: 14px;
  158. h1, h2, h3, h4, h5, h6 {
  159. margin-top: 1.6em * $ratio;
  160. margin-bottom: .8em * $ratio;
  161. &:first-child {
  162. margin-top: 15px;
  163. }
  164. }
  165. h1 {
  166. margin-top: 2em * $ratio;
  167. padding-bottom: 0.3em * $ratio;
  168. font-size: 1.8em * $ratio;
  169. line-height: 1.1em * $ratio;
  170. }
  171. h2 {
  172. padding-bottom: 0.5em * $ratio;
  173. font-size: 1.4em * $ratio;
  174. line-height: 1.225 * $ratio;
  175. }
  176. h3 {
  177. font-size: 1.2em * $ratio;
  178. }
  179. blockquote {
  180. font-size: .9em * $ratio;
  181. }
  182. img.emojione {
  183. margin-top: -0.3em * $ratio !important;
  184. }
  185. ul, ol {
  186. padding-left: 15px;
  187. margin: 10px 0;
  188. li {
  189. line-height: 1.1em;
  190. }
  191. }
  192. .revision-head {
  193. .revision-head-link,
  194. .revision-head-edit-button {
  195. margin-left: 0.5em * $ratio;
  196. font-size: 0.6em * $ratio;
  197. }
  198. }
  199. }
  200. }
  201. // mobile
  202. .page-mobile .wiki .revision-head {
  203. .revision-head-link,
  204. .revision-head-edit-button {
  205. opacity: 0.3;
  206. }
  207. }
  208. @media (max-width: $screen-sm-max) { // {{{ tablet and iphone size
  209. .main-container .main .wiki {
  210. img {
  211. max-width: 100%;
  212. }
  213. }
  214. }