Topics: How to use Flexbox , flex-direction , flex-wrap , flex-flow , justify-content , align-items , align-content , Flexbox Item Properties , order , flex-grow , flex-shrink , flex-basis , flex , align-self
- Create a html file with your name like
john.html
- Add current code to that file:
<!DOCTYPE html>
<style>
/* your css code here */
</style>
<html>
<body>
<!-- your html code here -->
</body>
</html>
-
Create a div with class
main
. Set display to flex. -
Inside
main
div create 2 divs. Set first class tosidebar
and second tocontent
.sidebar
width is 20% andcontent
width is 80%. -
In
sidebar
create a div with classsidebar-conainer
and set display to flex and flex-direction to column. -
Add 3 divs to
sidebar-conainer
as follow: -
Set first div class to brand, to take 10% of height. Set content
Dashboard
. -
Set second div class to menu, to take 80% of height. Set content to ul of items like menu1, menu 2, ... .
-
Set third div class to profile, to take 10% of height. Set content
Dashboard
. Set the div content toAdmin User
. -
In the
content
create a div with classcontent-conainer
. -
Create 3 divs for 3 users and set their class to
list-item
and setdisplay: flex;
forlist-item
. -
Inside each
list-item
create 2 divs. Firstlist-item-image
and secondlist-item-name
. -
Keep
list-item-image
fixed and letlist-item-name
grow. -
Add
img
tolist-item-image
s and set src to following images:
- https://s3-us-west-2.amazonaws.com/s.cdpn.io/210284/93.jpg
- https://s3-us-west-2.amazonaws.com/s.cdpn.io/210284/46.jpg
- https://s3-us-west-2.amazonaws.com/s.cdpn.io/210284/59.jpg
- Add
h4
tolist-item-name
s and set names to:
- Linda Hart
- Roger Medina
- Dean Sullivan
Send Pull Request. Check how to deliver your code: https://codingwithbasir.com/how-to-deliver-projects/
Download Free eBook https://codingwithbasir.com/download