Skip to content

Commit

Permalink
Feature editor title menu (#1366)
Browse files Browse the repository at this point in the history
* add title menu command

* update nls

* remove strike through from title bar
  • Loading branch information
peaceshi authored Dec 17, 2023
1 parent d4ecb64 commit c271b16
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 0 deletions.
56 changes: 56 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@
"command": "markdown.extension.editing.toggleCodeSpan",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleCodeSpan.title%",
"icon":"$(code)",
"category": "Markdown All in One"
},
{
Expand All @@ -130,13 +131,41 @@
"command": "markdown.extension.editing.toggleList",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleList.title%",
"icon":"$(list-unordered)",
"category": "Markdown All in One"
},
{
"command": "markdown.extension.editing.toggleCodeBlock",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleCodeBlock.title%",
"category": "Markdown All in One"
},
{
"command": "markdown.extension.editing.toggleBold",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleBold%",
"icon":"$(bold)",
"category": "Markdown All in One"
},
{
"command": "markdown.extension.editing.toggleItalic",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleItalic%",
"icon":"$(italic)",
"category": "Markdown All in One"
},
{
"command": "markdown.extension.editing.toggleStrikethrough",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.editing.toggleStrikethrough%",
"category": "Markdown All in One"
},
{
"command": "markdown.extension.checkTaskList",
"enablement": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"title": "%command.checkTaskList%",
"icon":"$(tasklist)",
"category": "Markdown All in One"
}
],
"menus": {
Expand All @@ -151,6 +180,33 @@
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/ && workspaceFolderCount >= 1",
"group": "markdown.print@2"
}
],
"editor/title": [
{
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"command": "markdown.extension.editing.toggleBold",
"group": "navigation@1_1"
},
{
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"command": "markdown.extension.editing.toggleItalic",
"group": "navigation@1_2"
},
{
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"command": "markdown.extension.checkTaskList",
"group": "navigation@1_3"
},
{
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"command": "markdown.extension.editing.toggleCodeSpan",
"group": "navigation@1_4"
},
{
"when": "editorLangId =~ /^markdown$|^rmd$|^quarto$/",
"command": "markdown.extension.editing.toggleList",
"group": "navigation@1_5"
}
]
},
"keybindings": [
Expand Down
4 changes: 4 additions & 0 deletions package.nls.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
"command.editing.toggleMathReverse.title": "Toggle math environment (in reverse order)",
"command.editing.toggleList.title": "Toggle list",
"command.editing.toggleCodeBlock.title": "Toggle code block",
"command.editing.toggleBold": "Toggle Bold",
"command.editing.toggleItalic": "Toggle Italic",
"command.editing.toggleStrikethrough": "Toggle Strikethrough",
"command.checkTaskList": "Toggle TaskList",
"config.title": "Markdown All in One",
"config.completion.enabled": "Whether to enable auto-completion.",
"config.completion.respectVscodeSearchExclude": "Whether to exclude files from auto-completion using VS Code's `#search.exclude#` setting. (`node_modules`, `bower_components` and `*.code-search` are **always excluded**, not affected by this option.)",
Expand Down

0 comments on commit c271b16

Please sign in to comment.