Ads+Data Design Offsite 2014
Technology is the medium that brings your designs to life.
Know your medium!
h1 {
font-size: 24px;
font-weight: bold;
text-transform: uppercase;
}
Text
CSS is composed of style "rules"
div {
background: Red;
}
h1 {
color: White;
}
<html>
<head></head>
<body>
<div>
<h1>Hola</h1>
I'm John Doe...
</div>
</body>
</html>
Select every paragraph element and make the font-size: 15px.
p {
font-size: 15px;
}
Select every image element and make them 500 x 500 height.
img {
width: 500px;
height: 500px;
}
Every element? What if I want to control a specific element?
<p id="intro">This is an intro paragraph.</p>
<span class="warning">Warning!</span>
#intro {
property: value;
}
.warning {
property: value;
}
An ID name is preceeded by a pound "#" sign
A class name is preceeded by a period "." sign
a:hover {
text-decoration: underline;
}
This styles a link to have a hover with an underline
a:link // unvisited link
a:visited // visited link
a:hover // hover link
a:active // activated link
Combine selectors if you want to get specific
p.warning a {
property: value;
}
Selects all link elements in a paragraph with class .warning
More on specificity
Well first, what is Git? Git is a version control system used to record and track the files of your project.
Github is a suite of tools that makes using git much, much easier.
Pull - The act of downloading changes from a remote repository.
Pull Request - Use a PR to present your changes and propose that work to be incorporated into the repo.
http://git.corp.yahoo.com/ads-data/bootstrap
Sass is a framework that adds more functionality to vanilla CSS
Don't repeat yourself :)
h1 {
font-color: #F0F0F0;
text-transform: uppercase;
}
.bg {
background-color: #F0F0F0;
font-weight: bold;
}
$primary-color: #F0F0F0;
h1 {
font-color: $primary-color;
text-transform: uppercase;
}
.bg {
background-color: $primary-color;
font-weight: bold;
}
"Plain" CSS
SASS
Feeling ambitious? Get your machine setup, and start contributing to our theme today!
Start learning CSS!
CSS References