auto-animate applies styles via stylesheet to avoid changing the slide dom

This commit is contained in:
Hakim El Hattab
2020-02-05 15:55:08 +01:00
parent b6b94739e2
commit 4802a2b7f4
3 changed files with 151 additions and 131 deletions

View File

@ -21,7 +21,7 @@
<section data-auto-animate>
<h3>Auto-Matched Content (no IDs)</h3>
<h3>This will fade out</h3>
<p>This will fade out</p>
<img src="assets/image1.png" style="height: 100px;">
<pre><code class="hljs">
function Example() {
@ -29,9 +29,10 @@ function Example() {
}
</code></pre>
</section>
<section data-auto-animate>
<section data-auto-animate data-auto-animate-unmatched="fade">
<h3>Auto-Matched Content (no IDs)</h3>
<h3 style="opacity: 0.2; margin-top: 200px;">This will fade out</h3>
<p style="opacity: 0.2; margin-top: 200px;">This will fade out</p>
<p>This element is unmatched</p>
<img src="assets/image1.png" style="height: 100px;">
<pre><code class="hljs">
function Example() {