Skip to content
This repository was archived by the owner on Feb 6, 2024. It is now read-only.

Commit f4e3a43

Browse files
Merge pull request #782 from deckgo/header-footer
feat: header and footer
2 parents 0656e0f + 01a4e8d commit f4e3a43

File tree

197 files changed

+5817
-6625
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

197 files changed

+5817
-6625
lines changed

CHANGELOG.md

Lines changed: 39 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,55 @@
1-
<a name="1.6.0"></a>
1+
<a name="2.0.0"></a>
22

3-
# [1.6.0](https://github.com/deckgo/deckdeckgo/compare/v1.5.0...v1.6.0) (In progress...)
3+
# [2.0.0](https://github.com/deckgo/deckdeckgo/compare/v1.5.0...v1.6.0) (In progress...)
4+
5+
### Breaking Changes
6+
7+
Because we are introducing the `header` and `footer` features, slots in the templates `gif` and `aspect-ratio` had to be renamed to avoid name collision.
8+
9+
Therefore, if you would edit such templates with our editor or developer kit, created before these releases, these modifications have to be performed in your content.
10+
11+
Ping [me](mailto:[email protected]) if you need any help or have questions.
12+
13+
Best regards,
14+
15+
David
416

517
### Applications
618

7-
- docs: v1.6.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/docs/CHANGELOG.md))
8-
- remote: v1.5.1 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/remote/CHANGELOG.md))
9-
- studio: v1.6.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/studio/CHANGELOG.md))
19+
- demo: v2.4.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo-website/blob/master/CHANGELOG.md))
20+
- docs: v1.7.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/docs/CHANGELOG.md))
21+
- remote: v1.6.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/remote/CHANGELOG.md))
22+
- studio: v2.0.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/studio/CHANGELOG.md))
23+
24+
### Web Components Templates
25+
26+
- slide-aspect-ratio: v2.0.1 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/aspect-ratio/CHANGELOG.md))
27+
- slide-author: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/author/CHANGELOG.md))
28+
- slide-big-img: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/big-img/CHANGELOG.md))
29+
- slide-chart: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/chart/CHANGELOG.md))
30+
- slide-code: v1.2.3 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/code/CHANGELOG.md))
31+
- slide-content: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/content/CHANGELOG.md))
32+
- slide-countdown: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/countdown/CHANGELOG.md))
33+
- slide-gif: v2.0.1 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/gif/CHANGELOG.md))
34+
- slide-playground: v1.1.3 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/playground/CHANGELOG.md))
35+
- slide-poll: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/poll/CHANGELOG.md))
36+
- slide-qrcode: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/qrcode/CHANGELOG.md))
37+
- slide-split: v1.3.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/split/CHANGELOG.md))
38+
- slide-title: v1.1.3 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/title/CHANGELOG.md))
39+
- slide-video: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/video/CHANGELOG.md))
40+
- slide-youtube: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/slides/youtube/CHANGELOG.md))
1041

1142
### Web Components
1243

44+
- core: v1.1.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/core/CHANGELOG.md))
1345
- highlight-code: v1.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/highlight-code/CHANGELOG.md))
1446
- social: v2.0.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/webcomponents/social/CHANGELOG.md))
1547

1648
### Others
1749

