Design comparison
Solution retrospective
Hello Everyone! 👋
I finally finished the first intermediate challenge. 🎉
This challenge is really testing my CSS skill, especially when making it responsive. 😆
Now for the questions:
- I added
aria-hidden="true"
for the phone, since it's just an illustration. Also because of that, I didn't use any interactive elements such asbutton
andinput
. But, what do you think about this? - I am struggling with making the two background that is on the top left and bottom right corner have a fluid layout. I had tried using
calc()
,clamp()
, but I wasn't able to find the calculation for it. Do you have any solutions for this? - I'm not sure what kind of animation should I make, so any idea about it would be appreciated.
Of course, other comments or any issue that you may find, feel free to write it down.
Also if you want me to give my feedback on your solution, feel free to give me the link on the community feedback! I will be glad to help you too!
Thanks!
Community feedback
- @pikapikamartPosted over 3 years ago
Hi, great work on this one. Both desktop and mobile layout is good.
Regarding your question:
- You can make the background fluid, like what you said, using clamp. I primarily use clamp to make media query-less layout in some projects. Try applying this one
width: clamp(25rem, 46vw, 36.875rem);
on yourbody::before
selector, this will be your base property that is inside the mobile workflow. Then you could just remove allwidth
declaration on yourmedia
queries related to thewidth
of the selector. For theheight
you can just use theclamp
function on it as well. Make sure that you know the properties on theclamp
. First argument isminimum
second ispreferred
last ismaximum
. What will really help you to graspedclamp
is that, first, add themin
andmax
of the property that you want, anypreferred
size could be use as well. Example:
width: clamp(10rem, 3vw, 37rem);
10rem is my minimum, 37rem is my maximum. My size will only grow or shrink base on my 3vw declaration.
Then what you should do, adjust your screen, go to your maximum size, for example, 1600px, then tinker on the preferred size, adjust it until you reached the maximum size. Example:
width: clamp(10rem, 23vw, 37rem);
I achieved my 37rem with my 23vw, after this, your layout will be fluid and you don't need any media queries. You can use clamp with font-sizes as well to avoid any media queries.
If you are confused on this one, you can message me in slack and I can help with it.
- You don't really need aria-hidden on this one since
div
is not really an graphic content.svgs
figure
img
those are the ones.
For animations, well, if you treat the phone as like a interactive element, you can maybe add like hover on the button like-ish, on the inputs, on the dots. Just micro interactions with those.
Other than that, good job.
Marked as helpful2@vanzasetiaPosted over 3 years ago@pikamart Thanks for your valuable feedback and your explanation about
clamp
, it really helps me understand better about it! I will try to use thatclamp
function as soon as possible!I used
aria-hidden
to prevent the screenreader to read the chat on the illustration 😅.0@vanzasetiaPosted over 3 years ago@pikamart I take a look at your profile at Frontend Mentor, then I see your slack name is Raymart Pamplona , but I only find Raymart (with girl using batman custom as a profile photo) on the slack. Is Raymart, you?
Anyway, the solution has been updated. Can you give your opinion about the
clamp()
that I used for those backgrounds?0@pikapikamartPosted over 3 years ago@vanzasetia that's a boy...that's me... hahahahha. but yes, that's my slack
on the
::after
yourvw
is too much, I tried about25vw
and it works properly, it gets the minimum for mobile, and gets the maximum on a 1440px. This is on the width, for the height, I haven't tested it.Marked as helpful0@vanzasetiaPosted over 3 years ago@pikamart Oops... my bad 😅. Thanks for checking it!
0 - You can make the background fluid, like what you said, using clamp. I primarily use clamp to make media query-less layout in some projects. Try applying this one
- @huhu0000Posted almost 3 years ago
Great work Vansa I did submit my solution too for this challenge but I think you did better 👍 so keep it a hundred
Marked as helpful0@vanzasetiaPosted almost 3 years ago@huhu0000 Thank you very much for your kind words! I've just provided you with some feedback on your solution! Hopefully, it helps you improve the solution! 😉
1 - @zineb-BouPosted about 3 years ago
Hi Vanza, it is a great solution I loved it, layouts are perfect, concerning animation I added some to this challenge, I appreciate it if you check my solution.
Marked as helpful0@vanzasetiaPosted about 3 years ago@zineb-Bou Thanks for your kind words! By the way, I'm Vanza not Venza 😉.
1 - @palgrammingPosted over 3 years ago
Looks Great !! Nice Job!! ⭐⭐⭐⭐⭐
Marked as helpful0
Please log in to post a comment
Log in with GitHubJoin 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