- Notifications
You must be signed in to change notification settings - Fork5.5k
Add token on tree widget#6496
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Uh oh!
There was an error while loading.Please reload this page.
jtpio commentedAug 2, 2022
Thanks@brichet for working on this. Diff looks good. CI is currently broken because of |
brichet commentedAug 2, 2022
I called the widget and token |
jtpio commentedAug 2, 2022
Right, this naming mostly comes from the name of the Probably it's fine to keep that way for now while in alpha. We can always revisit later and maybe we could also rename the |
packages/tree-extension/src/index.ts Outdated
| import{NotebookTreeWidget}from'@jupyter-notebook/tree'; | ||
| import{INotebookTree}from'@jupyter-notebook/tree'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Looks like these two imports could be combined?
| import{INotebookTree}from'./token'; | ||
| exportclassNotebookTreeWidgetextendsTabPanelimplementsINotebookTree{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Let's add a docstring to the class andconstructor for consistency with the rest of the code base?
jtpio commentedAug 3, 2022
The UI tests checks still appear to be cancelled after restarting them: |
brichet commentedAug 4, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Thanks for reviewing@jtpio. I''l have a look at it. |
brichet commentedAug 4, 2022
A part of the tests are currently failing because of : So the tree widget toolbar is not displayed and filled with |
packages/tree-extension/src/index.ts Outdated
| } | ||
| }; | ||
| functionactivateNotebookTreeWidget( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Any specific reason to move the activate function to a separate function?
Maybe we can keep inlined as part of the plugin definition for consistency with the rest of the code base?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Not really, I reverted it
jtpio commentedAug 4, 2022
Thanks@brichet this is looking good. I wanted to check on Binder but it seems like it doesn't start v7 anymore, which also happens on Probably something changed in the setup (maybe the hatch migration), I'll have a look in a separate PR. |
jtpio commentedAug 4, 2022
This should be fixed by#6505. |
…ets in it from external extension
Remove trailing whitespaceCo-authored-by: Jeremy Tuloup <jeremy.tuloup@gmail.com>
brichet commentedAug 4, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Nice! But the binder link is created only when the PR opens the first time I think, so it will not work on this one. |
jtpio commentedAug 4, 2022
Right but it doesn't change, so we can open it again or refresh the page. |
jtpio left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Thanks!

Uh oh!
There was an error while loading.Please reload this page.
Fixes#6410
The
NotebookShellallows only one widget in the main area.As the tree view is a
TabPanel, it would be interesting to be able to add widgets (as it was possible in Classic Notebook).This PR adds a token on the
NotebookTreeWidget, the widget in main area in tree view.Any extension will now be able to optionally try to retrieve the
INotebookTreein theactivatefunction, and add widgets in it using theTabPanel's interface functions.It shouldclose#6478 as a more generic implementation.