Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aplicar estilos a elementos HTML utilizando tres métodos diferentes #538

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 12 additions & 1 deletion foundations/01-css-methods/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,22 @@
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="style.css">
<title>Methods for Adding CSS</title>
<style>

div {
background-color: red;
color:white;
font-size: 32px;
text-align: center;
font-weight: bold;
}
</style>
</head>
<body>
<div>Style me via the external method!</div>
<p>I would like to be styled with the internal method, please.</p>
<button>Inline Method</button>
<button style="background-color: orange; font-size: 18px;">Inline Method</button>
</body>
</html>
5 changes: 5 additions & 0 deletions foundations/01-css-methods/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
p {
background-color: green;
color: white;
font-size: 18px;
}
10 changes: 5 additions & 5 deletions foundations/02-class-id-selectors/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
<link rel="stylesheet" href="style.css">
</head>
<body>
<p>Number 1 - I'm a class!</p>
<div>Number 2 - I'm one ID.</div>
<p>Number 3 - I'm a class, but cooler!</p>
<div>Number 4 - I'm another ID.</div>
<p>Number 5 - I'm a class!</p>
<p class="odd">Number 1 - I'm a class!</p>
<div id="two">Number 2 - I'm one ID.</div>
<p class="odd adjust-font-size">Number 3 - I'm a class, but cooler!</p>
<div id="id2">Number 4 - I'm another ID.</div>
<p class="odd">Number 5 - I'm a class!</p>
</body>
</html>
18 changes: 18 additions & 0 deletions foundations/02-class-id-selectors/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
.odd {
background-color: rgb(255, 167, 167);
font-family: Verdana, "DejaVu Sans", sans-serif;
}

#two {
color: #0000ff;
font-size: 36px;
}

.odd.adjust-font-size {
font-size: 24px;
}

#id2{
background-color: hsl(120, 100%, 75%);
font-weight: bold;
}