If there are a lot of rows within a Repeater or Flexible Content field, you need to scroll a lot to get to the field you want to edit and it is not easy to find the right one. Also, it is difficult to change the order of the rows.
The ACF Repeater & Flexible Content Collapser plugin solves this problem and add a button to collapse or expand all rows at once.
ACF Repeater & Flexible Content Collapser works in Repeater and Flexible Content Fields and even if they are nested. And the plugin works in all layout modes – no matter whether it is a table, block or row layout.
After plugin activation you get additional settings when you create an ACF Repeater or Flexible Content field.
You can specify whether all fields of this field group are automatically collapsed when the page is loaded. And you can choose whether the button is only displayed with an icon or with the icon and a text.
- Upload the
acf-repeater-flexible-content-collapserfolder to your
- Activate the plugin through the ’Plugins’ menu in WordPress
After collapsing Repeater fields, I can’t expand a single repeater row
This is because ACF adds collapsing/expanding functions of a repeater row only if a sub field is specified in the settings of the repeater field to show when row is collapsed.
If there’s no sub field set in the Collapsed setting for the repeater field you can’t expand/collapse a single row.
I don’t know, if this is a feature or a bug and reported this in the ACF support forum.
In some cases, you may not have a field that should be displayed in the collapsed state. There’s a workaround to solve this problem:
- Create a text field in the repeater, doesn’t matter what you call it
- Set this field as the field to show
- Delete the field you just created and selected
- Save the field group
Unfortunately, this bug does not seem to be fixed in the near future:
”This needs to be repeated whenever you modify the field group, and it’s probably not a good idea to depend on bugs, but I’m guessing that this one isn’t going to be corrected any time soon, especially if no one reports it since it not breaking anything.”
Bidragsgivare och utvecklare
”ACF Repeater & Flexible Content Collapser” är programvara med öppen källkod. Följande personer har bidragit till detta tillägg.Bidragande personer
”ACF Repeater & Flexible Content Collapser” har översatts till 1 språk. Tack till översättarna för deras bidrag.
Intresserad av programutveckling?
- Fixes for WP 5.5
- Optimized code to show collapse button
- Optimized for ACF Free version
- Fixed: Class wrapper is no longer overwritten
- Added option to show/hide the collapse button in field settings
- Changed class name to prevent future conflicts with ACF
- Update ”Tested up to” version.
- Fixed z-index of toggle button.
- Fixed CSS of toggle button for new ACF 5.6.
- Initial release of this plugin, tested and stable.