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

What is Framer? Join the Community
Return to index
John Lee
Posted Sep 16 - Read on Facebook

Hello you loop-lov'in, dynamic-layering Framer'ers

I had a question, (funnily enough) about targeting a dynamic layer's HTML CSS property using an onClick event. Attaching a screen shot of where I got to and it dun-not work...

Your help is always appreciated (grovel, beg, whimper...)

2 Comments

Krijn Rijshouwer

Hey John Lee,

There are a couple things going wrong here but to resolve the main issue. We don't support setting/changing the style property using states.

Some other little tips:
- Naming the index variable in the loop the same as the tab Layer variable can introduce some issues. Try using i for the index variable in the for loop.
- In the current setup the #000 would be applied to the tab Layer and will be overruled by the DOM element's child node h1 causing the text color to stay #666. Try setting the style to the tab Layer.

I hope this helps. Here's a little example how you could set it up → http://share.framerjs.com/hw4st0rhhylm/

John Lee

THANK YOU – Krijn Rijshouwer, that is spot ON! Awesome explanation and I feel like celebrating tonight with some beers! Love this community!
On a different note, one question for Framer – is there a way to get the home screen search functionality "search the community" via Google indexing, after have an opening file? I must search about 20-30 times during a project and having that functionality from the top menu would be awesome!

Read the entire post on Facebook