Skip to content

Commit

Permalink
Adds two extensions and documents them (lightly); improves workflow
Browse files Browse the repository at this point in the history
Adds two new extensions [davidwilby/openlinksinnewpage](https://github.com/davidwilby/openlinksinnewpage) and
[shafayetShafee/reveal-header](https://github.com/shafayetShafee/reveal-header) and updates documentation on usage.
  • Loading branch information
slackline committed Dec 9, 2023
1 parent ec4fcef commit 8292592
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 16 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/quarto-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@ jobs:

- name: Install Quarto Extensions
run: |
quarto install --no-prompt extension jmbuhr/quarto-qrcode
quarto install --no-prompt extension grantmcdermott/quarto-revealjs-clean
quarto install --no-prompt extension ArthurData/quarto-confetti
quarto add --no-prompt extension jmbuhr/quarto-qrcode
quarto add --no-prompt extension grantmcdermott/quarto-revealjs-clean
quarto add --no-prompt extension ArthurData/quarto-confetti
quarto add --no-prompt extension davidwilby/openlinksinnewpage
quarto add --no-prompt extension shafayetShafee/reveal-header
- name: Install Python and Dependencies
uses: actions/setup-python@v4
Expand Down
5 changes: 3 additions & 2 deletions .markdownlint-cli2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ globs:
- "**/*.qmd"

ignore:
- ".quarto/*"
- "_site/*"
- ".quarto/**/*.md"
- "_site/**/*.md"
- "renv/**/*.md"

# Fix any fixable errors
fix: true
29 changes: 23 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,16 @@ website:
This template uses some [extensions](https://quarto.org/docs/extensions/)
([quarto-clean](https://github.com/grantmcdermott/quarto-revealjs-clean), [QR
extension](https://github.com/jmbuhr/quarto-qrcode) and [confetti](https://github.com/ArthurData/quarto-confetti)) and
extension](https://github.com/jmbuhr/quarto-qrcode), [confetti](https://github.com/ArthurData/quarto-confetti)),
[openlinksinnewpage](https://github.com/davidwilby/openlinksinnewpage) and [reveal-header](https://github.com/shafayetShafee/reveal-header)
these need to be installed locally _before_ you can proceed.
``` bash
quarto install --no-prompt extension jmbuhr/quarto-qrcode
quarto install --no-prompt extension grantmcdermott/quarto-revealjs-clean
quarto install --no-prompt extension ArthurData/quarto-confetti
quarto add --no-prompt jmbuhr/quarto-qrcode
quarto add --no-prompt grantmcdermott/quarto-revealjs-clean
quarto add --no-prompt ArthurData/quarto-confetti
quarto add --no-prompt davidwilby/openlinksinnewpage
quarto add --no-prompt shafayetShafee/reveal-header
```

### Publish Locally
Expand Down Expand Up @@ -92,9 +95,10 @@ self](https://rse.shef.ac.uk/blog/pre-commit/) or refer to the official document

## Extensions

There are a growing number of useful [Quarto extensions](https://quarto.org/docs/extensions/). Three are included in this
There are a growing number of useful [Quarto extensions](https://quarto.org/docs/extensions/). Five are included in this
template and they are also installed during the publishing and deployment of the resulting slides as they are listed in
the `quarto-publish.yml`. You should have installed these locally as instructed above.
the `quarto-publish.yml` under the `Install Quarto Extensions` step. You should have installed these locally as
instructed above.

If you use additional extensions then as well as installing them locally on your computer you **MUST** remember to add
them to the `Install Quarto Extensions` section of `.github/workflows/quarto-publish.yaml` otherwise your pages will not
Expand All @@ -116,6 +120,19 @@ theme. For a full example of all the features of this theme see the authors
The [confetti](https://github.com/ArthurData/quarto-confetti) extension adds some eye-candy and throws confetti over
your slides whenever you press the `c` button. They originate from the mouse location and therefore follow it around.

### Open Links In New Page

The [openlinksinnewpage](https://github.com/davidwilby/openlinksinnewpage) extension does what it says on the tin and
ensures that when you click on a link in the resulting slides it will open a new tab/page (this saves you and others who
may not know of the shortcut from having to hold down `Ctrl` to achieve the same effect).

### Reveal Header

The [reveal-header](https://github.com/shafayetShafee/reveal-header) extension allows you to add headers as well as
footers to all slides. This template includes a simple text `header:` nested under the `format: <theme>:` YAML header
in `index.qmd`. Please refer to the [documetation](https://github.com/shafayetShafee/reveal-header) for further
customisation such as adding a `header-logo` and other options available with this extension.

## Embedding Code

The beauty of Quarto is that it is a literate programming system which means you can embed code that is executed and the
Expand Down
16 changes: 11 additions & 5 deletions index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ format:
chalkboard: true
# embed-resources: true
# standalone: true
header: Quarto RevealJS Template
revealjs-plugins:
- confetti
footer: "**Slides** : [**github-username.github.io/<repository>**](https://github-username.github.io/<repository>)"
Expand All @@ -24,11 +25,14 @@ project:
port: 7864
host: localhost
watch-inputs: true
filters:
- openlinksinnewpage
- reveal-header
---

## Scan This!
## Scan This

{{< qrcode https://ns-rse.github.io/quarto-revealjs-template qr1 width=400 height=400 >}}
{{< qrcode <https://ns-rse.github.io/quarto-revealjs-template> qr1 width=400 height=400 >}}

[ns-rse.github.io/quarto-revealjs-template](https://ns-rse.github.io/quarto-revealjs-template)

Expand Down Expand Up @@ -164,7 +168,7 @@ You can write equations if you need to.
[Figures](https://quarto.org/docs/authoring/figures.html) can be embeded using a URL and resized.

```markdown
![Relaxing in the mountains](https://live.staticflickr.com/65535/53144704609_c5e6fa8c77_k.jpg){width=700}
![Relaxing in the Julian Alps](https://live.staticflickr.com/65535/53144704609_c5e6fa8c77_k.jpg){width=700}
```

![Relaxing in the Julian Alps](https://live.staticflickr.com/65535/53144704609_c5e6fa8c77_k.jpg){width=700}
Expand Down Expand Up @@ -316,17 +320,19 @@ The official documentation is really good.

:::: {.columns}

::: {.column width="50%"}
::: {.column width="70%"}
[Extensions](https://quarto.org/docs/extensions/) for themes and other functionality
(press `c` whilst viewing these slides :wink: ).

+ [Shortcode/Filter](https://quarto.org/docs/extensions/listing-filters.html)
+ [Journal Articles](https://quarto.org/docs/extensions/listing-journals.html)
+ [Custom Formats](https://quarto.org/docs/extensions/listing-formats.html)
+ [**RevealJS**](https://quarto.org/docs/extensions/listing-revealjs.html)
+ [awesome-quarto](https://github.com/mcanouil/awesome-quarto) - Quarto tools & examples

:::
::: {.column width=50%}
::: {.column width=30%}
This Template...
{{< qrcode <https://ns-rse.github.io/quarto-revealjs-template> qr2 width=400 height=400 >}}
:::
::::

0 comments on commit 8292592

Please sign in to comment.