Creating a compelling interactive experience means more than just displaying information; it's about how that information appears and behaves on the screen. When building a data-driven presentation or report in InDesign, animating a line graph can add a layer of visual polish that engages your audience. With in5, you can export this type of animation to your own server in an HTML5 format and deliver high-impact, interactive visuals.
By animating a line graph in InDesign for export with in5, you can create a visual effect that makes the data points and connecting lines appear to “draw themselves” on the screen from left to right.
Watch this YouTube to learn how:
The video above shows how to reveal a line graph on a white background using a white rectangle or how to reveal a line graph over a grid using a combination of grouping and applying a blend mode.
If your graph elements don't have any animation, they will load and appear immediately when the page loads— before the rectangle starts to animate. This causes the graph (or whatever you have in the background) to flash briefly before the animation plays.
To solve this, we’ll apply a basic animation to the graph, set it to be hidden until animated, and then sync the reveal timing. These small tweaks make a big difference— and they export flawlessly with in5.
If the background of your content is solid, you can use a shape that's the same color as the background to cover the content and then reveal it by applying an InDesign animation preset (Window > Interactive > Animation) to move it.
If the document doesn't have much content to load and the content isn't very large in terms of file size, then it should load pretty quickly so that the graph doesn't appear while the page is loading.
However, with this type of setup, if your graph appears briefly and is then hidden, it's loading the content on the page slowly enough that the graph is visible. The browser renders the content from the bottom to top of the document's layer stack. Because the white rectangle with the animation covers the graph, it gets rendered after the graph.
How to hide the graph if it appears while the content is loading
The graph content does not have an animation applied, so the "hiding' of the content happens when the white rectangle that has animation applied to it loads. If the white rectangle doesn't load quickly enough, then the graph underneath is visible.
What you can do to hide the graph is apply an animation so that it's initially hidden and then appears. Link the animation that makes it appear with the animated white rectangle that reveals it. Here's how:
Group the graph content in case it contains multiple parts such as text labels, arrows--whatever goes along with that particular graph--with the graph image.
In the Animation panel,
Rename the group so that it's easier to find in the Timing panel later.
Apply an Appear animation preset to the group.
In the Visibility section, select Hide Until Animated.
In the Layers panel, find the rectangle that covers this graph group and rename it so that it's also easier to find in the Timing panel later.
In the Timing panel (Window > Interactive > Timing), Shift + select the graph group animation and the rectangle and click on the link icon at the bottom of the Timing panel to link them.
Repeat for any additional graphs.
Note: It may be more efficient to perform steps 1-4 if you have multiple groups and then do step 5 for all group and rectangle pairs.