Advertisement
OpataJoshua

Untitled

Aug 21st, 2022
841
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 0.73 KB | None | 0 0
  1. /*
  2. selector{
  3.   property: propertyValue,
  4.   property1: propertyValue,
  5.   property2: propertyValue,
  6. }
  7. */
  8.  
  9. /*  by the tagName */
  10. body{
  11.   background: #f5eeee;
  12. }
  13.  
  14. /*  by the id name attribute*/
  15. #app{
  16.   /* position: relative; */
  17. }
  18.  
  19. /*  by the class name attribute */
  20. .card{
  21.   background: white;
  22.   width: 70vw;
  23.   height: 60vh;
  24.   position: relative;
  25. }
  26.  
  27. .top-left{
  28.   background: yellow;
  29. }
  30.  
  31. .top-right{
  32.   background: green;
  33.   top: 0;
  34.   right: 0;
  35. }
  36.  
  37. .center{
  38.   background: red;
  39. }
  40.  
  41. .bottom-left{
  42.   background: blue;
  43.   bottom: 0px;
  44.   left: 0px;
  45. }
  46.  
  47. .bottom-right{
  48.   background: orange;
  49.   bottom: 0;
  50.   right: 0;
  51. }
  52.  
  53. /* dependent selector */
  54. .card div{
  55.   width: 60px;
  56.   height: 60px;
  57.   position: absolute;
  58. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement