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

profile-card-component

Nemanja NIkolicโ€ข 270

@nmnjnklc

Desktop design screenshot for the Profile card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Community feedback

@MelvinAguilar

Posted

Hi @nmnjnklc ๐Ÿ‘‹, good job for completing this challenge!

I have a suggestion that you might consider:

You can use the background properties to set the circles in the background, this is a very common way to place the circles.

body {
    . . .
    background-color: hsl(185, 75%, 39%);
    background-image: url(./images/bg-pattern-top.svg), url(./images/bg-pattern-bottom.svg);
    background-repeat: no-repeat, no-repeat;
    background-position: right 52vw bottom 35vh, left 48vw top 52vh;
}
  • background-color Set the background color
  • background-image Set a background-image
  • background-repeat Sets if a background image will be repeated along the horizontal and vertical axes, or not repeated at all.
  • background-position Sets the starting position of a background image. More information
  • Also you can use the background-size to specifies the size of the background image

Note: The background property is a shorthand to all the properties mentioned above but for now it is better to understand them separately. In this case if you want to have both circles, just separate in each property the values for each one by a comma url(./images/bg-pattern-top.svg), url(./images/bg-pattern-bottom.svg); .

The background-position worked for me with vw (viewport width) and vh (viewport height) units, but you can use percentage, it's just a matter of trial and error to place them as in the design.

References: CSS background Property | Background property Background-repeat (MDN)

Good Job and happy coding !

Marked as helpful

1

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