Skip to content

style: Fix #1911 change styling and move icons #1913

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
85 changes: 18 additions & 67 deletions components/Header/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,27 +21,26 @@ import {
AiFillEdit,
} from "react-icons/ai";


const NAV__LINK = [
{
path: "/",
display: "Home",
openInNewPage:false,
openInNewPage: false,
},
{
path: "/#courses",
display: "Courses",
openInNewPage:false,
openInNewPage: false,
},
{
path: "/gears",
display: "My Gears",
openInNewPage:false,
openInNewPage: false,
},
{
path: "https://blog.piyushgarg.dev",
display: "Blogs",
openInNewPage:true,
openInNewPage: true,
},
];

Expand Down Expand Up @@ -100,8 +99,7 @@ const Header = () => {
<div
className={`${classes.navigation}`}
ref={menuRef}
onClick={toggleMenu}
>
onClick={toggleMenu}>
<div className={`${classes.nav__menu}`}>
{crossMenu && (
<div className="border text-white text-3xl absolute top-10 right-10 font-extrabold">
Expand All @@ -111,13 +109,18 @@ const Header = () => {
{NAV__LINK.map((item, index) => (
<div
key={index}
className={`${classes.mobile__menuDiv} cursor-pointer`}
>
<Link aria-label={item.display} href={item.path} target={`${item.openInNewPage?'_blank':'_self'}`}>
className={`${classes.mobile__menuDiv} cursor-pointer`}>
<Link
aria-label={item.display}
href={item.path}
target={`${item.openInNewPage ? "_blank" : "_self"}`}>
<p className={`${classes.mobile__menu}`}>{icons[index]}</p>
</Link>

<Link aria-label={item.display} href={item.path} target={`${item.openInNewPage?'_blank':'_self'}`}>
<Link
aria-label={item.display}
href={item.path}
target={`${item.openInNewPage ? "_blank" : "_self"}`}>
<span className=" text-[#808dad] hover:text-green-400">
{item.display}
</span>
Expand All @@ -128,8 +131,7 @@ const Header = () => {
{data && data.user ? (
<div
onClick={signOut}
className={`${classes.mobile__menuDiv} cursor-pointer`}
>
className={`${classes.mobile__menuDiv} cursor-pointer`}>
<Link href={"#"}>
<p className={`${classes.mobile__menu}`}>{icons[4]}</p>
</Link>
Expand All @@ -143,8 +145,7 @@ const Header = () => {
) : (
<div
onClick={signIn}
className={`${classes.mobile__menuDiv} cursor-pointer`}
>
className={`${classes.mobile__menuDiv} cursor-pointer`}>
<Link href={"#"}>
<p className={`${classes.mobile__menu}`}>{icons[4]}</p>
</Link>
Expand All @@ -157,63 +158,13 @@ const Header = () => {
</div>
)}

<div className={`${classes.nav__right}`}>
<div
className={`flex flex-row items-center gap-3 border-l-2 pl-4 border-l-slate-500 `}
>
<Link
aria-label="Youtube Channel"
href="https://youtube.com/@piyushgargdev"
target="_blank"
title="Youtube Channel"
id="youtube-channel"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer"
>
<RiYoutubeFill />
</Link>

<Link
href="https://github.com/piyushgarg-dev/"
target="_blank"
title="Github Account"
id="github-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer"
>
<RiGithubFill />
</Link>

<Link
href="https://twitter.com/piyushgarg_dev"
target="_blank"
title="Twitter Account"
id="twitter-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer"
>
<NewTwitterLogo/>
</Link>

<Link
href="https://www.linkedin.com/in/piyushgarg195/"
target="_blank"
title="LinkedIn Account"
id="linkedin-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer"
>
<RiLinkedinFill />
</Link>
</div>
</div>
<div className={`${classes.nav__right}`}></div>
</div>
</div>

<span
onClick={() => setCrossMenu(!crossMenu)}
className={`${classes.mobile__menu}`}
>
className={`${classes.mobile__menu}`}>
<i className="ri-menu-line" onClick={toggleMenu}></i>
</span>
</div>
Expand Down
59 changes: 51 additions & 8 deletions components/UI/Hero.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ import Image from "next/image";
import heroImg from "../../public/images/PiyushGarg.png";
import classes from "../../styles/hero.module.css";
import classNames from "../../styles/subtitle.module.css";
import { RiYoutubeFill } from "react-icons/ri";
import { RiGithubFill } from "react-icons/ri";
import NewTwitterLogo from "./NewTwitterlogo";
import { RiLinkedinFill } from "react-icons/ri";

const Hero = () => {
return (
Expand All @@ -33,17 +37,15 @@ const Hero = () => {
target="_blank"
href="https://discord.gg/kRSRxBQ6xf"
className="relative text-sm sm:text-md md:text-lg text-center items-center justify-center px-8 py-4 font-bold text-white transition-all duration-200 bg-gray-900 font-pj rounded-xl focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-gray-900"
role="button"
>
role="button">
<span
style={{
display: "flex",
justifyContent: "center",
alignItems: "center",
gap: "10px",
}}
className="block"
>
className="block">
Join Discord Server <BsDiscord />
</span>
</Link>
Expand All @@ -54,6 +56,49 @@ const Hero = () => {
<div className={`${classes.hero__img} text-end`}>
<Image alt="Piyush Garg" src={heroImg} width="450" height="450" />
</div>
<div
className={`flex flex-row justify-center items-center gap-3 w-1/4 p-2 border-b-[0.5px] border-b-slate-400 ml-80`}>
<Link
aria-label="Youtube Channel"
href="https://youtube.com/@piyushgargdev"
target="_blank"
title="Youtube Channel"
id="youtube-channel"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer">
<RiYoutubeFill />
</Link>

<Link
href="https://github.com/piyushgarg-dev/"
target="_blank"
title="Github Account"
id="github-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer">
<RiGithubFill />
</Link>

<Link
href="https://twitter.com/piyushgarg_dev"
target="_blank"
title="Twitter Account"
id="twitter-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer">
<NewTwitterLogo />
</Link>

<Link
href="https://www.linkedin.com/in/piyushgarg195/"
target="_blank"
title="LinkedIn Account"
id="linkedin-account"
className={`cursor-pointer text-[#ffffff] hover:text-[--site-theme-color] transform ease-in-out hover:-translate-y+1 hover:scale-150`}
rel="noreferrer">
<RiLinkedinFill />
</Link>
</div>
</Col>
</Row>
</Container>
Expand Down Expand Up @@ -97,17 +142,15 @@ const Hero = () => {
target="_blank"
href="https://discord.gg/kRSRxBQ6xf"
className="relative w-full text-sm sm:text-md md:text-lg text-center items-center justify-center px-8 py-4 font-bold text-white transition-all duration-200 bg-gray-900 font-pj rounded-xl focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-gray-900"
role="button"
>
role="button">
<span
style={{
display: "flex",
justifyContent: "center",
alignItems: "center",
gap: "10px",
}}
className="block"
>
className="block">
Join Discord Server <BsDiscord />
</span>
</Link>
Expand Down
Loading
Loading