# Timeline (H5P.Timeline)

Events along a time line, each with a date, a headline and a text, browsed in order.

- `timeline.headline` and `timeline.text` make the title slide; each item of `timeline.date` is an event.
- Dates are written `YYYY,MM,DD`, the month and day optional: `"1888"`, `"1888,7,22"`. An event with an `endDate` spans a period; `timeline.era` shades longer periods.
- An event's `asset.media` is a web address (a YouTube video, a Wikipedia article, a picture's URL) that the timeline loads from that site when shown. That site then learns who views it; tell the user, or leave media out.

## Example

```json
{
  "type": "H5P.Timeline",
  "params": {
    "timeline": {
      "headline": "Bridges over the Danube in Budapest",
      "text": "From the first permanent bridge to the newest.",
      "date": [
        { "startDate": "1849,11,20", "headline": "Chain Bridge", "text": "The first permanent bridge between Buda and Pest." },
        { "startDate": "1876,4,30", "headline": "Margaret Bridge", "text": "The second permanent bridge." },
        { "startDate": "1896", "headline": "Liberty Bridge", "text": "Opened for the millennium celebrations." }
      ]
    }
  }
}
```

<!-- Generated by `h5p-author schema --markdown` from the pinned pack. Do not edit by hand. -->

## Fields of H5P.Timeline 1.1

The example is `type` and `params` alone, and `params` holds the fields below. A source also names its own `title`, `language`, `license` and `authors`, all four required: the build refuses a source that leaves out any of them. The author's name and the licence are the user's: ask for what they have not given. For a name they skip, write the one you know them by, or "Unknown"; for a licence they skip, `U`.

- `timeline` group — Timeline
  - `headline` text, required — Headline: Main timeline heading goes here (first page)
  - `text` html: strong em del a ul ol hr code — Body Text: The main timeline body goes here (first page).
  - `defaultZoomLevel` text = "0" — Default zoom level: This will tweak the default zoom level. Equivilent to pressing the zoom in or zoom out button the specified number of times. Negative numbers zoom out. default is 0
  - `backgroundImage` image file — Background image
  - `height` whole number = 600 — Height: The height in pixels
  - `asset` group — Asset
    - `media` text — Media: Link to media URL (Twitter, YouTube, Flickr, Vimeo, Google Maps and SoundCloud are currently supported)
    - `credit` text — Credits: Credits to the media
    - `caption` text — Caption: Caption description goes here
  - `date` list 1+ of, required — Dates: Add some dates to your timeline!
    - `startDate` text, required — Start date: YYYY,MM,DD (Minimum YYYY required)
    - `endDate` text — End date: YYYY,MM,DD (Minimum YYYY required)
    - `headline` text, required — Headline: Headline for the date entry
    - `text` html: strong em del a ul ol h2 h3 hr pre code — Body text: Body for the date entry
    - `tag` text — Tags: Enter Tags (categories)
    - `asset` group — Asset
      - `media` text — Media: URL to the media (Twitter, YouTube, Flickr, Vimeo, Wikipedia, Google Maps and SoundCloud are currently supported).
      - `thumbnail` image file — Thumbnail
      - `credit` text — Credit: Credits to the media
      - `caption` text — Caption: Caption text
  - `era` list of — Eras: Add an era to your timeline
    - `startDate` text, required — Start date: YYYY,MM,DD (Minimum YYYY required)
    - `endDate` text — End date: YYYY,MM,DD (Minimum YYYY required)
    - `headline` text, required — Headline: Era headline
    - `text` html: strong em del a ul ol hr code — Text: Era body
    - `tag` text — Tag: Era tags (categories)
  - `language` one of "af" | "ar" | "hy" | "eu" | "bg" | "ca" | "zh-cn" | "hr" | "cz" | "da" | "nl" | "en" | "en-24hr" | "eo" | "et" | "fo" | "fa" | "fi" | "fr" | "gl" | "ka" | "de" | "el" | "he" | "hu" | "is" | "id" | "it" | "ja" | "ko" | "lv" | "lt" | "lb" | "ms" | "ne" | "no" | "pl" | "pt" | "pt-br" | "rm" | "ru" | "sr-cy" | "sr" | "si" | "sk" | "sl" | "es" | "sv" | "tl" | "ta" | "zh-tw" | "te" | "tr" | "uk" = "en" — Language: The language of the user interface

It has no interface texts of its own.

<!-- End of the generated section. -->
