Home / Function/ ScopeDropdownCheckboxItem() — supabase Function Reference

ScopeDropdownCheckboxItem() — supabase Function Reference

Architecture documentation for the ScopeDropdownCheckboxItem() function in Scopes.tsx from the supabase codebase.

Entity Profile

Relationship Graph

Source Code

apps/studio/components/interfaces/Organization/OAuthApps/PublishAppSidePanel/Scopes.tsx lines 16–40

const ScopeDropdownCheckboxItem = ({
  children,
  scopeName,
  scopes,
  onChange,
}: PropsWithChildren<{
  scopeName: OAuthScope
  scopes: OAuthScope[]
  onChange: (v: OAuthScope[]) => void
}>) => {
  return (
    <DropdownMenuCheckboxItem
      checked={scopes.includes(scopeName)}
      onCheckedChange={(checked) => {
        if (checked) {
          onChange([...scopes, scopeName])
        } else {
          onChange([...scopes.filter((s) => s !== scopeName)])
        }
      }}
    >
      {children}
    </DropdownMenuCheckboxItem>
  )
}

Subdomains

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free