diff --git a/python/jupyterlab_widgets/src/renderer.ts b/python/jupyterlab_widgets/src/renderer.ts index 1e0aa34f37..ce0d257625 100644 --- a/python/jupyterlab_widgets/src/renderer.ts +++ b/python/jupyterlab_widgets/src/renderer.ts @@ -74,7 +74,8 @@ export class WidgetRenderer let widget: LuminoWidget; try { - widget = (await manager.create_view(wModel)).luminoWidget; + const view = await manager.create_view(wModel); + widget = view.luminoWidget || view.pWidget; } catch (err) { this.node.textContent = 'Error displaying widget'; this.addClass('jupyter-widgets');