Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

workspace-presentation-context.tsx

13 lines728 Bytes

1import { createContext, type ReactElement, type ReactNode } from "react";
2​
3/** Android's native presentation stack surrounds all workspace columns. */
4export const WorkspacePresentationHostContext = createContext(false);
5/** Lays out the workspace columns around the navigator's content and its sidebar route. */
6export const WorkspaceColumnsRendererContext = createContext<
7 ((content: ReactNode, sidebar: ReactNode) => ReactElement) | null
8>(null);
9/**
10 * The workspace route on top, under any presented overlays. A screen blurred by an overlay is still
11 * this route, so the workspace columns beside it keep their layout under the overlay.
12 */
13export const WorkspaceVisibleRouteContext = createContext<string | null>(null);