_wiki.scss 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285
  1. div.body {
  2. padding: 10px;
  3. }
  4. .revision-toc {
  5. float: right;
  6. font-size: .9em;
  7. border: solid 1px #aaa;
  8. border-radius: 5px;
  9. max-width: 250px;
  10. overflow: hidden;
  11. .revision-toc-head {
  12. display: inline-block;
  13. float: right;
  14. border-left: solid 1px #aaa;
  15. border-bottom: solid 1px #aaa;
  16. border-radius: 0 5px;
  17. padding: 3px 11px;
  18. font-weight: bold;
  19. background: #f0f0f0;
  20. margin-left: 5px;
  21. margin-bottom: 5px;
  22. &.collapsed {
  23. border: none;
  24. margin: 0;
  25. }
  26. }
  27. .revision-toc-content {
  28. background: #fcfcfc;
  29. padding: 10px;
  30. > ul {
  31. margin: 4px 4px 4px 15px;
  32. padding: 5px;
  33. }
  34. }
  35. }
  36. .revision-head {
  37. .revision-head-link {
  38. display: none;
  39. font-size: 0.6em;
  40. padding-top: 4px;
  41. padding-left: 10px;
  42. }
  43. &:hover .revision-head-link {
  44. display: inline-block;
  45. }
  46. }
  47. .wiki {
  48. line-height: 1.8em;
  49. font-size: 15px;
  50. h1, h2, h3, h4, h5, h6 {
  51. margin-top: 1.6em;
  52. margin-bottom: .8em;
  53. &:first-child {
  54. margin-top: 0;
  55. }
  56. }
  57. h1 {
  58. margin-top: 2em;
  59. padding-bottom: 0.3em;
  60. font-size: 1.8em;
  61. border-bottom: solid 1px #ccc;
  62. }
  63. h2 {
  64. padding-bottom: 0.5em;
  65. font-size: 1.4em;
  66. line-height: 1.225;
  67. font-weight: bold;
  68. border-bottom: 1px solid #eee;
  69. }
  70. h3 {
  71. font-size: 1.2em;
  72. font-weight: bold;
  73. }
  74. h4 {
  75. font-size: 1.1em;
  76. font-weight: normal;
  77. }
  78. h5 {
  79. font-size: 1.05em;
  80. font-weight: normal;
  81. }
  82. p {
  83. font-weight: normal;
  84. margin: 15px 0;
  85. }
  86. blockquote {
  87. font-size: .9em;
  88. margin: 0 0 30px 0;
  89. padding: 0 20px;
  90. color: darken(gray, 10%);
  91. }
  92. a {
  93. text-decoration: underline;
  94. color: #38ad9e;
  95. &:hover {
  96. text-decoration: none;
  97. color: darken(#38ad9e, 10%);
  98. }
  99. }
  100. /* ensure to disable in crowi-plus system
  101. pre {
  102. line-height: 1.4em;
  103. font-size: .9em;
  104. border: none;
  105. background: #444;
  106. color: #f0f0f0;
  107. font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
  108. word-wrap: break-word;
  109. }
  110. */
  111. pre {
  112. border: none;
  113. }
  114. img {
  115. margin: 5px 0;
  116. box-shadow: 0 0 5px 0px rgba(0,0,0,.2);
  117. border: solid 1px #ccc;
  118. max-width: 100%;
  119. }
  120. .noborder img, .img.noborder {
  121. box-shadow: none;
  122. border: none;
  123. }
  124. img.emoji {
  125. width: 0.95em;
  126. margin: 1px;
  127. border: none;
  128. box-shadow: none;
  129. vertical-align: middle;
  130. display: inline;
  131. }
  132. ul, ol {
  133. padding-left: 30px;
  134. margin: 20px 0;
  135. li {
  136. margin: 5px 0;
  137. line-height: 1.8em;
  138. }
  139. ul, ol {
  140. margin: 0;
  141. }
  142. }
  143. /* ensure to disable in crowi-plus
  144. .wiki-code {
  145. position: relative;
  146. cite {
  147. position: absolute;
  148. top: 0;
  149. right: 0;
  150. padding: 0 4px;
  151. background: #ccc;
  152. color: #333;
  153. font-size: .8em;
  154. }
  155. };
  156. */
  157. .page-template-builder {
  158. position: relative;
  159. .template-create-button {
  160. position: absolute;
  161. top: 8px;
  162. right: 8px;
  163. }
  164. }
  165. .highlighted {
  166. &em {
  167. padding: 2px;
  168. margin: 0 -2px;
  169. font-weight: bold;
  170. }
  171. font-style: normal;
  172. color: #333;
  173. background-color: rgba(255,255,140,0.5);
  174. border-radius: 3px;
  175. }
  176. // {{{ table (copied from bootstrap .table
  177. table {
  178. width: 100%;
  179. margin-bottom: $line-height-computed;
  180. // Cells
  181. > thead,
  182. > tbody,
  183. > tfoot {
  184. > tr {
  185. > th,
  186. > td {
  187. padding: $table-cell-padding;
  188. line-height: $line-height-base;
  189. vertical-align: top;
  190. border-top: 1px solid $table-border-color;
  191. }
  192. }
  193. }
  194. // Bottom align for column headings
  195. > thead > tr > th {
  196. vertical-align: bottom;
  197. border-bottom: 2px solid $table-border-color;
  198. }
  199. // Remove top border from thead by default
  200. > caption + thead,
  201. > colgroup + thead,
  202. > thead:first-child {
  203. > tr:first-child {
  204. > th,
  205. > td {
  206. border-top: 0;
  207. }
  208. }
  209. }
  210. // Account for multiple tbody instances
  211. > tbody + tbody {
  212. border-top: 2px solid $table-border-color;
  213. }
  214. // Nesting
  215. table {
  216. background-color: $body-bg;
  217. }
  218. // .table-bordered
  219. border: 1px solid $table-border-color;
  220. > thead,
  221. > tbody,
  222. > tfoot {
  223. > tr {
  224. > th,
  225. > td {
  226. border: 1px solid $table-border-color;
  227. }
  228. }
  229. }
  230. > thead > tr {
  231. > th,
  232. > td {
  233. border-bottom-width: 2px;
  234. }
  235. }
  236. }
  237. // }}}
  238. }
  239. @media (min-width: $screen-sm-min) and (max-width: $screen-sm-max) { // {{{ tablet size
  240. .crowi.main-container .main .wiki {
  241. }
  242. } // }}}
  243. @media (max-width: $screen-xs-max) { // {{{ iPhone size
  244. .crowi.main-container .main .wiki {
  245. }
  246. } // }}}
  247. @media (max-width: $screen-sm-max) { // {{{ tablet and iphone size
  248. .crowi.main-container .main .wiki {
  249. img {
  250. max-width: 100%;
  251. }
  252. }
  253. }