Conditional visibility per list detail field


I am using a List Details block.
Is it possible to conditionally show/hide individual fields (aka Content) depending on other field values?

E.g in my use case, I have a URL to send a Whatsapp message - but this should only show if the record’s Mobile number is not blank.


@kanavkhurana Natively speaking… no, I don’t believe this ability exists without some form of custom coding (which may not even be possible, I don’t honestly know).

Off the top of my head for a workaround - the only “quick” solution I can think of (albeit a little janky):

  1. create an airtable view of records only with a mobile number
  2. create a second list details block below the primary list details block that only shows the whatsapp link, and then filter that block to only show records in the view filtered by mobile number. You’ll have to tinker with the design settings to try and make this block appear blank when no record exists.
  3. zero all your paddings and tweak your design elements so the two list details blocks look like a single block.

Functionally, it should do everything you want it to do. Aesthetically, you’ll have to play around with the block design options to try and make it a palatable user experience.

Thanks for the response!
What is the goal of creating a new ‘view’ in Airtable?

Won’t this solution work without that? (may be a stupid question since I’m just starting on my no-code journey!)

The best would be to use a formula field in Airtable. Just show me a piece of your Airtable fields (or tell me how they are called = the one displaying the url and the mobile phone field) and I will build the formula by replying here in this thread.

Note that this method will only hide the content part if mobile phone is empty, not the label part. Also, if the number phone is empty I can make the formula show a specific text like “a mobile phone is needed”. I can even add a url to this sentence that would lead to a page where the user would have to enter their phone number (if it’s not to be typed in your current list details block. In this case, just prompt the user to click an update button in your list details).

Using Ryan method shouldn’t need an other Airtable view. You just add the second list details as mentioned and you add a conditional filter: “mobile phone” is not empty. But the problem is that you will end up with a generic message from Softr “Requested record was not found. Please contact the site administrator.”, which is far from ideal.

If you thought of filtering the second list details block (where the phone number would be) with the first list details block, that is impossible: two list details blocks can’t filter each other, as a list details block determines the url params. So if there are two list details blocks => conflict.

Plus, unfortunately, list details blocks can’t be related to a specific Airtable view (unlike the table block or the list blocks)

1 Like

Thanks @matthieu_chateau ! It makes sense and you’re right - it’s not the cleanest way to do it. :slight_smile:

What’s the overall limitation on enabling this feature? Is it an airtable issue or a softr issue?

It feels like a must-have for a lot of profile-based use cases. For example, I have user profiles that contain detailed information across a dozen fields. Not all users fill in all fields. My only option is to have some user profiles just display a bunch of -'s?

Softr should have the ability to only show fields that are filled out, and exclude blank values.

Hey folks, it’s a Softr limitation we don’t have the feature yet however we have planned to enable more advanced control on how to handle empty fields. It needs to be a setting as some folks prefer the field to be shown even if empty while others want to hide it…