Skip to main content
As a responsive design gets smaller, its content eventually stops fitting. A Layout has three ways to handle content that’s larger than the space available:
  • Reflow: Use Wrap to move content onto more rows or columns.
  • Shrink: Use Fill and size constraints so content gets smaller, down to a minimum size.
  • Scroll: Keep the content at its full size and let people scroll to see the rest.
Scrolling is the right choice when the amount of content can grow without a limit, such as a list of messages, a feed, or a menu with many options.

How scrolling works in Rive

Scrolling in Rive is a constraint that you add to a Layout. A scroll region is made of three levels of Layouts:
  • Scroll view: The Layout that defines the visible area. Its size usually comes from the rest of your responsive design, such as a Fill height in a Column.
  • Scroll content: A Layout inside the scroll view that holds everything that scrolls. This Layout gets the Scroll constraint. Set it to Hug so it grows with its content. If the scroll content holds text directly, such as a long block of text, also select Hug past bounds so it can grow larger than the scroll view. Scroll content made of child Layouts doesn’t need this.
  • Scroll items: The Layouts inside the scroll content, such as the rows of a list.
When the scroll content is larger than the scroll view, people can scroll it by dragging, with a mouse wheel or trackpad, or you can drive it from an animation or Data Binding. Hierarchy with a scroll view Layout containing a scroll content Layout and its items

Setting up scrolling

For step-by-step setup and every scroll setting, see Scroll Constraint. That page also covers: