Skip to content

Commit

Permalink
register item and change weight (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
The0zzy authored Apr 27, 2024
1 parent 734d2fa commit fde7316
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1037,7 +1037,7 @@
alert(message);
}

const workspaceSizeItem = {
const gitHubWorkspaceSizeItem = {
displayText: "Show Workspace Size",
preconditionFn: () => "enabled",
callback: showWorkspaceSize,
Expand All @@ -1052,7 +1052,7 @@
callback: exportWorkspaceJSON,
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubExportItem",
weight: 180,
weight: 181,
};

const gitHubImportItem = {
Expand All @@ -1061,7 +1061,7 @@
callback: importWorkspaceJSON,
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubImportItem",
weight: 181,
weight: 182,
};

const gitHubImportItemXML = {
Expand All @@ -1070,7 +1070,7 @@
callback: importFormattedXMLFile,
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubImportItemXML",
weight: 182,
weight: 183,
};

const gitHubSetupItem = {
Expand All @@ -1079,7 +1079,7 @@
callback: showSetupDialog,
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubSetupItem",
weight: 183,
weight: 184,
};

const gitHubPullItem = {
Expand All @@ -1093,7 +1093,7 @@
callback: gitHubPull,
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubPullItem",
weight: 184,
weight: 185,
};

const gitHubCommitItem = {
Expand All @@ -1109,7 +1109,7 @@
},
scopeType: _Blockly.ContextMenuRegistry.ScopeType.WORKSPACE,
id: "gitHubCommitItem",
weight: 185,
weight: 186,
};

const githubMenu = plugin.createMenu(
Expand Down Expand Up @@ -1167,6 +1167,7 @@
try {
showLoadingPopup("Register menu items...");
logInfo("Register menu items...");
plugin.registerItem(gitHubWorkspaceSizeItem);
plugin.registerItem(gitHubImportItem);
plugin.registerItem(gitHubImportItemXML);
plugin.registerItem(gitHubExportItem);
Expand Down

0 comments on commit fde7316

Please sign in to comment.