Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a description to plugins #7008

Closed
jtpio opened this issue Aug 11, 2023 · 2 comments · Fixed by #7127
Closed

Add a description to plugins #7008

jtpio opened this issue Aug 11, 2023 · 2 comments · Fixed by #7127

Comments

@jtpio
Copy link
Member

jtpio commented Aug 11, 2023

Lumino 2 now supports adding a description to plugins: jupyterlab/lumino#572

Currently most plugins in this repo don't make use of it, for example:

/**
* A plugin to display the document title in the browser tab title
*/
const tabTitle: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:tab-title',
autoStart: true,
requires: [INotebookShell],
activate: (app: JupyterFrontEnd, shell: INotebookShell) => {
const setTabTitle = () => {
const current = shell.currentWidget;
if (current instanceof ConsolePanel) {
const update = () => {
const title =
current.sessionContext.path || current.sessionContext.name;
const basename = PathExt.basename(title);
// Strip the ".ipynb" suffix from filenames for display in tab titles.
document.title = basename.replace(STRIP_IPYNB, '');
};
current.sessionContext.sessionChanged.connect(update);
update();
return;
} else if (current instanceof DocumentWidget) {
const update = () => {
const basename = PathExt.basename(current.context.path);
document.title = basename.replace(STRIP_IPYNB, '');
};
current.context.pathChanged.connect(update);
update();
}
};
shell.currentChanged.connect(setTabTitle);
setTabTitle();
},
};

We should add them to the notebook code base, so it's useful for contributors but also for users at some point: jupyterlab/jupyterlab#14536

@jupyterlab-probot jupyterlab-probot bot added the status:Needs Triage Applied to issues that need triage label Aug 11, 2023
@jtpio
Copy link
Member Author

jtpio commented Aug 11, 2023

This could be a good task for a new contributor willing to get into the notebook code base.

@Ramyahkay
Copy link

Ramyahkay commented Aug 13, 2023

I am a beginner contributor and I'd like to work on this issue.

@RRosio RRosio removed the status:Needs Triage Applied to issues that need triage label Aug 15, 2023
Dilip-Jain added a commit to Dilip-Jain/notebook that referenced this issue Oct 26, 2023
Add a description to plugins jupyter#7008
jtpio added a commit that referenced this issue Oct 27, 2023
* Added Lumino Plugin Description

* Added Lumino Plugin Description

* Added Lumino Plugin Description

* Added Lumino Plugin Description

* Added Lumino Description

* Added Lumino Description

* Added Lumino Description

* Added Lumino Description

* Added Lumino Description

* Fixed test checks

* Fixed test checks

* Fixed test checks

* Fixed test checks

---------

Co-authored-by: Aditya Mahimkar <mahimkaradi@gmail.com>
Co-authored-by: Jeremy Tuloup <jeremy.tuloup@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants