Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no undo for split cell #1408

Open
alefminus opened this issue May 19, 2024 · 3 comments
Open

no undo for split cell #1408

alefminus opened this issue May 19, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@alefminus
Copy link

Describe the bug

  1. Split cell using the new (awesome) shortcut Ctrl+'
  2. Press Ctrl-Z

Nothing happens

Environment

{
  "marimo": "0.6.0",
  "OS": "Linux",
  "OS Version": "6.8.7-300.fc40.x86_64",
  "Processor": "",
  "Python Version": "3.12.3",
  "Binaries": {
    "Browser": "--",
    "Node": "v20.12.2"
  },
  "Requirements": {
    "click": "8.1.7",
    "importlib-resources": "missing",
    "jedi": "0.19.1",
    "markdown": "3.6",
    "pymdown-extensions": "10.8.1",
    "pygments": "2.18.0",
    "tomlkit": "0.12.5",
    "uvicorn": "0.29.0",
    "starlette": "0.37.2",
    "websocket": "missing",
    "typing-extensions": "4.11.0",
    "black": "24.4.2"
  }
}

Code to reproduce

Any cell.

@alefminus alefminus added the bug Something isn't working label May 19, 2024
@mscolnick mscolnick added enhancement New feature or request and removed bug Something isn't working labels May 19, 2024
@mscolnick
Copy link
Contributor

Our undo (ctrl-z) functionality only works the cell editor. We can add a toast so that you can undo with a button click - and bind the Ctrl-Z to that button.

@alefminus
Copy link
Author

alefminus commented May 19, 2024 via email

@akshayka
Copy link
Contributor

Thanks for reporting!

Is it a purely implementation detail, i.e. would you like to have a shared
undo stack or do you prefer separate stacks?

We prefer separate stacks. Sometimes you want to undo all edits to a cell -- just hold Ctrl + z -- without worrying about crossing cell boundaries or bringing back cells you meant to delete.

We can also add a hotkey for undoing actions on the entire cell array, in addition to the toast.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants