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

Escape key doesn't switch back to normal mode when vim keybindings are active. #3122

Open
maranix opened this issue Jan 17, 2025 · 0 comments · May be fixed by #3123
Open

Escape key doesn't switch back to normal mode when vim keybindings are active. #3122

maranix opened this issue Jan 17, 2025 · 0 comments · May be fixed by #3123

Comments

@maranix
Copy link
Contributor

maranix commented Jan 17, 2025

What happened?

Support for Vim keybindings was introduced in #3044. When using the vim keybindings in the editor the Escape key should revert back to normal mode if we are currently in insert, visual and etc modes. As of now, it doesn't do that and stays in the currently activated mode. CTRL+C does this by default and works as expected by going back to normal mode.

Expected Behavior: Pressing Escape key in any other mode except for normal should switch back to normal mode.
Current Behvaior: Doesn't switch back to normal mode.

Screen.Recording.2025-01-17.at.11.15.50.mov

Steps to reproduce problem

  • open dartpad.
  • turn on vim keybindings by pressing on the keyboard button on the bottom left and turning on the switch button in the popup dialog.
  • close the dialog and go into insert or visual mode by either pressing i, a, I, A or SHIFT + v.
  • press esc key on the keyboard.

Additional info

Browser

Browser: Chrome & Firefox

Version: 132.0.6834.84 (Official Build) (x86_64) & 134.0.1 (64-bit)

Are you using any extensions/plugins that affect website behavior
(particularly those that affect iframes, such as ad blockers)?

No

Are there any warnings or errors in your browser's JavaScript console?
If so, paste them below:

Source map error: Error: JSON.parse: unexpected character at line 1 column 1 of the JSON data
Stack in the worker:parseSourceMapInput@resource://devtools/client/shared/vendor/source-map/lib/util.js:163:15
_factory@resource://devtools/client/shared/vendor/source-map/lib/source-map-consumer.js:1066:22
SourceMapConsumer@resource://devtools/client/shared/vendor/source-map/lib/source-map-consumer.js:26:12
_fetch@resource://devtools/client/shared/source-map-loader/utils/fetchSourceMap.js:83:19

Resource URL: https://dartpad.dev/
Source Map URL: flutter.js.map

Feature Policy: Skipping unsupported feature name “clipboard-write”. [main.dart.js:7835:11](https://dartpad.dev/main.dart.js)
Feature Policy: Skipping unsupported feature name “”. [main.dart.js:7835:11](https://dartpad.dev/main.dart.js)
Feature Policy: Skipping unsupported feature name “clipboard-write”. [main.dart.js:7836:1](https://dartpad.dev/main.dart.js)
Feature Policy: Skipping unsupported feature name “”. [main.dart.js:7836:1](https://dartpad.dev/main.dart.js)
WEBGL_debug_renderer_info is deprecated in Firefox and will be removed. Please use RENDERER. [canvaskit.js:15:383](https://www.gstatic.com/flutter-canvaskit/bd1ebf2e1498bd022808f8b237654ce42ae537be/canvaskit.js)
Feature Policy: Skipping unsupported feature name “clipboard-write”. [main.dart.js:34806:3](https://dartpad.dev/main.dart.js)
Feature Policy: Skipping unsupported feature name “”. [main.dart.js:34806:3](https://dartpad.dev/main.dart.js)
WEBGL_debug_renderer_info is deprecated in Firefox and will be removed. Please use RENDERER.

Machine

Operating system: macOS

Version: Sequoia 15.2

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

Successfully merging a pull request may close this issue.

1 participant