xoxoxoxo Posted September 29, 2021 Share Posted September 29, 2021 I have a use case where my container has pointer events prop, so clicks can go through from parent to an ancestor div. Currently, this prop doesnt get copied over to the pinned node. I think It would be harmful to add this property to _propNamesToCopyThoughts? Link to comment Share on other sites More sharing options...
GreenSock Posted September 29, 2021 Share Posted September 29, 2021 I'm not sure I totally understand your question - please provide a minimal demo so we can see exactly what the issue is in context and hopefully we can offer some good alternatives. Maybe you can just set a simple CSS style that targets that element. Link to comment Share on other sites More sharing options...
xoxoxoxo Posted September 30, 2021 Author Share Posted September 30, 2021 See the Pen dyRaxgp by nullhoooook (@nullhoooook) on CodePen See how the last div, the footer isn't clickable. Link to comment Share on other sites More sharing options...
GreenSock Posted September 30, 2021 Share Posted September 30, 2021 Wouldn't it be as simple as setting a CSS style?: .pin-spacer { pointer-events: none; } Or am I missing something? Link to comment Share on other sites More sharing options...
xoxoxoxo Posted September 30, 2021 Author Share Posted September 30, 2021 The above would apply to all pin spacer elements. I'm looking to apply to this one instance. Link to comment Share on other sites More sharing options...
xoxoxoxo Posted September 30, 2021 Author Share Posted September 30, 2021 Perhaps I can give a unique id to the instance and target the class .pin-spacer-uid Link to comment Share on other sites More sharing options...
GreenSock Posted October 1, 2021 Share Posted October 1, 2021 Yep, you can do it that way. Or use JavaScript to target the parentNode of your element. Whatever is easier for you. 👍 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now