Frontend Development

A presentation at Workshop @ Zalando in January 2014 in Berlin, Germany by Gunnar Bittersmann

Slide 1

Slide 1

Gunnar&Bittersmann&&&@g16n

Slide 2

Slide 2

Design&& is&not&& veneer.& —Aral&Balkan&

Slide 3

Slide 3

Design&& is&not&& veneer.& —Aral&Balkan&

Slide 4

Slide 4

Most&people&make&the&mistake&of&thinking&design&is&what&it&looks&like.& That’s&not&what&we&think&design&is.&It’s&not&just&what&it&looks&like&and& feels&like.&Design&is&how&it&works.& —Steve&Jobs

Slide 5

Slide 5

[Design]&is&about&worrying&about&the&right&thing:& solving&your&user’s&problems&not&your&own&problems.& —Aral&Balkan

Slide 6

Slide 6

Most&UX&pitfalls&would&be&prevented&if&developers& thought&‘What&is&the&user&trying&to&do’&instead&of& ‘What&info&do&I&have&to&present’.& —Lea&Verou

Slide 7

Slide 7

Design&is&as&much&about&asking&the&right&questions& as&it&is&about&answering&them.& —Aral&Balkan

Slide 8

Slide 8

Design&is&much&more&about&saying&‘no’& than&it&is&about&saying&‘yes’.& —Aral&Balkan

Slide 9

Slide 9

Perfection&is&achieved,&not&when&there&is&nothing&more&to&add,& but&when&there&is&nothing&left&to&take&away.& —Antoine&de&SaintTExupéry

Slide 10

Slide 10

Design&isn’t&crafting&a&beautiful,&textured&button.& It’s&figuring&out&if&there’s&a&way&to&get&rid&of&the& button&altogether.& —Edward&Tufte

Slide 11

Slide 11

Great&design&is&invisible,&bad&design&gets&noticed.& —Jared&Spool

Slide 12

Slide 12

The&enemy&of&good&design&is&rarely&bad&design;& more&often,&it&is&politics,&territorialism,&and&poor& understanding&of&the&problem&at&hand.& —Dave&Cronin

Slide 13

Slide 13

When&you&know&the&answer&to&a&problem&immediately& it’s&called&production,&not&design.& —Peter&van&Blokland

Slide 14

Slide 14

Design&is&a&process,&not&a&product.& —Aral&Balkan

Slide 15

Slide 15

The&details&are&not&details,&they&make&the&product.& —Charles&Eames

Slide 16

Slide 16

I&remain&amazed&and&perplexed&at&how&often&people&think& they&can&solve&an&information&architecture&problem&with& interaction&design.& —Jesse&James&Garrett

Slide 17

Slide 17

Slide 18

Slide 18

Dan&Saffer,&Designing&for&Interaction

Slide 19

Slide 19

usability the&extent&to&which&a&product&can&be&used& by&specified&users&to&achieve&specified&goals& with&effectiveness,&efficiency,&and& satisfaction&in&a&specified&context&of&use.& [ISO&9241T11]

Slide 20

Slide 20

ISO&9241T110 dialog&principles& suitability&for&the&task& self&descriptiveness& suitability&for&learning& controllability& conformity&with&user&expectations& suitability&for&individualization& error&tolerance

Slide 21

Slide 21

suitability&for&the&task webpage&(images)&optimized&for&performance& contact&information&on&a&website& no&required&input&field&irrelevant&to&the&task& autofocus&on&input&field&that&needs&correction& shortcuts&to&most&important&pages

Slide 22

Slide 22

self&descriptiveness feedback&messages& meaningful&link&titles& item&numbers&in&paged&lists& online&help

Slide 23

Slide 23

suitability&for&learning suitable&metaphors& guided&tour& sitemap

Slide 24

Slide 24

controllability scrollbar& sortable&table& halt&download&and&continue&later

Slide 25

Slide 25

conformity&with&& logo&on&top&left&links&to&home&page& user&expectations tab&key&moves&cursor&to&next&input&field& enter&key&submits&form& consistent&vocabulary,&eg.&“cart”& underlined&phrases&are&always&links

Slide 26

Slide 26

suitability&for&& user&profile& individualisation language&negotiation

Slide 27

Slide 27

error&tolerance form&validation& error&messages&in&the&languge&of&the&user& undo&function

Slide 28

Slide 28

accessibility& the&degree&to&which&a&product,&device,& ♿ service,&or&environment&is&available&to&as& many&people&as&possible.

Slide 29

Slide 29

do#websites#need#to#look#exactly#the#same#in#every#browser?

