Merge pull request #6477 from brichet/fix/closable_tab

Change the tab renderer to allow adding closable tab
This commit is contained in:
Jeremy Tuloup 2022-07-20 10:41:18 +02:00 committed by GitHub
commit fb5d50346d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,7 +27,8 @@ import { ITranslator } from '@jupyterlab/translation';
import {
caretDownIcon,
folderIcon,
runningIcon
runningIcon,
TabBarSvg
} from '@jupyterlab/ui-components';
import { Menu, MenuBar, TabPanel } from '@lumino/widgets';
@ -113,7 +114,11 @@ const browserWidget: JupyterFrontEndPlugin<void> = {
toolbarRegistry: IToolbarWidgetRegistry,
manager: IRunningSessionManagers | null
): void => {
const tabPanel = new TabPanel({ tabPlacement: 'top', tabsMovable: true });
const tabPanel = new TabPanel({
tabPlacement: 'top',
tabsMovable: true,
renderer: TabBarSvg.defaultRenderer
});
tabPanel.addClass('jp-TreePanel');
const trans = translator.load('notebook');