Skip to content

Commit

Permalink
fix: color
Browse files Browse the repository at this point in the history
  • Loading branch information
GZTimeWalker committed Aug 1, 2022
1 parent e0140da commit 0ef102e
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions GZCTF/ClientApp/src/pages/games/[id]/Index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const useStyles = createStyles((theme) => ({
position: 'relative',
height: '40vh',
display: 'flex',
background: ` rgba(0,0,0,0.2)`,
background: theme.colorScheme === "dark" ? ` rgba(0,0,0,0.2)` : theme.white,
justifyContent: 'center',
backgroundSize: 'cover',
backgroundPosition: 'center center',
Expand All @@ -56,7 +56,7 @@ const useStyles = createStyles((theme) => ({
maxWidth: 600,
},
title: {
color: theme.white,
color: theme.colorScheme === 'dark' ? theme.colors.white[0] : theme.colors.gray[6],
fontSize: 50,
fontWeight: 900,
lineHeight: 1.1,
Expand All @@ -78,6 +78,9 @@ const useStyles = createStyles((theme) => ({
display: 'none',
},
},
date: {
color: theme.colorScheme === 'dark' ? theme.colors.white[0] : theme.colors.gray[6]
}
}))

const GameAlertMap = new Map([
Expand Down Expand Up @@ -239,18 +242,18 @@ const GameDetail: FC = () => {
<Title className={classes.title}>{game?.title}</Title>
<Group>
<Stack spacing={0}>
<Text size="sm" color="white">
<Text size="sm" className={classes.date}>
开始时间
</Text>
<Text size="sm" weight={700} color="white">
<Text size="sm" weight={700} className={classes.date}>
{startTime.format('HH:mm:ss, MMMM DD, YYYY')}
</Text>
</Stack>
<Stack spacing={0}>
<Text size="sm" color="white">
<Text size="sm" className={classes.date}>
结束时间
</Text>
<Text size="sm" weight={700} color="white">
<Text size="sm" weight={700} className={classes.date}>
{endTime.format('HH:mm:ss, MMMM DD, YYYY')}
</Text>
</Stack>
Expand Down

0 comments on commit 0ef102e

Please sign in to comment.