mirror of
https://github.com/supabase/supabase.git
synced 2026-10-18 23:59:08 +03:00
* Start * Start * Move advisors * cleanup * Add redirects * Check for an id * Cleanup * Link to the advisor from the table editor * Cleanup * Link to rows in performance grid
27 lines
659 B
TypeScript
27 lines
659 B
TypeScript
import type { ProductMenuGroup } from 'components/ui/ProductMenu/ProductMenu.types'
|
|
import type { Project } from 'data/projects/project-detail-query'
|
|
|
|
export const generateAdvisorsMenu = (project?: Project): ProductMenuGroup[] => {
|
|
const ref = project?.ref ?? 'default'
|
|
|
|
return [
|
|
{
|
|
title: 'Advisors',
|
|
items: [
|
|
{
|
|
name: 'Security',
|
|
key: 'security',
|
|
url: `/project/${ref}/advisors/security`,
|
|
items: [],
|
|
},
|
|
{
|
|
name: 'Performance',
|
|
key: 'performance',
|
|
url: `/project/${ref}/advisors/performance`,
|
|
items: [],
|
|
},
|
|
],
|
|
},
|
|
]
|
|
}
|