css3: the future is now at drupalcon san francisco

38
CSS 3 : The Future is Now DrupalCon San Francisco April 2010

Upload: jen-simmons

Post on 31-Oct-2014

1.281 views

Category:

Technology


2 download

DESCRIPTION

The next generation of CSS is here, and it's being used on thousands of sites. Learn about the new styles, and how to use them today. Rounded corners, gradients, translucent color, shadows — forget making images, do it with CSS.

TRANSCRIPT

Page 1: CSS3: The Future is Now at DrupalCon San Francisco

CSS3: The Future is Now

DrupalCon San FranciscoApril 2010

Page 2: CSS3: The Future is Now at DrupalCon San Francisco

Jen SimmonsLullabot Trainer

Lead Front-End Developer and architect at workhabit

twitter: jensimmonsirc/d.o: jensimmons

http://extras.jensimmons.com/drupalconsf2010/css3.pdf

Page 3: CSS3: The Future is Now at DrupalCon San Francisco

wouldn’t you like tomake rounded corners

put multiple background images on one thing

make drop shadows

put shadows on text

have image-based borders on boxes

layout your content in multiple columns

use translucent colors

create gradients and reflections

use more fonts on the web

animate stuff

Page 4: CSS3: The Future is Now at DrupalCon San Francisco

with just css

You can!

today

Page 5: CSS3: The Future is Now at DrupalCon San Francisco

butwhat about the

evil one?

Page 6: CSS3: The Future is Now at DrupalCon San Francisco

ie

Page 7: CSS3: The Future is Now at DrupalCon San Francisco

well,you can ignore

internet explorer

let it stay in 200X

Page 9: CSS3: The Future is Now at DrupalCon San Francisco
Page 10: CSS3: The Future is Now at DrupalCon San Francisco
Page 11: CSS3: The Future is Now at DrupalCon San Francisco

“progressive enhancement”

Page 12: CSS3: The Future is Now at DrupalCon San Francisco

compliantbrowser*

drop shadow

rounded corners

gradient

translucency

new font

none

square corners

solid color

opaqueness

old font

internetexplorer

* safari & chrome, firefox, opera

Page 13: CSS3: The Future is Now at DrupalCon San Francisco

workaround ie with filter hacks

filter: progid:DXImageTransform.Microsoft.gradient(startColorStr='#444444', EndColorStr='#999999'); /* IE6,IE7 */ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorStr='#444444', EndColorStr='#999999')"; /* IE8 */

http://css3please.com

Page 14: CSS3: The Future is Now at DrupalCon San Francisco

http://modernizr.com

Page 15: CSS3: The Future is Now at DrupalCon San Francisco

enough about iewhat about

everybody else?

safari

chrome

opera

firefox

Page 16: CSS3: The Future is Now at DrupalCon San Francisco

browser makers are implementing stuff that not everyone

has agreed to.

and it’s ok.

Page 17: CSS3: The Future is Now at DrupalCon San Francisco

border-radius: 12px;

-webkit-border-radius: 12px; /* Saf3+, Chrome */

-moz-border-radius: 12px; /* FF1+ */

{

}

/* Opera 10.5, IE 9 */

Page 18: CSS3: The Future is Now at DrupalCon San Francisco

div.block {-moz-border-radius: 12px;-webkit-border-radius: 12px;-khtml-border-radius: 12px;border-radius: 12px;}

Page 19: CSS3: The Future is Now at DrupalCon San Francisco

browser makers are implementing stuff in bits and pieces

over time.

and it’s ok.

Page 20: CSS3: The Future is Now at DrupalCon San Francisco

the Css working group (where css is born)

is creating the spec over time

in

“modules”

Page 22: CSS3: The Future is Now at DrupalCon San Francisco

let’s get to it

Page 23: CSS3: The Future is Now at DrupalCon San Francisco

Border-radiushttp://border-radius.com

Page 25: CSS3: The Future is Now at DrupalCon San Francisco

text-shadowhttp://css3generator.com

Page 26: CSS3: The Future is Now at DrupalCon San Francisco

multicolumn layouthttp://css3generator.com

Page 28: CSS3: The Future is Now at DrupalCon San Francisco

rgba and hslahttp://css3generator.com

Page 29: CSS3: The Future is Now at DrupalCon San Francisco

transformationshttp://westciv.com/tools/transforms

Page 30: CSS3: The Future is Now at DrupalCon San Francisco

CSS animations

one cool example:http://anthonycalzadilla.com/css3-ATAT

(only works in webkit)

-webkit-transform: translate(x,y) rotate(x)

Page 31: CSS3: The Future is Now at DrupalCon San Francisco

font-facehttp://fontsquirrel.com

http://typekit.com

Page 32: CSS3: The Future is Now at DrupalCon San Francisco

resources

Page 33: CSS3: The Future is Now at DrupalCon San Francisco

Dan cederholmHandcrafted css

Page 36: CSS3: The Future is Now at DrupalCon San Francisco

http://css3.info

Page 37: CSS3: The Future is Now at DrupalCon San Francisco

http://google.com

Page 38: CSS3: The Future is Now at DrupalCon San Francisco

have fun :)welcome to the future