post.less 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. //
  2. // Posts List Post
  3. // --------------------------------------------------
  4. // Post unread border
  5. .post-new .panel-default {
  6. border-color: @brand-warning;
  7. }
  8. // Post header
  9. .post-heading-container {
  10. overflow: visible;
  11. height: 22px;
  12. &>* {
  13. float: left;
  14. margin-left: 0px;
  15. margin-right: 8px;
  16. &.pull-right {
  17. float: right;
  18. margin-left: 8px;
  19. margin-right: 0px;
  20. }
  21. }
  22. }
  23. .post-heading .label {
  24. position: relative;
  25. top: 3px;
  26. }
  27. .post-heading .btn-sm {
  28. margin-top: -3px;
  29. margin-bottom: 0px;
  30. padding: 4px @padding-small-horizontal;
  31. }
  32. .post-heading .btn-icon {
  33. margin: -6px 0px;
  34. margin-left: 8px;
  35. padding: 0px 3px;
  36. .material-icon {
  37. position: static;
  38. width: 28px;
  39. height: 28px;
  40. font-size: 28px;
  41. line-height: 28px;
  42. }
  43. }
  44. // Post status flags
  45. .post-status-message {
  46. padding: @padding-base-vertical @padding-base-horizontal;
  47. overflow: auto;
  48. .material-icon {
  49. float: left;
  50. font-size: 28px;
  51. }
  52. p {
  53. margin: 0px;
  54. margin-top: (28px - @line-height-computed) / 2;
  55. margin-left: 36px;
  56. }
  57. }
  58. .post-status-hidden {
  59. background-color: @brand-danger;
  60. color: #fff;
  61. }
  62. .post-status-unapproved {
  63. background-color: @brand-primary;
  64. color: #fff;
  65. }
  66. .post-status-protected {
  67. background-color: @gray;
  68. color: #fff;
  69. }
  70. // Hidden post message
  71. .posts-list .panel-body-hidden {
  72. .lead, .text-muted {
  73. margin: 0px;
  74. }
  75. }
  76. // Invalid post message
  77. .posts-list .panel-body-invalid {
  78. .lead, .text-muted {
  79. margin: 0px;
  80. }
  81. }
  82. // Post attachments
  83. .post-attachments {
  84. @post-preview-width: 40px;
  85. border-top: 1px solid @gray-lighter;
  86. padding: @padding-base-vertical @padding-large-horizontal;
  87. abbr {
  88. white-space: nowrap;
  89. }
  90. .attachment-name {
  91. word-wrap: break-word;
  92. }
  93. .row>div {
  94. margin: @padding-large-vertical 0px;
  95. }
  96. .post-attachment-preview {
  97. float: left;
  98. height: @post-preview-width;
  99. width: @post-preview-width;
  100. text-align: center;
  101. }
  102. .post-attachment {
  103. margin-left: @post-preview-width + 12px;
  104. }
  105. .post-thumbnail {
  106. display: block;
  107. background-size: cover;
  108. background-position: center;
  109. border-radius: @border-radius-small;
  110. width: @post-preview-width;
  111. height: @post-preview-width;
  112. }
  113. .material-icon {
  114. width: 28px;
  115. height: 28px;
  116. position: relative;
  117. top: 5px;
  118. font-size: 28px;
  119. line-height: 28px;
  120. &:link, &:active, &:visited, &:hover, &:focus {
  121. color: @gray-darker;
  122. text-decoration: none;
  123. }
  124. }
  125. .post-attachment-description {
  126. margin: 0px;
  127. padding: 0px;
  128. color: @text-muted;
  129. font-size: @font-size-small;
  130. }
  131. }
  132. // Post footer
  133. .post-footer {
  134. overflow: auto;
  135. .btn.pull-right {
  136. margin-left: @line-height-computed / 2;
  137. }
  138. p.pull-left {
  139. margin: 0px;
  140. margin-left: @line-height-computed / 2;
  141. padding: (@padding-base-vertical + 1px) 0px;
  142. }
  143. }
  144. // UI Preview
  145. .posts-list.ui-preview {
  146. .post-heading .ui-preview-text {
  147. position: relative;
  148. top: 0px;
  149. }
  150. }
  151. // Mobile tweaks
  152. @media screen and (max-width: @screen-xs-max) {
  153. .post-heading .post-heading-container {
  154. margin-left: 46px;
  155. height: 34px;
  156. position: relative;
  157. bottom: 2px;
  158. .pull-right {
  159. margin-top: -31px;
  160. }
  161. }
  162. .post-heading .user-status {
  163. margin-right: 3px;
  164. }
  165. .post-heading {
  166. .posted-on-compact, .edited-compact, .unread-compact {
  167. margin-top: -14px;
  168. font-size: @font-size-small;
  169. }
  170. }
  171. .post-heading .unread-compact {
  172. color: @brand-warning;
  173. }
  174. .post-heading .posted-on-compact {
  175. clear: left;
  176. }
  177. .post-heading .btn-icon {
  178. margin-top: 0px;
  179. margin-bottom: 0px;
  180. padding: 1px 4px;
  181. }
  182. .post-heading .post-avatar-sm {
  183. float: left;
  184. img {
  185. width: 35px;
  186. height: 35px;
  187. }
  188. }
  189. .post-footer {
  190. .btn, p {
  191. font-size: @font-size-small;
  192. }
  193. p .material-icon {
  194. margin-right: 3px;
  195. position: relative;
  196. bottom: 1px;
  197. }
  198. }
  199. }