Find the classic beamer outdated? Are your students losing focus due to it? 💤
I'm not sure how to solve the last one, but this theme is my attempt to address the first issue: too many a new presentation look decades old due to the classic look of beamer.
Note
Marp is a presentation framework that allows users to create presentations with Markdown and CSS.
Inspired by, but not affiliated with or sourced from, the Marp beam theme made by rnd195. As mentioned, I have not used any of their code to create this theme.
Important
None of the following is legal advice. Consult a professional. This theme uses free-to-use fonts, and should be okay for personal use, but do conduct your own research before hosting any large presentation with it.
Consider the license of this project as well, and Marp's license itself.
All fonts used in the theme by default are imported from Google Fonts. Consider the privacy aspects of this yourself and choose wheter you want local installs of them or not. This was a choice made to enable direct linking of the theme to work.
🔴 Live preview 🔴
Live previews for the other color schemes further down!
| NEObeam | beamer |
|---|---|
Image on the right courtesy of latextemplates.com. Will eventually be replaced by my own.
| Math | Code |
|---|---|
| Images | Tables |
|---|---|
Note
This is optionally enabled! See features & quirks.
Click on the theme to see a live preview
| Theme | Based on |
|---|---|
| neobeam | |
| neobeam-beamer | beamer color scheme |
| neobeam-dsek | LTH D-sektionen design profile |
| neobeam-csek | LTH C-sektionen design profile |
| neobeam-lund | Lund University design profile |
| neobeam-embracket | Embracket design language |
| neobeam-neonbeam | Inspired by neon colors |
| neobeam-oldenbeam | Inspired by coal? |
| neobeam-ecobeam | Inspired by nature? |
More are available in the repo!
| Default | beamer | LTH D-sektionen |
|---|---|---|
| LTH C-sektionen | LTH/Lund University | Embracket |
|---|---|---|
| Neonbeam | Oldenbeam | Ecobeam |
|---|---|---|
Note
Until a future timepoint, I won't provide a guide on how to use it with Marp CLI, as I expect CLI users to be technical enough to know how to do this. You can read the Marp CLI documentation here, and inspect the preview creation script for some examples.
- Git or zip
- Visual Studio Code
- Marp Extension for Visual Studio Code
Tip
This theme by default uses the fonts Roboto, Roboto Mono (for code) and Noto Sans Math (for math), as well as some others depending on the version of the theme. These are imported in the CSS file, but you can aquire them yourself too, or change them out. In the LTH C-sektionen and D-sektionen themes, Roboto is switched out for Helvetica.
Warning
For reasons beyond my comprehension, it is necessary to use different notation for hsl in CSS in the Marp VS code preview as compared to the build version sometimes. To mitigate this I have added a build-multiplier variable to the CSS files. Set this to 1 when necessary, otherwise 100.
- Download or copy the neobeam.css file into your project OR use the direct link. If using specific themes, do remember they are dependent on the base theme.
- Add it to your VSCode settings by editing your
.vscode/settings.jsonfile and appending:
//...
{
"markdown.marp.themes": [
//...
"path/to/neobeam.css"
//...
]
}
//...where path/to/neobeam.css is either local, for example css/neobeam.css or the direct link to the repo's CSS file, ex: https://raw.githubusercontent.com/mikael-ros/neobeam/main/css/neobeam.css. Keep in mind that using the direct link might cause your presentation to change over time and it's best you have a local copy instead. When you are using any derivative theme, you also need to import the base neobeam theme.
- Add it to your Marp presentation by adding:
marp: true
theme: neobeam
paginate: true
math: katex
footer: '**Author**
**Title**
**Conference/course/e.t.c.**'The theme names are written as presented in the table in the previews section.
4. Change build-multiplier to 1, if the preview looks wrong. Do not forget to change it back before you build.
If you are, against all odds, using more than 1000 slides, and the pagination wraps, go into
neobeam.cssand modifysection::after'swidth, and correspondingly the--pagination-spaceinfooter > *:last-child.
Simply clone or fork this repo or download the release. If you wish, you can delete the previews folder.
All themes are registered and ready in the template.
Most things work like you'd expect, but there are some quirks to keep the cogs turning.
This theme has some variables for easier tweaking, aiding inexperienced users and power-users alike.
You can use any of these variables to easily change most things about the theme. The direct variables are meant for easy tweaking, whereas the dependent variables are not necessarily meant to be referenced. Deeper customization can be achieved by modifying the CSS itself.
These variables are meant to be set by the user, and have snowball effects.
| Variable name | Purpose | What does it affect? |
|---|---|---|
build-multiplier |
Changes the overall multiplication of all color values. Used when there are inconsistencies between the preview and build. | Changes all colored elements. |
saturation-multiplier |
Multiplies all cases where saturation is added. | Affects darker-primary and darkest-primary. See the variables individual descriptions in the next section on "dependent variables". |
desaturation-multiplier |
Multiplies all cases where saturation is removed. | Affects lighter-primary, text-color, text-color-negative, highlight-color-two, highlight-color-three, and the background color for the definition blocks. ee their individual descriptions in the next section. |
brightness-multiplier |
Multiplies all cases where brightness is added. | Affects lighter-primary, text-color-lighter, text-color-lightest, text-color-negative, text-color-negative-lighter, text-color-negative-lightest, highlight-color-two, highlight-color-three, and the highlight brightness of mark elements. See the variables individual descriptions in the next section on "dependent variables". |
darkness-multiplier |
Multiplies all cases where brightness is removed. | Affects darker-primary, darkest-primary, text-color, text-color-negative-darker, and the background color of the definition blocks. See the variables individual descriptions in the next section on "dependent variables". |
color-shift-degrees |
Shifts the colors for sequenced definition blocks by the specified amount of degrees times some factor. | Affects highlight-color-two and highlight-color-three. See the variables individual descriptions in the next section on "dependent variables". |
default-font |
Sets the font for the majority of the text. | Affects the root font-family, e.g. the font for the document as a whole. |
monospace-font |
Sets the monospace font, used in code blocks, e.t.c. | Affects the font used for pre (code blocks), code (inline code snippets), and samp (sample code outputs). |
math-font |
Sets the math font, used in math blocks. | .katex (math blocks). |
font-size |
Sets the font size for the document. The variable is referenced in several locations. | Used to set the root font-size, and also affects where the pagination index is placed. |
primary |
Sets the primary color for the document. | Affects lighter-primary, darker-primary, darkest-primary, text-color, text-color-negative, highlight-color-one, highlight-color-two, highlight-color-three, the color of section header, the color of footer, the color of footers last child, and the title page header's color. See the variables individual descriptions in the next section on "dependent variables". |
definition-height |
Sets the height of definition blocks. | Affects definition block heights. |
header-height |
Sets the height of the headers. | Affects footer-height, top-margin, left-right-margin, and header heights. See the variables individual descriptions in the next section on "dependent variables". |
text-padding |
Sets the text padding within various elements. | Affects the text padding around all elements that contain text, essentially (too many to list). |
border-radius-default |
Sets the border radius of various elements. | Affects border-radius-softer, border-radius-harder, and all rounded elements (too many to list). See the variables individual descriptions in the next section on "dependent variables". |
These variables set themselves automatically through using the previously described direct variables, but you can also edit them manually.
| Variable name | Purpose | What does it change? |
|---|---|---|
lighter-primary |
Sets the lighter version of the primary color. | The color of th (table headers). |
darker-primary |
Sets the darker version of the primary color. | The color of the middle portion of the footer. |
darkest-primary |
Sets an even darker version of the primary color. | The color of the first portion of the footer. |
text-color |
Sets the primary text color. | The root color of text. Also effects it's own derived variables, seen below. |
text-color-lighter |
Sets the lighter version of the primary text color. | Various text elements. |
text-color-lightest |
Sets the lightest version of the primary text color. | Various text elements. |
text-color-negative |
Sets the opposite text color, mainly used for when text is set against a poorly contrasted background. | Various text elements. |
text-color-negative-lighter |
Sets the lighter opposite text color. | Various text elements as well as background-color. |
text-color-negative-lightest |
Sets the lightest opposite text color. | Various text elements. |
text-color-negative-darker |
Sets the darker opposite text color. | Various text elements. |
highlight-color-one |
Sets the first highlight color. | The first variety of definition block. |
highlight-color-two |
Sets the second highlight color. | The second variety of definition block in addition to mark and samp. |
highlight-color-three |
Sets the third highlight color. | The third variety of definition block. |
footer-height |
Sets the footer height. | The height of the footer, the position of the pagination index, left-right-margin, and bottom-margin. |
top-margin |
Sets the top margin of each slide. | Used in margin. |
left-right-margin |
Sets the margins on the left and right sides of the slides. | Used in margin. |
bottom-margin |
Sets the bottom margin of each slide. | Used in margin. |
margin |
Uses the previous three variables to set an overall margin. | Sets the margin of section, e.g. the margin of each slide. |
border-radius-softer |
Sets the radius of "softer" elements. | Nothing, currently. |
border-radius-harder |
Sets the radius of "harder" elements. | Nothing, currently. |
background-color |
Sets the background color of all the slides. | The background-color of section, e.g. the color of each slide. |
I opted not to always treat the first slide as a title slide, so to declare a slide (any slide actually) a title slide, add the following before the content: <!-- _class: title -->.
Heres an example of a title slide. As long as you follow as similar format it should work. Theres also an optional logo slot for a University logo or similar.
<!-- _class: title -->
# Title
## Author
> ### Faculty
> University
## Conference/course/e.t.c.
Like other images, the logo can be assigned left side too.
Every page has a footer. It's made from the footer content defined in the beginning of the presentation markdown, and the sections are split by using ** (to create children objects). The footer is a flex-box and I've made it split itself into three sections. You could likely with some modifications change this fairly easily.
I've opted to use KaTeX, and have not styled for other options yet.
To make LaTeX style bubble definitions I've had to do a slight work around to avoid using HTML in Marp. To define a definition, write the following:
> #### Definition title
> Definition descriptionThe first 3 of these will have unique colors, but after that all of them will have the same. If you wish to add more, change the CSS-file around the blockquote:nth-of-type part of the stylesheet.
This stylesheet supports adding a tag in the alt text for left, center and right alignment. To define this, you would write something like: . Do note this might cause issues when using these words in your alt text in a normal sentence.
There is light HTML support, including the elements:
<mark>(highlighting)<q>(inline quotes)<var>(variables)<samp>(code output)<audio>(audio)<abbr>(abbreviations).
To enable HTML support add or modify the line "markdown.marp.html": true in .vscode/settings.json (or globally).
Warning
Considering the security issues mentioned in Marps documentation, this is disabled by default, even in the template. You may need to restart Visual Studio Code after changing the setting. You will need to export in HTML for interactive elements to function.
Feel free to contribute 💙