1850
- gatsby-remark-highlight-code: v1.4.4 ([CHANGELOG](https://github.com/deckgo/gatsby-remark-highlight-code/blob/master/CHANGELOG.md))
19-
- starter kit: v2.5.3 ([CHANGELOG](https://github.com/deckgo/deckdeckgo-starter/blob/master/CHANGELOG.md))
51+
- slide-utils: v2.1.2 ([CHANGELOG](https://github.com/deckgo/deckdeckgo/blob/master/utils/slide/CHANGELOG.md))
52+
- starter kit: v2.6.0 ([CHANGELOG](https://github.com/deckgo/deckdeckgo-starter/blob/master/CHANGELOG.md))
2053

2154
<a name="1.5.0"></a>
2255

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ Are you interested to contribute to our open source project? That would be aweso
4747
| ------------------ | ----------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- | :--------------------------------------------------: |
4848
| **Studio** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v1.5.0&color=success)](https://deckdeckgo.com) | [https://deckdeckgo.com](https://deckdeckgo.com) | [`README.md`](studio/README.md) |
4949
| **Remote control** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v1.5.1&color=success)](https://deckdeckgo.app) | [https://deckdeckgo.app](https://deckdeckgo.app) | [`README.md`](remote/README.md) |
50-
| **Documentation** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v1.6.2&color=success)](https://docs.deckdeckgo.com) | [https://docs.deckdeckgo.com](https://docs.deckdeckgo.com) | [`README.md`](docs/README.md) |
51-
| **Demo** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v2.3.0&color=success)](https://demo.deckdeckgo.com) | [https://demo.deckdeckgo.com](https://demo.deckdeckgo.com) | [`Repo`](https://github.com/deckgo/deckdeckgo-demo/) |
50+
| **Documentation** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v1.7.0&color=success)](https://docs.deckdeckgo.com) | [https://docs.deckdeckgo.com](https://docs.deckdeckgo.com) | [`README.md`](docs/README.md) |
51+
| **Demo** | [![version](https://img.shields.io/static/v1.svg?label=production&message=v2.4.0&color=success)](https://demo.deckdeckgo.com) | [https://demo.deckdeckgo.com](https://demo.deckdeckgo.com) | [`Repo`](https://github.com/deckgo/deckdeckgo-demo/) |
5252

5353
## Web Components
5454

@@ -107,7 +107,7 @@ Are you interested to contribute to our open source project? That would be aweso
107107
| **Cloud** | | ![version](https://img.shields.io/static/v1.svg?label=production&message=v1.1.1&color=success) | [`README.md`](cloud/README.md) |
108108
| **Gatsby plugin highlight code** | | ![version](https://img.shields.io/static/v1.svg?label=version&message=v1.4.4&color=success) | [`Repo`](https://github.com/deckgo/gatsby-remark-highlight-code/) |
109109
| **Infrastructure** | | | [`README.md`](infra/README.md) |
110-
| **Starter kit** | | ![version](https://img.shields.io/static/v1.svg?label=version&message=v2.5.3&color=success) | [`Repo`](http://github.com/deckgo/deckdeckgo-starter/) |
110+
| **Starter kit** | | ![version](https://img.shields.io/static/v1.svg?label=version&message=v2.6.0&color=success) | [`Repo`](http://github.com/deckgo/deckdeckgo-starter/) |
111111
| **WAI Lambda** | | | [`Repo`](https://github.com/deckgo/wai-lambda) |
112112
| **Webpack plugins** | [`deckdeckgo-webpack-plugins`](https://www.npmjs.com/package/deckdeckgo-webpack-plugins) | [![version](https://img.shields.io/npm/v/deckdeckgo-webpack-plugins/latest.svg?color=success)](https://www.npmjs.com/package/deckdeckgo-webpack-plugins) | [`README.md`](webpack/README.md) |
113113

docs/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
# 1.7.0 (2020-07-11)
2+
3+
### Features
4+
5+
- group `notes` in a single page
6+
- add new `header` and `footer`
7+
18
# 1.6.2 (2020-07-02)
29

310
### Style

docs/docs/deck/app-deck-background/app-deck-background.md

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Background
22

3-
Beside slides and templates, a [DeckDeckGo] deck could also contains a customized element `background` which could be injected using a dedicated `slot`.
3+
Beside slides and templates, a [DeckDeckGo] deck could also contain a customized element `background` which could be injected using a dedicated `slot`.
44

55
## Table of contents
66

@@ -13,33 +13,29 @@ Beside slides and templates, a [DeckDeckGo] deck could also contains a customize
1313

1414
The slot `background` provided for the deck will be cloned into each slides of your presentation.
1515

16-
This slot is particularly useful if you wish to display your brand or company logo on each slides.
17-
18-
Also worth to notice, this slot will be `hidden` when the presentation will be displayed full screen.
19-
2016
Optionally, if you wish, this slot could also not be cloned, could be useful in case you rather would like to display a background which follows your entire presentation.
2117

2218
## Attributes
2319

2420
The following attribute could be applied to the `deckgo-deck` element:
2521

26-
| Property | Attribute | Mandatory | Description | Type | Default |
27-
| -------------- | --------------- | --------- | ----------- | --------- | ----------------------------------- |
28-
| `cloneBackground` | `clone-background` | | Set to false in case you don't want to clone the background in each slides | `boolean` | true |
22+
| Property | Attribute | Mandatory | Description | Type | Default |
23+
| ----------------- | ------------------ | --------- | -------------------------------------------------------------------------- | --------- | ------- |
24+
| `cloneBackground` | `clone-background` | | Set to false in case you don't want to clone the background in each slides | `boolean` | true |
2925

3026
## Theming
3127

3228
The following theming options will affect the slot `background` if set on the `deckgo-deck` or any slides.
3329

34-
| CSS4 variable | Default | Note |
35-
| -------------------------- |-----------------|-----------------|
36-
| --slide-background-position | absolute | The position of the background |
37-
| --slide-background-top | 0 | Top value |
38-
| --slide-background-end | | In LTR, right value |
39-
| --slide-background-start | 0 | In LTR, left value |
40-
| --slide-background-width | | A background width, default without being set all width |
41-
| --slide-background-height | | A background height, default without being set all height |
42-
| --slide-background-print-display | none | Don't print per default the background |
30+
| CSS4 variable | Default | Note |
31+
| -------------------------------- | -------- | --------------------------------------------------------- |
32+
| --slide-background-position | absolute | The position of the background |
33+
| --slide-background-top | 0 | Top value |
34+
| --slide-background-end | | In LTR, right value |
35+
| --slide-background-start | 0 | In LTR, left value |
36+
| --slide-background-width | | A background width, default without being set all width |
37+
| --slide-background-height | | A background height, default without being set all height |
38+
| --slide-background-print-display | none | Don't print per default the background |
4339

4440
## Examples
4541

@@ -53,7 +49,7 @@ An example with an image cloned as background for each slides:
5349
Hello World 🚀
5450
</p>
5551
</deckgo-slide-title>
56-
52+
5753
<img slot="background" data-src="https://deckdeckgo.com/assets/favicon/android-chrome-512x512.png">
5854
</deckgo-deck>
5955
```
@@ -68,7 +64,7 @@ An example with a more complex html and css element which is set as background f
6864
Hello World 🚀
6965
</p>
7066
</deckgo-slide-title>
71-
67+
7268
<div class="circle" slot="background"></div>
7369
</deckgo-deck>
7470
```
@@ -91,4 +87,4 @@ div.circle {
9187
}
9288
```
9389

94-
[DeckDeckGo]: https://deckdeckgo.com
90+
[deckdeckgo]: https://deckdeckgo.com
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
# Header &amp; Footer
2+
3+
Header and footer can be added to a [DeckDeckGo] deck or to any slides using their dedicated slots `header` and `footer`.
4+
5+
## Table of contents
6+
7+
- [Introduction](#app-deck-header-footer-introduction)
8+
- [Slides](#app-deck-header-footer-slides)
9+
- [Theming](#app-deck-header-footer-theming)
10+
11+
## Introduction
12+
13+
These elements are useful if you wish to display your brand or company logo on each slides.
14+
15+
To achieve this behavior, you can provide a slot `header` or `footer` to the deck, these are going to be cloned into each slides of your presentation at runtime.
16+
17+
```
18+
<deckgo-deck>
19+
<deckgo-slide-title>
20+
<h1 slot="title">My presentation title</h1>
21+
<p slot="content">
22+
Hello World 🚀
23+
</p>
24+
</deckgo-slide-title>
25+
26+
<div slot="header"><img data-src="./assets/mylogo.png"/></div>
27+
<div slot="footer"><a href="https://deckdeckgo.com">DeckDeckGo</a></div>
28+
</deckgo-deck>
29+
```
30+
31+
## Slides
32+
33+
If you want to display a specific `header` and `footer` on a particular slide, you proceed as displayed above but on the slide level.
34+
35+
```
36+
<deckgo-deck>
37+
<deckgo-slide-title>
38+
<h1 slot="title">My presentation title</h1>
39+
<p slot="content">
40+
Hello World 🚀
41+
</p>
42+
43+
<div slot="header"><img data-src="./assets/mylogo.png"/></div>
44+
<div slot="footer"><a href="https://deckdeckgo.com">DeckDeckGo</a></div>
45+
</deckgo-slide-title>
46+
</deckgo-deck>
47+
```
48+
49+
In case you would like to have `header` and `footer` defined for your deck but also assign specific ones on a particular slide, use the following attributes:
50+
51+
| Attribute | Type | Default | Description |
52+
| ------------- | ------- | ------- | ------------------------------------------------------ |
53+
| custom-header | boolean | false | Set to `true` to defined a specific header for a slide |
54+
| custom-footer | boolean | false | Set to `true` to defined a specific footer for a slide |
55+
56+
For example:
57+
58+
```
59+
<deckgo-deck>
60+
<deckgo-slide-title custom-header custom-footer>
61+
<h1 slot="title">My presentation title</h1>
62+
<p slot="content">
63+
Hello World 🚀
64+
</p>
65+
66+
<div slot="header"><img data-src="./assets/my-special-logo.png"/></div>
67+
<div slot="footer"><img data-src="./assets/my-special-footer.png"/></div>
68+
</deckgo-slide-title>
69+
70+
<div slot="header"><img data-src="./assets/mylogo.png"/></div>
71+
<div slot="footer"><a href="https://deckdeckgo.com">DeckDeckGo</a></div>
72+
</deckgo-deck>
73+
```
74+
75+
## Theming
76+
77+
The following theming options will affect the slot `header` and `footer`.
78+
79+
| CSS4 variable | Default | Note |
80+
| ------------------------------ | ---------- | ---------------------------------------------------------- |
81+
| --slide-header-footer-z-index | -1 | |
82+
| --slide-header-max-height | 48px | On devices smaller as `1024px` the default value is `16px` |
83+
| --slide-header-justify-content | flex-start | |
84+
| --slide-header-margin-top | 16px | |
85+
| --slide-header-margin-end | 32px | |
86+
| --slide-header-margin-bottom | 16px | |
87+
| --slide-header-margin-start | 32px | |
88+
| --slide-footer-max-height | 32px | |
89+
| --slide-footer-justify-content | center | |
90+
| --slide-footer-margin-top | 16px | |
91+
| --slide-footer-margin-end | 16px | |
92+
| --slide-footer-margin-bottom | 16px | |
93+
| --slide-footer-margin-start | 16px | |
94+
95+
[deckdeckgo]: https://deckdeckgo.com
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Notes
2+
3+
Notes can be added to any slides. For such purpose, use the related slot `notes` to the particular slide you wish to comment.
4+
5+
Your notes are going to be automatically `displayed` in the [remote control](https://deckdeckgo.app).
6+
7+
```
8+
<deckgo-deck>
9+
<deckgo-slide-title>
10+
<h1 slot="title">My presentation title</h1>
11+
<div slot="notes">A note regarding this particular slide</div>
12+
13+
And another note on a new line about it too.
14+
</deckgo-slide-title>
15+
</deckgo-deck>
16+
```
17+
18+
## Publishing Notes
19+
20+
If you are using the [DeckDeckGo] starter kit and wish to make your notes accessible to anyone, you will need to mark them with the attribute `show`.
21+
22+
```
23+
<deckgo-deck>
24+
<deckgo-slide-title>
25+
<h1 slot="title">My presentation title</h1>
26+
<div slot="notes" show>A note displayed in the presentation within a modal accessible for anyone</div>
27+
</deckgo-slide-title>
28+
</deckgo-deck>
29+
```
30+
31+
## Markdown
32+
33+
The [remote control](https://deckdeckgo.app) supports Markdown for your notes too.
34+
35+
[deckdeckgo]: https://deckdeckgo.com

docs/docs/slides/app-slide-aspect-ratio/app-slide-aspect-ratio.md

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ We use this slide in the [DeckDeckGo] editor to let users create slides containi
1313
- [Framework integration](#app-slide-aspect-ratio-framework-integration)
1414
- [Usage](#app-slide-aspect-ratio-usage)
1515
- [Slots](#app-slide-aspect-ratio-slots)
16-
- [Notes](#app-slide-aspect-ratio-notes)
1716
- [Attributes](#app-slide-aspect-ratio-attributes)
1817
- [Example](#app-slide-aspect-ratio-example)
1918
- [Theming](#app-slide-aspect-ratio-theming)
@@ -87,33 +86,7 @@ The "Aspect Ratio" slide's Web Component could be integrated using the tag `<dec
8786

8887
### Slots
8988

90-
The slots `title`, `header` and `footer` are both optional. `header` and `footer` would be displayed over the content.
91-
92-
### Notes
93-
94-
Optionally a slot `notes` could be use to add some notes regarding the particular slide. These will be automatically `displayed` in the [remote control](https://deckdeckgo.app).
95-
96-
```
97-
<deckgo-deck>
98-
<deckgo-slide-aspect-ratio>
99-
<h1>An element</h1>
100-
<div slot="notes">A note regarding this particular slide</div>
101-
102-
And another note on a new line about it too.
103-
</deckgo-slide-aspect-ratio>
104-
</deckgo-deck>
105-
```
106-
107-
If you are using the [DeckDeckGo] starter kit and wish to make your notes accessible to anyone, you will need to mark them with the attribute `show`.
108-
109-
```
110-
<deckgo-deck>
111-
<deckgo-slide-aspect-ratio>
112-
<h1>An element</h1>
113-
<div slot="notes" show>A note displayed in the presentation within a modal accessible for anyone</div>
114-
</deckgo-slide-aspect-ratio>
115-
</deckgo-deck>
116-
```
89+
The slots `title`, `top` and `bottom` are both optional. `top` and `bottom` would be displayed over the content.
11790

11891
## Attributes
11992

0 commit comments

Comments
 (0)