Lecture v1.0.0 w/ by Caboodle Tech
Lecture v1.0.0 w/ by Caboodle Tech
Press → to learn more or download Lecture and start creating presentations in minutes!
Press ↓ for an overview of features.
Press → for a live demo.
Transform simple text instructions into diagrams and charts with Mermaid.
Easily display code examples with Highlight JS Lite.
SELECT
passage_name,
location,
destination
FROM
hogwarts_secret_passages
WHERE
destination LIKE '%Room of Requirement%';
KaTex macros and math formulas are supported.
MathJax3 math formulas are supported.
All of the following media elements are supported with various advanced settings you can configure:
Presentation wide or slide specific background images, animated gifs, and videos are also supported!
And of course... fragments, animations, and auto advancement is supported.
Including combinations like highlighting text.
Fading in, then out.
Sliding up while fading in to name a few.
Press ↓ to view important keyboard shortcuts.
Press Shift + ? to view all shortcuts at once.
S | Open speaker view |
F | Enter fullscreen view |
D / L | Enable dark / light theme |
B or . | Blackout view |
Shift + P | Open print view |
Press O or Esc to bring up the presentation overview. Using your arrow keys you can navigate to the slide you want and press Space to select it.
Press G to enter a slide number to preview then Enter to jump to your selection or Esc to cancel.
You can also jump to a child slide with the pattern #/#
. Entering 2/3
would be slide 2 child 3.
← or H | Navigate left |
→ or L | Navigate right |
↑ or K | Navigate up |
↓ or J | Navigate down |
N or Space | Go forward |
P or Shift + Space | Go backward |
Alt + ← / → / ↑ / ↓ | Skip fragments + navigate |
Shift + ← or → | Jump to first or last slide |
Presentations are built with standard html and are split into slides (<section>
).
Press ↓ for a crash course in building your first presentation.
All presentations should be wrapped in two <div>
elements with the appropriate classes:
<div class="lecture">
<div class="slides">
<!-- Your slides go here. -->
</div>
</div>
Separate slides are created by wrapping individual slide content in <section>
elements:
<section>
<h1>Slide 1</h1>
<p>A paragraph in slide 1.</p>
</section>
<section>
<h1>Slide 2</h1>
<p>A paragraph in slide 2.</p>
</section>
To create vertical slide sections like what you are viewing now, wrap your slides in a <section>
element:
<section>
<section>
<h1>Child 1</h1>
<p>A paragraph in child 1.</p>
</section>
<section>
<h1>Child 2</h1>
<p>A paragraph in child 2.</p>
</section>
</section>
Setting various attributes on the slide or presentations <section>
element allows you to add all kinds of backgrounds.
Refer to the Reveal demo for more information.
Use one of these classes on the <section>
tag to alter the slides content:
left | Left align content |
center | Center align content (default) |
right | Right align content |
Add these classes to the element you would like to alter or add globally to <div class="slides">
:
r-fit-text | Auto fit text |
hide-numbers | Hides line numbers in code samples |
show-numbers | Shows line numbers in code samples |
inline-line-numbers | Simplify code sample line numbers |
Use one of these classes on the <section>
tag to alter the slides layout:
two-col | 2 column layout |
three-col | 3 column layout |
two-col-with-title | 2 columns with a title |
three-col-with-title | 3 column with a title |
To disable the row border in tables add the no-border
class to the <table>
tag.
You may add the left
or right
class to the <div class="slides">
element to overwrite the default style of centered content for the whole presentation.
Notice a change? Slide templates can automatically apply styles, logos, backgrounds, copyrights, and more to slides.
Press ↓ to learn how to add your own slide templates.
To create a new slide template add the slide-template
class to a <section>
:
<section class="slide-template">
<img src="..." class="logo">
<img src="..." class="logo dark-mode">
<p class="copyright">...</p>
<div class="background"></div>
</section>
Keep the following in mind when creating a template:
<section>
elements.
Name templates by adding the data-template
attribute to a templates element:
<section class="slide-template" data-template="demo-alt">
<!-- slide template -->
</section>
Apply a specific template to a slide by adding the data-template
attribute and the name to your slide(s) <section>
element(s):
<section data-template="demo-alt">
<!-- slide -->
</section>
Applying a template to the parent of a vertical section of slides will cause all nested slides to inherit that template and ignore any individually set templates:
<section data-template="demo-alt">
<section>
<!-- slide -->
</section>
<section>
<!-- slide -->
</section>
</section>
Lecture includes generic styles and css variables for the following elements and classes in slide templates.
<img src="..." class="logo">
<img src="..." class="logo dark-mode">
<p class="copyright">...</p>
<div class="background"></div>
You should be able to affect a lot without having to add additional HTML or styles of your own.
You can add various charts and diagrams using the Mermaid syntax.
Press ↓ for a crash course in adding Mermaid charts and diagrams to your presentations.
All charts and diagrams should be wrapped in a div
element with the mermaid
class:
<div class="mermaid">
graph LR;
A[Start] --> B[Process 1];
B --> C[Process 2];
C --> D[Process 3];
D --> E[End];
</div>
The previous code sample would create this graph:
But there are so many other diagrams.
Take a ↓ look!
If fact you can create anyone of these:
And many more not listed here!
Adding code to your presentation is a simple process with a few important rules.
Press ↓ for a crash course in adding code samples to your presentations.
Code samples should be wrapped with <pre><code>
elements with any <
and >
characters converted to their HTML entities <
and >
.
It is highly recommended to include the code samples language code as a class in the <code>
element. Check out the example ↓ for a visual.
Notice the pattern <pre><code class="?">
where you replace ?
with the language code:
<pre>
<code class="js">
// This is a javascript example
const happy = true;
const sad = false;
</code>
</pre>
NOTE: Color highlight is off in this demo because of how we have to write the demo code for you. Proper syntax highlight will appear in your presentations.
Line numbers are enabled by default. To disable line numbers add the hide-numbers
class to the <pre>
element like so: <pre class="hide-numbers">
You can also add the class inline-line-numbers
to simplify the line number styles. These classes can also be added globally to change all code samples.
Lecture supports KaTeX and MathJax3 math. You can use both together in the same presentation.
Press ↓ for a crash course in adding math examples to your presentations.
KaTeX and MathJax3 math should be placed inside a <div>
element with the appropriate class added:
<!-- Katex example: -->
<div class="katex">
Add KaTeX math here...
</div>
<!-- MathJax example: -->
<div class="mathjax-3">
Add MathJax math here...
</div>
If you would like to add a macro to Katex, declare the macro in a <div>
element with the katex-macro
class.
The new macro is declared as: [\name] = [macro]
To declare more than one macro at a time, place ---
on its own line in-between each macro definition.
Here is how to declare two katex macros at once:
<div class="katex-macro">
\prs = \pi r^3
---
\sphere = \dfrac{4}{3} \prs
</div>
<!-- And then use these macros: -->
<div class="katex">
V = \sphere
</div>
NOTE: The math was intentionally made harder to demo using macros.
You can build slides or an entire presentation with standard markdown. Lecture also supports some advanced markdown syntax.
Press ↓ for a crash course in adding markdown to your presentations.
To declare a slides content as markdown add the data-markdown
attribute to the <section>
element:
<section data-markdown>
## Heading
A paragraph with a [link](https://example.com).
</section>
To make an entire presentation out of markdown use only one <section>
element and ---
, markdowns horizontal rule, to separate slides:
<section data-markdown>
## Slide 1
A paragraph with a [link](https://hakim.se).
---
## Slide 2
---
## Slide 3
</section>
Lecture implements the standard common mark markdown syntax in addition to some GitHub Flavored markdown.
Lecture uses special markdown syntax ↓ to add attribute support for images and links.
You can add any attribute to an image or link in markdown by adding the attributes in {...}
after the standard image or link syntax:
<!-- Link that opens in a new tab instead. -->
[Link Text](URL){target="_blank"}
<!-- Image with a constrained width -->
![Alt Text](URL){width="100"}
You can add as many attributes you like just separate them with a space: {target="blank" rel="nofollow"}
Your can also place images with attributes inside links:
<!-- An image being used as a link with attributes. -->
[![Alt Text](URL){width="100"}](URL){target="_blank"}
Use standard HTML for the following media elements:
The Reveal documentation explains advanced features and settings for these elements.
Text fragments and slide transitions require adding the appropriate classes and/or attributes to elements.
Click on the above links to be taken to the Reveal documentation for these features.
Download Lecture and start creating your own presentations in minutes!