plugin.json 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439
  1. {
  2. "title": "Main Menu",
  3. "description": "Main JupyterLab menu settings.",
  4. "jupyter.lab.menus": {
  5. "main": [
  6. {
  7. "id": "jp-mainmenu-file",
  8. "label": "File",
  9. "items": [
  10. {
  11. "type": "submenu",
  12. "submenu": {
  13. "id": "jp-mainmenu-file-new",
  14. "label": "New",
  15. "items": []
  16. },
  17. "rank": 0
  18. },
  19. {
  20. "type": "separator",
  21. "rank": 2
  22. },
  23. {
  24. "command": "filemenu:create-console",
  25. "rank": 2.1
  26. },
  27. {
  28. "command": "filemenu:close-and-cleanup",
  29. "rank": 3.1
  30. },
  31. {
  32. "type": "separator",
  33. "rank": 99
  34. },
  35. {
  36. "command": "filemenu:logout",
  37. "rank": 99
  38. },
  39. {
  40. "command": "filemenu:shutdown",
  41. "rank": 99
  42. }
  43. ],
  44. "rank": 1
  45. },
  46. {
  47. "id": "jp-mainmenu-edit",
  48. "label": "Edit",
  49. "items": [
  50. {
  51. "command": "editmenu:undo",
  52. "rank": 0
  53. },
  54. {
  55. "command": "editmenu:redo",
  56. "rank": 0
  57. },
  58. {
  59. "type": "separator",
  60. "rank": 10
  61. },
  62. {
  63. "command": "editmenu:clear-current",
  64. "rank": 10
  65. },
  66. {
  67. "command": "editmenu:clear-all",
  68. "rank": 10
  69. },
  70. {
  71. "type": "separator",
  72. "rank": 200
  73. },
  74. {
  75. "command": "editmenu:go-to-line",
  76. "rank": 200
  77. }
  78. ],
  79. "rank": 2
  80. },
  81. {
  82. "id": "jp-mainmenu-view",
  83. "label": "View",
  84. "items": [
  85. {
  86. "type": "submenu",
  87. "rank": 1,
  88. "submenu": {
  89. "id": "jp-mainmenu-view-appearance",
  90. "label": "Appearance",
  91. "items": [
  92. {
  93. "command": "viewmenu:show-minimap",
  94. "rank": 50
  95. },
  96. {
  97. "type": "separator",
  98. "rank": 50
  99. }
  100. ]
  101. }
  102. },
  103. {
  104. "type": "separator",
  105. "rank": 10
  106. },
  107. {
  108. "command": "viewmenu:line-numbering",
  109. "rank": 10
  110. },
  111. {
  112. "command": "viewmenu:match-brackets",
  113. "rank": 10
  114. },
  115. {
  116. "command": "viewmenu:word-wrap",
  117. "rank": 10
  118. }
  119. ],
  120. "rank": 3
  121. },
  122. {
  123. "id": "jp-mainmenu-run",
  124. "label": "Run",
  125. "items": [
  126. {
  127. "command": "runmenu:run",
  128. "rank": 0
  129. },
  130. {
  131. "type": "separator"
  132. },
  133. {
  134. "command": "runmenu:run-all",
  135. "rank": 999
  136. },
  137. {
  138. "command": "runmenu:restart-and-run-all",
  139. "rank": 999
  140. }
  141. ],
  142. "rank": 4
  143. },
  144. {
  145. "id": "jp-mainmenu-kernel",
  146. "label": "Kernel",
  147. "items": [
  148. {
  149. "command": "kernelmenu:interrupt",
  150. "rank": 0
  151. },
  152. {
  153. "type": "separator",
  154. "rank": 1
  155. },
  156. {
  157. "command": "kernelmenu:restart",
  158. "rank": 1
  159. },
  160. {
  161. "command": "kernelmenu:restart-and-clear",
  162. "rank": 1
  163. },
  164. {
  165. "command": "runmenu:restart-and-run-all",
  166. "rank": 1.1
  167. },
  168. {
  169. "type": "separator",
  170. "rank": 1.5
  171. },
  172. {
  173. "command": "kernelmenu:reconnect-to-kernel",
  174. "rank": 1.5
  175. },
  176. {
  177. "type": "separator",
  178. "rank": 2
  179. },
  180. {
  181. "command": "kernelmenu:shutdown",
  182. "rank": 2
  183. },
  184. {
  185. "command": "kernelmenu:shutdownAll",
  186. "rank": 2
  187. },
  188. {
  189. "type": "separator",
  190. "rank": 3
  191. },
  192. {
  193. "command": "kernelmenu:change",
  194. "rank": 3
  195. }
  196. ],
  197. "rank": 5
  198. },
  199. {
  200. "id": "jp-mainmenu-tabs",
  201. "label": "Tabs",
  202. "items": [
  203. {
  204. "command": "application:activate-next-tab",
  205. "rank": 0
  206. },
  207. {
  208. "command": "application:activate-previous-tab",
  209. "rank": 0
  210. },
  211. {
  212. "command": "application:activate-next-tab-bar",
  213. "rank": 0
  214. },
  215. {
  216. "command": "application:activate-previous-tab-bar",
  217. "rank": 0
  218. },
  219. {
  220. "command": "tabsmenu:activate-previously-used-tab",
  221. "rank": 0
  222. }
  223. ],
  224. "rank": 500
  225. },
  226. {
  227. "id": "jp-mainmenu-settings",
  228. "label": "Settings",
  229. "items": [
  230. {
  231. "command": "settingeditor:open",
  232. "rank": 1000
  233. }
  234. ],
  235. "rank": 999
  236. },
  237. {
  238. "id": "jp-mainmenu-help",
  239. "label": "Help",
  240. "items": [],
  241. "rank": 1000
  242. }
  243. ],
  244. "context": [
  245. {
  246. "command": "filemenu:create-console",
  247. "selector": "[data-type=\"document-title\"].jp-mod-current",
  248. "rank": 10
  249. },
  250. {
  251. "command": "recentmenu:reopen-last",
  252. "selector": "#jp-main-dock-panel .lm-DockPanel-tabBar .lm-TabBar-tab",
  253. "rank": 6
  254. }
  255. ]
  256. },
  257. "jupyter.lab.shortcuts": [
  258. {
  259. "command": "editmenu:clear-all",
  260. "keys": [""],
  261. "selector": "[data-jp-undoer]"
  262. },
  263. {
  264. "command": "editmenu:clear-current",
  265. "keys": [""],
  266. "selector": "[data-jp-undoer]"
  267. },
  268. {
  269. "command": "editmenu:find",
  270. "keys": [""],
  271. "selector": "[data-jp-undoer]"
  272. },
  273. {
  274. "command": "editmenu:find-and-replace",
  275. "keys": [""],
  276. "selector": "[data-jp-undoer]"
  277. },
  278. {
  279. "command": "editmenu:redo",
  280. "keys": ["Accel Shift Z"],
  281. "selector": "[data-jp-undoer]"
  282. },
  283. {
  284. "command": "editmenu:undo",
  285. "keys": ["Accel Z"],
  286. "selector": "[data-jp-undoer]"
  287. },
  288. {
  289. "command": "filemenu:close-and-cleanup",
  290. "keys": ["Ctrl Shift Q"],
  291. "selector": ".jp-Activity"
  292. },
  293. {
  294. "command": "kernelmenu:interrupt",
  295. "keys": ["I", "I"],
  296. "selector": "[data-jp-kernel-user]:not(.jp-mod-readWrite) :focus:not(:read-write)"
  297. },
  298. {
  299. "command": "kernelmenu:restart",
  300. "keys": ["0", "0"],
  301. "selector": "[data-jp-kernel-user]:not(.jp-mod-readWrite) :focus:not(:read-write)"
  302. },
  303. {
  304. "command": "kernelmenu:restart-and-clear",
  305. "keys": [""],
  306. "selector": "[data-jp-kernel-user]:not(.jp-mod-readWrite) :focus:not(:read-write)"
  307. },
  308. {
  309. "command": "kernelmenu:shutdown",
  310. "keys": [""],
  311. "selector": "[data-jp-kernel-user]:not(.jp-mod-readWrite) :focus:not(:read-write)"
  312. },
  313. {
  314. "command": "runmenu:restart-and-run-all",
  315. "keys": [""],
  316. "selector": "[data-jp-code-runner]"
  317. },
  318. {
  319. "command": "runmenu:run",
  320. "keys": ["Shift Enter"],
  321. "selector": "[data-jp-code-runner]"
  322. },
  323. {
  324. "command": "runmenu:run-all",
  325. "keys": [""],
  326. "selector": "[data-jp-code-runner]"
  327. },
  328. {
  329. "command": "tabsmenu:activate-previously-used-tab",
  330. "keys": ["Accel Shift '"],
  331. "selector": "body"
  332. },
  333. {
  334. "command": "recentmenu:reopen-last",
  335. "keys": ["Accel Shift T"],
  336. "selector": "body"
  337. }
  338. ],
  339. "jupyter.lab.transform": true,
  340. "properties": {
  341. "menus": {
  342. "title": "The application menu description.",
  343. "description": "Note: To disable a menu or a menu item,\ncopy it to User Preferences and add the\n\"disabled\" key. The following example will disable\nthe \"Tabs\" menu and \"Restart Kernel and Run up to Selected Cell\"\nitem:\n{\n \"menus\": [\n {\n \"id\": \"jp-mainmenu-tabs\",\n \"disabled\": true\n },\n {\n \"id\": \"jp-mainmenu-kernel\",\n \"items\": [\n {\n \"command\": \"notebook:restart-and-run-to-selected\",\n \"disabled\": true\n }\n ]\n }\n ]\n}\n\nMenu description:",
  344. "items": {
  345. "$ref": "#/definitions/menu"
  346. },
  347. "type": "array",
  348. "default": []
  349. }
  350. },
  351. "additionalProperties": false,
  352. "definitions": {
  353. "menu": {
  354. "properties": {
  355. "disabled": {
  356. "description": "Whether the menu is disabled or not",
  357. "type": "boolean",
  358. "default": false
  359. },
  360. "icon": {
  361. "description": "Menu icon id",
  362. "type": "string"
  363. },
  364. "id": {
  365. "description": "Menu unique id",
  366. "type": "string",
  367. "pattern": "[a-z][a-z0-9\\-_]+"
  368. },
  369. "items": {
  370. "description": "Menu items",
  371. "type": "array",
  372. "items": {
  373. "$ref": "#/definitions/menuItem"
  374. }
  375. },
  376. "label": {
  377. "description": "Menu label",
  378. "type": "string"
  379. },
  380. "mnemonic": {
  381. "description": "Mnemonic index for the label",
  382. "type": "number",
  383. "minimum": -1,
  384. "default": -1
  385. },
  386. "rank": {
  387. "description": "Menu rank",
  388. "type": "number",
  389. "minimum": 0
  390. }
  391. },
  392. "required": ["id"],
  393. "additionalProperties": false,
  394. "type": "object"
  395. },
  396. "menuItem": {
  397. "properties": {
  398. "args": {
  399. "description": "Command arguments",
  400. "type": "object"
  401. },
  402. "command": {
  403. "description": "Command id",
  404. "type": "string"
  405. },
  406. "disabled": {
  407. "description": "Whether the item is disabled or not",
  408. "type": "boolean",
  409. "default": false
  410. },
  411. "type": {
  412. "description": "Item type",
  413. "type": "string",
  414. "enum": ["command", "submenu", "separator"],
  415. "default": "command"
  416. },
  417. "rank": {
  418. "description": "Item rank",
  419. "type": "number",
  420. "minimum": 0
  421. },
  422. "submenu": {
  423. "description": "Submenu definition",
  424. "oneOf": [
  425. {
  426. "$ref": "#/definitions/menu"
  427. },
  428. {
  429. "type": "null"
  430. }
  431. ]
  432. }
  433. },
  434. "additionalProperties": false,
  435. "type": "object"
  436. }
  437. },
  438. "type": "object"
  439. }