Slide 30

Slide 30

do#websites#need#to#look#exactly#the#same#in#every#browser#.com

Slide 31

Slide 31

Slide 32

Slide 32

progressive#enhancement is#an#escalator## that#becomes#stairs. graceful#degradation is#building#a#lift## then#having#to#add#stairs.# —#Andrew#Wight

Slide 33

Slide 33

I#like#an#escalator#because an#escalator#can#never#break, it#can#only#become#stairs.# There#would#never#be#an escalator#temporarily#out#of# order#sign,#only#an#escalator temporarily#stairs.# Sorry#for#the#convenience.# —#Mitch#Hedberg

Slide 34

Slide 34

structure’ HTML,’DOM behavior’ JavaScript presentation’ CSS

Slide 35

Slide 35

structure’ HTML,’DOM behavior’ JavaScript presentation’ CSS

Slide 36

Slide 36

structure’ HTML,’DOM behavior’ JavaScript presentation’ CSS

Slide 37

Slide 37

HTML Hypertext’Markup’Language

Slide 38

Slide 38

element

<p>This’paragraph’ ””introduces’the’terms’ ””element,’tag’and’ ””attribute.</p>

Slide 39

Slide 39

tag

<p>This’paragraph’ ””introduces’the’terms’ ””element,’tag’and’ ””attribute.</p>

Slide 40

Slide 40

element’content

<p>This’paragraph’ ””introduces’the’terms’ ””element,’tag’and’ ””attribute.</p>

Slide 41

Slide 41

element’content

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 42

Slide 42

tag

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 43

Slide 43

start’tag

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 44

Slide 44

tag’name’ element’type

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 45

Slide 45

end’tag

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 46

Slide 46

tag’pairs

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 47

Slide 47

nested’elements

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 48

Slide 48

wrong!

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute.</p></b>

Slide 49

Slide 49

child’element’ descendant

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 50

Slide 50

parent’element’ ancestor

<p>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 51

Slide 51

start’tag <p’id=”terms”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 52

Slide 52

attribute <p’id=”terms”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 53

Slide 53

attribute’name <p’id=”terms”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 54

Slide 54

attribute’value <p’id=”terms”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 55

Slide 55

attributes <p’id=”terms“‘class=”lede”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 56

Slide 56

wrong! <p’id=”terms“‘class=”lede“‘class=”important”>This’paragr ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 57

Slide 57

multiple’classes <p’id=”terms“‘class=”lede’important”>This’paragraph’ ””introduces’the’terms’ ””<b>element</b>,’<b>tag</b>’and’ ””<b>attribute</b>.</p>

Slide 58

Slide 58

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> element

Slide 59

Slide 59

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> end’tag start’tag element

Slide 60

Slide 60

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> content start’tag element end’tag

Slide 61

Slide 61

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> tag’name tag’name content start’tag element end’tag

Slide 62

Slide 62

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> tag’name attribute tag’name attribute content start’tag element end’tag

Slide 63

Slide 63

<p’id=”terms“‘class=”lede’important”>This’paragraph’introduces’the’terms…</p> attribute’name tag’name attribute value tag’name attribute content start’tag element end’tag

Slide 64

Slide 64

<!DOCTYPE)html>) <html>)lang=”en”>) <head>) ) <meta)charset=”UTFQ8”/>) ) ) <1tle>The)Universal)Declara1on)of)Human)Rights</1tle>) ) ) <link)rel=”stylesheet”)href=”udhr.css”/>) ) </head>) ) <body>) ) <h1>The)Universal)Declara1on)of)Human)Rights</h1>) ) <h2>Ar1cle)1</h2>) ) <p>All)human)beings)are)born)free)and)equal)in)dignity) ) and)rights.)They)are)endowed)with)reason)and)conscience) ) and)should)act)towards)one)another)in)a)spirit)of) ) brotherhood.</p>) ) </body>) ) </html>)

Slide 65

Slide 65

<!DOCTYPE’html>

always’on’top’for’proper’rendering html root’element’ 2’child’elements:’head’and’body’ should’have’a’lang’attribute’indicating’the’ language’of’page’content head container’for’character’encoding,’page’title,’ link’to’stylesheet,’metainformation <meta’charset=”UTFO8”/> character’encoding’declaration title page’title’(browser’tab,’bookmark) <link’rel=”stylesheet“‘href=”…”/> reference’to’stylesheet

Slide 66

Slide 66

body container’for’page’content h1’…’h6 heading,’1st’…’6th’level p paragraph em emphasis strong strong’emphasis <a’href=”…”> hyperlink

