File tree 2 files changed +15
-2
lines changed
2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -41,10 +41,11 @@ export default function RootLayout({
41
41
< Provider >
42
42
< Banner
43
43
id = "hiro-hacks"
44
- cta = "Learn more here "
44
+ cta = "Learn more"
45
45
url = "/stacks/hacks"
46
46
startDate = "2025-01-19T17:00:00.000Z"
47
47
endDate = "2025-06-24T23:59:59.999Z"
48
+ mobileText = "Hiro Hacks is live!"
48
49
>
49
50
Hiro Hacks is live! Get started with this months theme: AI x Stacks
50
51
</ Banner >
Original file line number Diff line number Diff line change @@ -32,12 +32,15 @@ export function Banner({
32
32
url = "/" ,
33
33
startDate,
34
34
endDate,
35
+ children,
36
+ mobileText,
35
37
...props
36
38
} : HTMLAttributes < HTMLDivElement > & {
37
39
cta ?: string ;
38
40
url ?: string ;
39
41
startDate ?: string ;
40
42
endDate ?: string ;
43
+ mobileText ?: string ;
41
44
} ) : React . ReactElement | null {
42
45
const [ open , setOpen ] = useState ( true ) ;
43
46
const [ isWithinDateRange , setIsWithinDateRange ] = useState ( false ) ;
@@ -88,7 +91,16 @@ export function Banner({
88
91
/>
89
92
) : null }
90
93
< div className = "flex items-center justify-center space-x-4" >
91
- < div > { props . children } </ div >
94
+ < div >
95
+ { mobileText ? (
96
+ < >
97
+ < span className = "sm:hidden" > { mobileText } </ span >
98
+ < span className = "hidden sm:inline" > { children } </ span >
99
+ </ >
100
+ ) : (
101
+ children
102
+ ) }
103
+ </ div >
92
104
{ cta && (
93
105
< Button
94
106
size = "sm"
You can’t perform that action at this time.
0 commit comments