1
+ "use client" ;
1
2
import Image from "next/image" ;
2
3
import Link from "next/link" ;
3
4
import { Button } from "@/components/ui/button" ;
@@ -14,8 +15,17 @@ import { SocialLinks } from "@/components/SocialLinks";
14
15
import { Highlight } from "@/components/ui/hero-hihglight" ;
15
16
import PricingCard from "@/components/LandingComponents/PriceCard" ;
16
17
import Navbar1 from "@/components/navbar" ;
18
+ import { useEffect , useState } from "react" ;
17
19
18
20
export default function LandingPage ( ) {
21
+ const [ currentYear , setCurrentYear ] = useState < number > (
22
+ new Date ( ) . getFullYear ( )
23
+ ) ;
24
+
25
+ useEffect ( ( ) => {
26
+ // Set the current year dynamically on mount
27
+ setCurrentYear ( new Date ( ) . getFullYear ( ) ) ;
28
+ } , [ ] ) ;
19
29
return (
20
30
< div className = "flex flex-col min-h-screen bg-background" >
21
31
< Navbar1 />
@@ -222,7 +232,9 @@ export default function LandingPage() {
222
232
</ div >
223
233
</ section >
224
234
</ main >
225
- < footer className = "w-full py-12 px-4 md:px-6 border-t bg-secondary" >
235
+ < footer className = "w-full pt-8 pb-4 px-4 md:px-6 border-t bg-secondary" >
236
+ { /* <-- Changed pt-12 into pt-8 and pb-4 to reduce unnecessary padding */ }
237
+
226
238
< div className = "container mx-auto" >
227
239
< div className = "flex flex-col md:flex-row justify-between items-center mb-8" >
228
240
< div className = "flex items-center space-x-4 mb-4 md:mb-0" >
@@ -366,9 +378,10 @@ export default function LandingPage() {
366
378
</ ul >
367
379
</ div >
368
380
</ div >
369
- < div className = "flex flex-col md:flex-row justify-between items-center pt-8 border-t border-border" >
381
+ < div className = "flex flex-col md:flex-row justify-center items-center pt-8 border-t border-border" >
382
+ { /* <-- Changed justify-between into justify-center to center the copyright statement*/ }
370
383
< p className = "text-sm text-muted-foreground mb-4 md:mb-0" >
371
- © 2023 LeetCode Journal. All rights reserved.
384
+ © { currentYear } LeetCode Journal. All rights reserved.
372
385
</ p >
373
386
</ div >
374
387
</ div >
0 commit comments