-
Notifications
You must be signed in to change notification settings - Fork 1
Examples: Reveal Text
examples/reveal_text
The reveal_text example demonstrates how to add a "reveal" effect to data docs text, so that words or phrases in an individual text div appear in sequence rather than all at once. To review the process for adding text, changing its font and adjusting its timing in the video, refer to the instructions for the simple_text example above. Once you've got all the timing, positions and appearance set, just do the following:
-
In one of the text divs inside your
dd_reveal_text.html
file, add pipes (|) wherever you want there to be a delay in the text's appearance. -
In the
main.js
file, make sure that eachaddSalt
method has two added parameters:has_reveal: "true"
andreveal_timeout: 300
(where 300 is the number of milliseconds' delay between text snippets revealed. The delay can be different for each piece of text, and you can mix "reveal" text with "simple" text in any combination you like within a DataDoc. -
Open up your
dd_reveal_text.html
file in your browser, and check out your DataDoc!