Created
February 10, 2025 17:29
-
-
Save kissu/d963d190d4ccd1dc462c7299fd30289a to your computer and use it in GitHub Desktop.
Dribble copycat
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Dribbble card</title> | |
<meta charset="utf-8"> | |
<link rel="stylesheet" href="css/style.css"> | |
</head> | |
<body> | |
<div class="card-container"> | |
<div class="card-white"> | |
<div class="card-white-image" | |
style="background-image: url('https://random-pic-a92f0baa4c2c.herokuapp.com/capybara');"> | |
</div> | |
<ul class="list-inline"> | |
<li><i class="fas fa-eye"></i> 90</li> | |
<li><i class="fas fa-comment"></i> 10</li> | |
<li><i class="fas fa-heart"></i> 24</li> | |
</ul> | |
</div> | |
<div class="card-user"> | |
<img src="https://kitt.lewagon.com/placeholder/users/arthur-littm" alt="arthur-littm" class="avatar"><a | |
href="alt">arthur-littm</a> | |
</div> | |
</div> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;700&family=Poppins:wght@700"); | |
@import url("https://use.fontawesome.com/releases/v6.1.2/css/all.css"); | |
.avatar { | |
border-radius: 50%; | |
width: 30px; | |
} | |
.card-white { | |
background-color: white; | |
border: 1px solid rgb(240, 240, 240); | |
padding: 8px; | |
width: 250px; | |
} | |
.card-white-image { | |
background-size: cover; | |
width: 100%; | |
height: 150px; | |
} | |
.card-white .list-inline { | |
color: #B0B0B0; | |
text-align: right; | |
padding-top: 8px; | |
} | |
.card-white .list-inline li { | |
margin-left: 8px; | |
} | |
.card-user { | |
margin-top: 8px; | |
/* intro to flexbox! */ | |
display: flex; | |
align-items: center; | |
} | |
.card-user a { | |
color: #4B94BD; | |
} | |
.card-user a:hover { | |
color: #3F7EA3; | |
} | |
.card-user .avatar { | |
margin-right: 8px; | |
} | |
/* --- Fonts --- */ | |
body { | |
font-family: "Open Sans", "Helvetica", "sans-serif"; | |
padding-bottom: 200px; | |
margin: 0; | |
background: #F4F4F4; | |
} | |
h1, h2, h3 { | |
font-family: "Poppins", "sans-serif"; | |
} | |
a { | |
text-decoration: none; | |
} | |
a:hover { | |
text-decoration: none; | |
} | |
.container { | |
margin: 0 auto; | |
max-width: 900px; | |
} | |
.text-center { | |
text-align: center; | |
} | |
.list-inline { | |
list-style: none; | |
padding-left: 0px; | |
margin: 0; | |
} | |
.list-inline li { | |
display: inline-block; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment