mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-06 07:12:12 +03:00
OpenCode Free (noAuth: true) was routed through OAuthModal which tried to call a non-existent /api/oauth/opencode/authorize endpoint, resulting in a 500 error. Detect noAuth free providers via FREE_PROVIDERS[id]?.noAuth and render a NoAuthProviderCard (lock_open + description) instead of the connections section with the "+ Add" button that triggered the broken flow.
22 lines
695 B
TypeScript
22 lines
695 B
TypeScript
"use client";
|
|
|
|
import Card from "./Card";
|
|
|
|
export default function NoAuthProviderCard() {
|
|
return (
|
|
<Card>
|
|
<div className="flex items-center gap-3">
|
|
<div className="inline-flex shrink-0 items-center justify-center w-10 h-10 rounded-full bg-green-500/10 text-green-500">
|
|
<span className="material-symbols-outlined text-[20px]">lock_open</span>
|
|
</div>
|
|
<div className="flex-1">
|
|
<p className="text-sm font-medium">No authentication required</p>
|
|
<p className="text-xs text-text-muted">
|
|
This provider is ready to use immediately — no signup or API key needed.
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</Card>
|
|
);
|
|
}
|