_wiki.scss 4.0 KB

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