Skip to content

Merge pull request #25 from Huynhthuongg/codex/fix-high-priority-bug-in-public-fallback-nv2thz Make AuthPortal aware of public mode and adjust public routes/redirects#38

Open
Huynhthuongg wants to merge 10 commits into
claude/grant-execute-permission-termuxfrom
codex/explain-codebase-structure-for-beginners-xev5l0
Open

Merge pull request #25 from Huynhthuongg/codex/fix-high-priority-bug-in-public-fallback-nv2thz Make AuthPortal aware of public mode and adjust public routes/redirects#38
Huynhthuongg wants to merge 10 commits into
claude/grant-execute-permission-termuxfrom
codex/explain-codebase-structure-for-beginners-xev5l0

Conversation

@Huynhthuongg

@Huynhthuongg Huynhthuongg commented Jun 2, 2026

Copy link
Copy Markdown
Member

Summary by cubic

Adds a public auth mode with a dedicated router and health check so the app runs without Clerk. Fixes public-mode redirects and the /pricing crash when auth env vars are missing.

  • New Features

    • Introduced auth-mode.ts with VITE_AUTH_MODE (clerk | public) and isAuthEnabled.
    • /auth portal: forwards to Clerk when enabled, or to /health-config in public mode.
    • /health-config page to validate env keys and show status.
    • Public-only router and banner when auth is disabled; redirects /pricing, /chat*, /sign-in, and /sign-up.
    • Added /mobile-dashboard, /chat-static, /termux-lab (updated), and /tools.
    • Added docs_self_healing_process.md with a self-healing checklist.
  • Bug Fixes

    • Redirected /pricing to home and /sign-in//sign-up to /auth in public mode.
    • Prevented crashes when VITE_CLERK_PUBLISHABLE_KEY is missing by falling back to public mode.
    • Resolved type errors in chat components and simplified tsconfig.json to avoid broken project refs.

Written for commit 09b90a7. Summary will update on new commits.

Review in cubic

@vercel

vercel Bot commented Jun 2, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
sanbox Ready Ready Preview, Comment Jun 2, 2026 8:57pm

@coderabbitai

coderabbitai Bot commented Jun 2, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: f621840a-40b1-4603-913b-65f70721bb52

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/explain-codebase-structure-for-beginners-xev5l0
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch codex/explain-codebase-structure-for-beginners-xev5l0
  • 🛠️ Aethon

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@kilo-code-bot

kilo-code-bot Bot commented Jun 2, 2026

Copy link
Copy Markdown

Kilo Code Review could not run — your account is out of credits.

Add credits or switch to a free model to enable reviews on this change.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

10 issues found across 12 files

Confidence score: 3/5

  • Some risk before merge: there are multiple medium-to-high severity findings (6–7/10) with strong confidence, including user-facing accessibility gaps and auth-mode edge cases.
  • Most severe impact is in artifacts/sandbox-ai/src/pages/mobile-dashboard.tsx and artifacts/sandbox-ai/src/pages/termux-lab.tsx, where missing accessible labels can block screen-reader users from operating key controls.
  • artifacts/sandbox-ai/src/config/auth-mode.ts has concrete behavior risk: whitespace-only Clerk publishable keys can be treated as valid and incorrectly enable auth, and env health output can misreport missing vars in public mode.
  • Pay close attention to artifacts/sandbox-ai/src/config/auth-mode.ts, artifacts/sandbox-ai/src/pages/mobile-dashboard.tsx, and artifacts/sandbox-ai/src/pages/termux-lab.tsx - auth-mode validation and accessibility issues could affect real user flows.

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread artifacts/sandbox-ai/src/pages/auth-portal.tsx
Comment thread artifacts/sandbox-ai/src/pages/mobile-dashboard.tsx
Comment thread artifacts/sandbox-ai/src/pages/termux-lab.tsx Outdated
Comment thread artifacts/sandbox-ai/src/config/auth-mode.ts
Comment thread artifacts/sandbox-ai/src/config/auth-mode.ts
Comment thread artifacts/sandbox-ai/src/pages/chat-static.tsx
Comment thread artifacts/sandbox-ai/src/config/auth-mode.ts
Comment thread artifacts/sandbox-ai/src/pages/mobile-dashboard.tsx
Comment thread artifacts/sandbox-ai/src/pages/termux-lab.tsx
Comment thread artifacts/sandbox-ai/src/App.tsx
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

0 issues found across 1 file (changes from recent commits).

Re-trigger cubic

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.

1 participant