# Allow empty splits on panes \(\#40245\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/3b626c8ac1b89ba5b233ae9a9c274489fa94f079)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 3b626c8ac1b89ba5b233ae9a9c274489fa94f079

Requested commit: 3b626c8ac1b89ba5b233ae9a9c274489fa94f079

Commit: 3b626c8ac1b89ba5b233ae9a9c274489fa94f079

Tree: 853948b2c6cbe91e47c1a13ac7750662943bb25a

Author: Yves Ineichen

Committer: GitHub

## Message

```
Allow empty splits on panes (#40245)

Draft as a base for continuing the discussion in #8008 : adds a
`SplitOperation` enum to support bindings like `["pane::SplitLeft",
{"operation": "Clear"}]`

To be discussed @MrSubidubi and others:

- Naming: Generally not happy with names yet and specifically `Empty` is
unclear, e.g., what does this mean for terminal panes? Added placeholder
code to split without cloning, but unsure what users would expect in
this case.
- ~~I removed `SplitAndMoveXyz` actions but I guess we should keep them
for backwards compatibility?~~
- May have missed details in the move implementation. Will check the
code again for opportunities to refactor more code after we agree on the
approach.
- ~~Tests should go to `crates/collab/src/tests/integration_tests.rs`?~~

Closes #8008

Release Notes:

- Add `pane::Split` mode (`{ClonePane,EmptyPane,MovePane}`) to allow
creating an empty buffer.

---------

Co-authored-by: Finn Evers <finn.evers@outlook.de>
Co-authored-by: MrSubidubi <finn@zed.dev>
```

## Parents

- [3dc0614dba258cea3929509b906028f2c291b54f](https://git.cafe/gitcafe/zed/commit/3dc0614dba258cea3929509b906028f2c291b54f?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/3b626c8ac1b89ba5b233ae9a9c274489fa94f079?format=markdown)
