# Course Presentation (H5P.CoursePresentation)

Slides with text, pictures, video and questions; a summary slide with the score follows when there are questions.

- `presentation.slides` is the list of slides; each slide's `elements` are sub-content under `action`: `{ "action": { "library": "H5P.AdvancedText", "params": { … } } }`.
- Leave out `x`, `y`, `width` and `height` and the build stacks a slide's elements top to bottom: text as tall as its lines, pictures in shape, a question in what is left. On a slide with room and no question it sets the text larger, up to twice its size; text you give a `font-size` keeps it. It notes a slide that holds too much; split it, or show its question as a button (`"displayAsButton": true`). To place an element by hand, give all four, in percent of the slide's width and height from the top left.
- A slide's `keywords` (`[{ "main": "…" }]`) name it in the outline.
- The slide is 16:9: a heading with a few short paragraphs or a list, or with a paragraph and a picture, or with a line of text and a question, fits one slide. Keep to one idea a slide.

## Example

```json
{
  "type": "H5P.CoursePresentation",
  "params": {
    "presentation": {
      "slides": [
        {
          "elements": [
            { "action": { "library": "H5P.AdvancedText", "params": { "text": "<h2>Rivers of Europe</h2><p>The Volga is the longest, at about 3,530 km.</p>" } } },
            { "action": { "library": "H5P.Image", "params": { "file": { "path": "map.png" }, "alt": "A map of Europe's rivers" } } }
          ],
          "keywords": [{ "main": "Rivers of Europe" }]
        },
        {
          "elements": [
            { "action": { "library": "H5P.MultiChoice", "params": { "question": "Which river is the longest in Europe?", "answers": [{ "text": "Volga", "correct": true }, { "text": "Danube", "correct": false }] } } }
          ],
          "keywords": [{ "main": "Question" }]
        }
      ]
    }
  }
}
```

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

## Fields of H5P.CoursePresentation 1.27

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`.

- `presentation` group
  - `slides` list of
    - `elements` list of
      - `action` sub-content: H5P.AdvancedText | H5P.Link | H5P.Image | H5P.Shape | H5P.Video | H5P.Audio | H5P.Blanks | H5P.SingleChoiceSet | H5P.MultiChoice | H5P.TrueFalse | H5P.DragQuestion | H5P.Summary | H5P.DragText | H5P.MarkTheWords | H5P.Dialogcards | H5P.ContinuousText | H5P.ExportableTextArea | H5P.Table | H5P.InteractiveVideo | H5P.TwitterUserFeed | H5P.AudioRecorder | H5P.MultiMediaChoice
      - `solution` html: strong em del a ul ol h2 h3 hr pre code — Comments: The comments are shown when the user displays the suggested answers for all slides.
      - `alwaysDisplayComments` boolean — Always display comments
      - `backgroundOpacity` number 0–100 = 0 — Background Opacity
      - `displayAsButton` boolean = false — Display as button
      - `buttonLabel` text — Optional button label
      - `buttonSize` one of "small" | "big" = "big" — Button size
      - `title` text — Title
      - `goToSlideType` one of "specified" | "next" | "previous" = "specified" — Go to
      - `goToSlide` number 1– — Specific slide number: Only applicable when 'Specific slide number' is selected
      - `invisible` boolean = false — Invisible
    - `keywords` list of
      - `main` text
      - `subs` list of text
    - `slideBackgroundSelector` group
      - `imageSlideBackground` image file — Image
      - `fillSlideBackground` text — Pick a color
  - `keywordListEnabled` boolean = true — Keyword list
  - `keywordListAlwaysShow` boolean = false — Always show
  - `keywordListAutoHide` boolean = false — Auto hide
  - `keywordListOpacity` number 0–100 = 100 — Opacity
  - `globalBackgroundSelector` group
    - `imageGlobalBackground` image file — Image
    - `fillGlobalBackground` text — Pick a color
- `override` group — Behaviour settings.
  - `activeSurface` boolean = false — Activate Active Surface Mode
  - `hideSummarySlide` boolean = false — Hide Summary Slide
  - `showSolutionButton` one of "on" | "off" — Override "Show Solution" button: This option determines if the "Show Solution" button will be configured for each question individually (default) shown for all questions (Enabled) or disabled for a…
  - `retryButton` one of "on" | "off" — Override "Retry" button: This option determines if the "Retry" button will be configured for each question individually (default) shown for all questions (Enabled) or disabled for all questions (Di…
  - `summarySlideSolutionButton` boolean = true; only when hideSummarySlide is false — Show "Show solution" button in the summary slide
  - `summarySlideRetryButton` boolean = true; only when hideSummarySlide is false — Show "Retry" button in the summary slide
  - `enablePrintButton` boolean = false — Enable print button
  - `social` group; only when hideSummarySlide is false — Social Settings
    - `showFacebookShare` boolean = false — Display Facebook share icon
    - `facebookShare` group; only when showFacebookShare is true — Facebook share settings
      - `url` text = "@currentpageurl" — Share to Facebook link
      - `quote` text = "I scored @score out of @maxScore on a task a… — Share to Facebook quote
    - `showTwitterShare` boolean = false — Display Twitter share icon
    - `twitterShare` group; only when showTwitterShare is true — Twitter share settings
      - `statement` text = "I scored @score out of @maxScore on a task a… — Share to Twitter statement
      - `url` text = "@currentpageurl" — Share to Twitter link
      - `hashtags` text = "h5p, course" — Share to Twitter hashtags
    - `showGoogleShare` boolean = false — Display Google+ share icon
    - `googleShareUrl` text = "@currentpageurl"; only when showGoogleShare is true — Share to Google link

53 interface texts are left out: they come from the libraries' translations. `h5p-author schema H5P.CoursePresentation --all` lists them, for a source to set one.

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