Repository navigation
Expand file tree
/
Copy pathpackage.json
More file actions
486 lines (486 loc) · 14.6 KB
/
Copy pathpackage.json
File metadata and controls
486 lines (486 loc) · 14.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
{
"name": "workspace-wiki",
"displayName": "Workspace Wiki",
"description": "Workspace Wiki",
"version": "1.3.0",
"publisher": "alexjsully",
"engines": {
"vscode": "^1.105.0"
},
"homepage": "https://github.com/AlexJSully/workspace-wiki",
"categories": [
"Other"
],
"contributors": [
{
"name": "Alexander Sullivan",
"email": "alexjsully.connect@outlook.com",
"url": "https://alexjsully.me/"
}
],
"activationEvents": [],
"main": "./dist/extension.js",
"browser": "./dist/web/extension.js",
"capabilities": {
"virtualWorkspaces": true,
"untrustedWorkspaces": {
"supported": true
}
},
"icon": "media/icon.png",
"galleryBanner": {
"color": "#2B5797",
"theme": "dark"
},
"contributes": {
"viewsContainers": {
"activitybar": [
{
"id": "workspaceWiki",
"title": "Workspace Wiki",
"icon": "media/icon.svg"
}
]
},
"commands": [
{
"command": "workspace-wiki.openPreview",
"title": "Open in Preview",
"icon": "$(open-preview)"
},
{
"command": "workspace-wiki.openEditor",
"title": "Edit",
"icon": "$(edit)"
},
{
"command": "workspace-wiki.refresh",
"title": "Refresh",
"icon": "$(refresh)"
},
{
"command": "workspace-wiki.openSite",
"title": "Open Wiki Site",
"category": "Workspace Wiki",
"icon": "$(book)"
},
{
"command": "workspace-wiki.openInSite",
"title": "Open in Wiki Site",
"category": "Workspace Wiki",
"icon": "$(book)"
},
{
"command": "workspace-wiki.site.openInNewTab",
"title": "Open in New Tab"
},
{
"command": "workspace-wiki.site.openToSide",
"title": "Open to the Side"
},
{
"command": "workspace-wiki.site.openOriginal",
"title": "Open Original File"
},
{
"command": "workspace-wiki.site.editSource",
"title": "Edit Source"
},
{
"command": "workspace-wiki.site.copyPath",
"title": "Copy Relative Path"
},
{
"command": "workspace-wiki.site.openLinkExternal",
"title": "Open in Default Browser"
},
{
"command": "workspace-wiki.site.openLinkIntegrated",
"title": "Open in Integrated Browser"
},
{
"command": "workspace-wiki.site.copyLink",
"title": "Copy Link Address"
}
],
"views": {
"explorer": [
{
"id": "workspaceWiki",
"name": "Workspace Wiki",
"icon": "media/icon.svg"
}
]
},
"menus": {
"view/item/context": [
{
"command": "workspace-wiki.openPreview",
"when": "view == workspaceWiki && viewItem == file",
"group": "navigation@1"
},
{
"command": "workspace-wiki.openEditor",
"when": "view == workspaceWiki && viewItem == file",
"group": "navigation@2"
},
{
"command": "workspace-wiki.openInSite",
"when": "view == workspaceWiki && viewItem == file",
"group": "navigation@3"
}
],
"explorer/context": [
{
"command": "workspace-wiki.openInSite",
"when": "!explorerResourceIsFolder && (resource in workspaceWiki.indexedFiles || (!workspaceWiki.indexedFiles && resourceLangId == markdown))",
"group": "navigation"
}
],
"editor/title/context": [
{
"command": "workspace-wiki.openInSite",
"when": "resource in workspaceWiki.indexedFiles || (!workspaceWiki.indexedFiles && resourceLangId == markdown)",
"group": "navigation"
}
],
"view/item/inline": [
{
"command": "workspace-wiki.openPreview",
"when": "view == workspaceWiki && viewItem == file",
"group": "inline@1"
},
{
"command": "workspace-wiki.openEditor",
"when": "view == workspaceWiki && viewItem == file",
"group": "inline@2"
}
],
"view/title": [
{
"command": "workspace-wiki.openSite",
"when": "view == workspaceWiki",
"group": "navigation@1"
},
{
"command": "workspace-wiki.refresh",
"when": "view == workspaceWiki",
"group": "navigation"
}
],
"webview/context": [
{
"command": "workspace-wiki.site.openInNewTab",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'doc'",
"group": "navigation@1"
},
{
"command": "workspace-wiki.site.openToSide",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'doc'",
"group": "navigation@2"
},
{
"command": "workspace-wiki.site.openOriginal",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'doc'",
"group": "open@1"
},
{
"command": "workspace-wiki.site.editSource",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'doc'",
"group": "open@2"
},
{
"command": "workspace-wiki.site.copyPath",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'doc'",
"group": "copy@1"
},
{
"command": "workspace-wiki.site.openLinkExternal",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'external'",
"group": "navigation@1"
},
{
"command": "workspace-wiki.site.openLinkIntegrated",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'external'",
"group": "navigation@2"
},
{
"command": "workspace-wiki.site.copyLink",
"when": "webviewId == 'workspaceWiki.site' && webviewSection == 'external'",
"group": "copy@1"
}
],
"commandPalette": [
{
"command": "workspace-wiki.openInSite",
"when": "false"
},
{
"command": "workspace-wiki.site.openInNewTab",
"when": "false"
},
{
"command": "workspace-wiki.site.openToSide",
"when": "false"
},
{
"command": "workspace-wiki.site.openOriginal",
"when": "false"
},
{
"command": "workspace-wiki.site.editSource",
"when": "false"
},
{
"command": "workspace-wiki.site.copyPath",
"when": "false"
},
{
"command": "workspace-wiki.site.openLinkExternal",
"when": "false"
},
{
"command": "workspace-wiki.site.openLinkIntegrated",
"when": "false"
},
{
"command": "workspace-wiki.site.copyLink",
"when": "false"
}
]
},
"configuration": {
"title": "Workspace Wiki",
"properties": {
"workspaceWiki.supportedExtensions": {
"type": "array",
"default": [
"md",
"markdown",
"mdx",
"txt"
],
"description": "List of file extensions to include in the workspace wiki",
"items": {
"type": "string"
}
},
"workspaceWiki.includeGlobs": {
"type": "array",
"default": [],
"description": "Additional file names or glob patterns to include beyond supportedExtensions (e.g. \"doc.go\", \"*.guide.ts\"). A pattern without a \"/\" matches at any depth. Exclude patterns, .gitignore, hidden-file, and depth settings still apply.",
"items": {
"type": "string"
}
},
"workspaceWiki.defaultOpenMode": {
"type": "string",
"enum": [
"preview",
"editor"
],
"default": "preview",
"description": "Default mode for opening files (preview or editor)"
},
"workspaceWiki.openWith": {
"type": "object",
"default": {
"md": "workspace-wiki.openMarkdown",
"markdown": "workspace-wiki.openMarkdown",
"mdx": "workspace-wiki.openMarkdown",
"txt": "vscode.open"
},
"description": "Commands to use for opening different file types. The default for Markdown, \"workspace-wiki.openMarkdown\", picks the best surface the running VS Code offers: the built-in Markdown Editor (VS Code 1.131+, .md only), otherwise Markdown Preview, otherwise a plain open. Set \"md\" to \"markdown.showPreview\" to always use the preview.",
"patternProperties": {
".*": {
"type": "string",
"description": "Command to execute for this file extension"
}
}
},
"workspaceWiki.directorySort": {
"type": "string",
"enum": [
"files-first",
"folders-first",
"alphabetical"
],
"default": "files-first",
"description": "How to sort files and folders within directories"
},
"workspaceWiki.excludeGlobs": {
"type": "array",
"default": [
"**/node_modules/**",
"**/.git/**"
],
"description": "Glob patterns for files to exclude from the workspace wiki. Your list replaces the default rather than adding to it, so include the default patterns in your list if you still want them applied.",
"items": {
"type": "string"
}
},
"workspaceWiki.maxSearchDepth": {
"type": "number",
"default": 10,
"description": "Maximum directory depth to search for documentation files"
},
"workspaceWiki.acronymCasing": {
"type": "array",
"default": [
"HTML",
"CSS",
"JS",
"TS",
"API",
"URL",
"JSON",
"XML",
"HTTP",
"HTTPS",
"REST",
"SQL",
"CSV",
"FHIR"
],
"description": "List of acronyms to preserve proper casing in file titles (e.g., 'html' becomes 'HTML')",
"items": {
"type": "string"
}
},
"workspaceWiki.showIgnoredFiles": {
"type": "boolean",
"default": false,
"description": "Show files and folders that are listed in .gitignore and excludeGlobs in the Workspace Wiki tree. Default is false (ignored/hidden)."
},
"workspaceWiki.showHiddenFiles": {
"type": "boolean",
"default": false,
"description": "Show hidden files and folders (those starting with a dot, e.g. .github, .env) in the Workspace Wiki tree, unless excluded by .gitignore or excludeGlobs. Default is false (hidden files are not shown)."
},
"workspaceWiki.autoReveal": {
"type": "boolean",
"default": true,
"description": "Automatically reveal the active file in the Workspace Wiki tree when the editor changes."
},
"workspaceWiki.autoRevealDelay": {
"type": "number",
"default": 500,
"description": "Delay in milliseconds before revealing the active file in the tree. Set to 0 for real-time reveal."
},
"workspaceWiki.site.theme": {
"type": "string",
"enum": [
"vscode",
"paper",
"slate",
"lagoon"
],
"enumDescriptions": [
"Follows the active VS Code colour theme.",
"Light, with an ink-blue accent.",
"Dark, blue-grey.",
"Light, under a teal header bar."
],
"default": "vscode",
"description": "Look of the Wiki Site. High-contrast colour themes always use \"vscode\"."
},
"workspaceWiki.site.customCss": {
"type": "array",
"default": [],
"items": {
"type": "string"
},
"description": "Stylesheets, as paths relative to the first workspace folder, loaded into the Wiki Site after its theme. Override the --wiki-* CSS variables on .wiki to restyle it (for example \".wiki { --wiki-accent: #8a3ffc; }\")."
},
"workspaceWiki.site.logo": {
"type": "string",
"default": "",
"description": "Image shown beside the workspace name in the Wiki Site header and used as its tab icon, as a path relative to the first workspace folder. Leave empty to use a favicon or logo found in the workspace. A tab can only show .svg, .png, .jpg, .gif or .webp images, so an .ico appears in the header only."
}
}
}
},
"scripts": {
"audit:fix": "npm i && npm audit fix",
"check-types": "tsc --noEmit && tsc -p cypress/tsconfig.json --noEmit",
"compile": "npm run check-types && node esbuild.js",
"compile:tests": "rm -rf out && npm run compile && npx esbuild src/extension.e2e.test.ts --bundle --platform=node --format=cjs --target=es2020 --external:vscode --external:mocha --outfile=out/extension.e2e.test.js",
"compile:tests:web": "npx esbuild src/test/web/index.ts --bundle --platform=browser --format=cjs --target=es2020 --external:vscode --outfile=out/web/index.js",
"harness:serve": "node esbuild.js --harness --serve",
"lint": "eslint src cypress cypress.config.ts",
"lint:markdown": "markdownlint-cli2",
"package": "node esbuild.js --production",
"package:vsix": "npm run compile && vsce package",
"pretest": "npm run compile:tests && npm run compile && npm run lint",
"prettier": "prettier --write ./",
"prettier:check": "prettier --check ./",
"regen-package-lock": "rm -rf node_modules package-lock.json && npm run audit:fix",
"run-in-browser": "npm run compile && vscode-test-web --browserType=chromium --quality=stable --extensionDevelopmentPath=. example",
"test:cypress": "node scripts/runWithoutElectronNode.mjs start-server-and-test harness:serve http://localhost:5179 \"cypress run --e2e --browser electron\"",
"test:cypress:open": "node scripts/runWithoutElectronNode.mjs start-server-and-test harness:serve http://localhost:5179 \"cypress open --e2e\"",
"test:extension": "npm run compile:tests && vscode-test",
"test:jest": "jest src/",
"test:jest:coverage": "jest --coverage src/",
"test:web": "npm run compile && npm run compile:tests:web && vscode-test-web --browserType=chromium --quality=stable --headless --extensionDevelopmentPath=. --extensionTestsPath=out/web/index.js example",
"validate": "npm run compile && npm run prettier && npm run lint && npm run lint:markdown && npm run test:jest && npm run test:extension && npm run test:web && npm run test:cypress && vsce package",
"vscode:prepublish": "npm run package",
"watch": "npm-run-all -p watch:*",
"watch-tests": "tsc -p . -w --outDir out",
"watch:esbuild": "node esbuild.js --watch",
"watch:tsc": "tsc --noEmit --watch --project tsconfig.json"
},
"dependencies": {
"dompurify": "^3.4.17",
"highlight.js": "^11.12.0",
"ignore": "^7.0.14",
"js-yaml": "^5.5.0",
"markdown-it": "^15.0.3",
"mermaid": "^12.2.0"
},
"devDependencies": {
"@trivago/prettier-plugin-sort-imports": "^6.0.2",
"@types/jest": "^30.0.0",
"@types/mocha": "^10.0.10",
"@types/node": "^26.6.6",
"@types/vscode": "1.105.0",
"@typescript-eslint/eslint-plugin": "^8.72.1",
"@typescript-eslint/parser": "^8.72.1",
"@vscode/test-cli": "^0.0.15",
"@vscode/test-electron": "^3.1.0",
"@vscode/test-web": "^0.0.81",
"@vscode/vsce": "^4.1.0",
"axe-core": "^4.14.0",
"cypress": "^15.21.1",
"cypress-axe": "^1.7.0",
"esbuild": "^0.28.2",
"eslint": "^10.13.0",
"jest": "^30.5.2",
"markdownlint-cli2": "^0.24.0",
"mocha": "^12.0.3",
"npm-run-all": "^4.1.5",
"prettier": "^3.9.10",
"start-server-and-test": "^3.0.13",
"ts-jest": "^29.4.15",
"typescript": "^6.0.3",
"vscode-uri": "^3.2.0"
},
"bugs": "https://github.com/AlexJSully/workspace-wiki/issues",
"repository": {
"type": "git",
"url": "https://github.com/AlexJSully/workspace-wiki.git"
},
"keywords": [
"documentation",
"wiki",
"markdown",
"notes",
"tree view",
"workspace",
"preview",
"editor",
"readme",
"index",
"local",
"vscode-extension"
]
}