update pay function

This commit is contained in:
2025-11-22 07:24:55 +08:00
parent b9ed0f5449
commit 990ca3663e
2 changed files with 79 additions and 122 deletions

View File

@@ -54,13 +54,11 @@ import { WatchlistMenu, FollowingEventsMenu } from './components/FeatureMenus';
import { useWatchlist } from '../../hooks/useWatchlist';
import { useFollowingEvents } from '../../hooks/useFollowingEvents';
// Phase 7 优化: 提取的二级导航、资料完整性、右侧功能区组件
import SecondaryNav from './components/SecondaryNav';
// Phase 7 优化: 提取的资料完整性、右侧功能区组件
import ProfileCompletenessAlert from './components/ProfileCompletenessAlert';
import { useProfileCompleteness } from '../../hooks/useProfileCompleteness';
import NavbarActions from './components/NavbarActions';
// Phase 7: SecondaryNav 组件已提取到 ./components/SecondaryNav/index.js
// Phase 4: MoreNavMenu 和 NavItems 组件已提取到 Navigation 目录
export default function HomeNavbar() {
@@ -207,9 +205,6 @@ export default function HomeNavbar() {
/>
</Box>
{/* 二级导航栏 - 显示当前页面所属的二级菜单 */}
{!isMobile && <SecondaryNav showCompletenessAlert={showCompletenessAlert} />}
{/* 投资日历 Modal - 已移至 CalendarButton 组件内部 */}
</>
);

View File

@@ -980,127 +980,89 @@ const AgentChatV4 = () => {
{/* 主聊天区域 */}
<Flex flex="1" direction="column" h="100%" position="relative">
{/* 聊天头部 */}
<Box
bg={glassBg}
backdropFilter="blur(20px)"
{/* 顶部操作栏 - 简化版 */}
<HStack
px={4}
py={2}
borderBottom="1px solid"
borderColor={borderGold}
px={{ base: 2, md: 4 }}
py={{ base: 2, md: 2 }}
minH={{ base: "56px", md: "64px" }}
boxShadow="0 4px 16px rgba(255, 215, 0, 0.1)"
bg={glassBg}
backdropFilter="blur(20px)"
justify="space-between"
flexShrink={0}
zIndex={10}
>
<Flex justify="space-between" align="center" h="full">
<HStack spacing={{ base: 2, md: 3 }} align="center" flex={1} minW={0}>
<Box
w={{ base: "24px", md: "32px" }}
h={{ base: "24px", md: "32px" }}
borderRadius="lg"
bg={goldGradient}
display="flex"
alignItems="center"
justifyContent="center"
boxShadow="0 4px 12px rgba(255, 215, 0, 0.3)"
flexShrink={0}
>
<FiCpu fontSize={{ base: "0.9rem", md: "1.2rem" }} color={darkBg} />
</Box>
<VStack align="start" spacing={0} flex={1} minW={0}>
<HStack spacing={2} align="baseline">
<Heading
size={{ base: "xs", md: "sm" }}
color={textWhite}
noOfLines={1}
>
价小前投研
</Heading>
<Badge
bg="rgba(255, 215, 0, 0.2)"
color={goldAccent}
fontSize={{ base: "xx-small", md: "xs" }}
borderRadius="full"
px={{ base: 1, md: 2 }}
whiteSpace="nowrap"
display="inline-flex"
alignItems="center"
gap={1}
>
<Box as={FiZap} display="inline-block" width="10px" height="10px" />
<Text as="span" fontSize="inherit">AI 深度分析</Text>
</Badge>
</HStack>
<Text
fontSize={{ base: "xx-small", md: "xs" }}
color={textGray}
display={{ base: "none", lg: "block" }}
noOfLines={1}
>
{AVAILABLE_MODELS.find(m => m.id === selectedModel)?.name || '智能模型'}
</Text>
</VStack>
</HStack>
<HStack spacing={{ base: 1, md: 2 }} flexShrink={0}>
<IconButton
icon={<FiMessageSquare />}
size="sm"
variant="ghost"
color={goldAccent}
_hover={{ bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="历史对话"
onClick={toggleSidebar}
/>
<IconButton
icon={<FiRefreshCw />}
size="sm"
variant="ghost"
color={textGray}
_hover={{ color: goldAccent, bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="清空对话"
onClick={handleClearChat}
/>
<IconButton
icon={<FiDownload />}
size="sm"
variant="ghost"
color={textGray}
_hover={{ color: goldAccent, bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="导出对话"
onClick={handleExportChat}
display={{ base: "none", sm: "inline-flex" }}
/>
<IconButton
icon={<FiSettings />}
size="sm"
variant="ghost"
color={goldAccent}
_hover={{ bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="设置"
onClick={toggleRightPanel}
/>
</HStack>
</Flex>
{/* 进度条 */}
{isProcessing && (
<Progress
value={currentProgress}
size="xs"
mt={3}
borderRadius="full"
bg="rgba(255, 255, 255, 0.1)"
sx={{
'& > div': {
background: goldGradient,
},
}}
isAnimated
{/* 左侧 - 标题和模型显示 */}
<HStack spacing={3}>
<IconButton
icon={<FiMessageSquare />}
size="sm"
variant="ghost"
color={goldAccent}
_hover={{ bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="历史对话"
onClick={toggleSidebar}
/>
)}
</Box>
<Text fontSize="sm" color={textWhite} fontWeight="medium">
价小前 AI
</Text>
<Badge
bg="rgba(255, 215, 0, 0.2)"
color={goldAccent}
fontSize="xs"
borderRadius="full"
px={2}
>
{AVAILABLE_MODELS.find(m => m.id === selectedModel)?.name || '智能模型'}
</Badge>
</HStack>
{/* 右侧 - 操作按钮 */}
<HStack spacing={1}>
<IconButton
icon={<FiRefreshCw />}
size="sm"
variant="ghost"
color={textGray}
_hover={{ color: goldAccent, bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="清空对话"
onClick={handleClearChat}
/>
<IconButton
icon={<FiDownload />}
size="sm"
variant="ghost"
color={textGray}
_hover={{ color: goldAccent, bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="导出对话"
onClick={handleExportChat}
/>
<IconButton
icon={<FiSettings />}
size="sm"
variant="ghost"
color={goldAccent}
_hover={{ bg: 'rgba(255, 215, 0, 0.1)' }}
aria-label="设置"
onClick={toggleRightPanel}
/>
</HStack>
</HStack>
{/* 进度条 */}
{isProcessing && (
<Progress
value={currentProgress}
size="xs"
borderRadius="full"
bg="rgba(255, 255, 255, 0.1)"
sx={{
'& > div': {
background: goldGradient,
},
}}
isAnimated
/>
)}
{/* 消息列表 */}
<Box