chatMini.scss 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376
  1. @charset "UTF-8";
  2. $chatBg: #34363c;
  3. $chatContBg: #eeeeee;
  4. $chatUiFont: #ffffff;
  5. $offsetBottom: 5px;
  6. $offsetRight: 5px;
  7. @keyframes tipFade{
  8. 0%{
  9. opacity: 1;
  10. transform: scale(1);
  11. }
  12. 100%{
  13. opacity: 0.4;
  14. transform: scale(1.1);
  15. }
  16. }
  17. .mini-wrap{
  18. z-index: 123456789;
  19. height: 100%;
  20. .back-bar{
  21. display: none;
  22. }
  23. }
  24. .mini-body{
  25. height: 100%;
  26. box-sizing: border-box;
  27. padding: 10px 2px 2px;
  28. background: rgba($color: $chatBg, $alpha: 0.9);
  29. }
  30. .box{
  31. position: relative;
  32. height: 100%;
  33. display: flex;
  34. flex-direction: column;
  35. }
  36. .box-hd{
  37. height: 26px;
  38. position: relative;
  39. .btn-menu{
  40. position: absolute;
  41. cursor: pointer;
  42. left: 0;
  43. top: -2px;
  44. width: 20px;
  45. height: 20px;
  46. background: url("./img/icon-menu.png") center no-repeat;
  47. &.active{
  48. &::before{
  49. display: block;
  50. }
  51. }
  52. &::before{
  53. content: "";
  54. position: absolute;
  55. top: 2px;
  56. right: 0;
  57. width: 6px;
  58. height: 6px;
  59. border-radius: 50%;
  60. background: #ff0000;
  61. display: none;
  62. }
  63. }
  64. .btn-close{
  65. position: absolute;
  66. cursor: pointer;
  67. right: 0;
  68. top: -2px;
  69. width: 20px;
  70. height: 20px;
  71. background: url("./img/icon-close.png") center no-repeat;
  72. &:hover{
  73. background-color: #2a2b30;
  74. }
  75. }
  76. .menu-extra{
  77. position: absolute;
  78. top: 24px;
  79. z-index: 10;
  80. left: 4px;
  81. background: #ffffff;
  82. border-radius: 2px;
  83. box-shadow: 0px 1px 5px 1px #cdcdcd;
  84. .info {
  85. padding: 8px 0;
  86. margin: 0 10px;
  87. .avatar {
  88. float: left;
  89. width: 36px;
  90. height: 36px;
  91. margin-right: 6px;
  92. margin-top: 6px;
  93. border-radius: 4px;
  94. border: 1px solid rgba(0,0,0,0.1);
  95. }
  96. .avatar-bg{
  97. background-color: #f5882b;
  98. text-align: center;
  99. line-height: 32px;
  100. color: #ffffff;
  101. font-size: 14px;
  102. }
  103. .account-info{
  104. float: left;
  105. margin-top: 5px;
  106. line-height: 18px;
  107. }
  108. em {
  109. font-size: 12px;
  110. color: #000000;
  111. }
  112. }
  113. .icon-arrow{
  114. display: inline-block;
  115. vertical-align: middle;
  116. margin-left: 10px;
  117. background: url('../chatMini/img/icon-arrow.png') no-repeat;
  118. width: 8px;
  119. height: 12px;
  120. }
  121. .login-out{
  122. display: block;
  123. line-height: 1.5;
  124. color: #7194c3;
  125. font-size: 12px;
  126. cursor: pointer;
  127. }
  128. li{
  129. line-height: 30px;
  130. font-size: 12px;
  131. padding: 0 10px;
  132. display: block;
  133. &:hover{
  134. background: #dcdddf;
  135. }
  136. em{
  137. display: inline-block;
  138. background: #ff0000;
  139. color: #fff;
  140. font-size: 12px;
  141. padding: 2px 5px;
  142. border-radius: 12px;
  143. z-index: 99;
  144. line-height: 1;
  145. margin-left: 4px;
  146. }
  147. }
  148. a{
  149. color: #333333;
  150. display: block;
  151. text-decoration: none;
  152. border-top: 1px solid #eeeeee;
  153. span{
  154. color: #7194c3;
  155. text-decoration:underline;
  156. }
  157. }
  158. }
  159. .box-title{
  160. min-width: 200px;
  161. text-align: left;
  162. padding-left: 25px;
  163. margin: 0 auto;
  164. font-size: 14px;
  165. color: $chatUiFont;
  166. cursor:pointer;
  167. }
  168. .user-tips{
  169. position: absolute;
  170. top: -2px;
  171. right: 30px;
  172. max-width: 50px;
  173. height: 20px;
  174. line-height: 20px;
  175. font-size: 0;
  176. text-align: right;
  177. cursor: pointer;
  178. padding-left: 20px;
  179. background: url(./img/icon-service.png) 0 center / 13px auto no-repeat;
  180. text-decoration: none;
  181. &.active{
  182. &:before{
  183. display: block;
  184. }
  185. }
  186. &:before{
  187. position: absolute;
  188. top: -6px;
  189. right: -17px;
  190. z-index: 2;
  191. width: 14px;
  192. height: 12px;
  193. background: url(./img/icon-msg-tip.png) 0 center/100% no-repeat;
  194. animation:tipFade .2s infinite alternate;
  195. display: none;
  196. }
  197. em{
  198. vertical-align: middle;
  199. color: $chatUiFont;
  200. font-size: 12px;
  201. }
  202. }
  203. }
  204. .box-bd{
  205. height: 0;
  206. flex: 1;
  207. position: relative;
  208. background: $chatContBg;
  209. .msg-unread{
  210. position: absolute;
  211. width: 120px;
  212. left: 50%;
  213. bottom: 10px;
  214. border-radius: 20px;
  215. background: rgba(#000000, 0.5);
  216. padding: 0 5px;
  217. text-align: center;
  218. line-height: 32px;
  219. margin-left: -65px;
  220. cursor: pointer;
  221. &:hover{
  222. background: rgba(#000000, 0.3);
  223. }
  224. em{
  225. color: #ffffff;
  226. font-size: 14px;
  227. }
  228. i{
  229. transform: rotate(90deg);
  230. margin-right: 5px;
  231. }
  232. }
  233. }
  234. .scroller{
  235. height: 100%;
  236. overflow-x: hidden;
  237. overflow-y: scroll;
  238. -webkit-overflow-scrolling: touch;
  239. &::-webkit-scrollbar {
  240. width: 8px;
  241. height: 6px;
  242. }
  243. &::-webkit-scrollbar-thumb {
  244. border-radius: 3px;
  245. -moz-border-radius: 3px;
  246. -webkit-border-radius: 3px;
  247. background-color: rgba($color: #8d8a8a, $alpha: 0.2);
  248. }
  249. &::-webkit-scrollbar-track {
  250. background-color: transparent;
  251. }
  252. }
  253. .mini-control{
  254. position: fixed;
  255. right: $offsetBottom;
  256. bottom: $offsetRight;
  257. user-select: none;
  258. .at-tip{
  259. position: absolute;
  260. left: -9px;
  261. top: -9px;
  262. width: 18px;
  263. height: 18px;
  264. background: #e0273a;
  265. border-radius: 50%;
  266. overflow: hidden;
  267. font-size: 12px;
  268. line-height: 18px;
  269. color: #fff;
  270. text-align: center;
  271. }
  272. ul{
  273. @include webkitbox(1);
  274. background: $chatBg;
  275. opacity: .9;
  276. border-radius: 4px;
  277. overflow: hidden;
  278. }
  279. li{
  280. width: 60px;
  281. height: 40px;
  282. line-height: 40px;
  283. text-align: center;
  284. font-size: 0;
  285. cursor: pointer;
  286. &:hover{
  287. background: #42454c;
  288. }
  289. em{
  290. font-size: 12px;
  291. color: $chatUiFont;
  292. vertical-align: middle;
  293. padding-left: 4px;
  294. }
  295. }
  296. .msg-tips{
  297. &:before{
  298. content: "";
  299. background: url("./img/icon-meechat.png") center center no-repeat;
  300. background-size: 100%;
  301. width: 22px;
  302. height: 20px;
  303. display: inline-block;
  304. vertical-align: middle;
  305. }
  306. }
  307. }
  308. .user-tips{
  309. &:before{
  310. content: "";
  311. background: url("./img/icon-user.png") no-repeat;
  312. background-size: 100%;
  313. width: 8px;
  314. height: 9px;
  315. display: inline-block;
  316. vertical-align: middle;
  317. margin-right: 4px;
  318. }
  319. }
  320. .meechat-icon {
  321. width: 46px;
  322. height: 40px;
  323. background: url('./img/meechat-bg.png') center center no-repeat;
  324. background-size: 100%;
  325. text-align: center;
  326. border-radius: 4px;
  327. cursor: pointer;
  328. padding-top: 14px;
  329. box-sizing: border-box;
  330. &:hover{
  331. opacity: .8;
  332. }
  333. em{
  334. color: #ffffff;
  335. font-size: 12px;
  336. }
  337. }
  338. .msg-wrap{
  339. margin-bottom: 16px;
  340. }
  341. .msg-top-more{
  342. margin-top: 10px;
  343. text-align: center;
  344. i{
  345. font-size: 30px;
  346. }
  347. em{
  348. font-size: 12px;
  349. line-height: 20px;
  350. color: #999999;
  351. }
  352. }
  353. .msg-loading-icon{
  354. display: block;
  355. background: url('../../assets/loading-icon.png') no-repeat;
  356. background-size: 100%;
  357. width: 16px;
  358. height: 16px;
  359. margin: 12px auto;
  360. animation: rotate 2s linear infinite;
  361. }