-
Notifications
You must be signed in to change notification settings - Fork 907
Contribution points
This document covers the various contribution points that are defined in the package.json extension manifest. These are in addition to the ones inherited by VS Code.
Contribute tab, container, insight widget to the dashboard.
dashboard.tabs will create the tab sections inside the dashboard page. It expects an object or an array of objects.
"dashboard.tabs": [
{
"id": "test-tab1",
"title": "Test 1",
"description": "The test 1 displays a list of widgets.",
"when": "connectionProvider == 'MSSQL' && !mssql:iscloud",
"alwaysShow": true,
"container": {
…
}
}
]
Instead of specifying dashboard container inline (inside the dashboard.tab). You can register containers using dashboard.containers. It accepts an object or an array of the object.
"dashboard.containers": [
{
"id": "innerTab1",
"container": {
…
}
},
{
"id": "innerTab2",
"container": {
…
}
}
]
To refer to registered container, you can simply specify the id of the container
"dashboard.tabs": [
{
...
"container": {
"innerTab1": {
}
}
}
]
You can register insights using dashboard.insights. This is similiar to Tutorial: Build a custom insight widget
"dashboard.insights": {
"id": "my-widget"
"type": {
"count": {
"dataDirection": "vertical",
"dataType": "number",
"legendPosition": "none",
"labelFirstColumn": false,
"columnsAsLabels": false
}
},
"queryFile": "{your file folder}/activeSession.sql"
}
There are 4 different container types that we currently support:
-
The list of widgets that will be displayed in the container. It’s a flow layout. It accepts the list of widgets.widgets-container
"container": { "widgets-container": [ { "widget": { "query-data-store-db-insight": { } } }, { "widget": { "explorer-widget": { } } } ] }
-
The webview will be displayed in the entire container. It expects webview id to be the same is tab IDwebview-container
"container": { "webview-container": null }
-
The list of widgets or webviews that will be displayed in the grid layoutgrid-container
"container": { "grid-container": [ { "name": "widget 1", "widget": { "explorer-widget": { } }, "row":0, "col":0 }, { "name": "widget 2", "widget": { "tasks-widget": { "backup", "restore", "configureDashboard", "newQuery" } }, "row":0, "col":1 }, { "name": "Webview 1", "webview": { "id": "google" }, "row":1, "col":0, "colspan":2 }, { "name": "widget 3", "widget": { "explorer-widget": {} }, "row":0, "col":3, "rowspan":2 }, ]
-
The navigation section will be displayed in the containernav-section
"container": { "nav-section": [ { "id": "innerTab1", "title": "inner-tab1", "icon": { "light": "./icons/tab1Icon.svg", "dark": "./icons/tab1Icon_dark.svg" } "container": { … } }, { "id": "innerTab2", "title": "inner-tab2", "icon": { "light": "./icons/tab2Icon.svg", "dark": "./icons/tab2Icon_dark.svg" } "container": { … } } ] }
This is an array of dataExplorer
contributions, each with the following properties. This is used to add views to the Connections
view container in the panel - it currently doesn't support having views adding through the normal contributes.views extension point from VS Code.
The ID of the view - used when registering the associated vscode.TreeDataProvider
The human-readable name of the view shown in the title bar
The when-clause condition for when the view will be shown
These are custom menu contributions for Azure Data Studio, in addition to the built-in ones inherited from VS Code.
Menu items for Data Explorer contributed views.
Menu items for the Object Explorer (Server) tree view
To set an item as the default menu item when a node is double-clicked, you can set the isDefault
property to true
. An error will be logged to the console if multiple menu items are set as the default action for a node and none of them will be executed.
Example:
{
"command": "mssql.objectProperties",
"when": "connectionProvider == MSSQL && nodeType =~ /^(ServerLevelLogin|User)$/ && config.workbench.enablePreviewFeatures",
"group": "0_query@1",
"isDefault": true
}
Documentation
- Get Started
- Install Azure Data Studio
- Telemetry
- Microsoft Ready 2019 Lab
- MS Docs Overview
- Debug Trace Logging
- Troubleshoot Azure Authentication Issues
- FAQ
Contributing
- How to Contribute
- Developer Getting Started
- Submitting Bugs and Suggestions
- Localization
- Troubleshooting Build Issues
- Engineering FAQ
- How to update typings files
- Importing and using modules
- UI Guidelines
- Angular UI Guidelines
- Contributor License Agreement
- Azure Data Studio Tests
- Why is the Azure Data Studio license different than the repository license?
Tool Services
Extensibility Reference
- Getting Started
- Extensibility API
- Contribution Points
- Context Variables
- Servers and Data Explorer Tree Views
- Debugging with VS Code
- Extension Authoring
- Building multiple insight widgets
- Microsoft Ignite lab
- List of Extensions
- Replace sqlops namespace
Project Management