diff --git a/apps/studio/components/interfaces/App/CommandMenu/ContextSearchCommands.tsx b/apps/studio/components/interfaces/App/CommandMenu/ContextSearchCommands.tsx index 9cd507530de..8e61ba4731a 100644 --- a/apps/studio/components/interfaces/App/CommandMenu/ContextSearchCommands.tsx +++ b/apps/studio/components/interfaces/App/CommandMenu/ContextSearchCommands.tsx @@ -1,25 +1,26 @@ 'use client' -import { useMemo } from 'react' -import { Database } from 'lucide-react' +import { IS_PLATFORM } from 'common' +import { useIsFeatureEnabled } from 'hooks/misc/useIsFeatureEnabled' +import { useSelectedProjectQuery } from 'hooks/misc/useSelectedProject' import { Auth, EdgeFunctions, Storage } from 'icons' +import { Database } from 'lucide-react' +import { useMemo } from 'react' import type { ICommand } from 'ui-patterns/CommandMenu' import { CommandHeader, CommandInput, CommandWrapper, PageType, + useQuery, useRegisterCommands, useRegisterPage, useSetPage, - useQuery, } from 'ui-patterns/CommandMenu' + import { COMMAND_MENU_SECTIONS } from './CommandMenu.utils' -import { useSelectedProjectQuery } from 'hooks/misc/useSelectedProject' -import { orderCommandSectionsByPriority } from './ordering' import { ContextSearchResults } from './ContextSearchResults' -import { useFlag, IS_PLATFORM } from 'common' -import { useIsFeatureEnabled } from 'hooks/misc/useIsFeatureEnabled' +import { orderCommandSectionsByPriority } from './ordering' import type { SearchContextValue } from './SearchContext.types' interface SearchContextOption { @@ -81,7 +82,6 @@ function ContextSearchPage({ } export function useContextSearchCommands() { - const enableSearchEntitiesCommandMenu = useFlag('enableSearchEntitiesCommandMenu') const { data: project } = useSelectedProjectQuery() const setPage = useSetPage() @@ -147,6 +147,6 @@ export function useContextSearchCommands() { useRegisterCommands(COMMAND_MENU_SECTIONS.QUERY, contextCommands, { orderSection: orderCommandSectionsByPriority, sectionMeta: { priority: 3 }, - enabled: !IS_PLATFORM || (enableSearchEntitiesCommandMenu && !!project), + enabled: !IS_PLATFORM || !!project, }) } diff --git a/apps/studio/components/interfaces/App/CommandMenu/CreateCommands.tsx b/apps/studio/components/interfaces/App/CommandMenu/CreateCommands.tsx index 09fafe9e864..4885b327494 100644 --- a/apps/studio/components/interfaces/App/CommandMenu/CreateCommands.tsx +++ b/apps/studio/components/interfaces/App/CommandMenu/CreateCommands.tsx @@ -1,6 +1,6 @@ 'use client' -import { IS_PLATFORM, useFlag } from 'common' +import { IS_PLATFORM } from 'common' import { SIDEBAR_KEYS } from 'components/layouts/ProjectLayout/LayoutSidebar/LayoutSidebarProvider' import { Clock5, @@ -51,7 +51,6 @@ const Graphql = dynamic(() => import('icons').then((mod) => mod.Graphql)) const CREATE_STUDIO_ENTITY = 'Create Studio Entity' export function useCreateCommands(options?: CommandOptions) { - const enableCreateCommands = useFlag('enablecreatecommands') const setIsOpen = useSetCommandMenuOpen() const { ref, @@ -451,7 +450,7 @@ export function useCreateCommands(options?: CommandOptions) { }, { deps: [sections], - enabled: enableCreateCommands, + enabled: true, } ) @@ -469,7 +468,7 @@ export function useCreateCommands(options?: CommandOptions) { ...options, orderSection: (sections) => sections, sectionMeta: { priority: 3 }, - enabled: enableCreateCommands, + enabled: true, } ) }