mirror of
https://github.com/supabase/supabase.git
synced 2026-10-07 18:35:07 +03:00
* all settings moved into the right places * clean a few things up * update ui for auth settings * more updating * rearrange settings * Update SmtpForm.tsx * updated styling * add old auth page to show links * add copy * udpate copy * smtp links * auth fixes * Smol fix * Another smol fix * Fix tab page menu selection * Add missing border * Gah one last one * Smol improvement for redirects from settings/auth to use id * Update apps/studio/components/layouts/AuthLayout/AuthLayout.utils.ts Co-authored-by: Kang Ming <kang.ming1996@gmail.com> * Update apps/studio/pages/project/[ref]/auth/mfa.tsx Co-authored-by: Kang Ming <kang.ming1996@gmail.com> * Update apps/studio/pages/project/[ref]/auth/mfa.tsx Co-authored-by: Kang Ming <kang.ming1996@gmail.com> * remove recommendation --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> Co-authored-by: Kang Ming <kang.ming1996@gmail.com>
84 lines
2.4 KiB
TypeScript
84 lines
2.4 KiB
TypeScript
import type { ProductMenuGroup } from 'components/ui/ProductMenu/ProductMenu.types'
|
|
import { IS_PLATFORM } from 'lib/constants'
|
|
|
|
export const generateAuthMenu = (ref: string): ProductMenuGroup[] => {
|
|
return [
|
|
{
|
|
title: 'Manage',
|
|
items: [{ name: 'Users', key: 'users', url: `/project/${ref}/auth/users`, items: [] }],
|
|
},
|
|
{
|
|
title: 'Configuration',
|
|
items: [
|
|
{
|
|
name: 'Policies',
|
|
key: 'policies',
|
|
url: `/project/${ref}/auth/policies`,
|
|
items: [],
|
|
},
|
|
...(IS_PLATFORM
|
|
? [
|
|
{
|
|
name: 'Sign In / Up',
|
|
key: 'sign-in-up',
|
|
pages: ['providers', 'third-party'],
|
|
url: `/project/${ref}/auth/providers`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Sessions',
|
|
key: 'sessions',
|
|
url: `/project/${ref}/auth/sessions`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Rate Limits',
|
|
key: 'rate-limits',
|
|
url: `/project/${ref}/auth/rate-limits`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Emails',
|
|
key: 'emails',
|
|
pages: ['templates', 'smtp'],
|
|
url: `/project/${ref}/auth/templates`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Multi-Factor',
|
|
key: 'mfa',
|
|
url: `/project/${ref}/auth/mfa`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'URL Configuration',
|
|
key: 'url-configuration',
|
|
url: `/project/${ref}/auth/url-configuration`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Attack Protection',
|
|
key: 'protection',
|
|
url: `/project/${ref}/auth/protection`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Auth Hooks',
|
|
key: 'hooks',
|
|
url: `/project/${ref}/auth/hooks`,
|
|
items: [],
|
|
label: 'BETA',
|
|
},
|
|
{
|
|
name: 'Advanced',
|
|
key: 'advanced',
|
|
url: `/project/${ref}/auth/advanced`,
|
|
items: [],
|
|
},
|
|
]
|
|
: []),
|
|
],
|
|
},
|
|
]
|
|
}
|