Icon as a checkbox

Hi,

I have 2 dropdowns and ‘checkbox’ as text and icon and button search. When I picked some value I clicked button “Search”, some things are shown and my text in button should be changed to “Refresh”. But if I changed my mind and want to check my icon I want my button to be back “Search”. Is there any possible way to do that in Bubble.io? (I know what to do with dropdowns when you change inputs, but I don’t know what to do with that icon)

I’m sure there is a way to do this, but to be honest there is a really simple way to do this.

Don’t.

And by that, I mean just get rid of the search/refresh button.

Instead, just have the search results display based on whatever the user selects from the dropdown or if they have your checkbox checked or not.

That way, the search results will automatically show results based on what they select/check/unchecked without any further interaction from them.

Just an idea. I am FAR from an interface expert but just wanted to give you a simple alternative.

1 Like

I’d agree with you up until the WU pricing change - now we’re literally charged each time a user plays with a search constraint :confused: I’ve moved to click to search/refresh rather than auto-updating unless a client fully understands the cost of the alternative.

2 Likes

OK, I can understand the WU issue concern.

I have a very similar situation where my users can select up to 6 different search criteria and re-triggering the search would kill me WU-wise.

Instead, I have a listshifter that already contains all potential rows the user might find. Then when they change search criteria I just re-filter the data to display, rather than re-retrieving.

1 Like

I agree, this is much easier way. But “Refresh” is part of functionality so I can’t get rid of it.

But you’re aware the Repeating Group can refresh without needing to press refresh, right?

Yes, I’m aware about that. And I still need button “Refresh”

1 Like

Hi @tetiana.deresh, I think I figured out a solution for this:

• I created two icons: one “unchecked” and one “checked” that have yes/no Custom States to determine which ones should be visible or not.
• I created a Search button and a Refresh button; each with yes/no Custom States to determine which ones should be visible or not.
• I have two Workflows for the “unchecked” icon and two for the “checked” icon.

  1. In one Workflow for the “checked” icon: when it’s clicked by a User, its “is_checked” Custom State changes to “No” (first Action) AND the “unchecked” icon’s “is_unchecked” Custom State changes to “Yes” (second Action).
  2. For the other Workflow for the “checked” icon: when it’s clicked by a User AND the “show_search_btn” Custom State for the “Search” button is set to “No”, I have Actions that change the yes/no Custom States for the icons AND for the “Search” and “Refresh” buttons.

Once you get that “checked” icon’s Workflows set up and working, you’ll see how to set the Workflows for the “unchecked” icon.

Does this achieve what you’re trying to do?

1 Like

Yes, it is what I was trying to do. Thank you a lot, it was very helpful. I really appreciate that .
Thank you so much :blush:

1 Like

Great! No problem!

This topic was automatically closed after 70 days. New replies are no longer allowed.