Fixed elements are handy when you want to keep prevent some elements in your prototype in place — such as fixing a row of tabs at the bottom of an app design, or have a floating button on a website, for example.
To create a fixed element, select a Layer or Hotspot and check the Fix position when scrolling option in the Prototype tab of the Inspector. Alternatively, choose Prototype > Fix Layer Position when Scrolling in the Menu Bar.
Sketch has two methods of calculating where a fixed Layer will display when you play a prototype:
- Proximity: If you place fixed layers at the top or bottom of an Artboard, Sketch assumes that you want to pin them to the top and bottom of the prototype window respectively. Any layers you fix elsewhere will display relative to their overall position in the prototype.
- Pinning: When you set a layer as Fixed, you can use the Pin to Edge options in the Resizing section of the Design tab to specify the exact edge that you want the Layer to be pinned to.
Any pinning options you set will override the default proximity setting.