| 1 | <!DOCTYPE html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="utf-8" /> |
| 5 | |
| 6 | <title>reveal.js - Scroll View</title> |
| 7 | |
| 8 | <meta |
| 9 | name="viewport" |
| 10 | content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" |
| 11 | /> |
| 12 | |
| 13 | <link rel="stylesheet" href="../dist/reset.css" /> |
| 14 | <link rel="stylesheet" href="../dist/reveal.css" /> |
| 15 | <link rel="stylesheet" href="../dist/theme/black.css" id="theme" /> |
| 16 | <link rel="stylesheet" href="../dist/plugin/highlight/monokai.css" /> |
| 17 | </head> |
| 18 | |
| 19 | <body> |
| 20 | <div class="reveal"> |
| 21 | <div class="slides"> |
| 22 | <section><h1>Scroll View</h1></section> |
| 23 | <section data-background="indigo"> |
| 24 | <h2>Scroll triggered fragments</h2> |
| 25 | <ul> |
| 26 | <li class="fragment fade-left">Step one</li> |
| 27 | <li class="fragment fade-left">Step two</li> |
| 28 | <li class="fragment fade-left">Step three</li> |
| 29 | </ul> |
| 30 | </section> |
| 31 | <section data-background-color="#fff"> |
| 32 | <h2>Scrollbar inverts<br />based on slide bg</h2> |
| 33 | </section> |
| 34 | <section |
| 35 | data-auto-animate |
| 36 | data-auto-animate-easing="cubic-bezier(0.770, 0.000, 0.175, 1.000)" |
| 37 | > |
| 38 | <h2>Auto-Animate</h2> |
| 39 | <p>Scroll triggered auto-animations 😍</p> |
| 40 | <div class="r-hstack justify-center"> |
| 41 | <div |
| 42 | data-id="box1" |
| 43 | style="background: #999; width: 50px; height: 50px; margin: 10px; border-radius: 5px" |
| 44 | ></div> |
| 45 | <div |
| 46 | data-id="box2" |
| 47 | style="background: #999; width: 50px; height: 50px; margin: 10px; border-radius: 5px" |
| 48 | ></div> |
| 49 | <div |
| 50 | data-id="box3" |
| 51 | style="background: #999; width: 50px; height: 50px; margin: 10px; border-radius: 5px" |
| 52 | ></div> |
| 53 | </div> |
| 54 | </section> |
| 55 | <section |
| 56 | data-auto-animate |
| 57 | data-auto-animate-easing="cubic-bezier(0.770, 0.000, 0.175, 1.000)" |
| 58 | > |
| 59 | <div class="r-hstack justify-center"> |
| 60 | <div |
| 61 | data-id="box1" |
| 62 | data-auto-animate-delay="0" |
| 63 | style="background: cyan; width: 150px; height: 100px; margin: 10px" |
| 64 | ></div> |
| 65 | <div |
| 66 | data-id="box2" |
| 67 | data-auto-animate-delay="0.1" |
| 68 | style="background: magenta; width: 150px; height: 100px; margin: 10px" |
| 69 | ></div> |
| 70 | <div |
| 71 | data-id="box3" |
| 72 | data-auto-animate-delay="0.2" |
| 73 | style="background: yellow; width: 150px; height: 100px; margin: 10px" |
| 74 | ></div> |
| 75 | </div> |
| 76 | <h2 style="margin-top: 20px">Auto-Animate</h2> |
| 77 | </section> |
| 78 | <section |
| 79 | data-auto-animate |
| 80 | data-auto-animate-easing="cubic-bezier(0.770, 0.000, 0.175, 1.000)" |
| 81 | > |
| 82 | <div class="r-stack"> |
| 83 | <div |
| 84 | data-id="box1" |
| 85 | style="background: cyan; width: 300px; height: 300px; border-radius: 200px" |
| 86 | ></div> |
| 87 | <div |
| 88 | data-id="box2" |
| 89 | style="background: magenta; width: 200px; height: 200px; border-radius: 200px" |
| 90 | ></div> |
| 91 | <div |
| 92 | data-id="box3" |
| 93 | style="background: yellow; width: 100px; height: 100px; border-radius: 200px" |
| 94 | ></div> |
| 95 | </div> |
| 96 | <h2 style="margin-top: 20px">Auto-Animate</h2> |
| 97 | </section> |
| 98 | <section |
| 99 | data-background-gradient="linear-gradient(to bottom, #283b95, #17b2c3)" |
| 100 | id="gradient-bg" |
| 101 | > |
| 102 | <h2 data-id="code-title">Code highlights,<br />meet scroll triggers</h2> |
| 103 | <pre |
| 104 | data-id="code-animation" |
| 105 | ><code class="hljs javascript" data-trim data-line-numbers="|4,8-11|17|22-24"><script type="text/template"> |
| 106 | import React, { useState } from 'react'; |
| 107 | |
| 108 | function Example() { |
| 109 | const [count, setCount] = useState(0); |
| 110 | |
| 111 | return ( |
| 112 | <div> |
| 113 | <p>You clicked {count} times</p> |
| 114 | <button onClick={() => setCount(count + 1)}> |
| 115 | Click me |
| 116 | </button> |
| 117 | </div> |
| 118 | ); |
| 119 | } |
| 120 | |
| 121 | function SecondExample() { |
| 122 | const [count, setCount] = useState(0); |
| 123 | |
| 124 | return ( |
| 125 | <div> |
| 126 | <p>You clicked {count} times</p> |
| 127 | <button onClick={() => setCount(count + 1)}> |
| 128 | Click me |
| 129 | </button> |
| 130 | </div> |
| 131 | ); |
| 132 | } |
| 133 | </script></code></pre> |
| 134 | </section> |
| 135 | <section class="stack"> |
| 136 | <section |
| 137 | data-background="https://static.slid.es/reveal/image-placeholder.png" |
| 138 | id="image-bg" |
| 139 | > |
| 140 | <h2>Image Backgrounds</h2> |
| 141 | </section> |
| 142 | <section |
| 143 | data-background-video-muted |
| 144 | data-background-video="https://s3.amazonaws.com/static.slid.es/site/homepage/v1/homepage-video-editor.mp4,https://s3.amazonaws.com/static.slid.es/site/homepage/v1/homepage-video-editor.webm" |
| 145 | > |
| 146 | <h2>Video background</h2> |
| 147 | </section> |
| 148 | </section> |
| 149 | <section><h2>The end</h2></section> |
| 150 | </div> |
| 151 | </div> |
| 152 | |
| 153 | <script src="../dist/reveal.js"></script> |
| 154 | <script src="../dist/plugin/notes.js"></script> |
| 155 | <script src="../dist/plugin/markdown.js"></script> |
| 156 | <script src="../dist/plugin/highlight.js"></script> |
| 157 | <script> |
| 158 | Reveal.initialize({ |
| 159 | view: 'scroll', |
| 160 | hash: true, |
| 161 | |
| 162 | plugins: [RevealMarkdown, RevealHighlight, RevealNotes], |
| 163 | }); |
| 164 | </script> |
| 165 | </body> |
| 166 | </html> |
| 167 |