diff --git a/apps/browser/src/popup/app-routing.module.ts b/apps/browser/src/popup/app-routing.module.ts index ad839bbd7c..73147cace2 100644 --- a/apps/browser/src/popup/app-routing.module.ts +++ b/apps/browser/src/popup/app-routing.module.ts @@ -105,10 +105,8 @@ import { clearVaultStateGuard } from "../vault/guards/clear-vault-state.guard"; import { AddEditComponent } from "../vault/popup/components/vault/add-edit.component"; import { AttachmentsComponent } from "../vault/popup/components/vault/attachments.component"; import { CollectionsComponent } from "../vault/popup/components/vault/collections.component"; -import { CurrentTabComponent } from "../vault/popup/components/vault/current-tab.component"; import { PasswordHistoryComponent } from "../vault/popup/components/vault/password-history.component"; import { ShareComponent } from "../vault/popup/components/vault/share.component"; -import { VaultFilterComponent } from "../vault/popup/components/vault/vault-filter.component"; import { VaultItemsComponent } from "../vault/popup/components/vault/vault-items.component"; import { VaultV2Component } from "../vault/popup/components/vault/vault-v2.component"; import { ViewComponent } from "../vault/popup/components/vault/view.component"; @@ -130,7 +128,6 @@ import { VaultSettingsComponent } from "../vault/popup/settings/vault-settings.c import { RouteElevation } from "./app-routing.animations"; import { debounceNavigationGuard } from "./services/debounce-navigation.service"; import { TabsV2Component } from "./tabs-v2.component"; -import { TabsComponent } from "./tabs.component"; /** * Data properties acceptable for use in extension route objects @@ -748,8 +745,9 @@ const routes: Routes = [ }, ], }, - ...extensionRefreshSwap(TabsComponent, TabsV2Component, { + { path: "tabs", + component: TabsV2Component, data: { elevation: 0 } satisfies RouteDataProperties, children: [ { @@ -759,18 +757,15 @@ const routes: Routes = [ }, { path: "current", - component: CurrentTabComponent, - canActivate: [authGuard], - canMatch: [extensionRefreshRedirect("/tabs/vault")], - data: { elevation: 0 } satisfies RouteDataProperties, - runGuardsAndResolvers: "always", + redirectTo: "/tabs/vault", }, - ...extensionRefreshSwap(VaultFilterComponent, VaultV2Component, { + { path: "vault", + component: VaultV2Component, canActivate: [authGuard, NewDeviceVerificationNoticeGuard], canDeactivate: [clearVaultStateGuard], data: { elevation: 0 } satisfies RouteDataProperties, - }), + }, ...extensionRefreshSwap(GeneratorComponent, CredentialGeneratorComponent, { path: "generator", canActivate: [authGuard], @@ -788,7 +783,7 @@ const routes: Routes = [ data: { elevation: 0 } satisfies RouteDataProperties, }), ], - }), + }, { path: "account-switcher", component: AccountSwitcherComponent, diff --git a/apps/browser/src/popup/app.module.ts b/apps/browser/src/popup/app.module.ts index 76bd06565c..4695f0820b 100644 --- a/apps/browser/src/popup/app.module.ts +++ b/apps/browser/src/popup/app.module.ts @@ -88,7 +88,6 @@ import { AppComponent } from "./app.component"; import { UserVerificationComponent } from "./components/user-verification.component"; import { ServicesModule } from "./services/services.module"; import { TabsV2Component } from "./tabs-v2.component"; -import { TabsComponent } from "./tabs.component"; // Register the locales for the application import "../platform/popup/locales"; @@ -177,7 +176,6 @@ import "../platform/popup/locales"; ShareComponent, SsoComponentV1, SyncComponent, - TabsComponent, TabsV2Component, TwoFactorComponent, TwoFactorOptionsComponent, diff --git a/apps/browser/src/popup/tabs.component.html b/apps/browser/src/popup/tabs.component.html deleted file mode 100644 index fd04967b91..0000000000 --- a/apps/browser/src/popup/tabs.component.html +++ /dev/null @@ -1,57 +0,0 @@ -
- - -
diff --git a/apps/browser/src/popup/tabs.component.ts b/apps/browser/src/popup/tabs.component.ts deleted file mode 100644 index 7546c9ca13..0000000000 --- a/apps/browser/src/popup/tabs.component.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { Component, OnInit } from "@angular/core"; - -import BrowserPopupUtils from "../platform/popup/browser-popup-utils"; - -@Component({ - selector: "app-tabs", - templateUrl: "tabs.component.html", -}) -export class TabsComponent implements OnInit { - showCurrentTab = true; - - ngOnInit() { - this.showCurrentTab = !BrowserPopupUtils.inPopout(window); - } -}