mirror of
https://github.com/pacnpal/Roo-Code.git
synced 2025-12-20 12:21:13 -05:00
Update view names
This commit is contained in:
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
26
package.json
26
package.json
@@ -15,40 +15,34 @@
|
|||||||
"viewsContainers": {
|
"viewsContainers": {
|
||||||
"activitybar": [
|
"activitybar": [
|
||||||
{
|
{
|
||||||
"id": "custom-activitybar",
|
"id": "claude-dev-ActivityBar",
|
||||||
"title": "VSCode Extension",
|
"title": "Claude Dev",
|
||||||
"icon": "assets/logo_bito.svg"
|
"icon": "assets/icon.png"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"views": {
|
"views": {
|
||||||
"custom-activitybar": [
|
"claude-dev-ActivityBar": [
|
||||||
{
|
{
|
||||||
"type": "webview",
|
"type": "webview",
|
||||||
"id": "vscodeSidebar.openview",
|
"id": "claude-dev.SidebarProvider",
|
||||||
"name": "View",
|
"name": ""
|
||||||
"contextualTitle": "View"
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"commands": [
|
"commands": [
|
||||||
{
|
{
|
||||||
"command": "vscodeSidebar.openview",
|
"command": "claude-dev.menuButtonTapped",
|
||||||
"title": "Sidebar View"
|
"title": "Text that will show when hovered",
|
||||||
},
|
|
||||||
{
|
|
||||||
"command": "vscodeSidebar.menu.view",
|
|
||||||
"category": "vscode-extension-sidebar-html",
|
|
||||||
"title": "Sample WebView in VS Code Sidebar",
|
|
||||||
"icon": "$(clear-all)"
|
"icon": "$(clear-all)"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"menus": {
|
"menus": {
|
||||||
"view/title": [
|
"view/title": [
|
||||||
{
|
{
|
||||||
"command": "vscodeSidebar.menu.view",
|
"command": "claude-dev.menuButtonTapped",
|
||||||
"group": "navigation",
|
"group": "navigation",
|
||||||
"when": "view == vscodeSidebar.openview"
|
"when": "view == claude-dev.SidebarProvider"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,21 +34,12 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
context.subscriptions.push(vscode.window.registerWebviewViewProvider(SidebarProvider.viewType, provider))
|
context.subscriptions.push(vscode.window.registerWebviewViewProvider(SidebarProvider.viewType, provider))
|
||||||
|
|
||||||
context.subscriptions.push(
|
context.subscriptions.push(
|
||||||
vscode.commands.registerCommand("vscodeSidebar.menu.view", () => {
|
vscode.commands.registerCommand("claude-dev.menuButtonTapped", () => {
|
||||||
const message = "Menu/Title of extension is clicked !"
|
const message = "claude-dev.menuButtonTapped!"
|
||||||
vscode.window.showInformationMessage(message)
|
vscode.window.showInformationMessage(message)
|
||||||
})
|
})
|
||||||
)
|
)
|
||||||
|
|
||||||
// Command has been defined in the package.json file
|
|
||||||
// Provide the implementation of the command with registerCommand
|
|
||||||
// CommandId parameter must match the command field in package.json
|
|
||||||
let openWebView = vscode.commands.registerCommand("vscodeSidebar.openview", () => {
|
|
||||||
// Display a message box to the user
|
|
||||||
vscode.window.showInformationMessage('Command " Sidebar View [vscodeSidebar.openview] " called.')
|
|
||||||
})
|
|
||||||
|
|
||||||
context.subscriptions.push(openWebView)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// This method is called when your extension is deactivated
|
// This method is called when your extension is deactivated
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ https://github.com/KumarVariable/vscode-extension-sidebar-html/blob/master/src/c
|
|||||||
|
|
||||||
|
|
||||||
export class SidebarProvider implements vscode.WebviewViewProvider {
|
export class SidebarProvider implements vscode.WebviewViewProvider {
|
||||||
public static readonly viewType = "vscodeSidebar.openview"
|
public static readonly viewType = "claude-dev.SidebarProvider"
|
||||||
|
|
||||||
private _view?: vscode.WebviewView
|
private _view?: vscode.WebviewView
|
||||||
|
|
||||||
@@ -86,7 +86,7 @@ export class SidebarProvider implements vscode.WebviewViewProvider {
|
|||||||
<meta name="theme-color" content="#000000">
|
<meta name="theme-color" content="#000000">
|
||||||
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; style-src ${webview.cspSource}; script-src 'nonce-${nonce}';">
|
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; style-src ${webview.cspSource}; script-src 'nonce-${nonce}';">
|
||||||
<link rel="stylesheet" type="text/css" href="${stylesUri}">
|
<link rel="stylesheet" type="text/css" href="${stylesUri}">
|
||||||
<title>Hello World</title>
|
<title>Claude Dev</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||||
|
|||||||
Reference in New Issue
Block a user