diff --git a/packages/notebook-extension/src/index.ts b/packages/notebook-extension/src/index.ts index 875da952cb8a..91ff1a281720 100644 --- a/packages/notebook-extension/src/index.ts +++ b/packages/notebook-extension/src/index.ts @@ -3604,9 +3604,7 @@ function addCommands( commands.addCommand(CommandIDs.virtualScrollbar, { label: trans.__('Show Minimap'), - caption: trans.__( - 'Show Minimap (virtual scrollbar, enabled with windowing mode: full)' - ), + caption: trans.__('Show Minimap'), execute: args => { const current = getCurrent(tracker, shell, args); @@ -3616,20 +3614,14 @@ function addCommands( }, icon: args => (args.toolbar ? tableRowsIcon : undefined), isEnabled: args => { - const enabled = - (args.toolbar ? true : isEnabled()) && - (settings?.composite.windowingMode === 'full' ?? false); - return enabled; + return args.toolbar ? true : isEnabled(); }, isToggled: () => { const current = tracker.currentWidget; return current?.content.scrollbar ?? false; }, isVisible: args => { - const visible = - (args.toolbar ? true : isEnabled()) && - (settings?.composite.windowingMode === 'full' ?? false); - return visible; + return args.toolbar ? true : isEnabled(); } }); diff --git a/packages/ui-components/src/components/windowedlist.ts b/packages/ui-components/src/components/windowedlist.ts index 8ad0ed343839..c3b419851dec 100644 --- a/packages/ui-components/src/components/windowedlist.ts +++ b/packages/ui-components/src/components/windowedlist.ts @@ -452,17 +452,9 @@ export abstract class WindowedListModel implements WindowedList.IModel { * @returns The current items range to display */ getRangeToRender(): WindowedList.WindowIndex | null { - let newWindowIndex: [number, number, number, number] = [ - 0, - Math.max(this.widgetCount - 1, -1), - 0, - Math.max(this.widgetCount - 1, -1) - ]; + const newWindowIndex = this._getRangeToRender(); const previousLastMeasuredIndex = this._measuredAllUntilIndex; - if (this.windowingActive) { - newWindowIndex = this._getRangeToRender(); - } const [startIndex, stopIndex] = newWindowIndex; if ( @@ -1824,10 +1816,10 @@ export class WindowedLayout extends PanelLayout { * * #### Notes * This is a reimplementation of the base class method, - * and is a no-op. */ protected onUpdateRequest(msg: Message): void { - // This is a no-op. + // @ts-ignore + this.parent?._update(); } }