no need to redirect when removing tab. router handles this fine
This commit is contained in:
committed by
Jacob Overgaard
parent
eec7b01f1c
commit
5f291bab22
@@ -269,9 +269,8 @@ export class UmbContentTypeDesignEditorElement extends UmbLitElement implements
|
||||
#deleteTab(tabId?: string) {
|
||||
if (!tabId) return;
|
||||
this.#workspaceContext?.structure.removeContainer(null, tabId);
|
||||
// TODO: We should only navigate away if it was the last tab and if it was the active one... [NL]
|
||||
if (this.#tabsStructureHelper?.isOwnerChildContainer(tabId)) {
|
||||
window.history.replaceState(null, '', this._routerPath + (this._routes[0]?.path ?? '/root'));
|
||||
if (this._activeTabId === tabId) {
|
||||
this._activeTabId = undefined;
|
||||
}
|
||||
}
|
||||
async #addTab() {
|
||||
|
||||
Reference in New Issue
Block a user