Skip to content

AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.

416 B
Raw Blame
// Kept out of the "use client" sidebar module so server components can read it too.
// Not `sidebar_state`: automatic collapses wrote that one too, so its value is no choice.
export const SIDEBAR_COOKIE_NAME = "sidebar_open";

export function parseSidebarCookie(
  value: string | undefined,
): boolean | undefined {
  if (value === "true") return true;
  if (value === "false") return false;
  return undefined;
}