Slide 67

Slide 67

block’elements

<p>Whereas’a’common’understanding’of’these’ rights’and’freedoms’is’of’the’greatest’importance’ for’the’full’realization’of’this’pledge,</p>’ <p><strong>Now,’Therefore’<em>the’General’ Assembly</em>’proclaims’<em>this’Universal’ Declaration’of’Human’Rights</em></strong>’as’a’ common’standard’of’achievement’for’all’peoples’ ‘⋮ and’all’nations,’to’the’end’that’every’individual’ and’every’organ’of’society,’keeping’this’ Declaration’constantly’in’mind,’shall’strive’by’ teaching’and’education’to’promote’respect’for’ these’rights’and’freedoms’and’by’progressive’ measures,’national’and’international,’to’secure’ their’universal’and’effective’recognition’and’ observance,’both’among’the’peoples’of’Member’ States’themselves’and’among’the’peoples’of’ territories’under’their’jurisdiction.</p>

Slide 68

Slide 68

block’elements inline’elements

<p>Whereas’a’common’understanding’of’these’ rights’and’freedoms’is’of’the’greatest’importance’ for’the’full’realization’of’this’pledge,</p>’ <p><strong>Now,’Therefore’<em>the’General’ Assembly</em>’proclaims’<em>this’Universal’ Declaration’of’Human’Rights</em></strong>’as’a’ common’standard’of’achievement’for’all’peoples’ ‘⋮ and’all’nations,’to’the’end’that’every’individual’ and’every’organ’of’society,’keeping’this’ Declaration’constantly’in’mind,’shall’strive’by’ teaching’and’education’to’promote’respect’for’ these’rights’and’freedoms’and’by’progressive’ measures,’national’and’international,’to’secure’ their’universal’and’effective’recognition’and’ observance,’both’among’the’peoples’of’Member’ States’themselves’and’among’the’peoples’of’ territories’under’their’jurisdiction.</p>

Slide 69

Slide 69

example:’udhr.html

Slide 70

Slide 70

CSS Cascading’Style’Sheets

Slide 71

Slide 71

rule p.lede’ {’ ””fontOweight:’bold;’ }’

Slide 72

Slide 72

selector p.lede’ {’ ””fontOweight:’bold;’ }’

Slide 73

Slide 73

declaration p.lede’ {’ ””fontOweight:’bold;’ }’

Slide 74

Slide 74

property p.lede’ {’ ””fontOweight:’bold;’ }’

Slide 75

Slide 75

value p.lede’ {’ ””fontOweight:’bold;’ }’

Slide 76

Slide 76

declarations p.lede’ {’ ””fontOweight:’bold;’ ””fontOsize:’1.25em;’ }’

Slide 77

Slide 77

group’of’selectors p.lede,’p.important’ {’ ””fontOweight:’bold;’ ””fontOsize:’1.25em;’ }’

Slide 78

Slide 78

p.lede,’p.important’{‘fontOweight:’bold;’fontOsize:’1.25em’}’ rule

Slide 79

Slide 79

p.lede,’p.important’{‘fontOweight:’bold;’fontOsize:’1.25em’}’ selector selector group’of’selectors rule

Slide 80

Slide 80

p.lede,’p.important’{‘fontOweight:’bold;’fontOsize:’1.25em’}’ selector selector declaration group’of’selectors rule declaration

Slide 81

Slide 81

p.lede,’p.important’{‘fontOweight:’bold;’fontOsize:’1.25em’}’ property value selector selector declaration group’of’selectors rule declaration

Slide 82

Slide 82

exercise:’udhr.html

Slide 83

Slide 83

box’model content

Slide 84

Slide 84

box’model content border

Slide 85

Slide 85

box’model content padding border

Slide 86

Slide 86

box’model content padding border

Slide 87

Slide 87

box’model content padding border margin

Slide 88

Slide 88

paddingOtop:’1em;’ paddingOright:’2em;’ paddingObottom:’3em;’ paddingOleft:’4em; padding:’1em’2em’3em’4em; top left right bottom

Slide 89

Slide 89

paddingOtop:’1em;’ paddingOright:’2em;’ paddingObottom:’3em;’ paddingOleft:’4em; padding:’1em’2em’3em’4em; top left right bottom

Slide 90

Slide 90

paddingOtop:’1em;’ paddingOright:’2em;’ paddingObottom:’3em;’ paddingOleft:’2em;’ padding:’1em’2em’3em; top left right bottom

Slide 91

Slide 91

