Default.sublime-keymap (3428B)
1 [ 2 // Auto-pair backticks 3 { "keys": ["`"], "command": "insert_snippet", "args": {"contents": "`$0`"}, "context": 4 [ 5 { "key": "selector", "operator": "equal", "operand": "(source.js, source.ts) - string" }, 6 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 7 { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 8 { "key": "following_text", "operator": "regex_contains", "operand": "^(?:\t| |\\)|]|\\}|>|$)", "match_all": true }, 9 ] 10 }, 11 { "keys": ["`"], "command": "insert_snippet", "args": {"contents": "`${0:$SELECTION}`"}, "context": 12 [ 13 { "key": "selector", "operator": "equal", "operand": "(source.js, source.ts) - string" }, 14 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 15 { "key": "selection_empty", "operator": "equal", "operand": false, "match_all": true } 16 ] 17 }, 18 { "keys": ["`"], "command": "move", "args": {"by": "characters", "forward": true}, "context": 19 [ 20 { "key": "selector", "operator": "equal", "operand": "source.js, source.ts" }, 21 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 22 { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 23 { "key": "following_text", "operator": "regex_contains", "operand": "^`", "match_all": true }, 24 { "key": "selector", "operator": "not_equal", "operand": "punctuation.definition.string.begin", "match_all": true }, 25 ] 26 }, 27 { "keys": ["backspace"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Delete Left Right.sublime-macro"}, "context": 28 [ 29 { "key": "selector", "operator": "equal", "operand": "string.quoted.other.js" }, 30 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 31 { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 32 { "key": "preceding_text", "operator": "regex_contains", "operand": "`$", "match_all": true }, 33 { "key": "following_text", "operator": "regex_contains", "operand": "^`", "match_all": true }, 34 { "key": "selector", "operator": "not_equal", "operand": "punctuation.definition.string.begin", "match_all": true }, 35 ] 36 }, 37 38 // Auto-pair interpolation 39 { "keys": ["{"], "command": "insert_snippet", "args": {"contents": "{$0}"}, "context": 40 [ 41 { "key": "selector", "operator": "equal", "operand": "string.quoted.other.js", "match_all": true }, 42 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 43 { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 44 { "key": "preceding_text", "operator": "regex_contains", "operand": "\\$$", "match_all": true } 45 ] 46 }, 47 { "keys": ["$"], "command": "insert_snippet", "args": {"contents": "\\${${0:$SELECTION}}"}, "context": 48 [ 49 { "key": "selector", "operator": "equal", "operand": "string.quoted.other.js", "match_all": true }, 50 { "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, 51 { "key": "selection_empty", "operator": "equal", "operand": false, "match_all": true } 52 ] 53 }, 54 ]