From e2434ff397afe70503f08d32376b7b82b5759b19 Mon Sep 17 00:00:00 2001 From: rr-bw <102181210+rr-bw@users.noreply.github.com> Date: Tue, 10 Sep 2024 16:26:54 -0700 Subject: [PATCH] create a LoginSecondaryContentComponent for AnonLayout use --- apps/desktop/src/app/app-routing.module.ts | 2 ++ apps/desktop/src/locales/en/messages.json | 3 ++ libs/auth/src/angular/index.ts | 1 + .../login-secondary-content.component.ts | 16 ++++++++++ .../src/angular/login/login.component.html | 32 +++++++++++++------ .../auth/src/angular/login/login.component.ts | 2 ++ 6 files changed, 47 insertions(+), 9 deletions(-) create mode 100644 libs/auth/src/angular/login/login-secondary-content.component.ts diff --git a/apps/desktop/src/app/app-routing.module.ts b/apps/desktop/src/app/app-routing.module.ts index 6c7932c9cab..b5c06357cf0 100644 --- a/apps/desktop/src/app/app-routing.module.ts +++ b/apps/desktop/src/app/app-routing.module.ts @@ -15,6 +15,7 @@ import { AnonLayoutWrapperComponent, AnonLayoutWrapperData, LoginComponentV2, + LoginSecondaryContentComponent, RegistrationFinishComponent, RegistrationStartComponent, RegistrationStartSecondaryComponent, @@ -130,6 +131,7 @@ const routes: Routes = [ }, children: [ { path: "", component: LoginComponentV2 }, + { path: "", component: LoginSecondaryContentComponent, outlet: "secondary" }, { path: "", component: EnvironmentSelectorComponent, diff --git a/apps/desktop/src/locales/en/messages.json b/apps/desktop/src/locales/en/messages.json index 43774a88b52..c0c44b4f0e0 100644 --- a/apps/desktop/src/locales/en/messages.json +++ b/apps/desktop/src/locales/en/messages.json @@ -499,6 +499,9 @@ "createAccount": { "message": "Create account" }, + "newToBitwarden": { + "message": "New to Bitwarden?" + }, "setAStrongPassword": { "message": "Set a strong password" }, diff --git a/libs/auth/src/angular/index.ts b/libs/auth/src/angular/index.ts index 569e7bb59f3..3ba0b8ef71b 100644 --- a/libs/auth/src/angular/index.ts +++ b/libs/auth/src/angular/index.ts @@ -20,6 +20,7 @@ export * from "./input-password/password-input-result"; // login export * from "./login/login.component"; +export * from "./login/login-secondary-content.component"; export * from "./login/login.service"; export * from "./login/default-login.service"; diff --git a/libs/auth/src/angular/login/login-secondary-content.component.ts b/libs/auth/src/angular/login/login-secondary-content.component.ts new file mode 100644 index 00000000000..f4d32533c6e --- /dev/null +++ b/libs/auth/src/angular/login/login-secondary-content.component.ts @@ -0,0 +1,16 @@ +import { Component } from "@angular/core"; +import { RouterModule } from "@angular/router"; + +import { JslibModule } from "@bitwarden/angular/jslib.module"; + +@Component({ + standalone: true, + imports: [JslibModule, RouterModule], + template: ` +