Vacantes
Building a Navigation Component with Variables
06-02-2022
Navigation is key within any digital interface. Smart Components enable us to create custom interactive navigation components that work perfectly with the rest of your prototype.In this guide, we will cover the concepts of nesting components, adding events to elements in a component using Event Variables, and passing these through your components. One of the main benefits of using nested components is that it provides full control over its states, such as unique hover states of elements within another component.
Starting at the atomic level
Framer allows you to create fully interactive and animated components, and even allows you to nest components within other components. We’re building a navigation bar component for a website that will contain two different kinds of nested components, with their own unique interactions. Our project will contain a Navigation bar that contains various nested components, namely five Nav items and one Shopping cart component. The design of our nested components, the nav list item and the shopping cart, will impact how we design our navigation bar. For this reason, an optimal workflow includes starting with the 'deepest' nested component and building up from there.
Nesting components
Once we have our two components ready, we can start creating the component in which we will nest these. Draw your navigation bar, select it on the canvas and click the Component tool in the Toolbar. To nest a different component in our new component, just drag any other component to the Component Canvas and place it within your designed navigation bar.
Triggering interactions from the navigation bar
Back on the main canvas, we’d like to be able to tap 'Clothing' and navigate to an entire new Screen. If you’d connect the component using the Prototyping Connector to a new screen, we could set up an Interaction. However, this would be triggered if we tap anywhere within our component. This isn’t what we want to do, as we want to trigger this transition only from a specific element. This is where Event Variables come in, which are special types of Variables not attached to properties (like opacity or fill) but instead to events.
Navigation is key within any digital interface. Smart Components enable us to create custom interactive navigation components that work perfectly with the rest of your prototype.In this guide, we will cover the concepts of nesting components, adding events to elements in a component using Event Variables, and passing these through your components. One of the main benefits of using nested components is that it provides full control over its states, such as unique hover states of elements within another component.
Starting at the atomic level
Framer allows you to create fully interactive and animated components, and even allows you to nest components within other components. We’re building a navigation bar component for a website that will contain two different kinds of nested components, with their own unique interactions. Our project will contain a Navigation bar that contains various nested components, namely five Nav items and one Shopping cart component. The design of our nested components, the nav list item and the shopping cart, will impact how we design our navigation bar. For this reason, an optimal workflow includes starting with the 'deepest' nested component and building up from there.
Nesting components
Once we have our two components ready, we can start creating the component in which we will nest these. Draw your navigation bar, select it on the canvas and click the Component tool in the Toolbar. To nest a different component in our new component, just drag any other component to the Component Canvas and place it within your designed navigation bar.
Triggering interactions from the navigation bar
Back on the main canvas, we’d like to be able to tap 'Clothing' and navigate to an entire new Screen. If you’d connect the component using the Prototyping Connector to a new screen, we could set up an Interaction. However, this would be triggered if we tap anywhere within our component. This isn’t what we want to do, as we want to trigger this transition only from a specific element. This is where Event Variables come in, which are special types of Variables not attached to properties (like opacity or fill) but instead to events.
Otras noticias de nuestro blog
En MPM te contamos periódicamente noticias, actualizaciones
Alianzas que dejan huella: Juntos por la infancia reconoció a MPM
05-12-2024
MPM presente en la 3° Olimpiadas Inclusivas RM de Miradas Compartidas
03-12-2024
WIM Chile visitó a las futuras operadoras de MPM
02-12-2024
MPM en la 3era Edición de “Academia De Digitalización Minera para Mujeres"
22-11-2024
¡Felicidades a Maria Soledad Carrizo, Operadora de Grúa Hidráulica de MPM!
11-11-2024
¡Juntos superamos nuestra meta en la Campaña 1+1 Teletón Chile 2024!
10-11-2024
Mariel Bascur recibe Premio FEC Mujeres 2024
08-11-2024
MPM es reconocido por su responsabilidad y compromiso con la protección respiratoria de sus trabajadores
29-10-2024
MPM: Excelencia al servicio de la minería y compromiso con la participación laboral de mujeres en la industria
28-10-2024
MPM pone en marcha su primera Estación de Carga Eléctrica Móvil
18-10-2024
Alianzas que dejan huella: Juntos por la infancia reconoció a MPM
05-12-2024
MPM presente en la 3° Olimpiadas Inclusivas RM de Miradas Compartidas
03-12-2024
WIM Chile visitó a las futuras operadoras de MPM
02-12-2024
Alianzas que dejan huella: Juntos por la infancia reconoció a MPM
05-12-2024
MPM presente en la 3° Olimpiadas Inclusivas RM de Miradas Compartidas
03-12-2024
WIM Chile visitó a las futuras operadoras de MPM
02-12-2024
MPM en la 3era Edición de “Academia De Digitalización Minera para Mujeres"
22-11-2024
¡Felicidades a Maria Soledad Carrizo, Operadora de Grúa Hidráulica de MPM!
11-11-2024
¡Juntos superamos nuestra meta en la Campaña 1+1 Teletón Chile 2024!
10-11-2024
Mariel Bascur recibe Premio FEC Mujeres 2024
08-11-2024
MPM es reconocido por su responsabilidad y compromiso con la protección respiratoria de sus trabajadores
29-10-2024
MPM: Excelencia al servicio de la minería y compromiso con la participación laboral de mujeres en la industria
28-10-2024