Files
supabase__supabase/apps/studio/components/layouts/useLayoutNavCommands.ts
Francesco Sansalvadore 0bf22ee6fc chore(studio): update product naming (#50208)
workers -> compute

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Added the Compute experience for deploying, viewing, managing, and
monitoring compute instances.
- Added Compute navigation, instance detail pages, secrets, logs,
deployment dialogs, generated snippets, and CLI commands.
- Added filtering, status, availability, and data-loading support for
compute instances.

- **Updates**
- Updated labels, icons, links, feature controls, unified logs, and
secret-deletion messaging to use Compute terminology.
  - Compute routes now replace the previous Workers routes and pages.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-09-10 16:26:48 +02:00

37 lines
2.0 KiB
TypeScript

import { useFlag, useIsLoggedIn } from 'common'
import { useStorageGotoCommands } from '../interfaces/Storage/Storage.Commands'
import { useAdvisorsGoToCommands } from './AdvisorsLayout/Advisors.Commands'
import { useAuthGotoCommands } from './AuthLayout/Auth.Commands'
import { useBillingGotoCommands } from './BillingLayout/Billing.Commands'
import { useComputeGotoCommands } from './ComputeLayout/Compute.Commands'
import { useDatabaseGotoCommands } from './DatabaseLayout/Database.Commands'
import { useFunctionsGotoCommands } from './EdgeFunctionsLayout/EdgeFunctions.Commands'
import { useIntegrationsGotoCommands } from './IntegrationsLayout/Integrations.Commands'
import { useLogsGotoCommands } from './LogsLayout/Logs.Commands'
import { useProjectSettingsGotoCommands } from './ProjectSettingsLayout/ProjectSettings.Commands'
import { useReportsGotoCommands } from './ReportsLayout/Reports.Commands'
import { useSqlEditorGotoCommands } from './SQLEditorLayout/SqlEditor.Commands'
import { useTableEditorGotoCommands } from './TableEditorLayout/TableEditor.Commands'
import { useApiDocsGotoCommands } from '@/components/interfaces/ProjectAPIDocs/ProjectAPIDocs.Commands'
export function useLayoutNavCommands() {
const isLoggedIn = useIsLoggedIn()
const computeEnabled = useFlag('compute')
useTableEditorGotoCommands({ enabled: isLoggedIn })
useSqlEditorGotoCommands({ enabled: isLoggedIn })
useDatabaseGotoCommands({ enabled: isLoggedIn })
useAuthGotoCommands({ enabled: isLoggedIn })
useAdvisorsGoToCommands({ enabled: isLoggedIn })
useStorageGotoCommands({ enabled: isLoggedIn })
useFunctionsGotoCommands({ enabled: isLoggedIn })
useComputeGotoCommands({ enabled: isLoggedIn && computeEnabled })
useLogsGotoCommands({ enabled: isLoggedIn })
useReportsGotoCommands({ enabled: isLoggedIn })
useApiDocsGotoCommands({ enabled: isLoggedIn })
useProjectSettingsGotoCommands({ enabled: isLoggedIn })
useIntegrationsGotoCommands({ enabled: isLoggedIn })
useBillingGotoCommands({ enabled: isLoggedIn })
}