nggrouter 0.1.21 → 0.1.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/.next-cli-build/BUILD_ID +1 -1
- package/app/.next-cli-build/app-path-routes-manifest.json +14 -12
- package/app/.next-cli-build/build-manifest.json +4 -4
- package/app/.next-cli-build/prerender-manifest.json +49 -21
- package/app/.next-cli-build/react-loadable-manifest.json +2 -2
- package/app/.next-cli-build/routes-manifest.json +12 -0
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/addons/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/addons/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/addons/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/arena/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/arena/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/arena/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/checkin/page.js +1 -0
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/checkin/page.js.nft.json +1 -0
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/checkin/page_client-reference-manifest.js +1 -0
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +5 -5
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/system-status/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/system-status/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/system-status/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error/page.js +2 -2
- package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error.html +1 -1
- package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found/page.js +1 -1
- package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_not-found.html +1 -1
- package/app/.next-cli-build/server/app/_not-found.rsc +6 -6
- package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/api/addons/list/route.js +1 -1
- package/app/.next-cli-build/server/app/api/addons/list/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/addons/update/route.js +1 -1
- package/app/.next-cli-build/server/app/api/addons/update/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/reset-password/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/status/route.js +2 -2
- package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/checkin/route.js +1 -0
- package/app/.next-cli-build/server/app/api/checkin/route.js.nft.json +1 -0
- package/app/.next-cli-build/server/app/api/checkin/route_client-reference-manifest.js +1 -0
- package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +5 -5
- package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +3 -3
- package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js +22 -2
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +3 -3
- package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/presets/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/health/route.js +1 -1
- package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/init/route.js +1 -1
- package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
- package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/locale/route.js +1 -1
- package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +1 -1
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +2 -2
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js +2 -2
- package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
- package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/bulk-proxy/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/bulk-proxy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/health/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/install/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/start/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/status/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/shutdown/route.js +1 -1
- package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/system/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/system/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tags/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +2 -2
- package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/load/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/save/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +2 -2
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/error-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/error-logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/stream/route.js +2 -2
- package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +2 -2
- package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/callback/page.js +1 -1
- package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/callback.html +1 -1
- package/app/.next-cli-build/server/app/callback.rsc +6 -6
- package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/arena.html +2 -2
- package/app/.next-cli-build/server/app/dashboard/arena.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/arena.segments/!KGRhc2hib2FyZCk/dashboard/arena/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/arena.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/arena.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/checkin.html +1 -0
- package/app/.next-cli-build/server/app/dashboard/checkin.meta +44 -0
- package/app/.next-cli-build/server/app/dashboard/checkin.rsc +45 -0
- package/app/.next-cli-build/server/app/dashboard/checkin.segments/!KGRhc2hib2FyZCk/dashboard/checkin/__PAGE__.segment.rsc +47 -0
- package/app/.next-cli-build/server/app/dashboard/checkin.segments/_full.segment.rsc +45 -0
- package/app/.next-cli-build/server/app/dashboard/checkin.segments/_tree.segment.rsc +11 -0
- package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/quota.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/system-status.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/system-status.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/system-status.segments/!KGRhc2hib2FyZCk/dashboard/system-status/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/system-status.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/system-status.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/token-saver.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.rsc +9 -9
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +9 -9
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +9 -9
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard.html +1 -1
- package/app/.next-cli-build/server/app/dashboard.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/favicon.ico/route.js +1 -1
- package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/index.html +1 -1
- package/app/.next-cli-build/server/app/index.rsc +6 -6
- package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/landing/page.js +1 -1
- package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/landing.html +1 -1
- package/app/.next-cli-build/server/app/landing.rsc +6 -6
- package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/login/page.js +1 -1
- package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/login.html +1 -1
- package/app/.next-cli-build/server/app/login.rsc +6 -6
- package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/manifest.webmanifest/route.js +2 -2
- package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/page.js +1 -1
- package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app-paths-manifest.json +14 -12
- package/app/.next-cli-build/server/chunks/1132.js +1 -1
- package/app/.next-cli-build/server/chunks/1306.js +1 -1
- package/app/.next-cli-build/server/chunks/1350.js +1 -1
- package/app/.next-cli-build/server/chunks/1757.js +22 -2
- package/app/.next-cli-build/server/chunks/1782.js +51 -0
- package/app/.next-cli-build/server/chunks/2236.js +1 -0
- package/app/.next-cli-build/server/chunks/238.js +1 -1
- package/app/.next-cli-build/server/chunks/24.js +1 -1
- package/app/.next-cli-build/server/chunks/2559.js +1 -1
- package/app/.next-cli-build/server/chunks/2925.js +1 -1
- package/app/.next-cli-build/server/chunks/2970.js +2 -2
- package/app/.next-cli-build/server/chunks/3192.js +3 -3
- package/app/.next-cli-build/server/chunks/{1851.js → 3360.js} +1 -1
- package/app/.next-cli-build/server/chunks/3943.js +1 -1
- package/app/.next-cli-build/server/chunks/3966.js +1 -1
- package/app/.next-cli-build/server/chunks/412.js +2 -2
- package/app/.next-cli-build/server/chunks/4123.js +1 -1
- package/app/.next-cli-build/server/chunks/4334.js +1 -0
- package/app/.next-cli-build/server/chunks/4386.js +1 -1
- package/app/.next-cli-build/server/chunks/444.js +1 -0
- package/app/.next-cli-build/server/chunks/4732.js +2 -0
- package/app/.next-cli-build/server/chunks/4775.js +1 -1
- package/app/.next-cli-build/server/chunks/4803.js +9 -0
- package/app/.next-cli-build/server/chunks/4827.js +1 -1
- package/app/.next-cli-build/server/chunks/{3277.js → 5274.js} +1 -1
- package/app/.next-cli-build/server/chunks/5299.js +11 -4
- package/app/.next-cli-build/server/chunks/5330.js +11 -7
- package/app/.next-cli-build/server/chunks/5360.js +2 -0
- package/app/.next-cli-build/server/chunks/539.js +1 -0
- package/app/.next-cli-build/server/chunks/5390.js +1 -1
- package/app/.next-cli-build/server/chunks/5615.js +1 -1
- package/app/.next-cli-build/server/chunks/5800.js +9 -0
- package/app/.next-cli-build/server/chunks/6103.js +1 -0
- package/app/.next-cli-build/server/chunks/6252.js +9 -0
- package/app/.next-cli-build/server/chunks/6267.js +1 -0
- package/app/.next-cli-build/server/chunks/6763.js +1 -1
- package/app/.next-cli-build/server/chunks/6877.js +1 -1
- package/app/.next-cli-build/server/chunks/6922.js +1 -1
- package/app/.next-cli-build/server/chunks/7121.js +1 -1
- package/app/.next-cli-build/server/chunks/7141.js +1 -0
- package/app/.next-cli-build/server/chunks/7211.js +1 -1
- package/app/.next-cli-build/server/chunks/7247.js +1 -1
- package/app/.next-cli-build/server/chunks/7373.js +2 -2
- package/app/.next-cli-build/server/chunks/7716.js +1 -1
- package/app/.next-cli-build/server/chunks/7774.js +13 -13
- package/app/.next-cli-build/server/chunks/7828.js +1 -1
- package/app/.next-cli-build/server/chunks/7911.js +1 -1
- package/app/.next-cli-build/server/chunks/7965.js +2 -2
- package/app/.next-cli-build/server/chunks/8062.js +9 -0
- package/app/.next-cli-build/server/chunks/8228.js +9 -0
- package/app/.next-cli-build/server/chunks/8238.js +1 -1
- package/app/.next-cli-build/server/chunks/8432.js +1 -0
- package/app/.next-cli-build/server/chunks/8469.js +9 -0
- package/app/.next-cli-build/server/chunks/8499.js +4 -54
- package/app/.next-cli-build/server/chunks/8895.js +13 -8
- package/app/.next-cli-build/server/chunks/8910.js +1 -1
- package/app/.next-cli-build/server/chunks/8920.js +1 -1
- package/app/.next-cli-build/server/chunks/915.js +1 -1
- package/app/.next-cli-build/server/instrumentation.js +2 -1
- package/app/.next-cli-build/server/instrumentation.js.nft.json +1 -1
- package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
- package/app/.next-cli-build/server/middleware-react-loadable-manifest.js +1 -1
- package/app/.next-cli-build/server/middleware.js +6 -6
- package/app/.next-cli-build/server/middleware.js.nft.json +1 -1
- package/app/.next-cli-build/server/pages/404.html +1 -1
- package/app/.next-cli-build/server/pages/500.html +1 -1
- package/app/.next-cli-build/server/prefetch-hints.json +24 -0
- package/app/.next-cli-build/server/preview-props.json +3 -3
- package/app/.next-cli-build/server/server-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/server-reference-manifest.json +1 -1
- package/app/.next-cli-build/static/chunks/2985-0edfac861dcab249.js +1 -0
- package/app/.next-cli-build/static/chunks/{3794-39f2d5bb0d40336b.js → 3794-04350b0fcecd82e5.js} +1 -1
- package/app/.next-cli-build/static/chunks/5497-2ad88f6a28d488f2.js +7 -0
- package/app/.next-cli-build/static/chunks/{620-eb4703fefb0a8224.js → 620-664195c468db3646.js} +1 -1
- package/app/.next-cli-build/static/chunks/{761-ee86f920b407fe8e.js → 761-4b979ab522d3ca71.js} +11 -4
- package/app/.next-cli-build/static/chunks/8105-8f6822fa963b7f8e.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/checkin/page-42825bd41f565908.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/combos/{page-cfb01ebc3a0d2693.js → page-96c2c298c3e438e7.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/error-log/page-41255a729606a996.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-b9356341fb501ec9.js +27 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-5fb01979338d3c54.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/translator/{page-e2e50aefcea07c9b.js → page-002702d0d2cd95ab.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/usage/page-c2ab03a59a42ed24.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/layout-bac485d168267329.js +1 -0
- package/app/.next-cli-build/static/chunks/app/_global-error/page-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/addons/list/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/addons/update/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/login/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/logout/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/status/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/checkin/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-profiles/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/devin-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-profiles/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/health/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/init/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/keys/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/locale/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/alias/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/availability/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/custom/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/auto-import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/import/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pricing/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/overrides/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/bulk-proxy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/client/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/netlify-deploy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/database/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/shutdown/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/system/status/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tags/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/load/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/save/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/send/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/claude-reset/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/error-logs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/history/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/search/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/update/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/app/page-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/{main-00cd8c01f6f6e461.js → main-ca004678a0b6b16d.js} +1 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-9080ff61af91a815.js +1 -0
- package/app/.next-cli-build/static/chunks/{webpack-c056b5babdc7a81f.js → webpack-d22e163354099479.js} +1 -1
- package/app/.next-cli-build/static/css/5ce1d74323ea1a81.css +1 -0
- package/app/.next-cli-build/static/o6uo4o14Oyh19p0YQDVpi/_buildManifest.js +1 -0
- package/app/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +94 -1589
- package/app/node_modules/@aws-sdk/core/package.json +2 -2
- package/app/node_modules/@aws-sdk/credential-provider-cognito-identity/package.json +3 -3
- package/app/node_modules/@aws-sdk/credential-provider-env/package.json +3 -3
- package/app/node_modules/@aws-sdk/credential-provider-http/package.json +3 -3
- package/app/node_modules/@aws-sdk/credential-provider-ini/package.json +10 -10
- package/app/node_modules/@aws-sdk/credential-provider-login/package.json +4 -4
- package/app/node_modules/@aws-sdk/credential-provider-node/package.json +8 -8
- package/app/node_modules/@aws-sdk/credential-provider-process/package.json +3 -3
- package/app/node_modules/@aws-sdk/credential-provider-sso/package.json +5 -5
- package/app/node_modules/@aws-sdk/credential-provider-web-identity/package.json +4 -4
- package/app/node_modules/@aws-sdk/credential-providers/package.json +13 -13
- package/app/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +1 -1
- package/app/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +1 -1
- package/app/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +1 -1
- package/app/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +1 -1
- package/app/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +1 -1
- package/app/node_modules/@aws-sdk/nested-clients/package.json +3 -3
- package/app/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +37 -19
- package/app/node_modules/@aws-sdk/token-providers/package.json +4 -4
- package/app/node_modules/@next/env/package.json +1 -1
- package/app/node_modules/baseline-browser-mapping/dist/index.cjs +1 -1
- package/app/node_modules/baseline-browser-mapping/package.json +4 -4
- package/app/node_modules/next/dist/build/swc/index.js +1 -1
- package/app/node_modules/next/dist/build/webpack-config.js +3 -3
- package/app/node_modules/next/dist/compiled/next-server/app-page-experimental.runtime.prod.js +1 -1
- package/app/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +1 -1
- package/app/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +1 -1
- package/app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js +1 -1
- package/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js +1 -1
- package/app/node_modules/next/dist/lib/patch-incorrect-lockfile.js +3 -3
- package/app/node_modules/next/dist/server/app-render/async-local-storage.js +1 -1
- package/app/node_modules/next/dist/server/config.js +1 -1
- package/app/node_modules/next/dist/server/dev/hot-reloader-turbopack.js +2 -2
- package/app/node_modules/next/dist/server/dev/hot-reloader-webpack.js +1 -1
- package/app/node_modules/next/dist/server/lib/app-info-log.js +1 -1
- package/app/node_modules/next/dist/server/lib/generate-agent-files.js +3 -3
- package/app/node_modules/next/dist/server/lib/router-server.js +1 -1
- package/app/node_modules/next/dist/server/lib/start-server.js +1 -1
- package/app/node_modules/next/dist/server/lib/trace/tracer.js +1 -1
- package/app/node_modules/next/dist/server/typescript/rules/config.js +2 -2
- package/app/node_modules/next/dist/telemetry/anonymous-meta.js +1 -1
- package/app/node_modules/next/dist/telemetry/events/swc-load-failure.js +1 -1
- package/app/node_modules/next/dist/telemetry/events/version.js +2 -2
- package/app/node_modules/next/package.json +10 -10
- package/app/node_modules/sql.js/dist/sql-wasm.js +92 -92
- package/app/node_modules/sql.js/package.json +1 -1
- package/app/package.json +2 -2
- package/app/public/fonts/material-symbols-outlined.woff2 +0 -0
- package/app/src/mitm/server.js +25 -25
- package/package.json +1 -1
- package/src/cli/menus/providers.js +4 -0
- package/app/.next-cli-build/server/chunks/2708.js +0 -1
- package/app/.next-cli-build/server/chunks/3726.js +0 -1
- package/app/.next-cli-build/server/chunks/700.js +0 -1
- package/app/.next-cli-build/server/chunks/7066.js +0 -1
- package/app/.next-cli-build/server/chunks/8251.js +0 -1
- package/app/.next-cli-build/server/chunks/8402.js +0 -1
- package/app/.next-cli-build/server/chunks/8716.js +0 -1
- package/app/.next-cli-build/static/-A8yVxeQUhunMwVeISlwZ/_buildManifest.js +0 -1
- package/app/.next-cli-build/static/chunks/5497-bdb464e8bf997966.js +0 -7
- package/app/.next-cli-build/static/chunks/6808-e6340e2d4cfe01fe.js +0 -1
- package/app/.next-cli-build/static/chunks/8105-5dd3fc022d984a17.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/error-log/page-b29648e60668531b.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-deb38e87524ff14e.js +0 -27
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-06427d5637ff9cb2.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/usage/page-07ce5bf168a701aa.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/layout-8d03e04e4f7e0bcc.js +0 -1
- package/app/.next-cli-build/static/chunks/app/_global-error/page-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/addons/list/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/addons/update/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/login/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/logout/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/status/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-profiles/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/devin-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-profiles/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/health/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/init/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/keys/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/locale/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/alias/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/availability/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/custom/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/auto-import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/import/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pricing/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/overrides/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/bulk-proxy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/client/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/netlify-deploy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/database/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/shutdown/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/system/status/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tags/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/load/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/save/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/send/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/claude-reset/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/error-logs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/history/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/search/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/update/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/app/page-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-7d5b3595c7187b08.js +0 -1
- package/app/.next-cli-build/static/css/a97374177c39fad4.css +0 -1
- /package/app/.next-cli-build/static/{-A8yVxeQUhunMwVeISlwZ → o6uo4o14Oyh19p0YQDVpi}/_ssgManifest.js +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4455],{1934:(e,t,s)=>{"use strict";s.d(t,{v:()=>l});var a=s(12115);let r=e=>{let t,s=new Set,a=(e,a)=>{let r="function"==typeof e?e(t):e;if(!Object.is(r,t)){let e=t;t=(null!=a?a:"object"!=typeof r||null===r)?r:Object.assign({},t,r),s.forEach(s=>s(t,e))}},r=()=>t,n={setState:a,getState:r,getInitialState:()=>l,subscribe:e=>(s.add(e),()=>s.delete(e))},l=t=e(a,r,n);return n},n=e=>{let t=e?r(e):r,s=e=>(function(e,t=e=>e){let s=a.useSyncExternalStore(e.subscribe,a.useCallback(()=>t(e.getState()),[e,t]),a.useCallback(()=>t(e.getInitialState()),[e,t]));return a.useDebugValue(s),s})(t,e);return Object.assign(s,t),s},l=e=>e?n(e):n},4797:(e,t,s)=>{Promise.resolve().then(s.bind(s,92717))},29499:(e,t,s)=>{"use strict";s.d(t,{A:()=>l});var a=s(95155),r=s(12115),n=s(31474);function l({isOpen:e,onClose:t,title:s,children:i,width:o="md",className:d}){let c={sm:"w-full max-w-[400px]",md:"w-full max-w-[500px]",lg:"w-full max-w-[600px]",xl:"w-full max-w-[800px]",full:"w-full"};return((0,r.useEffect)(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e]),(0,r.useEffect)(()=>{let s=s=>{"Escape"===s.key&&e&&t()};return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[e,t]),e)?(0,a.jsxs)("div",{className:"fixed inset-0 z-50",children:[(0,a.jsx)("div",{className:"absolute inset-0 bg-black/50 backdrop-blur-[2px] fade-in cursor-pointer",onClick:t,"aria-hidden":"true"}),(0,a.jsxs)("div",{className:(0,n.cn)("absolute right-0 top-0 h-full bg-surface flex flex-col","shadow-[var(--shadow-elev)]","slide-in-right","border-l border-border-subtle",c[o]||c.md,d),children:[(0,a.jsxs)("div",{className:"flex items-center justify-between p-6 border-b border-border-subtle flex-shrink-0",children:[(0,a.jsx)("div",{className:"flex items-center gap-3",children:s&&(0,a.jsx)("h2",{className:"text-lg font-semibold text-text-main",children:s})}),(0,a.jsx)("button",{type:"button",onClick:t,className:"p-1.5 rounded-[10px] text-text-muted hover:bg-surface-2 hover:text-text-main transition-colors",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[20px]",children:"close"})})]}),(0,a.jsx)("div",{className:"flex-1 overflow-y-auto p-6 custom-scrollbar",children:i})]})]}):null}},31474:(e,t,s)=>{"use strict";function a(...e){return e.filter(Boolean).join(" ").replace(/\s+/g," ").trim()}s.d(t,{cn:()=>a})},31590:(e,t,s)=>{"use strict";function a(e){let t,s,a=(t=e?.ttft,s=e?.total,"number"!=typeof t||!Number.isFinite(t)||"number"!=typeof s||!Number.isFinite(s)||t<=0||t>=s?null:t);return null===a?"—":`${a}ms`}function r(e){let t=e?.total;return"number"==typeof t&&Number.isFinite(t)?`${t}ms`:"—"}s.d(t,{Ej:()=>r,_g:()=>a})},50378:(e,t,s)=>{"use strict";s.d(t,{A:()=>l});var a=s(95155),r=s(31474),n=s(92542);function l({currentPage:e,pageSize:t,totalItems:s,onPageChange:i,onPageSizeChange:o,className:d}){let c=Math.ceil(s/t),m=s>0?(e-1)*t+1:0,x=Math.min(e*t,s),u=(()=>{let t=[],s=Math.max(1,e-2),a=Math.min(c,s+5-1);a-s+1<5&&(s=Math.max(1,a-5+1));for(let e=s;e<=a;e++)t.push(e);return t})();return(0,a.jsxs)("div",{className:(0,r.cn)("flex flex-col sm:flex-row items-center justify-between gap-4 py-4 px-2",d),children:[s>0&&(0,a.jsxs)("div",{className:"text-sm text-text-muted",children:["Showing ",(0,a.jsx)("span",{className:"font-medium text-text-main",children:m})," to"," ",(0,a.jsx)("span",{className:"font-medium text-text-main",children:x})," of"," ",(0,a.jsx)("span",{className:"font-medium text-text-main",children:s})," results"]}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center justify-center gap-2 sm:gap-4",children:[o&&(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-sm text-text-muted",children:"Rows:"}),(0,a.jsx)("select",{value:t,onChange:e=>o(Number(e.target.value)),className:(0,r.cn)("h-9 rounded-lg border border-black/10 dark:border-white/10 bg-surface","text-sm text-text-main focus:outline-none focus:ring-2 focus:ring-primary/20","cursor-pointer"),style:{colorScheme:"auto"},children:[10,20,50].map(e=>(0,a.jsx)("option",{value:e,children:e},e))})]}),c>1&&(0,a.jsxs)("div",{className:"flex items-center gap-1",children:[(0,a.jsx)(n.default,{variant:"outline",size:"sm",onClick:()=>i(e-1),disabled:1===e,className:"w-9 px-0",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"chevron_left"})}),u[0]>1&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(n.default,{variant:"ghost",size:"sm",onClick:()=>i(1),className:"w-9 px-0 hidden sm:inline-flex",children:"1"}),u[0]>2&&(0,a.jsx)("span",{className:"text-text-muted px-1 hidden sm:inline",children:"..."})]}),u.map(t=>(0,a.jsx)(n.default,{variant:e===t?"primary":"ghost",size:"sm",onClick:()=>i(t),className:(0,r.cn)("w-9 px-0",e===t?"inline-flex":"hidden sm:inline-flex"),children:t},t)),u[u.length-1]<c&&(0,a.jsxs)(a.Fragment,{children:[u[u.length-1]<c-1&&(0,a.jsx)("span",{className:"text-text-muted px-1 hidden sm:inline",children:"..."}),(0,a.jsx)(n.default,{variant:"ghost",size:"sm",onClick:()=>i(c),className:"w-9 px-0 hidden sm:inline-flex",children:c})]}),(0,a.jsx)(n.default,{variant:"outline",size:"sm",onClick:()=>i(e+1),disabled:e===c,className:"w-9 px-0",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"chevron_right"})})]})]})]})}},54642:e=>{var t;"u">typeof __nccwpck_require__&&(__nccwpck_require__.ab="//"),(t={}).endianness=function(){return"LE"},t.hostname=function(){return"u">typeof location?location.hostname:""},t.loadavg=function(){return[]},t.uptime=function(){return 0},t.freemem=function(){return Number.MAX_VALUE},t.totalmem=function(){return Number.MAX_VALUE},t.cpus=function(){return[]},t.type=function(){return"Browser"},t.release=function(){return"u">typeof navigator?navigator.appVersion:""},t.networkInterfaces=t.getNetworkInterfaces=function(){return{}},t.arch=function(){return"javascript"},t.platform=function(){return"browser"},t.tmpdir=t.tmpDir=function(){return"/tmp"},t.EOL="\n",t.homedir=function(){return"/"},e.exports=t},65921:(e,t,s)=>{"use strict";s.d(t,{i:()=>n});var a=s(1934);let r=0,n=(0,a.v)((e,t)=>({notifications:[],addNotification:s=>{let a=++r,n={id:a,type:s.type||"info",message:s.message,title:s.title||null,duration:s.duration??5e3,dismissible:s.dismissible??!0,createdAt:Date.now()};return e(e=>({notifications:[...e.notifications,n]})),n.duration>0&&setTimeout(()=>t().removeNotification(a),n.duration),a},removeNotification:t=>{e(e=>({notifications:e.notifications.filter(e=>e.id!==t)}))},clearAll:()=>e({notifications:[]}),success:(e,s)=>t().addNotification({type:"success",message:e,title:s}),error:(e,s)=>t().addNotification({type:"error",message:e,title:s,duration:8e3}),warning:(e,s)=>t().addNotification({type:"warning",message:e,title:s}),info:(e,s)=>t().addNotification({type:"info",message:e,title:s})}))},81127:(e,t,s)=>{"use strict";s.d(t,{ConfirmModal:()=>d,default:()=>o});var a=s(95155),r=s(12115),n=s(31474),l=s(92542),i=s(97677);function o({isOpen:e,onClose:t,title:s,children:l,footer:d,size:c="md",closeOnOverlay:m=!0,showTrafficLights:x=!0,className:u}){return((0,r.useEffect)(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e]),(0,r.useEffect)(()=>{let s=s=>{"Escape"===s.key&&e&&t()};return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[e,t]),e)?(0,a.jsxs)("div",{className:"fixed inset-0 z-50 flex items-center justify-center p-4",children:[(0,a.jsx)("div",{className:"absolute inset-0 bg-black/50 backdrop-blur-[2px] fade-in",onClick:m?t:void 0}),(0,a.jsxs)("div",{className:(0,n.cn)("relative w-full bg-surface","border border-border-subtle","rounded-[14px] shadow-[var(--shadow-elev)]","fade-in",{sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl",full:"max-w-4xl"}[c],u),children:[(s||x)&&(0,a.jsxs)("div",{className:"flex items-center justify-between p-2 border-b border-border-subtle",children:[(0,a.jsxs)("div",{className:"flex items-center",children:[x&&(0,a.jsxs)("div",{className:"hidden md:flex items-center gap-2 mr-4 ml-2",children:[(0,a.jsx)(i.default,{text:"Close",position:"top",color:"#FF5F56",children:(0,a.jsx)("button",{onClick:t,"aria-label":"Close",title:"Close",className:"w-4 h-4 rounded-full bg-[#FF5F56] hover:brightness-90 transition-all cursor-pointer flex items-center justify-center group/dot",children:(0,a.jsx)("span",{className:"text-[9px] font-bold text-white opacity-0 group-hover/dot:opacity-100 transition-opacity leading-none",children:"✕"})})}),(0,a.jsx)("div",{className:"w-4 h-4 rounded-full bg-[#3a3a3a]/20 dark:bg-white/15 cursor-not-allowed"}),(0,a.jsx)("div",{className:"w-4 h-4 rounded-full bg-[#3a3a3a]/20 dark:bg-white/15 cursor-not-allowed"})]}),s&&(0,a.jsx)("h2",{className:"text-lg font-semibold text-text-main",children:s})]}),(0,a.jsx)("button",{onClick:t,"aria-label":"Close",className:"md:hidden p-1.5 rounded-[10px] text-text-muted hover:bg-surface-2 hover:text-text-main transition-colors",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[20px]",children:"close"})})]}),(0,a.jsx)("div",{className:"p-6 max-h-[calc(85vh-100px)] overflow-y-auto custom-scrollbar",children:l}),d&&(0,a.jsx)("div",{className:"flex items-center justify-end gap-3 p-6 border-t border-border-subtle",children:d})]})]}):null}function d({isOpen:e,onClose:t,onConfirm:s,title:r="Confirm",message:n,confirmText:i="Confirm",cancelText:c="Cancel",variant:m="danger",loading:x=!1}){return(0,a.jsx)(o,{isOpen:e,onClose:t,title:r,size:"sm",footer:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(l.default,{variant:"ghost",onClick:t,disabled:x,children:c}),(0,a.jsx)(l.default,{variant:m,onClick:s,loading:x,children:i})]}),children:(0,a.jsx)("p",{className:"text-text-muted",children:n})})}},84588:(e,t,s)=>{"use strict";s.d(t,{default:()=>n});var a=s(95155),r=s(31474);function n({children:e,title:t,subtitle:s,icon:l,action:i,padding:o="md",hover:d=!1,elev:c=!1,className:m,...x}){return(0,a.jsxs)("div",{className:(0,r.cn)("bg-surface border border-border-subtle",c?"rounded-[14px] shadow-[var(--shadow-elev)]":"rounded-[14px] shadow-[var(--shadow-soft)]",d&&"hover:shadow-[var(--shadow-warm)] hover:border-brand-500/30 transition-all cursor-pointer",{none:"",xs:"p-3",sm:"p-4",md:"p-6",lg:"p-8"}[o],m),...x,children:[(t||i)&&(0,a.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[l&&(0,a.jsx)("div",{className:"p-2 rounded-[10px] bg-bg text-text-muted",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[20px]",children:l})}),(0,a.jsxs)("div",{children:[t&&(0,a.jsx)("h3",{className:"text-text-main font-semibold",children:t}),s&&(0,a.jsx)("p",{className:"text-sm text-text-muted",children:s})]})]}),i]}),e]})}n.Section=function({children:e,className:t,...s}){return(0,a.jsx)("div",{className:(0,r.cn)("p-4 rounded-[10px]","bg-bg border border-border-subtle",t),...s,children:e})},n.Row=function({children:e,className:t,...s}){return(0,a.jsx)("div",{className:(0,r.cn)("p-3 -mx-3 px-3 transition-colors","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50",t),...s,children:e})},n.ListItem=function({children:e,actions:t,className:s,...n}){return(0,a.jsxs)("div",{className:(0,r.cn)("group flex items-center justify-between p-3 -mx-3 px-3","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50 transition-colors",s),...n,children:[(0,a.jsx)("div",{className:"flex-1 min-w-0",children:e}),t&&(0,a.jsx)("div",{className:"flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:t})]})}},92542:(e,t,s)=>{"use strict";s.d(t,{default:()=>i});var a=s(95155),r=s(31474);let n={primary:"bg-brand-500 hover:bg-brand-600 text-white shadow-sm disabled:bg-surface-3 disabled:text-text-disabled",secondary:"bg-surface-2 hover:bg-surface-3 text-text-main border border-border disabled:text-text-disabled",outline:"border border-border text-text-main hover:bg-surface-2 hover:border-brand-500/40 disabled:text-text-disabled",ghost:"text-text-muted hover:bg-surface-2 hover:text-text-main disabled:text-text-disabled",danger:"bg-red-500 hover:bg-red-600 text-white shadow-sm disabled:bg-surface-3 disabled:text-text-disabled",success:"bg-green-600 hover:bg-green-700 text-white shadow-sm disabled:bg-surface-3 disabled:text-text-disabled"},l={sm:"h-7 px-3 text-xs rounded-[8px]",md:"h-9 px-4 text-sm rounded-[10px]",lg:"h-11 px-6 text-sm rounded-[10px]",stretch:"h-auto px-4 text-sm rounded-[10px]"};function i({children:e,variant:t="primary",size:s="md",icon:o,iconRight:d,disabled:c=!1,loading:m=!1,fullWidth:x=!1,className:u,...p}){return(0,a.jsxs)("button",{className:(0,r.cn)("inline-flex items-center justify-center gap-2 font-semibold whitespace-nowrap transition-all duration-150 ease-out cursor-pointer","active:scale-[0.97] disabled:cursor-not-allowed disabled:active:scale-100",n[t],l[s],x&&"w-full",u),disabled:c||m,...p,children:[m?(0,a.jsx)("span",{className:"material-symbols-outlined animate-spin text-[18px]",children:"progress_activity"}):o?(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:o}):null,e,d&&!m&&(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:d})]})}},92717:(e,t,s)=>{"use strict";s.d(t,{default:()=>h});var a=s(95155),r=s(12115),n=s(84588),l=s(92542),i=s(29499),o=s(50378),d=s(81127),c=s(31474),m=s(88105),x=s(65921),u=s(31590);function p(e){if(!e)return null;if("string"!=typeof e)try{e=JSON.stringify(e)}catch{e=String(e)}return e.length>240?`${e.slice(0,237)}...`:e}function h(){let[e,t]=(0,r.useState)([]),[s,h]=(0,r.useState)({page:1,pageSize:20,totalItems:0,totalPages:0}),[b,g]=(0,r.useState)(!1),[j,v]=(0,r.useState)(null),[N,w]=(0,r.useState)(!1),[y,k]=(0,r.useState)({provider:"",model:"",connectionId:"",comboName:"",statusCode:""}),[C,S]=(0,r.useState)(!0),E=(0,r.useCallback)(async()=>{g(!0);try{let e=new URLSearchParams({page:String(s.page),pageSize:String(s.pageSize)});for(let[t,s]of Object.entries(y))s&&e.append(t,s);let a=await fetch(`/api/usage/error-logs?${e}`),r=await a.json();t(r.details||[]),h(e=>({...e,...r.pagination}))}catch(e){console.error("Failed to fetch error logs:",e)}finally{g(!1)}},[s.page,s.pageSize,y]);(0,r.useEffect)(()=>{let e=setTimeout(E,0);return()=>clearTimeout(e)},[E]),(0,r.useEffect)(()=>{if(!C)return;let e=setInterval(E,4e3);return()=>clearInterval(e)},[C,E]);let[_,I]=(0,r.useState)(!1),[A,F]=(0,r.useState)(null),[R,z]=(0,r.useState)(!1),L=(0,x.i)(),T=async()=>{I(!0);try{let e=await fetch("/api/usage/error-logs",{method:"DELETE"}),s=await e.json();if(!e.ok)throw Error(s.error||"Failed to clear");t([]),h(e=>({...e,page:1,totalItems:0,totalPages:0})),v(null),w(!1),F(s.deleted),z(!1),L.success(s.deleted>0?`Cleared ${s.deleted} error logs`:"No error logs to clear"),E()}catch(e){console.error("Failed to clear error logs:",e),L.error(e.message||"Failed to clear error logs")}finally{I(!1)}};return(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-6",children:[(0,a.jsx)(n.default,{padding:"md",children:(0,a.jsxs)("div",{className:"flex flex-col gap-4 lg:flex-row lg:items-end lg:justify-between",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2 xl:grid-cols-5",children:[(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium text-text-main",children:"Provider"}),(0,a.jsx)("input",{value:y.provider,onChange:e=>{k(t=>({...t,provider:e.target.value})),h(e=>({...e,page:1}))},placeholder:"All providers",className:(0,c.cn)("h-9 rounded-lg border border-black/10 bg-surface px-3 text-sm text-text-main dark:border-white/10","placeholder:text-text-muted focus:outline-none focus:ring-2 focus:ring-primary/20")})]}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium text-text-main",children:"Model"}),(0,a.jsx)("input",{value:y.model,onChange:e=>{k(t=>({...t,model:e.target.value})),h(e=>({...e,page:1}))},placeholder:"All models",className:(0,c.cn)("h-9 rounded-lg border border-black/10 bg-surface px-3 text-sm text-text-main dark:border-white/10","placeholder:text-text-muted focus:outline-none focus:ring-2 focus:ring-primary/20")})]}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium text-text-main",children:"Combo"}),(0,a.jsx)("input",{value:y.comboName,onChange:e=>{k(t=>({...t,comboName:e.target.value})),h(e=>({...e,page:1}))},placeholder:"All combos",className:(0,c.cn)("h-9 rounded-lg border border-black/10 bg-surface px-3 text-sm text-text-main dark:border-white/10","placeholder:text-text-muted focus:outline-none focus:ring-2 focus:ring-primary/20")})]}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium text-text-main",children:"Status"}),(0,a.jsx)("input",{value:y.statusCode,onChange:e=>{k(t=>({...t,statusCode:e.target.value})),h(e=>({...e,page:1}))},placeholder:"e.g. 502",className:(0,c.cn)("h-9 rounded-lg border border-black/10 bg-surface px-3 font-mono text-sm text-text-main dark:border-white/10","placeholder:text-text-muted focus:outline-none focus:ring-2 focus:ring-primary/20")})]}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium text-text-main",children:"Account"}),(0,a.jsx)("input",{value:y.connectionId,onChange:e=>{k(t=>({...t,connectionId:e.target.value})),h(e=>({...e,page:1}))},placeholder:"All accounts",className:(0,c.cn)("h-9 rounded-lg border border-black/10 bg-surface px-3 font-mono text-sm text-text-main dark:border-white/10","placeholder:text-text-muted focus:outline-none focus:ring-2 focus:ring-primary/20")})]})]}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)(l.default,{variant:"ghost",onClick:()=>{S(e=>!e)},children:C?"Pause live refresh":"Resume live refresh"}),(0,a.jsx)(l.default,{variant:"outline",onClick:()=>{k({provider:"",model:"",connectionId:"",comboName:"",statusCode:""}),h(e=>({...e,page:1}))},disabled:!Object.values(y).some(e=>e),className:"whitespace-nowrap",children:"Clear filters"}),(0,a.jsx)(l.default,{variant:"outline",size:"sm",icon:"delete_sweep",onClick:()=>z(!0),disabled:_||0===s.totalItems,className:"border-red-500/30 text-red-500 hover:bg-red-500/10 hover:text-red-600 whitespace-nowrap",children:_?"Clearing…":"Clear all logs"})]})]})}),(0,a.jsxs)(n.default,{padding:"none",children:[(0,a.jsx)("div",{className:"overflow-x-auto",children:(0,a.jsxs)("table",{className:"min-w-[860px] w-full",children:[(0,a.jsx)("thead",{children:(0,a.jsxs)("tr",{className:"border-b border-black/5 dark:border-white/5",children:[(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Timestamp"}),(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Endpoint / Combo"}),(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Model"}),(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Provider"}),(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Account"}),(0,a.jsx)("th",{className:"text-center p-4 text-sm font-semibold text-text-main",children:"Status"}),(0,a.jsx)("th",{className:"text-left p-4 text-sm font-semibold text-text-main",children:"Error"}),(0,a.jsx)("th",{className:"text-center p-4 text-sm font-semibold text-text-main",children:"Action"})]})}),(0,a.jsx)("tbody",{children:b&&0===e.length?(0,a.jsx)("tr",{children:(0,a.jsx)("td",{colSpan:"8",className:"p-8 text-center text-text-muted",children:(0,a.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[(0,a.jsx)("span",{className:"material-symbols-outlined animate-spin text-[20px]",children:"progress_activity"}),"Loading error logs..."]})})}):0===e.length?(0,a.jsx)("tr",{children:(0,a.jsx)("td",{colSpan:"8",className:"p-8 text-center text-text-muted",children:"No error logs match the current filters."})}):e.map(e=>((e=>{if(!e)return;let t=[];return e.fallback&&t.push({label:"Fallback",variant:"danger"}),e.retryAfterHuman&&t.push({label:`Retry in ${e.retryAfterHuman}`,variant:"warning"})})(e.meta),(0,a.jsxs)("tr",{className:"border-b border-black/5 dark:border-white/5 last:border-b-0 hover:bg-black/[0.02] dark:hover:bg-white/[0.02] transition-colors",children:[(0,a.jsx)("td",{className:"whitespace-nowrap p-4 text-sm text-text-main",children:new Date(e.timestamp).toLocaleString()}),(0,a.jsx)("td",{className:"max-w-[220px] truncate p-4 text-sm text-text-main",children:(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsx)("span",{className:"font-mono text-xs text-text-muted",children:e.endpoint||"/v1/chat/completions"}),e.comboName?(0,a.jsxs)("span",{className:"inline-flex w-fit items-center rounded-md border border-black/10 bg-amber-500/10 px-2 py-0.5 text-xs font-medium text-amber-700 dark:border-white/10 dark:text-amber-300",children:["Combo: ",e.comboName]}):null]})}),(0,a.jsx)("td",{className:"max-w-[180px] truncate p-4 text-sm font-mono text-text-main",children:e.model}),(0,a.jsx)("td",{className:"max-w-[160px] truncate p-4 text-sm text-text-main",children:m.Q2[e.provider]?.name||e.provider||"Unknown provider"}),(0,a.jsx)("td",{className:"max-w-[180px] truncate p-4 font-mono text-sm text-text-main",children:e.connectionId?(0,a.jsxs)("div",{className:"flex flex-col gap-0.5",children:[(0,a.jsx)("span",{className:"truncate",children:e.connectionName||e.connectionId}),e.connectionName?(0,a.jsx)("span",{className:"truncate text-xs text-text-muted",children:e.connectionId}):null]}):"—"}),(0,a.jsx)("td",{className:"whitespace-nowrap p-4 text-center text-sm",children:(0,a.jsx)("span",{className:(0,c.cn)("inline-flex min-w-[3.5rem] justify-center rounded-md border px-2 py-1 font-mono text-xs",e.statusCode&&/4|5/.test(String(e.statusCode))?"border-red-500/20 bg-red-500/10 text-red-700 dark:text-red-300":"border-black/10 bg-black/5 text-text-main dark:border-white/10 dark:bg-white/5"),children:e.statusCode||"ERR"})}),(0,a.jsx)("td",{className:"max-w-[320px] truncate p-4 text-sm text-text-main",children:p(e.errorMessage)}),(0,a.jsx)("td",{className:"p-4 text-center",children:(0,a.jsx)(l.default,{variant:"outline",size:"sm",onClick:()=>{v(e),w(!0)},children:"Inspect"})})]},e.id)))})]})}),!b&&e.length>0&&(0,a.jsx)("div",{className:"border-t border-black/5 dark:border-white/5",children:(0,a.jsx)(o.A,{currentPage:s.page,pageSize:s.pageSize,totalItems:s.totalItems,onPageChange:e=>h(t=>({...t,page:e})),onPageSizeChange:e=>h(t=>({...t,pageSize:e,page:1}))})})]}),(0,a.jsx)(i.A,{isOpen:N,onClose:()=>w(!1),title:"Error Log Details",width:"lg",children:j&&(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"grid min-w-0 grid-cols-1 gap-4 text-sm sm:grid-cols-2",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Timestamp:"})," ",(0,a.jsx)("span",{className:"text-text-main",children:new Date(j.timestamp).toLocaleString()})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Endpoint:"})," ",(0,a.jsx)("span",{className:"break-all font-mono text-text-main",children:j.endpoint||"/v1/chat/completions"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Provider:"})," ",(0,a.jsx)("span",{className:"text-text-main",children:m.Q2[j.provider]?.name||j.provider||"Unknown provider"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Model:"})," ",(0,a.jsx)("span",{className:"break-all font-mono text-text-main",children:j.model})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Account:"})," ",j.connectionName?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"break-all font-mono text-text-main",children:j.connectionName})," ",(0,a.jsxs)("span",{className:"break-all font-mono text-xs text-text-muted",children:["(",j.connectionId,")"]})]}):(0,a.jsx)("span",{className:"break-all font-mono text-text-main",children:j.connectionId||"—"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Combo:"})," ",(0,a.jsx)("span",{className:"text-text-main",children:j.comboName||"—"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Status:"})," ",(0,a.jsx)("span",{className:(0,c.cn)("font-mono font-medium",j.statusCode&&/4|5/.test(String(j.statusCode))?"text-red-600":"text-text-main"),children:j.statusCode||"ERR"})]}),(0,a.jsxs)("div",{className:"sm:col-span-2",children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Error:"})," ",(0,a.jsx)("span",{className:"text-red-700 dark:text-red-300",children:p(j.errorMessage)})]}),j.meta?.latency?.total!=null?(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Latency:"})," ",(0,a.jsxs)("span",{className:"font-mono text-text-main",children:["TTFT ",(0,u._g)(j.meta.latency)," / Total ",(0,u.Ej)(j.meta.latency)]})]}):null,j.meta?.tokens?(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Tokens:"})," ",(0,a.jsx)("span",{className:"font-mono text-text-main",children:`in ${j.meta.tokens.prompt_tokens||j.meta.tokens.input_tokens||0} / out ${j.meta.tokens.completion_tokens||j.meta.tokens.output_tokens||0}`})]}):null,j.meta?.retryAfterHuman?(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-text-muted",children:"Retry after:"})," ",(0,a.jsx)("span",{className:"font-mono text-text-main",children:j.meta.retryAfterHuman})]}):null,(0,a.jsx)("div",{className:"sm:col-span-2 flex gap-2",children:j.meta?.fallback?(0,a.jsx)("span",{className:"inline-flex rounded-md border border-amber-500/20 bg-amber-500/10 px-2 py-1 text-xs font-medium text-amber-700 dark:text-amber-300",children:"Fallback event"}):null})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[j.request&&(0,a.jsx)(f,{title:"Client Request (Input)",defaultOpen:!0,icon:"input",data:j.request}),j.providerRequest&&(0,a.jsx)(f,{title:"Provider Request (Translated)",icon:"translate",data:j.providerRequest}),j.providerResponse&&(0,a.jsx)(f,{title:"Provider Response (Raw)",icon:"data_object",data:j.providerResponse})]})]})}),(0,a.jsx)(d.ConfirmModal,{isOpen:R,onClose:()=>!_&&z(!1),onConfirm:T,title:"Clear all error logs",message:`This permanently deletes all ${s.totalItems} error log${1===s.totalItems?"":"s"} and cannot be undone. Request details and usage history are not affected.`,confirmText:"Clear all logs",cancelText:"Cancel",variant:"danger",loading:_})]})}function f({title:e,children:t,defaultOpen:s=!1,icon:n=null,data:l}){let[i,o]=(0,r.useState)(s);return(0,a.jsxs)("div",{className:"rounded-lg border border-black/5 dark:border-white/5",children:[(0,a.jsxs)("button",{type:"button",onClick:()=>o(e=>!e),className:"flex w-full items-center justify-between p-3 hover:bg-black/[0.04] dark:hover:bg-white/[0.04]",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[n&&(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px] text-text-muted",children:n}),(0,a.jsx)("span",{className:"text-sm font-semibold text-text-main",children:e})]}),(0,a.jsx)("span",{className:(0,c.cn)("material-symbols-outlined text-text-muted transition-transform",i?"rotate-90":""),children:"chevron_right"})]}),i&&(0,a.jsx)("div",{className:"space-y-0 border-t border-black/5 p-4 dark:border-white/5",children:t??(0,a.jsx)("pre",{className:"max-h-[280px] max-w-full overflow-auto rounded-lg border border-black/5 bg-black/5 p-3 font-mono text-xs dark:border-white/5 dark:bg-white/5",children:JSON.stringify(l,null,2)})})]})}},97677:(e,t,s)=>{"use strict";s.d(t,{default:()=>r});var a=s(95155);function r({text:e,children:t,position:s="top",color:n}){let l=n?"":"bg-gray-900";return(0,a.jsxs)("div",{className:"relative inline-flex group/tt",children:[t,(0,a.jsx)("div",{className:`pointer-events-none absolute ${{top:"bottom-full left-1/2 -translate-x-1/2 mb-1.5",bottom:"top-full left-1/2 -translate-x-1/2 mt-1.5",left:"right-full top-1/2 -translate-y-1/2 mr-1.5",right:"left-full top-1/2 -translate-y-1/2 ml-1.5"}[s]} z-50 w-max max-w-56 rounded px-2 py-1 text-[11px] leading-snug ${l} text-white opacity-0 group-hover/tt:opacity-100 transition-opacity duration-150 whitespace-normal`,style:n?{backgroundColor:n}:{},children:e})]})}}},e=>{e.O(0,[8105,8441,3794,7358],()=>e(e.s=4797)),_N_E=e.O()}]);
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2134],{56828:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>Y});var a=s(95155),i=s(12115),l=s(73321),r=s(98500),n=s.n(r),o=s(5772),d=s(8247),c=s(35497),m=s(88105),p=s(28777),u=s(67899),x=s(62630);s(67468);var h=s(13097);let f=["none","low","medium","high"],g=["none","thinking"],y=["none","low","medium","high","xhigh","max"],b={openai:["none","minimal","low","medium","high","xhigh"],"claude-adaptive":y,"claude-budget":y,"gemini-level":["minimal","low","medium","high"],"gemini-budget":f,zai:g,qwen:f,kimi:["none","low","medium","high","max"],deepseek:["none","high","max"],commandcode:["none","low","medium","high","xhigh","max"],minimax:g,hunyuan:f,step:f},v=["none","minimal","low","medium","high","xhigh","max"],j=["none","low","medium","high","max"],w=[{pattern:"*claude*4.6*",levels:j},{pattern:"*claude*4-6*",levels:j},{provider:"codex",pattern:"*gpt-6*",levels:v},{provider:"codex",pattern:"*gpt-5.6-sol*",levels:[...v,"ultra"]},{provider:"codex",pattern:"*gpt-5.6-terra*",levels:[...v,"ultra"]},{provider:"codex",pattern:"*gpt-5.6-luna*",levels:v},{pattern:"*codex*",levels:["low","medium","high","xhigh"]},{pattern:"*mimo*v2.6*",levels:["none","low","medium","high","xhigh"]},{pattern:"*mimo*v2.5-pro*",levels:["none","low","medium","high","xhigh"]},{provider:"codebuddy-cn",pattern:"deepseek-v4-pro",levels:["low","high","xhigh"]},{provider:"codebuddy-cn",pattern:"deepseek-v4.1-flash",levels:["low","high","max"]},{provider:"codebuddy-cn",pattern:"deepseek-v4*",levels:["low","high","xhigh"]},{pattern:"*deepseek-v4.*",levels:["none","low","medium","high","xhigh","max"]},{provider:"codebuddy-cn",pattern:"glm-5.3",levels:["low","high","max"]},{provider:"codebuddy-cn",pattern:"glm-5.3-flash",levels:["low","high","max"]},{provider:"codebuddy-cn",pattern:"glm-5.2",levels:["high","xhigh"]},{provider:"codebuddy-cn",pattern:"kimi-k2.8-preview",levels:["low","medium","high"]},{provider:"codebuddy-cn",pattern:"hy3",levels:["low","high"]},{provider:"codebuddy-cn",pattern:"hy4-preview",levels:["high"]},{provider:"codebuddy-intl",pattern:"deepseek-v4*",levels:["low","high","xhigh"]},{provider:"minimax-code",pattern:"MiniMax-M3.1*",levels:["low","medium","high","xhigh","max"]},{provider:"minimax-code",pattern:"MiniMax-M3",levels:["none","high"]},{provider:"minimax-code-global",pattern:"MiniMax-M3.1*",levels:["low","medium","high","xhigh","max"]},{provider:"minimax-code-global",pattern:"MiniMax-M3",levels:["none","high"]}];function k(e,t){if("kiro"===e&&null===function(e){if("string"!=typeof e)return null;let t=e.toLowerCase().replace(/-/g,".");if(/(?:^|[/.])gpt[/.]5[/.]6(?:[/.]|$)/.test(t))return"reasoning";if(!t.includes("claude"))return null;let s=function(e){if("string"!=typeof e)return null;let t=e.toLowerCase().replace(/-/g,".").match(/(?:^|[/.])claude(?:[/.][a-z]+)*[/.](\d+)(?:[/.](\d+))?(?:[/.]|$)/);return t?{major:Number(t[1]),minor:void 0===t[2]?null:Number(t[2])}:null}(e);if(!s)return null;let{major:a,minor:i}=s;return a<4||4===a&&(null===i||i<=5||null!==i&&i>=1e3)?null:"output_config"}(t))return null;let s=(0,u.nl)(e,t);if(!s.reasoning)return null;let a=String(t||"").replace(/\([^()]+\)\s*$/,""),i="codex"===e?(0,h.SM)("cx").find(e=>e.id===a)?.thinkingLevels:null,l=w.find(s=>(!s.provider||s.provider===e)&&(0,x.gH)(s.pattern,t)),r=i||l?.levels||b[s.thinkingFormat]||f;return!1===s.thinkingCanDisable&&(r=r.filter(e=>"none"!==e)),r}var N=s(11059),C=s(929),S=s(73006);let A=new Map;async function T(e){if(!e?.url||!e?.type)return[];let t=A.get(e.url);if(t&&Date.now()<t.expiresAt)return t.data;try{let t=new URLSearchParams({url:e.url,type:e.type}),s=await fetch(`/api/providers/suggested-models?${t}`);if(!s.ok)return[];let a=(await s.json()).data??[];return A.set(e.url,{data:a,expiresAt:Date.now()+6e5}),a}catch{return[]}}var $=s(81231),O=s(14051),I=s.n(O);function P({model:e,fullModel:t,alias:s,copied:i,onCopy:l,testStatus:r,isCustom:n,isFree:o,onDeleteAlias:d,onTest:m,isTesting:p,onDisable:u,caps:x,thinkingSuffix:h}){let f=h?`${t}(${h})`:t,g="ok"===r?"#22c55e":"error"===r?"#ef4444":void 0;return(0,a.jsx)("div",{className:`group w-full sm:w-auto min-w-0 max-w-full rounded-lg border px-3 py-2 ${"ok"===r?"border-green-500/40":"error"===r?"border-red-500/40":"border-border"} hover:bg-sidebar/50`,children:(0,a.jsxs)("div",{className:"flex min-w-0 items-start gap-2 sm:items-center",children:[(0,a.jsx)("span",{className:"material-symbols-outlined shrink-0 text-base mt-0.5 sm:mt-0",style:g?{color:g}:void 0,children:"ok"===r?"check_circle":"error"===r?"cancel":"smart_toy"}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-1 flex-col gap-1",children:[(0,a.jsx)("code",{className:"w-fit max-w-full break-all rounded bg-sidebar px-1.5 py-0.5 font-mono text-xs text-text-muted sm:max-w-[360px] sm:truncate",children:f}),(0,a.jsxs)("span",{className:"flex min-w-0 items-center text-[9px] gap-1 pl-1",children:[e.name&&(0,a.jsx)("span",{className:"break-all sm:truncate text-[9px] italic text-text-muted/70",children:e.name}),(0,a.jsx)(c.nh,{caps:x,colorOverride:"text-text-muted/70",size:12})]})]}),(0,a.jsxs)("div",{className:"flex shrink-0 items-center gap-0.5 sm:gap-1",children:[m&&(0,a.jsxs)("div",{className:"relative shrink-0 group/btn",children:[(0,a.jsx)("button",{onClick:m,disabled:p,className:`rounded p-0.5 text-text-muted transition-opacity hover:bg-sidebar hover:text-primary ${p?"opacity-100":"opacity-100 sm:opacity-0 sm:group-hover:opacity-100"}`,children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",style:p?{animation:"spin 1s linear infinite"}:void 0,children:p?"progress_activity":"science"})}),(0,a.jsx)("span",{className:"pointer-events-none absolute mt-1 top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:p?"Testing...":"Test"})]}),(0,a.jsxs)("div",{className:"relative shrink-0 group/btn",children:[(0,a.jsx)("button",{onClick:()=>l(f,`model-${e.id}`),className:"rounded p-0.5 text-text-muted hover:bg-sidebar hover:text-primary",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:i===`model-${e.id}`?"check":"content_copy"})}),(0,a.jsx)("span",{className:"pointer-events-none absolute mt-1 top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:i===`model-${e.id}`?"Copied!":"Copy"})]}),n?(0,a.jsx)("button",{onClick:d,className:"rounded p-0.5 text-text-muted opacity-100 transition-opacity hover:bg-red-500/10 hover:text-red-500 sm:opacity-0 sm:group-hover:opacity-100",title:"Remove custom model",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"close"})}):u?(0,a.jsx)("button",{onClick:u,className:"rounded p-0.5 text-text-muted opacity-100 transition-opacity hover:bg-red-500/10 hover:text-red-500 sm:opacity-0 sm:group-hover:opacity-100",title:"Disable this model",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"close"})}):null]})]})})}function E({modelId:e,fullModel:t,caps:s,copied:i,onCopy:l,onDeleteAlias:r,onTest:n,testStatus:o,isTesting:d}){let c="ok"===o?"#22c55e":"error"===o?"#ef4444":void 0;return(0,a.jsxs)("div",{className:`flex items-center gap-3 p-3 rounded-lg border ${"ok"===o?"border-green-500/40":"error"===o?"border-red-500/40":"border-border"} hover:bg-sidebar/50`,children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-base text-text-muted",style:c?{color:c}:void 0,children:"ok"===o?"check_circle":"error"===o?"cancel":"smart_toy"}),(0,a.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,a.jsx)("p",{className:"text-sm font-medium truncate",children:e}),(0,a.jsxs)("div",{className:"flex items-center gap-1 mt-1",children:[(0,a.jsx)("code",{className:"text-xs text-text-muted font-mono bg-sidebar px-1.5 py-0.5 rounded",children:t}),(0,a.jsxs)("div",{className:"relative group/btn",children:[(0,a.jsx)("button",{onClick:()=>l(t,`model-${e}`),className:"p-0.5 hover:bg-sidebar rounded text-text-muted hover:text-primary",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:i===`model-${e}`?"check":"content_copy"})}),(0,a.jsx)("span",{className:"pointer-events-none absolute top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:i===`model-${e}`?"Copied!":"Copy"})]}),n&&(0,a.jsxs)("div",{className:"relative group/btn",children:[(0,a.jsx)("button",{onClick:n,disabled:d,className:"p-0.5 hover:bg-sidebar rounded text-text-muted hover:text-primary transition-colors",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",style:d?{animation:"spin 1s linear infinite"}:void 0,children:d?"progress_activity":"science"})}),(0,a.jsx)("span",{className:"pointer-events-none absolute top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:d?"Testing...":"Test"})]})]}),(s?.contextWindow||s?.maxOutput)&&(0,a.jsxs)("p",{className:"mt-1 text-[10px] text-text-muted",children:[s.contextWindow?`${s.contextWindow.toLocaleString()} context`:"",s.contextWindow&&s.maxOutput?" \xb7 ":"",s.maxOutput?`${s.maxOutput.toLocaleString()} max output`:""]})]}),(0,a.jsx)("button",{onClick:r,className:"p-1 hover:bg-red-50 rounded text-red-500",title:"Remove model",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"delete"})})]})}function D({providerStorageAlias:e,providerDisplayAlias:t,modelAliases:s,customModels:l,copied:r,onCopy:n,onDeleteAlias:o,onAddCustomModel:d,onDeleteCustomModel:m,connections:p,isAnthropic:u}){let[x,h]=(0,i.useState)(""),[f,g]=(0,i.useState)(""),[y,b]=(0,i.useState)(""),[v,j]=(0,i.useState)(!1),[w,k]=(0,i.useState)(!1),[N,C]=(0,i.useState)(()=>new Set),[S,A]=(0,i.useState)({}),T=async t=>{if(!N.has(t)){C(e=>new Set(e).add(t));try{let s=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${e}/${t}`})}),a=await s.json();A(e=>({...e,[t]:a.ok?"ok":"error"}))}catch{A(e=>({...e,[t]:"error"}))}finally{C(e=>{let s=new Set(e);return s.delete(t),s})}}},O=(0,$.R)({customModels:l,modelAliases:s,providerAlias:e,type:"llm"}),I=async()=>{if(!x.trim()||v)return;let e=x.trim();if(O.some(t=>t.id===e))return void alert("Model already exists for this provider.");j(!0);try{await d(e,{...f?{contextWindow:Number(f)}:{},...y?{maxOutput:Number(y)}:{}}),h(""),g(""),b("")}catch(e){console.log("Error adding model:",e)}finally{j(!1)}},P=async()=>{if(w)return;let e=p.find(e=>!1!==e.isActive);if(e){k(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||"Failed to import models");let a=s.models||[];if(0===a.length)return void alert("No models returned from /models.");let i=0;for(let e of a){let t=e.id||e.name||e.model;t&&(O.some(e=>e.id===t)||(await d(t,e.caps),i+=1))}0===i&&alert("No new models were added.")}catch(e){console.log("Error importing models:",e)}finally{k(!1)}}},R=p.some(e=>!1!==e.isActive);return(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsxs)("p",{className:"text-sm text-text-muted",children:["Add ",u?"Anthropic":"OpenAI","-compatible models manually or import them from the /models endpoint."]}),(0,a.jsxs)("div",{className:"flex items-end gap-2 flex-wrap",children:[(0,a.jsxs)("div",{className:"flex-1 min-w-[240px]",children:[(0,a.jsx)("label",{htmlFor:"new-compatible-model-input",className:"text-xs text-text-muted mb-1 block",children:"Model ID"}),(0,a.jsx)("input",{id:"new-compatible-model-input",type:"text",value:x,onChange:e=>h(e.target.value),onKeyDown:e=>"Enter"===e.key&&I(),placeholder:u?"claude-3-opus-20240229":"gpt-4o",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]}),(0,a.jsx)(c.$n,{size:"sm",icon:"add",onClick:I,disabled:!x.trim()||v,children:v?"Adding...":"Add"}),(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"download",onClick:P,disabled:!R||w,children:w?"Importing...":"Import from /models"})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"compatible-model-context-window",className:"text-xs text-text-muted mb-1 block",children:"Context window"}),(0,a.jsx)("input",{id:"compatible-model-context-window",type:"number",min:"1",step:"1",value:f,onChange:e=>g(e.target.value),placeholder:"Optional, in tokens",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"compatible-model-max-output",className:"text-xs text-text-muted mb-1 block",children:"Maximum output"}),(0,a.jsx)("input",{id:"compatible-model-max-output",type:"number",min:"1",step:"1",value:y,onChange:e=>b(e.target.value),placeholder:"Optional, in tokens",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]})]}),!R&&(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Add a connection to enable importing models."}),O.length>0&&(0,a.jsx)("div",{className:"flex flex-col gap-3",children:O.map(({id:s,alias:i,source:l,caps:d})=>(0,a.jsx)(E,{modelId:s,fullModel:`${t}/${s}`,caps:d,copied:r,onCopy:n,onDeleteAlias:()=>"custom"===l?m(s):o(i),onTest:p.length>0?()=>T(s):void 0,testStatus:S[s],isTesting:N.has(s)},`${l}-${e}/${s}`))})]})}P.propTypes={model:I().shape({id:I().string.isRequired}).isRequired,fullModel:I().string.isRequired,alias:I().string,copied:I().string,onCopy:I().func.isRequired,testStatus:I().oneOf(["ok","error"]),isCustom:I().bool,isFree:I().bool,onDeleteAlias:I().func,onTest:I().func,isTesting:I().bool,onDisable:I().func,caps:I().object,thinkingSuffix:I().string},I().string.isRequired,I().string.isRequired,I().string,I().func.isRequired,I().func.isRequired,I().func,I().oneOf(["ok","error"]),I().bool,I().string.isRequired,I().object.isRequired,I().arrayOf(I().object),I().string,I().func.isRequired,I().func.isRequired,I().func.isRequired,I().func.isRequired,D.propTypes={providerStorageAlias:I().string.isRequired,providerDisplayAlias:I().string.isRequired,modelAliases:I().object.isRequired,customModels:I().arrayOf(I().object),copied:I().string,onCopy:I().func.isRequired,onDeleteAlias:I().func.isRequired,onAddCustomModel:I().func.isRequired,onDeleteCustomModel:I().func.isRequired,connections:I().arrayOf(I().shape({id:I().string,isActive:I().bool})).isRequired,isAnthropic:I().bool};var R=s(70217);function z({until:e}){let[t,s]=(0,i.useState)("");return((0,i.useEffect)(()=>{let t=()=>{let t=new Date(e).getTime()-Date.now();if(t<=0)return void s("");let a=Math.floor(t/1e3);if(a<60)s(`${a}s`);else if(a<3600)s(`${Math.floor(a/60)}m ${a%60}s`);else{let e=Math.floor(a/3600),t=Math.floor(a%3600/60);s(`${e}h ${t}m`)}};t();let a=setInterval(t,1e3);return()=>clearInterval(a)},[e]),t)?(0,a.jsxs)("span",{className:"text-xs text-orange-500 font-mono",children:["⏱ ",t]}):null}function q({connection:e,proxyPools:t,isOAuth:s,isFirst:l,isLast:r,onMoveUp:n,onMoveDown:o,onToggleActive:d,onUpdateProxy:m,onEdit:p,onDelete:u,oneByOneStatus:x=null,autoPing:h=null}){let[f,g]=(0,i.useState)(!1),[y,b]=(0,i.useState)(!1),v=(0,i.useRef)(null),j=new Map((t||[]).map(e=>[e.id,e])),w=e.providerSpecificData?.proxyPoolId||null,k=w?j.get(w):null,N=e.providerSpecificData?.connectionProxyEnabled===!0&&!!e.providerSpecificData?.connectionProxyUrl,C=!!w||N,S=k?`Pool: ${k.name}`:w?`Pool: ${w} (inactive/missing)`:N?`Legacy: ${e.providerSpecificData?.connectionProxyUrl}`:"",A=h?.provider==="codex"?"Auto-starts the next 5h Codex window after reset by sending a tiny gpt-5.5 request. Consumes a small amount of quota.":"When your 5h quota runs out, auto-sends a request the moment it resets so a new window starts right away.",T="";if(k?.proxyUrl||e.providerSpecificData?.connectionProxyUrl){let t=k?.proxyUrl||e.providerSpecificData?.connectionProxyUrl;try{let e=new URL(t);T=`${e.protocol}//${e.hostname}${e.port?`:${e.port}`:""}`}catch{T=t}}let $=k?.noProxy||e.providerSpecificData?.connectionNoProxy||"",O="default";k?.isActive===!0?O="success":(w||N)&&(O="error"),(0,i.useEffect)(()=>{if(!f)return;let e=e=>{v.current&&!v.current.contains(e.target)&&g(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[f]);let I=async e=>{b(!0);try{await m("__none__"===e?null:e)}finally{b(!1),g(!1)}},P=e.authType||(s?"oauth":"apikey"),E="oauth"===P,D="cookie"===P,_=e.name?.trim()||e.email?.trim()||e.displayName?.trim()||(E?"OAuth Account":D?"Cookie Account":"API Key"),U=e.name?.trim()&&e.email?.trim()&&e.name.trim()!==e.email.trim()?e.email.trim():e.name?.trim()&&e.displayName?.trim()&&e.name.trim()!==e.displayName.trim()?e.displayName.trim():null,[M,K]=(0,i.useState)(!1),F=Object.entries(e).filter(([e])=>e.startsWith("modelLock_")).map(([,e])=>e).filter(e=>!!e).sort()[0]||null;(0,i.useEffect)(()=>{let t=()=>{K(!!Object.entries(e).filter(([e])=>e.startsWith("modelLock_")).map(([,e])=>e).filter(e=>e&&new Date(e).getTime()>Date.now()).sort()[0])};t();let s=F?setInterval(t,1e3):null;return()=>{s&&clearInterval(s)}},[F]);let J="unavailable"!==e.testStatus||M?e.testStatus:"active",L=()=>x?"queued"===x.state?"queued":"testing"===x.state?"testing":"success"===x.state?"success":"failed"===x.state?x.error?`failed: ${x.error}`:"failed":null:null;return(0,a.jsxs)("div",{className:`group flex min-w-0 flex-col gap-3 rounded-lg p-2 transition-colors hover:bg-black/[0.02] dark:hover:bg-white/[0.02] sm:flex-row sm:items-center sm:justify-between ${!1===e.isActive?"opacity-60":""}`,children:[(0,a.jsxs)("div",{className:"flex min-w-0 flex-1 items-start gap-2 sm:items-center sm:gap-3",children:[(0,a.jsxs)("div",{className:"flex shrink-0 flex-col",children:[(0,a.jsx)("button",{onClick:n,disabled:l,className:`p-0.5 rounded ${l?"text-text-muted/30 cursor-not-allowed":"hover:bg-sidebar text-text-muted hover:text-primary"}`,children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"keyboard_arrow_up"})}),(0,a.jsx)("button",{onClick:o,disabled:r,className:`p-0.5 rounded ${r?"text-text-muted/30 cursor-not-allowed":"hover:bg-sidebar text-text-muted hover:text-primary"}`,children:(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"keyboard_arrow_down"})})]}),(0,a.jsx)("span",{className:"material-symbols-outlined shrink-0 text-base text-text-muted",children:D?"cookie":E?"lock":"key"}),(0,a.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,a.jsx)("p",{className:"text-sm font-medium truncate",children:_}),U&&(0,a.jsx)("p",{className:"text-xs text-text-muted truncate",children:U}),(0,a.jsxs)("div",{className:"mt-1 flex min-w-0 flex-wrap items-center gap-1.5 sm:gap-2",children:[(0,a.jsx)(c.Ex,{variant:(0,R.g)(e.isActive,J),size:"sm",dot:!0,children:!1===e.isActive?"disabled":J||"Unknown"}),(0,a.jsx)(c.Ex,{variant:"default",size:"sm",children:E?"OAuth":D?"Cookie":"API Key"}),C&&(0,a.jsx)(c.Ex,{variant:O,size:"sm",children:"Proxy"}),M&&!1!==e.isActive&&(0,a.jsx)(z,{until:F}),e.lastError&&!1!==e.isActive&&(0,a.jsx)("span",{className:"max-w-full truncate text-xs text-red-500 sm:max-w-[300px]",title:e.lastError,children:e.lastError}),(0,a.jsxs)("span",{className:"text-xs text-text-muted",children:["#",e.priority]}),e.globalPriority&&(0,a.jsxs)("span",{className:"text-xs text-text-muted",children:["Auto: ",e.globalPriority]}),L()&&(0,a.jsx)(c.Ex,{variant:x?"success"===x.state?"success":"failed"===x.state?"error":"testing"===x.state?"primary":"default":"default",size:"sm",children:L()})]}),C&&(0,a.jsxs)("div",{className:"mt-1 flex items-center gap-2 flex-wrap",children:[(0,a.jsx)("span",{className:"max-w-full truncate text-[11px] text-text-muted sm:max-w-[420px]",title:S,children:S}),T&&(0,a.jsx)("code",{className:"max-w-full truncate rounded bg-black/5 px-1 py-0.5 font-mono text-[10px] text-text-muted dark:bg-white/5 sm:max-w-[260px]",children:T}),$&&(0,a.jsxs)("span",{className:"max-w-full truncate text-[11px] text-text-muted sm:max-w-[320px]",title:$,children:["no_proxy: ",$]})]})]})]}),(0,a.jsxs)("div",{className:"flex w-full items-center justify-between gap-2 sm:w-auto sm:justify-end",children:[(0,a.jsxs)("div",{className:"grid flex-1 grid-cols-3 gap-1 sm:flex sm:flex-none",children:[(t||[]).length>0&&(0,a.jsxs)("div",{className:"relative",ref:v,children:[(0,a.jsxs)("button",{onClick:()=>g(e=>!e),className:`flex w-full flex-col items-center rounded px-2 py-1 transition-colors hover:bg-black/5 dark:hover:bg-white/5 ${C?"text-primary":"text-text-muted hover:text-primary"}`,disabled:y,children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:y?"progress_activity":"lan"}),(0,a.jsx)("span",{className:"text-[10px] leading-tight",children:"Proxy"})]}),f&&(0,a.jsxs)("div",{className:"absolute right-0 top-full z-50 mt-1 max-w-[78vw] min-w-[160px] rounded-lg border border-border bg-bg py-1 shadow-lg",children:[(0,a.jsx)("button",{onClick:()=>I("__none__"),className:`w-full text-left px-3 py-1.5 text-sm hover:bg-black/5 dark:hover:bg-white/5 ${!w?"text-primary font-medium":"text-text-main"}`,children:"None"}),(t||[]).map(e=>(0,a.jsx)("button",{onClick:()=>I(e.id),className:`w-full text-left px-3 py-1.5 text-sm hover:bg-black/5 dark:hover:bg-white/5 ${w===e.id?"text-primary font-medium":"text-text-main"}`,children:e.name},e.id))]})]}),h&&(0,a.jsx)(c.m_,{text:A,children:(0,a.jsxs)("button",{onClick:()=>h.onToggle(!h.on),className:`flex w-full flex-col items-center rounded px-2 py-1 transition-colors hover:bg-black/5 dark:hover:bg-white/5 ${h.on?"text-primary":"text-text-muted hover:text-primary"}`,children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"bolt"}),(0,a.jsx)("span",{className:"text-[10px] leading-tight",children:"Auto-ping"})]})}),(0,a.jsxs)("button",{onClick:p,className:"flex flex-col items-center rounded px-2 py-1 text-text-muted hover:bg-black/5 hover:text-primary dark:hover:bg-white/5",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"edit"}),(0,a.jsx)("span",{className:"text-[10px] leading-tight",children:"Edit"})]}),(0,a.jsxs)("button",{onClick:u,className:"flex flex-col items-center rounded px-2 py-1 text-red-500 hover:bg-red-500/10",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"delete"}),(0,a.jsx)("span",{className:"text-[10px] leading-tight",children:"Delete"})]})]}),(0,a.jsx)(c.lM,{size:"sm",checked:e.isActive??!0,onChange:d,title:e.isActive??!0?"Disable connection":"Enable connection"})]})]})}z.propTypes={until:I().string.isRequired},q.propTypes={connection:I().shape({id:I().string,name:I().string,email:I().string,displayName:I().string,modelLockUntil:I().string,testStatus:I().string,isActive:I().bool,lastError:I().string,priority:I().number,globalPriority:I().number}).isRequired,proxyPools:I().arrayOf(I().shape({id:I().string,name:I().string,proxyUrl:I().string,noProxy:I().string,isActive:I().bool})),isOAuth:I().bool.isRequired,isFirst:I().bool.isRequired,isLast:I().bool.isRequired,onMoveUp:I().func.isRequired,onMoveDown:I().func.isRequired,onToggleActive:I().func.isRequired,onUpdateProxy:I().func,onEdit:I().func.isRequired,onDelete:I().func.isRequired,oneByOneStatus:I().shape({state:I().string,error:I().string}),autoPing:I().shape({on:I().bool,onToggle:I().func,provider:I().string})};let _=`name1|sk-key1
|
|
2
|
-
name2|sk-key2
|
|
3
|
-
sk-key-only-auto-named`;function U({isOpen:e,provider:t,providerName:s,isCompatible:l,isAnthropic:r,authType:n,authHint:o,website:d,proxyPools:p,error:u,existingNames:x,onSave:h,onBulkDone:f,onClose:g}){let y="__none__",b="ollama-local"===t,v="cookie"===n,j="xai"===t&&!v,w=v?"Cookie Value":"qoder"===t||"qoder-cn"===t?"Personal Access Token (PAT)":"API Key",k="azure"===t,N="cloudflare-ai"===t,C=m.Q2?.[t]?.credentialForm==="aws",S=m.Q2?.[t]?.apiKeyOptionalWith||null,A=m.Q2?.[t]?.regions||null,T=m.Q2?.[t]?.defaultRegion||A?.[0]?.id||"",[$,O]=(0,i.useState)({name:"",apiKey:"",defaultModel:"",priority:1,proxyPoolId:y,ollamaHostUrl:""}),[I,P]=(0,i.useState)({azureEndpoint:"",apiVersion:"2024-10-01-preview",deployment:"",organization:""}),[E,D]=(0,i.useState)({accountId:""}),[R,z]=(0,i.useState)({profile:"",region:"",accessKeyId:"",sessionToken:""}),[q,M]=(0,i.useState)(T),[K,F]=(0,i.useState)(!1),[J,L]=(0,i.useState)(null),[W,B]=(0,i.useState)(!1),H=N?`name1|sk-key1|acc123456
|
|
4
|
-
name2|sk-key2|def789012
|
|
5
|
-
sk-key-only-auto-named`:"qoder"===t||"qoder-cn"===t?`name1|pt-xxxxx
|
|
6
|
-
name2|pt-yyyyy
|
|
7
|
-
pt-only-auto-named`:_,[G,Q]=(0,i.useState)("single"),[V,Z]=(0,i.useState)(""),[X,Y]=(0,i.useState)(null),ee=()=>{if(b&&$.ollamaHostUrl.trim())return{baseUrl:$.ollamaHostUrl.trim()};if(k)return{azureEndpoint:I.azureEndpoint,apiVersion:I.apiVersion,deployment:I.deployment,organization:I.organization};if(N)return{accountId:E.accountId};if(C){let e={};return R.profile.trim()&&(e.profile=R.profile.trim()),R.region.trim()&&(e.region=R.region.trim()),R.accessKeyId.trim()&&(e.accessKeyId=R.accessKeyId.trim()),R.sessionToken.trim()&&(e.sessionToken=R.sessionToken.trim()),Object.keys(e).length?e:void 0}if(A&&q)return{region:q}},et=()=>{let e=ee();return!!(S&&e?.[S])||(C?!!$.apiKey&&!!e?.accessKeyId:!!$.apiKey)},es=async()=>{F(!0);try{let e=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:$.apiKey,providerSpecificData:ee()})}),s=await e.json();L(s.valid?"success":"failed")}catch{L("failed")}finally{F(!1)}},ea=async()=>{if(t&&(b||et())&&(b||$.name)&&(!l||$.defaultModel.trim())){B(!0);try{let e=!1;try{F(!0),L(null);let s=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:$.apiKey,providerSpecificData:ee()})});e=!!(await s.json()).valid,L(e?"success":"failed")}catch{L("failed")}finally{F(!1)}await h({name:$.name||(b?"Ollama Local":""),apiKey:$.apiKey,defaultModel:l?$.defaultModel.trim():void 0,priority:$.priority,proxyPoolId:$.proxyPoolId===y?null:$.proxyPoolId,testStatus:e?"active":"unknown",providerSpecificData:ee()})}finally{B(!1)}}},ei=async()=>{let e=V.split("\n");if(!e.length)return;let s=function(e,t,s={}){let{isCloudflareAi:a=!1}=s,i=new Set((Array.isArray(t)?t:[]).map(e=>"string"==typeof e?e.toLowerCase():"")),l=[];for(let t of e){let e,s="string"==typeof t?t.trim():"";if(!s)continue;let r=function(e,t={}){let{isCloudflareAi:s=!1}=t,a=e.split("|");if(s&&a.length>=3){let e=a[0].trim();return{baseName:e||"Key",apiKey:a.slice(1,-1).join("|").trim(),providerSpecificData:{accountId:a[a.length-1].trim()}}}return a.length>=2?{baseName:a[0].trim()||"Key",apiKey:a.slice(1).join("|").trim()}:{baseName:"Key",apiKey:a[0].trim()}}(s,{isCloudflareAi:a});if(!r||!r.apiKey)continue;let n=r.baseName,o=1;for(;e=`${n} ${o}`,i.has(e.toLowerCase());)o+=1;i.add(e.toLowerCase());let d={name:e,apiKey:r.apiKey,skipped:!1};r.providerSpecificData&&(d.providerSpecificData=r.providerSpecificData),l.push(d)}return l}(e,x,{isCloudflareAi:N});if(!s.length)return;B(!0),Y(null);let a=0,i=0;for(let e of s)try{let s=!1;try{let a=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:e.apiKey})});s=!!(await a.json().catch(()=>({}))).valid}catch{s=!1}(await fetch("/api/providers",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:e.apiKey,name:e.name,priority:1,testStatus:s?"active":"unknown",...e.providerSpecificData?{providerSpecificData:e.providerSpecificData}:{}})})).ok?a++:i++}catch{i++}B(!1),Y({success:a,failed:i}),a>0&&f&&f()};return t?(0,a.jsx)(c.aF,{isOpen:e,title:`Add ${s||t} ${w}`,onClose:g,children:(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[!C&&(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{size:"sm",variant:"single"===G?"primary":"ghost",onClick:()=>{Q("single"),Y(null)},children:"Single"}),(0,a.jsx)(c.$n,{size:"sm",variant:"bulk"===G?"primary":"ghost",onClick:()=>{Q("bulk"),Y(null)},children:"Bulk Add"})]}),"bulk"===G&&(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:N?(0,a.jsxs)(a.Fragment,{children:["One key per line. Format: ",(0,a.jsx)("code",{children:"name|apiKey|accountId"})," or just ",(0,a.jsx)("code",{children:"apiKey"})," (auto-named by index)."]}):"qoder"===t||"qoder-cn"===t?(0,a.jsxs)(a.Fragment,{children:["One PAT per line. Format: ",(0,a.jsx)("code",{children:"name|pt-..."})," or just ",(0,a.jsx)("code",{children:"pt-..."})," (auto-named by index)."]}):(0,a.jsxs)(a.Fragment,{children:["One key per line. Format: ",(0,a.jsx)("code",{children:"name|apiKey"})," or just ",(0,a.jsx)("code",{children:"apiKey"})," (auto-named by index)."]})}),(0,a.jsx)("textarea",{className:"w-full rounded border border-accent/30 bg-sidebar p-2 text-sm font-mono resize-y min-h-[140px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:H,value:V,onChange:e=>Z(e.target.value)}),X&&(0,a.jsxs)("div",{className:`text-sm font-medium ${X.failed>0?"text-yellow-400":"text-green-400"}`,children:["✓ ",X.success," added",X.failed>0?`, ✗ ${X.failed} failed`:""]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{onClick:ei,fullWidth:!0,disabled:W||!V.trim(),children:W?"Adding...":"Add All Keys"}),(0,a.jsx)(c.$n,{onClick:g,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]}),"single"===G&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.pd,{label:"Name",value:$.name,onChange:e=>O({...$,name:e.target.value}),placeholder:b?"Ollama Local":"Production Key"}),b&&(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.pd,{label:"Ollama Host URL",value:$.ollamaHostUrl,onChange:e=>O({...$,ollamaHostUrl:e.target.value}),placeholder:"http://localhost:11434",className:"flex-1"}),(0,a.jsx)("div",{className:"pt-6",children:(0,a.jsx)(c.$n,{onClick:es,disabled:K||W,variant:"secondary",children:K?"Checking...":"Check"})})]}),!b&&(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.pd,{label:w,type:v?"text":"password",value:$.apiKey,onChange:e=>O({...$,apiKey:e.target.value}),placeholder:v?"grok-web"===t?"sso=xxxxx... or just the raw value":"eyJhbGciOi...":j?"xai-...":"qoder"===t||"qoder-cn"===t?"pt-...":"",className:"flex-1"}),(0,a.jsx)("div",{className:"pt-6",children:(0,a.jsx)(c.$n,{onClick:es,disabled:!et()||K||W,variant:"secondary",children:K?"Checking...":"Check"})})]}),j&&(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Use a direct xAI API key from console.x.ai. This is separate from Grok Build OAuth."}),v&&o&&(0,a.jsxs)("p",{className:"text-xs text-text-muted",children:[o,d&&(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsxs)("a",{href:d,target:"_blank",rel:"noopener noreferrer",className:"text-primary underline",children:["Open ",d.replace(/^https?:\/\//,"")]})]})]}),A&&(0,a.jsx)(c.l6,{label:"Region",value:q,onChange:e=>M(e.target.value),options:A.map(e=>({value:e.id,label:e.label}))}),l&&(0,a.jsx)(c.pd,{label:"Default Model",value:$.defaultModel,onChange:e=>O({...$,defaultModel:e.target.value}),placeholder:r?"claude-3-5-sonnet-latest":"gpt-4o-mini"}),b&&(0,a.jsxs)("p",{className:"text-xs text-text-muted",children:["Leave blank to use ",(0,a.jsx)("code",{children:"http://localhost:11434"}),". For remote Ollama, enter the full host URL (e.g. ",(0,a.jsx)("code",{children:"http://192.168.1.10:11434"}),")."]}),J&&(0,a.jsx)(c.Ex,{variant:"success"===J?"success":"error",children:"success"===J?"Valid":"Invalid"}),u&&(0,a.jsx)("p",{className:"text-xs text-red-500 break-words",children:u}),l&&(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Enter the model ID exactly as your compatible endpoint expects it. This model will be saved as the connection default."}),N&&(0,a.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"Cloudflare Workers AI"}),(0,a.jsx)(c.pd,{label:"Account ID",value:E.accountId,onChange:e=>D({...E,accountId:e.target.value}),placeholder:"abc123def456..."}),(0,a.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["Find your Account ID in the right sidebar of ",(0,a.jsx)("a",{href:"https://dash.cloudflare.com",target:"_blank",rel:"noopener noreferrer",className:"text-primary underline",children:"dash.cloudflare.com"})]})]}),C&&(0,a.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"AWS Bedrock Credentials"}),(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(c.pd,{label:"AWS Profile (SSO — recommended)",value:R.profile,onChange:e=>z({...R,profile:e.target.value}),placeholder:"my-sso-profile"}),(0,a.jsx)(c.pd,{label:"Region",value:R.region,onChange:e=>z({...R,region:e.target.value}),placeholder:"us-east-1"})]}),(0,a.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["Set a profile from ",(0,a.jsx)("code",{children:"~/.aws/config"})," and leave the API key empty, then run"," ",(0,a.jsxs)("code",{children:["aws sso login --profile ",R.profile||"my-sso-profile"]}),". Credentials refresh automatically."]}),(0,a.jsxs)("div",{className:"flex flex-col gap-3 mt-4",children:[(0,a.jsx)(c.pd,{label:"Access Key ID (only for static keys)",value:R.accessKeyId,onChange:e=>z({...R,accessKeyId:e.target.value}),placeholder:"AKIA..."}),(0,a.jsx)(c.pd,{label:"Session Token (only for temporary ASIA… keys)",type:"password",value:R.sessionToken,onChange:e=>z({...R,sessionToken:e.target.value}),placeholder:"FwoGZXIvYXdz..."})]}),(0,a.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["For static keys instead: put the AWS ",(0,a.jsx)("strong",{children:"secret"})," access key in the API Key field above and the access key id here. A profile, if set, takes precedence."]})]}),k&&(0,a.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"Azure OpenAI Configuration"}),(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(c.pd,{label:"Azure Endpoint",value:I.azureEndpoint,onChange:e=>P({...I,azureEndpoint:e.target.value}),placeholder:"https://your-resource.openai.azure.com"}),(0,a.jsx)(c.pd,{label:"Deployment Name",value:I.deployment,onChange:e=>P({...I,deployment:e.target.value}),placeholder:"gpt-4"}),(0,a.jsx)(c.pd,{label:"API Version",value:I.apiVersion,onChange:e=>P({...I,apiVersion:e.target.value}),placeholder:"2024-10-01-preview"}),(0,a.jsx)(c.pd,{label:"Organization",value:I.organization,onChange:e=>P({...I,organization:e.target.value}),placeholder:"Organization ID"})]})]}),(0,a.jsx)(c.pd,{label:"Priority",type:"number",value:$.priority,onChange:e=>O({...$,priority:Number.parseInt(e.target.value)||1})}),(0,a.jsx)(c.l6,{label:"Proxy Pool",value:$.proxyPoolId,onChange:e=>O({...$,proxyPoolId:e.target.value}),options:[{value:y,label:"None"},...(p||[]).map(e=>({value:e.id,label:e.name}))],placeholder:"None"}),0===(p||[]).length&&(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"No active proxy pools available. Create one in Proxy Pools page first."}),(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Legacy manual proxy fields are still accepted by API for backward compatibility."}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{onClick:ea,fullWidth:!0,disabled:W||!b&&(!$.name||!et())||l&&!$.defaultModel.trim()||k&&(!I.azureEndpoint||!I.deployment||!I.organization)||N&&!E.accountId,children:W?"Saving...":"Save"}),(0,a.jsx)(c.$n,{onClick:g,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})]})}):null}function M({isOpen:e,node:t,onSave:s,onClose:l,isAnthropic:r}){let[n,o]=(0,i.useState)({name:"",prefix:"",apiType:"chat",baseUrl:"https://api.openai.com/v1"}),[d,m]=(0,i.useState)(!1),[p,u]=(0,i.useState)(""),[x,h]=(0,i.useState)(""),[f,g]=(0,i.useState)(!1),[y,b]=(0,i.useState)(null);(0,i.useEffect)(()=>{t&&o({name:t.name||"",prefix:t.prefix||"",apiType:t.apiType||"chat",baseUrl:t.baseUrl||(r?"https://api.anthropic.com/v1":"https://api.openai.com/v1")})},[t,r]);let v=async()=>{if(n.name.trim()&&n.prefix.trim()&&n.baseUrl.trim()){m(!0);try{let e={name:n.name,prefix:n.prefix,baseUrl:n.baseUrl};r||(e.apiType=n.apiType),await s(e)}finally{m(!1)}}},j=async()=>{g(!0);try{let e=await fetch("/api/provider-nodes/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:n.baseUrl,apiKey:p,type:r?"anthropic-compatible":"openai-compatible",modelId:x.trim()||void 0})}),t=await e.json();b(t.valid?"success":"failed")}catch{b("failed")}finally{g(!1)}};return t?(0,a.jsx)(c.aF,{isOpen:e,title:`Edit ${r?"Anthropic":"OpenAI"} Compatible`,onClose:l,children:(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsx)(c.pd,{label:"Name",value:n.name,onChange:e=>o({...n,name:e.target.value}),placeholder:`${r?"Anthropic":"OpenAI"} Compatible (Prod)`,hint:"Required. A friendly label for this node."}),(0,a.jsx)(c.pd,{label:"Prefix",value:n.prefix,onChange:e=>o({...n,prefix:e.target.value}),placeholder:r?"ac-prod":"oc-prod",hint:"Required. Used as the provider prefix for model IDs."}),!r&&(0,a.jsx)(c.l6,{label:"API Type",options:[{value:"chat",label:"Chat Completions"},{value:"responses",label:"Responses API"}],value:n.apiType,onChange:e=>o({...n,apiType:e.target.value})}),(0,a.jsx)(c.pd,{label:"Base URL",value:n.baseUrl,onChange:e=>o({...n,baseUrl:e.target.value}),placeholder:r?"https://api.anthropic.com/v1":"https://api.openai.com/v1",hint:`Use the base URL (ending in /v1) for your ${r?"Anthropic":"OpenAI"}-compatible API.`}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.pd,{label:"API Key (for Check)",type:"password",value:p,onChange:e=>u(e.target.value),className:"flex-1"}),(0,a.jsx)("div",{className:"pt-6",children:(0,a.jsx)(c.$n,{onClick:j,disabled:!p||f||!n.baseUrl.trim(),variant:"secondary",children:f?"Checking...":"Check"})})]}),(0,a.jsx)(c.pd,{label:"Model ID (optional)",value:x,onChange:e=>h(e.target.value),placeholder:"e.g. my-model-id",hint:"If provider lacks /models endpoint, enter a model ID to validate via chat/completions instead."}),y&&(0,a.jsx)(c.Ex,{variant:"success"===y?"success":"error",children:"success"===y?"Valid":"Invalid"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{onClick:v,fullWidth:!0,disabled:!n.name.trim()||!n.prefix.trim()||!n.baseUrl.trim()||d,children:d?"Saving...":"Save"}),(0,a.jsx)(c.$n,{onClick:l,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})}):null}U.propTypes={isOpen:I().bool.isRequired,provider:I().string,providerName:I().string,isCompatible:I().bool,isAnthropic:I().bool,authType:I().string,authHint:I().string,website:I().string,proxyPools:I().arrayOf(I().shape({id:I().string,name:I().string})),error:I().string,existingNames:I().arrayOf(I().string),onSave:I().func.isRequired,onBulkDone:I().func,onClose:I().func.isRequired},M.propTypes={isOpen:I().bool.isRequired,node:I().shape({id:I().string,name:I().string,prefix:I().string,apiType:I().string,baseUrl:I().string}),onSave:I().func.isRequired,onClose:I().func.isRequired,isAnthropic:I().bool};let K=()=>Object.fromEntries(Object.keys(p.bs).map(e=>[e,!1]));function F({isOpen:e,providerAlias:t,providerDisplayAlias:s,onSave:l,onClose:r}){let[n,o]=(0,i.useState)(""),[d,m]=(0,i.useState)(K),[u,x]=(0,i.useState)(""),[h,f]=(0,i.useState)(""),[g,y]=(0,i.useState)(null),[b,v]=(0,i.useState)(""),[j,w]=(0,i.useState)(!1),[k,N]=(0,i.useState)("");(0,i.useEffect)(()=>{e&&(o(""),m(K()),x(""),f(""),N(""),y(null),v(""))},[e]);let C=e=>{let s=`${t}/`;return e.startsWith(s)?e.slice(s.length):e},S=async()=>{let e=C(n.trim());if(e){y("testing"),v("");try{let s=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${t}/${e}`})}),a=await s.json();y(a.ok?"ok":"error"),v(a.error||"")}catch(e){y("error"),v(e.message)}}},A=async()=>{let e=C(n.trim());if(e&&!j){w(!0);try{let t={...d,...u?{contextWindow:Number(u)}:{},...h?{maxOutput:Number(h)}:{}};await l(e,t,d.stt?k:null)}finally{w(!1)}}};return(0,a.jsx)(c.aF,{isOpen:e,onClose:r,title:"Add Custom Model",children:(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Model ID"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)("input",{type:"text",value:n,onChange:e=>{o(e.target.value),y(null),v("")},onKeyDown:e=>{"Enter"===e.key&&S()},placeholder:"e.g. claude-opus-4-5",className:"flex-1 px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary",autoFocus:!0}),(0,a.jsx)(c.$n,{variant:"secondary",icon:"science",loading:"testing"===g,onClick:S,disabled:!n.trim()||"testing"===g,children:"testing"===g?"Testing...":"Test"})]}),(0,a.jsxs)("p",{className:"text-xs text-text-muted mt-1",children:["Sent to provider as: ",(0,a.jsx)("code",{className:"font-mono bg-sidebar px-1 rounded",children:C(n.trim())||"model-id"})]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Capabilities"}),(0,a.jsx)("div",{className:"flex flex-wrap gap-4",children:Object.entries(p.bs).map(([e,t])=>(0,a.jsx)(c.lM,{checked:!!d[e],onChange:t=>m(s=>({...s,[e]:t})),label:t.label,description:t.desc,size:"sm"},e))})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Context window"}),(0,a.jsx)("input",{type:"number",min:"1",step:"1",value:u,onChange:e=>x(e.target.value),placeholder:"Optional, in tokens",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Maximum output"}),(0,a.jsx)("input",{type:"number",min:"1",step:"1",value:h,onChange:e=>f(e.target.value),placeholder:"Optional, in tokens",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)(c.lM,{checked:!!d.stt,onChange:e=>{m(t=>({...t,stt:e})),e||N("")},label:"Speech to text",description:"Transcribes audio via /v1/audio/transcriptions",size:"sm"}),d.stt&&(0,a.jsx)("div",{className:"mt-3",children:(0,a.jsx)(c.l6,{label:"Transport",value:k,onChange:e=>N(e.target.value),placeholder:"Provider default (REST)",options:p.vp.map(e=>({value:e,label:p.qw[e].label})),hint:"Realtime transport marker for the STT dispatcher. Empty keeps the provider's REST format."})})]}),"ok"===g&&(0,a.jsxs)("div",{className:"flex items-center gap-2 text-sm text-green-600",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-base",children:"check_circle"}),"Model is reachable"]}),"error"===g&&(0,a.jsxs)("div",{className:"flex items-start gap-2 text-sm text-red-500",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-base shrink-0",children:"cancel"}),(0,a.jsx)("span",{children:b||"Model not reachable"})]}),(0,a.jsxs)("div",{className:"flex gap-2 pt-1",children:[(0,a.jsx)(c.$n,{onClick:r,variant:"ghost",fullWidth:!0,size:"sm",children:"Cancel"}),(0,a.jsx)(c.$n,{onClick:A,fullWidth:!0,size:"sm",disabled:!n.trim()||j,children:j?"Adding...":"Add Model"})]})]})})}F.propTypes={isOpen:I().bool.isRequired,providerAlias:I().string.isRequired,providerDisplayAlias:I().string.isRequired,onSave:I().func.isRequired,onClose:I().func.isRequired};let J=`[
|
|
8
|
-
{
|
|
9
|
-
"accessToken": "eyJhbGc...",
|
|
10
|
-
"refreshToken": "rt_...",
|
|
11
|
-
"idToken": "eyJhbGc...",
|
|
12
|
-
"email": "user@example.com"
|
|
13
|
-
}
|
|
14
|
-
]`;function L({isOpen:e,onClose:t,onSuccess:s}){let[l,r]=(0,i.useState)(""),[n,o]=(0,i.useState)(!1),[d,m]=(0,i.useState)(""),[p,u]=(0,i.useState)(null),x=()=>{n||(r(""),m(""),u(null),t())},h=async()=>{var e;let t;m(""),u(null);let a=l.trim();if(!a)return;try{t=JSON.parse(a)}catch(e){m(`${(0,S.Tl)("Invalid JSON")}: ${e.message}`);return}let i=Array.isArray(e=t)?e:e&&"object"==typeof e?Array.isArray(e.accounts)?e.accounts:[e]:null;if(!i||0===i.length)return void m((0,S.Tl)("No accounts found in input"));o(!0);try{let e=await fetch("/api/oauth/codex/bulk-import",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({accounts:i})}),t=await e.json();if(!e.ok)return void m(t?.error||`Request failed: ${e.status}`);u(t),t.success>0&&"function"==typeof s&&s()}catch(e){m(e.message||(0,S.Tl)("Request failed"))}finally{o(!1)}},f=p?.results?.filter(e=>!e.ok)||[];return(0,a.jsx)(c.aF,{isOpen:e,title:(0,S.Tl)("Bulk Add Codex Accounts"),onClose:x,children:(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:(0,S.Tl)("Paste an array of codex account JSON objects. Each must include accessToken (and ideally refreshToken, idToken).")}),(0,a.jsx)("textarea",{className:"w-full rounded border border-accent/30 bg-sidebar p-2 text-sm font-mono resize-y min-h-[240px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:J,value:l,onChange:e=>r(e.target.value),disabled:n}),d&&(0,a.jsx)("p",{className:"text-xs text-red-500 break-words",children:d}),p&&(0,a.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,a.jsxs)("div",{className:`text-sm font-medium ${p.failed>0?"text-yellow-400":"text-green-400"}`,children:["✓ ",p.success," ",(0,S.Tl)("added"),p.failed>0?`, ✗ ${p.failed} ${(0,S.Tl)("failed")}`:""]}),f.length>0&&(0,a.jsx)("ul",{className:"rounded border border-accent/20 bg-sidebar/50 p-2 text-xs font-mono max-h-40 overflow-y-auto",children:f.map(e=>(0,a.jsxs)("li",{className:"text-red-400",children:["[",e.index,"] ",e.error]},e.index))})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{onClick:h,fullWidth:!0,disabled:n||!l.trim(),children:n?(0,S.Tl)("Importing..."):(0,S.Tl)("Import All")}),(0,a.jsx)(c.$n,{onClick:x,variant:"ghost",fullWidth:!0,disabled:n,children:(0,S.Tl)("Close")})]})]})})}L.propTypes={isOpen:I().bool.isRequired,onClose:I().func.isRequired,onSuccess:I().func};let W=`[
|
|
15
|
-
{
|
|
16
|
-
"access_token": "eyJ0eXAiOiJhdCtqd3Qi...",
|
|
17
|
-
"refresh_token": "LZhriF9bf88pPykpXCuZ9...",
|
|
18
|
-
"id_token": "eyJ0eXAiOiJKV1QiLCJhbGci...",
|
|
19
|
-
"email": "account1@example.com"
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
"access_token": "eyJ0eXAiOiJhdCtqd3Qi...",
|
|
23
|
-
"refresh_token": "LZhriF9bf88pPykpXCuZ9...",
|
|
24
|
-
"id_token": "eyJ0eXAiOiJKV1QiLCJhbGci...",
|
|
25
|
-
"email": "account2@example.com"
|
|
26
|
-
}
|
|
27
|
-
]`;function B(e){let t,s=e.trim();if(!s)return[];try{t=JSON.parse(s)}catch(e){try{let e=s;e.startsWith("[")||((e=e.replace(/\}\s*,\s*\{/g,"},{").replace(/\}\s*\{/g,"},{")).endsWith(",")&&(e=e.slice(0,-1)),e=`[${e}]`),t=JSON.parse(e)}catch{throw e}}if(Array.isArray(t))return t;if(t&&"object"==typeof t)return Array.isArray(t.accounts)?t.accounts:[t];throw Error("Input must be a JSON object or array of objects")}function H({isOpen:e,onClose:t,onSuccess:s}){let[l,r]=(0,i.useState)(""),[n,o]=(0,i.useState)(!1),[d,m]=(0,i.useState)(""),[p,u]=(0,i.useState)(null),[x,h]=(0,i.useState)(!1),[f,g]=(0,i.useState)(null),y=(0,i.useRef)(null),b=()=>{n||(r(""),m(""),u(null),g(null),h(!1),t())},v=async e=>{if(!e||0===e.length)return;m("");let t=Array.from(e).filter(e=>e.name.endsWith(".json")||"application/json"===e.type||""===e.type);if(0===t.length)return void m((0,S.Tl)("Please select valid .json files"));try{let e=[];for(let s of t){let t=await s.text(),a=B(t);Array.isArray(a)?e.push(...a):a&&e.push(a)}if(0===e.length)return void m((0,S.Tl)("No accounts found in selected files"));r(JSON.stringify(e,null,2)),g({filesCount:t.length,accountsCount:e.length})}catch(e){m(`${(0,S.Tl)("Error reading files")}: ${e.message}`)}},j=async()=>{let e;m(""),u(null);try{e=B(l)}catch(e){m(`${(0,S.Tl)("Invalid JSON")}: ${e.message}`);return}if(!e||0===e.length)return void m((0,S.Tl)("No accounts found in input"));o(!0);try{let t=await fetch("/api/oauth/grok-cli/bulk-import",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({accounts:e})}),a=await t.json();if(!t.ok)return void m(a?.error||`Request failed: ${t.status}`);u(a),a.success>0&&"function"==typeof s&&s()}catch(e){m(e.message||(0,S.Tl)("Request failed"))}finally{o(!1)}},w=p?.results?.filter(e=>!e.ok)||[];return(0,a.jsx)(c.aF,{isOpen:e,title:(0,S.Tl)("Bulk Add Grok CLI Accounts"),onClose:b,children:(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:(0,S.Tl)("Upload multiple .json files or paste JSON array / object.")}),(0,a.jsx)("input",{ref:y,type:"file",accept:".json,application/json",multiple:!0,className:"hidden",onChange:e=>{v(e.target.files),e.target&&(e.target.value="")}}),(0,a.jsx)(c.$n,{type:"button",size:"sm",variant:"secondary",icon:"upload_file",onClick:()=>y.current?.click(),disabled:n,children:(0,S.Tl)("Upload JSON Files")})]}),(0,a.jsxs)("div",{onDragOver:e=>{e.preventDefault(),h(!0)},onDragLeave:e=>{e.preventDefault(),h(!1)},onDrop:e=>{e.preventDefault(),h(!1),e.dataTransfer?.files?.length>0&&v(e.dataTransfer.files)},className:`relative rounded border transition-colors ${x?"border-primary bg-primary/10 ring-2 ring-primary/30":"border-accent/30 bg-sidebar"}`,children:[(0,a.jsx)("textarea",{className:"w-full rounded bg-transparent p-2.5 text-sm font-mono resize-y min-h-[240px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:W,value:l,onChange:e=>{r(e.target.value),g(null)},disabled:n}),x&&(0,a.jsxs)("div",{className:"absolute inset-0 flex flex-col items-center justify-center bg-sidebar/90 rounded pointer-events-none backdrop-blur-xs",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-3xl text-primary mb-1",children:"upload_file"}),(0,a.jsx)("span",{className:"text-sm font-medium text-primary",children:(0,S.Tl)("Drop .json files here")})]})]}),f&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5 text-xs text-green-400 font-medium bg-green-500/10 border border-green-500/20 px-2.5 py-1.5 rounded",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"check_circle"}),(0,a.jsxs)("span",{children:[(0,S.Tl)("Loaded")," ",f.accountsCount," ",(0,S.Tl)("account(s) from")," ",f.filesCount," ",(0,S.Tl)("file(s)")]})]}),d&&(0,a.jsx)("p",{className:"text-xs text-red-500 break-words",children:d}),p&&p.failed>0&&(0,a.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,a.jsxs)("div",{className:"text-sm font-medium text-yellow-400",children:["✗ ",p.failed," ",(0,S.Tl)("failed")]}),w.length>0&&(0,a.jsx)("ul",{className:"rounded border border-accent/20 bg-sidebar/50 p-2 text-xs font-mono max-h-40 overflow-y-auto",children:w.map(e=>(0,a.jsxs)("li",{className:"text-red-400",children:["[",e.index,"] ",e.error]},e.index))})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(c.$n,{onClick:j,fullWidth:!0,disabled:n||!l.trim(),children:n?(0,S.Tl)("Importing..."):(0,S.Tl)("Import All")}),(0,a.jsx)(c.$n,{onClick:b,variant:"ghost",fullWidth:!0,disabled:n,children:(0,S.Tl)("Close")})]})]})})}var G=s(65921);let Q=["host","content-length","content-type","connection","transfer-encoding","authorization","cookie"],V=/^[A-Za-z0-9-]+$/;function Z({providerId:e}){let t=(0,G.i)(),[s,l]=(0,i.useState)(!1),[r,n]=(0,i.useState)([{name:"",value:""}]),[o,d]=(0,i.useState)({}),[m,p]=(0,i.useState)(!1),[u,x]=(0,i.useState)(!1);(0,i.useEffect)(()=>{let t=!1;return fetch(`/api/providers/${e}/overrides`,{cache:"no-store"}).then(e=>e.ok?e.json():null).then(e=>{if(t||!e)return;let s=e.builtinHeaders||{},a=Object.entries({...s,...e.headers||{}}).map(([e,t])=>({name:e,value:t}));d(s),n(a.length?a:[{name:"",value:""}]),p(Object.keys(e.headers||{}).length>0)}).catch(()=>{}),()=>{t=!0}},[e]);let h=(e,t,s)=>{n(a=>a.map((a,i)=>i===e?{...a,[t]:s}:a))},f=(0,i.useCallback)(async()=>{let s={};for(let e of r.filter(e=>e.name.trim())){let a=e.name.trim();if(!V.test(a))return void t.error(`Invalid header name: ${a}`);if(Q.includes(a.toLowerCase()))return void t.error(`Header ${a} cannot be overridden`);if(a in s)return void t.error(`Duplicate header name: ${a}`);e.value!==o[a]&&(s[a]=e.value)}x(!0);try{let a=await fetch(`/api/providers/${e}/overrides`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({headers:s})});if(!a.ok){let e=await a.json().catch(()=>({}));t.error(e.error||"Failed to save");return}p(Object.keys(s).length>0),t.success("Custom headers saved")}finally{x(!1)}},[r,o,e,t]);return 0!==Object.keys(o).length||m?(0,a.jsxs)(c.Zp,{padding:"xs",children:[(0,a.jsxs)("button",{type:"button",onClick:()=>l(e=>!e),className:"flex w-full items-center justify-between text-left",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-primary text-[20px]",children:"tune"}),(0,a.jsx)("span",{className:"text-sm font-semibold",children:"Custom Headers"}),m&&(0,a.jsx)(c.Ex,{variant:"success",size:"sm",children:"Active"})]}),(0,a.jsx)("span",{className:"material-symbols-outlined text-text-muted",children:s?"expand_less":"expand_more"})]}),s&&(0,a.jsxs)("div",{className:"mt-3 border-t border-border pt-3",children:[(0,a.jsx)("div",{className:"flex flex-col gap-2",children:r.map((e,t)=>{let s=e.name.trim()in o&&e.value!==o[e.name.trim()];return(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("input",{value:e.name,onChange:e=>h(t,"name",e.target.value),placeholder:"Header-Name",spellCheck:!1,className:"w-44 rounded-md border border-border bg-background px-2 py-1.5 text-sm focus:border-primary focus:outline-none"}),(0,a.jsx)("input",{value:e.value,onChange:e=>h(t,"value",e.target.value),placeholder:"Value",spellCheck:!1,title:s?"Overridden":e.name.trim()in o?"Registry default":"",className:`min-w-0 flex-1 rounded-md border bg-background px-2 py-1.5 text-sm focus:border-primary focus:outline-none ${s?"border-amber-400/60":"border-border"}`}),(0,a.jsx)("button",{type:"button",title:"Remove header",onClick:()=>n(e=>e.length>1?e.filter((e,s)=>s!==t):[{name:"",value:""}]),className:"shrink-0 text-text-muted hover:text-red-500",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"delete"})})]},t)})}),(0,a.jsxs)("div",{className:"mt-3 flex items-center justify-between gap-2",children:[(0,a.jsxs)("button",{type:"button",onClick:()=>n(e=>[...e,{name:"",value:""}]),className:"flex items-center gap-1 text-xs text-primary hover:underline",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"add"}),"Add header"]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)("button",{type:"button",disabled:u,onClick:()=>{n(Object.entries(o).map(([e,t])=>({name:e,value:t})))},className:"rounded-md border border-border px-3 py-1.5 text-xs hover:bg-black/[0.03] dark:hover:bg-white/[0.03] disabled:opacity-50",children:"Reset"}),(0,a.jsx)("button",{type:"button",disabled:u,onClick:f,className:"rounded-md bg-primary px-3 py-1.5 text-xs font-medium text-white hover:opacity-90 disabled:opacity-50",children:u?"Saving...":"Save"})]})]})]})]}):null}Z.propTypes={providerId:I().string.isRequired};let X={claude:"claudeAutoPing",codex:"codexAutoPing"};function Y(){let e,t,s=(0,l.useParams)(),r=(0,l.useRouter)(),u=s.id,{getCaps:x}=(0,C.yU)(),[h,f]=(0,i.useState)([]),[g,y]=(0,i.useState)(!0),[b,v]=(0,i.useState)(null),[j,w]=(0,i.useState)([]),[A,O]=(0,i.useState)(!1),[I,E]=(0,i.useState)(!1),[R,z]=(0,i.useState)(!1),[_,K]=(0,i.useState)(""),[J,W]=(0,i.useState)(!1),[B,G]=(0,i.useState)(!1),[Q,V]=(0,i.useState)(!1),[Y,ee]=(0,i.useState)(!1),[et,es]=(0,i.useState)(!1),[ea,ei]=(0,i.useState)(null),[el,er]=(0,i.useState)({}),[en,eo]=(0,i.useState)([]),[ed,ec]=(0,i.useState)(!1),[em,ep]=(0,i.useState)({}),[eu,ex]=(0,i.useState)(""),[eh,ef]=(0,i.useState)(()=>new Set),[eg,ey]=(0,i.useState)(!1),[eb,ev]=(0,i.useState)([]),[ej,ew]=(0,i.useState)("__none__"),[ek,eN]=(0,i.useState)(!1),[eC,eS]=(0,i.useState)(null),[eA,eT]=(0,i.useState)(""),[e$,eO]=(0,i.useState)("auto"),[eI,eP]=(0,i.useState)({enabled:!1,connections:{}}),[eE,eD]=(0,i.useState)([]),[eR,ez]=(0,i.useState)([]),[eq,e_]=(0,i.useState)(null),[eU,eM]=(0,i.useState)([]),[eK,eF]=(0,i.useState)([]),[eJ,eL]=(0,i.useState)(null),[eW,eB]=(0,i.useState)(!1),[eH,eG]=(0,i.useState)(!1),[eQ,eV]=(0,i.useState)(!1),[eZ,eX]=(0,i.useState)(null),[eY,e0]=(0,i.useState)({}),[e1,e2]=(0,i.useState)(null),e5=(0,i.useRef)(!1),[e3,e4]=(0,i.useState)(!1),[e6,e8]=(0,i.useState)(!1),[e7,e9]=(0,i.useState)(!1),{copied:te,copy:tt}=(0,N.C)(),ts="ag_risk_confirmed",ta=()=>{O(!0)},ti=()=>{"antigravity"===u&&"true"!==window.localStorage.getItem(ts)?eB(!0):td?ta():(K(""),z(!0))},tl=()=>{K(""),z(!0)},tr=()=>{td?ti():tl()},tn=b?{id:b.id,name:b.name||("anthropic-compatible"===b.type?"Anthropic Compatible":"OpenAI Compatible"),color:"anthropic-compatible"===b.type?"#D97757":"#10A37F",textIcon:"anthropic-compatible"===b.type?"AC":"OC",apiType:b.apiType,baseUrl:b.baseUrl,type:b.type}:m.zN[u]||m.fg[u]||m.IS[u]||m.nJ[u]||m.br[u],to=tn?.authModes||[],td=!!m.zN[u]||!!m.IS[u]||to.includes("oauth"),tc=!!m.fg[u]||to.includes("apikey"),tm=!!m.IS[u]?.noAuth,tp=(0,p.KC)(u),tu=("cursor"===u||"zed"===u)&&eR.length>0?eR:tp,tx=(0,m.wG)(u),th=(0,m.mq)(u),tf=(0,m.gb)(u),tg=th||tf,ty=!tg&&td&&tc,tb="xai"===u?"Grok Build OAuth":"grok-cli"===u?"Grok CLI Device Login":"kimi"===u?"Kimi Coding OAuth":"OAuth",tv="xai"===u?"xAI API Key":"kimi"===u?"Kimi API Key":"qoder"===u||"qoder-cn"===u?"PAT":"API Key",tj=e=>{if(!e$||"auto"===e$)return null;let t=k(u,e);return t&&t.includes(e$)?e$:null},tw=tg?u:tx,tk=(()=>{let e=new Set,t=new Set,s=s=>{if(!s||t.has(s))return;t.add(s);let a=k(u,s);a&&a.forEach(t=>{"none"!==t&&e.add(t)})};for(let e of tu)s(e.id);for(let e of eU)s(e.id);for(let e of en)e.providerAlias===tw&&"llm"===(e.kind||e.type||"llm")&&s(e.id);return e.size?["auto",...e]:null})(),tN=tg?b?.prefix||u:tx,tC=(0,i.useCallback)(async()=>{try{let e=await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tw)}`,{cache:"no-store"}),t=await e.json();e.ok&&eF(t.ids||[])}catch(e){console.log("Error fetching disabled models:",e)}},[tw]),tS=async e=>{try{(await fetch("/api/models/disabled",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:tw,ids:[e]})})).ok&&await tC()}catch(e){console.log("Error disabling model:",e)}},tA=async e=>{try{(await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tw)}&id=${encodeURIComponent(e)}`,{method:"DELETE"})).ok&&await tC()}catch(e){console.log("Error enabling model:",e)}},tT=async e=>{e.length&&eL({title:"Disable All Models",message:`Disable all ${e.length} model(s)?`,onConfirm:async()=>{eL(null);try{(await fetch("/api/models/disabled",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:tw,ids:e})})).ok&&await tC()}catch(e){console.log("Error disabling all models:",e)}}})},t$=async()=>{try{(await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tw)}`,{method:"DELETE"})).ok&&await tC()}catch(e){console.log("Error enabling all models:",e)}},tO=(0,i.useCallback)(async()=>{try{let e=await fetch("/api/models/alias"),t=await e.json();e.ok&&er(t.aliases||{})}catch(e){console.log("Error fetching aliases:",e)}},[]),tI=(0,i.useCallback)(async()=>{try{let e=await fetch("/api/models/custom",{cache:"no-store"}),t=await e.json();e.ok&&eo(t.models||[])}catch(e){console.log("Error fetching custom models:",e)}},[]);(0,i.useEffect)(()=>{"kilocode"===u&&fetch("/api/providers/kilo/free-models").then(e=>e.json()).then(e=>{e.models?.length&&eM(e.models)}).catch(()=>{})},[u]);let tP=(0,i.useCallback)(async()=>{try{let[e,t,s,a]=await Promise.all([fetch("/api/providers",{cache:"no-store"}),fetch("/api/provider-nodes",{cache:"no-store"}),fetch("/api/proxy-pools?isActive=true",{cache:"no-store"}),fetch("/api/settings",{cache:"no-store"})]),i=await e.json(),l=await t.json(),r=await s.json(),n=a.ok?await a.json():{};if(e.ok){let e=(i.connections||[]).filter(e=>e.provider===u);f(e)}s.ok&&w(r.proxyPools||[]);let o=(n.providerStrategies||{})[u]||{};eS(o.fallbackStrategy||null),eT(null!=o.stickyRoundRobinLimit?String(o.stickyRoundRobinLimit):"1");let d=(n.providerThinking||{})[u]||{};eO(d.mode||"auto");let c=X[u],m=c&&n[c]||{};if(eP({enabled:!0===m.enabled,connections:m.connections||{}}),t.ok){let e=(l.nodes||[]).find(e=>e.id===u)||null;if(!e&&tg)for(let t=0;t<3;t+=1){await new Promise(e=>setTimeout(e,150));let t=await fetch("/api/provider-nodes",{cache:"no-store"});if(t.ok&&(e=((await t.json()).nodes||[]).find(e=>e.id===u)||null))break}v(e)}}catch(e){console.log("Error fetching connections:",e)}finally{y(!1)}},[u,tg]),tE=async e=>{try{let t=await fetch(`/api/provider-nodes/${u}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}),s=await t.json();t.ok&&(v(s.node),await tP(),ee(!1))}catch(e){console.log("Error updating provider node:",e)}},tD=async(e,t)=>{try{let s=await fetch("/api/settings",{cache:"no-store"}),a=(s.ok?await s.json():{}).providerStrategies||{},i={};e&&(i.fallbackStrategy=e),"round-robin"===e&&""!==t&&(i.stickyRoundRobinLimit=Number(t)||3);let l={...a};0===Object.keys(i).length?delete l[u]:l[u]=i,await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerStrategies:l})})}catch(e){console.log("Error saving provider strategy:",e)}},tR=async e=>{try{let t=await fetch("/api/settings",{cache:"no-store"}),s={...(t.ok?await t.json():{}).providerThinking||{}};e&&"auto"!==e?s[u]={mode:e}:delete s[u],await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerThinking:s})})}catch(e){console.log("Error saving thinking config:",e)}},tz=async e=>{let t=X[u];if(t){eP(e);try{await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({[t]:e})})}catch(e){console.log("Error saving auto-ping config:",e)}}};(0,i.useEffect)(()=>{tP(),tO(),tI(),tC()},[tP,tO,tI,tC]),(0,i.useEffect)(()=>{if("cursor"!==u&&"zed"!==u)return void ez([]);let e=h.find(e=>!1!==e.isActive);if(!e?.id){ez([]),"zed"===u&&e_(null);return}let t=!1;return"zed"===u&&e_(null),fetch(`/api/providers/${e.id}/models`,{cache:"no-store"}).then(async e=>({ok:e.ok,data:await e.json().catch(()=>null)})).then(({ok:e,data:s})=>{if(!t){if(e&&Array.isArray(s?.models)&&s.models.length>0){ez(s.models),"zed"===u&&s?.warning&&e_(s.warning);return}"zed"===u&&(ez([]),e_(s?.warning||s?.error||"Zed returned no live models."))}}).catch(()=>{t||"zed"!==u||(ez([]),e_("Failed to reach the Zed model catalog."))}),()=>{t=!0}},[u,h]),(0,i.useEffect)(()=>{let e=(m.zN[u]||m.fg[u]||m.IS[u]||m.nJ[u])?.modelsFetcher;e&&T(e).then(eD)},[u]);let tq=async(e,t,s=tx)=>{let a=`${s}/${e}`;try{let e=await fetch("/api/models/alias",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:a,alias:t})});if(e.ok)await tO();else{let t=await e.json();alert(t.error||"Failed to set alias")}}catch(e){console.log("Error setting alias:",e)}},t_=async e=>{try{(await fetch(`/api/models/alias?alias=${encodeURIComponent(e)}`,{method:"DELETE"})).ok&&await tO()}catch(e){console.log("Error deleting alias:",e)}},tU=async(e,t="llm",s=tw,a,i)=>{try{let l=await fetch("/api/models/custom",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:s,id:e,type:t,...a?{caps:a}:{},...i?{transport:i}:{}})});if(l.ok)await tI(),window.dispatchEvent(new CustomEvent("customModelChanged"));else{let e=await l.json();alert(e.error||"Failed to add custom model")}}catch(e){console.log("Error adding custom model:",e)}},tM=async(e,t="llm",s=tw)=>{try{let a=new URLSearchParams({providerAlias:s,id:e,type:t});(await fetch(`/api/models/custom?${a}`,{method:"DELETE"})).ok&&(await tI(),window.dispatchEvent(new CustomEvent("customModelChanged")))}catch(e){console.log("Error deleting custom model:",e)}},tK=async()=>{if(!e6&&0!==eE.length){e8(!0);try{let e=new Set(tu.map(e=>e.id)),t=new Set(en.filter(e=>e.providerAlias===tw&&"llm"===(e.kind||e.type||"llm")).map(e=>e.id)),s=new Set(Object.values(el).filter(e=>"string"==typeof e)),a=0;for(let i of eE){let l=i.id||i.name||i.model;!(!l||e.has(l)||t.has(l))&&(s.has(`${tw}/${l}`)||(await tU(l,"llm",tw,i.caps),t.add(l),a+=1))}alert(a>0?`${(0,S.Tl)("Successfully added")} ${a} ${(0,S.Tl)("models")}`:(0,S.Tl)("All models already exist, no new models added"))}catch(e){console.log("Error importing provider models:",e),alert((0,S.Tl)("Error fetching models")+": "+e.message)}finally{e8(!1)}}},tF=async()=>{if(e3)return;let e=h.find(e=>!1!==e.isActive);if(!e)return void alert((0,S.Tl)("Please add an active Qoder connection first"));e4(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||(0,S.Tl)("Failed to fetch models"));let a=s.models||[];if(0===a.length)return void alert((0,S.Tl)("No models returned"));let i=0;for(let e of a){let t=e.id||e.name;if(!t)continue;let s=t.replace(/^(qoder-cn|qoder)\//,"");en.some(e=>e.providerAlias===tw&&e.id===s&&"llm"===(e.kind||e.type||"llm"))||Object.values(el).includes(`${tw}/${s}`)||(await tU(s,"llm",tw,e.caps),i+=1)}0===i?alert((0,S.Tl)("All models already exist, no new models added")):alert((0,S.Tl)("Successfully added")+` ${i} `+(0,S.Tl)("models"))}catch(e){console.log("Error importing Qoder models:",e),alert((0,S.Tl)("Error fetching models")+": "+e.message)}finally{e4(!1)}},tJ=async()=>{if(e7)return;let e=h.find(e=>!1!==e.isActive);if(!e)return void alert((0,S.Tl)("Please add an active Cline connection first"));e9(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||(0,S.Tl)("Failed to fetch models"));let a=s.models||[];if(0===a.length)return void alert((0,S.Tl)("No models returned"));let i=0;for(let e of a){let t=e.id||e.name;t&&(en.some(e=>e.providerAlias===tw&&e.id===t&&"llm"===(e.kind||e.type||"llm"))||Object.values(el).includes(`${tw}/${t}`)||(await tU(t,"llm",tw),i+=1))}0===i?alert((0,S.Tl)("All models already exist, no new models added")):alert((0,S.Tl)("Successfully added")+` ${i} `+(0,S.Tl)("models"))}catch(e){console.log("Error importing Cline models:",e),alert((0,S.Tl)("Error fetching models")+": "+e.message)}finally{e9(!1)}},tL=async()=>{if(eH||0===h.length)return;let e=Object.fromEntries(h.map(e=>[e.id,{state:"queued",error:null}]));e5.current=!1,eG(!0),eV(!1),eX(null),e0(e),e2({total:h.length,completed:0,passed:0,failed:0,stopped:!1});let t=0,s=0;try{for(let e=0;e<h.length;e+=1){if(e5.current){e2({total:h.length,completed:e,passed:t,failed:s,stopped:!0});break}let a=h[e];eX(a.id),e0(e=>({...e,[a.id]:{state:"testing",error:null}}));try{let e=await fetch(`/api/providers/${a.id}/test`,{method:"POST"}),i=await e.json(),l=!!i.valid;l?t+=1:s+=1,e0(e=>({...e,[a.id]:{state:l?"success":"failed",error:l?null:i.error||null}}))}catch(e){s+=1,e0(t=>({...t,[a.id]:{state:"failed",error:e.message||"Test failed"}}))}e2({total:h.length,completed:e+1,passed:t,failed:s,stopped:!1}),e<h.length-1&&await new Promise(e=>setTimeout(e,1e3))}}finally{eX(null),eG(!1),eV(!1),e5.current=!1}},tW=async e=>{eL({title:"Delete Connection",message:"Delete this connection?",onConfirm:async()=>{eL(null);try{(await fetch(`/api/providers/${e}`,{method:"DELETE"})).ok&&f(t=>t.filter(t=>t.id!==e))}catch(e){console.log("Error deleting connection:",e)}}})},tB=()=>{tP(),O(!1)},tH=async e=>{K("");try{let t=await fetch("/api/providers",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:u,...e})}),s=null;try{s=await t.json()}catch{s=null}if(t.ok){await tP(),z(!1);return}K(s?.error||"Failed to save connection")}catch(e){console.log("Error saving connection:",e),K("Failed to save connection")}},tG=async e=>{try{(await fetch(`/api/providers/${ea.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok&&(await tP(),V(!1))}catch(e){console.log("Error updating connection:",e)}},tQ=async(e,t)=>{try{(await fetch(`/api/providers/${e}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:t})})).ok&&f(s=>s.map(s=>s.id===e?{...s,isActive:t}:s))}catch(e){console.log("Error updating connection status:",e)}},tV=async(e,t)=>{let s=[...h];[s[e],s[t]]=[s[t],s[e]],f(s);try{await Promise.all([fetch(`/api/providers/${s[e].id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({priority:e})}),fetch(`/api/providers/${s[t].id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({priority:t})})])}catch(e){console.log("Error swapping priority:",e),await tP()}},tZ=h.filter(e=>eb.includes(e.id)),tX=h.length>0&&eb.length===h.length;(0,i.useEffect)(()=>{ev(e=>e.filter(e=>h.some(t=>t.id===e)))},[h]),(()=>{if(0===tZ.length)return;let e=new Set(tZ.map(e=>e.providerSpecificData?.proxyPoolId||"__none__"));if(1===e.size){let t=[...e][0];if("__none__"===t)return;let s=j.find(e=>e.id===t);return s?.name}})();let tY=()=>{ek||es(!1)},t0=async(e,{mode:t}={})=>{eN(!0);try{let s=await fetch("/api/providers/bulk-proxy",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:u,mode:t||"single",proxyPoolId:e[0]?.proxyPoolId??null,connectionIds:e.map(e=>e.connectionId)})});if(s.ok){let e=await s.json().catch(()=>({}));Array.isArray(e.missing)&&e.missing.length>0&&alert(`Applied to ${e.updated} connection(s); ${e.missing.length} no longer exist.`)}else if(404===s.status||405===s.status)await t1(e);else{let e=await s.json().catch(()=>({}));alert(e.error||"Failed to apply proxy.")}await tP(),es(!1)}finally{eN(!1)}},t1=async e=>{let t=0;for(let{connectionId:s,proxyPoolId:a}of e)try{(await fetch(`/api/providers/${s}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({proxyPoolId:a})})).ok||(t+=1)}catch(e){console.log("Error applying proxy for",s,e),t+=1}t>0&&alert(`Updated with ${t} failed request(s).`)},t2=e=>t0(h.map(t=>({connectionId:t.id,proxyPoolId:e})),{mode:"single"}),t5=(0,a.jsx)("div",{className:"flex min-w-0 flex-col divide-y divide-black/[0.03] dark:divide-white/[0.03] max-h-[500px] overflow-y-auto pr-1",children:h.map((e,t)=>{let s;return(0,a.jsxs)("div",{className:"flex min-w-0 items-stretch",children:[(0,a.jsx)("div",{className:"flex shrink-0 items-center pl-1 sm:pl-2",children:(0,a.jsx)("input",{type:"checkbox",checked:(s=e.id,eb.includes(s)),onChange:()=>{var t;return t=e.id,void ev(e=>e.includes(t)?e.filter(e=>e!==t):[...e,t])},className:"h-4 w-4 rounded border-gray-300 text-primary focus:ring-primary"})}),(0,a.jsx)("div",{className:"flex-1 min-w-0",children:(0,a.jsx)(q,{connection:e,proxyPools:j,isOAuth:td,isFirst:0===t,isLast:t===h.length-1,onMoveUp:()=>tV(t,t-1),onMoveDown:()=>tV(t,t+1),onToggleActive:t=>tQ(e.id,t),autoPing:X[u]&&"oauth"===e.authType?{on:!0===eI.connections[e.id],onToggle:t=>{var s;return s=e.id,void tz({...eI,connections:{...eI.connections,[s]:t}})},provider:u}:null,onUpdateProxy:async t=>{try{(await fetch(`/api/providers/${e.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({proxyPoolId:t||null})})).ok&&f(s=>s.map(s=>s.id===e.id?{...s,providerSpecificData:{...s.providerSpecificData,proxyPoolId:t||null}}:s))}catch(e){console.log("Error updating proxy:",e)}},onEdit:()=>{ei(e),V(!0)},onDelete:()=>tW(e.id),oneByOneStatus:eY[e.id]||null})})]},e.id)})}),t3=j.filter(e=>!0===e.isActive),t4=(0,a.jsx)(c.aF,{isOpen:et,onClose:tY,title:`Apply Proxy (${h.length} connections)`,children:(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsxs)("div",{className:"flex flex-col",children:[(0,a.jsxs)("button",{onClick:()=>{let e=j.filter(e=>!0===e.isActive);return 0===e.length?void alert("No active proxy pools available."):t0(h.map((t,s)=>({connectionId:t.id,proxyPoolId:e[s%e.length].id})),{mode:"one-to-one"})},disabled:ek||0===t3.length,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"sync_alt"}),(0,a.jsx)("span",{className:"text-sm text-text-main",children:"One-to-one (rotate)"})]}),(0,a.jsxs)("button",{onClick:()=>t2(null),disabled:ek,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"link_off"}),(0,a.jsx)("span",{className:"text-sm text-text-main",children:"None (unbind all)"})]}),j.map(e=>(0,a.jsxs)("button",{onClick:()=>t2(e.id),disabled:ek||!0!==e.isActive,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"lan"}),(0,a.jsx)("span",{className:"truncate text-sm text-text-main",children:e.name}),!0!==e.isActive&&(0,a.jsx)("span",{className:"text-[10px] text-text-muted",children:"(inactive)"})]},e.id))]}),ek&&(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Applying..."}),(0,a.jsx)(c.$n,{onClick:tY,variant:"ghost",fullWidth:!0,disabled:ek,children:"Cancel"})]})}),t6=async e=>{if(!eh.has(e)){ef(t=>new Set(t).add(e));try{let t=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${tw}/${e}`})}),s=await t.json();ep(t=>({...t,[e]:s.ok?"ok":"error"})),ex(s.ok?"":s.error||"Model not reachable")}catch{ep(t=>({...t,[e]:"error"})),ex("Network error")}finally{ef(t=>{let s=new Set(t);return s.delete(e),s})}}};if(g)return(0,a.jsxs)("div",{className:"flex flex-col gap-8",children:[(0,a.jsx)(c.Qv,{}),(0,a.jsx)(c.Qv,{})]});if(!tn)return(0,a.jsxs)("div",{className:"text-center py-20",children:[(0,a.jsx)("p",{className:"text-text-muted",children:"Provider not found"}),(0,a.jsx)(n(),{href:"/dashboard/providers",className:"text-primary mt-4 inline-block",children:"Back to Providers"})]});let t8=()=>th&&tn.apiType?"responses"===tn.apiType?"/providers/oai-r.png":"/providers/oai-cc.png":tf?"/providers/anthropic-m.png":(0,d.HY)(tn.id);return(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-6 px-1 sm:gap-8 sm:px-0",children:[(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsxs)(n(),{href:"/dashboard/providers",className:"inline-flex items-center gap-1 text-sm text-text-muted hover:text-primary transition-colors mb-4",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-lg",children:"arrow_back"}),"Back to Providers"]}),(0,a.jsxs)("div",{className:"flex min-w-0 items-center gap-3 sm:gap-4",children:[(0,a.jsx)("div",{className:"flex size-12 shrink-0 items-center justify-center rounded-lg",style:{backgroundColor:`${tn.color}15`},children:ed||!t8()?(0,a.jsx)("span",{className:"text-sm font-bold",style:{color:tn.color},children:tn.textIcon||tn.id.slice(0,2).toUpperCase()}):(0,a.jsx)(o.A,{src:t8(),alt:tn.name,width:48,height:48,className:"max-h-12 max-w-12 rounded-lg object-contain",sizes:"48px",onError:()=>{(0,d.Kw)(tn.id),ec(!0)},loading:"lazy",decoding:"async"})}),(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3 flex-wrap",children:[(0,a.jsx)("h1",{className:"truncate text-2xl font-semibold tracking-tight sm:text-3xl",children:tn.name}),(tn.notice?.apiKeyUrl||tn.notice?.signupUrl||tn.website)&&(0,a.jsxs)("a",{href:tn.notice?.apiKeyUrl||tn.notice?.signupUrl||tn.website,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-primary hover:underline inline-flex items-center gap-1",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"open_in_new"}),tn.notice?.apiKeyUrl?"Get API Key":"Sign up / Learn more"]})]}),(0,a.jsxs)("p",{className:"text-text-muted",children:[h.length," connection",1===h.length?"":"s"]})]})]})]}),tn.deprecated&&(0,a.jsxs)("div",{className:"flex items-center gap-2 px-3 py-2 rounded-lg bg-yellow-500/10 border border-yellow-500/30",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[16px] text-yellow-500 mt-0.5 shrink-0",children:"warning"}),(0,a.jsx)("p",{className:"text-xs text-red-600 dark:text-yellow-400 leading-relaxed",children:tn.deprecationNotice})]}),tn.notice?.text&&!tn.deprecated&&(0,a.jsxs)("div",{className:"flex flex-col gap-2 rounded-lg border border-blue-500/30 bg-blue-500/10 px-3 py-2 sm:flex-row sm:items-center",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[16px] text-blue-500 shrink-0",children:"info"}),(0,a.jsx)("p",{className:"min-w-0 flex-1 text-xs leading-relaxed text-blue-600 dark:text-blue-400",children:tn.notice.text}),tn.notice.apiKeyUrl&&(0,a.jsx)("a",{href:tn.notice.apiKeyUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex justify-center rounded bg-blue-500 px-2 py-1 text-xs font-medium text-white transition-colors hover:bg-blue-600 sm:py-0.5",children:"Get API Key →"})]}),tg&&b&&(0,a.jsx)(c.Zp,{children:(0,a.jsxs)("div",{className:"mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",children:[(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold",children:tf?"Anthropic Compatible Details":"OpenAI Compatible Details"}),(0,a.jsxs)("p",{className:"break-all text-sm text-text-muted",children:[tf?"Messages API":"responses"===b.apiType?"Responses API":"Chat Completions"," \xb7 ",(b.baseUrl||"").replace(/\/$/,""),"/",tf?"messages":"responses"===b.apiType?"responses":"chat/completions"]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,a.jsx)(c.$n,{size:"sm",icon:"add",onClick:()=>{K(""),z(!0)},className:"w-full sm:w-auto",children:"Add API Key"}),(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"edit",onClick:()=>ee(!0),className:"w-full sm:w-auto",children:"Edit"}),(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"delete",onClick:async()=>{eL({title:"Delete Compatible Node",message:`Delete this ${tf?"Anthropic":"OpenAI"} Compatible node?`,onConfirm:async()=>{eL(null);try{(await fetch(`/api/provider-nodes/${u}`,{method:"DELETE"})).ok&&r.push("/dashboard/providers")}catch(e){console.log("Error deleting provider node:",e)}}})},className:"w-full sm:w-auto",children:"Delete"})]})]})}),tm?(0,a.jsx)(c.gw,{providerId:u}):(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)("div",{className:"mb-4 flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold",children:"Connections"}),(0,a.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:flex-wrap sm:items-center sm:gap-4",children:[h.length>0&&j.length>0&&(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"lan",onClick:()=>es(!0),className:"whitespace-nowrap",children:"Apply Proxy"}),h.length>0&&(0,a.jsxs)(a.Fragment,{children:[eb.length>0&&(0,a.jsxs)(c.$n,{size:"sm",variant:"danger",icon:"delete",onClick:()=>{let e=eb.length;0!==e&&eL({title:`Delete ${e} Connection${e>1?"s":""}`,message:`Delete ${e} connection${e>1?"s":""}? This cannot be undone.`,onConfirm:async()=>{eL(null);let e=0,t=[...eb];for(let s of t)try{(await fetch(`/api/providers/${s}`,{method:"DELETE"})).ok||(e+=1)}catch(t){console.log("Error deleting connection:",t),e+=1}f(e=>e.filter(e=>!t.includes(e.id))),ev([]),e>0&&alert(`Deleted ${t.length-e} connection(s), ${e} failed.`)}})},className:"whitespace-nowrap",children:["Delete Selected (",eb.length,")"]}),(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"sync",onClick:tL,disabled:eH,className:"whitespace-nowrap",children:eH?"Testing Connection One-by-One...":"Test Connection One-by-One"}),eH&&(0,a.jsx)(c.$n,{size:"sm",variant:"ghost",icon:"stop",onClick:()=>{eH&&(e5.current=!0,eV(!0))},className:"whitespace-nowrap",disabled:eQ,children:eQ?"Stopping...":"Stop"})]}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsx)("span",{className:"text-xs text-text-muted font-medium",children:"Round Robin"}),(0,a.jsx)(c.lM,{checked:"round-robin"===eC,onChange:e=>{let t=e?"round-robin":null,s=e?eA||"1":eA;e&&!eA&&eT("1"),eS(t),tD(t,s)}}),"round-robin"===eC&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("span",{className:"text-xs text-text-muted",children:"Sticky:"}),(0,a.jsx)("input",{type:"number",min:1,value:eA,onChange:e=>{var t;eT(t=e.target.value),tD("round-robin",t)},placeholder:"1",className:"w-14 px-2 py-1 text-xs border border-border rounded-md bg-background focus:outline-none focus:border-primary"})]})]})]})]}),0===h.length?(0,a.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[(0,a.jsx)("div",{className:"inline-flex items-center justify-center w-9 h-9 rounded-full bg-primary/10 text-primary shrink-0",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:td?"lock":"key"})}),(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("p",{className:"text-sm text-text-muted",children:"No connections yet"}),ty&&(0,a.jsxs)("p",{className:"text-xs text-text-muted",children:["Choose ",tb," or ",tv,"."]})]})]}),(0,a.jsx)("div",{className:"flex gap-2",children:ty?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.$n,{size:"sm",icon:"lock",variant:"secondary",onClick:ti,children:tb}),(0,a.jsx)(c.$n,{size:"sm",icon:"key",onClick:tl,children:tv})]}):(0,a.jsxs)(a.Fragment,{children:[!tg&&"iflow"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"cookie",variant:"secondary",onClick:()=>E(!0),children:"Cookie"}),"codex"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>W(!0),children:(0,S.Tl)("Bulk Add")}),"grok-cli"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>G(!0),children:(0,S.Tl)("Bulk Add")}),(0,a.jsx)(c.$n,{size:"sm",icon:"add",onClick:tr,children:tg?"Add API Key":"iflow"===u?"OAuth":"Add Connection"})]})})]}):(0,a.jsxs)(a.Fragment,{children:[e1&&(0,a.jsx)("div",{className:"mb-4 rounded-lg border border-black/10 bg-black/[0.02] px-3 py-2 text-xs text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,a.jsxs)("span",{children:["Total: ",e1.total]}),(0,a.jsxs)("span",{children:["Completed: ",e1.completed]}),(0,a.jsxs)("span",{children:["Passed: ",e1.passed]}),(0,a.jsxs)("span",{children:["Failed: ",e1.failed]}),e1.stopped&&(0,a.jsx)("span",{className:"text-amber-600 dark:text-amber-400",children:"Stopped"}),eH&&eZ&&(0,a.jsxs)("span",{children:["Running: ",h.find(e=>e.id===eZ)?.name||eZ]})]})}),h.length>0&&(0,a.jsx)("div",{className:"mb-3 flex items-center gap-2 border-b border-black/[0.03] pb-2 dark:border-white/[0.03]",children:(0,a.jsxs)("label",{className:"flex cursor-pointer items-center gap-1.5 text-xs text-text-muted hover:text-primary",children:[(0,a.jsx)("input",{type:"checkbox",checked:tX,onChange:()=>{tX?ev([]):ev(h.map(e=>e.id))},className:"h-3.5 w-3.5 rounded border-gray-300 text-primary focus:ring-primary"}),"Select All"]})}),t5,!tg&&(0,a.jsxs)("div",{className:"mt-4 grid grid-cols-1 gap-2 sm:flex",children:["iflow"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"cookie",variant:"secondary",onClick:()=>E(!0),title:"Add connection using browser cookie",className:"w-full sm:w-auto",children:"Cookie"}),"codex"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>W(!0),title:(0,S.Tl)("Bulk import codex accounts from JSON"),className:"w-full sm:w-auto",children:(0,S.Tl)("Bulk Add")}),"grok-cli"===u&&(0,a.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>G(!0),title:(0,S.Tl)("Bulk import Grok CLI accounts from JSON"),className:"w-full sm:w-auto",children:(0,S.Tl)("Bulk Add")}),ty?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.$n,{size:"sm",icon:"lock",variant:"secondary",onClick:ti,className:"w-full sm:w-auto",children:tb}),(0,a.jsx)(c.$n,{size:"sm",icon:"key",onClick:tl,className:"w-full sm:w-auto",children:tv})]}):(0,a.jsx)(c.$n,{size:"sm",icon:"add",onClick:tr,className:"w-full sm:w-auto",children:"Add"})]})]})]}),(0,a.jsx)(Z,{providerId:u}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)("div",{className:"mb-4 flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,a.jsx)("h2",{className:"text-lg font-semibold",children:"Available Models"}),tk&&(0,a.jsx)("select",{value:e$,onChange:e=>{var t;eO(t=e.target.value),tR(t)},title:"Appends (level) suffix to copied model names",className:"rounded-md border border-border bg-background px-2 py-1 text-xs focus:border-primary focus:outline-none",children:tk.map(e=>(0,a.jsx)("option",{value:e,children:`Thinking: ${e.charAt(0).toUpperCase()+e.slice(1)}`},e))})]}),!tg&&(e=[...tu,...eU.filter(e=>!tu.some(t=>t.id===e.id))].filter(e=>{let t=(0,p.CP)(e);return!t||"llm"===t}).map(e=>e.id).filter(e=>!eK.includes(e)),t=("aihorde"===u||"opencode"===u)&&eE.length>0,(0,a.jsxs)("div",{className:"flex flex-wrap gap-2",children:[t&&(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"download",onClick:tK,disabled:e6,className:"whitespace-nowrap",children:e6?"Importing...":"Import from /models"}),eK.length>0&&(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"restart_alt",onClick:t$,className:"whitespace-nowrap",children:"Active All"}),e.length>0&&(0,a.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"block",onClick:()=>tT(e),className:"whitespace-nowrap",children:"Disable All"})]}))]}),!!eu&&(0,a.jsx)("p",{className:"text-xs text-red-500 mb-3 break-words",children:eu}),"zed"===u&&!!eq&&(0,a.jsx)("p",{className:"text-xs text-red-500 mb-3 break-words",children:eq}),(()=>{let e,t,s;if(tg)return(0,a.jsx)(D,{providerStorageAlias:tw,providerDisplayAlias:tN,modelAliases:el,customModels:en,copied:te,onCopy:tt,onSetAlias:tq,onDeleteAlias:t_,onAddCustomModel:(e,t)=>tU(e,"llm",tw,t),onDeleteCustomModel:e=>tM(e,"llm",tw),connections:h,isAnthropic:tf});let i=[...tu,...eU.filter(e=>!tu.some(t=>t.id===e.id))].filter(e=>{let t=(0,p.CP)(e);return!t||"llm"===t}),l=new Set(eK),r=i.filter(e=>!l.has(e.id)),n=i.filter(e=>l.has(e.id)),o=(0,$.R)({customModels:en,modelAliases:el,providerAlias:tw,builtInModels:tu,type:"llm"});return(0,a.jsxs)("div",{className:"flex flex-wrap gap-3",children:[o.map(e=>(0,a.jsx)(P,{model:{id:e.id,name:e.name},fullModel:`${tN}/${e.id}`,alias:e.alias,copied:te,onCopy:tt,onSetAlias:()=>{},onDeleteAlias:()=>{"custom"===e.source?tM(e.id,"llm",tw):t_(e.alias)},testStatus:em[e.id],onTest:h.length>0||tm?()=>t6(e.id):void 0,isTesting:eh.has(e.id),isCustom:!0,isFree:!1,caps:e.caps||x(`${tw}/${e.id}`),thinkingSuffix:tj(e.id)},`${e.source}-${e.fullModel}`)),r.map(e=>{let t=`${tw}/${e.id}`,s=`${u}/${e.id}`,i=Object.entries(el).find(([,e])=>e===t||e===s)?.[0];return(0,a.jsx)(P,{model:e,fullModel:`${tN}/${e.id}`,alias:i,copied:te,onCopy:tt,onSetAlias:t=>tq(e.id,t,tw),onDeleteAlias:()=>t_(i),testStatus:em[e.id],onTest:h.length>0||tm?()=>t6(e.id):void 0,isTesting:eh.has(e.id),isFree:e.isFree,onDisable:()=>tS(e.id),caps:x(`${u}/${e.id}`),thinkingSuffix:tj(e.id)},e.id)}),(0,a.jsxs)("button",{onClick:()=>ey(!0),className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-primary/40 px-3 py-2 text-xs text-primary transition-colors hover:border-primary hover:bg-primary/5 sm:w-auto",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",children:"add"}),"Add Model"]}),("qoder"===u||"qoder-cn"===u)&&h.some(e=>!1!==e.isActive)&&(0,a.jsxs)("button",{onClick:tF,disabled:e3,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-blue-500/40 px-3 py-2 text-xs text-blue-600 dark:text-blue-400 transition-colors hover:border-blue-500 hover:bg-blue-500/5 sm:w-auto disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",style:e3?{animation:"spin 1s linear infinite"}:void 0,children:e3?"progress_activity":"download"}),e3?(0,S.Tl)("Fetching..."):(0,S.Tl)("Fetch Qoder Models")]}),("cline"===u||"clinepass"===u)&&h.some(e=>!1!==e.isActive)&&(0,a.jsxs)("button",{onClick:tJ,disabled:e7,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-blue-500/40 px-3 py-2 text-xs text-blue-600 dark:text-blue-400 transition-colors hover:border-blue-500 hover:bg-blue-500/5 sm:w-auto disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-sm",style:e7?{animation:"spin 1s linear infinite"}:void 0,children:e7?"progress_activity":"download"}),e7?(0,S.Tl)("Fetching..."):(0,S.Tl)("Import from /models")]}),eE.length>0&&(e=new Set([...Object.values(el),...o.map(e=>e.fullModel)]),t=new Set(tu.map(e=>e.id)),0===(s=eE.filter(s=>!e.has(`${tw}/${s.id}`)&&!t.has(s.id))).length?null:(0,a.jsxs)("div",{className:"w-full mt-2",children:[(0,a.jsx)("p",{className:"text-xs text-text-muted mb-2",children:"Suggested free models (≥200k context):"}),(0,a.jsx)("div",{className:"flex flex-wrap gap-2",children:s.map(e=>(0,a.jsxs)("button",{onClick:async()=>{await tU(e.id,"llm",tw,e.caps)},className:"flex items-center gap-1 px-2.5 py-1.5 rounded-lg border border-black/10 dark:border-white/10 text-xs text-text-muted hover:text-primary hover:border-primary/40 hover:bg-primary/5 transition-colors",title:e.contextLength?`${e.name} \xb7 ${(e.contextLength/1e3).toFixed(0)}k ctx`:e.name,children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[13px]",children:"add"}),e.id.split("/").pop()]},e.id))})]})),n.length>0&&(0,a.jsxs)("div",{className:"w-full mt-2",children:[(0,a.jsxs)("p",{className:"text-xs text-text-muted mb-2",children:["Disabled models (",n.length,"):"]}),(0,a.jsx)("div",{className:"flex flex-wrap gap-2",children:n.map(e=>(0,a.jsxs)("button",{onClick:()=>tA(e.id),className:"flex items-center gap-1 px-2.5 py-1.5 rounded-lg border border-dashed border-black/10 dark:border-white/10 text-xs text-text-muted hover:text-primary hover:border-primary/40 hover:bg-primary/5 transition-colors",title:"Restore model",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[13px]",children:"add"}),e.id]},e.id))})]})]})})()]}),t4,"kiro"===u?(0,a.jsx)(c.Mh,{isOpen:A,providerInfo:tn,onSuccess:tB,onClose:()=>O(!1)}):"cursor"===u?(0,a.jsx)(c.G9,{isOpen:A,onSuccess:tB,onClose:()=>O(!1)}):"zed"===u?(0,a.jsx)(c.TE,{isOpen:A,providerInfo:tn,onSuccess:tB,onClose:()=>O(!1)}):"gitlab"===u?(0,a.jsx)(c.vj,{isOpen:A,providerInfo:tn,onSuccess:tB,onClose:()=>O(!1)}):(0,a.jsx)(c.LF,{isOpen:A,provider:u,providerInfo:tn,onSuccess:tB,onClose:()=>O(!1)}),"iflow"===u&&(0,a.jsx)(c.vE,{isOpen:I,onSuccess:()=>{tP(),E(!1)},onClose:()=>E(!1)}),(0,a.jsx)(U,{isOpen:R,provider:u,providerName:tn.name,isCompatible:tg,isAnthropic:tf,authType:tn?.authType,authHint:tn?.authHint,website:tn?.website,proxyPools:j,error:_,existingNames:h.map(e=>e.name).filter(Boolean),onSave:tH,onBulkDone:tP,onClose:()=>{K(""),z(!1)}}),(0,a.jsx)(c.wI,{isOpen:Q,connection:ea,proxyPools:j,onSave:tG,onClose:()=>V(!1)}),tg&&(0,a.jsx)(M,{isOpen:Y,node:b,onSave:tE,onClose:()=>ee(!1),isAnthropic:tf}),!tg&&(0,a.jsx)(F,{isOpen:eg,providerAlias:tw,providerDisplayAlias:tN,onSave:async(e,t,s)=>{await tU(e,t?.stt?"stt":"llm",tw,t,s),ey(!1)},onClose:()=>ey(!1)}),"codex"===u&&(0,a.jsx)(L,{isOpen:J,onClose:()=>W(!1),onSuccess:tP}),"grok-cli"===u&&(0,a.jsx)(H,{isOpen:B,onClose:()=>G(!1),onSuccess:tP}),(0,a.jsx)(c.uo,{isOpen:eW,onClose:()=>eB(!1),onConfirm:()=>{(window.localStorage.setItem(ts,"true"),eB(!1),td)?ta():tl()},title:"Risk Notice",message:tn?.deprecationNotice,confirmText:"I Understand, Continue",cancelText:"Cancel",variant:"danger"}),(0,a.jsx)(c.uo,{isOpen:!!eJ,onClose:()=>eL(null),onConfirm:eJ?.onConfirm,title:eJ?.title||"Confirm",message:eJ?.message,variant:"danger"})]})}},70217:(e,t,s)=>{"use strict";function a(e,t){return!1===e?"default":"active"===t||"success"===t?"success":"error"===t||"expired"===t||"unavailable"===t?"error":"default"}s.d(t,{g:()=>a})},82837:(e,t,s)=>{Promise.resolve().then(s.bind(s,56828))}},e=>{e.O(0,[763,5772,8105,620,705,5497,8441,3794,7358],()=>e(e.s=82837)),_N_E=e.O()}]);
|
package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-06427d5637ff9cb2.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3826],{63818:(e,t,r)=>{Promise.resolve().then(r.bind(r,75095)),Promise.resolve().then(r.bind(r,25086))},75095:(e,t,r)=>{"use strict";r.d(t,{default:()=>R});var a=r(95155),i=r(12115),s=r(73321),n=r(57250),l=r(13097);let o="quotaCacheData",d="quotaAutoRefresh",c=[10,20,50,100],u=[{value:"all",label:"All accounts"},{value:"active",label:"Active"},{value:"inactive",label:"Turned off"}],m=[{value:"default",label:"Default quota order"},{value:"remaining-asc",label:"% quota: low to high"},{value:"remaining-desc",label:"% quota: high to low"}];function x(e){return e.name?.trim()||e.email?.trim()||e.displayName?.trim()||null}function h(e,t){let r=t[e.id]?.quotas?.[0];return r&&"number"==typeof r.remaining?r.remaining:1/0}function p(e){let t={};return e.forEach(e=>{t[e.id]=!0}),t}function b(e,t){let r=new Set(t.map(e=>e.id));return Object.fromEntries(Object.entries(e).filter(([e])=>r.has(e)))}async function g(e,t){return await e(t)}function f(){try{let e=window.localStorage.getItem(o);return e?JSON.parse(e):{}}catch(e){return console.error("Error reading quota cache:",e),{}}}function y(e,t){try{let r=f();r[e]={...t,cachedAt:new Date().toISOString()},window.localStorage.setItem(o,JSON.stringify(r))}catch(e){console.error("Error writing quota cache:",e)}}function w(e,t){return t&&0!==t?!e||e<0?100:e>=t?0:Math.round((t-e)/t*100):0}function k(e){return e&&"object"==typeof e?String(e.modelKey||e.name||"").trim():""}function v(e,t,r=[]){let a=t?.[e]?.hidden;return Array.isArray(a)&&0!==a.length?new Set((r.length>0?function(e=[],t=[]){if(!Array.isArray(e)||0===e.length)return[];let r=new Set(t.map(k).filter(Boolean));return[...new Set(e.map(e=>String(e).trim()).filter(e=>r.has(e)))]}(a,r):a).map(String)):new Set}function j({quotas:e=[],compact:t=!1,sortMode:r="default",showSortLabel:s=!1,onHideQuota:n=null}){let[l,o]=(0,i.useState)(1),d=(0,i.useMemo)(()=>e.map((e,t)=>({...e,index:t,remaining:e?.remaining!==void 0?Math.max(0,Math.round(e.remaining)):e?.remainingPercentage!==void 0?Math.round(e.remainingPercentage):w(e?.used,e?.total)})),[e]),c=(0,i.useMemo)(()=>"remaining-asc"===r?[...d].sort((e,t)=>e.remaining-t.remaining||e.name.localeCompare(t.name)):"remaining-desc"===r?[...d].sort((e,t)=>t.remaining-e.remaining||e.name.localeCompare(t.name)):d,[d,r]),u=Math.max(1,Math.ceil(c.length/10));if((0,i.useEffect)(()=>{o(1)},[r,e]),(0,i.useEffect)(()=>{o(e=>Math.min(e,u))},[u]),!e||0===e.length)return null;let m=c.slice((l-1)*10,10*l),x=0===c.length?0:(l-1)*10+1,h=Math.min(10*l,c.length),p=t?"py-1 px-1.5":"py-2 px-3",b=t?"text-[11px]":"text-sm",g=t?"text-[11px]":"text-sm",f=t?"text-[10px] leading-tight":"text-xs",y="function"==typeof n;return(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,a.jsxs)("div",{className:"text-[10px] text-text-muted",children:[c.length," quota",c.length>1?"s":""]}),s&&(0,a.jsx)("div",{className:"rounded-md border border-black/10 bg-black/[0.02] px-2 py-1 text-[10px] text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:"Sorted by account remaining"})]}),(0,a.jsx)("div",{className:"space-y-px",children:m.map(e=>{var r;let i=!0===e.unlimited,s=!0===e.isCreditBalance,l=s?{text:"text-blue-600 dark:text-blue-400",bg:"bg-blue-500",bgLight:"bg-blue-500/10",emoji:"\uD83D\uDCB0"}:(r=e.remaining)>70?{text:"text-green-600 dark:text-green-400",bg:"bg-green-500",bgLight:"bg-green-500/10",emoji:"\uD83D\uDFE2"}:r>=30?{text:"text-yellow-600 dark:text-yellow-400",bg:"bg-yellow-500",bgLight:"bg-yellow-500/10",emoji:"\uD83D\uDFE1"}:{text:"text-red-600 dark:text-red-400",bg:"bg-red-500",bgLight:"bg-red-500/10",emoji:"\uD83D\uDD34"},o=function(e){if(!e)return"-";try{let t="string"==typeof e?new Date(e):e,r=new Date,a=t-r;if(a<=0)return"-";let i=Math.ceil(a/6e4);if(i<60)return`${i}m`;let s=Math.floor(i/60),n=i%60;if(s<24)return`${s}h ${n}m`;let l=Math.floor(s/24);return`${l}d ${s%24}h ${n}m`}catch(e){return"-"}}(e.resetAt),d=function(e){if(!e)return null;try{let t=new Date(e),r=new Date,a=new Date(r.getFullYear(),r.getMonth(),r.getDate()),i=new Date(a);i.setDate(i.getDate()+1);let s="";s=t>=a&&t<i?"Today":t>=i&&t<new Date(i.getTime()+864e5)?"Tomorrow":t.toLocaleDateString("en-US",{month:"short",day:"numeric"});let n=t.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit",hour12:!0});return`${s}, ${n}`}catch{return null}}(e.resetAt),c=!1!==e.recurring?`in ${o}`:`expires in ${o}`;return(0,a.jsxs)("div",{className:`flex items-center gap-2 border-b border-black/5 dark:border-white/5 hover:bg-black/[0.02] dark:hover:bg-white/[0.02] transition-colors ${p}`,children:[(0,a.jsxs)("div",{className:"flex w-36 min-w-0 items-center gap-1.5",children:[(0,a.jsx)("span",{className:"text-[10px] shrink-0",children:l.emoji}),(0,a.jsx)("div",{className:"min-w-0",children:(0,a.jsx)("div",{className:`${b} font-medium text-text-primary truncate`,children:e.name})})]}),(0,a.jsxs)("div",{className:`min-w-0 flex-1 ${t?"space-y-1":"space-y-1.5"}`,children:[!i&&!s&&(0,a.jsx)("div",{className:`${t?"h-1":"h-1.5"} rounded-full overflow-hidden border ${l.bgLight} ${0===e.remaining?"border-black/10 dark:border-white/10":"border-transparent"}`,children:(0,a.jsx)("div",{className:`h-full transition-all duration-300 ${l.bg}`,style:{width:`${Math.min(e.remaining,100)}%`}})}),(0,a.jsxs)("div",{className:`flex items-center justify-between gap-1 min-w-0 ${t?"text-[10px]":"text-xs"}`,children:[(0,a.jsx)("span",{className:"text-text-muted truncate",title:i?`${e.used.toLocaleString()} used \xb7 Unlimited`:s?`Credit balance: ${e.total.toFixed(2)} ${e.currency||""}`:`${e.used.toLocaleString()} / ${e.total>0?e.total.toLocaleString():"∞"}`,children:i?`${e.used.toLocaleString()} used \xb7 Unlimited`:s?`Credit: ${e.total.toFixed(2)} ${e.currency||""}`:`${e.used.toLocaleString()} / ${e.total>0?e.total.toLocaleString():"∞"}`}),(0,a.jsx)("span",{className:`font-medium ${i?"text-green-600 dark:text-green-400":s?"text-blue-600 dark:text-blue-400":l.text} shrink-0`,children:i?"Unlimited":s?"":`${e.remaining}%`})]})]}),(0,a.jsx)("div",{className:"min-w-0 shrink",children:"-"!==o||d?t?(0,a.jsx)("div",{className:`${g} text-text-primary font-medium truncate`,title:d||"",children:"-"!==o?c:d}):(0,a.jsxs)("div",{className:"min-w-0 space-y-0.5",children:["-"!==o&&(0,a.jsx)("div",{className:`${g} text-text-primary font-medium truncate`,children:c}),d&&(0,a.jsx)("div",{className:`${f} text-text-muted truncate`,children:d})]}):(0,a.jsx)("div",{className:`${g} text-text-muted italic`,children:"N/A"})}),y&&(0,a.jsx)("button",{type:"button",onClick:()=>n(e),className:"inline-flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-text-muted transition-colors hover:bg-black/5 hover:text-text-primary dark:hover:bg-white/5",title:"Hide this quota row","aria-label":`Hide quota ${e.name}`,children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[15px]",children:"visibility_off"})})]},`${e.name}-${e.index}`)})}),u>1&&(0,a.jsxs)("div",{className:"rounded-md border border-black/10 bg-black/[0.02] px-2 py-1.5 dark:border-white/10 dark:bg-white/[0.03]",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between gap-2 text-[10px] text-text-muted",children:[(0,a.jsxs)("span",{children:["Showing ",x,"-",h," of ",c.length]}),(0,a.jsxs)("span",{children:["Page ",l," / ",u]})]}),(0,a.jsxs)("div",{className:"mt-1.5 flex items-center justify-end gap-1",children:[(0,a.jsx)("button",{type:"button",onClick:()=>o(e=>Math.max(1,e-1)),disabled:1===l,className:"flex h-6 items-center rounded-md border border-black/10 px-2 text-[10px] text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5",children:"Prev"}),(0,a.jsx)("button",{type:"button",onClick:()=>o(e=>Math.min(u,e+1)),disabled:l===u,className:"flex h-6 items-center rounded-md border border-black/10 px-2 text-[10px] text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5",children:"Next"})]})]})]})}var N=r(98542),C=r(97677),A=r(84588),S=r(35497),$=r(88105),P=r(11059);let q={"builder-id":"AWS Builder ID",idc:"IAM Identity Center",google:"Google",github:"GitHub",imported:"Imported Token",api_key:"API Key"},E={claude:"claudeAutoPing",codex:"codexAutoPing"},_={claude:"When your 5h quota runs out, auto-sends a request the moment it resets so a new window starts right away.",codex:"Auto-starts the next 5h Codex window after reset by sending a tiny gpt-5.5 request. Consumes a small amount of quota."};function T(e){return e.name?.trim()&&e.email?.trim()&&e.name.trim()!==e.email.trim()?e.email.trim():e.name?.trim()&&e.displayName?.trim()&&e.name.trim()!==e.displayName.trim()?e.displayName.trim():null}function D(e){let t=e.providerSpecificData?.region;if(t)return t;let r=e.providerSpecificData?.profileArn;return("string"==typeof r?r.split(":")[3]:"")||""}let O={five_hour:"session",seven_day:"weekly",seven_day_overage_included:"weekly",seven_day_opus:"Opus weekly",seven_day_sonnet:"Sonnet weekly"};function M(e){let t=[...new Set((e||[]).map(e=>O[e]).filter(Boolean))];return t.length?`${t.join(" + ")} limits`:"limits"}function L(e){return $.Q2[e]?.name||e}function I(e){if(!e)return"N/A";let t=new Date(e);return Number.isFinite(t.getTime())?t.toLocaleString(void 0,{month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit"}):"N/A"}function F(e){if(!e)return"N/A";let t=new Date(e).getTime()-Date.now();if(!Number.isFinite(t))return"N/A";if(t<=0)return"Expired";let r=Math.ceil(t/36e5),a=Math.floor(r/24),i=r%24;return a>0?`${a}d ${i}h`:`${i}h`}function R(){let{copied:e,copy:t}=(0,P.C)(),r=(0,s.useSearchParams)(),O=(0,s.useRouter)(),R=(0,s.usePathname)(),[z,U]=(0,i.useState)([]),[W,B]=(0,i.useState)({}),[J,K]=(0,i.useState)({}),[H,G]=(0,i.useState)({}),[V,Q]=(0,i.useState)(!0),[Y,X]=(0,i.useState)({claude:{},codex:{}}),[Z,ee]=(0,i.useState)(null),[et,er]=(0,i.useState)(!1),[ea,ei]=(0,i.useState)(!1),[es,en]=(0,i.useState)(60),[el,eo]=(0,i.useState)(!0),[ed,ec]=(0,i.useState)(null),[eu,em]=(0,i.useState)(null),[ex,eh]=(0,i.useState)(null),[ep,eb]=(0,i.useState)(null),[eg,ef]=(0,i.useState)(null),[ey,ew]=(0,i.useState)(!1),[ek,ev]=(0,i.useState)(null),[ej,eN]=(0,i.useState)([]),[eC,eA]=(0,i.useState)(()=>r?.get("provider")||"all"),eS=(0,i.useCallback)(e=>{eA(e);try{let t=new URLSearchParams(r?.toString()||"");"all"===e?t.delete("provider"):t.set("provider",e);let a=t.toString()?`${R}?${t.toString()}`:R;O.replace(a,{scroll:!1})}catch{}},[R,O,r]),[e$,eP]=(0,i.useState)([]),[eq,eE]=(0,i.useState)("all"),[e_,eT]=(0,i.useState)("default"),[eD,eO]=(0,i.useState)({}),[eM,eL]=(0,i.useState)(!1),[eI,eF]=(0,i.useState)(!1),[eR,ez]=(0,i.useState)(!1),[eU,eW]=(0,i.useState)(1),[eB,eJ]=(0,i.useState)(20),[eK,eH]=(0,i.useState)(String(20)),[eG,eV]=(0,i.useState)({page:1,pageSize:20,total:0,totalPages:1}),[eQ,eY]=(0,i.useState)({eligibleConnections:0,providerFilteredConnections:0}),eX=(0,i.useRef)(null),eZ=(0,i.useRef)(null),e0=(0,i.useRef)(0),e1=(0,i.useCallback)(async(e=eU)=>{try{var t,r;let a=new URLSearchParams({page:String(e),pageSize:String(eB),accountStatus:eq,sort:"priority"});"all"!==eC&&a.set("provider",eC);let i=await fetch(`/api/providers/client?${a.toString()}`);if(!i.ok)throw Error("Failed to fetch connections");let s=await i.json(),n=s.connections||[],l=(t=s.pagination,t||{page:1,pageSize:eB,total:0,totalPages:1}),o=function(e,t=0){return e||{eligibleConnections:t,providerFilteredConnections:t}}(s.totals,n.length);return U(n),eP(s.providerOptions||[]),eV(l),eY(o),eW((r=s.pagination,r?.page||e)),n}catch(e){return console.error("Error fetching connections:",e),U([]),eP([]),eV({page:1,pageSize:eB,total:0,totalPages:1}),eY({eligibleConnections:0,providerFilteredConnections:0}),[]}},[eq,eM,eU,eB,eC]),e5=(0,i.useCallback)(async(e,t,{force:r=!1}={})=>{K(t=>({...t,[e]:!0})),G(t=>({...t,[e]:null}));try{console.log(`[ProviderLimits] Fetching quota for ${t} (${e})`);let a=`/api/usage/${e}${r?"?force=1":""}`,i=await fetch(a);if(!i.ok){let r=(await i.json().catch(()=>({}))).error||i.statusText;if(404===i.status)return void console.warn(`[ProviderLimits] Connection not found for ${t}, skipping`);if(401===i.status){console.warn(`[ProviderLimits] Auth error for ${t}:`,r);let a={quotas:[],message:r};B(t=>({...t,[e]:a})),y(e,a);return}throw Error(`HTTP ${i.status}: ${r}`)}let s=await i.json();console.log(`[ProviderLimits] Got quota for ${t}:`,s);let n={quotas:function(e,t){if(!t||"object"!=typeof t)return[];let r=[];try{switch(e.toLowerCase()){case"github":default:t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null})});break;case"antigravity":if(t.quotas){let e=Object.entries(t.quotas),a=new Set(["gemini_weekly","claude_gpt_weekly"]),i=new Set(["gemini_session","claude_gpt_session"]),s=new Set([...a,...i]),n=e.filter(([e])=>e.startsWith("gemini-")&&!e.includes("image")),l=e.filter(([e])=>e.startsWith("claude-")),o=e.filter(([e])=>e.includes("image")),d=e.filter(([e])=>s.has(e)),c=e.filter(([e])=>!e.startsWith("gemini-")&&!e.startsWith("claude-")&&!e.includes("image")&&!s.has(e)),u=!!t.quotas.gemini_weekly,m=!!t.quotas.gemini_session,x=!!t.quotas.claude_gpt_weekly,h=!!t.quotas.claude_gpt_session;if(m)d.filter(([e])=>"gemini_session"===e).forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});else if(n.length>0){let e=n.reduce((e,t)=>(t[1].remainingPercentage??100)<(e[1].remainingPercentage??100)?t:e)[1],a=t.quotas.gemini_weekly?.resetAt;u&&e.resetAt===a&&(e.remainingPercentage??0)===0||r.push({name:"Gemini (Flash / Pro)",modelKey:"gemini",used:e.used||0,total:e.total||0,resetAt:e.resetAt||null,remainingPercentage:e.remainingPercentage})}if(u&&d.filter(([e])=>"gemini_weekly"===e).forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})}),h)d.filter(([e])=>"claude_gpt_session"===e).forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});else if(l.length>0){let e=l.reduce((e,t)=>(t[1].remainingPercentage??100)<(e[1].remainingPercentage??100)?t:e)[1],a=t.quotas.claude_gpt_weekly?.resetAt;x&&e.resetAt===a&&(e.remainingPercentage??0)===0||r.push({name:"Claude (Sonnet / Opus)",modelKey:"claude",used:e.used||0,total:e.total||0,resetAt:e.resetAt||null,remainingPercentage:e.remainingPercentage})}x&&d.filter(([e])=>"claude_gpt_weekly"===e).forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})}),o.forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})}),x||h||c.forEach(([e,t])=>{r.push({name:t.displayName||e,modelKey:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})})}break;case"codex":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{let a=e;"spark_session"===e?a="Spark (5h)":"spark_weekly"===e?a="Spark (Weekly)":"session"===e?a="5h":"weekly"===e?a="Weekly":"review_session"===e?a="Review (5h)":"review_weekly"===e&&(a="Review (Weekly)"),r.push({name:a,quotaType:e,used:t.used||0,total:t.total||0,remaining:t.remaining,resetAt:t.resetAt||null})});break;case"kiro":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null})});break;case"qoder":case"qoder-cn":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{("organization"!==e||t&&0!==(Number(t.total)||0))&&r.push({name:"user"===e?"Personal":"organization"===e?"Organization":e,used:t.used||0,total:t.total||0,unit:t.unit,resetAt:t.resetAt||null})});break;case"claude":t.message?r.push({name:"error",used:0,total:0,resetAt:null,message:t.message}):t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,remaining:void 0!==t.remaining?t.remaining:Math.max(0,(t.total||100)-(t.used||0)),remainingPercentage:void 0!==t.remainingPercentage?t.remainingPercentage:w(t.used,t.total),resetAt:t.resetAt||null})});break;case"vercel-ai-gateway":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});break;case"codebuddy-cn":case"codebuddy-intl":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,recurring:!1!==t.recurring})});break;case"grok-cli":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});break;case"kimi":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});break;case"deepseek":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage,isCreditBalance:t.isCreditBalance??!0,currency:t.currency||(e.includes("(")?e.slice(e.indexOf("(")+1,e.indexOf(")")):"USD")})});break;case"groq":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null})});break;case"ollama":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage})});break;case"zed":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,resetAt:t.resetAt||null,remainingPercentage:t.remainingPercentage,unlimited:t.unlimited})});break;case"minimax-code":case"minimax-code-global":t.quotas&&Object.entries(t.quotas).forEach(([e,t])=>{r.push({name:e,used:t.used||0,total:t.total||0,remaining:t.remaining,remainingPercentage:t.remainingPercentage,resetAt:t.resetAt||null,message:t.message,isCreditBalance:t.isCreditBalance,currency:t.currency})})}}catch(t){return console.error(`Error parsing quota data for ${e}:`,t),[]}if(e?.toLowerCase()==="claude"){let e={"session (5h)":0,"weekly (7d)":1,"weekly fable (7d)":2,"weekly opus (7d)":3,"weekly sonnet (7d)":4};return r.sort((t,r)=>(e[t.name]??99)-(e[r.name]??99)),r}let a=(0,l.KC)(e);if(a.length>0){let e=new Map(a.map((e,t)=>[e.id,t]));r.sort((t,r)=>{let a=t.modelKey||t.name,i=r.modelKey||r.name;return("gemini"===a||"gemini_session"===a)&&(a="gemini-3.8-flash-high"),("claude"===a||"claude_gpt_session"===a)&&(a="claude-sonnet-4-6"),("gemini"===i||"gemini_session"===i)&&(i="gemini-3.8-flash-high"),("claude"===i||"claude_gpt_session"===i)&&(i="claude-sonnet-4-6"),(e.get(a)??999)-(e.get(i)??999)})}return r}(t,s),plan:s.plan||null,message:s.message||null,raw:s};B(t=>({...t,[e]:n})),y(e,n)}catch(r){console.error(`[ProviderLimits] Error fetching quota for ${t} (${e}):`,r),G(t=>({...t,[e]:r.message||"Failed to fetch quota"}))}finally{K(t=>({...t,[e]:!1}))}},[]),e2=(0,i.useCallback)(async(e,t)=>{await e5(e,t,{force:!0}),ee(new Date)},[e5]),e3=(0,i.useCallback)(async(e,t)=>{if(("codex"===t||"claude"===t)&&!ex){eh(e),G(t=>({...t,[e]:null}));try{let r="claude"===t?await fetch(`/api/usage/${e}/claude-reset`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({grantId:W[e]?.raw?.resetCredits?.nextGrantId})}):await fetch(`/api/usage/${e}/codex-reset-credits`,{method:"POST"}),a=await r.json().catch(()=>({}));if(!r.ok)throw Error(a.message||a.error||a.code||"Failed to reset limit");await e5(e,t,{force:!0}),ee(new Date)}catch(t){G(r=>({...r,[e]:t.message||"Failed to reset limit"}))}finally{eh(null)}}},[e5,ex,W]),e4=(0,i.useCallback)((e,t)=>{ef({connection:e,loading:!1,error:null,data:{kind:"claude",...t}})},[]),e8=(0,i.useCallback)(async e=>{ef({connection:e,loading:!0,error:null,data:null});try{let t=await fetch(`/api/usage/${e.id}/codex-reset-credits`,{cache:"no-store"}),r=await t.json().catch(()=>({}));if(!t.ok)throw Error(r.error||r.message||"Failed to load Codex reset credits");let a=Array.isArray(r.credits)?[...r.credits]:[];a.sort((e,t)=>(e.expiresAt?new Date(e.expiresAt).getTime():1/0)-(t.expiresAt?new Date(t.expiresAt).getTime():1/0)),ef({connection:e,loading:!1,error:null,data:{...r,credits:a}})}catch(t){ef({connection:e,loading:!1,error:t.message||"Failed to load Codex reset credits",data:null})}},[]),e6=(0,i.useCallback)(async e=>{if(confirm("Delete this connection?")){ec(e);try{if((await fetch(`/api/providers/${e}`,{method:"DELETE"})).ok){B(t=>{let r={...t};return delete r[e],r}),K(t=>{let r={...t};return delete r[e],r}),G(t=>{let r={...t};return delete r[e],r});try{let t=f();t[e]&&(delete t[e],window.localStorage.setItem(o,JSON.stringify(t)))}catch(e){console.error("Error deleting cache entry:",e)}await g(e1,eU)}}catch(e){console.error("Error deleting connection:",e)}finally{ec(null)}}},[e1,eU]),e7=(0,i.useCallback)(async(e,t)=>{em(e);try{(await fetch(`/api/providers/${e}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:t})})).ok&&(B(e=>({...e})),await g(e1,eU))}catch(e){console.error("Error updating connection status:",e)}finally{em(null)}},[e1,eU]),e9=(0,i.useCallback)(async e=>{if(!ek?.id)return;let t=ek.id,r=ek.provider;try{(await fetch(`/api/providers/${t}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok&&(await e1(),ew(!1),ev(null),$.wb.includes(r)&&await e5(t,r))}catch(e){console.error("Error saving connection:",e)}},[ek,e1,e5]);(0,i.useEffect)(()=>{let e=!1;return fetch("/api/proxy-pools?isActive=true",{cache:"no-store"}).then(e=>e.json()).then(t=>{!e&&t?.proxyPools&&eN(t.proxyPools)}).catch(()=>{}),()=>{e=!0}},[]);let te=(0,i.useCallback)(async(e=!1)=>{if(ea)return;ei(!0),en(60);let t=e0.current+=1;try{let r=await e1(eU);K(p(r)),G(e=>b(e,r)),B(e=>b(e,r)),await Promise.all(r.filter(r=>e||"claude"!==r.provider||t%10==0).map(e=>e5(e.id,e.provider))),ee(new Date)}catch(e){console.error("Error refreshing all providers:",e)}finally{ei(!1)}},[ea,e1,e5,eU]);(0,i.useEffect)(()=>{(async()=>{eo(!0);let e=await e1(eU);eo(!1),K(p(e)),G(t=>b(t,e)),B(t=>b(t,e)),await Promise.all(e.map(e=>e5(e.id,e.provider))),ee(new Date)})()},[e1,e5,eU]),(0,i.useEffect)(()=>{let e=window.localStorage.getItem(d);Q(null===e||"true"===e),er(!0)},[]),(0,i.useEffect)(()=>{et&&window.localStorage.setItem(d,String(V))},[V,et]),(0,i.useEffect)(()=>{fetch("/api/settings",{cache:"no-store"}).then(e=>e.ok?e.json():{}).then(e=>{X({claude:e?.claudeAutoPing?.connections||{},codex:e?.codexAutoPing?.connections||{}}),eO(e?.quotaVisibility||{})}).catch(()=>{})},[]);let tt=(0,i.useCallback)(async(e,t,r)=>{let a=E[t];if(!a)return;let i={...Y[t]||{},[e]:r};X({...Y,[t]:i});try{let e=await fetch("/api/settings",{cache:"no-store"}),t={...(e.ok?await e.json():{})[a]||{},connections:i};await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({[a]:t})})}catch{X(Y)}},[Y]),tr=(0,i.useCallback)(async(e,t)=>{eO(e);try{if(!(await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({quotaVisibility:e})})).ok)throw Error("Failed to update quota visibility")}catch(e){console.error("Error updating quota visibility:",e),eO(t)}},[]),ta=(0,i.useCallback)((e,t)=>{let r=k(t);if(!e||!r)return;let a=eD[e]||{},i=new Set(a.hidden||[]);if(i.add(r),"antigravity"===e){if("gemini"===r)for(let e of i)e.startsWith("gemini-")&&!e.includes("image")&&i.delete(e);else if("claude"===r)for(let e of i)e.startsWith("claude-")&&i.delete(e)}tr({...eD,[e]:{...a,hidden:[...i]}},eD)},[eD,tr]),ti=(0,i.useCallback)((e,t)=>{let r=k(t);if(!e||!r)return;let a=eD[e]||{},i=new Set(a.hidden||[]);if(i.delete(r),"antigravity"===e){if("gemini"===r)for(let e of i)e.startsWith("gemini-")&&!e.includes("image")&&i.delete(e);else if("claude"===r)for(let e of i)e.startsWith("claude-")&&i.delete(e)}tr({...eD,[e]:{...a,hidden:[...i]}},eD)},[eD,tr]);(0,i.useEffect)(()=>{if(!et||!V){eX.current&&(clearInterval(eX.current),eX.current=null),eZ.current&&(clearInterval(eZ.current),eZ.current=null);return}return eX.current=setInterval(()=>{te()},6e4),eZ.current=setInterval(()=>{en(e=>e<=1?60:e-1)},1e3),()=>{eX.current&&clearInterval(eX.current),eZ.current&&clearInterval(eZ.current)}},[V,te,et]),(0,i.useEffect)(()=>{let e=()=>{document.hidden?(eX.current&&(clearInterval(eX.current),eX.current=null),eZ.current&&(clearInterval(eZ.current),eZ.current=null)):V&&et&&(eX.current=setInterval(()=>te(),6e4),eZ.current=setInterval(()=>{en(e=>e<=1?60:e-1)},1e3))};return document.addEventListener("visibilitychange",e),()=>{document.removeEventListener("visibilitychange",e)}},[V,te,et]);let ts=(0,i.useMemo)(()=>(function(e,t,r,a,i){if("codex"===a&&"default"!==i)return[...e].sort((e,r)=>{let a=h(e,t),s=h(r,t),n="remaining-asc"===i?a-s:s-a;return 0!==n?n:(x(e)||"").localeCompare(x(r)||"")});if(!r){let t=new Map;for(let r of e){let e=r.provider||"";t.has(e)||t.set(e,[]),t.get(e).push(r)}return Array.from(t.values()).flat()}let s=e=>{let r=(t[e.id]?.quotas||[]).map(e=>e.resetAt?new Date(e.resetAt).getTime():1/0).filter(e=>Number.isFinite(e));return r.length>0?Math.min(...r):1/0};return[...e].sort((e,t)=>{let r=s(e)-s(t);return 0!==r?r:(e.provider||"").localeCompare(t.provider||"")||(x(e)||"").localeCompare(x(t)||"")})})(z,W,eM,eC,e_),[z,W,eM,eC,e_]),tn=e=>{let t=W[e.id]?.quotas;return!!t?.length&&t.some(e=>!!e.total&&!(e.total<=0)&&5>=w(e.used,e.total))},tl=(0,i.useCallback)(async(e,t)=>{if(e.length&&!eR){ez(!0);try{await Promise.all(e.map(e=>fetch(`/api/providers/${e}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:t})}))),await g(e1,eU)}catch(e){console.error("Error bulk toggling connections:",e)}finally{ez(!1)}}},[eR,e1,eU]),to="all"===eC?"All providers":L(eC),td=eQ.eligibleConnections>0,tc=ts.length>0,tu=eQ.eligibleConnections?eQ.providerFilteredConnections?{icon:"filter_alt_off",title:"No Accounts On This Page",description:"Try moving to another page or refreshing the current filters."}:{icon:"filter_alt_off",title:"No Accounts Match Current Filters",description:"all"===eC?"Try changing the account status filter to see more quota trackers.":`No ${"inactive"===eq?"turned off":"active"===eq?"active":"matching"} accounts found for ${eC}.`}:{icon:"cloud_off",title:"No Providers Connected",description:"Connect to providers with OAuth to track your API quota limits and usage."},tm=function(e){var t;let{start:r,end:a}=(t=e).total?{start:(t.page-1)*t.pageSize+1,end:Math.min(t.page*t.pageSize,t.total)}:{start:0,end:0};return`Showing ${r}-${a} of ${e.total}`}(eG),tx=!c.includes(eB);return el||td?el||tc?(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsx)("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-end",children:(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-1.5",children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsxs)("button",{type:"button",onClick:()=>eF(e=>!e),className:"flex h-8 items-center justify-between gap-1 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-haspopup":"menu","aria-expanded":eI,title:"Filter quota providers",children:[(0,a.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:["all"===eC?(0,a.jsx)("span",{className:"material-symbols-outlined text-[14px] text-text-muted",children:"apps"}):(0,a.jsx)(n.A,{src:`/providers/${eC}.png`,alt:eC,size:18,className:"size-[18px] rounded object-contain",fallbackText:eC.slice(0,2).toUpperCase()}),(0,a.jsx)("span",{className:"truncate hidden lg:inline",children:to})]}),(0,a.jsx)("span",{className:"material-symbols-outlined text-[14px] text-text-muted",children:"expand_more"})]}),eI&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"fixed inset-0 z-30 bg-transparent","aria-label":"Close provider filter",onClick:()=>eF(!1)}),(0,a.jsxs)("div",{className:"absolute left-0 z-40 mt-2 w-64 overflow-hidden rounded-2xl border border-black/10 bg-surface/95 p-1.5 shadow-xl shadow-black/10 backdrop-blur dark:border-white/10 dark:bg-surface/95 sm:w-72",children:[(0,a.jsxs)("button",{type:"button",onClick:()=>{"all"!==eC&&eW(1),eS("all"),eF(!1)},className:`flex w-full items-center gap-3 rounded-xl px-3 py-2.5 text-left text-sm transition-colors ${"all"===eC?"bg-primary/10 text-primary":"text-text-primary hover:bg-black/5 dark:hover:bg-white/10"}`,children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[22px]",children:"apps"}),(0,a.jsx)("span",{className:"font-medium",children:"All providers"}),"all"===eC&&(0,a.jsx)("span",{className:"material-symbols-outlined ml-auto text-[20px]",children:"check"})]}),(0,a.jsx)("div",{className:"my-1 h-px bg-black/10 dark:bg-white/10"}),(0,a.jsx)("div",{className:"max-h-72 overflow-y-auto pr-1",children:e$.map(e=>(0,a.jsxs)("button",{type:"button",onClick:()=>{eC!==e&&eW(1),eS(e),eF(!1)},className:`flex w-full items-center gap-3 rounded-xl px-3 py-2.5 text-left text-sm transition-colors ${eC===e?"bg-primary/10 text-primary":"text-text-primary hover:bg-black/5 dark:hover:bg-white/10"}`,children:[(0,a.jsx)(n.A,{src:`/providers/${e}.png`,alt:e,size:24,className:"size-6 rounded-md object-contain",fallbackText:e.slice(0,2).toUpperCase()}),(0,a.jsx)("span",{className:"font-medium",children:L(e)}),eC===e&&(0,a.jsx)("span",{className:"material-symbols-outlined ml-auto text-[20px]",children:"check"})]},e))})]})]})]}),(0,a.jsx)("select",{value:eq,onChange:e=>{let t=e.target.value;eq!==t&&eW(1),eE(t)},className:"h-8 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary outline-none transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-label":"Filter accounts by status",children:u.map(e=>(0,a.jsx)("option",{value:e.value,children:e.label},e.value))}),"codex"===eC&&(0,a.jsx)("select",{value:e_,onChange:e=>eT(e.target.value),className:"h-8 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary outline-none transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-label":"Sort Codex quotas by remaining",children:m.map(e=>(0,a.jsx)("option",{value:e.value,children:e.label},e.value))}),(0,a.jsxs)("button",{type:"button",onClick:()=>eL(e=>!e),"aria-pressed":eM,className:`flex h-8 shrink-0 items-center gap-1 rounded-lg border px-2 text-xs transition-colors ${eM?"border-amber-500/40 bg-amber-500/10 text-amber-500":"border-black/10 text-text-primary hover:bg-black/5 dark:border-white/10 dark:hover:bg-white/5"}`,title:"Sort accounts by earliest quota reset time",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"hourglass_top"}),(0,a.jsx)("span",{className:"hidden sm:inline",children:"Expiring first"})]}),(0,a.jsxs)("button",{type:"button",onClick:()=>{tl(ts.filter(e=>(e.isActive??!0)&&tn(e)).map(e=>e.id),!1)},disabled:eR,className:"flex h-8 shrink-0 items-center gap-1 rounded-lg border border-red-500/30 px-2 text-xs text-red-500 transition-colors hover:bg-red-500/10 disabled:opacity-50",title:"Disable connections with depleted quota on the current page",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"block"}),(0,a.jsx)("span",{className:"hidden sm:inline",children:"Turn off Empty"})]}),(0,a.jsxs)("button",{type:"button",onClick:()=>{tl(ts.filter(e=>!(e.isActive??!0)&&!tn(e)).map(e=>e.id),!0)},disabled:eR,className:"flex h-8 shrink-0 items-center gap-1 rounded-lg border border-emerald-500/30 px-2 text-xs text-emerald-500 transition-colors hover:bg-emerald-500/10 disabled:opacity-50",title:"Enable connections that still have quota on the current page",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"check_circle"}),(0,a.jsx)("span",{className:"hidden sm:inline",children:"Turn on Available"})]}),(0,a.jsxs)("button",{onClick:()=>Q(e=>!e),className:"flex h-8 shrink-0 items-center gap-1 rounded-lg border border-black/10 px-2 text-xs transition-colors hover:bg-black/5 dark:border-white/10 dark:hover:bg-white/5",title:V?"Disable auto-refresh":"Enable auto-refresh",children:[(0,a.jsx)("span",{className:`material-symbols-outlined text-[14px] ${V?"text-primary":"text-text-muted"}`,children:V?"toggle_on":"toggle_off"}),(0,a.jsx)("span",{className:"hidden text-text-primary sm:inline",children:"Auto-refresh"}),V&&(0,a.jsxs)("span",{className:"text-[10px] text-text-muted tabular-nums",children:["(",es,"s)"]})]}),(0,a.jsx)("button",{type:"button",onClick:()=>te(!0),disabled:ea,className:"flex h-8 shrink-0 items-center gap-1 rounded-lg border border-black/10 px-2 text-xs text-text-primary transition-colors hover:bg-black/5 dark:border-white/10 dark:hover:bg-white/5 disabled:opacity-50",title:"Refresh all",children:(0,a.jsx)("span",{className:`material-symbols-outlined text-[14px] ${ea?"animate-spin":""}`,children:"refresh"})})]})}),eM&&(0,a.jsx)("div",{className:"rounded-xl border border-amber-500/20 bg-amber-500/10 px-3 py-2 text-xs text-amber-700 dark:text-amber-300",children:"Expiring-first currently reorders accounts inside the current page. Cross-page ordering still follows backend pagination."}),(0,a.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3",children:ts.map(r=>{let i,s,l,o=W[r.id],d=J[r.id],c=H[r.id],u=!1===r.isActive,m="codex"===r.provider,h="claude"===r.provider?o?.raw?.resetCredits:null,p=m?"Codex reset credit":"Claude limit reset",b=Number.isFinite(s="number"==typeof(i=o?.raw?.resetCredits?.availableCount)?i:Number(i))?Math.max(0,s):0,g=ex===r.id,f=ed===r.id||eu===r.id||g,y=o?.quotas||[],w=function(e,t=[],r={}){if(!Array.isArray(t)||0===t.length)return[];let a=v(e,r,t);return 0===a.size?t:t.filter(e=>!a.has(k(e)))}(r.provider,y,eD),S=function(e,t=[],r={}){if(!Array.isArray(t)||0===t.length)return[];let a=v(e,r,t);return 0===a.size?[]:t.filter(e=>a.has(k(e)))}(r.provider,y,eD);return(0,a.jsxs)(A.default,{padding:"none",className:`min-w-0 ${u?"opacity-60":""}`,children:[(0,a.jsx)("div",{className:"px-3 py-2 border-b border-black/10 dark:border-white/10",children:(0,a.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2 min-w-0",children:[(0,a.jsx)("div",{className:"w-8 h-8 shrink-0 rounded-md flex items-center justify-center overflow-hidden",children:(0,a.jsx)(n.A,{src:`/providers/${r.provider}.png`,alt:r.provider,size:32,className:"object-contain",fallbackText:r.provider?.slice(0,2).toUpperCase()||"PR"})}),(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("h3",{className:"text-sm font-semibold text-text-primary truncate",children:L(r.provider)}),x(r)?(0,a.jsx)("p",{className:"text-xs text-text-muted truncate",children:x(r)}):null,T(r)?(0,a.jsx)("p",{className:"text-[11px] text-text-muted/80 truncate",children:T(r)}):null,"kiro"===r.provider&&(0,a.jsxs)("div",{className:"mt-1 flex flex-wrap items-center gap-1",children:[(0,a.jsx)("span",{className:"rounded-full bg-brand-500/10 px-2 py-0.5 text-[10px] font-semibold text-brand-600 dark:text-brand-300",children:(l=r.providerSpecificData?.authMethod)&&q[l]?q[l]:"api_key"===r.authType?"API Key":"OAuth"}),D(r)&&(0,a.jsx)("span",{className:"rounded-full bg-blue-500/10 px-2 py-0.5 text-[10px] font-semibold text-blue-600 dark:text-blue-400",children:D(r)}),(0,a.jsx)("span",{className:`rounded-full px-2 py-0.5 text-[10px] font-semibold ${u?"bg-surface-2 text-text-muted":"active"===r.testStatus||"success"===r.testStatus?"bg-green-500/10 text-green-600 dark:text-green-400":"error"===r.testStatus||"expired"===r.testStatus||"unavailable"===r.testStatus?"bg-red-500/10 text-red-600 dark:text-red-400":"bg-surface-2 text-text-muted"}`,children:u?"disabled":r.testStatus||"unknown"}),r.providerSpecificData?.profileArn&&(0,a.jsxs)("button",{type:"button",onClick:()=>t(r.providerSpecificData.profileArn,r.id),title:r.providerSpecificData.profileArn,className:"inline-flex max-w-full items-center gap-1 rounded-full border border-border-subtle px-2 py-0.5 text-[10px] text-text-muted transition-colors hover:text-primary",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:e===r.id?"check":"content_copy"}),(0,a.jsx)("code",{className:"truncate font-mono",children:r.providerSpecificData.profileArn})]})]})]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-1 shrink-0",children:[(m||h)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(C.default,{text:b>0?h?`Use your reset now (${b} left, use by ${I(h.expiresAt)}) \xb7 refills ${M(h.clears)}`:`Use one ${p}. Available: ${b}`:`No ${p}s available`,children:(0,a.jsxs)("button",{type:"button",onClick:()=>eb({connection:r,resetCreditCount:b}),disabled:b<=0||d||f,"aria-label":b>0?`Use one ${p}. ${b} available.`:`No ${p}s available`,className:`flex h-8 min-w-10 items-center justify-center gap-1 rounded-lg border px-2 text-[11px] font-medium tabular-nums transition-colors focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary/60 disabled:cursor-not-allowed disabled:opacity-60 ${b>0?"border-primary/30 bg-primary/5 text-primary hover:bg-primary/10":"border-black/10 bg-black/[0.02] text-text-muted dark:border-white/10 dark:bg-white/[0.03]"}`,children:[(0,a.jsx)("span",{className:`material-symbols-outlined text-[15px] ${g?"animate-spin":""}`,children:g?"progress_activity":"restart_alt"}),(0,a.jsx)("span",{children:b})]})}),(0,a.jsx)(C.default,{text:m?"View Codex reset credit expiry":"View Claude Code reset expiry",children:(0,a.jsx)("button",{type:"button",onClick:()=>m?e8(r):e4(r,h),disabled:d||f,"aria-label":m?"View Codex reset credit expiry":"View Claude Code reset expiry",className:"flex h-8 w-8 items-center justify-center rounded-lg border border-black/10 text-text-muted transition-colors hover:bg-black/5 hover:text-primary disabled:cursor-not-allowed disabled:opacity-50 dark:border-white/10 dark:hover:bg-white/5",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[17px]",children:"schedule"})})})]}),E[r.provider]&&"oauth"===r.authType&&(0,a.jsx)(C.default,{text:_[r.provider],children:(0,a.jsx)("button",{type:"button",onClick:()=>tt(r.id,r.provider,Y[r.provider]?.[r.id]!==!0),"aria-label":"Toggle auto-ping",className:`flex h-8 w-8 items-center justify-center rounded-lg transition-colors hover:bg-black/5 dark:hover:bg-white/5 ${Y[r.provider]?.[r.id]===!0?"text-primary":"text-text-muted"}`,children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"bolt"})})}),(0,a.jsx)(C.default,{text:"Refresh quota",children:(0,a.jsx)("button",{type:"button",onClick:()=>e2(r.id,r.provider),disabled:d||f,"aria-label":"Refresh quota",className:"flex h-8 w-8 items-center justify-center rounded-lg hover:bg-black/5 dark:hover:bg-white/5 transition-colors disabled:opacity-50",children:(0,a.jsx)("span",{className:`material-symbols-outlined text-[18px] text-text-muted ${d?"animate-spin":""}`,children:"refresh"})})}),(0,a.jsx)(C.default,{text:"Edit connection",children:(0,a.jsx)("button",{type:"button",onClick:()=>{ev(r),ew(!0)},disabled:f,"aria-label":"Edit connection",className:"flex h-8 w-8 items-center justify-center rounded-lg hover:bg-black/5 dark:hover:bg-white/5 text-text-muted hover:text-primary transition-colors disabled:opacity-50",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"edit"})})}),(0,a.jsx)(C.default,{text:"Delete connection",children:(0,a.jsx)("button",{type:"button",onClick:()=>e6(r.id),disabled:f,"aria-label":"Delete connection",className:"flex h-8 w-8 items-center justify-center rounded-lg hover:bg-red-500/10 text-red-500 transition-colors disabled:opacity-50",children:(0,a.jsx)("span",{className:`material-symbols-outlined text-[18px] ${ed===r.id?"animate-pulse":""}`,children:"delete"})})}),(0,a.jsx)("div",{className:"inline-flex items-center pl-0.5",title:r.isActive??!0?"Disable connection":"Enable connection",children:(0,a.jsx)(N.default,{size:"sm",checked:r.isActive??!0,disabled:f,onChange:e=>e7(r.id,e)})})]})]})}),(0,a.jsxs)("div",{className:"px-2 py-1.5",children:[d?(0,a.jsx)("div",{className:"text-center py-5 text-text-muted",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[28px] animate-spin",children:"progress_activity"})}):c?(0,a.jsxs)("div",{className:"text-center py-5",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[28px] text-red-500",children:"error"}),(0,a.jsx)("p",{className:"mt-1.5 text-xs text-text-muted",children:c})]}):o?.message?(0,a.jsx)("div",{className:"text-center py-5",children:(0,a.jsx)("p",{className:"text-xs text-text-muted",children:o.message})}):(0,a.jsx)(j,{quotas:w,compact:!0,sortMode:"default",showSortLabel:"codex"===r.provider&&"default"!==e_,onHideQuota:e=>ta(r.provider,e)}),o?.message&&!c&&!d&&(0,a.jsx)("p",{className:"mt-2 px-1 text-[10px] leading-relaxed text-text-muted",children:o.message}),S.length>0&&(0,a.jsxs)("div",{className:"mt-2 flex min-w-0 items-center gap-1 border-t border-black/5 pt-2 text-[10px] text-text-muted dark:border-white/5",children:[(0,a.jsx)("span",{className:"material-symbols-outlined shrink-0 text-[14px]",children:"visibility_off"}),(0,a.jsx)("span",{className:"shrink-0",children:"Hidden:"}),(0,a.jsx)("div",{className:"flex min-w-0 flex-1 items-center gap-1 overflow-x-auto whitespace-nowrap pb-2",children:S.map(e=>(0,a.jsx)("button",{type:"button",onClick:()=>ti(r.provider,e),className:"shrink-0 rounded-md border border-black/10 px-1.5 py-0.5 transition-colors hover:bg-black/5 hover:text-text-primary dark:border-white/10 dark:hover:bg-white/5",title:"Show this quota row",children:e.name},k(e)))})]})]})]},r.id)})}),(0,a.jsx)("div",{className:"rounded-xl border border-black/10 bg-black/[0.02] px-3 py-2 dark:border-white/10 dark:bg-white/[0.03]",children:(0,a.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,a.jsx)("span",{className:"text-xs text-text-muted",children:tm}),(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsxs)("select",{value:tx?"custom":String(eB),onChange:e=>{let t=e.target.value;if("custom"===t)return;let r=Number.parseInt(t,10);Number.isFinite(r)&&(eW(1),eJ(r),eH(String(r)))},className:"h-8 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary outline-none transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-label":"Accounts per page",children:[c.map(e=>(0,a.jsxs)("option",{value:String(e),children:[e," / page"]},e)),(0,a.jsx)("option",{value:"custom",children:"Custom"})]}),(0,a.jsx)("input",{type:"number",min:"1",max:String(500),inputMode:"numeric",value:eK,onChange:e=>eH(e.target.value),onBlur:()=>{let e=Number.parseInt(eK,10);if(!Number.isFinite(e))return void eH(String(eB));let t=Math.min(500,Math.max(1,e));eW(1),eJ(t),eH(String(t))},onKeyDown:e=>{if("Enter"!==e.key)return;let t=Number.parseInt(eK,10);if(!Number.isFinite(t))return void eH(String(eB));let r=Math.min(500,Math.max(1,t));eW(1),eJ(r),eH(String(r))},className:"h-8 w-20 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary outline-none transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-label":"Custom accounts per page",placeholder:"Custom"}),(0,a.jsxs)("span",{className:"text-xs text-text-muted",children:["Page ",eG.page," / ",eG.totalPages]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("button",{type:"button",onClick:()=>eW(1),disabled:eG.page<=1||el||ea,className:"flex h-8 items-center rounded-lg border border-black/10 px-3 text-xs text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5",children:"First Page"}),(0,a.jsx)("button",{type:"button",onClick:()=>eW(e=>Math.max(1,e-1)),disabled:eG.page<=1||el||ea,className:"flex h-8 w-8 items-center justify-center rounded-lg border border-black/10 text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5","aria-label":"Previous accounts page",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"chevron_left"})}),(0,a.jsx)("button",{type:"button",onClick:()=>eW(e=>Math.min(eG.totalPages,e+1)),disabled:eG.page>=eG.totalPages||el||ea,className:"flex h-8 w-8 items-center justify-center rounded-lg border border-black/10 text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5","aria-label":"Next accounts page",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"chevron_right"})}),(0,a.jsx)("button",{type:"button",onClick:()=>eW(eG.totalPages),disabled:eG.page>=eG.totalPages||el||ea,className:"flex h-8 items-center rounded-lg border border-black/10 px-3 text-xs text-text-primary transition-colors hover:bg-black/5 disabled:cursor-not-allowed disabled:opacity-40 dark:border-white/10 dark:hover:bg-white/5",children:"Last Page"})]})]})}),(0,a.jsx)(S.uo,{isOpen:!!ep,onClose:()=>{ex||eb(null)},onConfirm:async()=>{let e=ep?.connection;e&&(await e3(e.id,e.provider),eb(null))},title:ep?.connection?.provider==="claude"?"Reset Claude limits?":"Reset Codex limit?",message:ep?.connection?.provider==="claude"?`Refills your ${M(W[ep.connection.id]?.raw?.resetCredits?.clears)} now for ${x(ep.connection)||"this account"} \xb7 your weekly reset day stays ${I(W[ep.connection.id]?.raw?.resetCredits?.weeklyResetsAt)}. This cannot be undone. Resets left: ${ep.resetCreditCount??0}.`:`Use 1 Codex reset credit for ${x(ep?.connection||{})||"this account"}. This cannot be undone. Remaining credits: ${ep?.resetCreditCount??0}.`,confirmText:"Reset limit",cancelText:"Cancel",variant:"danger",loading:!!ex}),eg&&(0,a.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 px-4 backdrop-blur-sm",children:(0,a.jsxs)("div",{className:"w-full max-w-2xl overflow-hidden rounded-2xl border border-black/15 bg-white shadow-2xl ring-1 ring-black/10 dark:border-white/15 dark:bg-neutral-950 dark:ring-white/10",children:[(0,a.jsxs)("div",{className:"flex items-start justify-between gap-3 border-b border-black/10 bg-black/[0.03] px-4 py-3 dark:border-white/10 dark:bg-white/[0.04]",children:[(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("h3",{className:"text-base font-semibold text-text-primary",children:eg.data?.kind==="claude"?"Claude Code Limit Resets":"Codex Reset Credit Expiry"}),(0,a.jsx)("p",{className:"mt-0.5 truncate text-xs text-text-muted",children:x(eg.connection)||(eg.data?.kind==="claude"?"Claude account":"Codex account")})]}),(0,a.jsx)("button",{type:"button",onClick:()=>ef(null),className:"flex h-8 w-8 items-center justify-center rounded-lg text-text-muted transition-colors hover:bg-black/5 hover:text-text-primary dark:hover:bg-white/5","aria-label":"Close reset credit expiry modal",children:(0,a.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"close"})})]}),(0,a.jsx)("div",{className:"max-h-[70vh] overflow-auto bg-white p-4 dark:bg-neutral-950",children:eg.loading?(0,a.jsxs)("div",{className:"flex items-center justify-center gap-2 py-10 text-sm text-text-muted",children:[(0,a.jsx)("span",{className:"material-symbols-outlined animate-spin text-[20px]",children:"progress_activity"}),"Loading reset credits..."]}):eg.error?(0,a.jsx)("div",{className:"rounded-xl border border-red-500/20 bg-red-500/10 px-3 py-2 text-sm text-red-600 dark:text-red-300",children:eg.error}):eg.data?.kind==="claude"&&eg.data.grants?.length?(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between rounded-xl border border-black/10 bg-black/[0.02] px-3 py-2 text-xs text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:[(0,a.jsxs)("span",{children:[eg.data.availableCount??0," reset",1===eg.data.availableCount?"":"s"," left"]}),(0,a.jsxs)("span",{children:["Weekly reset day: ",I(eg.data.weeklyResetsAt)]})]}),(0,a.jsx)("div",{className:"overflow-x-auto rounded-xl border border-black/10 dark:border-white/10",children:(0,a.jsxs)("table",{className:"w-full min-w-[560px] text-left text-sm",children:[(0,a.jsx)("thead",{className:"bg-black/[0.03] text-xs uppercase tracking-wide text-text-muted dark:bg-white/[0.04]",children:(0,a.jsxs)("tr",{children:[(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Reset"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Left"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Refills"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Use By"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Remaining"})]})}),(0,a.jsx)("tbody",{children:(eg.data.grants||[]).map(e=>(0,a.jsxs)("tr",{className:"border-t border-black/5 dark:border-white/5",children:[(0,a.jsxs)("td",{className:"px-3 py-2",children:[(0,a.jsx)("div",{className:"text-text-primary",children:e.label||e.id}),(0,a.jsx)("span",{className:"mt-1 inline-block rounded-full bg-primary/10 px-2 py-0.5 text-xs font-medium text-primary",children:e.resetsLeft<=0?"used":e.paused?"paused":e.endsAt&&new Date(e.endsAt).getTime()<=Date.now()?"expired":e.usableNow?"usable now":e.startsAt&&new Date(e.startsAt).getTime()>Date.now()?"not started":e.useRequiresLimit?"at limit only":"unavailable"})]}),(0,a.jsxs)("td",{className:"whitespace-nowrap px-3 py-2 font-medium tabular-nums text-text-primary",children:[e.resetsLeft," / ",e.resetsTotal]}),(0,a.jsx)("td",{className:"px-3 py-2 text-text-muted",children:M(e.clears)}),(0,a.jsx)("td",{className:"px-3 py-2 text-text-primary",children:I(e.endsAt)}),(0,a.jsx)("td",{className:"whitespace-nowrap px-3 py-2 font-medium text-text-primary",children:F(e.endsAt)})]},e.id))})]})})]}):eg.data?.credits?.length?(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between rounded-xl border border-black/10 bg-black/[0.02] px-3 py-2 text-xs text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:[(0,a.jsxs)("span",{children:[eg.data.credits.length," reset credit",1===eg.data.credits.length?"":"s"]}),(0,a.jsxs)("span",{children:[eg.data.availableCount??0," available"]})]}),(0,a.jsx)("div",{className:"overflow-x-auto rounded-xl border border-black/10 dark:border-white/10",children:(0,a.jsxs)("table",{className:"w-full min-w-[560px] text-left text-sm",children:[(0,a.jsx)("thead",{className:"bg-black/[0.03] text-xs uppercase tracking-wide text-text-muted dark:bg-white/[0.04]",children:(0,a.jsxs)("tr",{children:[(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Status"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Granted At"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Expires At"}),(0,a.jsx)("th",{className:"px-3 py-2 font-medium",children:"Remaining"})]})}),(0,a.jsx)("tbody",{children:eg.data.credits.map((e,t)=>(0,a.jsxs)("tr",{className:"border-t border-black/5 dark:border-white/5",children:[(0,a.jsx)("td",{className:"px-3 py-2",children:(0,a.jsx)("span",{className:"rounded-full bg-primary/10 px-2 py-0.5 text-xs font-medium text-primary",children:e.status||"unknown"})}),(0,a.jsx)("td",{className:"px-3 py-2 text-text-muted",children:I(e.grantedAt)}),(0,a.jsx)("td",{className:"px-3 py-2 text-text-primary",children:I(e.expiresAt)}),(0,a.jsx)("td",{className:"px-3 py-2 font-medium text-text-primary",children:F(e.expiresAt)})]},`${e.status}-${e.expiresAt||t}`))})]})})]}):(0,a.jsx)("div",{className:"rounded-xl border border-black/10 bg-black/[0.02] px-3 py-8 text-center text-sm text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:eg.data?.kind==="claude"?"No limit resets available for this account.":"No reset credit details returned for this account."})})]})}),(0,a.jsx)(S.wI,{isOpen:ey,connection:ek,proxyPools:ej,onSave:e9,onClose:()=>{ew(!1),ev(null)}})]}):(0,a.jsx)(A.default,{padding:"lg",children:(0,a.jsxs)("div",{className:"text-center py-12",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[64px] text-text-muted opacity-20",children:tu.icon}),(0,a.jsx)("h3",{className:"mt-4 text-lg font-semibold text-text-primary",children:tu.title}),(0,a.jsx)("p",{className:"mt-2 text-sm text-text-muted max-w-md mx-auto",children:tu.description})]})}):(0,a.jsx)(A.default,{padding:"lg",children:(0,a.jsxs)("div",{className:"text-center py-12",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-[64px] text-text-muted opacity-20",children:"cloud_off"}),(0,a.jsx)("h3",{className:"mt-4 text-lg font-semibold text-text-primary",children:"No Providers Connected"}),(0,a.jsx)("p",{className:"mt-2 text-sm text-text-muted max-w-md mx-auto",children:"Connect to providers with OAuth to track your API quota limits and usage."})]})})}}},e=>{e.O(0,[763,8105,620,705,5497,8441,3794,7358],()=>e(e.s=63818)),_N_E=e.O()}]);
|