supermemory/apps/web/app
MaheshtheDev db7f5c3f64 fix(web): select the correct Company Brain workspace (#1372)
## What changed

- Make `/brain` reuse the active Company Brain, switch to a single existing Company Brain, show a picker for multiple choices, or create one only when none exists.
- Wait for active-organization restoration before making that decision.
- Make Company Brain onboarding match organizations by the confirmed company domain and never offer unrelated-domain workspaces.
- Create a new Company Brain when no matching workspace exists and show an actionable workspace-limit toast when creation is blocked.
- Improve the organization picker, loading, and error states.

## Why

The previous flows could use or mutate the currently active normal organization, start research against stale Company Brain metadata, or offer unrelated Company Brain workspaces after a quota failure.

## Impact

Normal organizations are no longer silently converted. Research is scoped to the Company Brain for the confirmed domain, and users receive a clear recovery path when they reach their workspace limit.

This keeps the existing `{ domain }` research API contract; no organization-reconfiguration API is required.

## Validation

- Biome checks passed for all five changed web files
- Targeted web TypeScript diagnostics reported no errors for the changed files
- React Doctor against `origin/main`: no issues found
- `git diff --check`

No test files were added.
2026-07-28 06:14:22 +00:00
..
(app) fix(web): select the correct Company Brain workspace (#1372) 2026-07-28 06:14:22 +00:00
(auth)/login fix(web): use backend URL fallback for direct fetches (#1212) 2026-07-10 20:02:24 -07:00
api fix(web): block IPv6 literals in OG scraper SSRF guard (#1154) 2026-07-10 18:20:43 -07:00
auth Refine Codex and OpenCode OAuth integration status (#1048) 2026-06-04 15:15:20 -07:00
oauth/consent Add console logs for debugging consent page (#1129) 2026-06-16 14:46:07 -07:00
org/invite/[invitationId] feat(web): company brain — invite-accept page, space UX/visibility, org-scoped daily brief (#1112) 2026-06-22 18:12:18 +00:00
ref chore: improve the codebase with react doctor (#917) 2026-05-09 19:12:01 +00:00
slack/link feat(web): add Slack account linking confirmation (#1359) 2026-07-24 22:00:58 +00:00
upgrade-mcp chore: improve the codebase with react doctor (#917) 2026-05-09 19:12:01 +00:00
global-error.tsx fix: resolve UI accessibility, hydration, and semantic HTML issues (#520) 2025-12-07 21:31:30 -08:00
icon.png Update app favicon assets (#953) 2026-05-16 21:24:27 -07:00
layout.tsx Add web app OG image metadata (#1058) 2026-06-06 02:11:36 +00:00
manifest.ts Update app favicon assets (#953) 2026-05-16 21:24:27 -07:00
not-found.tsx feat: mobile responsive, lint formats, toast, render issue fix (#688) 2026-01-21 03:11:53 +00:00
opengraph-image.png New Version of Supermemory Consumer App 2025-08-16 18:50:10 -07:00