update pay ui
This commit is contained in:
115
src/views/Company/config.ts
Normal file
115
src/views/Company/config.ts
Normal file
@@ -0,0 +1,115 @@
|
||||
/**
|
||||
* Company 页面配置
|
||||
* - 黑金主题配置
|
||||
* - Tab 配置
|
||||
*/
|
||||
|
||||
import { lazy } from 'react';
|
||||
import { Building2, TrendingUp, Wallet, FileBarChart } from 'lucide-react';
|
||||
import type { CompanyTheme, TabConfig } from './types';
|
||||
|
||||
// ============================================
|
||||
// 黑金主题配置
|
||||
// ============================================
|
||||
|
||||
export const THEME: CompanyTheme = {
|
||||
// 背景色
|
||||
bg: '#1A1A2E',
|
||||
cardBg: '#16213E',
|
||||
|
||||
// 金色系
|
||||
gold: '#D4AF37',
|
||||
goldLight: '#F0D78C',
|
||||
goldDark: '#B8960C',
|
||||
|
||||
// 文字色
|
||||
textPrimary: '#FFFFFF',
|
||||
textSecondary: 'rgba(255, 255, 255, 0.7)',
|
||||
textMuted: 'rgba(255, 255, 255, 0.5)',
|
||||
|
||||
// 边框色
|
||||
border: 'rgba(212, 175, 55, 0.2)',
|
||||
borderHover: 'rgba(212, 175, 55, 0.4)',
|
||||
|
||||
// 涨跌色
|
||||
positive: '#EF4444',
|
||||
negative: '#22C55E',
|
||||
positiveBg: 'rgba(239, 68, 68, 0.2)',
|
||||
negativeBg: 'rgba(34, 197, 94, 0.2)',
|
||||
};
|
||||
|
||||
// ============================================
|
||||
// Tab 懒加载组件
|
||||
// ============================================
|
||||
|
||||
const CompanyOverview = lazy(() => import('./components/CompanyOverview'));
|
||||
const MarketDataView = lazy(() => import('./MarketDataView'));
|
||||
const FinancialPanorama = lazy(() => import('./components/FinancialPanorama'));
|
||||
const ForecastReport = lazy(() => import('./ForecastReport'));
|
||||
|
||||
// ============================================
|
||||
// Tab 配置
|
||||
// ============================================
|
||||
|
||||
export const TAB_CONFIG: TabConfig[] = [
|
||||
{
|
||||
key: 'overview',
|
||||
name: '公司概览',
|
||||
icon: Building2,
|
||||
component: CompanyOverview,
|
||||
},
|
||||
{
|
||||
key: 'market',
|
||||
name: '股票行情',
|
||||
icon: TrendingUp,
|
||||
component: MarketDataView,
|
||||
},
|
||||
{
|
||||
key: 'financial',
|
||||
name: '财务全景',
|
||||
icon: Wallet,
|
||||
component: FinancialPanorama,
|
||||
},
|
||||
{
|
||||
key: 'forecast',
|
||||
name: '盈利预测',
|
||||
icon: FileBarChart,
|
||||
component: ForecastReport,
|
||||
},
|
||||
];
|
||||
|
||||
// ============================================
|
||||
// 搜索框样式配置(Ant Design AutoComplete)
|
||||
// ============================================
|
||||
|
||||
export const getSearchBoxStyles = (theme: CompanyTheme) => ({
|
||||
'.ant-select-selector': {
|
||||
backgroundColor: `${theme.bg} !important`,
|
||||
borderColor: `${theme.border} !important`,
|
||||
borderRadius: '8px !important',
|
||||
height: '40px !important',
|
||||
'&:hover': {
|
||||
borderColor: `${theme.borderHover} !important`,
|
||||
},
|
||||
},
|
||||
'.ant-select-selection-search-input': {
|
||||
color: `${theme.textPrimary} !important`,
|
||||
height: '38px !important',
|
||||
},
|
||||
'.ant-select-selection-placeholder': {
|
||||
color: `${theme.textMuted} !important`,
|
||||
},
|
||||
'.ant-select-dropdown': {
|
||||
backgroundColor: `${theme.cardBg} !important`,
|
||||
borderColor: `${theme.border} !important`,
|
||||
},
|
||||
'.ant-select-item': {
|
||||
color: `${theme.textPrimary} !important`,
|
||||
'&:hover': {
|
||||
backgroundColor: `${theme.bg} !important`,
|
||||
},
|
||||
},
|
||||
'.ant-select-item-option-selected': {
|
||||
backgroundColor: 'rgba(212, 175, 55, 0.2) !important',
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user