import{SplitWidget}from"./SplitWidget.js";import{VBox}from"./Widget.js";export class Panel extends VBox{constructor(e){super(),this.element.classList.add("panel"),this.element.setAttribute("aria-label",e),this.element.classList.add(e),this._panelName=e,UI.panels[e]=this}get name(){return this._panelName}searchableView(){return null}elementsToRestoreScrollPositionsFor(){return[]}}export class PanelWithSidebar extends Panel{constructor(e,t){super(e),this._panelSplitWidget=new SplitWidget(!0,!1,this._panelName+"PanelSplitViewState",t||200),this._panelSplitWidget.show(this.element),this._mainWidget=new VBox,this._panelSplitWidget.setMainWidget(this._mainWidget),this._sidebarWidget=new VBox,this._sidebarWidget.setMinimumSize(100,25),this._panelSplitWidget.setSidebarWidget(this._sidebarWidget),this._sidebarWidget.element.classList.add("panel-sidebar")}panelSidebarElement(){return this._sidebarWidget.element}mainElement(){return this._mainWidget.element}splitWidget(){return this._panelSplitWidget}}