Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] Allowing "click through" ability #6

Open
jrcollins4 opened this issue Mar 2, 2020 · 1 comment
Open

[Feature request] Allowing "click through" ability #6

jrcollins4 opened this issue Mar 2, 2020 · 1 comment

Comments

@jrcollins4
Copy link

Great job on this library!

I have a tab component from our own component library that either requires code or the Switch library to implement the child view that corresponds to the current selected tab, and the Switch library makes this so much easier without our designers having to touch code.

Ideally, it would be nice to set up a Switch target on top a tab, change the view with the switch library, and then have the component execute the click as it would normally (since the active state is managed in the code component).

Is this currently achievable in Framer with the switch library? Would this be possible to implement in the future?

Thanks!

@tisho
Copy link
Owner

tisho commented Mar 23, 2020

You should be able to do this using a SwitchToStateAction component (a hotspot). If you drop one on the canvas, notice that it has a connector dot on the side:

image

If you connect this dot to another component (it would need to be placed outside of the Frame), the hotspot will display that component, instead of being transparent). This will allow you to both handle your own tap events on the component AND have the SwitchToStateAction handle switching states.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants