mirror of
https://github.com/microsoft/vscode-extension-samples.git
synced 2026-04-27 16:55:44 +08:00
This makes sure that if folks get a relatively recent `vscode.d.ts`. It also lets us safely bump up the target to es2024 so you can use all the latest lib additions
170 lines
3.7 KiB
JSON
170 lines
3.7 KiB
JSON
{
|
|
"name": "vscode-comment-api-example",
|
|
"displayName": "Comment API Sample",
|
|
"description": "Comment API Sample",
|
|
"version": "0.0.1",
|
|
"publisher": "vscode-samples",
|
|
"private": true,
|
|
"license": "MIT",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "https://github.com/Microsoft/vscode-extension-samples"
|
|
},
|
|
"engines": {
|
|
"vscode": "^1.100.0"
|
|
},
|
|
"categories": [
|
|
"Other"
|
|
],
|
|
"activationEvents": [
|
|
"*"
|
|
],
|
|
"main": "./out/extension.js",
|
|
"contributes": {
|
|
"commands": [
|
|
{
|
|
"command": "mywiki.createNote",
|
|
"title": "Create Note",
|
|
"enablement": "!commentIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.replyNote",
|
|
"title": "Reply",
|
|
"enablement": "!commentIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.editNote",
|
|
"title": "Edit",
|
|
"icon": {
|
|
"dark": "resources/edit_inverse.svg",
|
|
"light": "resources/edit.svg"
|
|
}
|
|
},
|
|
{
|
|
"command": "mywiki.deleteNote",
|
|
"title": "Delete",
|
|
"icon": {
|
|
"dark": "resources/close_inverse.svg",
|
|
"light": "resources/close.svg"
|
|
}
|
|
},
|
|
{
|
|
"command": "mywiki.deleteNoteComment",
|
|
"title": "Delete",
|
|
"icon": {
|
|
"dark": "resources/close_inverse.svg",
|
|
"light": "resources/close.svg"
|
|
}
|
|
},
|
|
{
|
|
"command": "mywiki.saveNote",
|
|
"title": "Save"
|
|
},
|
|
{
|
|
"command": "mywiki.cancelsaveNote",
|
|
"title": "Cancel"
|
|
},
|
|
{
|
|
"command": "mywiki.startDraft",
|
|
"title": "Start Draft",
|
|
"enablement": "!commentIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.finishDraft",
|
|
"title": "Finish Draft"
|
|
},
|
|
{
|
|
"command": "mywiki.dispose",
|
|
"title": "Remove All Notes"
|
|
}
|
|
],
|
|
"menus": {
|
|
"commandPalette": [
|
|
{
|
|
"command": "mywiki.createNote",
|
|
"when": "false"
|
|
},
|
|
{
|
|
"command": "mywiki.replyNote",
|
|
"when": "false"
|
|
},
|
|
{
|
|
"command": "mywiki.deleteNote",
|
|
"when": "false"
|
|
},
|
|
{
|
|
"command": "mywiki.deleteNoteComment",
|
|
"when": "false"
|
|
}
|
|
],
|
|
"comments/commentThread/title": [
|
|
{
|
|
"command": "mywiki.deleteNote",
|
|
"group": "navigation",
|
|
"when": "commentController == comment-sample && !commentThreadIsEmpty"
|
|
}
|
|
],
|
|
"comments/commentThread/context": [
|
|
{
|
|
"command": "mywiki.createNote",
|
|
"group": "inline",
|
|
"when": "commentController == comment-sample && commentThreadIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.replyNote",
|
|
"group": "inline",
|
|
"when": "commentController == comment-sample && !commentThreadIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.startDraft",
|
|
"group": "inline",
|
|
"when": "commentController == comment-sample && commentThreadIsEmpty"
|
|
},
|
|
{
|
|
"command": "mywiki.finishDraft",
|
|
"group": "inline",
|
|
"when": "commentController == comment-sample && commentThread == draft"
|
|
}
|
|
],
|
|
"comments/comment/title": [
|
|
{
|
|
"command": "mywiki.editNote",
|
|
"group": "group@1",
|
|
"when": "commentController == comment-sample"
|
|
},
|
|
{
|
|
"command": "mywiki.deleteNoteComment",
|
|
"group": "group@2",
|
|
"when": "commentController == comment-sample && comment == canDelete"
|
|
}
|
|
],
|
|
"comments/comment/context": [
|
|
{
|
|
"command": "mywiki.cancelsaveNote",
|
|
"group": "inline@1",
|
|
"when": "commentController == comment-sample"
|
|
},
|
|
{
|
|
"command": "mywiki.saveNote",
|
|
"group": "inline@2",
|
|
"when": "commentController == comment-sample"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"scripts": {
|
|
"vscode:prepublish": "npm run compile",
|
|
"compile": "tsc -p ./",
|
|
"watch": "tsc -watch -p ./",
|
|
"lint": "eslint"
|
|
},
|
|
"devDependencies": {
|
|
"@eslint/js": "^9.13.0",
|
|
"@stylistic/eslint-plugin": "^2.9.0",
|
|
"@types/node": "^22",
|
|
"@types/vscode": "^1.100.0",
|
|
"eslint": "^9.13.0",
|
|
"typescript": "^5.9.2",
|
|
"typescript-eslint": "^8.39.0"
|
|
}
|
|
} |