fix code block auto-animate bug that caused unmatched lines to appear without fading in
added a line number offset option to the markdown plugin
this is the corresponding documentation.
see PR here: https://github.com/hakimel/reveal.js/pull/3409
add documentation for line number offset in markdown
Merge pull request #53 from flowolf/add-code-line-offset-to-markdown
add documentation for line number offset in markdown
Nice addition, thanks @flowolf!
add ln-start-from for code sections to markdown
add tests
Merge pull request #3409 from flowolf/add-code-line-offset-to-markdown
[Markdown plugin] add line number offset for code sections to markdown
added the option for a line number offset.
this was already possible with data-ln-number-offset
now it's possible in markdown as well.
see https://revealjs.com/code/#line-number-offset-4.2.0
I've openend a PR for revealjs.com too: https://github.com/reveal/revealjs.com/pull/53
the option to add line highlights is extended by an optional number offset for line numbers:
```javascript [1-5]
or
```javascript [256: 1-5]
or
```javascript [256:]
are valid.
fix search field centering, add slides as sponsor
@pamelafox Sorry about that! I just released version 4.5.0 which includes this change. I've added a Added in version 4.5.0
-label to the docs to save others the same confusion.
add version label to custom fragments
4.5.0
---
is the default slide separator so there shouldn't be any need to include it as an attribute. I tried running the example from the docs in a new reveal.js deck and it seems to work fine. Am I missing something?
fix prism/hljs conflict
All code samples on revealjs.com are glitchy because of a build error in the docs site. Looking into it now.
from https://revealjs.com/code/
iOS 16
I think it's a fair assumption that sync
should update slide classes.
Currently, the only time slide classes are update is when calling slide
, so a workaround for now is to do this:
Reveal.getSlidesElement().appendChild( document.createElement('section') );
Reveal.slide();
add demo of custom fragments
build latest css
I have a use case where I would want to write the following:
<div class="r-stack">
<div class="fragment fade-in-then-out" data-fragment-index="1-3">Variant 1</div>
<div class="fragment fade-in-then-out" data-fragment-index="4-6">Variant 2</div>
</div>
... individual fragments for 1 to 6.
I.e., have (stacked) fragments for the first three fragments, then for the subsequent 3.
This is possible, e.g., in latex beamer via \only<1-3>{Variant 1}
and that is elegant to use. Even multiple ranges may be given, e.g., \only<1-3,7>
. To not confuse users, it would be okay to add this as data-fragment-range
, too. But maybe it makes sense to copy some more concepts from beamer, e.g., differentiate between visibility (opacity) and disappearing (display:none). E.g. data-visible-range
and data-only-range
? Because these are no longer "fragments" of a page as originally intended with .fragment
.
I do not want to make three copies of that fragment because it contains a MathJax equation.
You can make a fragment appear and disappear at different indices by nesting fragments. Try this:
<section>
<div class="r-stack">
<div class="fragment" data-fragment-index="1">
<div class="fragment fade-out" data-fragment-index="4">
1-3
</div>
</div>
<div class="fragment" data-fragment-index="4">
<div class="fragment fade-out" data-fragment-index="7">
4-6
</div>
</div>
</div>
<p class="fragment" data-fragment-index="1">1</p>
<p class="fragment" data-fragment-index="2">2</p>
<p class="fragment" data-fragment-index="3">3</p>
<p class="fragment" data-fragment-index="4">4</p>
<p class="fragment" data-fragment-index="5">5</p>
<p class="fragment" data-fragment-index="6">6</p>
</section>
Thanks @kno10 for adding this to the docs.
I've reduced the specificity of all reveal.js fragment selectors. Plus, I've added a new custom
class that you can add to fragments to avoid having to override the default visibility/opacity styles.
You can see an example of how that's used in the docs: https://revealjs.com/fragments/#custom-fragments
Thanks! I tweaked this a little and added a full example of a custom fragment too.
add example of custom fragment css #50
reduce fragment style specificity, add custom class to reset fragment styles #2927
Improve fragments documentation
See https://github.com/hakimel/reveal.js/issues/2927 for a full example of custom effects.
I also added current-visible
, a synonym to fade-in-then-out
.
Merge pull request #50 from kno10/patch-1
Improve fragments documentation
See https://github.com/hakimel/reveal.js/issues/2927 for a full example of custom effects.
I also added current-visible
, a synonym to fade-in-then-out
.
add new languages; c, csharp, dart