diff --git a/video-gen-app/src/pages/GenerateConver.tsx b/video-gen-app/src/pages/GenerateConver.tsx index 7483e1f0..9069f221 100644 --- a/video-gen-app/src/pages/GenerateConver.tsx +++ b/video-gen-app/src/pages/GenerateConver.tsx @@ -1,7 +1,7 @@ import React, { useState, useRef, useEffect, useCallback } from 'react'; -// AI 创作对话框样式优化版 v11:白色极简高级风格,统一参考素材与历史附件展示。 +// AI 创作对话框样式优化版 v12:白色极简高级风格,选项按钮、标题、头像与关键字统一使用 #8b5cf6。 import { Layout, @@ -1276,7 +1276,7 @@ const AIChatPage: React.FC = () => { style={{ background: 'rgba(255,255,255,0.7)', backdropFilter: 'blur(16px)', - borderRight: '1px solid rgba(75, 85, 99, 0.08)', + borderRight: '1px solid rgba(139, 92, 246, 0.08)', }} >
@@ -1313,7 +1313,7 @@ const AIChatPage: React.FC = () => { borderRadius: 10, cursor: 'pointer', background: currentConversationId === conversation.id ? '#FAFBFC' : 'transparent', - border: currentConversationId === conversation.id ? '1px solid #e6e1ea' : 'none', + border: currentConversationId === conversation.id ? '1px solid #ede9fe' : 'none', transition: 'all 0.2s', }} onMouseEnter={(e) => { @@ -1371,7 +1371,7 @@ const AIChatPage: React.FC = () => { margin: 0, fontSize: 18, fontWeight: 700, - color: '#4B5563', + color: '#8b5cf6', letterSpacing: 0.4, }}> AI创作 @@ -1406,7 +1406,7 @@ const AIChatPage: React.FC = () => { width: 80, height: 80, borderRadius: 50, - background: 'linear-gradient(135deg, #4B5563 0%, #D6DAE2 100%)', + background: 'linear-gradient(135deg, #8b5cf6 0%, #ddd6fe 100%)', display: 'flex', alignItems: 'center', justifyContent: 'center', @@ -1448,7 +1448,7 @@ const AIChatPage: React.FC = () => { disabled={isLoadingMore} style={{ fontSize: 12, - color: '#4B5563', + color: '#8b5cf6', background: 'none', border: 'none', cursor: isLoadingMore ? 'not-allowed' : 'pointer', @@ -1478,7 +1478,7 @@ const AIChatPage: React.FC = () => { width: 36, height: 36, borderRadius: 12, - background: 'linear-gradient(135deg, #4B5563 0%, #D6DAE2 100%)', + background: 'linear-gradient(135deg, #8b5cf6 0%, #ddd6fe 100%)', display: 'flex', alignItems: 'center', justifyContent: 'center', @@ -1513,8 +1513,8 @@ const AIChatPage: React.FC = () => {
{msg.createdAt?.replace('T', ' ').split('.')[0]} { {/* 附件详情 - 右上角 */} {msg.mediaReferences && msg.mediaReferences.length > 0 && (
- { e.stopPropagation(); const target = e.currentTarget as HTMLElement; const rect = target.getBoundingClientRect(); setAttachmentPopupPosition({ x: rect.left, y: rect.top - 10 }); setAttachmentPopupMessageId(msg.id); setAttachmentPopupVisible(true); }}>附件详情 + { e.stopPropagation(); const target = e.currentTarget as HTMLElement; const rect = target.getBoundingClientRect(); setAttachmentPopupPosition({ x: rect.left, y: rect.top - 10 }); setAttachmentPopupMessageId(msg.id); setAttachmentPopupVisible(true); }}>附件详情
)} {/* 操作按钮 - 右下角 */} @@ -1569,8 +1569,8 @@ const AIChatPage: React.FC = () => { padding: '0 10px', borderRadius: 10, border: 'none', - background: 'rgba(75, 85, 99, 0.08)', - color: '#4B5563', + background: 'rgba(139, 92, 246, 0.08)', + color: '#8b5cf6', cursor: 'pointer', display: 'flex', alignItems: 'center', @@ -1580,10 +1580,10 @@ const AIChatPage: React.FC = () => { fontSize: 12, }} onMouseEnter={(e) => { - e.currentTarget.style.background = 'rgba(75, 85, 99, 0.15)'; + e.currentTarget.style.background = 'rgba(139, 92, 246, 0.15)'; }} onMouseLeave={(e) => { - e.currentTarget.style.background = 'rgba(75, 85, 99, 0.08)'; + e.currentTarget.style.background = 'rgba(139, 92, 246, 0.08)'; }} > @@ -1614,8 +1614,8 @@ const AIChatPage: React.FC = () => { padding: '0 10px', borderRadius: 10, border: 'none', - background: 'rgba(75, 85, 99, 0.08)', - color: '#4B5563', + background: 'rgba(139, 92, 246, 0.08)', + color: '#8b5cf6', cursor: 'pointer', display: 'flex', alignItems: 'center', @@ -1629,8 +1629,8 @@ const AIChatPage: React.FC = () => { e.currentTarget.style.color = '#A45B5B'; }} onMouseLeave={(e) => { - e.currentTarget.style.background = 'rgba(75, 85, 99, 0.08)'; - e.currentTarget.style.color = '#4B5563'; + e.currentTarget.style.background = 'rgba(139, 92, 246, 0.08)'; + e.currentTarget.style.color = '#8b5cf6'; }} > @@ -1646,9 +1646,9 @@ const AIChatPage: React.FC = () => { position: 'relative', margin: '8px 0', padding: '12px 16px', - backgroundColor: 'rgba(75, 85, 99, 0.04)', + backgroundColor: 'rgba(139, 92, 246, 0.04)', borderRadius: 10, - border: '1px solid rgba(75, 85, 99, 0.08)', + border: '1px solid rgba(139, 92, 246, 0.08)', fontSize: 13, color: '#475467', lineHeight: 1.6, @@ -1699,23 +1699,23 @@ const AIChatPage: React.FC = () => {
-
+
{msg.status === 'generating' ? ( <>
- {/*
*/} + {/*
*/}
-
-
+
+
- 生成中... + 生成中... {/*
-
+
-
+
*/}
@@ -1750,15 +1750,15 @@ const AIChatPage: React.FC = () => {
{msg.engineSnapshot.name} + // background: 'rgba(139, 92, 246, 0.08)', + borderRadius: 16, color: '#8b5cf6', fontWeight: 500 }}>{msg.engineSnapshot.name} {msg.genType === 'image' ? `${msg.imageProportion || ''} · ${msg.imagePx || ''} · ${msg.imageSize || ''}` : `${msg.duration || ''}s · ${msg.aspectRatio || ''} · ${msg.resolution || ''}`} 消耗积分:{msg.creditsCost} + borderRadius: 16, color: '#8b5cf6' }}>消耗积分:{msg.creditsCost}
@@ -1917,7 +1917,7 @@ const AIChatPage: React.FC = () => {
)} - + {label}
@@ -1939,7 +1939,7 @@ const AIChatPage: React.FC = () => { borderRadius: 9, border: '1px solid #E7EAF0', background: '#F8FAFC', - color: '#4B5563', + color: '#8b5cf6', fontSize: 11, fontWeight: 700, cursor: 'pointer', @@ -2004,7 +2004,7 @@ const AIChatPage: React.FC = () => { {/* 首帧 */}
- 首帧 + 首帧 必传
{firstFrame ? ( @@ -2018,7 +2018,7 @@ const AIChatPage: React.FC = () => { setAttachmentPreviewName(firstFrame.name); setAttachmentPreviewVisible(true); }} - style={{ width: '100%', height: '100%', objectFit: 'cover', borderRadius: 10, cursor: 'pointer', border: '1px solid rgba(75, 85, 99, 0.2)', boxShadow: '0 4px 12px rgba(47, 52, 64, 0.08)' }} + style={{ width: '100%', height: '100%', objectFit: 'cover', borderRadius: 10, cursor: 'pointer', border: '1px solid rgba(139, 92, 246, 0.2)', boxShadow: '0 4px 12px rgba(47, 52, 64, 0.08)' }} /> {showEngineModal && ( @@ -2565,10 +2565,10 @@ const AIChatPage: React.FC = () => { minHeight: 48, borderRadius: 10, border: countType === engine.id - ? '1px solid #4B5563' + ? '1px solid #8b5cf6' : '1px solid #E7EAF0', backgroundColor: countType === engine.id - ? '#F6F7FA' + ? '#f5f3ff' : '#ffffff', cursor: 'pointer', display: 'flex', @@ -2583,7 +2583,7 @@ const AIChatPage: React.FC = () => { {engine.name} @@ -2632,7 +2632,7 @@ const AIChatPage: React.FC = () => { e.currentTarget.style.boxShadow = '0 1px 2px rgba(47, 52, 64, 0.03)'; }} > - + { }}> {referenceMode === 'universal' ? '全能参考' : '首尾帧'} - + {referenceModeDropdownVisible && ( @@ -2681,10 +2681,10 @@ const AIChatPage: React.FC = () => { padding: '10px 14px', borderRadius: 10, border: referenceMode === 'universal' - ? '1px solid rgba(75, 85, 99, 0.3)' + ? '1px solid rgba(139, 92, 246, 0.3)' : '1px solid transparent', backgroundColor: referenceMode === 'universal' - ? 'rgba(75, 85, 99, 0.08)' + ? 'rgba(139, 92, 246, 0.08)' : 'transparent', cursor: supportsUniversalReference ? 'pointer' : 'not-allowed', display: 'flex', @@ -2696,7 +2696,7 @@ const AIChatPage: React.FC = () => { }} onMouseEnter={(e) => { if (supportsUniversalReference && referenceMode !== 'universal') { - e.currentTarget.style.backgroundColor = 'rgba(75, 85, 99, 0.04)'; + e.currentTarget.style.backgroundColor = 'rgba(139, 92, 246, 0.04)'; } }} onMouseLeave={(e) => { @@ -2705,11 +2705,11 @@ const AIChatPage: React.FC = () => { } }} > - + 全能参考 @@ -2726,10 +2726,10 @@ const AIChatPage: React.FC = () => { padding: '10px 14px', borderRadius: 10, border: referenceMode === 'first_last_frame' - ? '1px solid rgba(75, 85, 99, 0.3)' + ? '1px solid rgba(139, 92, 246, 0.3)' : '1px solid transparent', backgroundColor: referenceMode === 'first_last_frame' - ? 'rgba(75, 85, 99, 0.08)' + ? 'rgba(139, 92, 246, 0.08)' : 'transparent', cursor: supportsFirstLastFrame ? 'pointer' : 'not-allowed', display: 'flex', @@ -2741,7 +2741,7 @@ const AIChatPage: React.FC = () => { }} onMouseEnter={(e) => { if (supportsFirstLastFrame && referenceMode !== 'first_last_frame') { - e.currentTarget.style.backgroundColor = 'rgba(75, 85, 99, 0.04)'; + e.currentTarget.style.backgroundColor = 'rgba(139, 92, 246, 0.04)'; } }} onMouseLeave={(e) => { @@ -2750,11 +2750,11 @@ const AIChatPage: React.FC = () => { } }} > - + 首尾帧 @@ -2800,7 +2800,7 @@ const AIChatPage: React.FC = () => { e.currentTarget.style.boxShadow = '0 1px 2px rgba(47, 52, 64, 0.03)'; }} > - + { }}> {selectedRatio === 'auto' ? '智能' : selectedRatio} · {selectedResolution == '2K' ? '2K高清' : '4K超清'} · {width}×{height} - + {showImageSettingsModal && ( @@ -2858,10 +2858,10 @@ const AIChatPage: React.FC = () => { height: 52, borderRadius: 6, border: selectedRatio === item.value - ? '2px solid #4B5563' + ? '2px solid #8b5cf6' : '1px solid #E7EAF0', backgroundColor: selectedRatio === item.value - ? '#fff' + ? '#f5f3ff' : '#FFFFFF', cursor: 'pointer', display: 'flex', @@ -2884,7 +2884,7 @@ const AIChatPage: React.FC = () => { if (h >= w) return maxSize; return Math.round(maxSize * (h / w)); })(), - border: `2px solid ${selectedRatio === item.value ? '#4B5563' : '#98a2b3'}`, + border: `2px solid ${selectedRatio === item.value ? '#8b5cf6' : '#98a2b3'}`, borderRadius: 2, marginBottom: 2, display: 'flex', @@ -2895,7 +2895,7 @@ const AIChatPage: React.FC = () => { 智 @@ -2905,7 +2905,7 @@ const AIChatPage: React.FC = () => { @@ -2940,10 +2940,10 @@ const AIChatPage: React.FC = () => { height: 42, borderRadius: 6, border: selectedResolution === item.value - ? '2px solid #4B5563' + ? '2px solid #8b5cf6' : '1px solid #E7EAF0', backgroundColor: selectedResolution === item.value - ? '#4B5563' + ? '#8b5cf6' : '#FFFFFF', cursor: 'pointer', display: 'flex', @@ -3027,7 +3027,7 @@ const AIChatPage: React.FC = () => { display: 'flex', justifyContent: 'center', alignItems: 'center', - color: '#4B5563', + color: '#8b5cf6', }} > @@ -3157,10 +3157,10 @@ const AIChatPage: React.FC = () => { height: 52, borderRadius: 6, border: videoAspectRatio === ratio - ? '2px solid #4B5563' + ? '2px solid #8b5cf6' : '1px solid #E7EAF0', backgroundColor: videoAspectRatio === ratio - ? '#fff' + ? '#f5f3ff' : '#FFFFFF', cursor: 'pointer', display: 'flex', @@ -3183,14 +3183,14 @@ const AIChatPage: React.FC = () => { if (h >= w) return maxSize; return Math.round(maxSize * (h / w)); })(), - border: `2px solid ${videoAspectRatio === ratio ? '#4B5563' : '#98a2b3'}`, + border: `2px solid ${videoAspectRatio === ratio ? '#8b5cf6' : '#98a2b3'}`, borderRadius: 2, marginBottom: 2, }} /> @@ -3232,7 +3232,7 @@ const AIChatPage: React.FC = () => { left: 0, height: 6, borderRadius: 3, - background: '#4B5563', + background: '#8b5cf6', width: `${((videoDuration - Math.min(...engineOptions.durations)) / (Math.max(...engineOptions.durations) - Math.min(...engineOptions.durations))) * 100}%`, transform: 'translateY(-50%)', }} /> @@ -3294,10 +3294,10 @@ const AIChatPage: React.FC = () => { height: 42, borderRadius: 6, border: videoResolution === resolution - ? '2px solid #4B5563' + ? '2px solid #8b5cf6' : '1px solid #E7EAF0', backgroundColor: videoResolution === resolution - ? '#4B5563' + ? '#8b5cf6' : '#FFFFFF', cursor: 'pointer', display: 'flex', @@ -3323,31 +3323,6 @@ const AIChatPage: React.FC = () => { )}
)} -
@@ -3368,11 +3343,11 @@ const AIChatPage: React.FC = () => { height: 36, borderRadius: '50%', background: composerCanSend - ? 'linear-gradient(135deg, #4B5563 0%, #6B7280 100%)' + ? 'linear-gradient(135deg, #8b5cf6 0%, #a78bfa 100%)' : '#E7EAF0', color: '#ffffff', opacity: composerCanSend ? 1 : 0.86, - boxShadow: composerCanSend ? '0 10px 24px rgba(75, 85, 99, 0.28)' : 'inset 0 0 0 1px rgba(75, 85, 99, 0.18)', + boxShadow: composerCanSend ? '0 10px 24px rgba(139, 92, 246, 0.28)' : 'inset 0 0 0 1px rgba(139, 92, 246, 0.18)', cursor: composerCanSend ? 'pointer' : 'not-allowed', transition: 'all 0.2s ease', border: 'none', @@ -3386,6 +3361,12 @@ const AIChatPage: React.FC = () => { {/* 自定义CSS动画 - 加载中闪烁效果 */}