Title the new-diagram command New Diagram Archify… (0.4.1)

The Explorer folder menu shows a command's title without its category,
so it read just "New Diagram…". The title now names Archify itself and
the category is dropped, so the Command Palette shows the same text.
Integration test asserts the title.
This commit is contained in:
2026-10-04 21:49:54 +03:00
parent 6f6ffae96f
commit 8d8fc6f65e
6 changed files with 20 additions and 12 deletions
+3 -3
View File
@@ -112,7 +112,7 @@ export function activate(context: vscode.ExtensionContext): void {
vscode.commands.registerCommand('archify.newDiagram', async (arg?: unknown) => {
const template = await vscode.window.showQuickPick(
TEMPLATES.map((item) => ({ label: item.label, description: item.description, template: item })),
{ title: 'New Archify Diagram', placeHolder: 'Kind of diagram' },
{ title: 'New Diagram Archify', placeHolder: 'Kind of diagram' },
);
if (!template) return;
const { file, defaultName } = template.template;
@@ -121,7 +121,7 @@ export function activate(context: vscode.ExtensionContext): void {
let target: vscode.Uri | undefined;
if (folder) {
const name = await vscode.window.showInputBox({
title: 'New Archify Diagram',
title: 'New Diagram Archify',
prompt: `File name in ${vscode.workspace.asRelativePath(folder, true)}`,
value: defaultName,
validateInput: async (value) =>
@@ -133,7 +133,7 @@ export function activate(context: vscode.ExtensionContext): void {
} else {
// No workspace: let the user choose where to save.
target = await vscode.window.showSaveDialog({
title: 'New Archify Diagram',
title: 'New Diagram Archify',
filters: { 'Archify Diagram': ['archify'] },
saveLabel: 'Create',
});