using jquery and css to manipulate style and markup

45
Using CSS and JQuery to Manipulate Style and Markup A Case Study of LAdrupal.org by Helior Colorado

Upload: helior-colorado

Post on 13-Dec-2014

4.639 views

Category:

Technology


3 download

DESCRIPTION

Using jQuery and CSS to manipulate style and markup by Helior Colorado. Presented at Drupal Camp LA 2008 for the Designer Track. Located at the Los Angeles Convention Center approximately at 4:15pm.

TRANSCRIPT

Page 1: Using jQuery and CSS to manipulate style and markup

Using CSS and JQuery to Manipulate Style and Markup

A Case Study of LAdrupal.orgby Helior Colorado

Page 2: Using jQuery and CSS to manipulate style and markup

Drupal Learning Curve

Page 3: Using jQuery and CSS to manipulate style and markup

Drupal Learning Curve

Page 4: Using jQuery and CSS to manipulate style and markup

Drupal Learning Curve

Page 5: Using jQuery and CSS to manipulate style and markup

Post-Installation stage

Page 6: Using jQuery and CSS to manipulate style and markup

Post-Installation stage

Introducing the Garland Theme

Page 7: Using jQuery and CSS to manipulate style and markup

Post-Installation stage

Introducing the Garland Theme

Page 8: Using jQuery and CSS to manipulate style and markup

Post-Installation stage

Introducing the Garland Theme

3 stylesheets

Page 9: Using jQuery and CSS to manipulate style and markup

Zen Theme

Page 10: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

Page 11: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

7 stylesheets!

Page 12: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

7 stylesheets!

What are they doing?

Page 13: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

7 stylesheets!

What are they doing?

nothing.

Page 14: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

7 stylesheets!

What are they doing?

nothing.

restores default.

Page 15: Using jQuery and CSS to manipulate style and markup

Zen Theme

Removes visual design

7 stylesheets!

What are they doing?

nothing.

restores default.

Page 16: Using jQuery and CSS to manipulate style and markup

Why add complexity?

Page 17: Using jQuery and CSS to manipulate style and markup

Don’t modify, override!

Page 18: Using jQuery and CSS to manipulate style and markup
Page 19: Using jQuery and CSS to manipulate style and markup
Page 20: Using jQuery and CSS to manipulate style and markup
Page 21: Using jQuery and CSS to manipulate style and markup
Page 22: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

Page 23: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

Page 24: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

User !important

Page 25: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

User !important

Author !important

Page 26: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

User !important

Author !important

Author styles

Page 27: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

User !important

Author !important

Author styles

User styles

Page 28: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

User !important

Author !important

Author styles

User styles

Browser styles

Page 29: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”User !important

Author !important

Author styles

User styles

Browser styles

Page 30: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”

‣!important rule

User !important

Author !important

Author styles

User styles

Browser styles

Page 31: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”

‣!important rule

‣#id selector

User !important

Author !important

Author styles

User styles

Browser styles

Page 32: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”

‣!important rule

‣#id selector

‣.class selector

User !important

Author !important

Author styles

User styles

Browser styles

Page 33: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”

‣!important rule

‣#id selector

‣.class selector

‣type selector

User !important

Author !important

Author styles

User styles

Browser styles

Page 34: Using jQuery and CSS to manipulate style and markup

CSS - The Cascade

‣Inline style=” ”

‣!important rule

‣#id selector

‣.class selector

‣type selector

‣* (universal) selector

User !important

Author !important

Author styles

User styles

Browser styles

Page 35: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

Page 36: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

Page 37: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

= 121

Page 38: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

= 121

Page 39: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

Page 40: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

= 211

Page 41: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

= 211

Page 42: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

= 211

<li style=”display:none;”>item 1

</li>

Page 43: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

= 211

<li style=”display:none;”>item 1

</li>

= 1000

Page 44: Using jQuery and CSS to manipulate style and markup

A(inline)

B(id)

C(class)

D(type)

x1000 x100 x10 x1

Specificity Calculator

#main .block .nav li{display:inline;padding-left:5px;}

#page #main .block li{display:block;font-weight:800;}

= 121

= 211

<li style=”display:none;”>item 1

</li>

= 1000

Page 45: Using jQuery and CSS to manipulate style and markup

Ready to move on.