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

JupyterLab 3 bug fix #98

Merged
merged 3 commits into from
Apr 23, 2024
Merged

JupyterLab 3 bug fix #98

merged 3 commits into from
Apr 23, 2024

Conversation

martinRenou
Copy link
Collaborator

Fix support for JupyterLab 3 on the gist-publish feature

@martinRenou
Copy link
Collaborator Author

cc. @achhina @TanayParikh

Comment on lines +59 to 69
} catch(e) {
// @ts-ignore JupyterLab 3 support
const iter = panel.toolbar.layout.iter();
let widget: Widget;
while ((widget = iter.next())) {
if (widget instanceof ToolbarButton && widget.id == 'bx-publishButton') {
panel.toolbar.layout.removeWidget(widget);
break;
}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the reason for this patch that direct iteration over toolbar layouts not supported in JupyterLab 3?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, iterators have changed slightly from lumino v1 to lumino v2.

@achhina achhina merged commit e6e3198 into twosigma:master Apr 23, 2024
1 check failed
@martinRenou martinRenou deleted the jlab3_fix branch April 24, 2024 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants