index.css 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602
  1. /* ==================== Tailwind CSS 配置 ==================== */
  2. @layer tailwind-base, semi, tailwind-components, tailwind-utils;
  3. @layer tailwind-base {
  4. @tailwind base;
  5. }
  6. @layer tailwind-components {
  7. @tailwind components;
  8. }
  9. @layer tailwind-utils {
  10. @tailwind utilities;
  11. }
  12. /* ==================== 全局基础样式 ==================== */
  13. body {
  14. font-family: Lato, 'Helvetica Neue', Arial, Helvetica, 'Microsoft YaHei', sans-serif;
  15. color: var(--semi-color-text-0);
  16. background-color: var(--semi-color-bg-0);
  17. }
  18. code {
  19. font-family:
  20. source-code-pro, Menlo, Monaco, Consolas, 'Courier New', monospace;
  21. }
  22. /* ==================== 布局相关样式 ==================== */
  23. .semi-layout::-webkit-scrollbar,
  24. .semi-layout-content::-webkit-scrollbar,
  25. .semi-sider::-webkit-scrollbar {
  26. display: none;
  27. width: 0;
  28. height: 0;
  29. }
  30. .semi-layout,
  31. .semi-layout-content,
  32. .semi-sider {
  33. -ms-overflow-style: none;
  34. scrollbar-width: none;
  35. }
  36. /* ==================== 导航和侧边栏样式 ==================== */
  37. /* 导航项样式 */
  38. .semi-input-textarea-wrapper,
  39. .semi-navigation-sub-title,
  40. .semi-chat-inputBox-sendButton,
  41. .semi-page-item,
  42. .semi-navigation-item,
  43. .semi-tag-closable,
  44. .semi-input-wrapper,
  45. .semi-tabs-tab-button,
  46. .semi-select,
  47. .semi-button,
  48. .semi-datepicker-range-input {
  49. border-radius: 10px !important;
  50. }
  51. .semi-navigation-item {
  52. margin-bottom: 4px !important;
  53. padding: 4px 12px !important;
  54. }
  55. .semi-navigation-sub-title {
  56. padding: 0 !important;
  57. }
  58. .semi-navigation-item-icon {
  59. justify-items: center;
  60. align-items: center;
  61. }
  62. .semi-navigation-item-icon-info {
  63. margin-right: 0;
  64. }
  65. .semi-navigation-item,
  66. .semi-navigation-sub-title {
  67. height: 100% !important;
  68. }
  69. .semi-navigation-item-collapsed {
  70. height: 44px !important;
  71. }
  72. #root>section>header>section>div>div>div>div.semi-navigation-header-list-outer>div.semi-navigation-list-wrapper>ul>div>a>li>span {
  73. font-weight: 600 !important;
  74. }
  75. /* 自定义侧边栏样式 */
  76. .sidebar-container {
  77. height: 100%;
  78. display: flex;
  79. flex-direction: column;
  80. transition: width 0.3s ease;
  81. }
  82. .sidebar-nav {
  83. flex: 1;
  84. width: 100%;
  85. background: var(--semi-color-bg-0);
  86. height: 100%;
  87. overflow: hidden;
  88. border-right: none;
  89. overflow-y: auto;
  90. scrollbar-width: none;
  91. -ms-overflow-style: none;
  92. }
  93. .sidebar-nav::-webkit-scrollbar {
  94. display: none;
  95. }
  96. /* 侧边栏导航项样式 */
  97. .sidebar-nav-item {
  98. border-radius: 6px;
  99. margin: 3px 8px;
  100. transition: all 0.15s ease;
  101. padding: 8px 12px;
  102. }
  103. .sidebar-nav-item:hover {
  104. background-color: rgba(var(--semi-blue-0), 0.08);
  105. color: var(--semi-color-primary);
  106. }
  107. .sidebar-nav-item-selected {
  108. background-color: rgba(var(--semi-blue-0), 0.12);
  109. color: var(--semi-color-primary);
  110. font-weight: 500;
  111. }
  112. /* 图标容器样式 */
  113. .sidebar-icon-container {
  114. width: 22px;
  115. height: 22px;
  116. display: flex;
  117. align-items: center;
  118. justify-content: center;
  119. margin-right: 10px;
  120. transition: all 0.2s ease;
  121. }
  122. .sidebar-sub-icon-container {
  123. width: 18px;
  124. height: 18px;
  125. display: flex;
  126. align-items: center;
  127. justify-content: center;
  128. margin-right: 10px;
  129. margin-left: 1px;
  130. transition: all 0.2s ease;
  131. }
  132. /* 分割线样式 */
  133. .sidebar-divider {
  134. margin: 4px 8px;
  135. opacity: 0.15;
  136. }
  137. /* 分组标签样式 */
  138. .sidebar-group-label {
  139. padding: 4px 15px 8px;
  140. color: var(--semi-color-text-2);
  141. font-size: 12px;
  142. text-transform: uppercase;
  143. letter-spacing: 0.5px;
  144. opacity: 0.8;
  145. }
  146. /* 底部折叠按钮 */
  147. .sidebar-collapse-button {
  148. display: flex;
  149. justify-content: center;
  150. align-items: center;
  151. padding: 12px;
  152. cursor: pointer;
  153. background-color: var(--semi-color-bg-0);
  154. position: sticky;
  155. bottom: 0;
  156. z-index: 10;
  157. box-shadow: 0 -10px 10px -5px var(--semi-color-bg-0);
  158. backdrop-filter: blur(4px);
  159. border-top: 1px solid rgba(var(--semi-grey-0), 0.08);
  160. }
  161. .sidebar-collapse-button-inner {
  162. width: 28px;
  163. height: 28px;
  164. border-radius: 9999px;
  165. display: flex;
  166. align-items: center;
  167. justify-content: center;
  168. background-color: var(--semi-color-fill-0);
  169. transition: all 0.2s ease;
  170. }
  171. .sidebar-collapse-icon-container {
  172. display: inline-block;
  173. transition: transform 0.3s ease;
  174. }
  175. /* 侧边栏区域容器 */
  176. .sidebar-section {
  177. padding-top: 12px;
  178. }
  179. /* ==================== 聊天界面样式 ==================== */
  180. .semi-chat {
  181. padding-top: 0 !important;
  182. padding-bottom: 0 !important;
  183. height: 100%;
  184. max-width: 100% !important;
  185. width: 100% !important;
  186. overflow: hidden !important;
  187. }
  188. .semi-chat-chatBox {
  189. max-width: 100% !important;
  190. overflow: hidden !important;
  191. }
  192. .semi-chat-chatBox-wrap {
  193. max-width: 100% !important;
  194. overflow: hidden !important;
  195. }
  196. .semi-chat-chatBox-content {
  197. min-width: auto;
  198. word-break: break-word;
  199. max-width: 100% !important;
  200. overflow-wrap: break-word !important;
  201. }
  202. .semi-chat-content {
  203. max-width: 100% !important;
  204. overflow: hidden !important;
  205. }
  206. .semi-chat-list {
  207. max-width: 100% !important;
  208. overflow-x: hidden !important;
  209. }
  210. .semi-chat-container {
  211. overflow-x: hidden !important;
  212. }
  213. .semi-chat-chatBox-action {
  214. column-gap: 0 !important;
  215. }
  216. .semi-chat-inputBox-clearButton.semi-button .semi-icon {
  217. font-size: 20px !important;
  218. }
  219. /* 隐藏所有聊天相关区域的滚动条 */
  220. .semi-chat::-webkit-scrollbar,
  221. .semi-chat-chatBox::-webkit-scrollbar,
  222. .semi-chat-chatBox-wrap::-webkit-scrollbar,
  223. .semi-chat-chatBox-content::-webkit-scrollbar,
  224. .semi-chat-content::-webkit-scrollbar,
  225. .semi-chat-list::-webkit-scrollbar,
  226. .semi-chat-container::-webkit-scrollbar {
  227. display: none;
  228. }
  229. .semi-chat,
  230. .semi-chat-chatBox,
  231. .semi-chat-chatBox-wrap,
  232. .semi-chat-chatBox-content,
  233. .semi-chat-content,
  234. .semi-chat-list,
  235. .semi-chat-container {
  236. -ms-overflow-style: none;
  237. scrollbar-width: none;
  238. }
  239. /* ==================== 组件特定样式 ==================== */
  240. /* Tabs组件样式 */
  241. .semi-tabs-content {
  242. padding: 0 !important;
  243. height: calc(100% - 40px) !important;
  244. flex: 1 !important;
  245. }
  246. .semi-tabs-content .semi-tabs-pane {
  247. height: 100% !important;
  248. overflow: hidden !important;
  249. }
  250. .semi-tabs-content .semi-tabs-pane>div {
  251. height: 100% !important;
  252. }
  253. /* 表格样式 */
  254. .tableShow {
  255. display: revert;
  256. }
  257. .tableHiddle {
  258. display: none !important;
  259. }
  260. /* 页脚样式 */
  261. .custom-footer {
  262. font-size: 1.1em;
  263. }
  264. /* 卡片内容容器通用样式 */
  265. .card-content-container {
  266. position: relative;
  267. }
  268. .card-content-fade-indicator {
  269. position: absolute;
  270. bottom: 0;
  271. left: 0;
  272. right: 0;
  273. height: 30px;
  274. background: linear-gradient(transparent, var(--semi-color-bg-1));
  275. pointer-events: none;
  276. z-index: 1;
  277. opacity: 0;
  278. transition: opacity 0.3s ease;
  279. }
  280. /* ==================== 调试面板特定样式 ==================== */
  281. .debug-panel .semi-tabs {
  282. height: 100% !important;
  283. display: flex !important;
  284. flex-direction: column !important;
  285. }
  286. .debug-panel .semi-tabs-bar {
  287. flex-shrink: 0 !important;
  288. }
  289. .debug-panel .semi-tabs-content {
  290. flex: 1 !important;
  291. overflow: hidden !important;
  292. }
  293. /* ==================== 滚动条样式统一管理 ==================== */
  294. /* 表格滚动条样式 */
  295. .semi-table-body::-webkit-scrollbar {
  296. width: 6px;
  297. height: 6px;
  298. }
  299. .semi-table-body::-webkit-scrollbar-thumb {
  300. background: rgba(var(--semi-grey-2), 0.3);
  301. border-radius: 2px;
  302. }
  303. .semi-table-body::-webkit-scrollbar-thumb:hover {
  304. background: rgba(var(--semi-grey-2), 0.5);
  305. }
  306. .semi-table-body::-webkit-scrollbar-track {
  307. background: transparent;
  308. }
  309. /* 侧边抽屉滚动条样式 */
  310. .semi-sidesheet-body::-webkit-scrollbar {
  311. width: 6px;
  312. height: 6px;
  313. }
  314. .semi-sidesheet-body::-webkit-scrollbar-thumb {
  315. background: rgba(var(--semi-grey-2), 0.3);
  316. border-radius: 2px;
  317. }
  318. .semi-sidesheet-body::-webkit-scrollbar-thumb:hover {
  319. background: rgba(var(--semi-grey-2), 0.5);
  320. }
  321. .semi-sidesheet-body::-webkit-scrollbar-track {
  322. background: transparent;
  323. }
  324. /* 隐藏卡片内容区域的滚动条 */
  325. .model-test-scroll,
  326. .card-content-scroll,
  327. .model-settings-scroll,
  328. .thinking-content-scroll,
  329. .custom-request-textarea .semi-input,
  330. .custom-request-textarea textarea,
  331. .notice-content-scroll {
  332. -ms-overflow-style: none;
  333. scrollbar-width: none;
  334. }
  335. .model-test-scroll::-webkit-scrollbar,
  336. .card-content-scroll::-webkit-scrollbar,
  337. .model-settings-scroll::-webkit-scrollbar,
  338. .thinking-content-scroll::-webkit-scrollbar,
  339. .custom-request-textarea .semi-input::-webkit-scrollbar,
  340. .custom-request-textarea textarea::-webkit-scrollbar,
  341. .notice-content-scroll::-webkit-scrollbar {
  342. display: none;
  343. }
  344. /* 图片列表滚动条样式 */
  345. .image-list-scroll::-webkit-scrollbar {
  346. width: 6px;
  347. height: 6px;
  348. }
  349. .image-list-scroll::-webkit-scrollbar-thumb {
  350. background: var(--semi-color-tertiary-light-default);
  351. border-radius: 3px;
  352. }
  353. .image-list-scroll::-webkit-scrollbar-thumb:hover {
  354. background: var(--semi-color-tertiary);
  355. }
  356. .image-list-scroll::-webkit-scrollbar-track {
  357. background: transparent;
  358. }
  359. /* ==================== 响应式/移动端样式 ==================== */
  360. @media only screen and (max-width: 767px) {
  361. /* 移动端表格样式调整 */
  362. .semi-table-tbody,
  363. .semi-table-row,
  364. .semi-table-row-cell {
  365. display: block !important;
  366. width: auto !important;
  367. padding: 2px !important;
  368. }
  369. .semi-table-row-cell {
  370. border-bottom: 0 !important;
  371. }
  372. .semi-table-tbody>.semi-table-row {
  373. border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  374. }
  375. }
  376. /* ==================== 同步倍率 - 渠道选择器 ==================== */
  377. .components-transfer-source-item,
  378. .components-transfer-selected-item {
  379. display: flex;
  380. align-items: center;
  381. padding: 8px;
  382. }
  383. .semi-transfer-left-list,
  384. .semi-transfer-right-list {
  385. -ms-overflow-style: none;
  386. scrollbar-width: none;
  387. }
  388. .semi-transfer-left-list::-webkit-scrollbar,
  389. .semi-transfer-right-list::-webkit-scrollbar {
  390. display: none;
  391. }
  392. .components-transfer-source-item .semi-checkbox,
  393. .components-transfer-selected-item .semi-checkbox {
  394. display: flex;
  395. align-items: center;
  396. width: 100%;
  397. }
  398. .components-transfer-source-item .semi-avatar,
  399. .components-transfer-selected-item .semi-avatar {
  400. margin-right: 12px;
  401. flex-shrink: 0;
  402. }
  403. .components-transfer-source-item .info,
  404. .components-transfer-selected-item .info {
  405. flex: 1;
  406. overflow: hidden;
  407. display: flex;
  408. flex-direction: column;
  409. justify-content: center;
  410. }
  411. .components-transfer-source-item .name,
  412. .components-transfer-selected-item .name {
  413. font-weight: 500;
  414. white-space: nowrap;
  415. overflow: hidden;
  416. text-overflow: ellipsis;
  417. }
  418. .components-transfer-source-item .email,
  419. .components-transfer-selected-item .email {
  420. font-size: 12px;
  421. color: var(--semi-color-text-2);
  422. display: flex;
  423. align-items: center;
  424. }
  425. .components-transfer-selected-item .semi-icon-close {
  426. margin-left: 8px;
  427. cursor: pointer;
  428. color: var(--semi-color-text-2);
  429. }
  430. .components-transfer-selected-item .semi-icon-close:hover {
  431. color: var(--semi-color-text-0);
  432. }
  433. /* ==================== 未读通知闪光效果 ==================== */
  434. @keyframes sweep-shine {
  435. 0% {
  436. background-position: 200% 0;
  437. }
  438. 100% {
  439. background-position: -200% 0;
  440. }
  441. }
  442. .shine-text {
  443. background: linear-gradient(90deg, currentColor 0%, currentColor 40%, rgba(255, 255, 255, 0.9) 50%, currentColor 60%, currentColor 100%);
  444. background-size: 200% 100%;
  445. -webkit-background-clip: text;
  446. background-clip: text;
  447. -webkit-text-fill-color: transparent;
  448. animation: sweep-shine 4s linear infinite;
  449. }
  450. .dark .shine-text {
  451. background: linear-gradient(90deg, currentColor 0%, currentColor 40%, #facc15 50%, currentColor 60%, currentColor 100%);
  452. background-size: 200% 100%;
  453. -webkit-background-clip: text;
  454. background-clip: text;
  455. -webkit-text-fill-color: transparent;
  456. }
  457. /* ==================== ScrollList 定制样式 ==================== */
  458. .semi-scrolllist,
  459. .semi-scrolllist * {
  460. -ms-overflow-style: none;
  461. /* IE, Edge */
  462. scrollbar-width: none;
  463. /* Firefox */
  464. background: transparent !important;
  465. }
  466. .semi-scrolllist::-webkit-scrollbar,
  467. .semi-scrolllist *::-webkit-scrollbar {
  468. width: 0 !important;
  469. height: 0 !important;
  470. display: none !important;
  471. }
  472. .semi-scrolllist-body {
  473. padding: 1px !important;
  474. }
  475. .semi-scrolllist-list-outer {
  476. padding-right: 0 !important;
  477. }
  478. /* ==================== Banner 背景模糊球 ==================== */
  479. .blur-ball {
  480. position: absolute;
  481. width: 360px;
  482. height: 360px;
  483. border-radius: 50%;
  484. filter: blur(120px);
  485. pointer-events: none;
  486. z-index: -1;
  487. }
  488. .blur-ball-indigo {
  489. background: #6366f1;
  490. /* indigo-500 */
  491. top: 40px;
  492. left: 50%;
  493. transform: translateX(-50%);
  494. opacity: 0.5;
  495. }
  496. .blur-ball-teal {
  497. background: #14b8a6;
  498. /* teal-400 */
  499. top: 200px;
  500. left: 30%;
  501. opacity: 0.4;
  502. }
  503. /* 浅色主题下让模糊球更柔和 */
  504. html:not(.dark) .blur-ball-indigo {
  505. opacity: 0.25;
  506. }
  507. html:not(.dark) .blur-ball-teal {
  508. opacity: 0.2;
  509. }