Logical condition

Hello everyone…

I want to insert a logical “code”.
I want to display a symbol when a text is added.

Like this example here.
Screenshot_11


So if only BMW appears the symbol (red box) should not appear. But if another text comes next it should appear to make to distance from each other. And the last text that comes in the symbol should not appear.

Screenshot_11-

Is it possible with Bubble?

Thanks
Fabian

Yes

I suppose a follow up question now would be; how to do it?

So, how to do it.

In the condition on the text element, you need a dynamic expression that will match the value of BMW and then the character count, and then the value of the text element itself (I’m not sure if possible so maybe use the input element and style it look like text) character count and if the two are not equal then make a change to the text displayed to include the -

Probably much better ways to do it once it is known how you have everything in your app setup around this value, but the above is just off the top of my head.

How do I match the value when it’s always a random text?

Thanks for your answer.
Fabian

not sure. I’m positive there is an answer and a solution when all known variables are understood by the developer…maybe an extract with regex pattern or something, but there has to be some kind of value that all potential texts share or something you could do to manipulate it to add a value to all or possibly some kind of way to have the value stored somewhere else like a custom state that holds the value unchanged so you could then manipulate it to look how you want it to.

I’m a beginner and your answer is a little advanced for me. Anyway, I solved this by adding a dash to the beginning of every text element.

Thanks for your answer.
Fabian

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