32
Tecniche di animazione digitale 1

#3 - Sectioning content and outline view

Embed Size (px)

DESCRIPTION

- New elements in HTML5 - Sectioning content - Outline view - Markup and CSS validation

Citation preview

Page 1: #3 - Sectioning content and outline view

Tecniche di animazionedigitale 1

Page 2: #3 - Sectioning content and outline view

Michele BertoliFounder / Lead Software Engineer at Igloo

[email protected]

Tecniche di animazionedigitale 1

Page 3: #3 - Sectioning content and outline view

Basic 3

Page 4: #3 - Sectioning content and outline view

Agenda

New elements in HTML5

Sectioning content

Outline view

Markup and CSS validation

5

14

27

22

Page 5: #3 - Sectioning content and outline view

New elements in HTML5

Page 6: #3 - Sectioning content and outline view

Introduction

How were the element names decided upon?

6 Basic / New elements in HTML5

https://developers.google.com/webmasters/state-of-the-web/2005/classes

Page 7: #3 - Sectioning content and outline view

<details> <summary>

The details element represents a disclosure widget from which

the user can obtain additional information or controls.

The summary element represents a summary, caption, or

legend for the rest of the contents of the summary element's

parent details element, if any.

7 Basic / New elements in HTML5

Page 8: #3 - Sectioning content and outline view

<details> <summary>

8 Basic / New elements in HTML5

http://jsfiddle.net/MicheleBertoli/5QRUz

Page 9: #3 - Sectioning content and outline view

<details> <summary>

9 Basic / New elements in HTML5

Page 10: #3 - Sectioning content and outline view

<figure> <figcaption>

The figure element represents a unit of content, optionally with a

caption, that is self-contained, that is typically referenced as a

single unit from the main flow of the document, and that can be

moved away from the main flow of the document without affecting

the document’s meaning.

The figcaption element represents a caption or legend for a figure.

10 Basic / New elements in HTML5

Page 11: #3 - Sectioning content and outline view

<figure> <figcaption>

<figure>

<img src="/macaque.jpg" alt="Macaque in the trees">

<figcaption>

A cheeky macaque, Lower Kintaganban River, Borneo. Original by

<a href="http://www.flickr.com/photos/rclark/">Richard

Clark</a>

</figcaption>

</figure>

11 Basic / New elements in HTML5

Page 12: #3 - Sectioning content and outline view

<time>

The time element represents its contents, along with a

machine-readable form of those contents in the datetime

attribute.

The kind of content is limited to various kinds of dates, times,

time-zone offsets, and durations.

12 Basic / New elements in HTML5

<time>2011-11-12</time>

Page 13: #3 - Sectioning content and outline view

Coffee Break

Page 14: #3 - Sectioning content and outline view

Sectioning content

Page 15: #3 - Sectioning content and outline view

Sectioning models

● Text-level semantics — what were previously inline tags● Grouping content — block level elements like paragraphs,

lists, and divs● Forms — everything inside form tags● Embedded content — images, video, audio, and canvas● Sectioning content — the new structural tags

15 Basic / Sectioning content

Page 16: #3 - Sectioning content and outline view

Introduction

Sectioning content is used to divide an HTML document into

sections. Each section of the document would generally have

it's own header, and possibly footer, as well as content.

16 Basic / Sectioning content

Page 17: #3 - Sectioning content and outline view

Sectioning elements

● article ● aside ● nav ● section

17 Basic / Sectioning content

Page 18: #3 - Sectioning content and outline view

Implicit sectioning

Because the HTML5 Sectioning Elements aren't mandatory to

define an outline, to keep compatibility with the existing web

dominated by HTML4, there is a way to define sections without

them. This is called implicit sectioning.

18 Basic / Sectioning content

Page 19: #3 - Sectioning content and outline view

Sample

<section>

<h1>Forest elephants</h1>

<p>In this section, we discuss the lesser known forest

elephants.

...this section continues...

<h3 class="implicit subsection">Habitat</h3>

<p>Forest elephants do not live in trees but among them.

...this subsection continues...

</section>

19 Basic / Sectioning content

Page 20: #3 - Sectioning content and outline view

Untitled documents

If no heading is at the root level of the document (i.e. not

inside sectioning content), then the document itself will be

untitled.

20 Basic / Sectioning content

Page 21: #3 - Sectioning content and outline view

Sample

<body> <article> <h1>Title</h1> <p>Content</p> </article></body>

21 Basic / Sectioning content

Page 22: #3 - Sectioning content and outline view

Outline view

Page 23: #3 - Sectioning content and outline view

Introduction

The document outline is the structure of a document, generated by

the document’s headings, form titles, table titles, and any other

appropriate landmarks to map out the document.

The document outlining algorithm is a mechanism for producing

outline summaries of Web pages based on how they are marked

up.

23 Basic / Outline view

Page 25: #3 - Sectioning content and outline view

Twentyten

25 Basic / Outline view

Page 26: #3 - Sectioning content and outline view

Twentyeleven

26 Basic / Outline view

Page 27: #3 - Sectioning content and outline view

Markup and CSS validation

Page 28: #3 - Sectioning content and outline view

Introduction

The Markup Validation Service is a validator by the World Wide Web

Consortium (W3C) that allows Internet users to check HTML and

XHTML documents for well-formed markup.

28 Basic / Markup and CSS validation

Page 29: #3 - Sectioning content and outline view

Why validate?

● Validation as a debugging tool● Validation as a future-proof quality check● Validation eases maintenance● Validation helps teach good practices● Validation is a sign of professionalism

29 Basic / Markup and CSS validation

Page 30: #3 - Sectioning content and outline view

Markup Validation Service

30 Basic / Outline view

http://validator.w3.org

Page 31: #3 - Sectioning content and outline view

CSS Validation Service

31 Basic / Outline view

http://jigsaw.w3.org/css-validator

Page 32: #3 - Sectioning content and outline view

Thank you