mirror of
https://github.com/docmost/docmost.git
synced 2026-05-07 06:23:06 +08:00
f12866cf42
* feat(EE): fulltext search in attachments * feat: global search - search filters - attachments search ui - and more * fix import * fix import * rename migration * add GIN index * fix table name * sanitize
24 lines
841 B
TypeScript
24 lines
841 B
TypeScript
import { UserProvider } from "@/features/user/user-provider.tsx";
|
|
import { Outlet, useParams } from "react-router-dom";
|
|
import GlobalAppShell from "@/components/layouts/global/global-app-shell.tsx";
|
|
import { PosthogUser } from "@/ee/components/posthog-user.tsx";
|
|
import { isCloud } from "@/lib/config.ts";
|
|
import { SearchSpotlight } from "@/features/search/components/search-spotlight.tsx";
|
|
import React from "react";
|
|
import { useGetSpaceBySlugQuery } from "@/features/space/queries/space-query.ts";
|
|
|
|
export default function Layout() {
|
|
const { spaceSlug } = useParams();
|
|
const { data: space } = useGetSpaceBySlugQuery(spaceSlug);
|
|
|
|
return (
|
|
<UserProvider>
|
|
<GlobalAppShell>
|
|
<Outlet />
|
|
</GlobalAppShell>
|
|
{isCloud() && <PosthogUser />}
|
|
<SearchSpotlight spaceId={space?.id} />
|
|
</UserProvider>
|
|
);
|
|
}
|