mirror of
https://github.com/supabase/supabase.git
synced 2026-10-10 11:55:05 +03:00
* add CommandMenuTriggerInput in ui-patterns * optimize search input responsiveness * add event on commandMenu opened * add event on debounced commandMenu input submission * add event on commandMenu command selection * add commandMenu telemetry to studio, www and docs --------- Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>
45 lines
1.6 KiB
TypeScript
45 lines
1.6 KiB
TypeScript
import type { PropsWithChildren } from 'react'
|
|
|
|
import { FeatureFlagProvider, IS_PLATFORM, ThemeProvider } from 'common'
|
|
import { SonnerToaster, TooltipProvider } from 'ui'
|
|
import SiteLayout from '~/layouts/SiteLayout'
|
|
import { API_URL } from '~/lib/constants'
|
|
import { AuthContainer } from './auth/auth.client'
|
|
import { DocsCommandMenu, DocsCommandProvider } from './command'
|
|
import { QueryClientProvider } from './data/queryClient.client'
|
|
import { PageTelemetry } from './telemetry/telemetry.client'
|
|
import { ScrollRestoration } from './ui/helpers.scroll.client'
|
|
import { ThemeSandbox } from './ui/theme.client'
|
|
|
|
/**
|
|
* Global providers that wrap the entire app
|
|
*/
|
|
function GlobalProviders({ children }: PropsWithChildren) {
|
|
return (
|
|
<QueryClientProvider>
|
|
<AuthContainer>
|
|
<FeatureFlagProvider API_URL={API_URL} enabled={IS_PLATFORM}>
|
|
<PageTelemetry />
|
|
<ScrollRestoration />
|
|
<ThemeProvider defaultTheme="system" enableSystem disableTransitionOnChange>
|
|
<TooltipProvider delayDuration={0}>
|
|
<DocsCommandProvider>
|
|
<div className="flex flex-col">
|
|
<SiteLayout>
|
|
{children}
|
|
<DocsCommandMenu />
|
|
</SiteLayout>
|
|
<ThemeSandbox />
|
|
</div>
|
|
</DocsCommandProvider>
|
|
<SonnerToaster position="top-right" />
|
|
</TooltipProvider>
|
|
</ThemeProvider>
|
|
</FeatureFlagProvider>
|
|
</AuthContainer>
|
|
</QueryClientProvider>
|
|
)
|
|
}
|
|
|
|
export { GlobalProviders }
|