chat.scss 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336
  1. .els {
  2. white-space: nowrap; /* 强制文本不换行 */
  3. overflow: hidden; /* 隐藏溢出内容 */
  4. text-overflow: ellipsis; /* 显示省略号 */
  5. }
  6. .chat-container {
  7. border-radius: 14px;
  8. height: 100%;
  9. display: flex;
  10. flex-direction: column;
  11. border: 1px solid #dcdfe6;
  12. //background-color: #f0f0f0;
  13. background-color: #ffffff;
  14. }
  15. .message-list {
  16. flex: 1;
  17. overflow: hidden;
  18. position: relative;
  19. }
  20. .messages {
  21. padding: 12px 12px 0;
  22. min-height: 100%;
  23. display: flex;
  24. flex-direction: column;
  25. }
  26. .message-item {
  27. display: flex;
  28. margin-bottom: 20px;
  29. gap: 12px;
  30. color: #333;
  31. align-items: flex-start;
  32. animation: fadeIn 0.3s ease-in-out;
  33. }
  34. @keyframes fadeIn {
  35. from {
  36. opacity: 0;
  37. transform: translateY(10px);
  38. }
  39. to {
  40. opacity: 1;
  41. transform: translateY(0);
  42. }
  43. }
  44. .message-item.self {
  45. flex-direction: row-reverse;
  46. }
  47. .message-content {
  48. max-width: 80%;
  49. }
  50. .username {
  51. font-size: 14px;
  52. color: #606266;
  53. margin-bottom: 4px;
  54. }
  55. .content {
  56. padding: 6px;
  57. background-color: #f0f4f8;
  58. border-radius: 4px;
  59. //background: linear-gradient(to bottom right, #D2B48C, #E8D5B5);
  60. //background: linear-gradient(to bottom, #D2B48C, #E8D5B5);
  61. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  62. word-break: break-all;
  63. line-height: 1.5;
  64. font-size: 14px;
  65. letter-spacing: 1px;
  66. }
  67. .content :deep(pre) {
  68. margin: 10px 0;
  69. border-radius: 8px;
  70. }
  71. .content :deep(code) {
  72. font-family: 'Menlo', 'Monaco', 'Courier New', monospace;
  73. }
  74. .content :deep(p) {
  75. margin: 8px 0;
  76. }
  77. .content :deep(ul),
  78. .content :deep(ol) {
  79. padding-left: 20px;
  80. margin: 8px 0;
  81. }
  82. .content :deep(blockquote) {
  83. border-left: 4px solid #ddd;
  84. padding-left: 10px;
  85. color: #666;
  86. margin: 8px 0;
  87. }
  88. .self .content {
  89. background: #409eff;
  90. color: white;
  91. //border-bottom-right-radius: 4px;
  92. }
  93. .other .content {
  94. border-bottom-left-radius: 4px;
  95. }
  96. .timestamp {
  97. display: flex;
  98. justify-content: space-between;
  99. font-size: 12px;
  100. color: #909399;
  101. margin-top: 6px;
  102. }
  103. .timestamp span {
  104. transition: color 0.2s;
  105. }
  106. .timestamp span:hover {
  107. color: #409eff;
  108. }
  109. .info-card {
  110. margin: 10px;
  111. }
  112. .card-icon {
  113. color: #409eff;
  114. }
  115. @keyframes scrollTitle {
  116. 0% {
  117. transform: translateX(0);
  118. }
  119. 100% {
  120. transform: translateX(-100%);
  121. }
  122. }
  123. .upload :deep(.el-icon) {
  124. transition: color 0.3s;
  125. }
  126. .can-hover :deep(.el-icon:hover) {
  127. color: #409eff !important;
  128. }
  129. .el-check-tag {
  130. margin-right: 8px;
  131. transition: all 0.3s;
  132. }
  133. .el-check-tag:hover {
  134. transform: scale(1.05);
  135. }
  136. /* 加载中的消息样式 */
  137. .loading-content {
  138. min-height: 40px;
  139. display: flex;
  140. align-items: center;
  141. justify-content: flex-start;
  142. }
  143. .loading-indicator {
  144. display: inline-block;
  145. align-items: center;
  146. gap: 4px;
  147. margin-left: 2px;
  148. .dot {
  149. width: 4px;
  150. height: 4px;
  151. margin: 0 2px;
  152. background-color: gray;
  153. border-radius: 50%;
  154. display: inline-block;
  155. animation: pulse 1.5s infinite ease-in-out;
  156. }
  157. .dot:nth-child(2) {
  158. animation-delay: 0.3s;
  159. }
  160. .dot:nth-child(3) {
  161. animation-delay: 0.6s;
  162. }
  163. @keyframes pulse {
  164. 0%,
  165. 100% {
  166. transform: scale(0.8);
  167. opacity: 0.6;
  168. }
  169. 50% {
  170. transform: scale(1.2);
  171. opacity: 1;
  172. }
  173. }
  174. }
  175. .input-area {
  176. padding: 8px 10px;
  177. color: black;
  178. background-color: #fff;
  179. border: 1px solid rgba(102, 102, 102, 0.3);
  180. border-radius: 16px;
  181. margin: 0 12px 12px;
  182. position: relative;
  183. .card_list {
  184. display: flex;
  185. flex-wrap: nowrap;
  186. overflow-x: auto;
  187. padding: 4px 0;
  188. .card_width {
  189. width: 124px !important;
  190. }
  191. }
  192. .card-content {
  193. flex-shrink: 0;
  194. width: fit-content;
  195. max-width: 260px;
  196. height: 50px;
  197. display: flex;
  198. align-items: center;
  199. gap: 6px;
  200. padding: 8px 6px;
  201. margin: 0 8px 6px 0;
  202. background: #fff;
  203. border-radius: 10px;
  204. border: 1px solid rgba(0, 0, 0, 0.2);
  205. font-size: 14px;
  206. position: relative;
  207. .title-wrapper {
  208. display: flex;
  209. //width: fit-content;
  210. width: calc(100% - 30px);
  211. flex-direction: column;
  212. }
  213. .title-scroller {
  214. display: inline-block;
  215. white-space: nowrap;
  216. color: #000000;
  217. font-size: 14px;
  218. font-weight: 900;
  219. }
  220. .url-scroller {
  221. font-size: 12px;
  222. color: #909399;
  223. }
  224. .title-scroller.scroll {
  225. animation: scrollTitle 10s linear infinite;
  226. }
  227. .closeIcon {
  228. display: none;
  229. cursor: pointer;
  230. position: absolute;
  231. right: -5px;
  232. top: -5px;
  233. background-color: #ffffff;
  234. border-radius: 50%;
  235. z-index: 1;
  236. }
  237. }
  238. .closeShow {
  239. display: none;
  240. position: absolute;
  241. right: -5px;
  242. top: -5px;
  243. background-color: #ffffff;
  244. border-radius: 50%;
  245. z-index: 1;
  246. cursor: pointer;
  247. }
  248. .card-content:hover {
  249. .closeIcon {
  250. display: block;
  251. }
  252. }
  253. .card-btn {
  254. padding: 0 0 4px;
  255. .op {
  256. margin-right: 3px;
  257. }
  258. }
  259. .chat_area_op {
  260. margin-top: 3px;
  261. display: flex;
  262. justify-content: end;
  263. }
  264. }
  265. .input-area:hover {
  266. border-color: rgba(102, 102, 102, 0.4);
  267. }
  268. .input-area :deep(.el-textarea__inner) {
  269. border-radius: 8px;
  270. transition: border-color 0.3s;
  271. resize: none;
  272. box-shadow: none;
  273. }
  274. .input-area :deep(.el-textarea__inner) {
  275. padding: 0 4px;
  276. margin-top: 3px;
  277. }
  278. .input-area :deep(.el-textarea__inner:focus) {
  279. border-color: #409eff;
  280. box-shadow: none;
  281. }
  282. .buttom-clicked {
  283. color: #409eff;
  284. border-color: rgb(197.7, 225.9, 255);
  285. }