paddingOtop:’1em;’ paddingOright:’2em;’ paddingObottom:’1em;’ paddingOleft:’2em;’ padding:’1em’2em; top left right bottom

Slide 92

Slide 92

paddingOtop:’1em;’ paddingOright:’1em;’ paddingObottom:’1em;’ paddingOleft:’1em;’ padding:’1em; top left right bottom

Slide 93

Slide 93

marginOtop:’1em;’ marginOright:’2em;’ marginObottom:’3em;’ marginOleft:’4em;’ margin:’1em’2em’3em’4em; top left right bottom

Slide 94

Slide 94

borderOtopOwidth:’1em;’ borderOrightOwidth:’2em;’ borderObottomOwidth:’3em;’ borderOleftOwidth:’4em;’ borderOwidth:’1em’2em’3em’4em; top left right bottom

Slide 95

Slide 95

content padding border margin

Slide 96

Slide 96

boxOsizing:’contentObox height content padding border margin width

Slide 97

Slide 97

boxOsizing:’paddingObox height content padding border margin width

Slide 98

Slide 98

boxOsizing:’borderObox height content padding border margin width

Slide 99

Slide 99

Slide 100

Slide 100

<main’role=”main”> main’page’content;’max.’1’per’page section,’article grouping’elements,’should’have’headings header,’footer e.g.’information’ab.’author,’copyrights nav,’aside navigation,’tangentially’related’content div block’element’with’no’semantics span inline’element’with’no’semantics

Slide 101

Slide 101

<img’src=”…“‘alt=”…”/> image;’alternative’text’mandatory object,’audio,’video multimedia’objects figure container’for’multimedia’objects,’quotes,’etc. figcaption figure’caption

Slide 102

Slide 102

ol,’ul (un)ordered’list;’only’li’child’elements’allowed li list’item table table;’don’t’use’for’layout <table’role=”presentation”> layout’table caption table’caption

Slide 103

Slide 103

colgroup group’of’table’columns col table’column thead,’tfoot,’tbody groups’of’table’rows tr table’row th table’head’cell’(for’row’or’column) td table’data’cell

Slide 104

Slide 104

thead tr th”””””””””””’th”””””””””””’th””””””””” tr th”””””””””””’td”””””””””””’td””””””””’ tr th”””””””””””’td”””””””””””’td””””””””’ tbody

Slide 105

Slide 105

<form’action=”…”> form;’action’attribute’required fieldset,’legend grouping’element,’group’heading <label’for=”…”> label’for’input’field’with’id,’click’focusses’input <input’name=”…“‘type=”…”/> input’field textarea multiline’input’field button,’<button’type=”submit”> submit’button <button’type=”button”> other’button

Slide 106

Slide 106

input,’<input’type=”text”/> text’input <input’type=”password”/> password’input’(hidden) “email”,‘“tel”,‘“url”,‘“number” enable’special’keybords’on’mobile’devices “range”;‘“date”,‘“time”,’etc. browser’may’display’slider’or’date/time’picker <input’required/> input’field’must’be’filled’out <input’type=”checkbox”/> checkbox <input’type=”radio”/> radio’button;’all’of’same’name’in’a’group

Slide 107

Slide 107

selectors element’type”’p’ id”’#terms,’p#terms’ class”.lede,’p.lede’ attribute”’a[href],’a[href=”#”],’a[href^=”http”],” ’ combinators ‘img[href$=”.jpg”],’p[class~”lede”] descendant”’figure’img’ child”’ol’>’li’ adjacent’sibling”’h1’+’p’ general’sibling”’h2’~’p

Slide 108

Slide 108

pseudoQclasses :hover,’:active,’:focus,’:link,’:visited’ :firstQchild,’:lastQchild,’:nthQchild(an+b)’ :firstQofQtype,’:lastQofQtype,’:nthQofQtype(an+b)’ :checked’ :valid,’:invalid’ :target’ :lang(en)’ :not(…) pseudoQelements ::before,’::after”’li::before’{‘content:’”▶”’}

Slide 109

Slide 109

selector’specifity’ a. style’attribute?’ a.b.c.d b. number’of’ID’selectors’ c. number’of’class’selectors,’attributes’selectors,’ and’pseudoQclasses’ d. number’of’type’selectors’and’pseudoQelements

Slide 110

Slide 110

cascading’stylesheets

  1. browser’stylesheet’ 2. user’stylesheet,’normal’declarations” 3. author’stylesheet,’normal’declarations” 4. author’stylesheet,’important’declarations” 5. user’stylesheet,’important’declarations’