-
Notifications
You must be signed in to change notification settings - Fork 3
Update : img to Next.js Image component and fix one Tailwind syntax e… #19
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
base: develop
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,7 +44,7 @@ const ContactDetails = () => { | |
initial="initial" | ||
whileInView="animate" | ||
viewport={{ once: true }}> | ||
<img src={data.contact.img} width={155} | ||
<Image src={data.contact.img} width={155} | ||
height={155} | ||
alt="white bulb" /> | ||
Comment on lines
+47
to
49
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Missing import statement for the Image component. Add 'import Image from "next/image";' at the top of the file. Copilot uses AI. Check for mistakes. Positive FeedbackNegative Feedback |
||
</motion.div> | ||
|
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -2,6 +2,7 @@ import React, { useEffect, useState } from "react"; | |||||||||
import Title from "@/components/ui/title"; | ||||||||||
import MemberCard from "@/components/team/memberCard"; | ||||||||||
import data from "@/content/team.json"; | ||||||||||
import Image from "next/image"; | ||||||||||
import members from "@/content/members.json"; | ||||||||||
import alumni from "@/content/alumni.json"; | ||||||||||
import { motion } from "framer-motion"; | ||||||||||
|
@@ -76,8 +77,11 @@ const MembersAndAlumni = ({ contentFor }) => { | |||||||||
> | ||||||||||
<div className="flex justify-center flex-col items-center"> | ||||||||||
{showAllMembers ? "See less" : "See more"} | ||||||||||
<img | ||||||||||
<Image | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Missing required 'width' and 'height' props for Next.js Image component. These are required for proper optimization unless using 'fill' prop. Copilot uses AI. Check for mistakes. Positive FeedbackNegative Feedback |
||||||||||
src="/assets/icons/seeMore2.png" | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Next.js Image component requires width and height props for proper optimization. Add explicit width and height attributes based on the w-10 h-10 classes (40px each).
Suggested change
Copilot uses AI. Check for mistakes. Positive FeedbackNegative Feedback |
||||||||||
alt="see more" | ||||||||||
width={40} | ||||||||||
height={40} | ||||||||||
className={`w-10 h-10 my-5 ${ | ||||||||||
showAllMembers ? "transform rotate-180" : "" | ||||||||||
}`} | ||||||||||
|
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -1,5 +1,6 @@ | ||||||
import React from "react"; | ||||||
import data from "@/content/team.json"; | ||||||
import Image from "next/image"; | ||||||
import {motion} from 'framer-motion' | ||||||
const teamHero = () => { | ||||||
const team1Varients={ | ||||||
|
@@ -20,8 +21,9 @@ const teamHero = () => { | |||||
initial="initial" | ||||||
whileInView="animate" | ||||||
viewport={{once:true}}> | ||||||
<img src={data.hero.img} | ||||||
<Image src={data.hero.img} | ||||||
className="sm:w-[35rem] max-sm:w-[23rem] max-md:mx-5 sm:h-95" | ||||||
width={640} height={400} | ||||||
alt="team" /> | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Next.js Image component requires width and height props for proper optimization. Add explicit width and height attributes or use the fill prop with a positioned parent container.
Suggested change
Copilot uses AI. Check for mistakes. Positive FeedbackNegative Feedback |
||||||
<h1 className="md:text-[31px] text-center text-3xl mt-5">{data.hero.title}</h1> | ||||||
<p className="mt-3 text-[1.1rem] text-center"> | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing required 'width' and 'height' props for Next.js Image component. These are required for proper optimization unless using 'fill' prop.
Copilot uses AI. Check for mistakes.