mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Pinning Notebooks on Notebooks view (#11963)
* initial commit * added tests * code cleanup and more tests * add missed util test * changes to address comments * remove pin from resources
This commit is contained in:
@@ -59,6 +59,14 @@
|
||||
"type": "number",
|
||||
"default": 60000,
|
||||
"description": "%notebook.remoteBookDownloadTimeout.description%"
|
||||
},
|
||||
"notebook.pinnedNotebooks": {
|
||||
"type": "array",
|
||||
"default": [],
|
||||
"description": "%notebook.pinnedNotebooks.description%",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -247,6 +255,21 @@
|
||||
"dark": "resources/dark/open_notebook_inverse.svg",
|
||||
"light": "resources/light/open_notebook.svg"
|
||||
}
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.pinNotebook",
|
||||
"title": "%title.pinNotebook%",
|
||||
"category": "%books-preview-category%",
|
||||
"icon": "$(pinned)"
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.unpinNotebook",
|
||||
"title": "%title.unpinNotebook%",
|
||||
"category": "%books-preview-category%",
|
||||
"icon": {
|
||||
"dark": "resources/dark/unpin_inverse.svg",
|
||||
"light": "resources/light/unpin.svg"
|
||||
}
|
||||
}
|
||||
],
|
||||
"languages": [
|
||||
@@ -364,6 +387,14 @@
|
||||
{
|
||||
"command": "notebook.command.revealInBooksViewlet",
|
||||
"when": "false"
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.pinNotebook",
|
||||
"when": "false"
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.unpinNotebook",
|
||||
"when": "false"
|
||||
}
|
||||
],
|
||||
"notebooks/title": [
|
||||
@@ -424,6 +455,16 @@
|
||||
{
|
||||
"command": "notebook.command.closeNotebook",
|
||||
"when": "view == bookTreeView && viewItem == savedNotebook"
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.pinNotebook",
|
||||
"when": "view == bookTreeView && viewItem == savedNotebook",
|
||||
"group": "inline"
|
||||
},
|
||||
{
|
||||
"command": "notebook.command.unpinNotebook",
|
||||
"when": "view == pinnedBooksView || view == bookTreeView && viewItem == pinnedNotebook",
|
||||
"group": "inline"
|
||||
}
|
||||
],
|
||||
"view/title": [
|
||||
@@ -454,6 +495,11 @@
|
||||
},
|
||||
"views": {
|
||||
"notebooks": [
|
||||
{
|
||||
"id": "pinnedBooksView",
|
||||
"name": "%title.PinnedBooks%",
|
||||
"when": "showPinnedbooks"
|
||||
},
|
||||
{
|
||||
"id": "bookTreeView",
|
||||
"name": "%title.SavedBooks%"
|
||||
|
||||
Reference in New Issue
Block a user