Streaming live at 10am (PST)

Empty State for Dynamic List won't accept display:none


#1

I'm running into a weird issue that I believe is new to our published site.

I have created a class "empty" that I apply to the empty state of dynamic list. However the display none isn't hiding the Empty State. See attached screenshot. It's also appearing on the live site.

https://preview.webflow.com/preview/mwf?preview=cc2375212ef033fa8d6c2cc38b28061b


#2

Your

.empty {display: none;}

is being overwritten by a more specific instruction in the Webflow style sheets:

html .w-dyn-empty.wf-display-empty {display: block;}

Not great that it works like this.

I've had the same issue and solved it by deleting the 'text block' in the 'empty' container, and then applying 0 padding to the 'empty' container.

Hope that helps.


#3

Hi @pixelsock

It looks like you have have a filter set for "featured = on", but there are no collection items with the featured switch enabled.

If you remove the featured switch filter,

or enable the switch on a collection item the dynamic list will populate.

Hope this helps!


#4

Hey @Brando, thanks for the detail in the response, but that didn't really answer my question. I set it up that way on the on purpose. If there isn't content don't show it... I still feel like this is a bug and not a CMS help.

I'm trying to figure out why @spirelli comment is true. Why can't I just create a display:none class for Empty States?

I designed it this way previously and it was working fine.


#5

Hi @pixelsock

Apologies for the misunderstanding and thanks for the clarification.

The empty state stays visible in the Designer for designing, but it is not visible on the published site:

Are you seeing the empty state in the published version of your site?

Thanks in advance!


#6

@Brando not on the home page dynamic list but on the location pages they are still present.

http://mwf.webflow.io/charlotte
http://mwf.webflow.io/houston


#7

Looks like this is only the case in preview mode, but not on the published site, which isn't that great.

It looks as if you haven't applied your 'empty' class on this page. Can that be the case?


#8

Hi @pixelsock

You can set the empty state to display: none on the Charlotte and Houston pages to fix this.

Here is a quick GIF: https://cl.ly/390u2q3o0t1c

Hope this helps! :slight_smile:


#9

This is working now! Thank you both for your help! @spirelli It's now working on the live site again. But still not in the designer (which I can live with).

Thanks again.


#10

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.