Currently when an entry contains a matrix field each block needs to manually be collapsed or expanded (unless you multiselect them via checkbox). This can become quite time / click consuming, especially if you want to rearrange them. In this case a collapse all (and maybe also expand all) function would be great.
Where to place:
Double-clicking a block titlebar will only collapse/expand the selected block, which is what I would expect to happen. But there is a trick for quickly mass-expanding/collapsing blocks: Click on the first block鈥檚 titlebar, and then shift-click on the last block鈥檚 titlebar. Then all will be selected. Then click the cog icon and click Expand/Collapse, and that will affect all selected blocks.
Thanks for the tip, just tried, works like a charm. I still think this would be very handsome, this is 4 clicks (including holding a key) vs. 1 and to be honest, this is a feature normally available wherever you have to deal with multiple checkboxes (even in other craft overviews...).
Fair enough, just reopened and we can consider it down the road :)
maybe an option at the settings like this?
or a "handle all action bar"
or both 馃憤
thx
CMD + A also works to select all blocks when one block of the field is in focus.
I would love an option (in settings) to collapse blocks by default. I'm using a matrix for a custom menu manager, and it's much easier to visualize and rearrange the items when they're all collapsed. I might try the JS hack suggested in this old StackExchange post in the meantime.
I have a first draft of some instructions (using Sprout Notes) to help my authors remember how to expand/collapse all:
Because going into the site every couple months to make changes, they're not going to remember how to do this. A GUI option for expand/collapse all would be helpful.
Adding my support to this idea. I鈥檇 love it even more if the field contents were editable when the block is collapsed, but just the ability to easily expand/contract all would be a nice feature.
Just saw this, and maybe this FR can attract as a way to solve?
It suggests an audio-board-like Solo button, for many good reasons to use in editing. Click Solo again, and previously visible elements would be seen again. Simple.
...put a little more info in about related #3116
It sounds like this feature request is going to be considered. Which is awesome. but I want to add my vote here.
The command+a works quite well. Thanks @carlcs
There are still some UX issues that support the idea @crazyx13th is suggesting.
There is not a way to deselect all the blocks.
Even with Command+a, there is a UX issue. To trigger the collaspe or expand, one accesses the dropdown menu in the block's title bar. That title bar is specific to the block, that is how I 'read' the design. So a user could reasonably expect selecting _collapse_ from the block's title would only collapse that specific block, not all of them.
We need "Collapse All" and "Expand All" for Matrix fields please.
I would love to see this too. This comment had a great suggestion for both options.
https://github.com/craftcms/cms/issues/1880#issuecomment-320190919
What's really tough is that we can have dynamic content blocks in a matrix field. Sometimes one field can have a dozen types. Then each one could have a 1 to 10 items. Think of a matrix holding a gallery, FAQ, general text, specialized text, forms, etc. But it becomes unusable for the end user to scroll through everything.
We really need to start everything as collapsed instead of expanded.
Most helpful comment
maybe an option at the settings like this?

or a "handle all action bar"
or both 馃憤
thx