Skip to content

Commit

Permalink
Merge pull request #111 from vishnuvardhanreddy31/vishnu
Browse files Browse the repository at this point in the history
fix: Update copyright notice to dynamically display current year
  • Loading branch information
JiyaGupta-cs authored May 18, 2024
2 parents 19cba0f + e377330 commit c06218f
Showing 1 changed file with 50 additions and 40 deletions.
90 changes: 50 additions & 40 deletions src/Components/Footer/Footer.jsx
Original file line number Diff line number Diff line change
@@ -1,44 +1,54 @@
import React, { useContext } from 'react'
import './Footer.css'
import footer_logo from '../Assets/logo_big.png'
import instagram_icon from '../Assets/instagram_icon.png'
import pintester_icon from '../Assets/pintester_icon.png'
import whatsapp_icon from '../Assets/whatsapp_icon.png'
import { Link } from 'react-router-dom'
import { ShopContext } from '../../Context/ShopContext'
import React, { useContext } from "react";
import "./Footer.css";
import footer_logo from "../Assets/logo_big.png";
import instagram_icon from "../Assets/instagram_icon.png";
import pintester_icon from "../Assets/pintester_icon.png";
import whatsapp_icon from "../Assets/whatsapp_icon.png";
import { Link } from "react-router-dom";
import { ShopContext } from "../../Context/ShopContext";

const Footer = () => {
const {theme}=useContext(ShopContext);
return (
<div className='footer'>
<div className="footer-logo">
<img src={footer_logo} alt="" />
<p className={`footer_${theme}`}>ShopNex</p>
</div>
<ul className={'footer-links_'+theme}>
<li>Company</li>
<li>Products</li>
<li>Offices</li>
<li> <Link className={`link_${theme}`} to='/about'>About</Link></li>
<li> <Link className={`link_${theme}`} to='/contact'>Contact Us</Link></li>
</ul>
<div className="footer-social-icon">
<div className="footer-icons-container">
<img src={instagram_icon} alt="" />
</div>
<div className="footer-icons-container">
<img src={pintester_icon} alt="" />
</div>
<div className="footer-icons-container">
<img src={whatsapp_icon} alt="" />
</div>
</div>
<div className={`footer-copyright_${theme}`}>
<hr className={`hr_${theme}`} />
<p>Copyright @ 2023 - All Rights Reserved</p>
</div>
const { theme } = useContext(ShopContext);
return (
<div className="footer">
<div className="footer-logo">
<img src={footer_logo} alt="" />
<p className={`footer_${theme}`}>ShopNex</p>
</div>
<ul className={"footer-links_" + theme}>
<li>Company</li>
<li>Products</li>
<li>Offices</li>
<li>
{" "}
<Link className={`link_${theme}`} to="/about">
About
</Link>
</li>
<li>
{" "}
<Link className={`link_${theme}`} to="/contact">
Contact Us
</Link>
</li>
</ul>
<div className="footer-social-icon">
<div className="footer-icons-container">
<img src={instagram_icon} alt="" />
</div>
)
}
<div className="footer-icons-container">
<img src={pintester_icon} alt="" />
</div>
<div className="footer-icons-container">
<img src={whatsapp_icon} alt="" />
</div>
</div>
<div className={`footer-copyright_${theme}`}>
<hr className={`hr_${theme}`} />
<p>Copyright @ {new Date().getFullYear()} - All Rights Reserved</p>
</div>
</div>
);
};

export default Footer
export default Footer;

0 comments on commit c06218f

Please sign in to comment.