ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
SASS
&

COMPASS
Sass (Syntactically Awesome
StyleSheets)
? Sass is an extension of CSS that adds power
and elegance to the basic language. It allows
you to use variables, nested
rules, mixins, inline imports, and more, all
with a fully CSS-compatible syntax. Sass helps
keep large stylesheets well-organized, and get
small stylesheets up and running quickly,
particularly with the help of Compass library.
?
?
?
?
?
?
?
?
?
?

SASS
Compatibil CSS3
Variabile
Nesting
Mixins
Import
Mostenire
Functii
Functii de control
Output bine formatat
Integrare cu firebug
Syntax
? *scss (Sassy CSS) - este o extensie la fisierele de
tip *css, asta insemnand ca orice fisier css valid
este si un *scss valid.
? *sass ¨C este o alta extensie folosita, foloseste
indentarea pentru gruparea selectorilor, nu are
nevoie de ¡°{¡± sau ¡°;¡± fiind mai usor de scris si
inteles decat *css.
Sass are chiar si un ¡°tool¡± de convertire a
acestora in ambele sensuri:
$ sass-convert style.scss style.sass
*scss
?
?
?
?
?
?
?
?
?
?
?

#two-column {
@include column-count(2);
width: 300px;
margin-bottom: 20px;
}
#three-column {
@include column-count(3);
width: 300px;
margin-bottom: 20px;
}
*sass
#two-column
+column-count(2)
width: 300px
margin-bottom: 20px
#three-column
+column-count(3)
width: 300px
margin-bottom: 20px
Variabile
?
?
?
?
?
?

Numere (1,2,3, 20px)
String (¡°foo¡±, ¡®bar¡¯, baz)
Culori (blue,#FFFFFF, RGBA)
Boolean (true, false)
Null
Lista de valori separate cu virgula sau spatiu
(1.2em 1em 0 5em, Helvetica, Arial, sans-serif)
Variabile

$width: 5em;
#main
{
width: $width;
}
Grupare
Mixins
Sass and Compass short presentation
Import
Css generat
Mostenire
Css generat
Operatori
Css generat
Functii
Compass
? Framework pentru Sass
? Foarte multe librarii ce pot fi incluse
? Mixin-uri care sunt deja facute (rounded
corners, box-shadow¡­)
exempleeeeeeee

More Related Content

Sass and Compass short presentation