Files
supabase/apps/studio/components/interfaces/ApiAuthorization/ApiAuthorization.Schema.ts
Charis 6563dc7998 refactor: authorize page (#44522)
Refactor authorize page to move Next.js dependencies into the page shell
and have Next.js-agnostic code for the core logic. Add unit tests for
authorize screen.

## Summary by CodeRabbit

* **New Features**
* New end-to-end API authorization UI: loading, error, invalid,
approved, and main approval screens.
* Organization selector with preselection, create-organization link, MCP
warning, expiration handling, and approve/decline actions.
  * Improved page title handling via layout/head provider.

* **Tests**
* Added comprehensive component tests covering loading, error, approval
flows, organization states, validation, and side effects.
2026-04-06 10:02:56 -04:00

9 lines
312 B
TypeScript

import { z } from 'zod'
export const approvalFormSchema = z.object({
selectedOrgSlug: z.string().min(1, 'Please select an organization'),
})
export type IApprovalFormSchema = z.infer<typeof approvalFormSchema>
export type ApprovalState = 'indeterminate' | 'approving' | 'declining' | 'approved' | 'declined'