USKeyboardLayout.js 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274
  1. "use strict";
  2. /**
  3. * Copyright 2023 Google LLC.
  4. * Copyright (c) Microsoft Corporation.
  5. *
  6. * Licensed under the Apache License, Version 2.0 (the "License");
  7. * you may not use this file except in compliance with the License.
  8. * You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. */
  18. Object.defineProperty(exports, "__esModule", { value: true });
  19. exports.KeyToKeyCode = void 0;
  20. // TODO: Remove this once https://crrev.com/c/4548290 is stably in Chromium.
  21. // `Input.dispatchKeyboardEvent` will automatically handle these conversions.
  22. exports.KeyToKeyCode = {
  23. '0': 48,
  24. '1': 49,
  25. '2': 50,
  26. '3': 51,
  27. '4': 52,
  28. '5': 53,
  29. '6': 54,
  30. '7': 55,
  31. '8': 56,
  32. '9': 57,
  33. Abort: 3,
  34. Help: 6,
  35. Backspace: 8,
  36. Tab: 9,
  37. Numpad5: 12,
  38. NumpadEnter: 13,
  39. Enter: 13,
  40. '\\r': 13,
  41. '\\n': 13,
  42. ShiftLeft: 16,
  43. ShiftRight: 16,
  44. ControlLeft: 17,
  45. ControlRight: 17,
  46. AltLeft: 18,
  47. AltRight: 18,
  48. Pause: 19,
  49. CapsLock: 20,
  50. Escape: 27,
  51. Convert: 28,
  52. NonConvert: 29,
  53. Space: 32,
  54. Numpad9: 33,
  55. PageUp: 33,
  56. Numpad3: 34,
  57. PageDown: 34,
  58. End: 35,
  59. Numpad1: 35,
  60. Home: 36,
  61. Numpad7: 36,
  62. ArrowLeft: 37,
  63. Numpad4: 37,
  64. Numpad8: 38,
  65. ArrowUp: 38,
  66. ArrowRight: 39,
  67. Numpad6: 39,
  68. Numpad2: 40,
  69. ArrowDown: 40,
  70. Select: 41,
  71. Open: 43,
  72. PrintScreen: 44,
  73. Insert: 45,
  74. Numpad0: 45,
  75. Delete: 46,
  76. NumpadDecimal: 46,
  77. Digit0: 48,
  78. Digit1: 49,
  79. Digit2: 50,
  80. Digit3: 51,
  81. Digit4: 52,
  82. Digit5: 53,
  83. Digit6: 54,
  84. Digit7: 55,
  85. Digit8: 56,
  86. Digit9: 57,
  87. KeyA: 65,
  88. KeyB: 66,
  89. KeyC: 67,
  90. KeyD: 68,
  91. KeyE: 69,
  92. KeyF: 70,
  93. KeyG: 71,
  94. KeyH: 72,
  95. KeyI: 73,
  96. KeyJ: 74,
  97. KeyK: 75,
  98. KeyL: 76,
  99. KeyM: 77,
  100. KeyN: 78,
  101. KeyO: 79,
  102. KeyP: 80,
  103. KeyQ: 81,
  104. KeyR: 82,
  105. KeyS: 83,
  106. KeyT: 84,
  107. KeyU: 85,
  108. KeyV: 86,
  109. KeyW: 87,
  110. KeyX: 88,
  111. KeyY: 89,
  112. KeyZ: 90,
  113. MetaLeft: 91,
  114. MetaRight: 92,
  115. ContextMenu: 93,
  116. NumpadMultiply: 106,
  117. NumpadAdd: 107,
  118. NumpadSubtract: 109,
  119. NumpadDivide: 111,
  120. F1: 112,
  121. F2: 113,
  122. F3: 114,
  123. F4: 115,
  124. F5: 116,
  125. F6: 117,
  126. F7: 118,
  127. F8: 119,
  128. F9: 120,
  129. F10: 121,
  130. F11: 122,
  131. F12: 123,
  132. F13: 124,
  133. F14: 125,
  134. F15: 126,
  135. F16: 127,
  136. F17: 128,
  137. F18: 129,
  138. F19: 130,
  139. F20: 131,
  140. F21: 132,
  141. F22: 133,
  142. F23: 134,
  143. F24: 135,
  144. NumLock: 144,
  145. ScrollLock: 145,
  146. AudioVolumeMute: 173,
  147. AudioVolumeDown: 174,
  148. AudioVolumeUp: 175,
  149. MediaTrackNext: 176,
  150. MediaTrackPrevious: 177,
  151. MediaStop: 178,
  152. MediaPlayPause: 179,
  153. Semicolon: 186,
  154. Equal: 187,
  155. NumpadEqual: 187,
  156. Comma: 188,
  157. Minus: 189,
  158. Period: 190,
  159. Slash: 191,
  160. Backquote: 192,
  161. BracketLeft: 219,
  162. Backslash: 220,
  163. BracketRight: 221,
  164. Quote: 222,
  165. AltGraph: 225,
  166. Props: 247,
  167. Cancel: 3,
  168. Clear: 12,
  169. Shift: 16,
  170. Control: 17,
  171. Alt: 18,
  172. Accept: 30,
  173. ModeChange: 31,
  174. ' ': 32,
  175. Print: 42,
  176. Execute: 43,
  177. '\\u0000': 46,
  178. a: 65,
  179. b: 66,
  180. c: 67,
  181. d: 68,
  182. e: 69,
  183. f: 70,
  184. g: 71,
  185. h: 72,
  186. i: 73,
  187. j: 74,
  188. k: 75,
  189. l: 76,
  190. m: 77,
  191. n: 78,
  192. o: 79,
  193. p: 80,
  194. q: 81,
  195. r: 82,
  196. s: 83,
  197. t: 84,
  198. u: 85,
  199. v: 86,
  200. w: 87,
  201. x: 88,
  202. y: 89,
  203. z: 90,
  204. Meta: 91,
  205. '*': 106,
  206. '+': 107,
  207. '-': 109,
  208. '/': 111,
  209. ';': 186,
  210. '=': 187,
  211. ',': 188,
  212. '.': 190,
  213. '`': 192,
  214. '[': 219,
  215. '\\\\': 220,
  216. ']': 221,
  217. "'": 222,
  218. Attn: 246,
  219. CrSel: 247,
  220. ExSel: 248,
  221. EraseEof: 249,
  222. Play: 250,
  223. ZoomOut: 251,
  224. ')': 48,
  225. '!': 49,
  226. '@': 50,
  227. '#': 51,
  228. $: 52,
  229. '%': 53,
  230. '^': 54,
  231. '&': 55,
  232. '(': 57,
  233. A: 65,
  234. B: 66,
  235. C: 67,
  236. D: 68,
  237. E: 69,
  238. F: 70,
  239. G: 71,
  240. H: 72,
  241. I: 73,
  242. J: 74,
  243. K: 75,
  244. L: 76,
  245. M: 77,
  246. N: 78,
  247. O: 79,
  248. P: 80,
  249. Q: 81,
  250. R: 82,
  251. S: 83,
  252. T: 84,
  253. U: 85,
  254. V: 86,
  255. W: 87,
  256. X: 88,
  257. Y: 89,
  258. Z: 90,
  259. ':': 186,
  260. '<': 188,
  261. _: 189,
  262. '>': 190,
  263. '?': 191,
  264. '~': 192,
  265. '{': 219,
  266. '|': 220,
  267. '}': 221,
  268. '"': 222,
  269. Camera: 44,
  270. EndCall: 95,
  271. VolumeDown: 182,
  272. VolumeUp: 183,
  273. };
  274. //# sourceMappingURL=USKeyboardLayout.js.map