styles.css 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978
  1. /* 全局样式 */
  2. * {
  3. margin: 0;
  4. padding: 0;
  5. box-sizing: border-box;
  6. }
  7. body {
  8. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  9. line-height: 1.6;
  10. color: #1a1a1a;
  11. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  12. }
  13. /* 滚动条美化 */
  14. ::-webkit-scrollbar {
  15. width: 8px;
  16. height: 8px;
  17. }
  18. ::-webkit-scrollbar-track {
  19. background: #f1f1f1;
  20. border-radius: 4px;
  21. }
  22. ::-webkit-scrollbar-thumb {
  23. background: #c1c1c1;
  24. border-radius: 4px;
  25. }
  26. ::-webkit-scrollbar-thumb:hover {
  27. background: #a8a8a8;
  28. }
  29. /* 顶部导航栏 */
  30. .topbar {
  31. height: 64px;
  32. background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
  33. display: flex;
  34. align-items: center;
  35. padding: 0 24px;
  36. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  37. position: relative;
  38. z-index: 10;
  39. }
  40. .topbar::after {
  41. content: '';
  42. position: absolute;
  43. bottom: 0;
  44. left: 0;
  45. right: 0;
  46. height: 2px;
  47. background: linear-gradient(90deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.1) 100%);
  48. }
  49. .topbar-wrapper {
  50. width: 100%;
  51. display: flex;
  52. align-items: center;
  53. justify-content: space-between;
  54. }
  55. .logo {
  56. font-size: 22px;
  57. font-weight: 700;
  58. color: #fff;
  59. text-decoration: none;
  60. text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  61. letter-spacing: 0.5px;
  62. display: flex;
  63. align-items: center;
  64. gap: 8px;
  65. }
  66. .topbar-spacer {
  67. flex: 1;
  68. }
  69. .topbar-actions {
  70. display: flex;
  71. gap: 12px;
  72. align-items: center;
  73. }
  74. .config-button {
  75. padding: 10px 18px;
  76. background: rgba(255, 255, 255, 0.15);
  77. border: 1px solid rgba(255, 255, 255, 0.3);
  78. border-radius: 8px;
  79. font-size: 14px;
  80. color: #fff;
  81. cursor: pointer;
  82. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  83. display: flex;
  84. align-items: center;
  85. gap: 6px;
  86. backdrop-filter: blur(10px);
  87. font-weight: 500;
  88. }
  89. .config-button:hover {
  90. background: rgba(255, 255, 255, 0.25);
  91. border-color: rgba(255, 255, 255, 0.5);
  92. transform: translateY(-1px);
  93. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  94. }
  95. .config-button:active {
  96. transform: translateY(0);
  97. }
  98. .config-button:focus {
  99. outline: none;
  100. border-color: rgba(255, 255, 255, 0.7);
  101. box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
  102. }
  103. /* 内容布局容器 */
  104. .content-container {
  105. display: flex;
  106. height: calc(100vh - 64px);
  107. overflow: hidden;
  108. background-color: #f8f9fa;
  109. }
  110. /* 左侧菜单 */
  111. .menu-container {
  112. width: 300px;
  113. min-width: 220px;
  114. max-width: 500px;
  115. background-color: #fff;
  116. border-right: 1px solid #eef0f2;
  117. display: flex;
  118. flex-direction: column;
  119. overflow-y: auto;
  120. resize: horizontal;
  121. overflow-x: hidden;
  122. position: relative;
  123. box-shadow: 2px 0 8px rgba(0, 0, 0, 0.04);
  124. }
  125. .search-container {
  126. padding: 20px 16px 16px;
  127. border-bottom: 1px solid #eef0f2;
  128. background: linear-gradient(180deg, #fff 0%, #fafbfc 100%);
  129. }
  130. .search-input {
  131. width: 100%;
  132. padding: 10px 14px;
  133. border: 2px solid #eef0f2;
  134. border-radius: 10px;
  135. font-size: 14px;
  136. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  137. background-color: #fff;
  138. }
  139. .search-input::placeholder {
  140. color: #a0a0a0;
  141. }
  142. .search-input:hover {
  143. border-color: #d0d4d8;
  144. }
  145. .search-input:focus {
  146. outline: none;
  147. border-color: #667eea;
  148. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15);
  149. }
  150. .menu-list {
  151. list-style: none;
  152. flex: 1;
  153. }
  154. .menu-item {
  155. list-style: none;
  156. cursor: pointer;
  157. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  158. }
  159. .menu-item-content {
  160. padding: 14px 16px;
  161. display: flex;
  162. justify-content: space-between;
  163. align-items: center;
  164. border-left: 4px solid transparent;
  165. margin: 4px 0;
  166. }
  167. .menu-item:hover {
  168. background-color: #f8f9fa;
  169. }
  170. .menu-item.active .menu-item-content {
  171. background: linear-gradient(90deg, rgba(102, 126, 234, 0.1) 0%, rgba(102, 126, 234, 0.05) 100%);
  172. border-left-color: #667eea;
  173. }
  174. .menu-item-title {
  175. font-weight: 600;
  176. color: #2d3748;
  177. white-space: nowrap;
  178. overflow: hidden;
  179. text-overflow: ellipsis;
  180. }
  181. .menu-item-actions {
  182. display: flex;
  183. align-items: center;
  184. gap: 8px;
  185. }
  186. .count {
  187. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  188. color: #fff;
  189. font-size: 11px;
  190. font-weight: 600;
  191. padding: 4px 10px;
  192. border-radius: 12px;
  193. box-shadow: 0 2px 4px rgba(102, 126, 234, 0.3);
  194. }
  195. .arrow {
  196. font-size: 11px;
  197. color: #a0aec0;
  198. transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  199. }
  200. .submenu {
  201. list-style: none;
  202. max-height: 0;
  203. overflow: hidden;
  204. transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  205. }
  206. .submenu.show {
  207. max-height: 800px;
  208. transition: max-height 0.5s ease-in;
  209. }
  210. .api-item {
  211. padding: 10px 16px 10px 36px;
  212. border-left: 4px solid transparent;
  213. cursor: pointer;
  214. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  215. white-space: nowrap;
  216. overflow: hidden;
  217. text-overflow: ellipsis;
  218. margin: 2px 0;
  219. }
  220. .api-item:hover {
  221. background-color: #f7f9fc;
  222. }
  223. .api-item.active {
  224. background: linear-gradient(90deg, rgba(102, 126, 234, 0.08) 0%, rgba(102, 126, 234, 0.02) 100%);
  225. border-left-color: #667eea;
  226. }
  227. .api-item-content {
  228. display: flex;
  229. align-items: center;
  230. gap: 12px;
  231. }
  232. .method {
  233. display: inline-block;
  234. padding: 5px 12px;
  235. border-radius: 6px;
  236. font-size: 11px;
  237. font-weight: 700;
  238. flex-shrink: 0;
  239. letter-spacing: 0.5px;
  240. text-transform: uppercase;
  241. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  242. }
  243. .method.get {
  244. background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  245. color: #fff;
  246. }
  247. .method.post {
  248. background: linear-gradient(135deg, #27ae60 0%, #1e8449 100%);
  249. color: #fff;
  250. }
  251. .method.put {
  252. background: linear-gradient(135deg, #f39c12 0%, #d68910 100%);
  253. color: #fff;
  254. }
  255. .method.delete {
  256. background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
  257. color: #fff;
  258. }
  259. .method.patch {
  260. background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
  261. color: #fff;
  262. }
  263. /* 主内容区域 */
  264. .main-container {
  265. flex: 1;
  266. padding: 28px;
  267. overflow-y: auto;
  268. background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
  269. }
  270. .api-details {
  271. background-color: #fff;
  272. border-radius: 16px;
  273. box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  274. padding: 36px;
  275. }
  276. .api-header {
  277. margin-bottom: 6px;
  278. padding-bottom: 4px;
  279. }
  280. .api-title {
  281. font-size: 28px;
  282. margin-bottom: 0px;
  283. color: #1a202c;
  284. font-weight: 700;
  285. }
  286. .api-description {
  287. font-size: 15px;
  288. color: #718096;
  289. margin-bottom: 10px;
  290. line-height: 1.7;
  291. }
  292. .api-meta {
  293. display: flex;
  294. align-items: center;
  295. gap: 12px;
  296. font-size: 14px;
  297. color: #718096;
  298. flex-wrap: wrap;
  299. }
  300. .method-select {
  301. padding: 8px 14px;
  302. border: 2px solid #eef0f2;
  303. border-radius: 8px;
  304. font-size: 13px;
  305. font-weight: 600;
  306. cursor: pointer;
  307. background-color: #fff;
  308. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  309. appearance: none;
  310. -webkit-appearance: none;
  311. -moz-appearance: none;
  312. }
  313. .method-select:hover {
  314. border-color: #667eea;
  315. }
  316. .method-select:focus {
  317. outline: none;
  318. border-color: #667eea;
  319. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15);
  320. }
  321. .path-input {
  322. flex: 1;
  323. min-width: 300px;
  324. padding: 8px 14px;
  325. border: 2px solid #eef0f2;
  326. border-radius: 8px;
  327. font-size: 14px;
  328. font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Courier New', Courier, monospace;
  329. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  330. }
  331. .path-input:hover {
  332. border-color: #d0d4d8;
  333. }
  334. .path-input:focus {
  335. outline: none;
  336. border-color: #667eea;
  337. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15);
  338. }
  339. .send-button {
  340. padding: 8px 24px;
  341. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  342. color: #fff;
  343. border: none;
  344. border-radius: 8px;
  345. font-size: 14px;
  346. font-weight: 600;
  347. cursor: pointer;
  348. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  349. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  350. }
  351. .send-button:hover {
  352. transform: translateY(-2px);
  353. box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
  354. }
  355. .send-button:active {
  356. transform: translateY(0);
  357. }
  358. /* 章节容器 */
  359. .section-container {
  360. margin-bottom: 12px;
  361. }
  362. .section-title {
  363. font-size: 22px;
  364. margin-bottom: 8px;
  365. color: #1a202c;
  366. border-bottom: 2px solid #eef0f2;
  367. padding-bottom: 14px;
  368. font-weight: 700;
  369. }
  370. /* 标签页样式 */
  371. .tabs {
  372. display: flex;
  373. margin-bottom: 12px;
  374. border-bottom: 2px solid #eef0f2;
  375. background: linear-gradient(180deg, #fff 0%, #fafbfc 100%);
  376. padding: 0 16px;
  377. border-radius: 8px 8px 0 0;
  378. }
  379. .tab {
  380. padding: 14px 24px;
  381. background: transparent;
  382. border: none;
  383. cursor: pointer;
  384. font-size: 14px;
  385. font-weight: 500;
  386. position: relative;
  387. color: #718096;
  388. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  389. margin-right: 4px;
  390. border-bottom: 3px solid transparent;
  391. }
  392. .tab:hover {
  393. color: #667eea;
  394. background-color: rgba(102, 126, 234, 0.05);
  395. }
  396. .tab.active {
  397. color: #667eea;
  398. font-weight: 600;
  399. border-bottom-color: #667eea;
  400. background: linear-gradient(180deg, rgba(102, 126, 234, 0.08) 0%, rgba(102, 126, 234, 0.02) 100%);
  401. }
  402. .tab-content {
  403. overflow: hidden;
  404. }
  405. .tab-pane {
  406. display: none;
  407. }
  408. .tab-pane.active {
  409. display: block;
  410. }
  411. /* 参数表格样式 */
  412. .params-section {
  413. margin-bottom: 12px;
  414. }
  415. .params-table {
  416. width: 100%;
  417. border-collapse: collapse;
  418. table-layout: fixed;
  419. background-color: #fff;
  420. border-radius: 12px;
  421. overflow: hidden;
  422. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  423. border: 1px solid #eef0f2;
  424. }
  425. .params-table th,
  426. .params-table td {
  427. padding: 14px 18px;
  428. text-align: left;
  429. border-bottom: 1px solid #eef0f2;
  430. word-wrap: break-word;
  431. word-break: break-all;
  432. }
  433. .params-table th {
  434. background: linear-gradient(180deg, #f8f9fa 0%, #f0f2f5 100%);
  435. font-weight: 600;
  436. color: #2d3748;
  437. font-size: 13px;
  438. white-space: nowrap;
  439. text-transform: uppercase;
  440. letter-spacing: 0.5px;
  441. }
  442. .params-table td {
  443. color: #4a5568;
  444. font-size: 14px;
  445. }
  446. .params-table tr:last-child td {
  447. border-bottom: none;
  448. }
  449. .params-table tr:hover td {
  450. background-color: #f8f9fa;
  451. }
  452. /* 可编辑输入框样式 */
  453. .editable-input {
  454. width: 100%;
  455. padding: 8px 12px;
  456. border: 2px solid #eef0f2;
  457. border-radius: 6px;
  458. font-size: 14px;
  459. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  460. background-color: #fff;
  461. }
  462. .editable-input:hover {
  463. border-color: #d0d4d8;
  464. }
  465. .editable-input:focus {
  466. outline: none;
  467. border-color: #667eea;
  468. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
  469. }
  470. /* 操作按钮样式 */
  471. .action-buttons {
  472. display: flex;
  473. gap: 8px;
  474. justify-content: center;
  475. }
  476. .btn {
  477. padding: 6px 14px;
  478. border: none;
  479. border-radius: 6px;
  480. font-size: 12px;
  481. font-weight: 600;
  482. cursor: pointer;
  483. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  484. min-width: 60px;
  485. text-align: center;
  486. letter-spacing: 0.3px;
  487. }
  488. .btn-add {
  489. background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
  490. color: #fff;
  491. box-shadow: 0 2px 6px rgba(72, 187, 120, 0.3);
  492. }
  493. .btn-add:hover {
  494. transform: translateY(-1px);
  495. box-shadow: 0 4px 8px rgba(72, 187, 120, 0.4);
  496. }
  497. .btn-delete {
  498. background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%);
  499. color: #fff;
  500. box-shadow: 0 2px 6px rgba(245, 101, 101, 0.3);
  501. }
  502. .btn-delete:hover {
  503. transform: translateY(-1px);
  504. box-shadow: 0 4px 8px rgba(245, 101, 101, 0.4);
  505. }
  506. /* 表格操作区样式 */
  507. .table-actions {
  508. margin-top: 16px;
  509. display: flex;
  510. justify-content: flex-end;
  511. }
  512. /* 复选框容器样式 */
  513. .checkbox-container {
  514. display: flex;
  515. align-items: center;
  516. justify-content: center;
  517. }
  518. .checkbox-container input[type="checkbox"] {
  519. width: 16px;
  520. height: 16px;
  521. cursor: pointer;
  522. }
  523. /* 响应区域样式 */
  524. .response-section {
  525. background: linear-gradient(180deg, #fafbfc 0%, #f8f9fa 100%);
  526. border: 1px solid #eef0f2;
  527. border-radius: 12px;
  528. overflow: hidden;
  529. }
  530. .response-container {
  531. padding: 0px;
  532. }
  533. .response-header {
  534. display: flex;
  535. justify-content: flex-end;
  536. margin-bottom: 18px;
  537. }
  538. .response-select {
  539. padding: 8px 14px;
  540. border: 2px solid #eef0f2;
  541. border-radius: 8px;
  542. font-size: 14px;
  543. cursor: pointer;
  544. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  545. font-weight: 500;
  546. }
  547. .response-select:hover {
  548. border-color: #667eea;
  549. }
  550. .response-body {
  551. background-color: #1a202c;
  552. border: 1px solid #2d3748;
  553. border-radius: 10px;
  554. padding: 20px;
  555. max-height: 450px;
  556. overflow-y: auto;
  557. box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.3);
  558. }
  559. .response-body pre {
  560. margin: 0;
  561. white-space: pre-wrap;
  562. word-wrap: break-word;
  563. }
  564. .response-body code {
  565. font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Courier New', Courier, monospace;
  566. font-size: 13px;
  567. line-height: 1.6;
  568. color: #e2e8f0;
  569. }
  570. /* JSON编辑器样式 */
  571. .json-editor-container {
  572. margin-bottom: 20px;
  573. }
  574. .json-editor {
  575. width: 100%;
  576. min-height: 220px;
  577. padding: 18px;
  578. border: 2px solid #eef0f2;
  579. border-radius: 10px;
  580. font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Courier New', Courier, monospace;
  581. font-size: 13px;
  582. line-height: 1.6;
  583. resize: vertical;
  584. background-color: #fafbfc;
  585. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  586. color: #2d3748;
  587. }
  588. .json-editor:hover {
  589. border-color: #d0d4d8;
  590. }
  591. .json-editor:focus {
  592. outline: none;
  593. border-color: #667eea;
  594. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
  595. background-color: #fff;
  596. }
  597. /* 空状态样式 */
  598. .empty-body {
  599. text-align: center;
  600. color: #a0aec0;
  601. padding: 48px 0;
  602. background: linear-gradient(180deg, #fafbfc 0%, #f8f9fa 100%);
  603. border: 2px dashed #e2e8f0;
  604. border-radius: 12px;
  605. font-size: 15px;
  606. font-weight: 500;
  607. }
  608. /* 配置对话框样式 */
  609. .config-dialog-overlay {
  610. position: fixed;
  611. top: 0;
  612. left: 0;
  613. right: 0;
  614. bottom: 0;
  615. background-color: rgba(0, 0, 0, 0.6);
  616. backdrop-filter: blur(4px);
  617. display: flex;
  618. align-items: center;
  619. justify-content: center;
  620. z-index: 1000;
  621. animation: fadeIn 0.25s ease;
  622. }
  623. @keyframes fadeIn {
  624. from { opacity: 0; }
  625. to { opacity: 1; }
  626. }
  627. .config-dialog {
  628. background-color: #fff;
  629. border-radius: 16px;
  630. box-shadow: 0 16px 48px rgba(0, 0, 0, 0.25);
  631. width: 640px;
  632. max-width: 90%;
  633. max-height: 80vh;
  634. overflow: hidden;
  635. animation: slideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  636. }
  637. @keyframes slideIn {
  638. from {
  639. opacity: 0;
  640. transform: translateY(-30px) scale(0.95);
  641. }
  642. to {
  643. opacity: 1;
  644. transform: translateY(0) scale(1);
  645. }
  646. }
  647. .config-dialog-header {
  648. display: flex;
  649. justify-content: space-between;
  650. align-items: center;
  651. padding: 24px 28px;
  652. border-bottom: 2px solid #eef0f2;
  653. background: linear-gradient(180deg, #fff 0%, #fafbfc 100%);
  654. }
  655. .config-dialog-header h3 {
  656. font-size: 20px;
  657. color: #1a202c;
  658. margin: 0;
  659. font-weight: 700;
  660. }
  661. .close-button {
  662. background: none;
  663. border: none;
  664. font-size: 26px;
  665. color: #a0aec0;
  666. cursor: pointer;
  667. width: 36px;
  668. height: 36px;
  669. display: flex;
  670. align-items: center;
  671. justify-content: center;
  672. border-radius: 8px;
  673. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  674. }
  675. .close-button:hover {
  676. background-color: #f8f9fa;
  677. color: #e53e3e;
  678. transform: rotate(90deg);
  679. }
  680. .config-dialog-body {
  681. padding: 28px;
  682. overflow-y: auto;
  683. max-height: calc(80vh - 160px);
  684. }
  685. .config-table {
  686. width: 100%;
  687. border-collapse: collapse;
  688. }
  689. .config-table th {
  690. background: linear-gradient(180deg, #f8f9fa 0%, #f0f2f5 100%);
  691. padding: 14px 16px;
  692. text-align: left;
  693. font-weight: 600;
  694. color: #2d3748;
  695. border-bottom: 2px solid #eef0f2;
  696. font-size: 13px;
  697. text-transform: uppercase;
  698. letter-spacing: 0.5px;
  699. }
  700. .config-table td {
  701. padding: 12px 16px;
  702. border-bottom: 1px solid #eef0f2;
  703. }
  704. .config-input {
  705. width: 100%;
  706. padding: 10px 14px;
  707. border: 2px solid #eef0f2;
  708. border-radius: 8px;
  709. font-size: 14px;
  710. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  711. background-color: #fff;
  712. }
  713. .config-input:hover {
  714. border-color: #d0d4d8;
  715. }
  716. .config-input:focus {
  717. outline: none;
  718. border-color: #667eea;
  719. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
  720. }
  721. .config-dialog-footer {
  722. padding: 24px 28px;
  723. border-top: 2px solid #eef0f2;
  724. display: flex;
  725. justify-content: flex-end;
  726. gap: 14px;
  727. background: linear-gradient(180deg, #fafbfc 0%, #fff 100%);
  728. }
  729. .btn-primary {
  730. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  731. color: #fff;
  732. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  733. }
  734. .btn-primary:hover {
  735. transform: translateY(-2px);
  736. box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
  737. }
  738. .btn-primary:active {
  739. transform: translateY(0);
  740. }
  741. /* 通知样式 */
  742. .notification {
  743. position: fixed;
  744. top: 80px;
  745. right: 28px;
  746. padding: 16px 24px;
  747. background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
  748. color: #fff;
  749. border-radius: 12px;
  750. box-shadow: 0 8px 24px rgba(72, 187, 120, 0.4);
  751. font-size: 14px;
  752. font-weight: 500;
  753. opacity: 0;
  754. transform: translateX(100px);
  755. transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  756. z-index: 1001;
  757. display: flex;
  758. align-items: center;
  759. gap: 10px;
  760. }
  761. .notification.show {
  762. opacity: 1;
  763. transform: translateX(0);
  764. }
  765. .notification::before {
  766. content: '✓';
  767. font-size: 18px;
  768. font-weight: bold;
  769. }
  770. /* 响应式设计 */
  771. @media (max-width: 768px) {
  772. .content-container {
  773. flex-direction: column;
  774. }
  775. .menu-container {
  776. width: 100%;
  777. height: 240px;
  778. border-right: none;
  779. border-bottom: 1px solid #eef0f2;
  780. }
  781. .main-container {
  782. padding: 20px;
  783. }
  784. .api-details {
  785. padding: 24px;
  786. }
  787. .api-meta {
  788. flex-direction: column;
  789. align-items: stretch;
  790. }
  791. .path-input {
  792. min-width: auto;
  793. }
  794. .tabs {
  795. overflow-x: auto;
  796. white-space: nowrap;
  797. }
  798. .params-table {
  799. display: block;
  800. overflow-x: auto;
  801. }
  802. .config-dialog {
  803. width: 95%;
  804. max-height: 90vh;
  805. }
  806. }
  807. /* 添加更多视觉增强 */
  808. .api-item .api-summary {
  809. color: #4a5568;
  810. font-size: 13px;
  811. overflow: hidden;
  812. text-overflow: ellipsis;
  813. white-space: nowrap;
  814. }
  815. /* 表格操作区样式 */
  816. .table-actions {
  817. margin-top: 18px;
  818. display: flex;
  819. justify-content: flex-end;
  820. }
  821. /* 复选框容器样式 */
  822. .checkbox-container {
  823. display: flex;
  824. align-items: center;
  825. justify-content: center;
  826. }
  827. .checkbox-container input[type="checkbox"] {
  828. width: 18px;
  829. height: 18px;
  830. cursor: pointer;
  831. accent-color: #667eea;
  832. border-radius: 4px;
  833. }
  834. /* 添加加载动画 */
  835. @keyframes pulse {
  836. 0%, 100% { opacity: 1; }
  837. 50% { opacity: 0.5; }
  838. }
  839. .loading {
  840. animation: pulse 1.5s ease-in-out infinite;
  841. }