Skip to content

Commit aed3960

Browse files
committed
update: change the scope of key trigger bindings
1 parent 1422f24 commit aed3960

4 files changed

+25
-25
lines changed

Default (Linux).sublime-keymap

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"command": "typescript_paste_and_format",
55
"context": [
66
{ "key": "setting.typescript_auto_format", "operator": "equal", "operand": true },
7-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
7+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
88
]
99
}
10-
]
10+
]

Default (OSX).sublime-keymap

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"command": "typescript_paste_and_format",
55
"context": [
66
{ "key": "setting.typescript_auto_format", "operator": "equal", "operand": true },
7-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
7+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
88
]
99
}
10-
]
10+
]

Default (Windows).sublime-keymap

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
"command": "typescript_paste_and_format",
55
"context": [
66
{ "key": "setting.typescript_auto_format", "operator": "equal", "operand": true },
7-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" },
7+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" },
88
{ "key": "setting.enable_typescript_language_service", "operator": "equal", "operand": true }
99
]
1010
}
11-
]
11+
]

Default.sublime-keymap

+19-19
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
"keys": [ "ctrl+t", "ctrl+d" ],
44
"command": "typescript_go_to_definition",
55
"context": [
6-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
6+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
77
]
88
},
99
{
1010
"keys": [ "f12" ],
1111
"command": "typescript_go_to_definition",
1212
"context": [
13-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
13+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
1414
]
1515
},
1616
{
@@ -19,14 +19,14 @@
1919
"context": [
2020
{ "key": "selection_empty", "operator": "equal", "operand": false, "match_all": true },
2121
{ "key": "num_selections", "operator": "equal", "operand": 1, "match_all": true },
22-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
22+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
2323
]
2424
},
2525
{
2626
"keys": [ "ctrl+alt+r"],
2727
"command": "typescript_nav_to",
2828
"context": [
29-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
29+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
3030
]
3131
},
3232
{
@@ -35,21 +35,21 @@
3535
"context": [
3636
{ "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true },
3737
{ "key": "num_selections", "operator": "equal", "operand": 1, "match_all": true },
38-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
38+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
3939
]
4040
},
4141
{
4242
"keys": [ "ctrl+t", "ctrl+m" ],
4343
"command": "typescript_rename",
4444
"context": [
45-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
45+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
4646
]
4747
},
4848
{
4949
"keys": [ "ctrl+t", "ctrl+n" ],
5050
"command": "typescript_next_ref",
5151
"context": [
52-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
52+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
5353
]
5454
},
5555
{
@@ -63,7 +63,7 @@
6363
"keys": [ "ctrl+t", "ctrl+p" ],
6464
"command": "typescript_prev_ref",
6565
"context": [
66-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
66+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
6767
]
6868
},
6969
{
@@ -77,35 +77,35 @@
7777
"keys": [ "ctrl+t", "ctrl+q" ],
7878
"command": "typescript_quick_info_doc",
7979
"context": [
80-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
80+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
8181
]
8282
},
8383
{
8484
"keys": [ "ctrl+t", "ctrl+r" ],
8585
"command": "typescript_find_references",
8686
"context": [
87-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
87+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
8888
]
8989
},
9090
{
9191
"keys": [ "ctrl+t", "ctrl+s" ],
9292
"command": "typescript_save",
9393
"context": [
94-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
94+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
9595
]
9696
},
9797
{
9898
"keys": [ "ctrl+t", "ctrl+o" ],
9999
"command": "typescript_signature_panel",
100100
"context": [
101-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
101+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
102102
]
103103
},
104104
{
105105
"keys": ["("],
106106
"command": "typescript_signature_popup",
107107
"context": [
108-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" },
108+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" },
109109
{ "key": "paren_pressed"}
110110
]
111111
},
@@ -114,7 +114,7 @@
114114
"command": "typescript_signature_popup",
115115
"args": {"move": "next"},
116116
"context": [
117-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" },
117+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" },
118118
{ "key": "is_popup_visible"}
119119
]
120120
},
@@ -123,15 +123,15 @@
123123
"command": "typescript_signature_popup",
124124
"args": {"move": "prev"},
125125
"context": [
126-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" },
126+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" },
127127
{ "key": "is_popup_visible"}
128128
]
129129
}, // In case when auto match is enabled, only format if not within {}
130130
{
131131
"keys": [ "alt+,"],
132132
"command": "typescript_signature_popup",
133133
"context": [
134-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" },
134+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" },
135135
{ "key": "tooltip_supported", "operator": "equal", "operand": true}
136136

137137
]
@@ -159,21 +159,21 @@
159159
{ "key": "selection_empty", "operator": "equal", "operand": true },
160160
{ "key": "preceding_text", "operator": "regex_contains", "operand": "\\{$" },
161161
{ "key": "following_text", "operator": "regex_contains", "operand": "^\\}" },
162-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
162+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
163163
]
164164
},
165165
{
166166
"keys": [ "ctrl+;" ],
167167
"command": "typescript_format_line",
168168
"context": [
169-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
169+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
170170
]
171171
},
172172
{
173173
"keys": [ "ctrl+shift+]" ],
174174
"command": "typescript_format_brackets",
175175
"context": [
176-
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx" }
176+
{ "key": "selector", "operator": "equal", "operand": "source.ts, source.tsx, source.js, source.jsx" }
177177
]
178178
}
179179
]

0 commit comments

Comments
 (0)