Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
activate: (
app: JupyterFrontEnd,
labShell: ILabShell | null,
settingRegistry: ISettingRegistry | null,
mainMenu: IMainMenu | null,
palette: ICommandPalette | null
) => {
const statusBar = new StatusBar();
statusBar.id = 'jp-main-statusbar';
app.shell.add(statusBar, 'bottom');
// If available, connect to the shell's layout modified signal.
if (labShell) {
labShell.layoutModified.connect(() => {
statusBar.update();
});
}
const category: string = 'Main Area';
const command: string = 'statusbar:toggle';
app.commands.addCommand(command, {
label: 'Show Status Bar',
execute: (args: any) => {
activate: (
app: JupyterFrontEnd,
labShell: ILabShell | null,
settingRegistry: ISettingRegistry | null,
mainMenu: IMainMenu | null,
palette: ICommandPalette | null
) => {
const statusBar = new StatusBar();
statusBar.id = 'jp-main-statusbar';
app.shell.add(statusBar, 'bottom');
// If available, connect to the shell's layout modified signal.
if (labShell) {
labShell.layoutModified.connect(() => {
statusBar.update();
});
}
const category: string = 'Main Area';
const command: string = 'statusbar:toggle';
app.commands.addCommand(command, {
label: 'Show Status Bar',
execute: (args: any) => {
it('should construct a new status bar', () => {
const statusBar = new StatusBar();
expect(statusBar).to.be.an.instanceof(StatusBar);
});
});
beforeEach(() => {
statusBar = new StatusBar();
Widget.attach(statusBar, document.body);
});