Forum Academy Marketplace Showcase Pricing Features

[SOLVED] Reusable element able to interact with elements on different pages?

Typically a great description of my question… but not sure how to put it.

Can I use a reusable element that acts as a menu on different pages and have buttons/links on the reusable element show and hide elements on those respective pages?

Since the reusable element sits in a void, it seems unable to communicate with elements on the pages it sits on so I cannot select groups or elements on pages it sits to show or hide those.

So to illustrate:

User (links to internal page user)
create new user (shows group/popup on user page with a form)
Quote (links to internal page quote)
new quote (shows popup with form on quotes page)

1 Like

Maybe… not 100% sure if this would work. I haven’t tested it.

On the Reusable element, can you create a custom state and set the state when the button is clicked?

Then on the page(s) that has the reusable element, have a condition on the element you want to hide/show where the qualification is “reusable element’s custom state = x”.

2 Likes

Thanks for the reply.

Unfortunately I can only refer to the element itself, nothing inside the element. Also, if that was the workflow, it might make more sense to just create a group for each page instead of a reusable element.

Am I missing something or is just the way the reusable element is supposed to function? I’d hoped it worked more like a normal group but with linked clones that update when you update the parent element.

See this https://forumapp3.bubbleapps.io/version-test/reusablecustomstate?debug_mode=true

Click the “Set Custom State” button. That button lives inside the reusable HeaderCustomState element, but triggers the visibility of the hidden shape on the page when clicked.

Here’s the editor https://bubble.io/page?type=page&name=reusablecustomstate&id=forumapp3&tab=tabs-1

8 Likes

Ah yes of course, i was being lazy again…

You would only have to refer to the reusable element itself as you just define multiple states. Nice.

Just tested this with the popup element, works fine too. Thanks.

Kfawcett, just wanted to say thanks for the explanation and share (albeit 3 years later). This was a great help.

2 Likes

Thanks, I have been searching for this answer. Still relate in 2021!