Skip to content

[PM-20287] Initialize login email state when email is remembered #14302

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

trmartin4
Copy link
Member

@trmartin4 trmartin4 commented Apr 15, 2025

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-20287

📔 Objective

We currently set the email state when a there is input on the email or remember me form fields. However, this doesn't work if the user has "Remember Me" selected and attempts a subsequent login without editing the email address. This never fires the email input event and so the loginEmail is never persisted to state for that login flow.

This change sets the loginEmail if an email is remembered, ensuring that the field is initialized in sync with the remembered email if one exists.

📸 Screenshots

email_state_missing.mov

⏰ Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • ❓ (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • ❌ (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

@trmartin4 trmartin4 changed the title Initialize login email state when email is remembered [PM-20287] Initialize login email state when email is remembered Apr 15, 2025
Copy link

codecov bot commented Apr 15, 2025

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 36.87%. Comparing base (a61d878) to head (ce70228).

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
libs/auth/src/angular/login/login.component.ts 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #14302      +/-   ##
==========================================
- Coverage   36.88%   36.87%   -0.01%     
==========================================
  Files        3213     3213              
  Lines       92636    92637       +1     
  Branches    16630    16630              
==========================================
- Hits        34168    34161       -7     
- Misses      56047    56055       +8     
  Partials     2421     2421              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@trmartin4 trmartin4 marked this pull request as ready for review April 15, 2025 23:16
@trmartin4 trmartin4 requested a review from a team as a code owner April 15, 2025 23:16
@trmartin4 trmartin4 requested a review from rr-bw April 15, 2025 23:16
Copy link
Contributor

Logo
Checkmarx One – Scan Summary & Details4c3e8f40-3703-49f8-a723-a6092aa3b662

Great job, no security vulnerabilities found in this Pull Request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants