Skip to content

Commit

Permalink
fix: example
Browse files Browse the repository at this point in the history
  • Loading branch information
echarles committed Oct 23, 2023
1 parent a463ab9 commit 2d3cf14
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/react/src/examples/JupyterLabHeadlessApp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const PATH_INDEX = 1;

const JupyterLabHeadlessAppExample = () => {
const [notebookBoxPanel, setNotebookBoxPanel] = useState<BoxPanel>();
const [runningSessions, setRunningSessions] = useState<BoxPanel>();
const [runningSessions, setRunningSessions] = useState<RunningSessions>();
const [theme, setTheme] = useState<JupyterLabTheme>('light');
const [jupyterLabAdapter, setJupyterlabAdapter] = useState<JupyterLabAppAdapter>();
const { setColorMode } = useTheme();
Expand Down
13 changes: 10 additions & 3 deletions packages/react/src/jupyter/lumino/Lumino.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,20 @@ export const Lumino = (props: LuminoProps) => {
Widget.detach(children);
}
} catch(e) {
// no-op
// console.debug('Exception while detaching Lumino widget.', e);
// no-op.
// console.debug('Exception while detaching Lumino widget.', e);
}
}
}
}, [ref, children]);
return <div ref={ref} id={id} style={{ height: height, minHeight: height }} />
return (
<div
ref={ref}
id={id}
style={{ height: height, minHeight: height }}
>
</div>
)
}

Lumino.defaultProps = {
Expand Down
4 changes: 2 additions & 2 deletions packages/react/src/jupyter/lumino/LuminoBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ export const LuminoBox = (props: LuminoBoxProps) => {
Widget.detach(boxPanel);
}
} catch(e) {
// no-op
// console.debug('Exception while detaching Lumino widget.', e);
// no-op.
// console.debug('Exception while detaching Lumino widget.', e);
}
}
}
Expand Down

0 comments on commit 2d3cf14

Please sign in to comment.