-
-
Notifications
You must be signed in to change notification settings - Fork 10
feat(organizations): always-create workspace + suggestedJoin hint (drop onboarding limbo) #3680
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
Merged
PierreBrisorgueil
merged 9 commits into
master
from
feat/signup-always-create-suggested-join
May 19, 2026
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
6f7f0f8
feat(organizations): canonical email-domain normalization helper
PierreBrisorgueil 70ef4e1
feat(organizations): always-create workspace + suggestedJoin hint, dr…
PierreBrisorgueil 63332d6
fix(organizations): remove dead imports + harden signup test mock iso…
PierreBrisorgueil 2d91e10
fix(organizations): normalize domain on write + exact-match read via …
PierreBrisorgueil af9cf6b
refactor(organizations): drop dead extractDomain + simplify public-do…
PierreBrisorgueil 13f7b04
fix(organizations): idempotent retry-safe signup provisioning (spec C…
PierreBrisorgueil 7c275b0
refactor(organizations): dedupe signup result builder + lock email-ve…
PierreBrisorgueil 7132647
feat(auth): forward suggestedJoin through signup HTTP response (A2b)
PierreBrisorgueil 4b970e6
fix(organizations): address CodeRabbit + Copilot review findings
PierreBrisorgueil File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| /** | ||
| * Email-domain normalization helpers. | ||
| * | ||
| * Maintained constant. Not auto-refreshed (spec H2 — freshness out of scope). | ||
| */ | ||
|
|
||
| export const PUBLIC_DOMAINS = new Set([ | ||
| 'gmail.com', 'googlemail.com', 'outlook.com', 'hotmail.com', 'live.com', | ||
| 'yahoo.com', 'icloud.com', 'me.com', 'proton.me', 'protonmail.com', | ||
| 'aol.com', 'gmx.com', 'mail.com', 'yandex.com', 'zoho.com', | ||
| ]); | ||
|
|
||
| /** | ||
| * Extract and normalize the domain portion of an email address. | ||
| * @param {*} email - Raw value to parse. | ||
| * @returns {string|null} Lowercased, trimmed domain, or null on malformed input. | ||
| */ | ||
| export function normalizeEmailDomain(email) { | ||
| if (typeof email !== 'string') return null; | ||
| const at = email.indexOf('@'); | ||
| if (at === -1 || at !== email.lastIndexOf('@')) return null; | ||
| const domain = email.slice(at + 1).trim().toLowerCase(); | ||
| return domain.length > 0 && domain.includes('.') ? domain : null; | ||
| } | ||
|
|
||
| /** | ||
| * Return true when the domain belongs to a known public e-mail provider. | ||
| * @param {string} domain - Normalized or raw domain string. | ||
| * @returns {boolean} | ||
| */ | ||
| export function isPublicDomain(domain) { | ||
| return PUBLIC_DOMAINS.has(String(domain ?? '').trim().toLowerCase()); | ||
| } | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.