freepost.styl 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376
  1. @require 'reset.styl'
  2. /* A class used for displaying URLs domain (under post tile) */
  3. .netloc
  4. color #828282
  5. font-size 1rem
  6. font-style italic
  7. .monkey
  8. height 1.5em
  9. margin 0 1em
  10. vertical-align middle
  11. a.topic,
  12. a.topic:hover,
  13. a.topic:visited
  14. color rgba(200,0,100,.8)
  15. font-size 1rem
  16. padding 0 .2rem
  17. text-decoration none
  18. /* Text icon near the title, to display the post content */
  19. .text_preview
  20. height .8rem
  21. margin 0 .5rem
  22. vertical-align middle
  23. /* Logo text */
  24. a.logo,
  25. a.logo:hover,
  26. a.logo:visited
  27. color #000
  28. font-weight bold
  29. text-decoration none
  30. body
  31. > .container
  32. margin auto
  33. max-width 80%
  34. /* Page header */
  35. > .header
  36. @media only screen and (max-width: 800px)
  37. display grid
  38. grid-template-columns auto
  39. > .title-large
  40. display none
  41. > .title-small
  42. display grid
  43. grid-template-columns auto max-content
  44. @media only screen and (min-width: 800px)
  45. display grid
  46. grid-template-columns max-content auto
  47. > .title-small
  48. display none
  49. padding 1rem 0
  50. /* Menu under the logo */
  51. @media only screen and (max-width: 800px)
  52. .burger-icon
  53. display inline-block
  54. .menu
  55. border-bottom 2px dashed #aaa
  56. display none
  57. padding 1rem 0
  58. /* This class is toggled when the burger icon is clicked */
  59. &.visible
  60. display block
  61. /* Every menu item */
  62. > a
  63. border 0
  64. color #000
  65. display block
  66. margin 0
  67. padding .8rem 0
  68. text-align left
  69. text-decoration none
  70. /* Highlight menu item of the current active page (Hot/New/Submit/...) */
  71. > .active_page
  72. font-weight bold
  73. text-decoration underline dotted
  74. text-transform uppercase
  75. /* Highlight username if there are unread messages */
  76. .new_messages
  77. background-color rgb(255, 175, 50)
  78. color #fff
  79. font-weight bold
  80. padding-left 1rem
  81. @media only screen and (min-width: 800px)
  82. .burger-icon
  83. display none
  84. .menu
  85. border-bottom 1px solid transparent
  86. display flex
  87. flex-direction row
  88. flex-wrap wrap
  89. justify-content flex-start
  90. align-content flex-start
  91. align-items flex-end
  92. > .flex-item
  93. flex 0 1 auto
  94. align-self auto
  95. order 0
  96. border 0
  97. border-bottom 1px solid #ccc
  98. color #000
  99. margin 0
  100. padding 0 .5rem .5rem .5rem
  101. /* Highlight menu item of the current active page (Hot/New/Submit/...) */
  102. > .active_page
  103. border-bottom 3px solid #000
  104. /* Highlight username if there are unread messages */
  105. .new_messages
  106. background-color rgb(255, 175, 50)
  107. border 0
  108. border-radius 4px
  109. color #fff
  110. font-weight bold
  111. margin 0
  112. padding .5em .5em
  113. text-decoration none
  114. > .content
  115. padding 1em 0
  116. line-height 1.5em
  117. .vote
  118. margin 0 1rem 0 0
  119. padding 0 .5rem
  120. form
  121. display inline-block
  122. margin 0
  123. padding 0
  124. > button
  125. background transparent
  126. border 0
  127. cursor pointer
  128. display inline-block
  129. margin 0
  130. overflow hidden
  131. padding 0
  132. text-decoration none
  133. vertical-align middle
  134. > img
  135. height .8rem
  136. width .8rem
  137. /* Votes counter */
  138. > .count
  139. margin 0 .5rem
  140. .upvoted
  141. background-color #d1ffd5
  142. border 1px dashed
  143. border-color #00e313
  144. border-radius .5rem
  145. color #00a200
  146. font-weight bolder
  147. .downvoted
  148. background-color #ffd9d9
  149. border 1px dashed
  150. border-color #ff7171
  151. border-radius .5rem
  152. color #f00
  153. font-weight bolder
  154. /* Home page */
  155. .posts
  156. /* A singe post */
  157. > .post
  158. display grid
  159. grid-template-columns min-content auto
  160. grid-column-gap 1.5rem
  161. margin-bottom 2rem
  162. /* Show numbered position in the list */
  163. > .position
  164. color #555
  165. font-style italic
  166. line-height 1.9rem
  167. text-align right
  168. > .info
  169. > .title > a
  170. color #000
  171. font-size 1.6rem
  172. /* Some post info showed below the title */
  173. > .about
  174. color #666
  175. margin .5rem 0 0 0
  176. > .pagination
  177. > form
  178. width 100%
  179. /* New submission page */
  180. > form.submit
  181. width 100%
  182. /* Page for a post */
  183. > .post
  184. /* Style used to format Markdown tables */
  185. table
  186. background #fff
  187. border-collapse collapse
  188. text-align left
  189. th
  190. border-bottom 2px solid #6678b1
  191. color #039
  192. font-weight normal
  193. padding 0 1em
  194. td
  195. border-bottom 1px solid #ccc
  196. color #669
  197. padding .5em 1em
  198. tbody tr:hover td
  199. color #009
  200. /* The post title */
  201. > .title
  202. font-size 1.5em
  203. /* Info below post title */
  204. > .info
  205. margin 1em 0
  206. > .username
  207. margin-left 1rem
  208. /* Post text */
  209. > .text
  210. margin 2rem 0
  211. word-wrap break-word
  212. /* The "new comment" form for this post page */
  213. .new_comment
  214. > input[type=submit]
  215. margin 1em 0
  216. /* Comments tree for the Post page */
  217. > .comments
  218. margin 5em 0 0 0
  219. /* A single comment in the tree */
  220. > .comment
  221. margin 0 0 1rem 0
  222. overflow hidden
  223. /* Some info about this comment */
  224. > .info
  225. display inline-block
  226. font-size .9rem
  227. > .username
  228. display inline-block
  229. margin 0 1rem
  230. > a, a:hover, a:visited
  231. display inline-block
  232. text-decoration none
  233. > .op
  234. background-color rgb(255, 175, 50)
  235. border-radius 4px
  236. font-weight bold
  237. padding 0 1rem
  238. > a, a:hover, a:visited
  239. color #fff
  240. /* The comment text */
  241. > .text
  242. word-wrap break-word
  243. /* Give the comment that's linked to in the URL location hash a lightyellow background color */
  244. .comment:target
  245. background-color lightyellow
  246. > .search
  247. margin-bottom 3rem
  248. /* User home page */
  249. > form > .user
  250. display grid
  251. grid-column-gap 3rem
  252. grid-row-gap 1rem
  253. grid-template-columns max-content auto
  254. /* User activity */
  255. > .user_activity
  256. > *
  257. margin 0 0 2em 0
  258. > .info
  259. color #888
  260. /* Login page */
  261. > .login
  262. @media only screen and (min-width: 1024px)
  263. margin auto
  264. max-width 40%
  265. > form > div
  266. margin 1rem 0
  267. /* Page to edit a post or a comment */
  268. > .edit
  269. {
  270. }
  271. /* Page to reply to a comment */
  272. > .reply
  273. {
  274. }
  275. /* About page */
  276. > .about
  277. > h3
  278. margin 1em 0 .5em 0
  279. > p
  280. line-height 1.5em
  281. > footer
  282. border-top 1px solid #ccc
  283. margin 3em 0 0 0
  284. padding 2em 0
  285. img
  286. height 1.2em
  287. margin 0 .5em 0 0
  288. vertical-align middle
  289. > ul
  290. list-style none
  291. margin 0
  292. overflow hidden
  293. padding 0
  294. > li
  295. float left
  296. margin 0 2em 0 0
  297. @media only screen and (max-width: 1024px)
  298. float none
  299. margin 1rem 0