You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Could you please tell me the targeted files and how much functionality are you expecting on the frontend part?
Yeah you can go for the PlaceItems.js file which is basically all the places, and then If I hit the like button, we should call a function, But for now don't do anything in that function (We will call an API in this function later). For now you just have to customize PlaceItems.js file to add a Like button.
Could you please tell me the targeted files and how much functionality are you expecting on the frontend part?
Yeah you can go for the PlaceItems.js file which is basically all the places, and then If I hit the like button, we should call a function, But for now don't do anything in that function (We will call an API in this function later). For now you just have to customize PlaceItems.js file to add a Like button.
Could you please tell me the targeted files and how much functionality are you expecting on the frontend part?
Yeah you can go for the PlaceItems.js file which is basically all the places, and then If I hit the like button, we should call a function, But for now don't do anything in that function (We will call an API in this function later). For now you just have to customize PlaceItems.js file to add a Like button.
@Amoghtech Sir, I have added the like button as such, modifying the PlaceItems.js
added LIKE_SVG , made an assets folder in frontend/src and importing the SVG by import LIKE_SVG from "../../assets/heart-fill.svg"
Could you please tell me the targeted files and how much functionality are you expecting on the frontend part?
Yeah you can go for the PlaceItems.js file which is basically all the places, and then If I hit the like button, we should call a function, But for now don't do anything in that function (We will call an API in this function later). For now you just have to customize PlaceItems.js file to add a Like button.
@Amoghtech Sir, I have added the like button as such, modifying the PlaceItems.js added LIKE_SVG , made an assets folder in frontend/src and importing the SVG by import LIKE_SVG from "../../assets/heart-fill.svg"
@Amoghtech I actually used Button component and made it's innerHTML as SVG , yes it has the hover effect same as View on map, I will make it better in design , thankyou
@Amoghtech sir, I have a hover effect in the SVG using two SVGs
using the following code , I have made use of two SVG, please review the changes and let me know if you need some changes.
const handleLike=()=>{
// make API call to the backend
}
const handleMouseEnter=(e)=>{
e.target.src=LIKE_SVG;
}
const handleMouseLeave=(e)=>{
e.target.src=LOVE_SVG;
}
Activity
[-]Add like a place functionality[/-][+]Add like a place functionality(Frontend)[/+]shikhar13012001 commentedon Oct 5, 2021
I would like to work on this, Please assign it to me
amogh-nagar commentedon Oct 5, 2021
Sure go for it, Happy Hacking!
shikhar13012001 commentedon Oct 5, 2021
Could you please tell me the targeted files and how much functionality are you expecting on the frontend part?
amogh-nagar commentedon Oct 7, 2021
Yeah you can go for the PlaceItems.js file which is basically all the places, and then If I hit the like button, we should call a function, But for now don't do anything in that function (We will call an API in this function later). For now you just have to customize PlaceItems.js file to add a Like button.
shikhar13012001 commentedon Oct 7, 2021
Ok sir , I understand it , thankyou
shikhar13012001 commentedon Oct 8, 2021
@Amoghtech Sir, I have added the like button as such,
modifying the PlaceItems.jsadded
LIKE_SVG, made an assets folder infrontend/srcand importing the SVG byimport LIKE_SVG from "../../assets/heart-fill.svg"amogh-nagar commentedon Oct 9, 2021
Great man! Just remove the border color of this svg and then let me know, I'll merge it
And does this image has a hover effect?
shikhar13012001 commentedon Oct 9, 2021
@Amoghtech I actually used
Buttoncomponent and made it's innerHTML as SVG , yes it has the hover effect same asView on map, I will make it better in design , thankyoushikhar13012001 commentedon Oct 10, 2021
@Amoghtech sir, I have a hover effect in the SVG using two SVGs
using the following code , I have made use of two SVG, please review the changes and let me know if you need some changes.
--
screenshot
amogh-nagar commentedon Oct 10, 2021
Yeah nice, Just add a left margin as well, It's quite close to the DELETE button and also ensure that it's responsive
shikhar13012001 commentedon Oct 14, 2021
@Amoghtech sir please could you add
hacktoberfest-acceptedlabel as well to my PR :) that would be great.