@@ -5,7 +5,14 @@ import { ParsedUrlQuery } from 'querystring'
55import ReactMarkdown from 'react-markdown'
66import ChakraUIRenderer from 'chakra-ui-markdown-renderer'
77import type { GetStaticPaths , GetStaticProps } from 'next/types'
8- import { Box , Flex , FlexProps , Image , Text } from '@chakra-ui/react'
8+ import {
9+ Box ,
10+ Flex ,
11+ FlexProps ,
12+ Image ,
13+ Text ,
14+ useColorMode ,
15+ } from '@chakra-ui/react'
916import { ButtonLink , Map , PageMetadata , YouTube } from '@/components'
1017import { EVENTS_DIR , MAIN_CONTENT_ID , MATTER_OPTIONS } from '@/constants'
1118import { EventMDStyles } from '@/styles'
@@ -76,6 +83,7 @@ const CtaButtonGroup: React.FC<CtaButtonGroupProps> = ({
7683)
7784
7885const EventPage : React . FC < EventPost > = ( { frontmatter, content } ) => {
86+ const { colorMode } = useColorMode ( )
7987 const {
8088 title,
8189 location,
@@ -93,16 +101,19 @@ const EventPage: React.FC<EventPost> = ({ frontmatter, content }) => {
93101 ) } `
94102 const isMultiDay = formatDate ( startDate ) !== formatDate ( endDate )
95103
104+ // Use different star images based on color mode
105+ const starImageSrc =
106+ colorMode === 'dark' ? '/assets/star_gray.png' : '/assets/star_blue.png'
107+
96108 return (
97109 < >
98110 < PageMetadata title = { title } description = { description } />
99111 < Box as = "main" id = { MAIN_CONTENT_ID } >
100112 { /* Hero image */ }
101113 < Image
102- src = { imageSrc }
114+ src = { starImageSrc }
103115 alt = "Event hero image"
104- maxH = "450px"
105- w = "full"
116+ maxW = "250px"
106117 objectFit = "cover"
107118 mx = "auto"
108119 />
0 commit comments