- Issue created by @socalerich
- Status changed to Postponed: needs info
11 months ago 11:24pm 10 April 2024 - πΊπΈUnited States smustgrave
Could you provide steps for reproducing this?
- Status changed to Closed: outdated
10 months ago 2:31pm 19 April 2024 - πΊπΈUnited States smustgrave
If still a problem in 6.0.x please reopen
- πΊπΈUnited States mlncn Minneapolis, MN, USA
This is still an issue, at least when used with the latest Facets 3.x
- Configure facets within Views as documented in https://project.pages.drupalcode.org/facets/exposed_filters/
- In Better Exposed Filters settings on the view, under Exposed Filter Settings, open Advanced filter options and enable Make filter options collapsible ("Puts the filter options in a collapsible details element.")
- Visit the view and filter by another facet so one set to be in a Details element has no results.
- Note that the facet label is still there as the summary for the details element, but nothing is inside.
- Change the Exposed Filter Settings option to not make filter options collapsible.
- Reload the view and see that now the facet label is gone, as expected.
- Status changed to Active
4 months ago 5:02am 23 October 2024 - πΊπΈUnited States mlncn Minneapolis, MN, USA
Thanks, i realized that after posting and upgraded, and it is still the case on 7.0.2 at least.
- πΊπΈUnited States mlncn Minneapolis, MN, USA
Configurable Views Filter Block shows Better Exposed Filters facets-sourced Details elements (label, no options) even when not selected in the block if that is helpful for pointing me at where to try to fix this. Thanks!
- πΊπΈUnited States mlncn Minneapolis, MN, USA
Nothing like writing ones own Better Exposed Filter plugin - https://www.drupal.org/project/bef_links_filter β - to get a better sense of how this all works. Implemented a workaround in π Prevent collapsible fieldset from showing when facet is empty Active but the fix here should be to put the wrapping of facet into a details element on line 254 of better_exposed_filters/src/Plugin/better_exposed_filters/filter/FilterWidgetBase.php in a
if (!empty($form[$field_id])) { β¦ }
block, unless that does not work for all better_exposed_filter plugins? - Merge request !133Issue #3379736 by socalerich, mlncn: Collapsible details element not hidden if... β (Closed) created by smustgrave
- πΊπΈUnited States smustgrave
I have 0 idea how to test this with just in bef but if it works with facets I can merge it.
- Status changed to Needs review
about 1 month ago 3:24pm 14 January 2025 Happy to confirm #10 works for me on BEF 7.0.4 with Facets 3.0.0. Thanks for the fix!
- π«π·France laborouge
laborouge β changed the visibility of the branch 3379736-collapsible-details-element to hidden.
-
smustgrave β
committed 1e50bd2a on 7.0.x
Issue #3379736 by smustgrave, erichhaemmerle, mlncn, sarsion, laborouge...
-
smustgrave β
committed 1e50bd2a on 7.0.x
- πΊπΈUnited States johnny5th
This commit breaks putting wrapped filters in a collapsible detail element. It looks like a similar issue to # 3475063 π Hide labels for wrapped filters Active where the form field id is "field_name" + "_wrapper". Maybe we can solve both by tweaking getExposedFilterFieldId. I tried looking into it but can't find a clear indication that the field is a wrapped multi-field.
- πΊπΈUnited States danflanagan8 St. Louis, US
I solved the issue for myself by extending the bef Radios/Checkboxes filter and using it for my facets.
// Remove corresponding details if no options. if (empty($form[$field_id]) && empty($form[$field_id . '_wrapper']) && isset($form[$field_id . '_collapsible'])) { unset($form[$field_id . '_collapsible']); }
This also checks for the `_wrapper` element as @johnny5th suggested might work.
I'm also using the extension to manage the conditional visibility of facets, which is already a won't fix in bef: β¨ Add support for conditional exposed filters in views Closed: works as designed
- π¬π§United Kingdom gsquirrel London
After this commit am no loner able to collapse slider widget in the views exposed form.
It seems to change from details element to fieldset, and I cannot see how to alter this.
- π¬π§United Kingdom gsquirrel London
Downgrading to 7.0.4 is simplest fix for me - hoping this gets fixed for next release
- πͺπΈSpain ady1503
The same thing happens to me. I have left it at version 7.0.4:
"After this commit am no loner able to collapse slider widget in the views exposed form.
It seems to change from details element to fieldset, and I cannot see how to alter this."
Downgrading to 7.0.4 is simplest fix for me
Gracias