Simple key binding problem

So, I finally tried the atom with one of the unofficial Windows builds. Now I'm trying to create a simple binding (and then wrap my legs with real plugins).

Binding is simple when you are in vim command line mode and press ':', open the command bar.

I started with this as a binding:

'.editor':
  ':': 'command-palette:toggle'

This works fine, but I only want this in command mode. If I change the selector, do the following:

'.command-mode':
  ':': 'command-palette:toggle'

This does not work, although the command mode class is in the same element as the editor class.

+4
source share
1 answer

Have you tried combining the two, as in CSS?

'.editor .command-mode':
  ':': 'command-palette:toggle'
+1
source

Source: https://habr.com/ru/post/1540191/


All Articles