闭社主体 forked from https://github.com/tootsuite/mastodon
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

380 lines
6.5 KiB

  1. .activity-stream {
  2. clear: both;
  3. box-shadow: 0 0 15px rgba($base-shadow-color, 0.2);
  4. .entry {
  5. background: $simple-background-color;
  6. .detailed-status.light,
  7. .status.light {
  8. border-bottom: 1px solid $ui-secondary-color;
  9. }
  10. &:last-child {
  11. &,
  12. .detailed-status.light,
  13. .status.light {
  14. border-bottom: 0;
  15. border-radius: 0 0 4px 4px;
  16. }
  17. }
  18. &:first-child {
  19. &,
  20. .detailed-status.light,
  21. .status.light {
  22. border-radius: 4px 4px 0 0;
  23. }
  24. &:last-child {
  25. &,
  26. .detailed-status.light,
  27. .status.light {
  28. border-radius: 4px;
  29. }
  30. }
  31. }
  32. }
  33. .status.light {
  34. padding: 14px 14px 14px (48px + 14px * 2);
  35. position: relative;
  36. min-height: 48px;
  37. cursor: default;
  38. .status__header {
  39. font-size: 15px;
  40. .status__meta {
  41. float: right;
  42. font-size: 14px;
  43. .status__relative-time {
  44. color: $ui-primary-color;
  45. }
  46. }
  47. }
  48. .status__display-name {
  49. display: block;
  50. max-width: 100%;
  51. padding-right: 25px;
  52. color: $ui-base-color;
  53. }
  54. .status__avatar {
  55. position: absolute;
  56. left: 14px;
  57. top: 14px;
  58. width: 48px;
  59. height: 48px;
  60. & > div {
  61. width: 48px;
  62. height: 48px;
  63. }
  64. img {
  65. display: block;
  66. border-radius: 4px;
  67. }
  68. }
  69. .display-name {
  70. display: block;
  71. max-width: 100%;
  72. overflow: hidden;
  73. white-space: nowrap;
  74. text-overflow: ellipsis;
  75. strong {
  76. font-weight: 500;
  77. color: $ui-base-color;
  78. }
  79. span {
  80. font-size: 14px;
  81. color: $ui-primary-color;
  82. }
  83. }
  84. .status__content {
  85. color: $ui-base-color;
  86. a {
  87. color: $ui-highlight-color;
  88. }
  89. a.status__content__spoiler-link {
  90. color: $primary-text-color;
  91. background: $ui-primary-color;
  92. &:hover {
  93. background: lighten($ui-primary-color, 8%);
  94. }
  95. }
  96. }
  97. .status__attachments {
  98. margin-top: 8px;
  99. overflow: hidden;
  100. width: 100%;
  101. box-sizing: border-box;
  102. position: relative;
  103. .status__attachments__inner {
  104. display: flex;
  105. height: 214px;
  106. }
  107. }
  108. }
  109. .detailed-status.light {
  110. padding: 14px;
  111. background: $simple-background-color;
  112. cursor: default;
  113. .detailed-status__display-name {
  114. display: block;
  115. overflow: hidden;
  116. margin-bottom: 15px;
  117. & > div {
  118. float: left;
  119. margin-right: 10px;
  120. }
  121. .display-name {
  122. display: block;
  123. max-width: 100%;
  124. overflow: hidden;
  125. white-space: nowrap;
  126. text-overflow: ellipsis;
  127. strong {
  128. font-weight: 500;
  129. color: $ui-base-color;
  130. }
  131. span {
  132. font-size: 14px;
  133. color: $ui-primary-color;
  134. }
  135. }
  136. }
  137. .avatar {
  138. width: 48px;
  139. height: 48px;
  140. img {
  141. display: block;
  142. border-radius: 4px;
  143. }
  144. }
  145. .status__content {
  146. color: $ui-base-color;
  147. a {
  148. color: $ui-highlight-color;
  149. }
  150. a.status__content__spoiler-link {
  151. color: $primary-text-color;
  152. background: $ui-primary-color;
  153. &:hover {
  154. background: lighten($ui-primary-color, 8%);
  155. }
  156. }
  157. }
  158. .detailed-status__meta {
  159. margin-top: 15px;
  160. color: $ui-primary-color;
  161. font-size: 14px;
  162. line-height: 18px;
  163. a {
  164. color: inherit;
  165. }
  166. span > span {
  167. font-weight: 500;
  168. font-size: 12px;
  169. margin-left: 6px;
  170. display: inline-block;
  171. }
  172. }
  173. .detailed-status__attachments {
  174. margin-top: 8px;
  175. overflow: hidden;
  176. width: 100%;
  177. box-sizing: border-box;
  178. position: relative;
  179. .status__attachments__inner {
  180. display: flex;
  181. height: 360px;
  182. }
  183. }
  184. .video-player {
  185. margin-top: 8px;
  186. height: 300px;
  187. overflow: hidden;
  188. position: relative;
  189. video {
  190. position: relative;
  191. z-index: 1;
  192. width: 100%;
  193. height: 100%;
  194. object-fit: cover;
  195. top: 50%;
  196. transform: translateY(-50%);
  197. }
  198. }
  199. }
  200. .media-item,
  201. .video-item {
  202. box-sizing: border-box;
  203. position: relative;
  204. left: auto;
  205. top: auto;
  206. right: auto;
  207. bottom: auto;
  208. float: left;
  209. border: medium none;
  210. display: block;
  211. flex: 1 1 auto;
  212. height: 100%;
  213. margin-right: 2px;
  214. &:last-child {
  215. margin-right: 0;
  216. }
  217. a {
  218. display: block;
  219. width: 100%;
  220. height: 100%;
  221. background: no-repeat scroll center center / cover;
  222. text-decoration: none;
  223. cursor: zoom-in;
  224. }
  225. video {
  226. position: relative;
  227. z-index: 1;
  228. width: 100%;
  229. height: 100%;
  230. object-fit: cover;
  231. top: 50%;
  232. transform: translateY(-50%);
  233. }
  234. }
  235. .video-item {
  236. a {
  237. cursor: pointer;
  238. }
  239. .video-item__play {
  240. position: absolute;
  241. top: 50%;
  242. left: 50%;
  243. font-size: 36px;
  244. transform: translate(-50%, -50%);
  245. padding: 5px;
  246. border-radius: 100px;
  247. color: rgba($primary-text-color, 0.8);
  248. z-index: 1;
  249. }
  250. }
  251. .media-spoiler {
  252. background: $ui-primary-color;
  253. width: 100%;
  254. height: 100%;
  255. cursor: pointer;
  256. position: absolute;
  257. top: 0;
  258. left: 0;
  259. display: flex;
  260. align-items: center;
  261. justify-content: center;
  262. flex-direction: column;
  263. text-align: center;
  264. transition: all 100ms linear;
  265. z-index: 2;
  266. &:hover {
  267. background: darken($ui-primary-color, 5%);
  268. }
  269. span {
  270. display: block;
  271. &:first-child {
  272. font-size: 14px;
  273. }
  274. &:last-child {
  275. font-size: 11px;
  276. font-weight: 500;
  277. }
  278. }
  279. }
  280. .pre-header {
  281. padding: 14px 0;
  282. padding-left: (48px + 14px * 2);
  283. padding-bottom: 0;
  284. margin-bottom: -4px;
  285. color: $ui-primary-color;
  286. font-size: 14px;
  287. position: relative;
  288. .pre-header__icon {
  289. position: absolute;
  290. left: (48px + 14px * 2 - 30px);
  291. }
  292. .status__display-name.muted strong {
  293. color: $ui-primary-color;
  294. }
  295. }
  296. .open-in-web-link {
  297. text-decoration: none;
  298. &:hover {
  299. text-decoration: underline;
  300. }
  301. }
  302. }
  303. .embed {
  304. .activity-stream {
  305. border-radius: 4px;
  306. box-shadow: none;
  307. .entry {
  308. &:last-child {
  309. border-radius: 0 0 4px 4px;
  310. }
  311. &:first-child {
  312. border-radius: 4px 4px 0 0;
  313. &:last-child {
  314. border-radius: 4px;
  315. }
  316. }
  317. }
  318. }
  319. }