Hover, press and scroll effects

Give any layer a hover and a pressed look with a smooth transition, and make layers move, scale, turn, fade or drift in parallax as visitors scroll.

Updated · 3 min read

Select a layer in the page editor (a section, stack, grid, text, button, image, icon, or a tab, question or slide) and the Style panel on the right gives you two kinds of effect: how it looks when a visitor points at it or presses it, and what it does as the page scrolls. Both work without any code on the page, so they never slow it down.

Hover, press and scroll effects

Hover and pressed

At the top of the Style panel, switch from Default to Hover or Pressed. The bar under it says Editing Hover (or Pressed), and the canvas shows the selected layer in that state, so you see what you're making.

A state can change:

  • Fill, Overlay, Text colour and Border colour;
  • Radius and Shadow;
  • Opacity;
  • Scale, Rotate and Move X, Y, which nudge the layer without moving anything around it.

Size, spacing, layout and type stay as they are in Default, so nothing on the page jumps when a visitor points at something.

Grey values in a state are what it inherits: Hover starts from Default, and Pressed starts from Hover. Type a value to set it; a blue dot appears next to its name. Click the dot to go back to the inherited value, or Reset to clear the whole state. A dot on the Hover or Pressed tab means that state has values.

When visitors see them:

  • Hover shows while a mouse or trackpad is over the layer, and when it has keyboard focus. Touch screens skip it, so a tap never leaves a button stuck in its hover look.
  • Pressed shows while the layer is clicked or tapped, on top of Hover.

States look the same on desktop, tablet and phone.

Transition

In a Hover or Pressed tab, Transition sets how the layer moves into its states and back:

  • Duration, in seconds (0.3 until you set one);
  • Easing: Ease out (the default), Ease in and out, Ease in, Linear, Spring (a quick overshoot that settles) or Bouncy spring;
  • Delay, in seconds.

Preview plays it on the canvas: the layer goes back to Default and into the state again. In any number field the up and down arrow keys change the value (hold Shift for bigger steps).

While scrolling

In the Default tab, While scrolling (under Motion) makes the layer change as it passes through the screen.

  • Move: choose When it happens (while on screen, while entering, while leaving, or until it's centred), then a Start and End for Move Y, Move X, Scale, Rotate and Opacity. Empty boxes mean "as it is". Opacity is on top of the layer's own: 1 is the layer as you styled it, so a layer at 80% opacity fades in to 80%, and its hover opacity still shows. A new effect starts as a rise and fade-in while the layer enters, which you can change.
  • Parallax: the layer drifts at a different speed from the page. Below 1× it's slower, like a background; above 1×, faster, like something in front.

Every change plays the effect once on the canvas, and Preview plays it again. On the live page the layer follows the visitor's scrolling exactly, up and down. A scroll effect takes over from the layer's Motion while it runs. A layer moving in from the side never makes a phone's page scroll sideways.

For visitors who prefer less motion

Visitors who've asked their device for less motion still see a state's colour changes, but nothing moves, scales or turns, and scroll effects stay still. Browsers that don't support scroll effects (older versions of Safari and Firefox) show the layer as it is in Default.

Good to know

  • In the editor, pointing at a layer on the canvas doesn't trigger its hover, and nothing moves as you scroll the canvas: only the selected layer previews, and only while you're looking at its state or playing an effect. Use the editor's Preview to try the page as a visitor.
  • A scroll effect can't run inside a layer whose overflow is hidden or scrolls, or inside a question's answer or a slideshow, so While scrolling tells you when the layer sits in one. For a layer, set its Overflow to Clip, which trims it the same way without stopping effects inside it.
  • States and effects are saved with the page, so they go live when you publish.

Something unclear or missing? Ask us and we'll answer, then fix the page.

Was this page helpful?

Built with Overlays