2015-11-07 03:47:06 +08:00
|
|
|
# This is the core set of universal, cross-platform keymaps. This is
|
|
|
|
# extended in the following places:
|
2015-02-05 10:31:41 +08:00
|
|
|
#
|
2015-11-07 03:47:06 +08:00
|
|
|
# 1. keymaps/base.cson - (This file) Core, universal keymaps across all platforms
|
|
|
|
# 2. keymaps/base-darwin.cson - Any universal mac-only keymaps
|
|
|
|
# 3. keymaps/base-win32.cson - Any universal windows-only keymaps
|
|
|
|
# 4. keymaps/base-darwin.cson - Any universal linux-only keymaps
|
|
|
|
# 5. keymaps/templates/Gmail.cson - Gmail key bindings for all platforms
|
|
|
|
# 6. keymaps/templates/Outlook.cson - Outlook key bindings for all platforms
|
|
|
|
# 7. keymaps/templates/Apple Mail.cson - Mac Mail key bindings for all platforms
|
|
|
|
# 8. some/package/keymaps/package.cson - Keymaps for a specific package
|
|
|
|
# 9. ~/.nylas/keymap.cson - Custom user-specific overrides
|
|
|
|
#
|
|
|
|
# NOTE: We have a special N1 extension called `cmdctrl` that automatically
|
|
|
|
# uses `cmd` on mac and `ctrl` on windows and linux. This covers most
|
|
|
|
# cross-platform cases. For truely platform-specific features, use the
|
|
|
|
# platform keymap extensions.
|
2015-02-05 10:31:41 +08:00
|
|
|
|
2015-03-06 10:49:26 +08:00
|
|
|
'body':
|
2015-11-07 03:47:06 +08:00
|
|
|
### Core system commands. ###
|
|
|
|
# These have their default effects, but map to
|
|
|
|
# commands to allow for custom interactions.
|
|
|
|
'cmdctrl-z': 'core:undo'
|
|
|
|
'cmdctrl-Z': 'core:redo'
|
|
|
|
'cmdctrl-y': 'core:redo'
|
2015-11-14 08:05:40 +08:00
|
|
|
'shift-delete': 'core:cut'
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-x': 'core:cut'
|
|
|
|
'cmdctrl-c': 'core:copy'
|
|
|
|
'cmdctrl-v': 'core:paste'
|
|
|
|
'cmdctrl-a': 'core:select-all'
|
|
|
|
|
|
|
|
'up' : 'core:previous-item'
|
|
|
|
'down' : 'core:next-item'
|
|
|
|
'left' : 'core:move-left'
|
|
|
|
'right' : 'core:move-right'
|
|
|
|
'shift-up' : 'core:select-up'
|
|
|
|
'shift-down' : 'core:select-down'
|
|
|
|
'shift-left' : 'core:select-left'
|
|
|
|
'shift-right': 'core:select-right'
|
|
|
|
|
|
|
|
### Core application commands. ###
|
|
|
|
'cmdctrl-q' : 'application:quit'
|
|
|
|
'cmdctrl-w' : 'window:close'
|
|
|
|
|
|
|
|
### Universal N1 commands. ###
|
2015-04-09 10:25:00 +08:00
|
|
|
'enter' : 'core:focus-item'
|
2015-10-30 11:34:43 +08:00
|
|
|
'delete' : 'core:remove-from-view'
|
2015-11-07 03:47:06 +08:00
|
|
|
'escape' : 'application:pop-sheet'
|
2015-10-24 05:45:28 +08:00
|
|
|
'backspace': 'core:remove-from-view'
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-,': 'application:open-preferences'
|
2015-03-14 04:11:24 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
'pageup' : 'core:messages-page-up'
|
|
|
|
'pagedown' : 'core:messages-page-down'
|
|
|
|
'shift-pageup' : 'core:list-page-up'
|
|
|
|
'shift-pagedown': 'core:list-page-down'
|
2015-10-30 11:34:43 +08:00
|
|
|
|
2015-11-07 06:37:33 +08:00
|
|
|
'cmdctrl-1': 'application:select-account-0'
|
|
|
|
'cmdctrl-2': 'application:select-account-1'
|
|
|
|
'cmdctrl-3': 'application:select-account-2'
|
|
|
|
'cmdctrl-4': 'application:select-account-3'
|
|
|
|
'cmdctrl-5': 'application:select-account-4'
|
|
|
|
'cmdctrl-6': 'application:select-account-5'
|
|
|
|
'cmdctrl-7': 'application:select-account-6'
|
|
|
|
'cmdctrl-8': 'application:select-account-7'
|
|
|
|
'cmdctrl-9': 'application:select-account-8'
|
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
### N1 developer commands. ###
|
|
|
|
'cmdctrl-alt-l': 'window:reload'
|
|
|
|
'cmdctrl-alt-i': 'window:toggle-dev-tools'
|
|
|
|
'cmdctrl-alt-w': 'application:show-work-window'
|
|
|
|
'cmdctrl-alt-s': 'application:run-all-specs'
|
|
|
|
'cmdctrl-alt-p': 'application:run-package-specs'
|
|
|
|
|
|
|
|
'body *[contenteditable].contenteditable':
|
|
|
|
### Basic formatting commands ###
|
|
|
|
'cmdctrl-u': 'contenteditable:underline'
|
|
|
|
'cmdctrl-b': 'contenteditable:bold'
|
|
|
|
'cmdctrl-i': 'contenteditable:italic'
|
|
|
|
'cmdctrl-k': 'contenteditable:insert-link'
|
|
|
|
|
|
|
|
### Advanced formatting commands ###
|
|
|
|
'cmdctrl-&': 'contenteditable:numbered-list'
|
|
|
|
'cmdctrl-#': 'contenteditable:numbered-list'
|
|
|
|
'cmdctrl-*': 'contenteditable:bulleted-list'
|
|
|
|
'cmdctrl-(': 'contenteditable:quote'
|
|
|
|
|
|
|
|
'cmdctrl-[': 'contenteditable:outdent'
|
|
|
|
'cmdctrl-]': 'contenteditable:indent'
|
2015-02-05 10:31:41 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-L': 'contenteditable:align-left'
|
|
|
|
'cmdctrl-E': 'contenteditable:align-center'
|
|
|
|
'cmdctrl-R': 'contenteditable:align-right'
|
2015-02-07 06:46:30 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-,': 'contenteditable:set-right-to-left'
|
|
|
|
'cmdctrl-.': 'contenteditable:set-left-to-right'
|
2015-03-05 10:12:50 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-\\': 'contenteditable:remove-formatting'
|
2015-03-05 10:12:50 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
'cmdctrl-%': 'contenteditable:previous-font'
|
|
|
|
'cmdctrl-^': 'contenteditable:next-font'
|
|
|
|
'cmdctrl-+': 'contenteditable:increase-text-size'
|
|
|
|
'cmdctrl--': 'contenteditable:decrease-text-size'
|
2015-08-20 04:26:11 +08:00
|
|
|
|
2015-11-07 03:47:06 +08:00
|
|
|
### Custom Property Navigating ###
|
|
|
|
'cmdctrl-;': 'contenteditable:previous-selection'
|
|
|
|
"cmdctrl-'": 'contenteditable:next-selection'
|
|
|
|
'cmdctrl-m': 'contenteditable:open-spelling-suggestions'
|