Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

tip calculator made with react, sass and packed with vite

#react#sass/scss#vite

@LuisJimenez19

Desktop design screenshot for the Tip calculator app coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


App created with react and vite, using the 3 main hooks and styles with sass to be able to use the variables, use the props to be able to give the styles to the buttons, but use the useContext to be able to give the functionality to the app, the correct thing should be It would have been to use the context for everything, but since I'm practicing, my biggest question is to know if there is another way to give the styles to the buttons in a more optimal way

Community feedback

yishak abrham 2,150

@yishak621

Posted

Congrats for completing the challenge but the card is not responsive to mobile the fonts are squashed so work on that ....it should be displayed as a design image ...when we come to the functionality the event is not fired unless the user come back to the tip percent buttons in ur design .....but it should be fired .....1]when a user type the value in number of peoples input .... 2]when a user come back to the tip percent buttons and click the btns and also type in to the custom input So to enable that type of events u should use input events or keyup events that allows the events to be fired automatically when a user types input and also the should not be 0 error message should be fired when a user types 0 value ...it shouldn't be fired when a user click on the percent buttons ...so use if conditional statement to restrict that event

0

@LuisJimenez19

Posted

@yishak621 thanks, if the functionality is something that cost me since it is the first time that I use react, I should also change the state in the event of the Inputs, regarding the responsiveness it is a pity that it looks bad on you, I have it in a device with 375px and it looks great. Thank you

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord