This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Thibault Maekelbergh
Posted Oct 25 - Read on Facebook

Just started using Framer today to prototype some animations for a school project.

It's a bar which fills with another color when you click it, however the bar animates in from origin (0,0) and I would like it to take up the whole height of the black bar and animate the width to 100% instead of animating in from the corner.

GIF: http://imgur.com/YPtRbmX
Code: http://cl.ly/text/1K1e3B2M150w
Any tips?

3 Comments

Alejandro Cámara López

I would do something like this (I can't test it out because I'm on my phone in a train)

Redbar.originX = 0
Redbar.scaleX= 0

Redbar.states.add 'fullbar',
Redbar.scaleX = 1

Thibault Maekelbergh

Thanks, that's what I was looking for with way less code!

Alejandro Cámara López

I read the code after commenting 😅

So Redbar = red and 'fullbar' = second

Read the entire post on Facebook