-
-
Notifications
You must be signed in to change notification settings - Fork 132
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
fix(TabBar): Event forwarding fails when hosted in a ShadowRoot #276
Conversation
4785067
to
499f0ee
Compare
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! Just a couple of suggestions.
Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
499f0ee
to
ba25d64
Compare
@blink1073 FYI these changes are needed so that lumino widgets can be used within custom web components, which in turn can expose lumino widgets via "simple" html, see POC repo here (not currently published):
This should greatly simplify the use of lumino widgets within frameworks like React, Vue and Angular. |
Very nice! |
@GordonSmith, are you ready for me to make a release? |
@blink1073 no real rush as I am building off local branches for now. |
@blink1073 I might request a build if your not planning to do a release for a while? Did you have any thoughts on the above examples? |
The examples are cool! Happy to feature them as part of the https://github.com/jupyterlab/lumino#external-examples if you want to submit a PR. I'll cut a release on Monday (I don't like to make releases on a Friday). |
@@ -2184,7 +2193,7 @@ namespace Private { | |||
renderer: DockLayout.IRenderer | |||
): TabLayoutNode { | |||
// Create the tab bar for the layout node. | |||
let tabBar = renderer.createTabBar(); | |||
let tabBar = renderer.createTabBar(this._document); |
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.
Does this
exist in this context?
This function is inside the Private namespace.
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.
I'm updating lumino in JupyterLab, and there is an issue with this._document
, when changing to a single-mode document.
jupyterlab/jupyterlab#11823
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.
Do you have an example of the breaking code - I couldn't see anything related in the failing visual regression test?
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.
Fix incoming.
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.
FYI: #281
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.
Hey @GordonSmith, thanks for the quick reply.
Do you have an example of the breaking code
Yes, when in JupyterLab you change the view to a single-mode document, there is an error on this line:
https://github.com/jupyterlab/jupyterlab/blob/3b21d568035f7383dfd88332e051277130aea7d8/packages/application/src/shell.ts#L557
Following the trace, you can see that the error comes from
lumino/packages/widgets/src/docklayout.ts
Line 2196 in 948eec9
let tabBar = renderer.createTabBar(this._document); |
where this
is null.
Signed-off-by: Gordon Smith GordonJSmith@gmail.com