CSS is easy!
Why would I need a framework?
Why would you write another framework?
What's wrong with existing frameworks?
- Design
- Tools
- RWD assumptions
- Tightly coupled components
- BLOAT!
Let me make the decisions!
A framework should help me solve design problems.
It shouldn't do my work for me.
What makes Scales different?
A design-free, independent collection of OOCSS patterns, framework settings, and utilities for quickly building responsive web projects
Design Free
Independent
Object Oriented CSS
CSS "Object" - A repeating visual pattern that can be abstracted into an independent, reusable snippet of HTML and CSS
Media Object
A fixed piece of media on the left (image, video, icon) and some unknown content to the right.
Media Object
.media {
@extend %clearfix;
display: block;
}
.media__figure {
float: left;
margin-right: 1em;
> img {
display: block;
}
}
.media_body {
overflow: hidden;
display: block;
&,
> :last-child {
margin-bottom: 0;
}
}
OOCSS Principles
Separation of Structure from Skin
Separation of Content from Container
Structure vs. Skin
.btn {
display: inline-block;
font-size: 1.5em;
padding: 1em 2em;
text-align: center;
border-radius: 5px;
cursor: pointer;
}
.btn--primary {
background-color: blue;
color: white;
}
.btn--warning {
background-color: orange;
color: black;
}
Content vs. Container
.category-list h3 {
font-size: 2em;
color: red;
}
.heading--tertiary {
font-size: 2em;
color: red;
}
Yay Modularity!
(Seriously, OOCSS is awesome)
What's in Scales?
Scales Pattern Library
Scales on Github
That's it?
4kb minified and gzipped
Yes, that's it!
Awesome! How do I get it?
The Future of Scales
Questions?