export-view.css 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. body {
  2. margin: 0;
  3. padding: 0;
  4. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  5. background: transparent;
  6. overflow: hidden;
  7. }
  8. .export-container {
  9. width: 100%;
  10. height: 100vh;
  11. display: flex;
  12. flex-direction: column;
  13. background: white;
  14. border-radius: 16px;
  15. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  16. max-width: 900px;
  17. max-height: 80vh;
  18. margin: 0 auto;
  19. }
  20. .export-header {
  21. padding: 24px 32px;
  22. border-bottom: 1px solid #e5e7eb;
  23. }
  24. .export-header h2 {
  25. margin: 0;
  26. font-size: 20px;
  27. font-weight: 600;
  28. color: #1f2937;
  29. }
  30. .export-content {
  31. flex: 1;
  32. padding: 24px 32px;
  33. overflow-y: auto;
  34. display: flex;
  35. flex-direction: column;
  36. gap: 24px;
  37. }
  38. .export-section h3 {
  39. margin: 0 0 12px 0;
  40. font-size: 15px;
  41. font-weight: 600;
  42. color: #374151;
  43. }
  44. /* Spritesheet 预览 */
  45. .preview-box {
  46. width: 100%;
  47. min-height: 300px;
  48. background: repeating-conic-gradient(#f3f4f6 0% 25%, white 0% 50%) 50% / 20px 20px;
  49. border: 2px solid #e5e7eb;
  50. border-radius: 8px;
  51. display: flex;
  52. align-items: center;
  53. justify-content: center;
  54. position: relative;
  55. overflow: auto;
  56. }
  57. #spritesheetCanvas {
  58. max-width: 100%;
  59. max-height: 100%;
  60. display: none;
  61. }
  62. #spritesheetCanvas.show {
  63. display: block;
  64. }
  65. .preview-placeholder {
  66. position: absolute;
  67. color: #9ca3af;
  68. font-size: 15px;
  69. }
  70. .preview-placeholder.hide {
  71. display: none;
  72. }
  73. /* 参考图上传 */
  74. .reference-upload {
  75. width: 100%;
  76. }
  77. .reference-preview {
  78. width: 100%;
  79. height: 200px;
  80. border: 2px dashed #d1d5db;
  81. border-radius: 8px;
  82. display: flex;
  83. align-items: center;
  84. justify-content: center;
  85. cursor: pointer;
  86. transition: all 0.2s;
  87. background: #f9fafb;
  88. }
  89. .reference-preview:hover {
  90. border-color: #9ca3af;
  91. background: #f3f4f6;
  92. }
  93. .reference-preview.has-image {
  94. border-style: solid;
  95. border-color: #667eea;
  96. background: white;
  97. }
  98. .upload-hint {
  99. display: flex;
  100. flex-direction: column;
  101. align-items: center;
  102. gap: 8px;
  103. color: #9ca3af;
  104. }
  105. .upload-hint svg {
  106. color: #d1d5db;
  107. }
  108. .upload-hint p {
  109. margin: 0;
  110. font-size: 14px;
  111. }
  112. .reference-preview img {
  113. max-width: 100%;
  114. max-height: 100%;
  115. object-fit: contain;
  116. }
  117. /* 操作按钮 */
  118. .export-actions {
  119. padding: 20px 32px;
  120. border-top: 1px solid #e5e7eb;
  121. display: flex;
  122. gap: 12px;
  123. justify-content: flex-end;
  124. }
  125. .export-btn {
  126. padding: 12px 28px;
  127. border: none;
  128. border-radius: 8px;
  129. font-size: 15px;
  130. cursor: pointer;
  131. transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  132. font-weight: 500;
  133. letter-spacing: 0.3px;
  134. min-width: 100px;
  135. }
  136. .export-cancel {
  137. background: #f3f4f6;
  138. color: #6b7280;
  139. border: 1px solid #e5e7eb;
  140. }
  141. .export-cancel:hover {
  142. background: #e5e7eb;
  143. color: #4b5563;
  144. border-color: #d1d5db;
  145. }
  146. .export-cancel:active {
  147. transform: scale(0.98);
  148. }
  149. .export-confirm {
  150. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  151. color: white;
  152. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  153. }
  154. .export-confirm:hover {
  155. box-shadow: 0 6px 16px rgba(102, 126, 234, 0.5);
  156. transform: translateY(-1px);
  157. }
  158. .export-confirm:active {
  159. transform: translateY(0) scale(0.98);
  160. }
  161. .export-confirm:disabled {
  162. background: #d1d5db;
  163. color: #9ca3af;
  164. box-shadow: none;
  165. cursor: not-allowed;
  166. transform: none;
  167. }