Skip to content

feat(Registration): Email verification - #2328

Open
Aaron-Detre wants to merge 16 commits into
developfrom
email-verification
Open

feat(Registration): Email verification#2328
Aaron-Detre wants to merge 16 commits into
developfrom
email-verification

Conversation

@Aaron-Detre

@Aaron-Detre Aaron-Detre commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Changes

  • After registration, emailed verification link takes you to the login page.
  • Unverified teachers are not able to log in.
  • Added various confirmation/error messages to the login page.

Test

  • Test with feat(Registration): Email verification WISE-API#335
  • Accounts created before this PR should be verified by default.
  • Depending on the verificationState, below the password input, you should see different confirmation/error messages on the login page:
    • When logging into an account that was previously verified, you shouldn't see any new messages.
    • If your account was just verified by clicking the link, you should see a confirmation that your account was verified.
    • If the verification code doesn't match a user in the database, you should see an error message telling you to try again.
    • The first time you try to log into an unverified account, you should see an error message including a link allowing you to resend the email.
      • If you then try to log into the account again without verifying, you should see an error message including a countdown to wait until you can send another email.
    • If you click to resend the email, you should see a confirmation if it was sent successfully or an error message if it couldn't be delivered (if email isn't set up in application.properties for example).

@Aaron-Detre Aaron-Detre self-assigned this Jul 21, 2026
@Aaron-Detre Aaron-Detre added the enhancement New feature of any size or improvement (UI, performance, security) label Jul 21, 2026
@qltysh

qltysh Bot commented Jul 21, 2026

Copy link
Copy Markdown

❌ 1 blocking issue (1 total)

Tool Category Rule Count
qlty Structure Function with many parameters (count = 6): constructor 1

@qltysh

qltysh Bot commented Jul 21, 2026

Copy link
Copy Markdown

Qlty


Coverage Impact

Unable to calculate total coverage change because base branch coverage was not found.

Modified Files with Diff Coverage (2)

RatingFile% DiffUncovered Line #s
New Coverage rating: C
src/app/login/login-home/login-home.component.ts81.0%48, 52, 128-131
New Coverage rating: F
src/app/services/user.service.ts100.0%
Total84.0%
🤖 Increase coverage with AI coding...
In the `email-verification` branch, add test coverage for this new code:

- `src/app/login/login-home/login-home.component.ts` -- Lines 48, 52, and 128-131

🚦 See full report on Qlty Cloud »

🛟 Help
  • Diff Coverage: Coverage for added or modified lines of code (excludes deleted files). Learn more.

  • Total Coverage: Coverage for the whole repository, calculated as the sum of all File Coverage. Learn more.

  • File Coverage: Covered Lines divided by Covered Lines plus Missed Lines. (Excludes non-executable lines including blank lines and comments.)

    • Indirect Changes: Changes to File Coverage for files that were not modified in this PR. Learn more.

@Aaron-Detre
Aaron-Detre marked this pull request as ready for review July 22, 2026 00:12
@hirokiterashima
hirokiterashima requested a review from breity July 22, 2026 16:38

@breity breity left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functionality works well. I split some of the verification messages into separate elements to simplify the i18n messages. I also cleaned up the login-home template a little.

One issue: If user clicks the link to re-send the verification email, the countdown to send another verification email starts properly. But if the user refreshes or reloads the login page and then tries to sign again, the link to send another email shows up and the countdown is reset because the component has been reloaded. Kind of an edge case, so not sure if it's worth addressing, as it would add complexity to the code. @Aaron-Detre @hirokiterashima, what do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature of any size or improvement (UI, performance, security)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants