first-update
This commit is contained in:
169
easy-dataset-main/styles/blindTest.js
Normal file
169
easy-dataset-main/styles/blindTest.js
Normal file
@@ -0,0 +1,169 @@
|
||||
import { alpha } from '@mui/material/styles';
|
||||
|
||||
export const blindTestStyles = theme => ({
|
||||
// 容器
|
||||
container: {
|
||||
p: 3,
|
||||
height: 'calc(100vh - 64px)',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
overflow: 'hidden',
|
||||
bgcolor: 'background.default'
|
||||
},
|
||||
|
||||
// 头部
|
||||
header: {
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'space-between',
|
||||
mb: 2
|
||||
},
|
||||
headerTitle: {
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
gap: 1.5
|
||||
},
|
||||
|
||||
// 进度和问题区域
|
||||
questionPaper: {
|
||||
p: 3,
|
||||
borderRadius: 3,
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
boxShadow: 'none',
|
||||
bgcolor: theme.palette.background.paper
|
||||
},
|
||||
|
||||
// 回答区域容器
|
||||
answersContainer: {
|
||||
display: 'flex',
|
||||
gap: 3,
|
||||
flex: 1,
|
||||
minHeight: 0, // 关键:允许 flex 子项收缩
|
||||
mt: 2
|
||||
},
|
||||
|
||||
// 单个回答卡片
|
||||
answerPaper: {
|
||||
width: 'calc(50% - 12px)',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
height: '100%',
|
||||
borderRadius: 3,
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
boxShadow: 'none',
|
||||
overflow: 'hidden',
|
||||
bgcolor: theme.palette.background.paper
|
||||
},
|
||||
answerHeader: {
|
||||
p: 2,
|
||||
borderBottom: `1px solid ${theme.palette.divider}`,
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'space-between',
|
||||
bgcolor: theme.palette.background.default
|
||||
},
|
||||
answerContent: {
|
||||
flex: 1,
|
||||
overflow: 'auto',
|
||||
p: 3,
|
||||
// 增加滚动条美化
|
||||
'&::-webkit-scrollbar': {
|
||||
width: '8px'
|
||||
},
|
||||
'&::-webkit-scrollbar-track': {
|
||||
background: 'transparent'
|
||||
},
|
||||
'&::-webkit-scrollbar-thumb': {
|
||||
backgroundColor: theme.palette.divider,
|
||||
borderRadius: '4px'
|
||||
},
|
||||
'&::-webkit-scrollbar-thumb:hover': {
|
||||
backgroundColor: theme.palette.text.disabled
|
||||
}
|
||||
},
|
||||
answerFooter: {
|
||||
p: 1.5,
|
||||
borderTop: `1px solid ${theme.palette.divider}`,
|
||||
bgcolor: theme.palette.background.default,
|
||||
display: 'flex',
|
||||
justifyContent: 'flex-end'
|
||||
},
|
||||
|
||||
// 底部投票栏
|
||||
voteBar: {
|
||||
p: 1.5,
|
||||
borderRadius: 4,
|
||||
mx: 'auto',
|
||||
width: 'fit-content',
|
||||
minWidth: 800,
|
||||
mt: 'auto',
|
||||
bgcolor: alpha(theme.palette.background.paper, 0.8),
|
||||
backdropFilter: 'blur(20px)',
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
boxShadow: theme.shadows[8]
|
||||
},
|
||||
voteButtons: {
|
||||
display: 'flex',
|
||||
justifyContent: 'center',
|
||||
gap: 2
|
||||
},
|
||||
voteBtn: {
|
||||
flex: 1,
|
||||
py: 1.2,
|
||||
borderRadius: 3,
|
||||
fontWeight: 600,
|
||||
textTransform: 'none',
|
||||
boxShadow: 'none',
|
||||
'&:hover': {
|
||||
boxShadow: theme.shadows[4]
|
||||
}
|
||||
},
|
||||
|
||||
// 结果页
|
||||
resultContainer: {
|
||||
height: 'calc(100vh - 64px)',
|
||||
overflow: 'auto',
|
||||
p: 3
|
||||
},
|
||||
resultContent: {
|
||||
maxWidth: 1200,
|
||||
mx: 'auto'
|
||||
},
|
||||
|
||||
// 结果卡片
|
||||
scoreCard: {
|
||||
flex: 1,
|
||||
borderRadius: 3,
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
boxShadow: 'none',
|
||||
transition: 'all 0.3s ease',
|
||||
'&:hover': {
|
||||
transform: 'translateY(-4px)',
|
||||
boxShadow: theme.shadows[4]
|
||||
}
|
||||
},
|
||||
scoreCardContent: {
|
||||
textAlign: 'center',
|
||||
py: 5
|
||||
},
|
||||
|
||||
// 详细结果列表项
|
||||
resultItem: {
|
||||
mb: 2,
|
||||
borderRadius: 3,
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
boxShadow: 'none',
|
||||
overflow: 'hidden',
|
||||
transition: 'all 0.2s ease'
|
||||
},
|
||||
resultItemHeader: {
|
||||
p: 2.5,
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'space-between',
|
||||
cursor: 'pointer',
|
||||
'&:hover': {
|
||||
bgcolor: theme.palette.action.hover
|
||||
}
|
||||
}
|
||||
});
|
||||
19
easy-dataset-main/styles/globals.css
Normal file
19
easy-dataset-main/styles/globals.css
Normal file
@@ -0,0 +1,19 @@
|
||||
/* 添加流式输出的闪烁光标动画 */
|
||||
@keyframes blink {
|
||||
0% {
|
||||
opacity: 1;
|
||||
}
|
||||
50% {
|
||||
opacity: 0;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.blinking-cursor {
|
||||
animation: blink 1s infinite;
|
||||
display: inline-block;
|
||||
font-weight: bold;
|
||||
color: #666;
|
||||
}
|
||||
165
easy-dataset-main/styles/home.js
Normal file
165
easy-dataset-main/styles/home.js
Normal file
@@ -0,0 +1,165 @@
|
||||
// styles/home.js
|
||||
import { alpha } from '@mui/material/styles';
|
||||
|
||||
export const styles = {
|
||||
heroSection: {
|
||||
pt: { xs: 6, md: 10 },
|
||||
pb: { xs: 6, md: 8 },
|
||||
position: 'relative',
|
||||
overflow: 'hidden',
|
||||
transition: 'all 0.3s ease-in-out'
|
||||
},
|
||||
heroBackground: theme => ({
|
||||
background:
|
||||
theme.palette.mode === 'dark'
|
||||
? 'linear-gradient(135deg, rgba(42, 92, 170, 0.25) 0%, rgba(139, 92, 246, 0.25) 100%)'
|
||||
: 'linear-gradient(135deg, rgba(42, 92, 170, 0.08) 0%, rgba(139, 92, 246, 0.08) 100%)',
|
||||
'&::before': {
|
||||
content: '""',
|
||||
position: 'absolute',
|
||||
top: 0,
|
||||
left: 0,
|
||||
right: 0,
|
||||
bottom: 0,
|
||||
background: 'url("/imgs/grid-pattern.png") repeat',
|
||||
opacity: theme.palette.mode === 'dark' ? 0.05 : 0.03,
|
||||
zIndex: 0
|
||||
}
|
||||
}),
|
||||
decorativeCircle: {
|
||||
position: 'absolute',
|
||||
width: '800px',
|
||||
height: '800px',
|
||||
borderRadius: '50%',
|
||||
background: 'radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, rgba(42, 92, 170, 0) 70%)',
|
||||
top: '-300px',
|
||||
right: '-200px',
|
||||
zIndex: 0,
|
||||
animation: 'pulse 15s infinite ease-in-out',
|
||||
'@keyframes pulse': {
|
||||
'0%': { transform: 'scale(1)' },
|
||||
'50%': { transform: 'scale(1.05)' },
|
||||
'100%': { transform: 'scale(1)' }
|
||||
}
|
||||
},
|
||||
decorativeCircleSecond: {
|
||||
position: 'absolute',
|
||||
width: '500px',
|
||||
height: '500px',
|
||||
borderRadius: '50%',
|
||||
background: 'radial-gradient(circle, rgba(42, 92, 170, 0.1) 0%, rgba(139, 92, 246, 0) 70%)',
|
||||
bottom: '-200px',
|
||||
left: '-100px',
|
||||
zIndex: 0,
|
||||
animation: 'pulse2 20s infinite ease-in-out',
|
||||
'@keyframes pulse2': {
|
||||
'0%': { transform: 'scale(1)' },
|
||||
'50%': { transform: 'scale(1.08)' },
|
||||
'100%': { transform: 'scale(1)' }
|
||||
}
|
||||
},
|
||||
gradientTitle: theme => ({
|
||||
mb: 2,
|
||||
background: theme.palette.gradient.primary,
|
||||
WebkitBackgroundClip: 'text',
|
||||
WebkitTextFillColor: 'transparent',
|
||||
backgroundClip: 'text',
|
||||
textFillColor: 'transparent'
|
||||
}),
|
||||
createButton: theme => ({
|
||||
mt: 3,
|
||||
px: 4,
|
||||
py: 1.2,
|
||||
borderRadius: '12px',
|
||||
fontSize: '1rem',
|
||||
background: theme.palette.gradient.primary,
|
||||
'&:hover': {
|
||||
boxShadow: '0 8px 16px rgba(0, 0, 0, 0.1)'
|
||||
}
|
||||
}),
|
||||
statsCard: theme => ({
|
||||
mt: 6,
|
||||
p: { xs: 2, md: 4 },
|
||||
borderRadius: '16px',
|
||||
boxShadow: theme.palette.mode === 'dark' ? '0 8px 24px rgba(0, 0, 0, 0.2)' : '0 8px 24px rgba(0, 0, 0, 0.05)',
|
||||
background: theme.palette.mode === 'dark' ? 'rgba(30, 30, 30, 0.6)' : 'rgba(255, 255, 255, 0.8)',
|
||||
backdropFilter: 'blur(8px)'
|
||||
}),
|
||||
projectCard: theme => ({
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
position: 'relative',
|
||||
transition: 'transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out',
|
||||
borderRadius: '16px',
|
||||
overflow: 'visible', // 允许内容溢出(如下拉菜单)
|
||||
'&:hover': {
|
||||
transform: 'translateY(-4px)',
|
||||
boxShadow: theme.palette.mode === 'dark' ? '0 12px 24px rgba(0,0,0,0.3)' : '0 12px 24px rgba(0,0,0,0.1)'
|
||||
}
|
||||
}),
|
||||
projectCardContent: {
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
p: 2
|
||||
},
|
||||
projectTitle: {
|
||||
fontWeight: 700,
|
||||
fontSize: '1rem',
|
||||
lineHeight: 1.2,
|
||||
mb: 0.25,
|
||||
overflow: 'hidden',
|
||||
textOverflow: 'ellipsis',
|
||||
whiteSpace: 'nowrap'
|
||||
},
|
||||
projectDescription: {
|
||||
mb: 1.5,
|
||||
display: '-webkit-box',
|
||||
WebkitBoxOrient: 'vertical',
|
||||
WebkitLineClamp: 2,
|
||||
overflow: 'hidden',
|
||||
textOverflow: 'ellipsis',
|
||||
height: '32px',
|
||||
color: 'text.secondary',
|
||||
fontSize: '0.75rem',
|
||||
lineHeight: 1.4
|
||||
},
|
||||
statsContainer: {
|
||||
display: 'grid',
|
||||
gridTemplateColumns: 'repeat(2, 1fr)',
|
||||
gap: 1,
|
||||
mt: 'auto'
|
||||
},
|
||||
statItem: theme => ({
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
gap: 1,
|
||||
p: 0.75,
|
||||
borderRadius: '8px',
|
||||
backgroundColor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.05)' : 'rgba(0,0,0,0.02)',
|
||||
transition: 'background-color 0.2s',
|
||||
'&:hover': {
|
||||
backgroundColor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.08)' : 'rgba(0,0,0,0.04)'
|
||||
}
|
||||
}),
|
||||
statIconBox: (theme, color) => ({
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
width: 24,
|
||||
height: 24,
|
||||
borderRadius: '6px',
|
||||
backgroundColor: alpha(theme.palette[color].main, 0.1),
|
||||
color: theme.palette[color].main
|
||||
}),
|
||||
cardFooter: {
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'space-between',
|
||||
mt: 2,
|
||||
pt: 2,
|
||||
borderTop: '1px solid',
|
||||
borderColor: 'divider'
|
||||
}
|
||||
};
|
||||
82
easy-dataset-main/styles/playground.js
Normal file
82
easy-dataset-main/styles/playground.js
Normal file
@@ -0,0 +1,82 @@
|
||||
// 模型测试页面样式
|
||||
import { alpha } from '@mui/material/styles';
|
||||
|
||||
export const playgroundStyles = theme => ({
|
||||
container: {
|
||||
p: 3,
|
||||
height: 'calc(100vh - 64px)',
|
||||
display: 'flex',
|
||||
flexDirection: 'column'
|
||||
},
|
||||
mainPaper: {
|
||||
p: 3,
|
||||
flex: 1,
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
mb: 2,
|
||||
borderRadius: 2
|
||||
},
|
||||
controlsContainer: {
|
||||
mb: 2
|
||||
},
|
||||
clearButton: {
|
||||
height: '56px'
|
||||
},
|
||||
divider: {
|
||||
mb: 2
|
||||
},
|
||||
emptyStateBox: {
|
||||
flex: 1,
|
||||
display: 'flex',
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
mb: 2,
|
||||
p: 2,
|
||||
bgcolor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.03)' : 'rgba(0,0,0,0.02)',
|
||||
borderRadius: 1
|
||||
},
|
||||
chatContainer: {
|
||||
flex: 1,
|
||||
mb: 2
|
||||
},
|
||||
modelPaper: {
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
border: `1px solid ${theme.palette.divider}`,
|
||||
borderRadius: 1,
|
||||
overflow: 'hidden'
|
||||
},
|
||||
modelHeader: {
|
||||
p: 1,
|
||||
bgcolor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.05)' : 'primary.light',
|
||||
color: theme.palette.mode === 'dark' ? 'white' : 'white',
|
||||
fontWeight: 'medium',
|
||||
textAlign: 'center',
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center'
|
||||
},
|
||||
modelChatBox: {
|
||||
flex: 1,
|
||||
overflowY: 'auto',
|
||||
p: 2,
|
||||
bgcolor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.03)' : 'rgba(0,0,0,0.02)'
|
||||
},
|
||||
emptyChatBox: {
|
||||
display: 'flex',
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
height: '100%'
|
||||
},
|
||||
inputContainer: {
|
||||
display: 'flex',
|
||||
gap: 1,
|
||||
mt: 2
|
||||
},
|
||||
sendButton: {
|
||||
minWidth: '120px',
|
||||
height: '56px',
|
||||
marginLeft: '20px'
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user