zed icon indicating copy to clipboard operation
zed copied to clipboard

keymap: Move main editor keybinds to `Editor && mode == full`

Open notpeter opened this issue 7 months ago • 1 comments

This moves a number of keybinds from Editor to Editor && mode == full.

These keybinds only operate in the full editor (e.g. normal buffers) and don't make sense when inside a auto_height (git commit, inline assistant, etc) or single_line (search fields, command palette, renaming a file, etc) context.

If I have successfully moved these actions correctly, this should be a no-op. If not, we can fast follow with fixes.

Release Notes:

  • N/A

notpeter avatar Apr 30 '25 18:04 notpeter

I'm not actually sure we should merge this until we've fixed the underlying cause of what led me down this path. Zed does not handle nested Editor contexts well. I'm not sure the implications, but it feels like a more specific match (InlineAssistEditor) should be a higher priority match than an earlier match on Editor. I'm sure that has implications though.

Screenshot 2025-04-30 at 13 13 34

See: https://github.com/zed-industries/zed/issues/27896

notpeter avatar Apr 30 '25 19:04 notpeter

@ConradIrwin I'm not going to merge this now. But if we decide to refactor the Editor context so that Multiline / Single Line / Full Editor are distinct contexts we should replicate these migrations at that time.

notpeter avatar May 16 '25 09:05 notpeter