Quarto revealjs presentations
Add the extension by running the following code in the terminal
Then add it as a filter in the yaml like so
Use arrow keys or spacebar to trigger annotations. Add the .rn-fragment class to any span or div.
This text has a highlighted word that appears on trigger.
And this has an underlined phrase.
All options are prefixed with rn-:
| Option | Example | Description |
|---|---|---|
rn-type |
rn-type=underline |
Annotation style (underline, box, circle, highlight, strike-through, crossed-off, bracket) |
rn-color |
rn-color=blue |
Annotation color |
rn-animate |
rn-animate=false |
Disable animation |
rn-animationDuration |
rn-animationDuration=2000 |
Animation duration in milliseconds |
rn-strokeWidth |
rn-strokeWidth=3 |
Line thickness |
rn-padding |
rn-padding=10 |
Space around element in pixels |
rn-multiline |
rn-multiline=true |
Annotate across multiple lines |
rn-iterations |
rn-iterations=1 |
Number of drawing passes |
rn-brackets |
rn-brackets=left,right |
Bracket sides (for bracket type only) |
rn-rtl |
rn-rtl=true |
Draw right-to-left |
Set the annotation style. Default is highlight.
Underline
Box
Circle
Highlight
Strike-Through
Crossed-off
Bracket
Div with rn-type=box
Set the annotation color. Default is yellow highlight color.
Blue | Red | Green | Purple
Div with rn-color=orange
Colors can be specified in multiple formats:
Color name - rn-color=tomato
Hex code - rn-color=#3498db
Hex with alpha - rn-color=#e74c3c80 (50% opacity)
RGB - rn-color="rgb(46, 204, 113)"
RGBA - rn-color="rgba(155, 89, 182, 0.5)"
Disable animation with rn-animate=false. Default is true.
With animation (default)
Without animation
Div without animation
Set animation duration in milliseconds. Default is 800.
Fast (200ms)
Default (800ms)
Slow (2000ms)
Div with 1500ms animation
Set line thickness. Default is 1.
Thin (1)
Medium (3)
Thick (5)
Div with rn-strokeWidth=4
Set space around the element in pixels. Default is 5.
No padding (0)
Default padding (5)
Large padding (20)
Div with rn-padding=15
Enable annotations across multiple lines with rn-multiline=true.
Lorem ipsum dolor sit amet. This span wraps across multiple lines to demonstrate the multiline option working correctly. Consectetur adipiscing elit.
This div spans multiple lines and uses multiline mode for proper annotation rendering.
Set the number of drawing passes. Default is 2. Higher values create rougher look.
One pass (1)
Default (2)
Many passes (5)
Div with rn-iterations=4
For rn-type=bracket, specify which sides to draw. Options: left, right, top, bottom.
Right bracket (default)
Left bracket
Both sides
Div with top and bottom brackets
Draw annotation right-to-left with rn-rtl=true. Default is false.
Left-to-right (default)
Right-to-left
Div with right-to-left animation
Control order with fragment-index. Lower numbers trigger first.
Third
First
Second
The following 2 slides show the legacy R key interface. This still works but the fragment interface above is recommended.
Press R to activate notation animations
I will be highlighted, and so will these words right here
(Press R to show)
Set rn-index to control order when using the R key trigger:
No rn-index
rn-index set to 1
rn-index set to 2
rn-index set to 3
rn-index set to 4